|
|
|
@ -337,6 +337,105 @@ |
|
|
|
</div> |
|
|
|
</span> |
|
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
|
|
|
<!-- <!– 客户联系人-> 快速新增 –>--> |
|
|
|
<!-- <el-dialog title="项目联系人" :close-on-click-modal="false" v-drag :visible.sync="contactChooseFlag" width="1000px">--> |
|
|
|
<!-- <div style="font-size: 12px">--> |
|
|
|
<!-- <el-form :inline="true" label-position="top" :model="contactData">--> |
|
|
|
<!-- <el-form-item :label="'联系人编码'">--> |
|
|
|
<!-- <el-input v-model="contactData.contactId" clearable style="width: 120px"></el-input>--> |
|
|
|
<!-- </el-form-item>--> |
|
|
|
<!-- <el-form-item :label="'联系人名称'">--> |
|
|
|
<!-- <el-input v-model="contactData.contactName" clearable style="width: 150px"></el-input>--> |
|
|
|
<!-- </el-form-item>--> |
|
|
|
<!-- <el-form-item :label="' '">--> |
|
|
|
<!-- <el-button type="primary" @click="queryCustomerContact()">查询</el-button>--> |
|
|
|
<!-- </el-form-item>--> |
|
|
|
<!-- </el-form>--> |
|
|
|
<!-- </div>--> |
|
|
|
<!-- <el-container style="margin-top: 0px;">--> |
|
|
|
<!-- <el-main style="width: 350px;padding: 1px">--> |
|
|
|
<!-- <span style="font-size: 12px" >可选联系人:</span>--> |
|
|
|
<!-- <el-table--> |
|
|
|
<!-- height="400px"--> |
|
|
|
<!-- :data="contactChooseList1"--> |
|
|
|
<!-- border--> |
|
|
|
<!-- ref="contactTable1"--> |
|
|
|
<!-- @row-click="contactClickRow1"--> |
|
|
|
<!-- @selection-change="selectionContact1"--> |
|
|
|
<!-- highlight-current-row--> |
|
|
|
<!-- style="width: 100%">--> |
|
|
|
<!-- <el-table-column--> |
|
|
|
<!-- type="selection"--> |
|
|
|
<!-- header-align="center"--> |
|
|
|
<!-- align="center"--> |
|
|
|
<!-- width="50">--> |
|
|
|
<!-- </el-table-column>--> |
|
|
|
<!-- <el-table-column--> |
|
|
|
<!-- prop="contactId"--> |
|
|
|
<!-- header-align="center"--> |
|
|
|
<!-- align="center"--> |
|
|
|
<!-- min-width="80"--> |
|
|
|
<!-- label="联系人编码">--> |
|
|
|
<!-- </el-table-column>--> |
|
|
|
<!-- <el-table-column--> |
|
|
|
<!-- prop="contactDesc"--> |
|
|
|
<!-- header-align="center"--> |
|
|
|
<!-- align="center"--> |
|
|
|
<!-- min-width="200"--> |
|
|
|
<!-- label="联系人名称">--> |
|
|
|
<!-- </el-table-column>--> |
|
|
|
<!-- </el-table>--> |
|
|
|
<!-- </el-main>--> |
|
|
|
<!-- <el-main style="width: 10px;padding: 1px">--> |
|
|
|
<!-- <div style="margin-top: 200px;margin-left: 18px">--> |
|
|
|
<!-- <el-button type="primary" @click="addContact()">添加>></el-button>--> |
|
|
|
<!-- </div>--> |
|
|
|
<!-- <div style="margin-top: 15px;margin-left: 18px">--> |
|
|
|
<!-- <el-button type="primary" @click="deleteContact()">删除<<</el-button>--> |
|
|
|
<!-- </div>--> |
|
|
|
<!-- </el-main>--> |
|
|
|
<!-- <el-main style="width: 350px;padding: 1px">--> |
|
|
|
<!-- <span style="font-size: 12px" >已有联系人:</span>--> |
|
|
|
<!-- <el-table--> |
|
|
|
<!-- height="400px"--> |
|
|
|
<!-- :data="contactChooseList2"--> |
|
|
|
<!-- border--> |
|
|
|
<!-- ref="contactTable2"--> |
|
|
|
<!-- @row-click="contactClickRow2"--> |
|
|
|
<!-- @selection-change="selectionContact2"--> |
|
|
|
<!-- highlight-current-row--> |
|
|
|
<!-- style="width: 100%">--> |
|
|
|
<!-- <el-table-column--> |
|
|
|
<!-- type="selection"--> |
|
|
|
<!-- header-align="center"--> |
|
|
|
<!-- align="center"--> |
|
|
|
<!-- width="50">--> |
|
|
|
<!-- </el-table-column>--> |
|
|
|
<!-- <el-table-column--> |
|
|
|
<!-- prop="contactId"--> |
|
|
|
<!-- header-align="center"--> |
|
|
|
<!-- align="center"--> |
|
|
|
<!-- min-width="80"--> |
|
|
|
<!-- label="联系人编码">--> |
|
|
|
<!-- </el-table-column>--> |
|
|
|
<!-- <el-table-column--> |
|
|
|
<!-- prop="contactDesc"--> |
|
|
|
<!-- header-align="center"--> |
|
|
|
<!-- align="center"--> |
|
|
|
<!-- min-width="200"--> |
|
|
|
<!-- label="联系人名称">--> |
|
|
|
<!-- </el-table-column>--> |
|
|
|
<!-- </el-table>--> |
|
|
|
<!-- </el-main>--> |
|
|
|
<!-- </el-container>--> |
|
|
|
<!-- <el-footer style="height:40px;margin-top: 20px;text-align:center">--> |
|
|
|
<!-- <el-button type="primary" @click="contactChooseFlag = false">关闭</el-button>--> |
|
|
|
<!-- </el-footer>--> |
|
|
|
<!-- </el-dialog>--> |
|
|
|
|
|
|
|
|
|
|
|
<!-- 上传文件的modal --> |
|
|
|
<projectUploadFile ref="projectUploadFile" @refreshPageTables="getFileContentData()" v-drag></projectUploadFile> |
|
|
|
<add-or-update v-if="addOrUpdateVisible" v-model="addOrUpdate" ref="addOrUpdate" @refreshDataList="search" v-drag></add-or-update> |
|
|
|
@ -360,6 +459,7 @@ |
|
|
|
downLoadProjectFile, |
|
|
|
getCustomerContactData, |
|
|
|
getContactChooseData, |
|
|
|
getContactChooseData2, |
|
|
|
saveProjectContactList, |
|
|
|
deleteProjectInfo, |
|
|
|
getProjectUserRole, |
|
|
|
@ -1014,17 +1114,22 @@ |
|
|
|
fixed: false |
|
|
|
}, |
|
|
|
], |
|
|
|
|
|
|
|
contactSelections1: [], |
|
|
|
contactSelections2: [], |
|
|
|
contactData: { |
|
|
|
site: this.$store.state.user.site, |
|
|
|
contactId: '', |
|
|
|
contactName: '', |
|
|
|
}, |
|
|
|
} |
|
|
|
}, |
|
|
|
watch: { |
|
|
|
// columnList1: { |
|
|
|
// deep: true, |
|
|
|
// handler: function (newV, oldV) { |
|
|
|
// debugger |
|
|
|
// |
|
|
|
// } |
|
|
|
// } |
|
|
|
contactData: { |
|
|
|
deep: true, |
|
|
|
handler: function (newV, oldV) { |
|
|
|
this.contactData.contactId = this.contactData.contactId.toUpperCase() |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
mounted() { |
|
|
|
this.$nextTick(() => { |
|
|
|
@ -1493,6 +1598,126 @@ |
|
|
|
}); |
|
|
|
this.contactChooseFlag=true; |
|
|
|
}, |
|
|
|
// contactChooseModal () { |
|
|
|
// if (this.currentRow == null || this.currentRow === '') { |
|
|
|
// this.$alert('请选择项目!', '错误', { |
|
|
|
// confirmButtonText: '确定' |
|
|
|
// }) |
|
|
|
// return false |
|
|
|
// } |
|
|
|
// let inData = { |
|
|
|
// site: this.currentRow.site, |
|
|
|
// customerId: this.currentRow.customerId, |
|
|
|
// projectId: this.currentRow.projectId |
|
|
|
// } |
|
|
|
// this.contactSelections1 = null |
|
|
|
// this.contactSelections2 = null |
|
|
|
// this.contactData.contactId = '' |
|
|
|
// this.contactData.contactName = '' |
|
|
|
// getContactChooseData2(inData).then(({data}) => { |
|
|
|
// //区分请求成功和失败的状况 |
|
|
|
// if (data && data.code === 0) { |
|
|
|
// this.contactChooseList1 = data.rows1 |
|
|
|
// this.contactChooseList2 = data.rows2 |
|
|
|
// } |
|
|
|
// }) |
|
|
|
// this.contactChooseFlag = true |
|
|
|
// }, |
|
|
|
|
|
|
|
// // 查询物料项目 |
|
|
|
// queryCustomerContact () { |
|
|
|
// queryCustomerContact(this.contactData).then(({data}) => { |
|
|
|
// if (data && data.code === 0) { |
|
|
|
// this.contactChooseList1 = data.rows |
|
|
|
// } else { |
|
|
|
// this.contactChooseList1 = [] |
|
|
|
// } |
|
|
|
// }) |
|
|
|
// }, |
|
|
|
|
|
|
|
// // 可选联系人 |
|
|
|
// contactClickRow1 (row) { |
|
|
|
// this.$refs.contactTable1.toggleRowSelection(row) |
|
|
|
// }, |
|
|
|
// |
|
|
|
// // 已有联系人 |
|
|
|
// contactClickRow2 (row) { |
|
|
|
// this.$refs.contactTable2.toggleRowSelection(row) |
|
|
|
// }, |
|
|
|
// |
|
|
|
// selectionContact1 (val) { |
|
|
|
// this.contactSelections1 = val |
|
|
|
// }, |
|
|
|
// |
|
|
|
// selectionContact2 (val) { |
|
|
|
// this.contactSelections2 = val |
|
|
|
// }, |
|
|
|
|
|
|
|
// // 客户联系人新增 |
|
|
|
// addContact () { |
|
|
|
// if (this.contactSelections1 == null || this.contactSelections1.length === 0) { |
|
|
|
// this.$message.warning('请选择可选属性!') |
|
|
|
// return |
|
|
|
// } |
|
|
|
// let inData = { |
|
|
|
// site: this.currentRow.site, |
|
|
|
// customerId: this.currentRow.customerId, |
|
|
|
// projectId: this.currentRow.projectId, |
|
|
|
// contactList: this.contactSelections1 |
|
|
|
// } |
|
|
|
// addContact(inData).then(({data}) => { |
|
|
|
// if (data && data.code === 0) { |
|
|
|
// getContactChooseData(inData).then(({data}) => { |
|
|
|
// //区分请求成功和失败的状况 |
|
|
|
// if (data && data.code === 0) { |
|
|
|
// this.contactChooseList1 = data.rows1 |
|
|
|
// this.contactChooseList2 = data.rows2 |
|
|
|
// } |
|
|
|
// }) |
|
|
|
// this.getCustomerContactData() |
|
|
|
// this.contactSelections1 = [] |
|
|
|
// } else { |
|
|
|
// this.$alert(data.msg, '错误', { |
|
|
|
// confirmButtonText: '确定' |
|
|
|
// }) |
|
|
|
// } |
|
|
|
// }) |
|
|
|
// }, |
|
|
|
|
|
|
|
// // 客户联系人删除 |
|
|
|
// deleteContact () { |
|
|
|
// if (this.contactSelections2 == null || this.contactSelections2.length === 0) { |
|
|
|
// this.$alert("请选择已有属性!", '提示', { |
|
|
|
// confirmButtonText: '确定' |
|
|
|
// }) |
|
|
|
// return false |
|
|
|
// } |
|
|
|
// let inData = { |
|
|
|
// site: this.currentRow.site, |
|
|
|
// customerId: this.currentRow.customerId, |
|
|
|
// projectId: this.currentRow.projectId, |
|
|
|
// contactList: this.contactSelections2 |
|
|
|
// } |
|
|
|
// deleteContact(inData).then(({data}) => { |
|
|
|
// if (data && data.code === 0) { |
|
|
|
// getContactChooseData(inData).then(({data}) => { |
|
|
|
// //区分请求成功和失败的状况 |
|
|
|
// if (data && data.code === 0) { |
|
|
|
// this.contactChooseList1 = data.rows1 |
|
|
|
// this.contactChooseList2 = data.rows2 |
|
|
|
// } |
|
|
|
// }) |
|
|
|
// this.getCustomerContactData() |
|
|
|
// this.contactSelections2 = [] |
|
|
|
// } else { |
|
|
|
// this.$alert(data.msg, '错误', { |
|
|
|
// confirmButtonText: '确定' |
|
|
|
// }) |
|
|
|
// } |
|
|
|
// }) |
|
|
|
// }, |
|
|
|
|
|
|
|
|
|
|
|
saveProjectContactList(){ |
|
|
|
let data={ |
|
|
|
site:this.currentRow.site, |
|
|
|
|