部件接口相关上传

This commit is contained in:
小朱 2025-05-23 14:27:32 +08:00
parent 6effcfbba7
commit ed7049cfdc
2 changed files with 21 additions and 4 deletions

View File

@ -3,6 +3,7 @@ package com.cdzy.ebikemaintenance.mapper;
import com.mybatisflex.core.BaseMapper;
import com.cdzy.ebikemaintenance.model.pojo.EbikeBikeInfo;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import java.util.List;
@ -54,4 +55,20 @@ public interface EbikeBikeInfoMapper extends BaseMapper<EbikeBikeInfo> {
})
int vehicleLeaveWarehouse(@Param("bikeCodes") List<String> bikeCodes,
@Param("status") String status, @Param("reginId") String reginId);
@Select({
"SELECT COUNT(1) FROM ebike_bike_order a " +
"LEFT JOIN ebike_bike_info b ON a.bike_id = b.bike_id " +
"WHERE a.order_type = 1 " +
"AND a.handle_state = 0 " +
"AND a.is_deleted = 0 " +
"AND b.bike_code = #{bikeCode}"
})
int selectOrderCount(@Param("bikeCode") String bikeCode);
@Select({
"SELECT count(1) as sl FROM ebike_bike_faultreport where " +
"ifnull(handle_state,0)=0 AND bike_code = #{bikeCode}"
})
int selectReportCount(@Param("bikeCode") String bikeCode);
}

View File

@ -20,17 +20,17 @@ public class EbikeComponentController {
@Autowired
EbikeComponentService ebikeComponentService;
/**
* 中控设备部件入库暂存 stockInType 0或空 表示暂存1 表示入库
* 设备部件入库暂存 stockInType 0或空 表示暂存1 表示入库
* @param params
* @return
*/
@PostMapping("/ecuStorageSave")
@PostMapping("/componentInventoryEnterbound")
public JsonResult<?> ecuStorageSave(@RequestBody ReqComponentEnterRecordDto params) {
return ebikeComponentService.ecuStorageSave(params);
}
/**
* 设备部件作废 通用
* 设备部件入库作废 通用
* @param componentEnterRecordId
* @return
*/
@ -39,7 +39,7 @@ public class EbikeComponentController {
return ebikeComponentService.invalidateDevicePart(componentEnterRecordId);
}
/**
* 设备部件取消通用
* 设备部件入库取消通用
* @param componentEnterRecordId
* @return
*/