diff --git a/src/views/main/BookingLedger/detail/modules/operationArea.vue b/src/views/main/BookingLedger/detail/modules/operationArea.vue
index ba88b41..2cb6c35 100644
--- a/src/views/main/BookingLedger/detail/modules/operationArea.vue
+++ b/src/views/main/BookingLedger/detail/modules/operationArea.vue
@@ -704,6 +704,7 @@ export default {
uploadFile(file) {
const formData = new FormData()
formData.append('file', file.file)
+ formData.append('bookingId', this.id)
const type = file.file.type
console.log(type)
BookingOrderOcrUpFile(formData).then(res => {
diff --git a/src/views/main/Customer/addForm.vue b/src/views/main/Customer/addForm.vue
index dc04bdd..4c80940 100644
--- a/src/views/main/Customer/addForm.vue
+++ b/src/views/main/Customer/addForm.vue
@@ -104,65 +104,46 @@
-
-
+
+
-
+
+
+ {{ item.name }}
+
+
-
+
-
+
+
+ {{ item.name }}
+
+
-
+
-
+
+
+ {{ item.name }}
+
+
-
+
-
+
+
+ {{ item.name }}
+
+
@@ -272,6 +253,7 @@
-
diff --git a/src/views/main/Customer/editForm.vue b/src/views/main/Customer/editForm.vue
index 1fbfd1a..c37358f 100644
--- a/src/views/main/Customer/editForm.vue
+++ b/src/views/main/Customer/editForm.vue
@@ -102,6 +102,49 @@
+
+
+
+
+
+ {{ item.name }}
+
+
+
+
+
+
+
+
+ {{ item.name }}
+
+
+
+
+
+
+
+
+ {{ item.name }}
+
+
+
+
+
+
+
+
+ {{ item.name }}
+
+
+
+
+
联系人信息
@@ -242,7 +285,8 @@ export default {
ContactsData: [],
Data: {},
TypeData: [],
- propStringData: []
+ propStringData: [],
+ saleUserList: []
}
},
watch: {
@@ -256,33 +300,51 @@ export default {
methods: {
init() {
DjyCustomerDetail({ id: this.$route.query.id }).then(res => {
- this.Data = res.data
- let WpropString = []
- if (res.data.propString) {
- res.data.propString.split(']').forEach(item => {
- if (item.split('[')[1]) {
- WpropString.push(item.split('[')[1])
- }
- })
- }
- res.data.contacts.forEach((item, index) => {
- item.WebKey = index + 1
- })
- this.ContactsData = res.data.contacts
- if (WpropString.length) {
- this.form.setFieldsValue({
- ...res.data,
- WpropString
- })
- } else {
- this.form.setFieldsValue({
- ...res.data
+ if (res.data) {
+ this.Data = res.data
+ let WpropString = []
+ if (res.data.propString) {
+ res.data.propString.split(']').forEach(item => {
+ if (item.split('[')[1]) {
+ WpropString.push(item.split('[')[1])
+ }
+ })
+ }
+ res.data.contacts.forEach((item, index) => {
+ item.WebKey = index + 1
})
+ this.ContactsData = res.data.contacts
+ if (WpropString.length) {
+ this.form.setFieldsValue({
+ ...res.data,
+ WpropString
+ })
+ } else {
+ this.form.setFieldsValue({
+ ...res.data
+ })
+ }
}
})
this.TypeData = this.$options.filters['dictData']('djy_cust_contact_role')
this.propStringData = this.$options.filters['dictData']('djy_cust_prop')
},
+ getUserList(name = '', type) {
+ GetSysUserPage({
+ name: name
+ })
+ .then(res => {
+ if (res.success) {
+ this.saleUserList = res.data
+ }
+ })
+ .catch(err => {
+ console.log(err)
+ })
+ },
+ filterOption(value, option) {
+ return option.componentOptions.children[0].text.indexOf(value) >= 0
+ },
removeCheckboxRow() {
this.$refs.xTable.selection.forEach(item => {
this.ContactsData.forEach((item2, index2) => {
@@ -357,19 +419,37 @@ export default {
propString == '' ? (propString = `[${item2}]`) : (propString = `${propString}[${item2}]`)
})
}
-
- DjyCustomerEdit({ ...this.Data, ...values, propString: propString, contacts: this.ContactsData })
+ let Arr = ['sale', 'op', 'doc', 'custservice']
+ GetSysUserPage()
.then(res => {
if (res.success) {
- this.$message.success('编辑成功')
- this.confirmLoading = false
- this.$emit('ok', values)
- } else {
- this.$message.error(`编辑失败,${res.message}`)
+ let saleUserList = res.data
+ Arr.forEach(item => {
+ if (values[`${item}id`]) {
+ saleUserList.forEach(i => {
+ if (i.id == values[`${item}id`]) {
+ values[item] = i.name
+ }
+ })
+ }
+ })
+ DjyCustomerEdit({ ...this.Data, ...values, propString: propString, contacts: this.ContactsData })
+ .then(res => {
+ if (res.success) {
+ this.$message.success('编辑成功')
+ this.confirmLoading = false
+ this.$emit('ok', values)
+ } else {
+ this.$message.error(`编辑失败,${res.message}`)
+ }
+ })
+ .finally(res => {
+ this.confirmLoading = false
+ })
}
})
- .finally(res => {
- this.confirmLoading = false
+ .catch(err => {
+ console.log(err)
})
} else {
this.confirmLoading = false