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