package org.dromara.eims.controller;
|
|
import cn.dev33.satoken.annotation.SaCheckPermission;
|
import lombok.RequiredArgsConstructor;
|
import org.dromara.common.core.domain.R;
|
import org.dromara.common.core.validate.AddGroup;
|
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
import org.dromara.common.log.annotation.Log;
|
import org.dromara.common.log.enums.BusinessType;
|
import org.dromara.common.web.core.BaseController;
|
import org.dromara.eims.domain.bo.EimsRepairResBo;
|
import org.dromara.eims.domain.vo.EimsRepairResVo;
|
import org.dromara.eims.service.IEimsRepairResService;
|
import org.dromara.eims.service.IMobileService;
|
import org.springframework.validation.annotation.Validated;
|
import org.springframework.web.bind.annotation.PostMapping;
|
import org.springframework.web.bind.annotation.RequestBody;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RestController;
|
|
/**
|
* 移动端controller
|
* 主要用于一些特殊操作: 如快捷接单维修(一次请求多个接口,为保证原子性新增的接口)
|
*/
|
@Validated
|
@RequiredArgsConstructor
|
@RestController
|
@RequestMapping("/eims/mobile")
|
public class MobileController extends BaseController {
|
private final IMobileService mobileService;
|
|
@Log(title = "接单维修-组合api", businessType = BusinessType.OTHER)
|
@RepeatSubmit()
|
@PostMapping("receiveOrderRepair")
|
public R<EimsRepairResVo> receiveOrderRepair(@Validated(AddGroup.class) @RequestBody EimsRepairResBo bo) {
|
EimsRepairResVo eimsRepairResVo = mobileService.receiveOrderRepair(bo);
|
return R.ok(eimsRepairResVo);
|
}
|
}
|