diff --git a/src/views/xgf/flow/components/list.vue b/src/views/xgf/flow/components/list.vue index 0219ab9..8bbe506 100644 --- a/src/views/xgf/flow/components/list.vue +++ b/src/views/xgf/flow/components/list.vue @@ -38,20 +38,18 @@ - - +
- 批量推送 + 批量同意
@@ -69,10 +67,10 @@ import vueQr from 'vue-qr' import apply from './apply' import user from './user.vue' import SendUtil from './sendUtil.vue' -import UserInfo from "./userInfo.vue"; +import UserInfo from './userInfo.vue' export default { - components: {UserInfo, SendUtil, Pagination, apply, vueQr, user }, + components: { UserInfo, SendUtil, Pagination, apply, vueQr, user }, directives: { waves }, data() { return { @@ -163,27 +161,8 @@ export default { handleShow(row) { this.$refs.userInfos.init(row) }, - sendMessage(row) { - this.$confirm('确定要提交人员撤回申请吗?', '提示', { - confirmButtonText: '确定', - cancelButtonText: '取消', - type: 'warning' - }).then(() => { - requestFN( - '/trainingbatch/submitApplication', { xgf_user_ids: row.map(item => item.USER_ID).join(',') } - ).then((data) => { - this.getList() - }) - this.$message({ - type: 'success', - message: '申请提交成功!' - }) - }).catch(() => { - this.$message({ - type: 'info', - message: '申请提交取消' - }) - }) + approve(row) { + this.$refs.sendUtil.init(row) }, getUserInfo(row) { this.$refs.userInfo.init(row) diff --git a/src/views/xgf/flow/components/sendUtil.vue b/src/views/xgf/flow/components/sendUtil.vue index 3b46ac8..a7fdb5b 100644 --- a/src/views/xgf/flow/components/sendUtil.vue +++ b/src/views/xgf/flow/components/sendUtil.vue @@ -2,22 +2,16 @@
- - + + + + +
@@ -39,81 +33,24 @@ export default { data() { return { visible: false, - jituanDanwei: '', loading: false, - jituanDanweiTreeData: [], - normalizer(node) { - return { - id: node.id, - label: node.name, - children: node.nodes - } - }, - corp_id: null, - corp_name: '', + value: null, heirloom: {} } }, methods: { init(e) { this.visible = true - this.getCorpinfo() this.heirloom = JSON.stringify(e) }, - getCorpinfo() { - requestFN( - '/corpinfo/getDataForEditByCorpInfoId', - { - CORPINFO_ID: JSON.parse(sessionStorage.getItem('user')).CORPINFO_ID, - tm: new Date().getTime() - } - ).then((data) => { - this.corpinfo = data.pd - // 河港机械 jtdw002 1e6dbbe16004402f8d2c0e52afd9a676 - // 河港港工 jtdw003 3a854eefa7894e06aaa1a2611bca80f6 - // 河港检测 jtdw004 020578a4c1f04bc692ee25145c2efbe5 - // 方宇物业 jtdw005 90966974de3c4b83aca6f8fd6432d5c2 - - if (data.pd.CORP_TYPE == 'jtdw002') { - this.jituanDanwei = '1e6dbbe16004402f8d2c0e52afd9a676' - } - if (data.pd.CORP_TYPE == 'jtdw003') { - this.jituanDanwei = '3a854eefa7894e06aaa1a2611bca80f6' - } - if (data.pd.CORP_TYPE == 'jtdw004') { - this.jituanDanwei = '020578a4c1f04bc692ee25145c2efbe5' - } - if (data.pd.CORP_TYPE == 'jtdw005') { - this.jituanDanwei = '90966974de3c4b83aca6f8fd6432d5c2' - } - this.getTreeData() - }) - }, - getTreeData() { - if (this.jituanDanwei) { - requestFN( - '/companyApi/department/listTree', - { CORPINFO_ID: this.jituanDanwei } - ).then((data) => { - this.jituanDanweiTreeData = JSON.parse(data.zTreeNodes) - }).catch((e) => { - }) - } - }, - getInfo(e) { - console.log(e) - this.corp_name = e.name - }, beforeClose() { - this.corp_id = null }, sendMessage(row) { requestFN( - '/trainingbatch/sendMessage', + '/xgf/user/approve', { list: this.heirloom, - corp_id: this.corp_id, - corp_name: this.corp_name, + STATUS: this.value, tm: new Date().getTime() } ).then((data) => {