|  |  |  | 
|---|
|  |  |  | @GetMapping("/delete/{id}") | 
|---|
|  |  |  | @RequiresPermissions("business:bookings:delete") | 
|---|
|  |  |  | public ApiResponse deleteById(@PathVariable Integer id) { | 
|---|
|  |  |  | bookingsService.deleteById(id); | 
|---|
|  |  |  | bookingsService.deleteById(id,this.getLoginUser(null)); | 
|---|
|  |  |  | return ApiResponse.success(null); | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | 
|---|
|  |  |  | for (String id : idArray) { | 
|---|
|  |  |  | idList.add(Integer.valueOf(id)); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | bookingsService.deleteByIdInBatch(idList); | 
|---|
|  |  |  | bookingsService.deleteByIdInBatch(idList,this.getLoginUser(null)); | 
|---|
|  |  |  | return ApiResponse.success(null); | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | 
|---|
|  |  |  | @PostMapping("/updateById") | 
|---|
|  |  |  | @RequiresPermissions("business:bookings:update") | 
|---|
|  |  |  | public ApiResponse updateById(@RequestBody Bookings bookings) { | 
|---|
|  |  |  | LoginUserInfo user = getLoginUser(null); | 
|---|
|  |  |  | bookings.setCreator(user.getId()); | 
|---|
|  |  |  | bookings.setLoginUserInfo(getLoginUser(null)); | 
|---|
|  |  |  | bookingsService.updateById(bookings); | 
|---|
|  |  |  | return ApiResponse.success(null); | 
|---|
|  |  |  | } | 
|---|