taskCenterEvlNewFrom.vue 45 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047
  1. <template>
  2. <div class="taskEvalFrom">
  3. <el-dialog title="考评详情" v-model="dialogVisible" :fullscreen="true" :close-on-click-modal="false">
  4. <div class="startDetail">
  5. <p class="starttitleSty">单据信息:</p>
  6. <el-row class="danjuMsg">
  7. <el-col :span="6">
  8. <div class="danjuMsg_data">
  9. <span class="data_tit">业务编号:</span>
  10. <span>{{receiptMsg.code}}</span>
  11. </div>
  12. <div class="danjuMsg_data">
  13. <span class="data_tit">创建日期:</span>
  14. <span>{{receiptMsg.createDate}}</span>
  15. </div>
  16. </el-col>
  17. <el-col :span="6">
  18. <div class="danjuMsg_data">
  19. <span class="data_tit">业务简述:</span>
  20. <span>{{receiptMsg.des}}</span>
  21. </div>
  22. <div class="danjuMsg_data">
  23. <span class="data_tit">业务类别:</span>
  24. <span>{{receiptMsg.type}}</span>
  25. </div>
  26. </el-col>
  27. <el-col :span="6">
  28. <div class="danjuMsg_data">
  29. <span class="data_tit">流程状态:</span>
  30. <span>{{receiptMsg.stage}}</span>
  31. </div>
  32. <div class="danjuMsg_data">
  33. <span class="data_tit">年度:</span>
  34. <span>{{receiptMsg.year}}</span>
  35. </div>
  36. </el-col>
  37. <el-col :span="6">
  38. <div class="danjuMsg_data">
  39. <span class="data_tit">创建人:</span>
  40. <span>{{receiptMsg.createName}}</span>
  41. </div>
  42. <div class="danjuMsg_data">
  43. <span class="data_tit">单据状态:</span>
  44. <span>{{receiptMsg.recStage}}</span>
  45. </div>
  46. </el-col>
  47. </el-row>
  48. <div class="monthQuarterYear">
  49. <el-tabs v-model="activeName" class="tableMain" @tab-click="handleClick">
  50. <el-tab-pane v-for="it in stageData" :key="it.id" :label="it.stageName" :name="it.stageCode">
  51. <div class="detailsHeader">
  52. <div class="headerLeft">
  53. <el-tag v-for="tag in indicatorList" :key="tag.id" size="large" class="tagArr"
  54. effect="dark" :type="tag.id === isClickTagId ? '': 'info'" @click="handleShowPage(tag)">
  55. <span>{{ tag.indicator_name }}</span>
  56. </el-tag>
  57. </div>
  58. <div class="headerRight">
  59. <div class="seachFor">
  60. <el-input v-model="compNameSa" placeholder="请输入单位名称" @keyup.enter="getTableData(isClickTagId)"></el-input>
  61. <!-- <el-icon :size="20" color="#3B7AD1" @click="getTableData(isClickTagId)"><Search /></el-icon> -->
  62. </div>
  63. <!-- <div class="tableBtn add" @click="addTableDetail"
  64. v-if="(activeName === 'ZDZX' || activeName === 'GLSX') && indicatorList.length > 0">
  65. <img :src="addIcon" alt="">
  66. <span>新增</span>
  67. </div>
  68. <div class="tableBtn save" @click="saveAddDetail"
  69. v-if="(activeName === 'ZDZX' || activeName === 'GLSX') && indicatorList.length > 0">
  70. <img :src="saveIcon" alt="">
  71. <span>保存</span>
  72. </div> -->
  73. <div class="tableBtn save" @click="saveDetail">
  74. <img :src="saveIcon" alt="">
  75. <span>保存</span>
  76. </div>
  77. <div class="tableBtn import" @click="handleImport">
  78. <img :src="importIcon" alt="">
  79. <span>导入</span>
  80. </div>
  81. <div class="tableBtn export" @click="handleExport">
  82. <img :src="exportIcon" alt="">
  83. <span>导出</span>
  84. </div>
  85. </div>
  86. </div>
  87. <el-table :data="monthQuarterYearData" style="width: 100%" ref="monthQuarterYearTT"
  88. :row-class-name="tableRowClassName" :border="true" >
  89. <el-table-column type="index" label="排名" align="center"></el-table-column>
  90. <el-table-column label="考评单位" prop="organizationShortName" width="300">
  91. <template #default="scope">
  92. <el-select v-model="scope.row.organizationShortName" placeholder="请选择考评单位">
  93. <el-option
  94. v-for="item in organizationData"
  95. :key="item.organizationId"
  96. :label="item.organizationShortName"
  97. :value="item.organizationId">
  98. </el-option>
  99. </el-select>
  100. </template>
  101. </el-table-column>
  102. <el-table-column v-for="(it, index) in monthQuarterYearHeader" :key="index"
  103. :label="it.name" align="center">
  104. <el-table-column v-for="(iv, index) in it.children" :key="index" :label="iv.key"
  105. align="center" width="150" sortable :sort-method="(a,b)=>sortMethods(a,b,iv.code)">
  106. <template #default="scope">
  107. <template v-if="!scope.row['operation']">
  108. <el-select v-model="scope.row[iv.code]" class="selectSty" placeholder="请选择审核状态" v-if="scope.row['IS_LH_'+iv.code] === '3'">
  109. <el-option
  110. v-for="item in statusData"
  111. :key="item.id"
  112. :label="item.name"
  113. :value="item.id">
  114. </el-option>
  115. </el-select>
  116. <el-input v-model="scope.row[iv.code]" class="inputSty" v-else-if="scope.row['IS_LH_'+iv.code] === '2'"></el-input>
  117. <el-input-number v-model="scope.row[iv.code]" class="numberSty" :precision="2" :step="0.1" v-else />
  118. </template>
  119. <template v-else>
  120. <el-select v-model="scope.row[iv.code]" class="selectSty" placeholder="请选择审核状态" v-if="scope.row['IS_LH_'+iv.code] === '3'">
  121. <el-option
  122. v-for="item in statusData"
  123. :key="item.id"
  124. :label="item.name"
  125. :value="item.id">
  126. </el-option>
  127. </el-select>
  128. <span class="indicitem" v-if="iv.code === 'operation'" @click="changeDetail(scope.row)">详情</span>
  129. <span class="inputSty" v-else>{{scope.row[iv.code]}}</span>
  130. </template>
  131. </template>
  132. </el-table-column>
  133. </el-table-column>
  134. </el-table>
  135. </el-tab-pane>
  136. </el-tabs>
  137. <div class="tableSeach">
  138. <div class="seachType" v-for="item in titleMsgArr" :key="item.isName"
  139. :class="item.showClick? 'seachTypeCha':''" @click="changType(item)">
  140. <img :src="item.img" alt="" v-if="!item.showClick">
  141. <img :src="item.clickImg" alt="" v-else>
  142. <p :style="item.showClick? 'color: #3B7AD1' : ''">{{item.isName}}</p>
  143. </div>
  144. </div>
  145. </div>
  146. <div>
  147. <p class="starttitleSty">审批意见:</p>
  148. <el-input v-model="descMsg" :rows="3" type="textarea" placeholder="请输入审批意见"></el-input>
  149. </div>
  150. </div>
  151. <!-- <template #footer>
  152. <span class="dialog-footer">
  153. <el-button type="primary" @click="dialogVisible = false">取 消</el-button>
  154. </span>
  155. </template> -->
  156. <template #footer>
  157. <span class="dialog-footer">
  158. <el-button type="primary" @click="examineAndApprove('agree')">同 意</el-button>
  159. <el-button @click="examineAndApprove('reject')">拒 绝</el-button>
  160. </span>
  161. </template>
  162. </el-dialog>
  163. <el-dialog title="详情填报" v-model="detailVisible" :fullscreen="true" :close-on-click-modal="false">
  164. <div class="detailSeach">
  165. <div class="tableBtn add" @click="addTableDetailInfo">
  166. <img :src="addIcon" alt="">
  167. <span>新增</span>
  168. </div>
  169. <div class="tableBtn save" @click="saveAddDetailInfo">
  170. <img :src="saveIcon" alt="">
  171. <span>保存</span>
  172. </div>
  173. </div>
  174. <el-table :data="monthQuarterYearDetailData" style="width: 100%" ref="monthQuarterYearTT"
  175. :row-class-name="tableRowClassName" :border="true" >
  176. <el-table-column type="index" label="序号" align="center"></el-table-column>
  177. <el-table-column label="部门名称" prop="deptName" align="center" width="200"></el-table-column>
  178. <el-table-column v-for="(it, index) in monthQuarterYearDetailHeader" :key="index"
  179. :label="it.name" align="center">
  180. <el-table-column v-for="(iv, index) in it.children" :key="index" :label="iv.key" align="center">
  181. <template #default="scope">
  182. <el-input v-model="scope.row[iv.code]" class="inputSty" v-if="scope.row['IS_LH_'+iv.code] === '2'"></el-input>
  183. <el-input-number v-model="scope.row[iv.code]" class="numberSty" :precision="2" :step="0.1" v-else-if="scope.row['IS_LH_'+iv.code] === '1'" />
  184. </template>
  185. </el-table-column>
  186. </el-table-column>
  187. <el-table-column label="操作" width="100">
  188. <template #default="scope">
  189. <span class="indicitem" @click="removeDetailData(scope.row)">删除</span>
  190. </template>
  191. </el-table-column>
  192. </el-table>
  193. </el-dialog>
  194. <import-dailog ref="importPage" @successImport="successImport"></import-dailog>
  195. </div>
  196. </template>
  197. <script>
  198. import importDailog from '../importPage/importDailog.vue'
  199. import {apiGetEvaluationIndicatorList,apiGetgetEvaluationInfoDataList,apiGetbinsectionList, apiGetbinstageList,apiGetExportMsg,
  200. apiPostorganizationUpdateEvaluationInfo, apiPostorganizationUpdateAddEvaluationInfo,apiGetHeaderOrganizationEvaluation,
  201. apiPostIsdoAction, apiGetorganizationevaluationcommoninfo, apiPostsaveEvaluationCommonInfo, apiPostremoveEvaluationCommonInfo,
  202. apiGetOrganizationListAll} from '../../api/api'
  203. import * as XLSX from 'xlsx'
  204. import { saveAs } from 'file-saver'
  205. import * as XLSXD from 'xlsx-js-style'
  206. import sectionDef from '../../assets/benchmarkImg/sectionDef.png'
  207. import sectionCha from '../../assets/benchmarkImg/sectionCha.png'
  208. import addIcon from '../../assets/btnIcon/add.png'
  209. import saveIcon from '../../assets/btnIcon/save.png'
  210. import exportIcon from '../../assets/btnIcon/export.png'
  211. import importIcon from '../../assets/btnIcon/import.png'
  212. export default {
  213. components: {
  214. importDailog
  215. },
  216. data() {
  217. return {
  218. dialogVisible: false,
  219. detailVisible: false,
  220. activeName: '',
  221. monthQuarterYearData: [],
  222. monthQuarterYearHeader: [],
  223. monthQuarterYearDetailData: [],
  224. monthQuarterYearDetailHeader: [],
  225. indicatorList: [],
  226. isClickTagId: '',
  227. compNameSa: '',
  228. receiptMsg: {
  229. code: '',
  230. des: '',
  231. stage: '',
  232. createName: '',
  233. createDate: '',
  234. type: '',
  235. year: '',
  236. recStage: ''
  237. },
  238. rowMsg: {},
  239. moduleData: [],
  240. stageData: [],
  241. titleMsgArr: [],
  242. binSectionStr: '',
  243. addIcon: addIcon,
  244. saveIcon: saveIcon,
  245. exportIcon: exportIcon,
  246. importIcon: importIcon,
  247. addstageId: '',
  248. tastbizKey: '',
  249. taskDefKey: '',
  250. instanceChild: {},
  251. descMsg: '',
  252. statusData: [],
  253. organizationData: [],
  254. detailMsg: {}
  255. }
  256. },
  257. created() {
  258. this.statusData = [
  259. {
  260. name: '已确认',
  261. id: '1'
  262. },
  263. {
  264. name: '待确认',
  265. id: '0'
  266. },
  267. {
  268. name: '不合格',
  269. id: '-1'
  270. }
  271. ]
  272. },
  273. methods: {
  274. init(row, allData) {
  275. this.dialogVisible = true
  276. this.instanceChild = allData
  277. this.tastbizKey = allData.bizKey
  278. this.taskDefKey = allData.defKey
  279. this.getevalHeaderDetails(this.tastbizKey, this.taskDefKey)
  280. this.getModelData(this.taskDefKey)
  281. this.rowMsg = row
  282. },
  283. sortMethods(a, b, it) {
  284. if (a[it] < b[it]) {
  285. return -1
  286. }
  287. },
  288. //获取头部详情
  289. getevalHeaderDetails(id, defKey) {
  290. let that = this
  291. let params = {
  292. id: id
  293. }
  294. apiGetHeaderOrganizationEvaluation(params).then(datas =>{
  295. that.getDataMsg(defKey, datas)
  296. })
  297. },
  298. getDataMsg(types, datas) {
  299. if (datas && datas.data) {
  300. let item = datas.data
  301. this.receiptMsg = {
  302. code: types === 'dwkpmbqd'?item.responsibilityCode:item.organizationEvaluationCode,
  303. des: item.des,
  304. stage: item.stage,
  305. createName: item.createName,
  306. createDate: item.createTime,
  307. type: item.checkCycle === 'YDKP'?'月度考评':item.checkCycle === 'JDKP'?'季度考评':'年度考评',
  308. year: item.year,
  309. recStage: '有效'
  310. }
  311. }
  312. },
  313. // 获取业务属性
  314. getModelData(type) {
  315. let that = this
  316. that.titleMsgArr = []
  317. let params = {
  318. type: type === 'nddwkplc' ? '3' : '2'
  319. }
  320. apiGetbinsectionList(params).then(datas =>{
  321. if (datas && datas.data) {
  322. that.moduleData = datas.data
  323. that.moduleData.forEach(item =>{
  324. let obj = {
  325. id: item.id,
  326. isName: item.sectionName === '新能源(光电)' ? '新能源光电' : item.sectionName === '新能源(风电)' ? '新能源风电' : item.sectionName,
  327. isNameEn: item.sectionCode,
  328. showClick: false,
  329. isClass: 'sectionDef',
  330. img: sectionDef,
  331. isClassC: 'sectionCha',
  332. clickImg: sectionCha
  333. }
  334. that.titleMsgArr.push(obj)
  335. })
  336. that.titleMsgArr[0].showClick = true
  337. that.binSectionStr = that.titleMsgArr[0].id
  338. that.getStageData(type)
  339. that.getorganizationData(type)
  340. }
  341. })
  342. },
  343. //获取单位数据
  344. getorganizationData(type) {
  345. let that = this
  346. let params = {
  347. evaluationCycle: type ==='nddwkplc' ? 'NDKP': type ==='jddwkplc' ? 'JDKP' : 'YDKP',
  348. organizationType: 'DWKP',
  349. binSection: that.binSectionStr
  350. }
  351. apiGetOrganizationListAll(params).then(datas => {
  352. if (datas && datas.data) {
  353. that.organizationData = datas.data
  354. }
  355. })
  356. },
  357. //根据业务属性获取业务阶段
  358. getStageData(type) {
  359. let that = this
  360. let params = {
  361. type: '3'
  362. }
  363. apiGetbinstageList(params).then(datas =>{
  364. if (datas && datas.data) {
  365. that.stageData = datas.data
  366. that.activeName = datas.data[0].stageCode
  367. that.getTableHeaderData(datas.data[0].id)
  368. }
  369. })
  370. },
  371. //获取指标数据
  372. getTableHeaderData(id) {
  373. let that = this
  374. that.monthQuarterYearHeader = []
  375. that.monthQuarterYearData = []
  376. that.isClickTagId = ''
  377. let params = {
  378. organizationEvaluationId: that.tastbizKey,
  379. binSection: that.binSectionStr,
  380. binStage: id
  381. }
  382. apiGetEvaluationIndicatorList(params).then(datas =>{
  383. if (datas && datas.data) {
  384. that.indicatorList = datas.data
  385. if (datas.data.length>0) {
  386. that.isClickTagId = datas.data[0].id
  387. that.getTableData(that.isClickTagId)
  388. }
  389. }
  390. })
  391. },
  392. tableRowClassName(row, rowIndex) {
  393. if (!row.row.valueFlag) {
  394. return 'error-row'
  395. }
  396. },
  397. handleClick(val) {
  398. let stageId = ''
  399. this.stageData.forEach(it =>{
  400. if (it.stageCode === val.props.name) {
  401. stageId = it.id
  402. }
  403. })
  404. this.getTableHeaderData(stageId)
  405. },
  406. //获取表格数据
  407. getTableData(id) {
  408. let that = this
  409. let params = {
  410. organizationEvaluationId: that.tastbizKey,
  411. indicatorId: id,
  412. organizationShortName: that.compNameSa
  413. }
  414. apiGetgetEvaluationInfoDataList(params).then(datas =>{
  415. if (datas && datas.data) {
  416. if (datas.data.title) {
  417. let header = []
  418. for(let i in datas.data.title) {
  419. let obj = {
  420. name: i,
  421. children: datas.data.title[i]
  422. }
  423. header.push(obj)
  424. }
  425. that.monthQuarterYearHeader = header
  426. }
  427. that.monthQuarterYearData = datas.data.value
  428. }
  429. })
  430. },
  431. handleShowPage(tag) {
  432. this.isClickTagId = tag.id
  433. this.monthQuarterYearHeader = []
  434. this.monthQuarterYearData = []
  435. this.getTableData(tag.id)
  436. },
  437. changType(data) {
  438. this.titleMsgArr.forEach(it =>{
  439. it.showClick = false
  440. if (it.isName === data.isName) {
  441. it.showClick = true
  442. this.binSectionStr = it.id
  443. }
  444. })
  445. let stageId = ''
  446. this.stageData.forEach(it =>{
  447. if (it.stageCode === this.activeName) {
  448. stageId = it.id
  449. }
  450. })
  451. this.getTableHeaderData(stageId)
  452. this.getorganizationData(this.taskDefKey)
  453. },
  454. addTableDetail() {
  455. console.log('表头数据11====>>>>>>>', this.monthQuarterYearHeader)
  456. if (this.monthQuarterYearHeader.length>0) {
  457. let headerArr = []
  458. this.monthQuarterYearHeader.forEach(item =>{
  459. headerArr = headerArr.concat(item.children)
  460. })
  461. console.log('表头数据22====>>>>>>>', headerArr)
  462. this.addstageId = ''
  463. this.stageData.forEach(it =>{
  464. if (it.stageCode === this.activeName) {
  465. this.addstageId = it.id
  466. }
  467. })
  468. let obj = {
  469. isAdd: true,
  470. }
  471. headerArr.forEach(it =>{
  472. obj[it.code] = ''
  473. obj['IS_LH_'+it.code] = it.flag
  474. })
  475. this.monthQuarterYearData.unshift(obj)
  476. }
  477. console.log('表格数据====>>>>>>>', this.monthQuarterYearData)
  478. },
  479. saveAddDetail() {
  480. let that = this
  481. let addParams = []
  482. let saveParams = []
  483. let addObj = {
  484. organizationEvaluationId: that.tastbizKey,
  485. indicatorId: that.isClickTagId,
  486. binSection: that.binSectionStr,
  487. binStage: that.addstageId,
  488. optionMap: {}
  489. }
  490. that.monthQuarterYearData.forEach(it =>{
  491. if (it.isAdd) {
  492. addObj.organizationId = it.organizationShortName
  493. addObj.optionMap = it
  494. addParams.push(addObj)
  495. } else {
  496. saveParams.push(it)
  497. }
  498. })
  499. if (addParams.length > 0) {
  500. apiPostorganizationUpdateAddEvaluationInfo(addParams).then(datas =>{
  501. if (datas) {
  502. that.responseData(datas)
  503. }
  504. })
  505. }
  506. if (saveParams.length > 0) {
  507. apiPostorganizationUpdateEvaluationInfo(saveParams).then(datas =>{
  508. if (datas) {
  509. that.responseData(datas)
  510. }
  511. })
  512. }
  513. },
  514. // 返回数据
  515. responseData(datas) {
  516. if (datas.message === '成功') {
  517. this.$message({
  518. message: '考评详情信息保存成功',
  519. type: 'success'
  520. });
  521. } else {
  522. this.$message({
  523. message: datas.message,
  524. type: 'error'
  525. });
  526. }
  527. this.getTableData(this.isClickTagId)
  528. },
  529. saveDetail() {
  530. let that = this
  531. apiPostorganizationUpdateEvaluationInfo(that.monthQuarterYearData).then(datas =>{
  532. if (datas) {
  533. if (datas.message === '成功') {
  534. that.$message({
  535. message: '考评详情信息保存成功',
  536. type: 'success'
  537. });
  538. } else {
  539. that.$message({
  540. message: datas.message,
  541. type: 'error'
  542. });
  543. }
  544. that.getTableData(that.isClickTagId)
  545. }
  546. })
  547. },
  548. handleImport() {
  549. this.$refs.importPage.upload.title = "考评详情信息导入"
  550. this.$refs.importPage.upload.open = true
  551. this.$refs.importPage.upload.url = '/organization-evaluation-info/import-excel'
  552. },
  553. successImport(val) {
  554. that.getTableData(that.isClickTagId)
  555. },
  556. handleExport() {
  557. let that = this
  558. let url = 'organization-evaluation-info/download-excel'
  559. let params = {
  560. organizationEvaluationId: that.tastbizKey,
  561. indicatorId: that.isClickTagId
  562. }
  563. apiGetExportMsg(url,params).then(datas =>{
  564. let blob = new Blob([datas])
  565. saveAs(blob, '考评详情数据导出.xlsx')
  566. }).catch((r) => {
  567. console.error(r)
  568. })
  569. },
  570. examineAndApprove(type) {
  571. let that = this
  572. let actionCS = ''
  573. if (type === 'agree') {
  574. if (that.rowMsg.taskType === 'SIGN') {
  575. actionCS = 'signAgree'
  576. } else if (that.rowMsg.taskType === 'NORMAL') {
  577. actionCS = 'agree'
  578. }
  579. } else {
  580. // if (that.rowMsg.taskType === 'SIGN') {
  581. // actionCS = 'signReject'
  582. // } else if (that.rowMsg.taskType === 'NORMAL') {
  583. // }
  584. actionCS = 'reject'
  585. }
  586. let params = {
  587. taskId: that.rowMsg.id, //任务ID
  588. nodeId: that.rowMsg.nodeId, //节点ID
  589. action: actionCS, //固定值
  590. instanceId: that.rowMsg.instId, //流程实例ID
  591. opinion: that.descMsg, //审批意见
  592. iamCode: window.localStorage.getItem('code'), //认证后code值
  593. taskName: that.rowMsg.name,
  594. defKey: that.instanceChild.defKey,
  595. bizKey: that.instanceChild.bizKey
  596. }
  597. apiPostIsdoAction(params).then(datas =>{
  598. if (datas && datas.data) {
  599. if (datas.data.isOk) {
  600. that.$message({
  601. message: datas.data.data,
  602. type: 'success'
  603. })
  604. that.dialogVisible = false
  605. that.$emit('approveMsg', datas.data.isOk)
  606. } else {
  607. that.$message({
  608. message: datas.data.msg,
  609. type: 'error'
  610. })
  611. }
  612. }
  613. })
  614. },
  615. changeDetail(row) {
  616. this.detailVisible = true
  617. this.detailMsg = row
  618. this.changeDetailList(row)
  619. },
  620. changeDetailList(row) {
  621. let that = this
  622. let params = {
  623. organizationEvaluationId: that.tastbizKey,
  624. indicatorId: that.isClickTagId,
  625. organizationId: row.organizationId
  626. }
  627. apiGetorganizationevaluationcommoninfo(params).then(datas =>{
  628. if (datas && datas.data) {
  629. if (datas.data.title) {
  630. let header = []
  631. for(let i in datas.data.title) {
  632. let obj = {
  633. name: i,
  634. children: datas.data.title[i]
  635. }
  636. header.push(obj)
  637. }
  638. that.monthQuarterYearDetailHeader = header
  639. }
  640. that.monthQuarterYearDetailData = datas.data.value
  641. }
  642. })
  643. },
  644. addTableDetailInfo() {
  645. if (this.monthQuarterYearDetailHeader.length>0) {
  646. let headerArr = []
  647. this.monthQuarterYearDetailHeader.forEach(item =>{
  648. headerArr = headerArr.concat(item.children)
  649. })
  650. let obj = {
  651. isAdd: true,
  652. deptName: this.userMes.deptName
  653. }
  654. headerArr.forEach(it =>{
  655. if (it.flag === '1') {
  656. obj[it.code] = 0
  657. } else {
  658. obj[it.code] = ''
  659. }
  660. obj['IS_LH_'+it.code] = it.flag
  661. })
  662. this.monthQuarterYearDetailData.unshift(obj)
  663. }
  664. },
  665. saveAddDetailInfo() {
  666. let that = this
  667. let addParams = []
  668. that.monthQuarterYearDetailData.forEach(it =>{
  669. let addObj = {
  670. organizationEvaluationId: that.tastbizKey,
  671. indicatorId: that.isClickTagId,
  672. organizationId: that.detailMsg.organizationId,
  673. optionMap: it
  674. }
  675. addParams.push(addObj)
  676. })
  677. apiPostsaveEvaluationCommonInfo(addParams).then(datas =>{
  678. if (datas) {
  679. that.detailVisible = false
  680. that.responseData(datas)
  681. }
  682. })
  683. },
  684. removeDetailData(row) {
  685. this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
  686. confirmButtonText: '确定',
  687. cancelButtonText: '取消',
  688. type: 'warning'
  689. }).then(() => {
  690. let that = this
  691. let parArr = []
  692. for(let i in row) {
  693. if (i.indexOf('ID_') !== -1) {
  694. parArr.push(row[i])
  695. }
  696. }
  697. apiPostremoveEvaluationCommonInfo(parArr.join(',')).then(datas =>{
  698. if (datas) {
  699. that.changeDetailList(that.detailMsg)
  700. }
  701. })
  702. })
  703. }
  704. }
  705. }
  706. </script>
  707. <style lang="less">
  708. .taskEvalFrom{
  709. .el-overlay{
  710. .el-dialog{
  711. // margin-top: 7vh;
  712. .el-dialog__body{
  713. padding: 0 20px !important;
  714. .startDetail{
  715. .starttitleSty{
  716. font-size: 18px;
  717. font-family: Microsoft YaHei;
  718. font-weight: bold;
  719. color: #3B7AD1;
  720. // line-height: 12px;
  721. margin: 20px 0 20px 10px;
  722. }
  723. .danjuMsg{
  724. border: 1px solid #D6DBEA;
  725. padding: 10px 20px;
  726. border-radius: 10px;
  727. // margin-bottom: 20px;
  728. .danjuMsg_data{
  729. padding: 5px 0 10px 0;
  730. .data_tit{
  731. margin-right: 10px;
  732. font-weight: bold;
  733. font-size: 14px;
  734. font-family: Microsoft YaHei;
  735. color: #8991B0;
  736. }
  737. .data_tit_wd{
  738. display: inline-block;
  739. width: 90px;
  740. }
  741. .el-form-item--small{
  742. .el-input{
  743. height: 25px;
  744. width: 160px;
  745. }
  746. margin-bottom: 0;
  747. .el-input-number{
  748. height: 25px;
  749. .el-input-number__decrease, .el-input-number__increase{
  750. right: -39px;
  751. }
  752. }
  753. }
  754. }
  755. }
  756. .el-select, .el-input{
  757. width: 100%;
  758. }
  759. .monthQuarterYear{
  760. display: flex;
  761. width: 100%;
  762. margin-top: 20px;
  763. .tableMain{
  764. width: calc(100% - 100px);
  765. .el-tabs__header{
  766. .el-tabs__nav{
  767. .el-tabs__item{
  768. font-size: 18px;
  769. font-family: Microsoft YaHei;
  770. font-weight: bold;
  771. margin: 0 10px;
  772. color: #8991B0;
  773. }
  774. .is-active{
  775. font-size: 18px;
  776. font-family: Microsoft YaHei;
  777. font-weight: bold;
  778. color: #3B7AD1;
  779. margin: 0 10px;
  780. }
  781. }
  782. }
  783. .detailsHeader{
  784. width: 100%;
  785. display: flex;
  786. justify-content: space-between;
  787. .headerLeft{
  788. display: flex;
  789. width: 65%;
  790. overflow-x: auto;
  791. .tagArr {
  792. height: 33px;
  793. margin-right: 10px;
  794. cursor: pointer;
  795. margin-bottom: 10px;
  796. }
  797. .el-tag--dark {
  798. background-color: #184FB4;
  799. border: 1px solid #184FB4;
  800. }
  801. .el-tag--info {
  802. background-color: #E6EBF5;
  803. border: 1px solid #E6EBF5;
  804. color: #9DA5BE;
  805. .el-tag__close {
  806. color: #9DA5BE;
  807. }
  808. }
  809. }
  810. .headerRight{
  811. display: flex;
  812. justify-content: end;
  813. width: 35%;
  814. margin-bottom: 5px;
  815. .seachFor{
  816. display: flex;
  817. .el-input{
  818. height: 30px;
  819. .el-input__inner{
  820. height:30px;
  821. }
  822. .el-input__suffix{
  823. .el-select__caret{
  824. line-height:30px;
  825. }
  826. }
  827. }
  828. .el-icon{
  829. margin: 5px 10px 0 10px;
  830. cursor: pointer;
  831. }
  832. }
  833. .tableBtn {
  834. display: flex;
  835. height: 20px;
  836. margin: 5px 8px 0 8px;
  837. // width: 20%;
  838. width: fit-content;
  839. img{
  840. margin-right: 5px;
  841. margin-top: 1px;
  842. }
  843. span{
  844. display: inline-block;
  845. width: 35px;
  846. font-size: 14px;
  847. font-family: Microsoft YaHei;
  848. font-weight: 400;
  849. }
  850. }
  851. .add{
  852. cursor: pointer;
  853. span{
  854. color: #3B7AD1;
  855. }
  856. }
  857. .save{
  858. cursor: pointer;
  859. span{
  860. color: #50C14E;
  861. }
  862. }
  863. .import{
  864. cursor: pointer;
  865. span{
  866. color: #ce1e78;
  867. }
  868. }
  869. .export{
  870. cursor: pointer;
  871. span{
  872. color: #2baa8a;
  873. }
  874. }
  875. }
  876. }
  877. .el-table {
  878. .el-table__header-wrapper{
  879. .el-table__header{
  880. .el-table__cell {
  881. border-bottom: none !important;
  882. }
  883. thead{
  884. tr{
  885. th{
  886. .cell{
  887. line-height: 16px;
  888. }
  889. }
  890. }
  891. }
  892. }
  893. }
  894. .el-table__body-wrapper {
  895. height: 35vh !important;
  896. .el-scrollbar{
  897. .el-table__body{
  898. .error-row {
  899. --el-table-tr-bg-color: #fdecec;
  900. &:hover > td{
  901. background: #fdecec !important;
  902. }
  903. }
  904. tr{
  905. td{
  906. padding: 0;
  907. .cell{
  908. // background: #F6F7FA;
  909. line-height: 47px;
  910. height: 47px;
  911. }
  912. }
  913. td:hover {
  914. line-height: 45px;
  915. height: 45px;
  916. }
  917. }
  918. }
  919. }
  920. }
  921. .el-table--border .el-table__cell{
  922. border: none;
  923. }
  924. .el-table thead.is-group th.el-table__cell{
  925. background: transparent;
  926. }
  927. .tooltipCC {
  928. width: 180px;
  929. display: inline-block;
  930. overflow: hidden;
  931. text-overflow: ellipsis;
  932. white-space: nowrap;
  933. }
  934. }
  935. .el-pagination {
  936. margin-top: 20px;
  937. text-align: end;
  938. position: relative;
  939. }
  940. }
  941. .tableSeach{
  942. width: 88px;
  943. height: 50vh;
  944. margin-left: 10px;
  945. margin-top: 37px;
  946. border: 1px solid #D6DBEA;
  947. padding: 5px 0;
  948. border-radius: 5px;
  949. overflow-y: auto;
  950. .seachType{
  951. width: 78px;
  952. height: 78px;
  953. cursor: pointer;
  954. border-left: 3px solid transparent;
  955. img{
  956. margin-top: 17px;
  957. margin-left: 27px;
  958. }
  959. p{
  960. text-align: center;
  961. font-size: 14px;
  962. }
  963. }
  964. .seachTypeCha{
  965. background: #E6EBF5;
  966. cursor: pointer;
  967. border-left: 3px solid #3B7AD1;
  968. }
  969. }
  970. }
  971. }
  972. .detailSeach{
  973. display: flex;
  974. justify-content: flex-end;
  975. margin: 15px 0;
  976. .tableBtn {
  977. display: flex;
  978. height: 20px;
  979. margin: 5px 8px 0 8px;
  980. // width: 20%;
  981. width: fit-content;
  982. img{
  983. margin-right: 5px;
  984. margin-top: 1px;
  985. }
  986. span{
  987. display: inline-block;
  988. width: 35px;
  989. font-size: 14px;
  990. font-family: Microsoft YaHei;
  991. font-weight: 400;
  992. }
  993. }
  994. .add{
  995. cursor: pointer;
  996. span{
  997. color: #3B7AD1;
  998. }
  999. }
  1000. .save{
  1001. cursor: pointer;
  1002. span{
  1003. color: #50C14E;
  1004. }
  1005. }
  1006. }
  1007. .el-table {
  1008. .indicitem{
  1009. color: #409EFF;
  1010. font-size: 12px;
  1011. margin-right: 20px;
  1012. cursor:pointer;
  1013. &:hover{
  1014. text-decoration: underline;
  1015. }
  1016. }
  1017. }
  1018. }
  1019. .el-dialog__footer{
  1020. .dialog-footer{
  1021. display: flex;
  1022. justify-content: center;
  1023. .el-button{
  1024. width: 180px !important;
  1025. height: 40px !important;
  1026. }
  1027. }
  1028. }
  1029. }
  1030. }
  1031. }
  1032. </style>