diff --git a/src/views/xgf/flow/components/sendUtil.vue b/src/views/xgf/flow/components/sendUtil.vue
index 40d7eff..e799dc5 100644
--- a/src/views/xgf/flow/components/sendUtil.vue
+++ b/src/views/xgf/flow/components/sendUtil.vue
@@ -44,6 +44,17 @@
+
+
+
+
+
@@ -59,9 +70,11 @@
import vueQr from 'vue-qr'
import Treeselect from '@riophae/vue-treeselect'
import { requestFN } from '@/utils/request'
+import uploadFile from '../../../util/uploadFile/index.vue'
+import { upload } from '@/utils/upload'
export default {
- components: { Treeselect, vueQr },
+ components: { uploadFile, Treeselect, vueQr },
props: {
appendToBody: {
type: Boolean,
@@ -80,6 +93,7 @@ export default {
APPOINT_DEPARTMENT_NAME: '',
APPOINT_USER_ID: null,
APPOINT_USER_NAME: '',
+ APPOINT_ANNEX: null,
OPINION: '',
STEP: false,
LIMIT_END_TIME: '',
@@ -87,7 +101,8 @@ export default {
tm: new Date().getTime(),
list: [],
isShow: true,
- info: {}
+ info: {},
+ TYPE: null
},
rules: {
STATUS: [
@@ -127,6 +142,7 @@ export default {
this.heirloom = JSON.stringify(e)
this.form.list = JSON.stringify(e)
this.form.STEP = (e[0].FLOWS_STEP === 2)
+ this.form.TYEP = e[0].FLOWS_TYPE
this.getDepartmentTree()
this.loading = false
},
@@ -135,16 +151,39 @@ export default {
if (!valid) {
this.$message.error('请填写完整信息')
} else {
- requestFN('/xgf/user/approveMax', this.form)
- .then((data) => {
- this.$message.success('推送成功')
- this.visible = false
- this.$emit('refresh', '')
- this.handleClose()
- })
- .catch((e) => {
- console.log(e)
+ if (this.form.TYPE !== '2') {
+ requestFN('/xgf/user/approveMax', this.form)
+ .then((data) => {
+ this.$message.success('推送成功')
+ this.visible = false
+ this.$emit('refresh', '')
+ this.handleClose()
+ })
+ .catch((e) => {
+ console.log(e)
+ })
+ } else {
+ const formData = new FormData()
+ this.form.chengNuoFlag = '1'
+ Object.keys(this.form).map(key => {
+ formData.append(key, this.form[key])
})
+ if (this.form.APPOINT_ANNEX) {
+ for (let i = 0; i < this.form.APPOINT_ANNEX.length; i++) {
+ formData.append('weiTuoShu', this.form.APPOINT_ANNEX[i].raw)
+ }
+ }
+ upload('/xgf/user/approveMax', formData)
+ .then((data) => {
+ this.$message.success('推送成功')
+ this.visible = false
+ this.$emit('refresh', '')
+ this.handleClose()
+ })
+ .catch((e) => {
+ console.log(e)
+ })
+ }
}
})
},