taskApplicationFrom.vue 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877
  1. <template>
  2. <div class="applicationFrom">
  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.deptName}}</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.declarationLevel}}级</span>
  21. </div>
  22. <div class="danjuMsg_data">
  23. <span class="data_tit">申报年度:</span>
  24. <span>{{receiptMsg.year}}年</span>
  25. </div>
  26. <!-- <div class="danjuMsg_data">
  27. <span class="data_tit">申报领导:</span>
  28. <span>{{receiptMsg.deptLeaderName}}</span>
  29. </div> -->
  30. </el-col>
  31. <el-col :span="6">
  32. <div class="danjuMsg_data">
  33. <span class="data_tit">流程状态:</span>
  34. <span>{{receiptMsg.stage}}</span>
  35. </div>
  36. <div class="danjuMsg_data">
  37. <span class="data_tit">申报月份:</span>
  38. <span>{{receiptMsg.month}}月</span>
  39. </div>
  40. </el-col>
  41. <el-col :span="6">
  42. <div class="danjuMsg_data">
  43. <span class="data_tit">创建日期:</span>
  44. <span>{{receiptMsg.createDate}}</span>
  45. </div>
  46. </el-col>
  47. <el-col :span="6">
  48. <div class="danjuMsgSelect">
  49. <span class="data_tit">评定等级:</span>
  50. <span v-if="userMes.deptId !== '23031009'">{{receiptMsg.ratingGrade}}</span>
  51. <el-select v-model="receiptMsg.ratingGrade" placeholder="请选择评定等级" @change="changeratingGrade" v-else>
  52. <el-option
  53. v-for="item in ratingGradeOption"
  54. :key="item.value"
  55. :label="item.label"
  56. :value="item.value">
  57. </el-option>
  58. </el-select>
  59. </div>
  60. </el-col>
  61. <el-col :span="18">
  62. <div class="danjuMsgSelect">
  63. <span class="data_tit">申报简述:</span>
  64. <span v-if="userMes.deptId !== '23031009'">{{receiptMsg.des}}</span>
  65. <el-input v-model="receiptMsg.des" :rows="1" type="textarea" @blur="blurDes" v-else
  66. placeholder="请输入申报简述"></el-input>
  67. </div>
  68. </el-col>
  69. </el-row>
  70. <el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick">
  71. <el-tab-pane label="员工月度考核系数" name="first">
  72. <div class="detaTableBtns">
  73. <div class="tableBtn add" @click="addTableDetail">
  74. <img :src="addIcon" alt="">
  75. <span>新增</span>
  76. </div>
  77. <div class="tableBtn save" @click="saveDetail">
  78. <img :src="saveIcon" alt="">
  79. <span>保存</span>
  80. </div>
  81. <div class="tableBtn delete" @click="handleDelete">
  82. <img :src="deleteIcon" alt="">
  83. <span>删除</span>
  84. </div>
  85. <div class="tableBtn import" @click="handleImport">
  86. <img :src="importIcon" alt="">
  87. <span>导入</span>
  88. </div>
  89. <div class="tableBtn export" @click="handleExport">
  90. <img :src="exportIcon" alt="">
  91. <span>导出</span>
  92. </div>
  93. </div>
  94. <el-table :data="quantifiedList.slice((pageLeft.currentPage-1)*pageLeft.pagesize, pageLeft.currentPage*pageLeft.pagesize)"
  95. style="width: 100%" @select="rowClick" @select-all="rowClick">
  96. <el-table-column type="selection" label="操作" align="center"></el-table-column>
  97. <el-table-column label="序号" type="index" width="80" />
  98. <el-table-column label="人员编号" prop="employeeNo">
  99. <template #default="scope">
  100. <el-input v-model="scope.row.employeeNo" @blur="employeeNoInputBlur(scope.row.employeeNo, scope.row)" />
  101. </template>
  102. </el-table-column>
  103. <el-table-column label="人员" prop="deptName">
  104. <template #default="scope">
  105. <!-- <el-select v-model="scope.row.employeeId" placeholder="请选择人员">
  106. <el-option
  107. v-for="item in deptLeaderOptionDet"
  108. :key="item.id"
  109. :label="item.name"
  110. :value="item.id">
  111. </el-option>
  112. </el-select> -->
  113. <span>{{scope.row.employeeName}}</span>
  114. </template>
  115. </el-table-column>
  116. <el-table-column label="建议值" v-if="showMessage">
  117. <template #default="scope">
  118. <el-input-number v-model="scope.row.suggestedValue" :precision="2" :step="0.1" :min="0" />
  119. </template>
  120. </el-table-column>
  121. <el-table-column label="排序" >
  122. <template #default="scope">
  123. <el-input-number v-model="scope.row.serialNumber" :min="1" />
  124. </template>
  125. </el-table-column>
  126. <el-table-column label="操作" width="120">
  127. <template #default="scope">
  128. <p class="indicitem" @click="deleteRowFn(scope.row, scope.$index)">删除</p>
  129. </template>
  130. </el-table-column>
  131. </el-table>
  132. <el-pagination
  133. @current-change="handleCurrentChangeLeft"
  134. :current-page="pageLeft.currentPage"
  135. :page-size="pageLeft.pagesize"
  136. layout="total, prev, pager, next, jumper"
  137. :total="pageLeft.total">
  138. </el-pagination>
  139. </el-tab-pane>
  140. <el-tab-pane label="本月主要工作完成情况" name="second">
  141. <div class="detaTableBtns">
  142. <div class="tableBtn add" @click="addSecondWork">
  143. <img :src="addIcon" alt="">
  144. <span>新增</span>
  145. </div>
  146. <div class="tableBtn save" @click="saveSecondWork">
  147. <img :src="saveIcon" alt="">
  148. <span>保存</span>
  149. </div>
  150. <div class="tableBtn delete" @click="handleSecondWork">
  151. <img :src="deleteIcon" alt="">
  152. <span>删除</span>
  153. </div>
  154. </div>
  155. <el-table :data="secondWorkSituation.slice((pageRight.currentPage-1)*pageRight.pagesize, pageRight.currentPage*pageRight.pagesize)"
  156. style="width: 100%" @select="rowSituationClick" @select-all="rowSituationClick">
  157. <el-table-column type="selection" label="操作" align="center"></el-table-column>
  158. <el-table-column label="序号" type="index" width="80" />
  159. <el-table-column label="工作内容">
  160. <template #default="scope">
  161. <el-input v-model="scope.row.jobContent" :rows="1" type="textarea" />
  162. </template>
  163. </el-table-column>
  164. <el-table-column label="完成情况">
  165. <template #default="scope">
  166. <el-input v-model="scope.row.completionStatus" />
  167. </template>
  168. </el-table-column>
  169. <el-table-column label="相关处室" width="200">
  170. <template #default="scope">
  171. <el-input v-model="scope.row.relatedOffice" />
  172. </template>
  173. </el-table-column>
  174. <el-table-column label="经办人" width="200">
  175. <template #default="scope">
  176. <el-input v-model="scope.row.handlePeopleName" />
  177. </template>
  178. </el-table-column>
  179. <el-table-column label="排序" >
  180. <template #default="scope">
  181. <el-input-number v-model="scope.row.serialNumber" :min="1" />
  182. </template>
  183. </el-table-column>
  184. </el-table>
  185. <el-pagination
  186. @current-change="handleCurrentChangeRight"
  187. :current-page="pageRight.currentPage"
  188. :page-size="pageRight.pagesize"
  189. layout="total, prev, pager, next, jumper"
  190. :total="pageRight.total">
  191. </el-pagination>
  192. </el-tab-pane>
  193. </el-tabs>
  194. <div>
  195. <p class="starttitleSty">审批意见:</p>
  196. <el-input v-model="descMsg" :rows="3" type="textarea" placeholder="请输入审批意见"></el-input>
  197. </div>
  198. </div>
  199. <template #footer>
  200. <span class="dialog-footer">
  201. <el-button type="primary" @click="examineAndApprove('agree')">同 意</el-button>
  202. <el-button @click="examineAndApprove('reject')">拒 绝</el-button>
  203. </span>
  204. </template>
  205. </el-dialog>
  206. <import-dailog ref="importPage" @successImport="successImport" @importLoading="importLoading"></import-dailog>
  207. </div>
  208. </template>
  209. <script>
  210. import importDailog from '../importPage/importDailog.vue'
  211. import {apiPostevaluationdeptadDetails,apiGetevaluationdeptadUpdate, apiGetevaluationdeptadDelete,apiPostIsdoAction,apideptAdmodify,
  212. apiPostevaluationdeptadDetailsHead, apiGetuserPageList, apiGetUserPostList, apiGetevaluationdeptadUpdateComplete,
  213. apiGetevaluationdeptadDeleteComplete} from '../../api/api'
  214. import ExcelJS from 'exceljs'
  215. import fileSave from 'file-saver'
  216. import addIcon from '../../assets/btnIcon/add.png'
  217. import saveIcon from '../../assets/btnIcon/save.png'
  218. import editIcon from '../../assets/btnIcon/edit.png'
  219. import deleteIcon from '../../assets/btnIcon/delete.png'
  220. import exportIcon from '../../assets/btnIcon/export.png'
  221. import importIcon from '../../assets/btnIcon/import.png'
  222. export default {
  223. components: {
  224. importDailog
  225. },
  226. data() {
  227. return {
  228. dialogVisible: false,
  229. activeName: 'first',
  230. quantifiedList: [],
  231. secondWorkSituation: [],
  232. changeDateSelect: [],
  233. descMsg: '',
  234. receiptMsg: {
  235. code: '',
  236. des: '',
  237. stage: '',
  238. createName: '',
  239. createDate: '',
  240. type: '',
  241. year: '',
  242. month: '',
  243. recStage: ''
  244. },
  245. addIcon: addIcon,
  246. saveIcon: saveIcon,
  247. editIcon: editIcon,
  248. deleteIcon: deleteIcon,
  249. exportIcon: exportIcon,
  250. importIcon: importIcon,
  251. rowMsg: {},
  252. orgruleData: [],
  253. indicItemoptions: [],
  254. sectionNameArr: [],
  255. deptNameArr: [],
  256. pageLeft:{
  257. pagesize: 15,
  258. currentPage: 1,
  259. total: 0
  260. },
  261. pageRight:{
  262. pagesize: 15,
  263. currentPage: 1,
  264. total: 0
  265. },
  266. deptLeaderOptionDet: [],
  267. ratingGradeOption: [],
  268. userMes: {},
  269. instanceChild: {},
  270. keyId: '',
  271. showMessage: false,
  272. changeSituationSelect: [],
  273. }
  274. },
  275. created() {
  276. this.ratingGradeOption = [
  277. {
  278. label: 'A',
  279. value: 'A'
  280. },
  281. {
  282. label: 'B',
  283. value: 'B'
  284. },
  285. {
  286. label: 'C',
  287. value: 'C'
  288. },
  289. {
  290. label: 'D',
  291. value: 'D'
  292. }
  293. ]
  294. },
  295. methods: {
  296. init(row, id, allData) {
  297. this.dialogVisible = true
  298. this.userMes = JSON.parse(window.sessionStorage.getItem('user'))
  299. this.activeName = 'first'
  300. this.instanceChild = allData
  301. this.getUserPostList()
  302. this.getDetails(id)
  303. this.getDetailsHeader(id)
  304. this.keyId = id
  305. this.changeDeptLead(row.deptId)
  306. this.rowMsg = row
  307. },
  308. // 根据部门查询人员
  309. changeDeptLead(val) {
  310. let that = this
  311. let params = {
  312. current: 1,
  313. size: 500,
  314. orgId: val
  315. }
  316. apiGetuserPageList(params).then(datas =>{
  317. if (datas && datas.data) {
  318. that.deptLeaderOptionDet = datas.data.records
  319. }
  320. })
  321. },
  322. getUserPostList() {
  323. let that = this
  324. that.showMessage = false
  325. if (that.userMes.deptId === '23031009') {
  326. that.showMessage = true
  327. } else {
  328. let params = {
  329. userId: that.userMes.id,
  330. current: 1,
  331. size: 10
  332. }
  333. apiGetUserPostList(params).then(datas =>{
  334. if (datas.data && datas.data.records.length>0) {
  335. datas.data.records.forEach(it =>{
  336. if (it.posName === '主任' || it.posName === '副主任') {
  337. that.showMessage = true
  338. }
  339. })
  340. }
  341. })
  342. }
  343. },
  344. rowClick(selection, row) {
  345. this.changeDateSelect = selection
  346. },
  347. rowSituationClick(selection, row) {
  348. this.changeSituationSelect = selection
  349. },
  350. changeratingGrade(val) {
  351. this.modeifyDetail('level', val)
  352. },
  353. blurDes() {
  354. this.modeifyDetail('des', this.receiptMsg.des)
  355. },
  356. // 修改申报详情头信息
  357. modeifyDetail(type, val) {
  358. let that = this
  359. let params = {
  360. id: that.keyId
  361. }
  362. if (type === 'level') {
  363. params.ratingGrade = val
  364. } else {
  365. params.des = val
  366. }
  367. apideptAdmodify(params).then(datas =>{
  368. if (datas.success) {
  369. that.$message({
  370. message: '修改成功',
  371. type: 'success'
  372. });
  373. } else {
  374. that.$message({
  375. message: '修改失败',
  376. type: 'error'
  377. });
  378. }
  379. })
  380. },
  381. handleClick(val) {
  382. this.changeDateSelect = []
  383. this.changeSituationSelect = []
  384. this.activeName = val.props.name
  385. },
  386. handleCurrentChangeLeft(val) {
  387. this.pageLeft.currentPage = val
  388. },
  389. handleCurrentChangeRight(val) {
  390. this.pageRight.currentPage = val
  391. },
  392. //获取详情头数据
  393. getDetailsHeader(id) {
  394. let that = this
  395. apiPostevaluationdeptadDetailsHead(id).then(datas =>{
  396. if (datas && datas.data) {
  397. let row = datas.data
  398. that.receiptMsg = {
  399. code: row.orderNumber,
  400. des: row.declarationReason,
  401. stage: row.stage,
  402. deptName: row.deptName,
  403. deptLeaderName: row.deptLeaderName,
  404. declarationLevel: row.declarationLevel,
  405. ratingGrade: row.ratingGrade,
  406. createName: row.createName,
  407. createDate: row.createTime,
  408. type: row.checkCycle === 'YDKP'?'月度考评':row.checkCycle === 'JDKP'?'季度考评':'年度考评',
  409. year: row.annual,
  410. month: row.declarationMonth,
  411. recStage: '有效'
  412. }
  413. }
  414. })
  415. },
  416. //获取详情
  417. getDetails(id) {
  418. let that = this
  419. that.quantifiedList = []
  420. that.secondWorkSituation = []
  421. apiPostevaluationdeptadDetails(id).then(datas =>{
  422. if (datas && datas.data) {
  423. if (datas.data['ygydkhxs'][0]) {
  424. datas.data['ygydkhxs'][0].forEach(it =>{
  425. it.serialNumber = it.serialNumber.toString()
  426. })
  427. that.quantifiedList = datas.data['ygydkhxs'][0]
  428. that.pageLeft.total = datas.data['ygydkhxs'][0].length
  429. }
  430. if (datas.data['byzygzwcqk'][0]) {
  431. that.secondWorkSituation = datas.data['byzygzwcqk'][0]
  432. that.pageRight.total = datas.data['byzygzwcqk'][0].length
  433. }
  434. }
  435. })
  436. },
  437. employeeNoInputBlur(val, row) {
  438. this.deptLeaderOptionDet.forEach(it =>{
  439. if (val === it.no) {
  440. row.employeeId = it.id
  441. }
  442. })
  443. },
  444. addTableDetail() {
  445. this.pageLeft.currentPage = 1
  446. let obj = {
  447. showInput: true,
  448. businessPlanId: this.keyId,
  449. employeeId: '',
  450. employeeNo: '',
  451. suggestedValue: 1.00,
  452. serialNumber: 0
  453. }
  454. this.quantifiedList.unshift(obj)
  455. },
  456. saveDetail() {
  457. let that = this
  458. let params = []
  459. that.quantifiedList.forEach(item =>{
  460. // let emName = ''
  461. // let emNo = ''
  462. // that.deptLeaderOptionDet.forEach(it =>{
  463. // if (item.employeeId === it.id) {
  464. // emName = it.name
  465. // emNo = it.no
  466. // }
  467. // })
  468. let obj = {
  469. assessmentDeclarationId: that.keyId,
  470. employeeId: item.employeeId,
  471. employeeName: item.employeeName,
  472. employeeNo: item.employeeNo,
  473. suggestedValue: Number(item.suggestedValue).toFixed(2),
  474. serialNumber: item.serialNumber
  475. }
  476. if (!item.showInput) {
  477. obj.id = item.id
  478. }
  479. params.push(obj)
  480. })
  481. apiGetevaluationdeptadUpdate(params).then(datas =>{
  482. if (datas) {
  483. if (datas.success) {
  484. that.$message({
  485. message: '保存成功',
  486. type: 'success'
  487. });
  488. that.getDetails(that.keyId)
  489. } else {
  490. that.$message({
  491. message: datas.data,
  492. type: 'error'
  493. })
  494. }
  495. }
  496. })
  497. },
  498. deleteRowFn(row) {
  499. let that = this
  500. this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
  501. confirmButtonText: '确定',
  502. cancelButtonText: '取消',
  503. type: 'warning'
  504. }).then(() => {
  505. if (!row.id) {
  506. that.quantifiedList.splice(index, 1)
  507. } else {
  508. apiGetevaluationdeptadDelete(row.id).then(datas =>{
  509. if (datas) {
  510. that.$message({
  511. type: 'success',
  512. message: '删除成功!'
  513. });
  514. that.getDetails(that.keyId)
  515. }
  516. })
  517. }
  518. })
  519. },
  520. handleImport() {
  521. this.$refs.importPage.upload.title = "绩效结果考核申报导入"
  522. this.$refs.importPage.upload.open = true
  523. this.$refs.importPage.upload.url = '/evaluation-dept-ad/import'
  524. },
  525. successImport(val) {
  526. this.$message({
  527. type: 'success',
  528. message: val.message
  529. });
  530. this.getDetails(this.keyId)
  531. },
  532. handleExport() {
  533. let data = this.quantifiedList //接口返回数据
  534. const workbook = new ExcelJS.Workbook()
  535. const worksheet = workbook.addWorksheet('Sheet1')
  536. //根据数据自己调整
  537. let colums = []
  538. colums = [
  539. // { header: 'ID', key: 'id', width: 26, hidden: true },
  540. { header: '申报ID', key: 'assessmentDeclarationId', width: 26, hidden: true },
  541. { header: '人员编号', key: 'employeeNo', width: 26 },
  542. // { header: '员工ID', key: 'employeeId', width: 26 },
  543. { header: '员工名称', key: 'employeeName', width: 26 },
  544. { header: '建议值', key: 'suggestedValue', width: 26 },
  545. { header: '排序', key: 'serialNumber', width: 26 },
  546. ]
  547. worksheet.columns = colums
  548. worksheet.getRow(1).font = {
  549. size: 12,
  550. bold: true
  551. }
  552. worksheet.addRows(data)
  553. workbook.xlsx.writeBuffer().then(buffer => {
  554. //这里为type
  555. const blob = new Blob([buffer], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8' })
  556. fileSave(blob, `绩效结果考核申报数据导出.xlsx`)
  557. })
  558. },
  559. examineAndApprove(type) {
  560. let that = this
  561. let actionCS = ''
  562. if (type === 'agree') {
  563. if (that.rowMsg.taskType === 'SIGN') {
  564. actionCS = 'signAgree'
  565. } else if (that.rowMsg.taskType === 'NORMAL') {
  566. actionCS = 'agree'
  567. }
  568. } else {
  569. if (that.rowMsg.taskType === 'SIGN') {
  570. actionCS = 'signReject'
  571. } else if (that.rowMsg.taskType === 'NORMAL') {
  572. actionCS = 'reject'
  573. }
  574. }
  575. let params = {
  576. taskId: that.rowMsg.id, //任务ID
  577. nodeId: that.rowMsg.nodeId, //节点ID
  578. action: actionCS, //固定值
  579. instanceId: that.rowMsg.instId, //流程实例ID
  580. opinion: that.descMsg, //审批意见
  581. iamCode: window.localStorage.getItem('code'), //认证后code值
  582. taskName: that.rowMsg.name,
  583. defKey: that.instanceChild.defKey,
  584. bizKey: that.instanceChild.bizKey
  585. }
  586. apiPostIsdoAction(params).then(datas =>{
  587. if (datas && datas.data) {
  588. if (datas.data.isOk) {
  589. that.$message({
  590. message: datas.data.data,
  591. type: 'success'
  592. })
  593. that.dialogVisible = false
  594. that.$emit('approveMsg', datas.data.isOk)
  595. } else {
  596. that.$message({
  597. message: datas.data.msg,
  598. type: 'error'
  599. })
  600. }
  601. }
  602. })
  603. },
  604. addSecondWork() {
  605. this.pageRight.currentPage = 1
  606. let obj = {
  607. showInput: true,
  608. assessmentDeclarationId: this.keyId,
  609. jobContent: '',
  610. completionStatus: '',
  611. relatedOffice: '',
  612. handlePeopleName: this.userMes.name,
  613. serialNumber: 0
  614. }
  615. this.secondWorkSituation.unshift(obj)
  616. },
  617. saveSecondWork() {
  618. let that = this
  619. let params = []
  620. that.secondWorkSituation.forEach(item =>{
  621. let obj = {
  622. assessmentDeclarationId: that.keyId,
  623. jobContent: item.jobContent,
  624. completionStatus: item.completionStatus,
  625. relatedOffice: item.relatedOffice,
  626. handlePeopleName: item.handlePeopleName,
  627. serialNumber: item.serialNumber
  628. }
  629. if (!item.showInput) {
  630. obj.id = item.id
  631. }
  632. params.push(obj)
  633. })
  634. apiGetevaluationdeptadUpdateComplete(params).then(datas =>{
  635. if (datas) {
  636. if (datas.success) {
  637. that.$message({
  638. message: '保存成功',
  639. type: 'success'
  640. });
  641. that.activeName = 'second'
  642. that.getDetails(that.keyId)
  643. } else {
  644. that.$message({
  645. message: datas.message,
  646. type: 'error'
  647. })
  648. }
  649. }
  650. })
  651. },
  652. handleSecondWork() {
  653. this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
  654. confirmButtonText: '确定',
  655. cancelButtonText: '取消',
  656. type: 'warning'
  657. }).then(() => {
  658. let that = this
  659. let paramsArr = []
  660. that.changeSituationSelect.forEach(it =>{
  661. paramsArr.push(it.id)
  662. })
  663. apiGetevaluationdeptadDeleteComplete(paramsArr.join(',')).then(datas =>{
  664. if (datas) {
  665. that.$message({
  666. type: 'success',
  667. message: '删除成功!'
  668. });
  669. that.activeName = 'second'
  670. that.changeSituationSelect = []
  671. that.getDetails(that.keyId)
  672. }
  673. })
  674. })
  675. },
  676. }
  677. }
  678. </script>
  679. <style lang="less">
  680. .applicationFrom{
  681. .el-overlay{
  682. .el-dialog{
  683. // margin-top: 7vh;
  684. .el-dialog__body{
  685. padding: 0 20px !important;
  686. .startDetail{
  687. .starttitleSty{
  688. font-size: 18px;
  689. font-family: Microsoft YaHei;
  690. font-weight: bold;
  691. color: #3B7AD1;
  692. // line-height: 12px;
  693. margin: 20px 0 20px 10px;
  694. }
  695. .danjuMsg{
  696. border: 1px solid #D6DBEA;
  697. padding: 10px 20px;
  698. border-radius: 10px;
  699. margin-bottom: 10px;
  700. .danjuMsg_data{
  701. padding: 5px 0 10px 0;
  702. .data_tit{
  703. margin-right: 10px;
  704. font-weight: bold;
  705. font-size: 14px;
  706. font-family: Microsoft YaHei;
  707. color: #8991B0;
  708. }
  709. .data_tit_wd{
  710. display: inline-block;
  711. width: 90px;
  712. }
  713. .el-form-item--small{
  714. .el-input{
  715. height: 25px;
  716. width: 160px;
  717. }
  718. margin-bottom: 0;
  719. .el-input-number{
  720. height: 25px;
  721. .el-input-number__decrease, .el-input-number__increase{
  722. right: -39px;
  723. }
  724. }
  725. }
  726. }
  727. .danjuMsgSelect{
  728. display: flex;
  729. .data_tit{
  730. margin-right: 10px;
  731. font-weight: bold;
  732. font-size: 14px;
  733. font-family: Microsoft YaHei;
  734. color: #8991B0;
  735. }
  736. .el-select{
  737. width: 30%;
  738. position: relative;
  739. top: -5px;
  740. }
  741. .el-textarea{
  742. width: 80%;
  743. position: relative;
  744. top: -4px;
  745. }
  746. }
  747. }
  748. .el-select, .el-input{
  749. width: 100%;
  750. }
  751. .el-tabs{
  752. margin-top: 20px;
  753. .detaTableBtns{
  754. display: flex;
  755. justify-content: flex-end;
  756. width: 100%;
  757. margin-top: 5px;
  758. .tableBtn {
  759. display: flex;
  760. height: 20px;
  761. margin: 0 10px;
  762. // width: 20%;
  763. width: fit-content;
  764. img{
  765. margin-right: 5px;
  766. margin-top: 1px;
  767. }
  768. span{
  769. width: 35px;
  770. display: inline-block;
  771. font-size: 14px;
  772. font-family: Microsoft YaHei;
  773. font-weight: 400;
  774. }
  775. }
  776. .add{
  777. cursor: pointer;
  778. span{
  779. color: #3B7AD1;
  780. }
  781. }
  782. .save{
  783. cursor: pointer;
  784. span{
  785. color: #50C14E;
  786. }
  787. }
  788. .edit{
  789. span{
  790. color: #F5A623;
  791. }
  792. }
  793. .delete{
  794. cursor: pointer;
  795. span{
  796. color: #F65177;
  797. }
  798. }
  799. .import{
  800. cursor: pointer;
  801. span{
  802. color: #ce1e78;
  803. }
  804. }
  805. .export{
  806. cursor: pointer;
  807. span{
  808. color: #2baa8a;
  809. }
  810. }
  811. }
  812. .el-tabs__header{
  813. .el-tabs__nav{
  814. .el-tabs__item{
  815. font-size: 18px;
  816. font-family: Microsoft YaHei;
  817. font-weight: bold;
  818. margin: 0 10px;
  819. color: #8991B0;
  820. }
  821. .is-active{
  822. font-size: 18px;
  823. font-family: Microsoft YaHei;
  824. font-weight: bold;
  825. color: #3B7AD1;
  826. margin: 0 10px;
  827. }
  828. }
  829. }
  830. .el-table{
  831. margin-bottom: 10px;
  832. .el-table__body-wrapper{
  833. height: 38vh;
  834. }
  835. .el-table__row{
  836. .cell{
  837. .el-input{
  838. height: 24px;
  839. .el-input__inner{
  840. height: 24px;
  841. }
  842. }
  843. }
  844. }
  845. .indicitem{
  846. color: #F65177;
  847. font-size: 12px;
  848. margin-right: 20px;
  849. cursor:pointer;
  850. &:hover{
  851. text-decoration: underline;
  852. }
  853. }
  854. }
  855. }
  856. }
  857. }
  858. .el-dialog__footer{
  859. .dialog-footer{
  860. display: flex;
  861. justify-content: center;
  862. .el-button{
  863. width: 180px !important;
  864. height: 40px !important;
  865. }
  866. }
  867. }
  868. }
  869. }
  870. }
  871. </style>