|
|
@ -6,6 +6,7 @@ import com.win.module.system.api.user.dto.AdminUserRespDTO; |
|
|
|
import com.win.module.wms.convert.inventorymoveJob.InventorymoveJobDetailConvert; |
|
|
|
import com.win.module.wms.dal.dataobject.inventorymoveJob.InventorymoveJobDetailDO; |
|
|
|
import com.win.module.wms.service.inventorymoveJob.InventorymoveJobDetailService; |
|
|
|
import jodd.util.StringUtil; |
|
|
|
import org.springframework.web.bind.annotation.*; |
|
|
|
import javax.annotation.Resource; |
|
|
|
import org.springframework.validation.annotation.Validated; |
|
|
@ -147,4 +148,19 @@ public class InventorymoveJobMainController { |
|
|
|
return success(result); |
|
|
|
} |
|
|
|
|
|
|
|
@PostMapping("/getCountByStatus") |
|
|
|
@Operation(summary = "APP获得库存转移任务数量根据任务状态") |
|
|
|
@Parameter(name = "types", description = "类型数组", required = false, example = "\"types\":[\"1\",\"2\"]") |
|
|
|
@PreAuthorize("@ss.hasPermission('wms:inventorymove-job-main:query')") |
|
|
|
public CommonResult<Map<String,Integer>> getCountByStatus(@RequestBody Map<String, List<String>> map) { |
|
|
|
List<String> list = new ArrayList<>(); |
|
|
|
if(map==null||map.get("types")==null|| StringUtil.isEmpty(map.get("types").toString())){ |
|
|
|
list.add("1");//默认不传为执行中的
|
|
|
|
}else{ |
|
|
|
list = map.get("types"); |
|
|
|
} |
|
|
|
Map<String, Integer> countByStatus = inventorymoveJobMainService.getCountByStatus(list); |
|
|
|
return success(countByStatus); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|