diff --git a/artRepairFile.js b/artRepairFile.js index 6d2fdd7..7e3731c 100644 --- a/artRepairFile.js +++ b/artRepairFile.js @@ -9,6 +9,7 @@ import ArtRepairLog from './artRepairLog'; import { EditType } from '@airkoon/cellsys/cellsysUtil'; import { PublishStatus, PublishTarget } from '@airkoon/cellsys/cellsysEnum'; import ArtSystem from './artSystem'; +import RepairFileAudit from "./repairFileAudit"; class ArtRepairFile { constructor(params = {}) { @@ -171,6 +172,7 @@ class ArtRepairFile { editTask.addParam('_datetime', params.datetime); editTask.addParam('_links', params.links); editTask.addParam('_geometry', params.geometry); + editTask.addParam('_geometry_name', params.geometryName); return new Promise((resolve, reject) => { editTask .execute() @@ -258,6 +260,44 @@ class ArtRepairFile { pageInfo, }); } + //查询修复档案归档申请列表 + queryRepairFileArchive(params = {}) { + let { pageInfo, order, filters } = params; + let query = new Query(); + if (pageInfo) { + query.setCurrPage(pageInfo.currPage); + query.setPageSize(pageInfo.pageSize); + } + query.addFilter('repair_record_id', '=', this.id); //查询审核中的记录 + if (filters && filters.length > 0) { + filters.forEach((item) => { + query.addFilter(item['name'], item['operator'], item['value']); + }); + } + let queryTask = new QueryTask(artApi.viewRepairRecordArchiveReview, !!pageInfo); + return new Promise((resolve, reject) => { + queryTask + .execute(query) + .then((res) => { + if (pageInfo) { + if (res.data) { + res.data = res.data.map((item) => { + return new RepairFileAudit(item); + }); + resolve(res); + } + } else { + let resArr = res.map((item) => { + return new RepairFileAudit(item); + }); + resolve(resArr); + } + }) + .catch((err) => { + reject(err); + }); + }); + } } export default ArtRepairFile; diff --git a/artRepairLog.js b/artRepairLog.js index d392e06..3474a5e 100644 --- a/artRepairLog.js +++ b/artRepairLog.js @@ -68,6 +68,7 @@ class ArtRepairLog extends CellsysEvent { editTask.addParam('_datetime', params.datetime); editTask.addParam('_links', params.links); editTask.addParam('_geometry', params.geometry); + editTask.addParam('_geometry_name', params.geometryName); return new Promise((resolve, reject) => { editTask