|
@@ -73,7 +73,26 @@ object EquipScanTaskQueryService : SObjectService<EquipScanTaskQuery>(SMybatisDa
|
|
|
return pageQuery
|
|
|
} // Fun
|
|
|
|
|
|
-
|
|
|
+ fun pageQueryTwo(request: SQueryRequest): SQueryResponse<EquipScanTaskQuery> {
|
|
|
+ val projectId = SPageContext.getHeader("projectId").toString()
|
|
|
+ val withFilterList = ArrayList<SFilter>()
|
|
|
+ withFilterList.add(SFilter.eq("projectId", SPageContext.getHeader("projectId").toString()))
|
|
|
+ val pageQuery = pageQuery(request, withFilterList)
|
|
|
+ if (!pageQuery.content.isNullOrEmpty()&&pageQuery.content!!.size>0){
|
|
|
+ for (content in pageQuery.content!!){
|
|
|
+ val exec = select(SFilter.eq("parentId", content.equipId!!),SFilter.eq("taskParentId", content.id!!)).exec()
|
|
|
+ if (exec.size>0){
|
|
|
+ content.component = exec
|
|
|
+ }
|
|
|
+ val defClass =
|
|
|
+ defClassService.select(SFilter.eq("projectId", projectId), SFilter.eq("code", content.classCode!!)).entity()
|
|
|
+ if (defClass!=null) {
|
|
|
+ content.equipCategory = defClass
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return pageQuery
|
|
|
+ } // Fun
|
|
|
|
|
|
|
|
|
|