临时人员
This commit is contained in:
parent
405f974af1
commit
9531438411
|
|
@ -3,12 +3,15 @@ package com.bonus.app.controller;
|
|||
import com.bonus.app.entity.BoxEntity;
|
||||
import com.bonus.app.entity.BraceletEntity;
|
||||
import com.bonus.app.service.BraceletService;
|
||||
import com.bonus.common.core.utils.BASE64DecodedMultipartFile;
|
||||
import com.bonus.common.core.utils.UploadCheckUtils;
|
||||
import com.bonus.common.core.web.controller.BaseController;
|
||||
import com.bonus.common.core.web.domain.AjaxResult;
|
||||
import com.bonus.common.core.web.page.TableDataInfo;
|
||||
import com.bonus.common.log.annotation.SysLog;
|
||||
import com.bonus.common.log.enums.OperaType;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
|
@ -23,7 +26,7 @@ import java.util.List;
|
|||
@RestController
|
||||
@RequestMapping("/bracelet/")
|
||||
@Slf4j
|
||||
public class BraceletController extends BaseController{
|
||||
public class BraceletController extends BaseController {
|
||||
|
||||
|
||||
@Autowired
|
||||
|
|
@ -32,13 +35,14 @@ public class BraceletController extends BaseController{
|
|||
/**
|
||||
* 查询班组
|
||||
* 所领取的手环箱
|
||||
*
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("getBoxListById")
|
||||
@SysLog(title = "手环管理", businessType = OperaType.QUERY, module = "基础管理->手环管理", details = "查询手环列表")
|
||||
@SysLog(title = "手环管理", businessType = OperaType.QUERY, module = "基础管理->手环管理", details = "查询手环列表")
|
||||
public AjaxResult getBoxListById(BoxEntity entity) {
|
||||
return service.getBoxListById(entity);
|
||||
return service.getBoxListById(entity);
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -46,11 +50,12 @@ public class BraceletController extends BaseController{
|
|||
/**
|
||||
* 查询相关手环箱
|
||||
* 分配信息
|
||||
*
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("getBoxInfo")
|
||||
@SysLog(title = "手环管理", businessType = OperaType.QUERY, module = "基础管理->手环管理", details = "查询手环列表")
|
||||
@SysLog(title = "手环管理", businessType = OperaType.QUERY, module = "基础管理->手环管理", details = "查询手环列表")
|
||||
public AjaxResult getBoxInfo(BoxEntity entity) {
|
||||
return service.getBoxInfo(entity);
|
||||
}
|
||||
|
|
@ -58,11 +63,12 @@ public class BraceletController extends BaseController{
|
|||
/**
|
||||
* 发放手环查询接口
|
||||
* 分配信息
|
||||
*
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("getBoxToUser")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->手环管理", details = "查看手环发放信息")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->手环管理", details = "查看手环发放信息")
|
||||
public AjaxResult getBoxToUser(BoxEntity entity) {
|
||||
return service.getBoxToUser(entity);
|
||||
}
|
||||
|
|
@ -70,46 +76,55 @@ public class BraceletController extends BaseController{
|
|||
/**
|
||||
* 发放手环查询接口
|
||||
* 分配信息
|
||||
*
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("sendBoxBracelet")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->发放手环", details = "发放手环")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->发放手环", details = "发放手环")
|
||||
public AjaxResult sendBoxBracelet(@RequestBody BoxEntity entity) {
|
||||
return service.sendBoxBracelet(entity);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 归还手环箱查询
|
||||
*
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("getBoxBraceletUsed")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->归还手环", details = "查询手环使用信息")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->归还手环", details = "查询手环使用信息")
|
||||
public AjaxResult getBoxBraceletUsed(BoxEntity entity) {
|
||||
return service.getBoxBraceletUsed(entity);
|
||||
}
|
||||
|
||||
/**
|
||||
* 归还手环箱查询
|
||||
*
|
||||
* @param entity
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("returnBoxBracelet")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->归还手环", details = "归还手环")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->归还手环", details = "归还手环")
|
||||
public AjaxResult returnBoxBracelet(@RequestBody BoxEntity entity) {
|
||||
return service.returnBoxBracelet(entity);
|
||||
}
|
||||
|
||||
/**
|
||||
* 归还手环箱查询
|
||||
*
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("addLsUser")
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->新增临时人员", details = "新增临时人员")
|
||||
public AjaxResult addLsUser(@RequestParam(value = "file", required = false) MultipartFile file, String params) {
|
||||
return service.addLsUser(file,params);
|
||||
@SysLog(title = "app->手环管理", businessType = OperaType.QUERY, module = "app->手环管理->新增临时人员", details = "新增临时人员")
|
||||
public AjaxResult addLsUser(String file, String params) {
|
||||
MultipartFile fileData = BASE64DecodedMultipartFile.base64ToMultipart2(file);
|
||||
String result = UploadCheckUtils.uploadExcelVerify(fileData);
|
||||
if (StringUtils.isNotBlank(result)) {
|
||||
return AjaxResult.error(result);
|
||||
}
|
||||
return service.addLsUser(fileData, params);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue