|
|
@@ -10,64 +10,67 @@
|
|
|
<el-button
|
|
|
class="el-button--small-yh add-customer-btn"
|
|
|
type="primary"
|
|
|
+ :disabled="disabled"
|
|
|
@click="editCustomer"
|
|
|
>{{form.id?'确认修改':'确认新增'}}
|
|
|
</el-button>
|
|
|
</div>
|
|
|
<div style="margin-top: 60px">
|
|
|
- <el-form :model="form" ref="form" label-width="100px" class="demo-ruleForm">
|
|
|
+ <el-form :model="form" ref="form" label-width="130px" class="demo-ruleForm">
|
|
|
<containerTitle title="基础资料"></containerTitle>
|
|
|
<basic-container style="margin-bottom: 10px">
|
|
|
<el-row>
|
|
|
<el-col v-for="item in basicData.column" :span="item.span?item.span:8">
|
|
|
<el-form-item :label="item.label" :prop="item.prop" :rules="item.rules">
|
|
|
- <avue-input-tree v-if="item.prop === 'corpsTypeId'" leaf-only multiple :props="{label:'title'}" v-model="form[item.prop]" placeholder="请选择内容" type="tree" :dic="dic"
|
|
|
- ></avue-input-tree>
|
|
|
+<!-- <avue-input-tree v-if="item.prop === 'corpsTypeId'" leaf-only multiple :props="{label:'title'}" v-model="form[item.prop]" placeholder="请选择内容" type="tree" :dic="dic"-->
|
|
|
+<!-- ></avue-input-tree>-->
|
|
|
+ <el-date-picker v-if="item.type === 'datetime'" style="width: 100%;" v-model="form[item.prop]" size="small" type="datetime" placeholder="选择日期" value-format="yyyy-MM-dd HH:mm:ss"/>
|
|
|
<el-input type="age" v-else v-model="form[item.prop]" size="small" autocomplete="off"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</basic-container>
|
|
|
- <containerTitle title="联系方式"></containerTitle>
|
|
|
+ <containerTitle title="发货信息"></containerTitle>
|
|
|
<basic-container style="margin-bottom: 10px">
|
|
|
<el-row>
|
|
|
<el-col v-for="item in contactInformation.column" :span="item.span?item.span:8">
|
|
|
<el-form-item :label="item.label" :prop="item.prop" :rules="item.rules">
|
|
|
- <el-input type="age" v-model="form[item.prop]" size="small" autocomplete="off"></el-input>
|
|
|
- </el-form-item>
|
|
|
- </el-col>
|
|
|
- </el-row>
|
|
|
- </basic-container>
|
|
|
- <containerTitle title="财务资料"></containerTitle>
|
|
|
- <basic-container style="margin-bottom: 10px">
|
|
|
- <el-row>
|
|
|
- <el-col v-for="item in financialInformation.column" :span="item.span?item.span:8">
|
|
|
- <el-form-item :label="item.label" :prop="item.prop" :rules="item.rules">
|
|
|
- <el-switch
|
|
|
- v-if="item.prop === 'creditstatus'"
|
|
|
- v-model="form[item.prop]"
|
|
|
- active-value="0"
|
|
|
- inactive-value="1"
|
|
|
- active-text="开启"
|
|
|
- inactive-text="关闭">
|
|
|
- </el-switch>
|
|
|
+ <el-date-picker v-if="item.type === 'datetime'" style="width: 100%;" v-model="form[item.prop]" size="small" type="datetime" placeholder="选择日期" value-format="yyyy-MM-dd HH:mm:ss"/>
|
|
|
<el-input v-else type="age" v-model="form[item.prop]" size="small" autocomplete="off"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</basic-container>
|
|
|
- <containerTitle title="客户联系人"></containerTitle>
|
|
|
+ <containerTitle title="商品信息"></containerTitle>
|
|
|
<basic-container style="margin-bottom: 10px">
|
|
|
<avue-crud
|
|
|
:option="customerContact"
|
|
|
v-model="contactsForm"
|
|
|
:data="contactsData"
|
|
|
+ ref="crudContact"
|
|
|
@row-save="rowSave"
|
|
|
+ @row-click="handleRowClick"
|
|
|
@row-update="rowUpdate"
|
|
|
@row-del="rowDel"
|
|
|
- ></avue-crud>
|
|
|
+ >
|
|
|
+ <template slot-scope="{row,index}" slot="menu">
|
|
|
+ <el-button
|
|
|
+ type="text"
|
|
|
+ size="small"
|
|
|
+ @click="rowCell(row,index)"
|
|
|
+ >{{row.$cellEdit?'保存':'修改'}}</el-button>
|
|
|
+ </template>
|
|
|
+ <template slot="menuLeft" slot-scope="{size}">
|
|
|
+ <el-button type="success"
|
|
|
+ icon="el-icon-edit"
|
|
|
+ size="small"
|
|
|
+ plain
|
|
|
+ @click="dialogVisible = !dialogVisible"
|
|
|
+ >导入</el-button>
|
|
|
+ </template>
|
|
|
+ </avue-crud>
|
|
|
</basic-container>
|
|
|
- <containerTitle title="客户优势项目"></containerTitle>
|
|
|
+ <containerTitle title="费用明细"></containerTitle>
|
|
|
<basic-container style="margin-bottom: 10px">
|
|
|
<avue-crud
|
|
|
:option="advantageProject"
|
|
|
@@ -78,7 +81,7 @@
|
|
|
@row-del="rowDelProject"
|
|
|
></avue-crud>
|
|
|
</basic-container>
|
|
|
- <containerTitle title="客户开户行"></containerTitle>
|
|
|
+ <containerTitle title="附件上传"></containerTitle>
|
|
|
<basic-container style="margin-bottom: 40px">
|
|
|
<avue-crud
|
|
|
:option="bankOfDeposit"
|
|
|
@@ -91,6 +94,41 @@
|
|
|
</basic-container>
|
|
|
</el-form>
|
|
|
</div>
|
|
|
+ <el-dialog
|
|
|
+ title="导入商品"
|
|
|
+ append-to-body
|
|
|
+ class="el-dialogDeep"
|
|
|
+ :visible.sync="dialogVisible"
|
|
|
+ width="80%"
|
|
|
+ :close-on-click-modal="false"
|
|
|
+ :close-on-press-escape="false">
|
|
|
+ <el-row style="height: 0;">
|
|
|
+ <el-col :span="5">
|
|
|
+ <div>
|
|
|
+ <el-scrollbar>
|
|
|
+ <basic-container>
|
|
|
+ <avue-tree :option="treeOption" :data="treeData" @node-click="nodeClick"/>
|
|
|
+ </basic-container>
|
|
|
+ </el-scrollbar>
|
|
|
+ </div>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="19">
|
|
|
+ <basic-container>
|
|
|
+ <avue-crud :option="optionTwo"
|
|
|
+ :table-loading="loading"
|
|
|
+ :data="data"
|
|
|
+ ref="crud"
|
|
|
+ @selection-change="selectionChange"
|
|
|
+ :page.sync="page"
|
|
|
+ @on-load="onLoad"></avue-crud>
|
|
|
+ </basic-container>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ <span slot="footer" class="dialog-footer">
|
|
|
+ <el-button @click="dialogVisible = false">取 消</el-button>
|
|
|
+ <el-button type="primary" @click="importGoods" :disabled="tableData.length>1?true:false">导入</el-button>
|
|
|
+ </span>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
@@ -100,95 +138,127 @@ import {customerList, typeSave, detail, deleteDetails,
|
|
|
corpsattn,
|
|
|
corpsbank,
|
|
|
corpsfiles,
|
|
|
- corpsitem} from "@/api/basicData/customerInformation"
|
|
|
+ corpsitem} from "@/api/basicData/configuration"
|
|
|
import customerContact from "./configuration/customerContact.json"
|
|
|
import advantageProject from "./configuration/advantageProject.json"
|
|
|
import bankOfDeposit from "./configuration/bankOfDeposit.json"
|
|
|
+import commodity from "./configuration/commodity.json"
|
|
|
+import {getDeptLazyTree, getList} from "@/api/basicData/commodityType";
|
|
|
export default {
|
|
|
name: "detailsPage",
|
|
|
data() {
|
|
|
return {
|
|
|
form: {},
|
|
|
+ data:[],
|
|
|
+ page:{
|
|
|
+ pageSize: 10,
|
|
|
+ currentPage: 1,
|
|
|
+ total: 0
|
|
|
+ },
|
|
|
+ loading:false,
|
|
|
contactsForm: {},
|
|
|
+ optionTwo:commodity,
|
|
|
+ treeOption: {
|
|
|
+ nodeKey: 'id',
|
|
|
+ lazy: true,
|
|
|
+ treeLoad: function (node, resolve) {
|
|
|
+ const parentId = (node.level === 0) ? 0 : node.data.id;
|
|
|
+ getDeptLazyTree(parentId).then(res => {
|
|
|
+ resolve(res.data.data.map(item => {
|
|
|
+ return {
|
|
|
+ ...item,
|
|
|
+ leaf: !item.hasChildren
|
|
|
+ }
|
|
|
+ }))
|
|
|
+ });
|
|
|
+ },
|
|
|
+ addBtn: false,
|
|
|
+ menu: false,
|
|
|
+ size: 'small',
|
|
|
+ props: {
|
|
|
+ labelText: '标题',
|
|
|
+ label: 'title',
|
|
|
+ value: 'value',
|
|
|
+ children: 'children'
|
|
|
+ }
|
|
|
+ },
|
|
|
+ dialogVisible:false,
|
|
|
advantageProjectForm: {},
|
|
|
bankOfDepositForm: {},
|
|
|
contactsData: [],
|
|
|
advantageProjectData: [],
|
|
|
+ disabled:false,
|
|
|
bankOfDepositData: [],
|
|
|
dic:[],
|
|
|
+ tableData:[],
|
|
|
customerContact:customerContact,
|
|
|
advantageProject:advantageProject,
|
|
|
bankOfDeposit:bankOfDeposit,
|
|
|
contactInformation: {
|
|
|
column: [
|
|
|
{
|
|
|
- label: '联系人',
|
|
|
- prop: 'attn',
|
|
|
+ label: '销售金额',
|
|
|
+ prop: 'orderAmount',//无
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
- message: '请输入联系人',
|
|
|
+ message: ' ',
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '联系电话',
|
|
|
- prop: 'tel',
|
|
|
+ },{
|
|
|
+ label: '其他费用',
|
|
|
+ prop: 'otherAmount',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
- message: '请输入联系电话',
|
|
|
+ message: ' ',
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '职位',
|
|
|
- prop: 'positoin',
|
|
|
+ },{
|
|
|
+ label: '应收账款',
|
|
|
+ prop: 'debitAmount',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
- message: '请输入联系电话',
|
|
|
+ message: ' ',
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '单位地址',
|
|
|
- prop: 'addr',
|
|
|
+ },{
|
|
|
+ label: '单据状态',
|
|
|
+ prop: 'status1',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
- message: '请输入单位地址',
|
|
|
+ message: ' ',
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '仓库地址',
|
|
|
- prop: 'storageAddr',
|
|
|
+ },{
|
|
|
+ label: '溢付款',
|
|
|
+ prop: 'overPayment',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
- message: '请输入仓库地址',
|
|
|
+ message: ' ',
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '分仓地址',
|
|
|
- prop: 'subStorageAddr',
|
|
|
+ },{
|
|
|
+ label: '应收预付款',
|
|
|
+ prop: 'advancePayment',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
- message: '请输入分仓地址',
|
|
|
+ message: ' ',
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }
|
|
|
- ]
|
|
|
- },
|
|
|
- financialInformation: {
|
|
|
- column: [
|
|
|
- {
|
|
|
- label: '账户名称',
|
|
|
- prop: 'accountName',
|
|
|
+ },{
|
|
|
+ label: '已收款',
|
|
|
+ prop: 'settlmentAmount',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -196,9 +266,9 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '开户银行',
|
|
|
- prop: 'accountBank',
|
|
|
+ },{
|
|
|
+ label: '应收未收款',
|
|
|
+ prop: 'settlmentAmount',//无
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -206,9 +276,9 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '银行帐号',
|
|
|
- prop: 'accountNo',
|
|
|
+ },{
|
|
|
+ label: '保证金',
|
|
|
+ prop: 'deposit',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -216,9 +286,9 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '外币账户名称',
|
|
|
- prop: 'accountNameFcy',
|
|
|
+ },{
|
|
|
+ label: '逾期账款',
|
|
|
+ prop: 'overDueAccounts',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -226,9 +296,10 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '外币开户银行',
|
|
|
- prop: 'accountBankFcy',
|
|
|
+ },{
|
|
|
+ label: '合同日期',
|
|
|
+ prop: 'businesDate',
|
|
|
+ type:'datetime',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -236,9 +307,10 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '外币银行账号',
|
|
|
- prop: 'accountNoFcy',
|
|
|
+ },{
|
|
|
+ label: '实际发货日期',
|
|
|
+ prop: 'actualDeliveryDate',
|
|
|
+ type:'datetime',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -246,9 +318,10 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '授信状态',
|
|
|
- prop: 'creditstatus',
|
|
|
+ },{
|
|
|
+ label: '制单日期',
|
|
|
+ prop: 'createTime',
|
|
|
+ type:'datetime',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -256,9 +329,9 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '授信等级',
|
|
|
- prop: 'creditLevel',
|
|
|
+ },{
|
|
|
+ label: '制单人',
|
|
|
+ prop: 'createUser',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -266,9 +339,9 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '授信额度',
|
|
|
- prop: 'creditGrant',
|
|
|
+ },{
|
|
|
+ label: '毛利率',
|
|
|
+ prop: 'grossProfitRate',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -276,9 +349,9 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '授信天数',
|
|
|
- prop: 'creditDay',
|
|
|
+ },{
|
|
|
+ label: '毛利额',
|
|
|
+ prop: 'grossProfit',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -286,9 +359,61 @@ export default {
|
|
|
trigger: 'blur'
|
|
|
}
|
|
|
]
|
|
|
- }, {
|
|
|
- label: '授信利率',
|
|
|
- prop: 'creditRate',
|
|
|
+ },{
|
|
|
+ label: '所属公司',
|
|
|
+ prop: 'belongToCorpId',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: false,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },{
|
|
|
+ label: '历史运费(元/条)',
|
|
|
+ prop: 'freightAmountHistory',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: false,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },{
|
|
|
+ label: '到货日期',
|
|
|
+ prop: 'arrivalDate',
|
|
|
+ type:'datetime',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: false,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },{
|
|
|
+ label: '预收款日期',
|
|
|
+ type:'datetime',
|
|
|
+ prop: 'advanceCollectionDate',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: false,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },{
|
|
|
+ label: '积分倍数',
|
|
|
+ prop: 'pointMutiple',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: false,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },{
|
|
|
+ label: '特别提醒',
|
|
|
+ prop: 'specialRemarks',
|
|
|
rules: [
|
|
|
{
|
|
|
required: false,
|
|
|
@@ -302,8 +427,8 @@ export default {
|
|
|
basicData: {
|
|
|
column: [
|
|
|
{
|
|
|
- label: '客户编码',
|
|
|
- prop: 'code',
|
|
|
+ label: '销售订单号',
|
|
|
+ prop: 'orderNo',
|
|
|
rules: [
|
|
|
{
|
|
|
required: true,
|
|
|
@@ -312,8 +437,8 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
- label: '代理品牌',
|
|
|
- prop: 'goodtypes',
|
|
|
+ label: '主订单号',
|
|
|
+ prop: 'morderNo',
|
|
|
rules: [
|
|
|
{
|
|
|
required: true,
|
|
|
@@ -322,8 +447,18 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
- label: '所属公司',
|
|
|
- prop: 'belongtocompany',
|
|
|
+ label: '发货地址',
|
|
|
+ prop: 'shippingAddress',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: true,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }, {
|
|
|
+ label: '到货地址',
|
|
|
+ prop: 'arrivalAddress',
|
|
|
rules: [
|
|
|
{
|
|
|
required: true,
|
|
|
@@ -332,8 +467,8 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
- label: '客户名称',
|
|
|
- prop: 'cname',
|
|
|
+ label: '付款方式',
|
|
|
+ prop: 'paymentType',
|
|
|
rules: [
|
|
|
{
|
|
|
required: true,
|
|
|
@@ -342,8 +477,8 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
- label: '客户类别',
|
|
|
- prop: 'corpsTypeId',
|
|
|
+ label: '包装要求',
|
|
|
+ prop: 'packageRemarks',
|
|
|
rules: [
|
|
|
{
|
|
|
required: true,
|
|
|
@@ -352,8 +487,8 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
- label: '企业类型',
|
|
|
- prop: 'companytype',
|
|
|
+ label: '运费',
|
|
|
+ prop: 'packageRemarks',
|
|
|
rules: [
|
|
|
{
|
|
|
required: true,
|
|
|
@@ -362,9 +497,62 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
- label: "代理区域",
|
|
|
+ label: '银行帐号',
|
|
|
+ prop: 'banks',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: true,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }, {
|
|
|
+ label: '要求发货日期',
|
|
|
+ prop: 'requiredDeliveryDate',
|
|
|
+ type:'datetime',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: true,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }, {
|
|
|
+ label: '要求到货日期',
|
|
|
+ prop: 'requiredArrivalDate',
|
|
|
+ type:'datetime',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: true,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }, {
|
|
|
+ label: '公司户头',
|
|
|
+ prop: 'banksAccountName',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: false,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }, {
|
|
|
+ label: '信用证到期日',
|
|
|
+ type:'datetime',
|
|
|
+ prop: 'creditDate',
|
|
|
+ rules: [
|
|
|
+ {
|
|
|
+ required: true,
|
|
|
+ message: ' ',
|
|
|
+ trigger: 'blur'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }, {
|
|
|
+ label: "订单备注",
|
|
|
span: 24,
|
|
|
- prop: "belongtoarea",
|
|
|
+ prop: "orderRemark",
|
|
|
mock: {
|
|
|
type: 'county'
|
|
|
}
|
|
|
@@ -374,21 +562,21 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
created() {
|
|
|
- corpstypeTree().then(res=>{
|
|
|
- this.dic = res.data.data
|
|
|
- })
|
|
|
+ // corpstypeTree().then(res=>{
|
|
|
+ // this.dic = res.data.data
|
|
|
+ // })
|
|
|
if (this.$route.query.id){
|
|
|
let id = this.$route.query.id.replace(/\"/g, "")
|
|
|
// let id = parseInt(this.$route.query.id)
|
|
|
detail(id).then(res => {
|
|
|
console.log(res.data.data)
|
|
|
this.form = res.data.data;
|
|
|
- this.contactsData = this.form.corpsAttnList
|
|
|
- this.bankOfDepositData = this.form.corpsBankList
|
|
|
- this.advantageProjectData = this.form.corpsItems
|
|
|
- delete this.form.corpsAttnList
|
|
|
- delete this.form.corpsBankList
|
|
|
- delete this.form.corpsItems
|
|
|
+ this.contactsData = this.form.orderItemsList
|
|
|
+ this.advantageProjectData = this.form.orderFeesList
|
|
|
+ this.bankOfDepositData = this.form.orderFilesList
|
|
|
+ delete this.form.orderItemsList
|
|
|
+ delete this.form.orderFeesList
|
|
|
+ delete this.form.orderFilesList
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
@@ -407,17 +595,47 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
- //新增客户联系人保存触发
|
|
|
+ //点击行可编辑
|
|
|
+ handleRowClick(row, event, column) {
|
|
|
+ this.$message({
|
|
|
+ showClose: true,
|
|
|
+ message: '序号' + row.$index,
|
|
|
+ type: 'success',
|
|
|
+ });
|
|
|
+ },
|
|
|
+ rowCell(row, index) {
|
|
|
+ console.log(row)
|
|
|
+ this.$refs.crudContact.rowCell(row, index)
|
|
|
+ },
|
|
|
+ //确认导入触发
|
|
|
+ importGoods(){
|
|
|
+ this.contactsData = this.contactsData.concat(this.tableData)
|
|
|
+ this.dialogVisible = false
|
|
|
+ },
|
|
|
+ //选中触发
|
|
|
+ selectionChange(list){
|
|
|
+ console.log(list);
|
|
|
+ this.tableData = list
|
|
|
+ if (list.length > 1){
|
|
|
+ this.$message({
|
|
|
+ showClose: true,
|
|
|
+ message: '警告,只允许导入一条',
|
|
|
+ type: 'warning'
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
+ //新增商品信息保存触发
|
|
|
rowSave(row, done, loading){
|
|
|
- console.log(row,done,loading)
|
|
|
- this.contactsData.push(row)
|
|
|
+ console.log(row)
|
|
|
+ console.log(this.contactsData)
|
|
|
+ // this.contactsData.push(row)
|
|
|
done()
|
|
|
},
|
|
|
- //修改客户联系人触发
|
|
|
+ //修改商品信息触发
|
|
|
rowUpdate(row, index, done, loading) {
|
|
|
done(row);
|
|
|
},
|
|
|
- //删除客户联系人触发
|
|
|
+ //删除商品信息触发
|
|
|
rowDel(row, index, donerowDel) {
|
|
|
this.$confirm("确定将选择数据删除?", {
|
|
|
confirmButtonText: "确定",
|
|
|
@@ -442,17 +660,26 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
- //新增客户优势项目保存触发
|
|
|
+ //新增费用明细保存触发
|
|
|
rowSaveProject(row, done, loading){
|
|
|
- console.log(row,done,loading)
|
|
|
this.advantageProjectData.push(row)
|
|
|
done()
|
|
|
},
|
|
|
- //修改客户优势项目触发
|
|
|
+ //修改费用明细触发
|
|
|
rowUpdateProject(row, index, done, loading) {
|
|
|
done(row);
|
|
|
},
|
|
|
- //删除客户优势项目触发
|
|
|
+ //商品列表查询
|
|
|
+ onLoad(page, params = {}) {
|
|
|
+ this.loading = true;
|
|
|
+ getList(page.currentPage, page.pageSize, Object.assign(params, this.query), this.treeDeptId).then(res => {
|
|
|
+ const data = res.data.data;
|
|
|
+ this.page.total = data.total;
|
|
|
+ this.data = data.records;
|
|
|
+ this.loading = false;
|
|
|
+ });
|
|
|
+ },
|
|
|
+ //删除费用明细触发
|
|
|
rowDelProject(row, index, donerowDel) {
|
|
|
this.$confirm("确定将选择数据删除?", {
|
|
|
confirmButtonText: "确定",
|
|
|
@@ -476,17 +703,16 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
- //新增客户优势项目保存触发
|
|
|
+ //新增附件上传保存触发
|
|
|
rowSaveBankOfDeposit(row, done, loading){
|
|
|
- console.log(row,done,loading)
|
|
|
this.bankOfDepositData.push(row)
|
|
|
done()
|
|
|
},
|
|
|
- //修改客户优势项目触发
|
|
|
+ //修改附件上传触发
|
|
|
rowUpdateBankOfDeposit(row, index, done, loading) {
|
|
|
done(row);
|
|
|
},
|
|
|
- //删除客户优势项目触发
|
|
|
+ //删除附件上传触发
|
|
|
rowDelBankOfDeposit(row, index, donerowDel) {
|
|
|
this.$confirm("确定将选择数据删除?", {
|
|
|
confirmButtonText: "确定",
|
|
|
@@ -515,15 +741,18 @@ export default {
|
|
|
console.log(this.form)
|
|
|
this.$refs["form"].validate((valid) => {
|
|
|
if (valid) {
|
|
|
- this.form.corpsAttnList = this.contactsData
|
|
|
- this.form.corpsBankList = this.bankOfDepositData
|
|
|
- this.form.corpsItems = this.advantageProjectData
|
|
|
+ //商品信息
|
|
|
+ this.form.orderItemsList = this.contactsData
|
|
|
+ this.form.orderFeesList = this.advantageProjectData
|
|
|
+ this.form.orderFilesList = this.bankOfDepositData
|
|
|
// console.log(typeof(this.form.companytype))
|
|
|
// this.form.corpsTypeId = JSON.stringify(this.form.corpsTypeId).replace(/[\[\]]/g,"")
|
|
|
// console.log(typeof this.form.corpsTypeId)
|
|
|
if (typeof this.form.corpsTypeId == 'object'){
|
|
|
this.form.corpsTypeId = this.form.corpsTypeId.join(",")
|
|
|
}
|
|
|
+ this.disabled = true
|
|
|
+ this.form.billType = 'XS'
|
|
|
typeSave(this.form).then(res => {
|
|
|
console.log(res.data)
|
|
|
this.$message({
|
|
|
@@ -532,7 +761,7 @@ export default {
|
|
|
});
|
|
|
this.$router.$avueRouter.closeTag();
|
|
|
this.$router.push({
|
|
|
- path: '/basicData/customerInformation/index',
|
|
|
+ path: '/businessManagement/salesOrder/index',
|
|
|
query: {}
|
|
|
});
|
|
|
})
|
|
|
@@ -544,7 +773,7 @@ export default {
|
|
|
backToList() {
|
|
|
this.$router.$avueRouter.closeTag();
|
|
|
this.$router.push({
|
|
|
- path: '/basicData/customerInformation/index',
|
|
|
+ path: '/businessManagement/salesOrder/index',
|
|
|
query: {}
|
|
|
});
|
|
|
}
|
|
|
@@ -589,4 +818,14 @@ export default {
|
|
|
::v-deep .el-form-item {
|
|
|
margin-bottom: 0;
|
|
|
}
|
|
|
+.el-dialogDeep {
|
|
|
+ ::v-deep .el-dialog {
|
|
|
+ margin: 1vh auto 0!important;
|
|
|
+ padding-bottom: 10px!important;
|
|
|
+ .el-dialog__body,.el-dialog__footer{
|
|
|
+ padding-bottom: 0 !important;
|
|
|
+ padding-top: 0!important;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
</style>
|