Commit a06c9f55 authored by jiangqihao's avatar jiangqihao

代理商详情信息

parent e362e088
<template>
<div class="table-container">
<form-title :title="tableConfig.tableTitle">
<div>
<div v-if="isShowBtn">
<slot
name="btn"
:selection="selection"
......@@ -78,6 +78,10 @@ export default {
deleteUrl: {
type: String,
default: ''
},
isShowBtn: {
type: Boolean,
default: true
}
},
data() {
......@@ -89,7 +93,8 @@ export default {
selection: [],
dialogFormVisible: false,
dialogTitle: '',
loading: false
loading: false,
fenye: true
}
},
created() {
......
......@@ -187,6 +187,7 @@ export default {
const params = this.$translateToC4CData(data)
this.loading = true
fetchJAVATable(this.url, params).then(res => {
console.log(res)
this.tableData = res.results || []
this.total = Number(res.totalSize || 0)
this.loading = false
......
import dictionary from '@/api/dictionary'
import { releaseRecord, applicationRecord } from '@/api/customers'
const tableConfig = {
url: releaseRecord.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
ReleaseName: {
label: '发布名称',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.ReleaseName)
},
showInSearch: true
},
ReleaseBatch: {
label: '发布批次',
type: 'input',
showInSearch: true
},
ReleaseContent: {
label: '发布内容',
type: 'select'
},
ReleaseStartTime: {
label: '发布开始时间',
showInSearch: true,
type: 'date'
},
ReleaseEndTime: {
label: '发布截止时间',
type: 'input'
},
PublicationResultTime: {
label: '公布结果时间',
type: 'input'
},
ApprovalEndTime: {
label: '审核截止时间',
type: 'input'
},
ApprovalStatus: {
label: '审批状态',
type: 'select',
value: 'ApprovalStatusText',
options: dictionary.approvalStatus
},
CreateName: {
label: '创建人',
type: 'input'
},
CreateOn: {
label: '创建时间',
type: 'input'
}
}
}
const listConfig = {
tableTitle: '客户资源清单',
url: releaseRecord.customerListUrl,
initialParams: {},
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
AccountName: {
label: '客户',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.AccountName)
},
showInSearch: true
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleApply(scope.row)
},
class: 'el-icon-s-promotion',
props: {
type: 'text'
}
},
'申请')
}
}
}
}
const applyDialogformConfig = {
title: '申请原因',
createUrl: applicationRecord.createUrl,
labelPosition: 'left',
submitBtnText: '确定',
span: 22,
formDesc: {
ApplicationReason: {
type: 'textarea',
label: '申请原因',
required: true,
layout: 24
}
}
}
const applicationRecordConfig = {
tableTitle: '申请记录',
url: applicationRecord.searchUrl,
initialParams: {},
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
AccountName: {
label: '客户',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.AccountName)
}
},
ApplicationPersonName: {
label: '申请人',
type: 'input'
},
ApplicationTime: {
label: '申请时间',
type: 'input'
},
ApplicationReason: {
label: '申请原因',
type: 'input'
}
}
}
export default {
tableConfig,
listConfig,
applicationRecordConfig,
applyDialogformConfig
}
<template>
<div class="app-container">
<ele-search
:columns="listConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<div class="table-container">
<form-title :title="listConfig.tableTitle" />
<ele-table
ref="eleTable"
v-bind="listConfig"
:expand-params="expandParams"
:listeners="tableListeners"
/>
</div>
<div class="table-container">
<form-title :title="applicationRecordConfig.tableTitle" />
<ele-table
ref="eleTable2"
v-bind="applicationRecordConfig"
:expand-params="expandParams"
:listeners="tableListeners"
/>
</div>
<!-- 弹框部分 -->
<ele-form-dialog
:form-data="applyData"
:request-fn="handleSave"
:visible.sync="applyDialogFormVisible"
v-bind="applyDialogformConfig"
:loading="applyLoading"
/>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
listConfig: {},
applicationRecordConfig: {},
applyLoading: false,
applyData: {},
applyDialogFormVisible: false,
applyDialogformConfig: constant.applyDialogformConfig
}
},
created() {
constant.listConfig.initialParams.parentObjectID = this.$route.query.objectID
this.listConfig = constant.listConfig
constant.applicationRecordConfig.initialParams.releaseRecordID = this.$route.query.objectID
this.applicationRecordConfig = constant.applicationRecordConfig
this.tableListeners = {
handleCheck: this.handleCheck,
handleApply: this.handleApply
}
},
methods: {
handleCheck(row) {
},
handleApply(row) {
this.applyData = {
AccountID: row.AccountID,
AccountName: row.AccountName,
releaseRecordID: row.ParentObjectID,
approvalStatus: '101'
}
this.applyDialogFormVisible = true
},
handleSave() {
this.applyLoading = true
const url = this.applyDialogformConfig.createUrl
const applyData = this.$translateToC4CData(this.applyData)
this.$request(url, [applyData]).then(res => {
this.applyLoading = false
this.applyDialogFormVisible = false
this.$refs.eleTable2.handleSearch()
}).catch(() => {
this.applyLoading = false
})
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<div class="app-container">
<ele-search
:columns="tableConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<div class="table-container">
<ele-table
ref="eleTable"
v-bind="tableConfig"
:expand-params="expandParams"
:listeners="tableListeners"
@handleSelectionChange="handleSelectionChange"
/>
</div>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
tableConfig: constant.tableConfig
}
},
created() {
this.tableListeners = {
handleCheck: this.handleCheck
}
},
methods: {
handleSelectionChange(selection) {
console.log(selection)
this.selection = selection
},
handleCheck(row) {
this.$router.push({
path: '/customers/resource/application-detail',
query: {
objectID: row.ObjectID
}
})
}
}
}
</script>
<style lang="scss" scoped>
</style>
import dictionary from '@/api/dictionary'
import { releaseRecord, applicationRecord, approvalRecord } from '@/api/customers'
const tableConfig = {
url: releaseRecord.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
ReleaseName: {
label: '发布名称',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.ReleaseName)
},
showInSearch: true
},
ReleaseBatch: {
label: '发布批次',
type: 'input',
showInSearch: true
},
ReleaseContent: {
label: '发布内容',
type: 'select'
},
ReleaseStartTime: {
label: '发布开始时间',
showInSearch: true,
type: 'date'
},
ReleaseEndTime: {
label: '发布截止时间',
type: 'input'
},
PublicationResultTime: {
label: '公布结果时间',
type: 'input'
},
ApprovalEndTime: {
label: '审核截止时间',
type: 'input'
},
ApprovalStatus: {
label: '审批状态',
type: 'select',
value: 'ApprovalStatusText',
options: dictionary.approvalStatus
},
CreateName: {
label: '创建人',
type: 'input'
},
CreateOn: {
label: '创建时间',
type: 'input'
}
}
}
const listConfig = {
tableTitle: '客户资源清单',
url: releaseRecord.customerListUrl,
initialParams: {},
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
AccountName: {
label: '客户',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.AccountName)
}
}
}
}
const applyDialogformConfig = {
title: '审批意见',
createUrl: approvalRecord.updateUrl,
labelPosition: 'left',
submitBtnText: '确定',
span: 22,
formDesc: {
ApplicationReason: {
type: 'textarea',
label: '申请原因',
required: true,
layout: 24
}
}
}
const applicationRecordConfig = {
tableTitle: '审批记录',
url: applicationRecord.searchUrl,
initialParams: {},
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
AccountName: {
label: '客户',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.AccountName)
}
},
ApplicationPersonName: {
label: '申请人',
type: 'input',
showInSearch: true
},
ApplicationTime: {
label: '申请时间',
type: 'input'
},
ApplicationReason: {
label: '申请原因',
type: 'input'
},
ApprovalPersonName: {
label: '审批人',
type: 'input'
},
ApprovalTime: {
label: '审批时间',
type: 'input'
},
ApprovalComments: {
label: '审批原因',
type: 'input'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h('div', {}, [
h(
'el-button',
{
on: {
click: (e) => listeners.handleAddView(scope.row)
},
// class: 'el-icon-edit',
props: {
type: 'text'
}
},
'审批意见'),
scope.row.Ext_CustomerStatus_KUTText === '草稿' && h(
'el-button',
{
on: {
click: (e) => listeners.handlePass(scope.row)
},
// class: 'el-icon-delete',
props: {
type: 'text'
}
},
'通过')
])
}
}
}
}
export default {
tableConfig,
listConfig,
applicationRecordConfig,
applyDialogformConfig
}
<template>
<div class="app-container">
<div class="table-container">
<form-title :title="listConfig.tableTitle" />
<ele-table
v-bind="listConfig"
:expand-params="expandParams"
:listeners="tableListeners"
/>
</div>
<div class="table-container">
<ele-search
:columns="listConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<form-title :title="applicationRecordConfig.tableTitle" />
<ele-table
ref="eleTable"
v-bind="applicationRecordConfig"
:expand-params="expandParams"
:listeners="tableListeners"
/>
</div>
<!-- 弹框部分 -->
<ele-form-dialog
:form-data="applyData"
:request-fn="handleSave"
:visible.sync="applyDialogFormVisible"
v-bind="applyDialogformConfig"
:loading="applyLoading"
/>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
listConfig: {},
applicationRecordConfig: {},
applyLoading: false,
applyData: {},
applyDialogFormVisible: false,
applyDialogformConfig: constant.applyDialogformConfig
}
},
created() {
constant.listConfig.initialParams.parentObjectID = this.$route.query.objectID
this.listConfig = constant.listConfig
constant.applicationRecordConfig.initialParams.releaseRecordID = this.$route.query.objectID
this.applicationRecordConfig = constant.applicationRecordConfig
this.tableListeners = {
handleCheck: this.handleCheck,
handlePass: this.handlePass,
handleAddView: this.handleAddView
}
},
methods: {
handleCheck(row) {
},
handlePass(row) {
this.applyData = {
AccountID: row.AccountID,
AccountName: row.AccountName,
releaseRecordID: row.ParentObjectID,
approvalStatus: '101'
}
this.applyDialogFormVisible = true
},
handleAddView(row) {
},
handleSave() {
this.applyLoading = true
const url = this.applyDialogformConfig.createUrl
const applyData = this.$translateToC4CData(this.applyData)
this.$request(url, [applyData]).then(res => {
this.applyLoading = false
this.applyDialogFormVisible = false
this.$refs.eleTable.handleSearch()
}).catch(() => {
this.applyLoading = false
})
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<div class="app-container">
<ele-search
:columns="tableConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<div class="table-container">
<ele-table
ref="eleTable"
v-bind="tableConfig"
:expand-params="expandParams"
:listeners="tableListeners"
@handleSelectionChange="handleSelectionChange"
/>
</div>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
tableConfig: constant.tableConfig
}
},
created() {
this.tableListeners = {
handleCheck: this.handleCheck
}
},
methods: {
handleSelectionChange(selection) {
console.log(selection)
this.selection = selection
},
handleCheck(row) {
this.$router.push({
path: '/customers/resource/approval-detail',
query: {
objectID: row.ObjectID
}
})
}
}
}
</script>
<style lang="scss" scoped>
</style>
import { contact } from '@/api/customers'
import dictionary from '@/api/dictionary'
const tableConfig = {
url: contact.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
ContactID: {
label: '联系人编码',
type: 'input',
showInSearch: true
},
LastName: {
label: '联系人名称',
type: 'input',
showInSearch: true
},
AccountFormattedName: {
label: '客户名称'
},
Ext_CustomerPhone_KUT: {
label: '手机1'
},
Ext_CustomerMobile_KUT: {
label: '手机2'
},
Ext_CustomerLandline_KUT: {
label: '座机'
},
Ext_CustomerRole_KUT: {
label: '角色',
value: 'Ext_CustomerRole_KUTText'
},
JobTitle: {
label: '职位',
type: 'input',
showInSearch: true
},
Email: {
label: '电子邮箱'
},
Ext_CustomerWeChat_KUT: {
label: '微信'
},
Ext_CustomerQQ_KUT: {
label: 'QQ'
},
Ext_CustomerAddress_KUT: {
label: '详细地址'
},
Ext_CustomerCreateBy_KUT: {
label: '创建人'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
LastName: {
type: 'input',
label: '联系人名称',
layout: 12
},
AccountFormattedName: {
type: 'lov',
label: '客户名称',
code: 'customer',
returnFn: function(row) {
return {
AccountID: row.AccountID,
AccountUUID: row.AccountUUID,
AccountFormattedName: row.Name
}
},
layout: 12
},
Ext_CustomerPhone_KUT: {
label: '手机1',
type: 'input',
layout: 12
},
Ext_CustomerMobile_KUT: {
label: '手机2',
type: 'input',
layout: 12
},
Ext_CustomerLandline_KUT: {
label: '座机',
type: 'input',
layout: 12
},
Ext_CustomerRole_KUT: {
type: 'select',
label: '角色',
isOptions: true,
options: dictionary.contactRole,
layout: 12
},
JobTitle: {
label: '职位',
type: 'input',
layout: 12
},
Email: {
label: '电子邮箱',
type: 'input',
layout: 12
},
Ext_CustomerWeChat_KUT: {
label: '微信',
type: 'input',
layout: 12
},
Ext_CustomerQQ_KUT: {
label: 'QQ',
type: 'input',
layout: 12
},
Ext_CustomerAddress_KUT: {
label: '详细地址',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig
}
<template>
<div class="app-container">
<ele-search
:columns="tableConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<div class="table-container">
<TableBtns>
<template v-slot:left>
<el-button
type="primary"
icon="el-icon-plus"
@click="handleShowDialog"
>新建</el-button>
<el-button
type="danger"
icon="el-icon-delete"
@click="handleDelete"
>
删除
</el-button>
</template>
</TableBtns>
<ele-table
ref="eleTable"
v-bind="tableConfig"
:expand-params="expandParams"
:listeners="tableListeners"
@handleSelectionChange="handleSelectionChange"
/>
</div>
<!-- 弹框部分 -->
<ele-form-dialog
:title="title"
:form-data="diglogFormData"
:request-fn="handleSave"
:visible.sync="diglogVisble"
v-bind="formConfig"
:loading="loading"
/>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
import { contact } from '@/api/customers'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
tableConfig: constant.tableConfig,
selection: [],
loading: false,
diglogVisble: false,
title: '',
diglogFormData: {},
formConfig: constant.formConfig
}
},
created() {
this.tableListeners = {
handleCheck: this.handleCheck,
handleEdit: this.handleEdit
}
},
methods: {
handleCheck(row) {
this.$router.push({
path: '/customers/resource/detail',
query: {
objectID: row.ObjectID
}
})
},
handleSelectionChange(selection) {
console.log(selection)
this.selection = selection
},
handleClearSelection() {
this.selection = []
this.$refs.eleTable.clearSelection()
},
handleDelete() {
if (this.selection.length === 0) {
this.$message.warning('请先选择一个客户')
return
}
},
handleShowDialog() {
this.title = '新建联系人'
this.diglogFormData = {}
this.diglogVisble = true
},
handleEdit(row) {
this.title = '编辑联系人'
this.diglogFormData = JSON.parse(JSON.stringify(row))
this.diglogVisble = true
},
handleSave() {
this.loading = true
var data = this.$translateToC4CData(this.releaseData)
if (data.objectID) {
this.$request(contact.updateUrl, [data]).then(res => {
this.$message.success('保存成功')
this.loading = false
this.dialogVisble = false
this.handleSearch()
}).catch(() => {
this.loading = false
})
} else {
this.$request(contact.createUrl, [data]).then(res => {
this.$message.success('新建成功')
this.loading = false
this.dialogVisble = false
this.handleSearch()
}).catch(() => {
this.loading = false
})
}
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<div>
<BusinessTable v-bind="constant"/>
<BusinessTable v-bind="constant" :isShowBtn="isShowBtn"/>
</div>
</template>
......@@ -21,6 +21,7 @@ export default {
data() {
return {
constant: {},
isShowBtn: false,
}
},
watch: {
......
......@@ -13,7 +13,7 @@
/>
</div>
<CustomerAddress :objectID='objectID' v-if="showAdress"/>
<PersonalInFo :addBtnStart='addBtnStart' :dedeleBtnStart="dedeleBtnStart" :type-code="typeCode" :searchUrl="searchUrl"/>
<PersonalInFo :addBtnStart='addBtnStart' :dedeleBtnStart="dedeleBtnStart" :type-code="typeCode" :searchUrl="searchUrl" :isShowEditBtn='isShowEditBtn'/>
</div>
</template>
......@@ -46,10 +46,10 @@ export default {
dedeleBtnStart: true,
objectID: '',
showAdress: false,
addBtnStart: true,
formData: {},
isShowSubmitBtn: false,
isShowBackBtn: false,
isShowEditBtn: true,
sections: [
{
title: '基本信息',
......@@ -200,7 +200,8 @@ export default {
type: 'input',
layout: 12,
label: 'Unis业务负责人姓名',
disabled: true
disabled: true,
break: true,
},
ExtUnisPhone_SDK: {
type: 'input',
......@@ -219,6 +220,7 @@ export default {
layout: 12,
label: '商务负责人姓名',
disabled: true,
break: true,
},
ExtBusinessPhone_SDK: {
type: 'input',
......@@ -257,29 +259,29 @@ export default {
// },
// }
// },
// {
// title: "合作日期",
// formDesc: {
// ExtStartDate_SDK: {
// type: 'input',
// label: '初始合作开始时间',
// layout: 12,
// disabled: true
// },
// // ExtAuthenticationDate_SDK: {
// // type: 'input',
// // label: '高级认证日期',
// // layout: 12,
// // disabled: true
// // },
// ExtEndDate_SDK: {
{
title: "合作日期",
formDesc: {
ExtStartDate_SDK: {
type: 'input',
label: '初始合作开始时间',
layout: 12,
disabled: true
},
// ExtAuthenticationDate_SDK: {
// type: 'input',
// label: '合作终止日期',
// label: '高级认证日期',
// layout: 12,
// disabled: true
// },
// }
// }
ExtEndDate_SDK: {
type: 'input',
label: '合作终止日期',
layout: 12,
disabled: true
},
}
}
],
rules: {}
}
......@@ -316,6 +318,29 @@ export default {
return formData;
},
async getOneData() {
const showTime = {
title: "合作日期",
formDesc: {
ExtStartDate_SDK: {
type: 'input',
label: '初始合作开始时间',
layout: 12,
disabled: true
},
ExtAuthenticationDate_SDK: {
type: 'input',
label: '高级认证日期',
layout: 12,
disabled: true
},
ExtEndDate_SDK: {
type: 'input',
label: '合作终止日期',
layout: 12,
disabled: true
},
}
}
this.loading = true
// this.objectId = JSON.parse(localStorage.getItem('USERINFO')).ExtCustomerObjectID_SDK
if (JSON.parse(localStorage.getItem('USERINFO')).ExtCustomerObjectID_SDK !== '') {
......@@ -366,7 +391,30 @@ export default {
},
}
}
this.sections.splice(2, 1, show)
const subscription = {
title: "签约信息",
formDesc: {
ExtChannelType_SDKText: {
type: 'input',
label: '签约渠道类型',
layout: 12,
disabled: true,
},
ExtLockRspName_SDK: {
type: 'input',
label: '锁定RSP',
layout: 12,
disabled: true
},
ExtLockCityName_SDK: {
type: 'input',
label: '城市覆盖范围',
layout: 12,
disabled: true
}
}
}
this.sections.splice(2, 2, show,subscription,showTime)
} else if (res.results[0].ExtCustomerType_SDK === '101') {
const show = {
title: "签约信息",
......@@ -389,10 +437,18 @@ export default {
layout: 12,
disabled: true
},
ExtLockCityName_SDK: {
type: 'input',
label: '城市覆盖范围',
layout: 12,
disabled: true
}
}
}
this.sections.push(show)
this.isShowEditBtn = false
this.sections.splice(3,0,show)
} else {
this.isShowEditBtn = false
this.showAdress = true
}
this.formData = res.results[0]
......
import { customer } from '@/api/customers'
import dictionary from '@/api/dictionary'
const tableConfig = {
url: customer.searchUrl,
initialParams: {
roleCode: 'CRM000'
},
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Name: {
label: '客户名称',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.Name)
},
showInSearch: true
},
Ext_CustomerType_KUT: {
label: '客户类型',
type: 'select',
value: 'Ext_CustomerType_KUTText',
showInSearch: true,
options: dictionary.customerType
},
Ext_CustomerStatus_KUT: {
label: '客户状态',
type: 'select',
value: 'Ext_CustomerStatus_KUTText',
showInSearch: true,
options: dictionary.customerStatus
},
Namexxs: {
label: '所属代理商',
type: 'input'
},
Ext_CustomerMainContactName_KUT: {
label: '联系人',
type: 'input'
},
Ext_CustomerMainContactPhone_KUT: {
label: '手机号码',
type: 'input'
},
Ext_CustomerFollowUpDate_KUT: {
label: '最后跟进',
type: 'input'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h('div', {}, [
h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row)
},
class: 'el-icon-edit',
props: {
type: 'text'
}
},
'编辑'),
scope.row.Ext_CustomerStatus_KUTText === '草稿' && h(
'el-button',
{
on: {
click: (e) => listeners.handleDelete(scope.row)
},
class: 'el-icon-delete',
props: {
type: 'text'
}
},
'删除')
])
}
}
}
}
const formConfig = {
formDesc: {
code: {
type: 'input',
label: '集团代码',
disabled: true,
required: true
},
name: {
type: 'input',
label: '集团名称',
required: true
},
coreEnterprise: {
type: 'select',
label: '是否核心企业',
isOptions: true,
options: [
{
text: '是',
value: 1
},
{
text: '否',
value: 0
}
]
}
},
rules: {
// name: [{ required: true, message: '请输入集团名称', trigger: 'blur' }],
// code: [{ required: true, message: '请输入集团代码', trigger: 'blur' }]
}
}
// 注销客户弹框配置
const CancellationFormConfig = {
title: '注销原因',
createUrl: customer.updateUrl,
labelPosition: 'left',
submitBtnText: '确定',
span: 22,
formDesc: {
Ext_CustomerStatus_KUT: {
type: 'input',
label: '客户状态',
default: '131',
vif: false,
layout: 24
},
Ext_CustomerCancellationReasons_KUT: {
type: 'textarea',
label: '注销原因',
layout: 24
}
}
}
// 激活客户弹框配置
const ActivationFormConfig = {
title: '激活原因',
createUrl: customer.updateUrl,
labelPosition: 'left',
submitBtnText: '确定',
span: 22,
formDesc: {
Ext_CustomerStatus_KUT: {
type: 'input',
label: '客户状态',
default: '111',
vif: false,
layout: 24
},
Ext_CustomerActivationReasons_KUT: {
type: 'textarea',
label: '激活原因',
layout: 24
}
}
}
// 冻结客户弹框配置
const frozenFormConfig = {
title: '冻结原因',
createUrl: customer.updateUrl,
labelPosition: 'left',
submitBtnText: '确定',
span: 22,
formDesc: {
Ext_CustomerStatus_KUT: {
type: 'input',
label: '客户状态',
default: '121',
vif: false,
layout: 24
},
Ext_CustomerFrozenReasons_KUT: {
type: 'textarea',
label: '冻结原因',
layout: 24
}
}
}
// 解冻客户弹框配置
const thawFormConfig = {
title: '解冻原因',
createUrl: customer.updateUrl,
labelPosition: 'left',
submitBtnText: '确定',
span: 22,
formDesc: {
Ext_CustomerStatus_KUT: {
type: 'input',
label: '客户状态',
default: '111',
vif: false,
layout: 24
},
Ext_CustomerThawReasons_KUT: {
type: 'textarea',
label: '解冻原因',
layout: 24
}
}
}
// 移入资源池弹框配置
const ResourcePoolFormConfig = {
title: '移入资源池',
createUrl: customer.toPoolUrl,
labelPosition: 'left',
submitBtnText: '确定',
span: 22,
formDesc: {
Ext_CustomerActivationReasons_KUT: {
type: 'textarea',
label: '移入资源池原因',
layout: 24
}
}
}
export default {
tableConfig,
formConfig,
ActivationFormConfig,
CancellationFormConfig,
frozenFormConfig,
thawFormConfig,
ResourcePoolFormConfig
}
<template>
<div class="app-container">
<ele-search
:columns="tableConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<div class="table-container">
<TableBtns>
<template v-slot:left>
<el-button
type="primary"
icon="el-icon-plus"
@click="handleAdd"
>添加</el-button>
<el-button
plain
icon="el-icon-document"
@click="handleAddTask(config.supervise)"
>
督办
</el-button>
<el-button
plain
icon="el-icon-user"
>转资源池</el-button>
<el-button
plain
icon="el-icon-refresh"
>同步ERP</el-button>
<export-btn
:expand-params="expandParams"
config-code="customer"
/>
</template>
</TableBtns>
<ele-table
ref="eleTable"
v-bind="tableConfig"
:expand-params="expandParams"
:listeners="tableListeners"
@handleSelectionChange="handleSelectionChange"
/>
<!-- 弹框部分 -->
<ele-form-dialog
:title="dialogTitle"
:form-data="formData"
:request-fn="handleSave"
:visible.sync="dialogFormVisible"
v-bind="formConfig"
:loading="loading"
/>
</div>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
import { customer } from '@/api/customers'
import supervise from '../important-customers/components/record-info/components/supervise/constant'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
tableConfig: constant.tableConfig,
keyCustomerUrl: '/customers/important',
keyCustomerDetailUrl: '/customers/important-detail',
selection: [],
config: {
supervise
},
dialogTitle: '',
dialogFormVisible: false,
formData: {},
formConfig: {
formDesc: {}
},
loading: false
}
},
created() {
this.tableListeners = {
handleCheck: this.handleCheck,
handleEdit: this.handleEdit,
handleDelete: this.handleDelete
}
},
methods: {
handleAdd() {
this.$router.push({
path: this.keyCustomerUrl
})
},
handleCheck(row) {
this.$router.push({
path: this.keyCustomerDetailUrl,
query: {
objectID: row.ObjectID
}
})
},
handleEdit(row) {
this.$router.push({
path: this.keyCustomerUrl,
query: {
objectID: row.ObjectID
}
})
},
handleSelectionChange(selection) {
console.log(selection)
this.selection = selection
},
handleAddTask(constant) {
if (this.selection.length === 0) {
this.$message.warning('请先选择一个客户')
return
}
this.dialogTitle = '添加' + constant.tableConfig.tableTitle
this.postUrl = constant.createUrl
this.formData = {
accountID: this.selection[0].ObjectID
}
this.formConfig = constant.formConfig
this.dialogFormVisible = true
},
handleSave(data) {
this.loading = true
data = this.$translateToC4CData(data)
this.$request(this.postUrl, [data]).then(res => {
this.loading = false
this.dialogFormVisible = false
}).catch(() => {
this.loading = false
})
},
handleDelete(row) {
this.$confirm('此操作将删除该客户, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
const data = {
objectID: row.ObjectID,
ext_CustomerStatus_KUT: '191'
}
this.$request(customer.updateUrl, data).then(res => {
this.$message.success('删除成功')
this.handleSearch()
})
})
}
}
}
</script>
<style lang="scss" scoped>
</style>
import { releaseRecord } from '@/api/customers'
import dictionary from '@/api/dictionary'
const tableConfig = {
url: releaseRecord.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
ReleaseName: {
label: '发布名称',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.ReleaseName)
},
showInSearch: true
},
ReleaseBatch: {
label: '发布批次',
type: 'input',
showInSearch: true
},
ReleaseContent: {
label: '发布内容',
type: 'select'
},
ReleaseStartTime: {
label: '发布开始时间',
showInSearch: true,
type: 'date'
},
ReleaseEndTime: {
label: '发布截止时间',
type: 'input'
},
PublicationResultTime: {
label: '公布结果时间',
type: 'input'
},
ApprovalEndTime: {
label: '审核截止时间',
type: 'input'
},
ApprovalStatus: {
label: '审批状态',
type: 'select',
value: 'ApprovalStatusText',
options: dictionary.approvalStatus
},
CreateName: {
label: '创建人',
type: 'input'
},
CreateOn: {
label: '创建时间',
type: 'input'
}
}
}
const listConfig = {
tableTitle: '客户资源清单',
url: releaseRecord.customerListUrl,
initialParams: {},
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
AccountName: {
label: '客户',
type: 'input',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleCheck(scope.row)
},
props: {
type: 'text'
}
},
scope.row.AccountName)
},
showInSearch: true
}
}
}
const formConfig = {
formDesc: {
code: {
type: 'input',
label: '集团代码',
disabled: true,
required: true
},
name: {
type: 'input',
label: '集团名称',
required: true
},
coreEnterprise: {
type: 'select',
label: '是否核心企业',
isOptions: true,
options: [
{
text: '是',
value: 1
},
{
text: '否',
value: 0
}
]
}
},
rules: {
// name: [{ required: true, message: '请输入集团名称', trigger: 'blur' }],
// code: [{ required: true, message: '请输入集团代码', trigger: 'blur' }]
}
}
export default {
tableConfig,
listConfig,
formConfig
}
<template>
<div class="app-container">
<ele-search
:columns="listConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<div class="table-container">
<form-title :title="listConfig.tableTitle" />
<ele-table
ref="eleTable"
v-bind="listConfig"
:expand-params="expandParams"
:listeners="tableListeners"
/>
</div>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
listConfig: {},
applicationRecordConfig: {},
applyLoading: false,
applyData: {},
applyDialogFormVisible: false,
applyDialogformConfig: constant.applyDialogformConfig
}
},
created() {
constant.listConfig.initialParams.parentObjectID = this.$route.query.objectID
this.listConfig = constant.listConfig
},
methods: {
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<div class="app-container">
<ele-search
:columns="tableConfig.columns"
@handleSearch="handleSearch"
@handleReset="handleReset"
@handleFilter="handleFilter"
/>
<div class="table-container">
<TableBtns>
<template v-slot:left>
<el-button
type="primary"
icon="el-icon-plus"
@click="handleChangeStatus('111')"
>通过</el-button>
<el-button
plain
icon="el-icon-refresh"
@click="handleChangeStatus('121')"
>拒绝</el-button>
</template>
</TableBtns>
<ele-table
ref="eleTable"
v-bind="tableConfig"
:expand-params="expandParams"
:listeners="tableListeners"
@handleSelectionChange="handleSelectionChange"
/>
</div>
</div>
</template>
<script>
import constant from './constant'
import tableMixin from '@/mixins/table'
import { releaseRecord } from '@/api/customers'
export default {
mixins: [tableMixin],
data() {
return {
expandParams: {}, // 筛选条件
tableListeners: {}, // 事件监听对象,供ele-table内部调用
tableConfig: constant.tableConfig
}
},
created() {
this.tableListeners = {
handleCheck: this.handleCheck
}
},
methods: {
handleSelectionChange(selection) {
console.log(selection)
this.selection = selection
},
handleChangeStatus(status) {
const msg = status === '111' ? '通过' : '拒绝'
this.$confirm(`确定该批次申请全部${msg}吗`, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消'
}).then(() => {
var selection = this.selection.map(item => {
return {
objectID: item.ObjectID,
approvalStatus: status
}
})
this.$request(releaseRecord.updateUrl, selection).then(res => {
this.$message.success(`${msg}成功`)
this.$refs.eleTable.handleSearch()
})
})
},
handleCheck(row) {
this.$router.push({
path: '/customers/resource/release-detail',
query: {
objectID: row.ObjectID
}
})
}
}
}
</script>
<style lang="scss" scoped>
</style>
import { address } from '@/api/customers'
import dictionary from '@/api/dictionary'
const tableConfig = {
tableTitle: '地址信息',
url: address.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Ext_CustomerAddressType_KUT: {
label: '地址类型'
},
CountryCode: {
label: '国别',
value: 'CountryCodeText'
},
StateCode: {
label: '省份',
value: 'StateCodeText'
},
City: {
label: '城市'
},
Street: {
label: '区/县'
},
HouseNumber: {
label: '详细地址'
},
SalesArea: {
label: '邮编'
},
Ext_CustomerIsDefault_KUT: {
label: '是否默认'
},
Ext_CustomerAddressNote_KUT: {
label: '备注'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
Ext_CustomerAddressType_KUT: {
type: 'select',
label: '地址类型',
isOptions: true,
options: dictionary.customerAddressType,
layout: 12
},
CountryCode: {
type: 'select',
label: '国别',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
StateCode: {
label: '省份',
type: 'select',
value: 'Ext_CustomerStatus_KUTText',
layout: 12
},
City: {
label: '城市',
type: 'select',
layout: 12
},
Street: {
label: '区/县',
type: 'input',
layout: 12
},
HouseNumber: {
label: '详细地址',
type: 'input',
layout: 12
},
SalesArea: {
label: '邮编',
type: 'input',
layout: 12
},
Ext_CustomerIsDefault_KUT: {
label: '是否默认',
type: 'input',
layout: 12
},
Ext_CustomerAddressNote_KUT: {
label: '备注',
type: 'date',
attrs: {
type: 'year'
},
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...address
}
<template>
<div>
<Title :title="title" />
<AddressTable />
<div class="submit-btn">
<el-button
type="primary"
icon="el-icon-back"
@click="handlePrev"
>
上一步,完善项目信息
</el-button>
<el-button
type="primary"
icon="el-icon-right"
@click="handleNext"
>下一步,完善联系人信息</el-button>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import AddressTable from './table.vue'
import constant from './constant'
const tableTitle = constant.tableConfig.tableTitle
export default {
components: {
Title,
AddressTable
},
data() {
return {
title: '创建企业客户-' + tableTitle
}
},
methods: {
handlePrev() {
this.$emit('changeComponent', 'projectInfo')
},
handleNext() {
this.$emit('changeComponent', 'contactsInfo')
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import { customer } from '@/api/customers'
// 潜在客户主列表配置
const tableConfig = {
url: customer.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Name: {
label: '审批类型'
},
Ext_CustomerType_KUT: {
label: '审批人'
},
Ext_CustomerStatus_KUT: {
label: '审批职位'
},
Namexxx: {
label: '审批状态'
},
Mobile: {
label: '审批意见'
},
Ext_CustomerFollowUpDate_KUT: {
label: '审批时间'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h('div', {}, [
h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row)
},
class: 'el-icon-edit',
props: {
type: 'text'
}
},
'审批通过'),
scope.row.Ext_CustomerStatus_KUT === '101' && h(
'el-button',
{
on: {
click: (e) => listeners.handleDelete(scope.row)
},
class: 'el-icon-delete',
props: {
type: 'text'
}
},
'审批否决')
])
}
}
}
}
export default {
tableConfig
}
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import dictionary from '@/api/dictionary'
const formConfig = {
labelPosition: 'left',
isShowBackBtn: false,
isShowSubmitBtn: true,
rules: {
// Name: {
// trigger: 'blur',
// validator: function(rule, value, callback) {
// if (this.formData.Ext_CustomerIsRepeatability_KUT === true) {
// return callback(new Error('客户名称重复'))
// } else {
// return callback()
// }
// }
// }
},
formDesc: {
Name: {
type: 'input',
label: '客户名称',
layout: 12,
required: true
},
Ext_CustomerSocialUnifiedCreditCode_KUT: {
type: 'input',
label: '社会统一信用代码',
layout: 12
},
Ext_CustomerIsRepeatability_KUT: {
type: 'radio',
label: '进行重复性校验',
isOptions: true,
options: [
{
text: '是',
value: true
},
{
text: '否',
value: false
}
],
layout: 12,
default: true
},
key_btn: {
type: 'button',
default: '重复性校验',
layout: 12,
attrs: {
type: 'primary'
}
},
Ext_CustomerEnglishName_KUT: {
type: 'input',
label: '英文名称',
layout: 12
},
Ext_CustomerType_KUT: {
type: 'select',
label: '客户类型',
isOptions: true,
options: [
{
text: '直销客户',
value: '101'
},
{
text: '代理商客户',
value: '111'
}
],
layout: 12
},
CountryCode: {
type: 'select',
label: '客户国别',
isOptions: true,
options: dictionary.countryCode,
attrs: {
filterable: true
},
layout: 12
},
Ext_CustomerContinent_KUT: {
type: 'select',
label: '所在大洲',
isOptions: true,
options: dictionary.customerContinent,
layout: 12
},
Ext_CustomerStatus_KUT: {
type: 'select',
label: '客户状态',
isOptions: true,
disabled: true,
default: '101',
options: dictionary.customerStatus,
layout: 12
},
Ext_CustomerAccountManagerID_KUT: {
type: 'select',
label: '客户经理',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
ParentAccountID: {
type: 'select',
label: '上级客户',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
Ext_CustomerAgentPMID_KUT: {
type: 'select',
label: '代理商',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
Ext_CustomerIsRepeatability_KU111: {
type: 'radio',
label: '重要客户',
isOptions: true,
options: [
{
text: '是',
value: true
},
{
text: '否',
value: false
}
],
layout: 12,
default: true
},
Ext_CustomerFilingInstructions_KUT: {
type: 'textarea',
label: '报备说明',
attrs: {
autosizeType: 'switch',
autosize: false,
rows: 3
}
},
Ext_CustomerNote_KUT: {
type: 'textarea',
label: '备注信息',
attrs: {
autosizeType: 'switch',
autosize: false,
rows: 3
}
}
}
}
export default {
formConfig
}
<template>
<div>
<Title :title="title">
<span>*</span>为必填项
</Title>
<div class="form-container">
<form-title :title="formTitle" />
<ele-form
ref="form"
v-model="formData"
v-bind="formConfig"
>
<template v-slot:key_btn="{ desc, data, field, formData }">
<el-button
type="primary"
@click="handleCheckRepeat(formData)"
>进行重复性校验</el-button>
</template>
<template v-slot:form-btn>
<el-button
type="primary"
icon="el-icon-right"
:loading="loading"
@click="handleSubmit"
>保存,下一步,完善行业信息</el-button>
</template>
</ele-form>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import constant from './constant.js'
import { addPotentialCustomer, updatePotentialCustomer } from '@/api/customers'
export default {
name: 'EnterpriseCustomersBaseInfo',
components: {
Title
},
props: {
formData: {
type: Object,
default: () => { }
}
},
data() {
return {
title: '创建正式客户-基础信息',
formTitle: '基础信息',
loading: false,
formConfig: constant.formConfig
}
},
watch: {
formData(val) {
this.originData = JSON.stringify(val)
}
},
created() {
this.$emit('changeTitle', this.title)
},
methods: {
async handleSubmit() {
await this.$refs.form.validate()
this.loading = true
if (this.$route.query.objectID) {
if (JSON.stringify(this.formData) !== this.originData) {
this.handleEdit()
} else {
this.loading = false
this.handleNext()
}
} else {
this.handleAdd()
}
},
handleAdd() {
const formData = this.$translateToC4CData(this.formData)
// 正式客户roleCode默认是'BUP002'
formData.roleCode = 'CRM000'
delete formData.key_btn
// 新建接口是基于批量新增设计的,所以要用数组包裹formData传值
addPotentialCustomer([formData]).then(res => {
console.log(res)
this.loading = false
const objectID = res.results[0]
this.$router.push({
path: '/customers/important',
query: { objectID }
})
this.handleNext()
})
},
handleEdit() {
const formData = this.$translateToC4CData(this.formData)
updatePotentialCustomer(formData).then(res => {
this.loading = false
this.handleNext()
})
},
handleCheckRepeat(data) {
},
handleNext() {
this.originData = JSON.stringify(this.formData)
this.$emit('changeComponent', 'industryInfo')
}
}
}
</script>
<style>
</style>
import dictionary from '@/api/dictionary'
import { billing } from '@/api/customers'
// import { fetchFirstLevelClassification, fetchSecondLevelClassification, fetchThirdLevelClassification } from '@/api/customers'
const tableConfig = {
tableTitle: '开票信息',
url: billing.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
BillingType: {
label: '开票类型'
},
CompanyName: {
label: '单位'
},
DetailedAddress: {
label: '地址'
},
TaxpayerIdentificationNumber: {
label: '纳税人识别号'
},
DepositBank: {
label: '开户行'
},
BankNumber: {
label: '账号'
},
Phone: {
label: '电话'
},
TradeName: {
label: '商品名称'
},
Unit: {
label: '单位'
},
Currency: {
label: '货币'
},
TaxRate: {
label: '税率'
},
IsDefault: {
label: '是否默认'
},
Note: {
label: '备注'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
BillingType: {
type: 'select',
label: '开票类型',
isOptions: true,
options: dictionary.BillingType,
required: true,
layout: 12
},
CompanyName: {
type: 'input',
label: '公司名称',
layout: 12
},
DetailedAddress: {
label: '地址',
type: 'input',
layout: 12
},
TaxpayerIdentificationNumber: {
label: '纳税人识别号',
type: 'input',
layout: 12
},
DepositBank: {
label: '开户行',
type: 'input',
layout: 12
},
BankNumber: {
label: '账号',
type: 'input',
layout: 12
},
Phone: {
label: '电话',
type: 'input',
layout: 12
},
TradeName: {
label: '商品名称',
type: 'input',
layout: 12
},
Unit: {
label: '单位',
type: 'select',
isOptions: true,
options: dictionary.Unit,
layout: 12
},
Currency: {
label: '货币',
type: 'select',
isOptions: true,
options: dictionary.Currency,
layout: 12
},
TaxRate: {
label: '税率',
type: 'input',
layout: 12
},
IsDefault: {
label: '是否默认',
type: 'input',
layout: 12
},
Note: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...billing
}
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
<template>
<div>
<Title :title="title" />
<TabsTable />
<div class="submit-btn">
<el-button
type="primary"
icon="el-icon-back"
@click="handlePrev"
>
上一步,完善联系人信息
</el-button>
<el-button
type="primary"
icon="el-icon-right"
@click="handleNext"
>关闭</el-button>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import TabsTable from './table.vue'
export default {
components: {
Title,
TabsTable
},
data() {
return {
title: '创建个人客户-项目信息'
}
},
methods: {
handlePrev() {
this.$emit('changeComponent', 'contactsInfo')
},
handleNext() {
}
}
}
</script>
<style lang="scss" scoped>
</style>
import { project, fetchFirstLevelClassification, fetchSecondLevelClassification, fetchThirdLevelClassification } from '@/api/customers'
import dictionary from '@/api/dictionary'
const tableConfig = {
tableTitle: '生产型项目',
url: project.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
ProjectType: {
label: '项目类型'
},
levelOneClassification: {
label: '一级分类'
},
levelTwoClassification: {
label: '二级分类'
},
levelThreeClassification: {
label: '三级分类'
},
TerminalProducts: {
label: '终端产品'
},
ProductsType: {
label: '产品型号'
},
PCS: {
label: '年用量预估(PCS)'
},
ProductIntroduction: {
label: '项目介绍'
},
ExpectStartTime: {
label: '预计启动时间'
},
ExpectCompletionTime: {
label: '预计完成时间'
},
OriginalProductsCompanyOne: {
label: '原用产品公司1'
},
OriginalProductsTypeOne: {
label: '原用产品型号1'
},
OriginalProductsCompanyTwo: {
label: '原用产品公司2'
},
OriginalProductsTypeTwo: {
label: '原用产品型号2'
},
OriginalProductsCompanyThree: {
label: '原用产品公司3'
},
OriginalProductsTypeThree: {
label: '原用产品型号3'
},
MainlyRepresentCustomers: {
label: '主要代表客户'
},
Note: {
label: '备注'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
ProjectType: {
type: 'select',
label: '项目类型',
isOptions: true,
options: dictionary.customerProjectType,
layout: 12
},
levelOneClassification: {
type: 'select',
label: '一级分类',
isOptions: true,
options: async data => {
const res = await fetchFirstLevelClassification()
var result = res.results.map(item => {
return {
text: item.LevelOneClassificationName,
value: item.LevelOneClassificationID
}
})
return result
},
layout: 12
},
levelTwoClassification: {
type: 'select',
label: '二级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification'],
options: async data => {
if (!data.levelOneClassification) {
return []
}
const res = await fetchSecondLevelClassification({
levelOneClassificationID: data.levelOneClassification
})
var result = res.results.map(item => {
return {
text: item.LevelTwoClassificationName,
value: item.LevelTwoClassificationID
}
})
return result
},
layout: 12
},
levelThreeClassification: {
type: 'select',
label: '三级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification', 'levelTwoClassification'],
options: async data => {
if (!data.levelTwoClassification) {
return []
}
const res = await fetchThirdLevelClassification({
levelTwoClassificationID: data.levelTwoClassification
})
var result = res.results.map(item => {
return {
text: item.LevelThreeClassificationName,
value: item.LevelThreeClassificationID
}
})
return result
},
layout: 12
},
TerminalProducts: {
label: '终端产品',
type: 'select',
layout: 12
},
ProductsType: {
label: '产品型号',
type: 'input',
layout: 12
},
PCS: {
label: '年用量预估(PCS)',
type: 'input',
layout: 12
},
ProductIntroduction: {
label: '项目介绍',
type: 'input',
layout: 12
},
ExpectStartTime: {
label: '预计启动时间',
type: 'input',
layout: 12
},
ExpectCompletionTime: {
label: '预计完成时间',
type: 'date',
attrs: {
type: 'year'
},
layout: 12
},
OriginalProductsCompanyOne: {
label: '原用产品公司1',
type: 'input',
layout: 12
},
OriginalProductsTypeOne: {
label: '原用产品型号1',
type: 'input',
layout: 12
},
OriginalProductsCompanyTwo: {
label: '原用产品公司2',
type: 'input',
layout: 12
},
OriginalProductsTypeTwo: {
label: '原用产品型号2',
type: 'input',
layout: 12
},
OriginalProductsCompanyThree: {
label: '原用产品公司3',
type: 'input',
layout: 12
},
OriginalProductsTypeThree: {
label: '原用产品型号3',
type: 'input',
layout: 12
},
MainlyRepresentCustomers: {
label: '主要代表客户',
type: 'input',
layout: 12
},
Note: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...project
}
<template>
<div>
<BusinessTable v-bind="constant" />
<BusinessTable v-bind="constant" />
<BusinessTable v-bind="constant" />
<BusinessTable v-bind="constant" />
</div>
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID,
projectType: '111'
}
this.constant = constant
}
}
</script>
<style>
</style>
import { project, fetchFirstLevelClassification, fetchSecondLevelClassification, fetchThirdLevelClassification } from '@/api/customers'
import dictionary from '@/api/dictionary'
const tableConfig = {
tableTitle: '研究型项目',
url: project.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
ProjectType: {
label: '项目类型'
},
levelOneClassification: {
label: '一级分类'
},
levelTwoClassification: {
label: '二级分类'
},
levelThreeClassification: {
label: '三级分类'
},
TerminalProducts: {
label: '终端产品'
},
ProductsType: {
label: '产品型号'
},
PCS: {
label: '年用量预估(PCS)'
},
ProductIntroduction: {
label: '项目介绍'
},
ExpectStartTime: {
label: '预计启动时间'
},
ExpectCompletionTime: {
label: '预计完成时间'
},
Note: {
label: '备注'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
ProjectType: {
type: 'select',
label: '项目类型',
isOptions: true,
options: dictionary.customerProjectType,
layout: 12
},
levelOneClassification: {
type: 'select',
label: '一级分类',
isOptions: true,
options: async data => {
const res = await fetchFirstLevelClassification()
var result = res.results.map(item => {
return {
text: item.LevelOneClassificationName,
value: item.LevelOneClassificationID
}
})
return result
},
layout: 12
},
levelTwoClassification: {
type: 'select',
label: '二级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification'],
options: async data => {
if (!data.levelOneClassification) {
return []
}
const res = await fetchSecondLevelClassification({
levelOneClassificationID: data.levelOneClassification
})
var result = res.results.map(item => {
return {
text: item.LevelTwoClassificationName,
value: item.LevelTwoClassificationID
}
})
return result
},
layout: 12
},
levelThreeClassification: {
type: 'select',
label: '三级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification', 'levelTwoClassification'],
options: async data => {
if (!data.levelTwoClassification) {
return []
}
const res = await fetchThirdLevelClassification({
levelTwoClassificationID: data.levelTwoClassification
})
var result = res.results.map(item => {
return {
text: item.LevelThreeClassificationName,
value: item.LevelThreeClassificationID
}
})
return result
},
layout: 12
},
TerminalProducts: {
label: '终端产品',
type: 'select',
layout: 12
},
ProductsType: {
label: '产品型号',
type: 'input',
layout: 12
},
PCS: {
label: '年用量预估(PCS)',
type: 'input',
layout: 12
},
ProductIntroduction: {
label: '项目介绍',
type: 'input',
layout: 12
},
ExpectStartTime: {
label: '预计启动时间',
type: 'input',
layout: 12
},
ExpectCompletionTime: {
label: '预计完成时间',
type: 'date',
attrs: {
type: 'year'
},
layout: 12
},
Note: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...project
}
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID,
projectType: '101'
}
this.constant = constant
}
}
</script>
<style>
</style>
<template>
<div class="tab-container">
<el-tabs type="border-card">
<el-tab-pane
label="生成型项目"
:lazy="true"
>
<ProductProjectTable />
</el-tab-pane>
<el-tab-pane
label="研究型项目"
:lazy="true"
>
<ResearchProjectTable />
</el-tab-pane>
</el-tabs>
</div>
</template>
<script>
import ProductProjectTable from './product-table'
import ResearchProjectTable from './research-table'
export default {
components: {
ProductProjectTable,
ResearchProjectTable
}
}
</script>
<style lang="scss" scoped>
.tab-container {
padding: 20px;
background: #fff;
}
</style>>
import dictionary from '@/api/dictionary'
import { industry, fetchFirstLevelClassification, fetchSecondLevelClassification, fetchThirdLevelClassification } from '@/api/customers'
const tableConfig = {
tableTitle: '商机信息',
url: industry.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Name: {
label: '商机名称'
},
levelOneClassification: {
label: '一级分类'
},
levelTwoClassification: {
label: '二级分类'
},
levelThreeClassification: {
label: '三级分类'
},
MainProduct: {
label: '终端产品'
},
MainProduct1: {
label: '是否为重点项目'
},
MainBusinessSituation: {
label: '初始年用量预估(PCS)'
},
PCS: {
label: '项目介绍'
},
AnnualSales: {
label: '预计启动时间'
},
SalesArea: {
label: '预计完成时间'
},
MarketShare: {
label: '当前项目阶段'
},
Year: {
label: '项目状态'
},
Note: {
label: '项目类型'
},
Note2: {
label: '销售区域'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
Name: {
type: 'input',
label: '商机名称',
required: true
},
levelOneClassification: {
type: 'select',
label: '一级分类',
isOptions: true,
options: async data => {
const res = await fetchFirstLevelClassification()
var result = res.results.map(item => {
return {
text: item.LevelOneClassificationName,
value: item.LevelOneClassificationID
}
})
return result
},
layout: 12
},
levelTwoClassification: {
type: 'select',
label: '二级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification'],
options: async data => {
if (!data.levelOneClassification) {
return []
}
const res = await fetchSecondLevelClassification({
levelOneClassificationID: data.levelOneClassification
})
var result = res.results.map(item => {
return {
text: item.LevelTwoClassificationName,
value: item.LevelTwoClassificationID
}
})
return result
},
layout: 12
},
levelThreeClassification: {
type: 'select',
label: '三级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification', 'levelTwoClassification'],
options: async data => {
if (!data.levelTwoClassification) {
return []
}
const res = await fetchThirdLevelClassification({
levelTwoClassificationID: data.levelTwoClassification
})
var result = res.results.map(item => {
return {
text: item.LevelThreeClassificationName,
value: item.LevelThreeClassificationID
}
})
return result
},
layout: 12
},
MainProduct: {
label: '主要产品',
type: 'input',
value: 'Ext_CustomerStatus_KUTText',
layout: 12
},
MainBusinessSituation: {
label: '主要业务情况',
type: 'input',
layout: 12
},
PCS: {
label: '年销售量(PCS)',
type: 'input',
layout: 12
},
AnnualSales: {
label: '年销售额(万元)',
type: 'input',
layout: 12
},
SalesArea: {
label: '销售区域',
type: 'select',
options: dictionary.customerSalesArea,
layout: 12
},
MarketShare: {
label: '市场份额占比',
type: 'input',
layout: 12
},
Year: {
label: '年份',
type: 'input',
attrs: {
type: 'year'
},
layout: 12
},
Note: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...industry
}
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import { contact } from '@/api/customers'
const tableConfig = {
tableTitle: '联系人信息',
url: contact.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Ext_CustomerRole_KUT: {
label: '角色'
},
Name: {
label: '联系人名称'
},
JobTitle: {
label: '职位'
},
Ext_CustomerPhone_KUT: {
label: '电话'
},
Email: {
label: '电子邮箱'
},
Ext_CustomerMainContact_KUT: {
label: '是否主要联系人'
},
Ext_CustomerWeChat_KUT: {
label: '微信'
},
Ext_CustomerQQ_KUT: {
label: 'QQ'
},
Mobile: {
label: '手机'
},
Address: {
label: '地址'
},
Ext_CustomerNote_KUT: {
label: '备注'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
Ext_CustomerRole_KUT: {
type: 'select',
label: '角色',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
Name: {
type: 'select',
label: '联系人名称',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
JobTitle: {
label: '职位',
type: 'select',
value: 'Ext_CustomerStatus_KUTText',
layout: 12
},
Ext_CustomerPhone_KUT: {
label: '电话',
type: 'select',
layout: 12
},
Email: {
label: '电子邮箱',
type: 'input',
layout: 12
},
Ext_CustomerMainContact_KUT: {
label: '是否主要联系人',
type: 'input',
layout: 12
},
Ext_CustomerWeChat_KUT: {
label: '微信',
type: 'input',
layout: 12
},
Ext_CustomerQQ_KUT: {
label: 'QQ',
type: 'input',
layout: 12
},
Mobile: {
label: '手机',
type: 'date',
attrs: {
type: 'year'
},
layout: 12
},
Address: {
label: '地址',
type: 'input',
layout: 12
},
Ext_CustomerNote_KUT: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...contact
}
<template>
<div>
<Title :title="title" />
<ContactTable />
<div class="submit-btn">
<el-button
type="primary"
icon="el-icon-back"
@click="handlePrev"
>
上一步,完善地址信息
</el-button>
<el-button
type="primary"
icon="el-icon-right"
@click="handleNext"
>下一步,完善附件信息</el-button>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import ContactTable from './table.vue'
import constant from './constant'
const tableTitle = constant.tableConfig.tableTitle
export default {
components: {
Title,
ContactTable
},
data() {
return {
title: '创建企业客户-' + tableTitle
}
},
methods: {
handlePrev() {
this.$emit('changeComponent', 'addressInfo')
},
handleNext() {
this.$emit('changeComponent', 'fileInfo')
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import dictionary from '@/api/dictionary'
import { industry, fetchFirstLevelClassification, fetchSecondLevelClassification, fetchThirdLevelClassification } from '@/api/customers'
const tableConfig = {
tableTitle: '合同信息',
url: industry.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Name: {
label: '合同编码'
},
levelOneClassification: {
label: '合同名称'
},
levelTwoClassification: {
label: '客户名称'
},
levelThreeClassification: {
label: '状态'
},
MainProduct: {
label: '签署日期'
},
MainProduct1: {
label: '开始日期'
},
MainBusinessSituation: {
label: '结束日期'
},
PCS: {
label: '创建日期'
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
Name: {
type: 'input',
label: '商机名称',
required: true
},
levelOneClassification: {
type: 'select',
label: '一级分类',
isOptions: true,
options: async data => {
const res = await fetchFirstLevelClassification()
var result = res.results.map(item => {
return {
text: item.LevelOneClassificationName,
value: item.LevelOneClassificationID
}
})
return result
},
layout: 12
},
levelTwoClassification: {
type: 'select',
label: '二级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification'],
options: async data => {
if (!data.levelOneClassification) {
return []
}
const res = await fetchSecondLevelClassification({
levelOneClassificationID: data.levelOneClassification
})
var result = res.results.map(item => {
return {
text: item.LevelTwoClassificationName,
value: item.LevelTwoClassificationID
}
})
return result
},
layout: 12
},
levelThreeClassification: {
type: 'select',
label: '三级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification', 'levelTwoClassification'],
options: async data => {
if (!data.levelTwoClassification) {
return []
}
const res = await fetchThirdLevelClassification({
levelTwoClassificationID: data.levelTwoClassification
})
var result = res.results.map(item => {
return {
text: item.LevelThreeClassificationName,
value: item.LevelThreeClassificationID
}
})
return result
},
layout: 12
},
MainProduct: {
label: '主要产品',
type: 'input',
value: 'Ext_CustomerStatus_KUTText',
layout: 12
},
MainBusinessSituation: {
label: '主要业务情况',
type: 'input',
layout: 12
},
PCS: {
label: '年销售量(PCS)',
type: 'input',
layout: 12
},
AnnualSales: {
label: '年销售额(万元)',
type: 'input',
layout: 12
},
SalesArea: {
label: '销售区域',
type: 'select',
options: dictionary.customerSalesArea,
layout: 12
},
MarketShare: {
label: '市场份额占比',
type: 'input',
layout: 12
},
Year: {
label: '年份',
type: 'input',
attrs: {
type: 'year'
},
layout: 12
},
Note: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...industry
}
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import dictionary from '@/api/dictionary'
const formConfig = {
labelPosition: 'left',
isShowBackBtn: false,
isShowSubmitBtn: false,
rules: {
// Name: {
// trigger: 'blur',
// validator: function(rule, value, callback) {
// if (this.formData.Ext_CustomerIsRepeatability_KUT === true) {
// return callback(new Error('客户名称重复'))
// } else {
// return callback()
// }
// }
// }
},
formDesc: {
Ext_CustomerSocialUnifiedCreditCode_KUT: {
type: 'input',
label: '社会统一信用代码',
layout: 12,
required: true
},
Ext_CustomerListedCompanyCode_KUT: {
type: 'input',
label: '上市公司代码',
layout: 12
},
Ext_CustomerCompanyName_KUT: {
type: 'radio',
label: '公司名称',
isOptions: true,
options: [
{
text: '是',
value: true
},
{
text: '否',
value: false
}
],
layout: 12,
default: true
},
Ext_CustomerRegisteredCapital_KUT: {
type: 'input',
label: '注册资本',
layout: 12
},
Ext_CustomerRegistrationNumber_KUT: {
type: 'input',
label: '注册号',
layout: 12
},
Ext_CustomerEnterprisesTypes_KUT: {
type: 'select',
label: '企业类型',
isOptions: true,
options: dictionary.countryCode,
attrs: {
filterable: true
},
layout: 12
},
Ext_CustomerRegistrationAuthority_KUT: {
type: 'select',
label: '登记机关',
isOptions: true,
options: dictionary.customerForm,
layout: 12
},
Ext_CustomerExperienceRange_KUT: {
type: 'select',
label: '经验范围',
isOptions: true,
options: dictionary.customerContinent,
layout: 12
},
Ext_CustomerCorporateName_KUT: {
type: 'select',
label: '法人名',
isOptions: true,
options: dictionary.customerType,
layout: 12
},
Ext_CustomerOpeningTime_KUT: {
type: 'select',
label: '营业开始日期',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
Ext_CustomerOldName_KUT: {
type: 'radio',
label: '曾用名',
isOptions: true,
options: [
{
text: '是',
value: true
},
{
text: '否',
value: false
}
],
layout: 12
},
Ext_CustomerClosingTime_KUT: {
type: 'input',
label: '营业结束日期',
attrs: {
autosizeType: 'switch',
autosize: false,
rows: 3
}
},
Ext_CustomerIncorporationDate_KUT: {
type: 'input',
label: '成立日期',
layout: 12
},
Ext_CustomerLssuingLicenseDate_KUT: {
type: 'input',
label: '发照日期',
layout: 12
},
Ext_CustomerRevocationDate_KUT: {
type: 'input',
label: '吊销日期',
layout: 12
},
Ext_CustomerOrganizationStructureCode_KUT: {
type: 'input',
label: '组织机构代码',
layout: 12
},
Ext_CustomerEnterpriseStatus_KUT: {
type: 'input',
label: '企业状态',
layout: 12
},
Ext_CustomerIsListed_KUT: {
type: 'input',
label: '是否上市',
layout: 12
},
Ext_CustomerProvince_KUT: {
type: 'input',
label: '省份',
layout: 12
},
Ext_CustomerBeListedType_KUT: {
type: 'input',
label: '上市类型',
layout: 12
},
Ext_CustomerUpdateDate_KUT: {
type: 'input',
label: '更新日期',
layout: 12
},
Ext_CustomerEnterpriseScale_KUT: {
type: 'input',
label: '企业规模',
layout: 12
},
Ext_CustomerLandline_KUT: {
type: 'input',
label: '座机',
layout: 12
},
Ext_CustomerWebURL_KUT: {
type: 'input',
label: '官方地址',
layout: 12
},
Ext_CustomerEnterpriseIntroduction_KUT: {
type: 'textarea',
label: '企业介绍',
attrs: {
autosizeType: 'switch',
autosize: false,
rows: 3
}
}
}
}
export default {
formConfig
}
<template>
<div>
<Title :title="title">
<el-button
type="primary"
icon="el-icon-download"
:loading="loading"
@click="handleNext"
>从企查查获取企业工商信息</el-button>
</Title>
<div class="form-container">
<form-title :title="formTitle" />
<ele-form
ref="form"
v-model="formData"
v-bind="formConfig"
:request-fn="handleRequest"
@request-success="handleRequestSuccess"
/>
<div class="submit-btn">
<el-button
type="primary"
icon="el-icon-back"
@click="handlePrev"
>
上一步,完善附件信息
</el-button>
<el-button
type="primary"
icon="el-icon-check"
@click="handleNext"
>确认提交</el-button>
</div>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import FormTitle from '@/components/FormTitle'
import constant from './constant.js'
// import { addPotentialCustomer } from '@/api/customers'
export default {
name: 'EnterpriseCustomersBaseInfo',
components: {
Title,
FormTitle
},
data() {
return {
title: '创建企业客户-基础信息',
formTitle: '基础信息',
loading: false,
formData: {},
formConfig: constant.formConfig
}
},
methods: {
handleRequest(data) {
console.log(data)
return Promise.resolve()
},
handleRequestSuccess() {
this.$message.success('发送成功')
},
async handleNext() {
await this.$refs.form.validate()
this.$emit('changeComponent', 'industryInfo')
return
// this.loading = true
// const formData = JSON.parse(JSON.stringify(this.formData))
// formData.RoleCode = 'BUP002'
// delete formData.key_btn
// addPotentialCustomer(formData).then(res => {
// console.log(res)
// this.loading = false
// this.$emit('changeComponent', 'industryInfo')
// })
},
handlePrev() {
this.$emit('changeComponent', 'fileInfo')
}
}
}
</script>
<style>
</style>
// import { file } from '@/api/customers'
const tableConfig = {
tableTitle: '附件信息',
url: '',
showPagination: false,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Title: {
label: '标题'
},
TypeCode: {
label: '类型'
},
CreatedBy: {
label: '创建人'
},
CreatedOn: {
label: '创建时间'
},
Note: {
label: '备注'
},
URL: {
label: '附件'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
Title: {
type: 'select',
label: '标题',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
TypeCode: {
type: 'select',
label: '类型',
isOptions: true,
options: [
{
text: '选项1',
value: 1
},
{
text: '选项2',
value: 2
},
{
text: '选项3',
value: 3
}
],
layout: 12
},
Note: {
label: '备注',
type: 'textarea'
},
URL: {
label: '附件',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig
}
<template>
<div>
<Title :title="title" />
<FileTable />
<div class="submit-btn">
<el-button
type="primary"
icon="el-icon-back"
@click="handlePrev"
>
上一步,完善联系人信息
</el-button>
<el-button
type="primary"
icon="el-icon-right"
@click="handleNext"
>保存,下一步,完善企业工商信息</el-button>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import FileTable from './table.vue'
import constant from './constant'
const tableTitle = constant.tableConfig.tableTitle
export default {
components: {
Title,
FileTable
},
data() {
return {
title: '创建企业客户-' + tableTitle
}
},
created() {
this.tableListeners = {
handleEdit: this.handleEdit
}
},
methods: {
handlePrev() {
this.$emit('changeComponent', 'contactsInfo')
},
handleNext() {
this.$emit('changeComponent', 'enterpriseInfo')
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import dictionary from '@/api/dictionary'
import { industry, fetchFirstLevelClassification, fetchSecondLevelClassification, fetchThirdLevelClassification } from '@/api/customers'
const tableConfig = {
tableTitle: '行业信息',
url: industry.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
levelOneClassification: {
label: '一级分类'
},
levelTwoClassification: {
label: '二级分类'
},
levelThreeClassification: {
label: '三级分类'
},
MainProduct: {
label: '主要产品'
},
MainBusinessSituation: {
label: '主要业务情况'
},
PCS: {
label: '年销售量(PCS)'
},
AnnualSales: {
label: '年销售额(万元)'
},
SalesArea: {
label: '销售区域'
},
MarketShare: {
label: '市场份额占比'
},
Year: {
label: '年份'
},
Note: {
label: '备注'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
levelOneClassification: {
type: 'select',
label: '一级分类',
isOptions: true,
options: async data => {
const res = await fetchFirstLevelClassification()
var result = res.results.map(item => {
return {
text: item.LevelOneClassificationName,
value: item.LevelOneClassificationID
}
})
return result
},
layout: 12
},
levelTwoClassification: {
type: 'select',
label: '二级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification'],
options: async data => {
if (!data.levelOneClassification) {
return []
}
const res = await fetchSecondLevelClassification({
levelOneClassificationID: data.levelOneClassification
})
var result = res.results.map(item => {
return {
text: item.LevelTwoClassificationName,
value: item.LevelTwoClassificationID
}
})
return result
},
layout: 12
},
levelThreeClassification: {
type: 'select',
label: '三级分类',
isOptions: true,
optionsLinkageFields: ['levelOneClassification', 'levelTwoClassification'],
options: async data => {
if (!data.levelTwoClassification) {
return []
}
const res = await fetchThirdLevelClassification({
levelTwoClassificationID: data.levelTwoClassification
})
var result = res.results.map(item => {
return {
text: item.LevelThreeClassificationName,
value: item.LevelThreeClassificationID
}
})
return result
},
layout: 12
},
MainProduct: {
label: '主要产品',
type: 'input',
value: 'Ext_CustomerStatus_KUTText',
layout: 12
},
MainBusinessSituation: {
label: '主要业务情况',
type: 'input',
layout: 12
},
PCS: {
label: '年销售量(PCS)',
type: 'input',
layout: 12
},
AnnualSales: {
label: '年销售额(万元)',
type: 'input',
layout: 12
},
SalesArea: {
label: '销售区域',
type: 'select',
options: dictionary.customerSalesArea,
layout: 12
},
MarketShare: {
label: '市场份额占比',
type: 'input',
layout: 12
},
Year: {
label: '年份',
type: 'input',
attrs: {
type: 'year'
},
layout: 12
},
Note: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...industry
}
<template>
<div>
<Title :title="title" />
<IndustryTable />
<div class="submit-btn">
<el-button
type="primary"
icon="el-icon-back"
@click="handlePrev"
>
上一步,完善基础信息
</el-button>
<el-button
type="primary"
icon="el-icon-right"
@click="handleNext"
>下一步,完善市场信息</el-button>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import IndustryTable from './table.vue'
import constant from './constant'
const tableTitle = constant.tableConfig.tableTitle
export default {
components: {
Title,
IndustryTable
},
data() {
return {
title: '创建企业客户-' + tableTitle
}
},
methods: {
handlePrev() {
this.$emit('changeComponent', 'baseInfo')
},
handleNext() {
this.$emit('changeComponent', 'marketInfo')
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import { market } from '@/api/customers'
const tableConfig = {
tableTitle: '市场信息',
url: market.searchUrl,
showPagination: false,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
AnnualSales: {
label: '年销售额(万元)'
},
Year: {
label: '年份'
},
Note: {
label: '备注'
},
handle: {
label: '操作',
hideInFilter: true,
fixed: 'right',
renderItem: (h, scope, listeners) => {
return h(
'el-button',
{
on: {
click: (e) => listeners.handleEdit(scope.row, scope.$index)
},
props: {
type: 'text'
}
},
'编辑')
}
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
formDesc: {
AnnualSales: {
type: 'input',
label: '年销售额(万元)',
layout: 12
},
Year: {
type: 'date',
label: '年份',
layout: 12,
attrs: {
type: 'year',
valueFormat: 'yyyy'
}
},
Note: {
label: '备注',
type: 'input',
layout: 12
}
}
}
export default {
tableConfig,
formConfig,
...market
}
<template>
<div>
<Title :title="title" />
<ProjectTable />
<div class="submit-btn">
<el-button
type="primary"
icon="el-icon-back"
@click="handlePrev"
>
上一步,完善行业信息
</el-button>
<el-button
type="primary"
icon="el-icon-right"
@click="handleNext"
>下一步,完善地址信息</el-button>
</div>
</div>
</template>
<script>
import Title from '@/components/Title'
import ProjectTable from './table.vue'
import constant from './constant'
const tableTitle = constant.tableConfig.tableTitle
export default {
components: {
Title,
ProjectTable
},
data() {
return {
title: '创建企业客户-' + tableTitle
}
},
methods: {
handlePrev() {
this.$emit('changeComponent', 'industryInfo')
},
handleNext() {
this.$emit('changeComponent', 'addressInfo')
}
}
}
</script>
<style lang="scss" scoped>
</style>
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
// import dictionary from '@/api/dictionary'
import { industry } from '@/api/customers'
const tableConfig = {
tableTitle: '报价信息',
url: industry.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
Ext_QuoteOppotunity_KUT: {
label: '商机'
},
Ext_QuoteProductModel_KUT: {
label: '产品型号'
},
Ext_QuotePrice_KUTContent_KUT: {
label: '价格'
},
Ext_QuoteUnit_KUT: {
label: '单位'
},
Ext_QuoteMinimaleTransaktionsmenge_KUT: {
label: '最小交易数量'
},
Ext_QuotePrice_KUTcurrencyCode_KUT: {
label: '币别'
},
Ext_QuoteIsTax_KUT: {
label: '是否含税'
},
Ext_QuoteTax_KUT: {
label: '税率'
},
Ext_QuoteStatus_KUT: {
label: '状态'
},
EmployeeResponsiblePartyID: {
label: '报价人'
},
ValidFromDate: {
label: '有效开始时间'
},
ValidToDate: {
label: '有效截止时间'
},
CreationDateTime: {
label: '创建时间'
}
}
}
export default {
tableConfig
}
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
import { followRecord } from '@/api/customers'
const tableConfig = {
tableTitle: '跟进记录',
url: followRecord.searchUrl,
defaultColumns: {
minWidth: 120,
showOverflowTooltip: true,
align: 'center'
},
columns: {
FollowUPRecordPerson: {
label: '跟进人'
},
FollowUPRecord: {
label: '跟进记录'
},
CreateOn: {
label: '创建时间'
}
}
}
const formConfig = {
labelPosition: 'left',
submitBtnText: '保存',
span: 22,
formDesc: {
FollowUPRecord: {
type: 'textarea',
label: '跟进记录',
layout: 24
}
}
}
export default {
tableConfig,
formConfig,
...followRecord
}
<template>
<BusinessTable v-bind="constant" />
</template>
<script>
import constant from './constant'
export default {
data() {
return {
constant: {}
}
},
created() {
// 设置表单的初始搜索条件,该条件一般不会发生改变
constant.tableConfig.initialParams = {
objectID: this.$route.query.objectID
}
this.constant = constant
}
}
</script>
<style>
</style>
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment