|
@@ -55,16 +55,19 @@ public class RepairCustomerService {
|
|
|
if(repair.getStatus() != 3){
|
|
|
throw new BusinessException(ResultCode.REPAIR_STATUS_NOT_EXITS);
|
|
|
}
|
|
|
- Integer repairStatus = 5;
|
|
|
- String remark = "确认维修";
|
|
|
- if(param.getConfirm() == 1 ){
|
|
|
- repairStatus = 4;
|
|
|
- remark = "取消维修";
|
|
|
- }
|
|
|
- if(repairStatus == 5){
|
|
|
+
|
|
|
+ if(param.getConfirm() == 0){
|
|
|
priceListService.updateStatusByRepairId(repair.getRepairId());
|
|
|
+ repairLogService.saveBySysUser(null,repair.getRepairId(),5,"确认维修");
|
|
|
+ }
|
|
|
+ if(param.getConfirm() == 1) {
|
|
|
+ repairLogService.saveBySysUser(null,repair.getRepairId(),4,"取消维修");
|
|
|
+ //存在确认过的报价单,返回维修中
|
|
|
+ List<PriceList> priceLists = priceListService.getByRepairIdAndStatus(repair.getRepairId(),1);
|
|
|
+ if(priceLists !=null && priceLists.size() >0){
|
|
|
+ repairService.updateRepairStatus(repair.getRepairId(),7);
|
|
|
+ }
|
|
|
}
|
|
|
- repairLogService.saveBySysUser(null,repair.getRepairId(),repairStatus,remark);
|
|
|
}
|
|
|
|
|
|
public void comment(RepairParam param) {
|