作者 shenhailong

修改首页样式

增加模板下载
优化预配界面功能
优化收发货人功能
预配收发货人 绑定用户id 企业id
... ... @@ -296,7 +296,7 @@ let routes = [
},
{
path: '/output',
component: Home,
component: HomeNew,
name: '国内进港业务申报',
iconCls: 'el-icon-collection',
children: [
... ... @@ -406,7 +406,7 @@ let routes = [
},
{
path: '/con',
component: Home,
component: HomeNew,
name: '收发货人管理',
iconCls:'el-icon-goods',
children:[
... ... @@ -417,12 +417,12 @@ let routes = [
]
},
{
path: '/shipper',
component: Home,
path: '/cargo_shipper',
component: HomeNew,
name: '货主信息管理',
iconCls:'el-icon-setting',
iconCls:'el-icon-goods',
children:[
{path:'/shipper',component:Shipper,name:'货主信息管理'},
{path: '/shipper',component: Shipper,name: '货主信息管理'}
]
},
{
... ...
... ... @@ -4,10 +4,10 @@
<el-col :span="24" class="toolbar" style="padding-bottom: 0px;">
<el-form :inline="true" :model="filters">
<el-form-item>
<el-input size="small" v-model="filters.companyName" placeholder="关键字查询"></el-input>
<el-input size="small" v-model="filters.companyName" placeholder="公司名称"></el-input>
</el-form-item>
<el-form-item>
<el-button type="warning" style="width:150px" size="small" icon="el-icon-plus" v-on:click="getConsigner()">查询</el-button>
<el-button type="warning" style="width:150px" size="small" icon="el-icon-plus" v-on:click="getConsignee()">查询</el-button>
</el-form-item>
<el-form-item>
<el-button type="primary" style="width:150px" size="small" icon="el-icon-plus" @click="companyAdd">新增</el-button>
... ... @@ -31,8 +31,8 @@
</el-table-column>
<el-table-column prop="conPhone" label="收货人电话" >
</el-table-column>
<el-table-column prop="enterprise" label="收货人企业代码" >
</el-table-column>
<!-- <el-table-column prop="enterprise" label="收货人企业代码" >-->
<!-- </el-table-column>-->
<el-table-column label="操作" min-width="150">
<template slot-scope="scope">
<el-button type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(scope.$index, scope.row)">编辑</el-button>
... ... @@ -40,28 +40,27 @@
</template>
</el-table-column>
</el-table>
<!--编辑界面-->
<el-dialog title="编辑" :visible.sync="editFormVisible" :close-on-click-modal="false" width="60%" text-align="center" tyle="margin-top: -20px">
<el-form :model="editForm" :rules="editFormRules" ref="editForm" label-width="145px" style="margin-top: -10px">
<el-dialog :title="dialogMap[dialogStatus]" :visible.sync="coneeVisible" :close-on-click-modal="false" width="60%" text-align="center" tyle="margin-top: -20px">
<el-form :model="coneeForm" :rules="coneeRules" ref="coneeForm" label-width="145px" style="margin-top: -10px">
<el-row>
<el-col :span="4">
<el-col :span="4" style="display: none">
<el-form-item label="ID">
<span>{{editForm.id}}</span>
<span>{{coneeForm.id}}</span>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="companyName">
<el-input v-model="editForm.companyName" auto-complete="on" placeholder="公司" style="width:300px" size="small">
<el-input v-model="coneeForm.companyName" auto-complete="on" placeholder="公司" style="width:300px" size="small">
<template slot="prepend" >公司</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conAddress">
<el-input v-model="editForm.conAddress" auto-complete="on" placeholder="地址" style="width:300px" size="small">
<el-input v-model="coneeForm.conAddress" auto-complete="on" placeholder="地址" style="width:300px" size="small">
<template slot="prepend" >地址</template>
</el-input>
</el-form-item>
... ... @@ -70,14 +69,14 @@
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPhone">
<el-input v-model="editForm.conPhone" auto-complete="on" placeholder="电话" style="width:300px" size="small">
<el-input v-model="coneeForm.conPhone" auto-complete="on" placeholder="电话" style="width:300px" size="small">
<template slot="prepend" >电话</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conFax">
<el-input v-model="editForm.conFax" auto-complete="on" placeholder="传真" style="width:300px" size="small">
<el-input v-model="coneeForm.conFax" auto-complete="on" placeholder="传真" style="width:300px" size="small">
<template slot="prepend" >传真</template>
</el-input>
</el-form-item>
... ... @@ -87,14 +86,14 @@
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPostcode">
<el-input v-model="editForm.conPostcode" auto-complete="on" placeholder="邮编" style="width:300px" size="small">
<el-input v-model="coneeForm.conPostcode" auto-complete="on" placeholder="邮编" style="width:300px" size="small">
<template slot="prepend" >邮编</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conCity">
<el-input v-model="editForm.conCity" auto-complete="on" placeholder="城市" style="width:300px" size="small">
<el-input v-model="coneeForm.conCity" auto-complete="on" placeholder="城市" style="width:300px" size="small">
<template slot="prepend" >城市</template>
</el-input>
</el-form-item>
... ... @@ -103,14 +102,14 @@
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="country">
<el-input v-model="editForm.country" auto-complete="on" placeholder="国家代码" style="width:300px" size="small">
<el-input v-model="coneeForm.country" auto-complete="on" placeholder="国家代码" style="width:300px" size="small">
<template slot="prepend" >国家代码</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conName">
<el-input v-model="editForm.conName" auto-complete="on" placeholder="收货人名称" style="width:300px" size="small">
<el-input v-model="coneeForm.conName" auto-complete="on" placeholder="收货人名称" style="width:300px" size="small">
<template slot="prepend" >收货人名称</template>
</el-input>
</el-form-item>
... ... @@ -119,151 +118,24 @@
<el-row>
<el-col :span="8">
<el-form-item label="" prop="conAeo">
<el-input v-model="editForm.conAeo" auto-complete="on" placeholder="收货人AEO" style="width:300px" size="small">
<el-input v-model="coneeForm.conAeo" auto-complete="on" placeholder="收货人AEO" style="width:300px" size="small">
<template slot="prepend" >收货人AEO</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="6">
<el-form-item label="" prop="enterprise">
<el-select v-model="editForm.enterprise" placeholder="请选择企业代码" style="width:150px" size="small">
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="+" prop="enterprise">
<el-input v-model="editForm.ent" style="width:200px" size="small"/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer" style="text-align: center">
<el-button @click.native="editFormVisible = false" style="width: 120px;background-color: #6F8294;color: #ffffff" size="medium" >取消</el-button>
<el-button type="success" size="medium" style="width: 120px" @click.native="editSubmit">提交</el-button>
</div>
</el-dialog>
<!--新增界面-->
<el-dialog title="新增" :visible.sync="addFormVisible" :close-on-click-modal="false" tyle="margin-top: -20px"
width="60%" text-align="center">
<el-form :model="addForm" label-width="145px" :rules="addFormRules" ref="addForm" style="margin-top: -10px" >
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="companyName">
<el-input v-model="addForm.companyName" auto-complete="on" placeholder="公司" style="width:300px" size="small">
<template slot="prepend" >公司</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conAddress">
<el-input v-model="addForm.conAddress" auto-complete="on" placeholder="地址" style="width:300px" size="small">
<template slot="prepend" >地址</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPhone">
<el-input v-model="addForm.conPhone" auto-complete="on" placeholder="电话" style="width:300px" size="small">
<template slot="prepend" >电话</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conFax">
<el-input v-model="addForm.conFax" auto-complete="on" placeholder="传真" style="width:300px" size="small">
<template slot="prepend" >传真</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPostcode">
<el-input v-model="addForm.conPostcode" auto-complete="on" placeholder="邮编" style="width:300px" size="small">
<template slot="prepend" >邮编</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conCity">
<el-input v-model="addForm.conCity" auto-complete="on" placeholder="城市" style="width:300px" size="small">
<template slot="prepend" >城市</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="country">
<el-input v-model="addForm.country" auto-complete="on" placeholder="国家代码" style="width:300px" size="small">
<template slot="prepend" >国家代码</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conAddress">
<el-form-item label="" prop="conName">
<el-input v-model="addForm.conName" auto-complete="on" placeholder="收货人名称" style="width:300px" size="small">
<template slot="prepend" >收货人名称</template>
</el-input>
</el-form-item>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="" prop="conAeo">
<el-input v-model="addForm.conAeo" auto-complete="on" placeholder="收货人AEO" style="width:300px" size="small">
<template slot="prepend" >收货人AEO</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="6">
<el-form-item label="" prop="enterprise">
<el-select v-model="addForm.enterprise" placeholder="请选择企业代码" style="width:150px" size="small">
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="+" prop="enterprise">
<el-input v-model="addForm.ent" style="width:200px" size="small"/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer" style="text-align: center">
<el-button style="width: 120px;background-color: #6F8294;color: #ffffff" size="medium" @click.native="addFormVisible = false">取消</el-button>
<el-button type="success" size="medium" style="width: 120px" @click.native="addSubmit">提交</el-button>
<el-button @click.native="coneeVisible = false" style="width: 120px;background-color: #6F8294;color: #ffffff" size="medium" >取消</el-button>
<el-button type="success" size="medium" style="width: 120px" @click.native="dialogStatus ==='create'? addSubmit():editSubmit()">保存</el-button>
</div>
</el-dialog>
</section>
</template>
<script>
import util from '../../common/js/util'
import NProgress from 'nprogress'
import { getList, remove, add, edit} from '../../api/consigner/consignee';
import moment from 'moment'
import loginUserInfo from '../../api/base';
export default {
data() {
... ... @@ -289,14 +161,17 @@
limitSize: 5,
listLoading: false,
//编辑界面是否显示
editFormVisible: false,
coneeVisible: false,
dialogStatus: undefined,
editLoading: false,
editFormRules: {
dialogMap: {
update: '编辑',
create: '新增'
},
coneeRules: {
companyName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
... ... @@ -311,10 +186,22 @@
],
conAddress: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conPhone: [
{ required: true, message: '手机号不能为空', trigger: 'blur' },
{ type: 'number', message: '手机号格式不正确', trigger: 'blur',
transform(value){
var phone = 11 && /^((13|14|15|16|17|18|19)[0-9]{1}\d{8})$/
if (!phone.test(value)){
return false;
}else {
return Number(value);
}
}}
]
},
//编辑界面数据
editForm: {
//实体数据
coneeForm: {
id:'',
companyName: '',
conAddress: '',
... ... @@ -326,59 +213,25 @@
conPostcode: '',
country: '',
enterprise: '',
ent: ''
ent: '',
enterpriseId:'',
userId:''
},
//新增界面是否显示
addFormVisible: false,
addFormRules: {
companyName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
country: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
enterprise: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conCity: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conAddress: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
]
},
//新增界面数据
addForm: {
companyName: '',
conAddress: '',
conAeo: '',
conCity: '',
conFax: '',
conName: '',
conPhone: '',
conPostcode: '',
country: '',
enterprise: '',
ent: ''
}
}
},
mounted() {
this.getConsigner();
this.getConsignee();
},
methods: {
//获取收货人列表
getConsigner() {
getConsignee() {
let para = {
pageSize: this.pageSize,
limitSize: this.limitSize,
companyName: this.filters.companyName
companyName: this.filters.companyName,
enterpriseId: loginUserInfo.companyId
};
this.listLoading = true;
getList(para).then((res) => {
... ... @@ -398,8 +251,6 @@
});
},
//删除
handleDel: function (index, row) {
this.$confirm('确认删除该记录吗?', '提示', {
... ... @@ -414,14 +265,14 @@
message: '删除成功',
type: 'success'
});
this.getConsigner();
this.getConsignee();
}else {
this.listLoading = false;
this.$message({
message: '删除失败',
type: 'error'
});
this.getConsigner();
this.getConsignee();
}
}).catch((error) => {
... ... @@ -436,33 +287,29 @@
* @param row 为这行的数据对象
*/
handleEdit: function (index, row) {
this.editFormVisible = true;
let strings = row.enterprise.split("+");
row.enterprise = strings[0];
row.ent = strings[1]
this.editForm = Object.assign({}, row);
this.getConsigner();
this.dialogStatus = 'update'
this.coneeVisible = true;
this.coneeForm = Object.assign({}, row);
// this.getConsignee();
this.userId()
},
//编辑
editSubmit: function () {
this.$refs.editForm.validate((valid) => {
this.$refs.coneeForm.validate((valid) => {
if (valid) {
this.$confirm('确认提交吗?', '提示', {}).then(() => {
this.editLoading = true;
this.editForm.enterprise = this.editForm.enterprise+"+"+this.editForm.ent;
let para = Object.assign({}, this.editForm);
let para = Object.assign({}, this.coneeForm);
this.editLoading = true;
edit(para).then((res) => {
if (res.data.code == 200){
if (res.data.code == '200'){
this.$message({
message: '提交成功',
type: 'success'
});
this.$refs['editForm'].resetFields();
this.editFormVisible = false;
this.getConsigner();
this.$refs['coneeForm'].resetFields();
this.coneeVisible = false;
this.getConsignee();
}else {
this.$message({
message: '提交失败',
... ... @@ -475,31 +322,31 @@
}
});
},
//显示新增界面,每次点开初始化数据
companyAdd: function () {
this.addFormVisible = true;
this.getConsigner();
this.dialogStatus = 'create'
this.coneeVisible = true;
this.tableForm();
this.userId();
},
//新增
addSubmit: function () {
this.$refs.addForm.validate((valid) => {
this.$refs.coneeForm.validate((valid) => {
if (valid) {
this.$confirm('确认提交吗?', '提示', {}).then(() => {
//NProgress.start();
this.listLoading = true;
this.addForm.enterprise = this.addForm.enterprise+"+"+this.addForm.ent;
let para = Object.assign({}, this.addForm);
let para = Object.assign({}, this.coneeForm);
add(para).then((res) => {
if (res.data.code == 200){
if (res.data.code == '200'){
//NProgress.done();
this.$message({
message: '提交成功',
type: 'success'
});
this.$refs['addForm'].resetFields();
this.addFormVisible = false;
this.getConsigner();
this.$refs['coneeForm'].resetFields();
this.coneeVisible = false;
this.getConsignee();
}else {
this.$message({
message: '提交失败',
... ... @@ -530,11 +377,33 @@
message: '删除成功',
type: 'success'
});
this.getConsigner();
this.getConsignee();
});
}).catch(() => {
});
},
// 实体重置
tableForm(){
this.coneeForm = {
id:'',
companyName: '',
conAddress: '',
conAeo: '',
conCity: '',
conFax: '',
conName: '',
conPhone: '',
conPostcode: '',
country: '',
enterprise: '',
ent: ''
}
},
//设置 用户id 企业id
userId(){
this.coneeForm.userId = loginUserInfo.userId;
this.coneeForm.enterpriseId = loginUserInfo.companyId;
}
},
... ...
... ... @@ -4,10 +4,10 @@
<el-col :span="24" class="toolbar" style="padding-bottom: 0px;">
<el-form :inline="true" :model="filters">
<el-form-item>
<el-input size="small" v-model="filters.companyName" placeholder="关键字查询"></el-input>
<el-input size="small" v-model="filters.companyName" placeholder="公司名称"></el-input>
</el-form-item>
<el-form-item>
<el-button type="warning" style="width:150px" size="small" icon="el-icon-plus" v-on:click="getConsigner()">查询</el-button>
<el-button type="warning" style="width:150px" size="small" icon="el-icon-plus" v-on:click="getConsignee()">查询</el-button>
</el-form-item>
<el-form-item>
<el-button type="primary" style="width:150px" size="small" icon="el-icon-plus" @click="companyAdd">新增</el-button>
... ... @@ -23,16 +23,16 @@
</el-table-column>
<el-table-column label="序号" type="index">
</el-table-column>
<el-table-column prop="companyName" label="货人公司" >
<el-table-column prop="companyName" label="货人公司" >
</el-table-column>
<el-table-column prop="conCity" label="货人城市" >
<el-table-column prop="conCity" label="货人城市" >
</el-table-column>
<el-table-column prop="country" label="货人国家代码" >
<el-table-column prop="country" label="货人国家代码" >
</el-table-column>
<el-table-column prop="conPhone" label="发货人电话" >
</el-table-column>
<el-table-column prop="enterprise" label="发货人企业代码" >
<el-table-column prop="conPhone" label="收货人电话" >
</el-table-column>
<!-- <el-table-column prop="enterprise" label="收货人企业代码" >-->
<!-- </el-table-column>-->
<el-table-column label="操作" min-width="150">
<template slot-scope="scope">
<el-button type="primary" icon="el-icon-edit" size="mini" @click="handleEdit(scope.$index, scope.row)">编辑</el-button>
... ... @@ -40,28 +40,27 @@
</template>
</el-table-column>
</el-table>
<!--编辑界面-->
<el-dialog title="编辑" :visible.sync="editFormVisible" :close-on-click-modal="false" width="60%" text-align="center" tyle="margin-top: -20px">
<el-form :model="editForm" :rules="editFormRules" ref="editForm" label-width="145px" style="margin-top: -10px">
<el-dialog :title="dialogMap[dialogStatus]" :visible.sync="conerVisible" :close-on-click-modal="false" width="60%" text-align="center" tyle="margin-top: -20px">
<el-form :model="conerForm" :rules="conerRules" ref="conerForm" label-width="145px" style="margin-top: -10px">
<el-row>
<el-col :span="4">
<el-col :span="4" style="display: none">
<el-form-item label="ID">
<span>{{editForm.id}}</span>
<span>{{conerForm.id}}</span>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="companyName">
<el-input v-model="editForm.companyName" auto-complete="on" placeholder="公司" style="width:300px" size="small">
<el-input v-model="conerForm.companyName" auto-complete="on" placeholder="公司" style="width:300px" size="small">
<template slot="prepend" >公司</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conAddress">
<el-input v-model="editForm.conAddress" auto-complete="on" placeholder="地址" style="width:300px" size="small">
<el-input v-model="conerForm.conAddress" auto-complete="on" placeholder="地址" style="width:300px" size="small">
<template slot="prepend" >地址</template>
</el-input>
</el-form-item>
... ... @@ -70,134 +69,31 @@
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPhone">
<el-input v-model="editForm.conPhone" auto-complete="on" placeholder="电话" style="width:300px" size="small">
<el-input v-model="conerForm.conPhone" auto-complete="on" placeholder="电话" style="width:300px" size="small">
<template slot="prepend" >电话</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conFax">
<el-input v-model="editForm.conFax" auto-complete="on" placeholder="传真" style="width:300px" size="small">
<el-input v-model="conerForm.conFax" auto-complete="on" placeholder="传真" style="width:300px" size="small">
<template slot="prepend" >传真</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPostcode">
<el-input v-model="editForm.conPostcode" auto-complete="on" placeholder="邮编" style="width:300px" size="small">
<template slot="prepend" >邮编</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conCity">
<el-input v-model="editForm.conCity" auto-complete="on" placeholder="城市" style="width:300px" size="small">
<template slot="prepend" >城市</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="country">
<el-input v-model="editForm.country" auto-complete="on" placeholder="国家代码" style="width:300px" size="small">
<template slot="prepend" >国家代码</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conName">
<el-input v-model="editForm.conName" auto-complete="on" placeholder="发货人名称" style="width:300px" size="small">
<template slot="prepend" >发货人名称</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="" prop="conAeo">
<el-input v-model="editForm.conAeo" auto-complete="on" placeholder="发货人AEO" style="width:300px" size="small">
<template slot="prepend" >发货人AEO</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="6">
<el-form-item label="" prop="enterprise">
<el-select v-model="editForm.enterprise" placeholder="请选择企业代码" style="width:150px" size="small">
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="+" prop="enterprise">
<el-input v-model="editForm.ent" style="width:200px" size="small"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer" style="text-align: center">
<el-button @click.native="editFormVisible = false" style="width: 120px;background-color: #6F8294;color: #ffffff" size="medium" >取消</el-button>
<el-button type="success" size="medium" style="width: 120px" @click.native="editSubmit" :loading="editLoading">提交</el-button>
</div>
</el-dialog>
<!--新增界面-->
<el-dialog title="新增" :visible.sync="addFormVisible" :close-on-click-modal="false" tyle="margin-top: -20px"
width="60%" text-align="center">
<el-form :model="addForm" label-width="145px" :rules="addFormRules" ref="addForm" style="margin-top: -10px" >
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="companyName">
<el-input v-model="addForm.companyName" auto-complete="on" placeholder="公司" style="width:300px" size="small">
<template slot="prepend" >公司</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conAddress">
<el-input v-model="addForm.conAddress" auto-complete="on" placeholder="地址" style="width:300px" size="small">
<template slot="prepend" >地址</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPhone">
<el-input v-model="addForm.conPhone" auto-complete="on" placeholder="电话" style="width:300px" size="small">
<template slot="prepend" >电话</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conFax">
<el-input v-model="addForm.conFax" auto-complete="on" placeholder="传真" style="width:300px" size="small">
<template slot="prepend" >传真</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="conPostcode">
<el-input v-model="addForm.conPostcode" auto-complete="on" placeholder="邮编" style="width:300px" size="small">
<el-input v-model="conerForm.conPostcode" auto-complete="on" placeholder="邮编" style="width:300px" size="small">
<template slot="prepend" >邮编</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conCity">
<el-input v-model="addForm.conCity" auto-complete="on" placeholder="城市" style="width:300px" size="small">
<el-input v-model="conerForm.conCity" auto-complete="on" placeholder="城市" style="width:300px" size="small">
<template slot="prepend" >城市</template>
</el-input>
</el-form-item>
... ... @@ -206,63 +102,40 @@
<el-row>
<el-col :span="8" style="margin-right: 20px">
<el-form-item label="" prop="country">
<el-input v-model="addForm.country" auto-complete="on" placeholder="国家代码" style="width:300px" size="small">
<el-input v-model="conerForm.country" auto-complete="on" placeholder="国家代码" style="width:300px" size="small">
<template slot="prepend" >国家代码</template>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="" prop="conName">
<el-input v-model="addForm.conName" auto-complete="on" placeholder="发货人名称" style="width:300px" size="small">
<template slot="prepend" >发货人名称</template>
<el-input v-model="conerForm.conName" auto-complete="on" placeholder="收货人名称" style="width:300px" size="small">
<template slot="prepend" >收货人名称</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="" prop="conAeo">
<el-input v-model="addForm.conAeo" auto-complete="on" placeholder="发货人AEO" style="width:300px" size="small">
<template slot="prepend" >发货人AEO</template>
<el-input v-model="conerForm.conAeo" auto-complete="on" placeholder="收货人AEO" style="width:300px" size="small">
<template slot="prepend" >收货人AEO</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="6">
<el-form-item label="" prop="enterprise">
<el-select v-model="addForm.enterprise" placeholder="请选择企业代码" style="width:150px" size="small">
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="+" prop="enterprise">
<el-input v-model="addForm.ent" style="width:200px" size="small"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer" style="text-align: center">
<el-button style="width: 120px;background-color: #6F8294;color: #ffffff" size="medium" @click.native="addFormVisible = false">取消</el-button>
<el-button type="success" size="medium" style="width: 120px" @click.native="addSubmit">提交</el-button>
<el-button @click.native="conerVisible = false" style="width: 120px;background-color: #6F8294;color: #ffffff" size="medium" >取消</el-button>
<el-button type="success" size="medium" style="width: 120px" @click.native="dialogStatus ==='create'? addSubmit():editSubmit()">保存</el-button>
</div>
</el-dialog>
</section>
</template>
<script>
import util from '../../common/js/util'
import NProgress from 'nprogress'
import { getList, remove, add, edit} from '../../api/consigner/consigner';
import moment from 'moment'
import loginUserInfo from '../../api/base';
export default {
data() {
... ... @@ -288,14 +161,17 @@
limitSize: 5,
listLoading: false,
//编辑界面是否显示
editFormVisible: false,
conerVisible: false,
dialogStatus: undefined,
editLoading: false,
editFormRules: {
dialogMap: {
update: '编辑',
create: '新增'
},
conerRules: {
companyName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
... ... @@ -310,10 +186,22 @@
],
conAddress: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conPhone: [
{ required: true, message: '手机号不能为空', trigger: 'blur' },
{ type: 'number', message: '手机号格式不正确', trigger: 'blur',
transform(value){
var phone = 11 && /^((13|14|15|16|17|18|19)[0-9]{1}\d{8})$/
if (!phone.test(value)){
return false;
}else {
return Number(value);
}
}}
]
},
//编辑界面数据
editForm: {
//实体数据
conerForm: {
id:'',
companyName: '',
conAddress: '',
... ... @@ -325,59 +213,25 @@
conPostcode: '',
country: '',
enterprise: '',
ent: ''
ent: '',
enterpriseId:'',
userId:''
},
//新增界面是否显示
addFormVisible: false,
addFormRules: {
companyName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conName: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
country: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
enterprise: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conCity: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
],
conAddress: [
{ required: true, message: '不能为空!!!', trigger: 'blur' }
]
},
//新增界面数据
addForm: {
companyName: '',
conAddress: '',
conAeo: '',
conCity: '',
conFax: '',
conName: '',
conPhone: '',
conPostcode: '',
country: '',
enterprise: '',
ent: ''
}
}
},
mounted() {
this.getConsigner();
this.getConsignee();
},
methods: {
//获取发货人列表
getConsigner() {
//获取收货人列表
getConsignee() {
let para = {
pageSize: this.pageSize,
limitSize: this.limitSize,
companyName: this.filters.companyName
companyName: this.filters.companyName,
enterpriseId: loginUserInfo.companyId
};
this.listLoading = true;
getList(para).then((res) => {
... ... @@ -397,8 +251,6 @@
});
},
//删除
handleDel: function (index, row) {
this.$confirm('确认删除该记录吗?', '提示', {
... ... @@ -413,14 +265,14 @@
message: '删除成功',
type: 'success'
});
this.getConsigner();
this.getConsignee();
}else {
this.listLoading = false;
this.$message({
message: '删除失败',
type: 'error'
});
this.getConsigner();
this.getConsignee();
}
}).catch((error) => {
... ... @@ -435,33 +287,29 @@
* @param row 为这行的数据对象
*/
handleEdit: function (index, row) {
this.editFormVisible = true;
let strings = row.enterprise.split("+");
row.enterprise = strings[0];
row.ent = strings[1]
this.editForm = Object.assign({}, row);
this.getConsigner();
this.dialogStatus = 'update'
this.conerVisible = true;
this.conerForm = Object.assign({}, row);
// this.getConsignee();
this.userId()
},
//编辑
editSubmit: function () {
this.$refs.editForm.validate((valid) => {
this.$refs.conerForm.validate((valid) => {
if (valid) {
this.$confirm('确认提交吗?', '提示', {}).then(() => {
this.editLoading = true;
this.editForm.enterprise = this.editForm.enterprise+"+"+this.editForm.ent;
let para = Object.assign({}, this.editForm);
let para = Object.assign({}, this.conerForm);
this.editLoading = true;
edit(para).then((res) => {
if (res.data.code == 200){
if (res.data.code == '200'){
this.$message({
message: '提交成功',
type: 'success'
});
this.$refs['editForm'].resetFields();
this.editFormVisible = false;
this.getConsigner();
this.$refs['conerForm'].resetFields();
this.conerVisible = false;
this.getConsignee();
}else {
this.$message({
message: '提交失败',
... ... @@ -474,31 +322,31 @@
}
});
},
//显示新增界面,每次点开初始化数据
companyAdd: function () {
this.addFormVisible = true;
this.getConsigner();
this.dialogStatus = 'create'
this.conerVisible = true;
this.tableForm();
this.userId();
},
//新增
addSubmit: function () {
this.$refs.addForm.validate((valid) => {
this.$refs.conerForm.validate((valid) => {
if (valid) {
this.$confirm('确认提交吗?', '提示', {}).then(() => {
//NProgress.start();
this.listLoading = true;
this.addForm.enterprise = this.addForm.enterprise+"+"+this.addForm.ent;
let para = Object.assign({}, this.addForm);
let para = Object.assign({}, this.conerForm);
add(para).then((res) => {
if (res.data.code == 200){
if (res.data.code == '200'){
//NProgress.done();
this.$message({
message: '提交成功',
type: 'success'
});
this.$refs['addForm'].resetFields();
this.addFormVisible = false;
this.getConsigner();
this.$refs['conerForm'].resetFields();
this.conerVisible = false;
this.getConsignee();
}else {
this.$message({
message: '提交失败',
... ... @@ -529,11 +377,33 @@
message: '删除成功',
type: 'success'
});
this.getConsigner();
this.getConsignee();
});
}).catch(() => {
});
},
// 实体重置
tableForm(){
this.conerForm = {
id:'',
companyName: '',
conAddress: '',
conAeo: '',
conCity: '',
conFax: '',
conName: '',
conPhone: '',
conPostcode: '',
country: '',
enterprise: '',
ent: ''
}
},
//设置 用户id 企业id
userId(){
this.conerForm.userId = loginUserInfo.userId;
this.conerForm.enterpriseId = loginUserInfo.companyId;
}
},
... ...
... ... @@ -41,6 +41,9 @@
style="width:150px" icon="el-icon-plus"
@click="handleAddpre">新增预配舱单
</el-button>
<el-button @click="download" style="width:150px" size="small" type="primary">
模板下载
</el-button>
<el-upload
style="display: inline; margin-left: 10px;margin-right: 10px;"
action=""
... ... @@ -185,503 +188,6 @@
<pagination background layout="total, prev, pager, next" v-show="total>0" :total="total" :page.sync="preQuery.pageSize" :limit.sync="preQuery.limitSize"
@pagination="getList"/>
<!-- <el-dialog top="5vh" :title="dialogMap[dialogStatus]" :visible.sync="dialogFormVisible" width="90%">-->
<!-- <el-form ref="preFormData" :model="preModel" :rules="preRoles" label-position="right"-->
<!-- label-width="80px" size="mini" class="el-dialog-div">-->
<!-- <div class="grid-content content" style="font-size: 10px">-->
<!-- 运单信息-->
<!-- </div>-->
<!-- <el-row>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="awba">-->
<!-- <el-input :disabled="dialogStatus !== 'create'" v-model="awba" clearable>-->
<!-- <template slot="prepend" >主单号</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5" v-if="fenStatus === 'addAwbh'">-->
<!-- <el-form-item label="" prop="awbh">-->
<!-- <el-input v-model="awbh" clearable>-->
<!-- <template slot="prepend" >分单号</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- <div class="grid-content content" style="font-size: 10px">-->
<!-- 航班信息-->
<!-- </div>-->
<!-- <el-row>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="carrier">-->
<!-- <el-input v-model="carrier" :disabled="fenStatus === 'addAwbh'" clearable>-->
<!-- <template slot="prepend" >承运人</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="flightno">-->
<!-- <el-input v-model="flightno" :disabled="fenStatus === 'addAwbh'" clearable>-->
<!-- <template slot="prepend" >航班号</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="flightdate">-->
<!-- <el-date-picker :disabled="fenStatus === 'addAwbh'"-->
<!-- value-format="yyyy-MM-dd" style="width: 270px"-->
<!-- v-model="preModel.flightdate" align="right"-->
<!-- type="date" placeholder="请输入航班日期" clearable/>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="originstation">-->
<!-- <el-select-->
<!-- filterable-->
<!-- clearable-->
<!-- placeholder="请选择起始站"-->
<!-- :remote-method="remoteMethodAirport"-->
<!-- allow-create remote-->
<!-- v-model="originstation"-->
<!-- :loading="airportLoading"-->
<!-- style="width: 270px">-->
<!-- <el-option v-for="item in airportCode"-->
<!-- :key="item.airportid" :label="item.airportid"-->
<!-- :value="item.airportid" :disabled="fenStatus === 'addAwbh'">-->
<!-- <span style="float: left">{{ item.airportdescchn }}</span>-->
<!-- <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span>-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="destinationstation">-->
<!-- <el-select filterable clearable placeholder="请选择目的站" allow-create remote-->
<!-- v-model="destinationstation" :remote-method="remoteMethodAirport" style="width: 270px">-->
<!-- <el-option v-for="item in airportCode"-->
<!-- :key="item.airportid" :label="item.airportid"-->
<!-- :value="item.airportid" :disabled="fenStatus === 'addAwbh'" >-->
<!-- <span style="float: left">{{ item.airportdescchn }}</span>-->
<!-- <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span>-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- <div class="grid-content content" style="font-size: 10px">-->
<!-- 航程信息-->
<!-- </div>-->
<!-- <div>-->
<!-- <el-row>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="carrier">-->
<!-- <el-input v-model="carrier" disabled clearable>-->
<!-- <template slot="prepend" >承运人</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="destinationstation">-->
<!-- <el-input v-model="destinationstation" disabled clearable>-->
<!-- <template slot="prepend" >到达航站</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="by1" clearable>-->
<!-- <template slot="prepend" >承运人1</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="dest1" clearable>-->
<!-- <template slot="prepend" >到达航站1</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="by2" clearable>-->
<!-- <template slot="prepend" >承运人2</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="dest2" clearable>-->
<!-- <template slot="prepend" >到达航站2</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- </div>-->
<!-- <div class="grid-content content" style="font-size: 10px">-->
<!-- 货物信息-->
<!-- </div>-->
<!-- <el-row>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.pcs">-->
<!-- <el-input v-model="preModel.awbinfo.pcs" clearable>-->
<!-- <template slot="prepend" >运单件数</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.weight">-->
<!-- <el-input v-model="preModel.awbinfo.weight" clearable>-->
<!-- <template slot="prepend" >运单重量</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="goodsname">-->
<!-- <el-input v-model="goodsname" clearable>-->
<!-- <template slot="prepend" >货物描述</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5" v-if="fenStatus !=='addAwbh'">-->
<!-- <el-form-item label="" prop="piece">-->
<!-- <el-input v-model="preModel.piece" clearable>-->
<!-- <template slot="prepend" >预配件数</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5" v-if="fenStatus ==='addAwbh'">-->
<!-- <el-form-item label="" prop="piece">-->
<!-- <el-input v-model="preModel.piece" clearable>-->
<!-- <template slot="prepend" >预配件数</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5" v-if="fenStatus !=='addAwbh'">-->
<!-- <el-form-item label="" prop="weight">-->
<!-- <el-input v-model="preModel.weight" clearable>-->
<!-- <template slot="prepend" >预配重量</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5" v-if="fenStatus ==='addAwbh'">-->
<!-- <el-form-item label="" prop="weight">-->
<!-- <el-input v-model="preModel.weight" clearable>-->
<!-- <template slot="prepend" >预配重量</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="actime">-->
<!-- <el-date-picker value-format="yyyy-MM-dd HH:mm:ss"-->
<!-- v-model="preModel.actime" align="right" style="width: 180px"-->
<!-- type="datetime" placeholder="请选择预配时间"/>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="customcode">-->
<!-- <el-select v-model="preModel.customcode" placeholder="请选择关区代码"-->
<!-- filterable clearable :remote-method="remoteMethodCustomCode" :loading="customLoading" remote-->
<!-- :disabled="fenStatus === 'addAwbh'">-->
<!-- <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode"-->
<!-- :value="item.customcode">-->
<!-- <span style="float: left">{{ item.customcode }}</span>-->
<!-- <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span>-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-select v-model="preModel.awbinfo.awbtype" class="filter-item" placeholder="请录入货物类型">-->
<!-- <el-option v-for="item in customTypes" :key="item.value"-->
<!-- :label="item.label"-->
<!-- :value="item.value">-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.paymodel">-->
<!-- <el-select v-model="preModel.awbinfo.paymodel" class="filter-item" placeholder="请选择付费方式">-->
<!-- <el-option-->
<!-- v-for="item in payTypes"-->
<!-- :key="item.value"-->
<!-- :label="item.label"-->
<!-- :value="item.value">-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="">-->
<!-- <el-input v-model="specopeid" clearable>-->
<!-- <template slot="prepend" >卸货地</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="">-->
<!-- <el-input v-model="preModel.awbinfo.shpcustomerid" clearable>-->
<!-- <template slot="prepend" >代理人代码</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="">-->
<!-- <el-input v-model="preModel.awbinfo.shpcustomerid" clearable>-->
<!-- <template slot="prepend" >代理人名称</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- <el-row style="margin-bottom: 10px">-->
<!-- <el-col :span="7" v-if="fenStatus ==='addAwbh'">-->
<!-- <span>-->
<!-- 货物剩余信息:-->
<!-- </span>-->
<!-- </el-col>-->
<!-- <el-col :span="7" v-if="fenStatus ==='addAwbh'">-->
<!-- <span>剩余件数:{{awbPiece}}</span>-->
<!-- </el-col>-->
<!-- <el-col :span="7" v-if="fenStatus ==='addAwbh'">-->
<!-- <span>剩余重量:{{awbWeight}}</span>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- <div class="grid-content content" style="font-size: 10px">-->
<!-- 发货人信息-->
<!-- <el-button type="primary" size="mini" @click="consignerSelect()">选择发货人信息</el-button>-->
<!-- </div>-->
<!-- <el-row>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.shprname">-->
<!-- <el-input v-model="shprname" clearable>-->
<!-- <template slot="prepend" >发货人名称</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.shpraddress">-->
<!-- <el-input v-model="shpraddress" clearable>-->
<!-- <template slot="prepend" >地址</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="scityid" maxlength="5" clearable>-->
<!-- <template slot="prepend" >城市代码</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="preModel.awbinfo.shprmobiletype" clearable>-->
<!-- <template slot="prepend" >传真</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.shprcountyr">-->
<!-- <el-select-->
<!-- :remote-method="remoteMethod"-->
<!-- :loading="listLoading"-->
<!-- v-model="shprcountyr"-->
<!-- filterable-->
<!-- allow-create-->
<!-- remote-->
<!-- placeholder="请选择国家代码" clearable>目的站-->
<!-- <el-option-->
<!-- v-for="item in countryOption"-->
<!-- :key="item.value"-->
<!-- :label="item.value"-->
<!-- :value="item.value">-->
<!-- <span style="float: left">{{ item.label }}</span>-->
<!-- <span style="float: right; color: #8492a6; font-size: 13px">{{ item.value }}</span>-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="awbinfo.shprtel">-->
<!-- <el-input v-model="preModel.awbinfo.shprtel" clearable>-->
<!-- <template slot="prepend" >电话</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="awbinfo.shpaeocode">-->
<!-- <el-input v-model="shpaeocode" clearable style="width: 270px">-->
<!-- <template slot="prepend" >发货人AEO编码</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- &lt;!&ndash;<el-col :span="7.5">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-form-item label="企业代码类型" prop="awbinfo.shpcomidpre">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-select&ndash;&gt;-->
<!-- &lt;!&ndash;v-model="shpcomidpre"&ndash;&gt;-->
<!-- &lt;!&ndash;filterable&ndash;&gt;-->
<!-- &lt;!&ndash;placeholder="请选择企业代码类型" style="width: 200px;">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-option&ndash;&gt;-->
<!-- &lt;!&ndash;v-for="item in shpCompnyTypeOption"&ndash;&gt;-->
<!-- &lt;!&ndash;:key="item.value"&ndash;&gt;-->
<!-- &lt;!&ndash;:label="item.label"&ndash;&gt;-->
<!-- &lt;!&ndash;:value="item.value"/>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-select>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-form-item>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-col>&ndash;&gt;-->
<!-- &lt;!&ndash;<el-col :span="7.5">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-form-item prop="awbinfo.shpcomidpno" label-width="10px">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-input v-model="shpcomidpno" placeholder="企业代码"/>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-form-item>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-col>&ndash;&gt;-->
<!-- </el-row>-->
<!-- <div class="grid-content content" style="font-size: 10px">-->
<!-- 收货人信息-->
<!-- <el-button type="primary" size="mini" @click="consigneeSelect()">选择收货人信息</el-button>-->
<!-- </div>-->
<!-- <el-row>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.cnsnname">-->
<!-- <el-input v-model="cnsnname" clearable>-->
<!-- <template slot="prepend" >收货人名称</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.cnsnaddress">-->
<!-- <el-input v-model="cnsnaddress" clearable>-->
<!-- <template slot="prepend" >地址</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="ecityid" clearable maxlength="5">-->
<!-- <template slot="prepend" >城市代码</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="">-->
<!-- <el-input v-model="preModel.awbinfo.cnsrmobiletype" clearable>-->
<!-- <template slot="prepend" >传真</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="5">-->
<!-- <el-form-item label="" prop="awbinfo.cnscountyr">-->
<!-- <el-select-->
<!-- :remote-method="remoteMethod"-->
<!-- :listLoading="listLoading"-->
<!-- v-model="cnscountyr"-->
<!-- filterable-->
<!-- allow-create-->
<!-- remote-->
<!-- placeholder="请选择国家代码" clearable>-->
<!-- <el-option-->
<!-- v-for="item in countryOption"-->
<!-- :key="item.value"-->
<!-- :label="item.value"-->
<!-- :value="item.value">-->
<!-- <span style="float: left">{{ item.label }}</span>-->
<!-- <span style="float: right; color: #8492a6; font-size: 13px">{{ item.value }}</span>-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="awbinfo.cnsntel">-->
<!-- <el-input v-model="preModel.awbinfo.cnsntel" clearable>-->
<!-- <template slot="prepend" >电话</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="7.5">-->
<!-- <el-form-item label="" prop="awbinfo.cnsaeocode">-->
<!-- <el-input v-model="cnsaeocode" clearable style="width: 270px">-->
<!-- <template slot="prepend" >收货人AEO编码</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- <el-row>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="" prop="awbinfo.cnsrctcname">-->
<!-- <el-input v-model="cnsrctcname" clearable>-->
<!-- <template slot="prepend" >收货人名称</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="" prop="awbinfo.cnsrctctel">-->
<!-- <el-input v-model="preModel.awbinfo.cnsrctctel" clearable style="width: 270px">-->
<!-- <template slot="prepend" >收货人电话</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- &lt;!&ndash;<el-col :span="7.5">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-form-item label="企业代码类型" prop="awbinfo.csgcustomerid">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-select&ndash;&gt;-->
<!-- &lt;!&ndash;v-model="cnscomidpre"&ndash;&gt;-->
<!-- &lt;!&ndash;filterable&ndash;&gt;-->
<!-- &lt;!&ndash;placeholder="请选择企业代码类型" style="width: 200px;">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-option&ndash;&gt;-->
<!-- &lt;!&ndash;v-for="item in shpCompnyTypeOption"&ndash;&gt;-->
<!-- &lt;!&ndash;:key="item.value"&ndash;&gt;-->
<!-- &lt;!&ndash;:label="item.label"&ndash;&gt;-->
<!-- &lt;!&ndash;:value="item.value"/>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-select>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-form-item>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-col>&ndash;&gt;-->
<!-- &lt;!&ndash;<el-col :span="7.5">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-form-item prop="awbinfo.cnscomidno" label-width="10px">&ndash;&gt;-->
<!-- &lt;!&ndash;<el-input v-model="cnscomidno" placeholder="企业代码"/>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-form-item>&ndash;&gt;-->
<!-- &lt;!&ndash;</el-col>&ndash;&gt;-->
<!-- <div v-if="dialogStatus === 'sendUpdate'">-->
<!-- <div class="grid-content content">-->
<!-- 运单信息-->
<!-- </div>-->
<!-- <el-row>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="" prop="reason">-->
<!-- <el-input v-model="preModel.reason" clearable>-->
<!-- <template slot="prepend" >修改原因</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="" prop="contactName">-->
<!-- <el-input v-model="preModel.contactName" clearable>-->
<!-- <template slot="prepend" >修改人</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="6">-->
<!-- <el-form-item label="" prop="contactTel">-->
<!-- <el-input v-model="preModel.contactTel" clearable maxlength="5">-->
<!-- <template slot="prepend" >修改人Tel</template>-->
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- </el-row>-->
<!-- </div>-->
<!-- </el-form>-->
<!-- <div slot="footer" class="dialog-footer" style="text-align: center">-->
<!-- <el-button @click="dialogFormVisible = false" size="medium"-->
<!-- style="width: 100px;background-color: #6F8294;color: #ffffff">取消</el-button>-->
<!-- <el-button type="success" size="medium" style="width: 100px" v-show="dialogStatus!=='sendUpdate'"-->
<!-- @click="dialogStatus ==='create'? createData():updateData()">保存</el-button>-->
<!-- <el-button type="primary" size="medium" style="width: 100px" v-show="dialogStatus==='sendUpdate'" @click="sendUpdate()">发送</el-button>-->
<!-- </div>-->
<!-- </el-dialog>-->
<el-dialog top="5vh" :title="dialogMap[dialogStatus]" :visible.sync="dialogFormVisible" width="90%">
<el-form ref="preFormData" :model="preModel" :rules="preRoles" label-position="right"
label-width="80px" size="mini" class="el-dialog-div">
... ... @@ -693,19 +199,21 @@
<el-row class="flight-info" style="padding-left: 90px;padding-right: 90px">
<el-col :span="6">
<el-form-item label="主单号" prop="awba">
<el-input :disabled="dialogStatus !== 'create'" v-model="awba" clearable style="width: 140px">
<el-input :disabled="dialogStatus !== 'create'" v-model="awba" clearable v-if="fenStatus === 'addAwbh'" disabled style="width: 140px">
</el-input>
<el-input :disabled="dialogStatus !== 'create'" v-model="awba" clearable v-else style="width: 140px">
</el-input>
</el-form-item>
</el-col>
<el-col :span="6" v-if="fenStatus === 'addAwbh'">
<el-form-item label="分单号" prop="awbh">
<el-input v-model="awbh" clearable>
<el-form-item label="分单号" prop="awbh" >
<el-input v-model="awbh" clearable style="width: 140px">
</el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="提前运抵">
<el-select v-model="preModel.ext3" class="filter-item" style="width: 140px" placeholder="请录入报关类型">
<el-select v-model="preModel.ext3" class="filter-item" clearable style="width: 140px" placeholder="请选择">
<el-option v-for="item in ext3" :key="item.value"
:label="item.label"
:value="item.value">
... ... @@ -715,7 +223,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="报关类型">
<el-select v-model="preModel.ext4" class="filter-item" style="width: 140px" placeholder="请录入报关类型">
<el-select v-model="preModel.ext4" class="filter-item" style="width: 140px" clearable placeholder="请选择报关类型">
<el-option v-for="item in customsDeclarationType" :key="item.value"
:label="item.label"
:value="item.value">
... ... @@ -725,7 +233,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="货物属性">
<el-select v-model="preModel.awbinfo.goodsAttribute" class="filter-item" style="width: 140px" placeholder="请录入货物属性">
<el-select v-model="preModel.awbinfo.goodsAttribute" class="filter-item" clearable style="width: 140px" placeholder="请选择货物属性">
<el-option v-for="item in goodsAttribute" :key="item.value"
:label="item.label"
:value="item.value">
... ... @@ -750,7 +258,7 @@
<el-form-item label="航班日期" prop="flightdate">
<el-date-picker :disabled="fenStatus === 'addAwbh'"
value-format="yyyy-MM-dd"
style="width: 280px"
style="width: 140px"
v-model="preModel.flightdate" align="left"
class="flight-date-tianbo"
type="date" placeholder="请输入航班日期" clearable/>
... ... @@ -840,7 +348,7 @@
<el-row class="flight-info" v-if="fenStatus !=='addAwbh'" style="padding-left: 90px;padding-right: 90px">
<el-col :span="6">
<el-form-item label="订舱代理">
<el-select v-model="preModel.bookingAgentId" class="filter-item" style="width: 140px" placeholder="请录入订舱代理">
<el-select v-model="preModel.bookingAgentId" clearable class="filter-item" style="width: 140px" placeholder="请录入订舱代理">
<el-option v-for="item in bookingAgentList" :key="item.id"
:label="item.forShort"
:value="item.id">
... ... @@ -850,7 +358,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="操作代理">
<el-select v-model="preModel.operatingAgentId" class="filter-item" placeholder="请录入操作代理">
<el-select v-model="preModel.operatingAgentId" clearable class="filter-item" placeholder="请录入操作代理">
<el-option v-for="item in operatingAgentList" :key="item.id"
:label="item.forShort"
:value="item.id">
... ... @@ -1042,7 +550,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="所属关区" prop="customcode">
<el-select v-model="preModel.customcode" class="filter-item" style="width: 140px" placeholder="请选择所属关区">
<el-select v-model="preModel.customcode" clearable class="filter-item" style="width: 140px" placeholder="请选择所属关区">
<el-option v-for="item in custom" :key="item.value"
:label="item.label"
:value="item.value">
... ... @@ -1064,7 +572,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="货物类型" prop="awbinfo.awbtype">
<el-select v-model="preModel.awbinfo.awbtype" class="filter-item" style="width: 140px" placeholder="请录入货物类型">
<el-select v-model="preModel.awbinfo.awbtype" clearable class="filter-item" style="width: 120px" placeholder="请录入货物类型">
<el-option v-for="item in customTypess" :key="item.value"
:label="item.label"
:value="item.value">
... ... @@ -1213,8 +721,6 @@
</el-table-column>
<el-table-column prop="conPhone" label="发货人电话" >
</el-table-column>
<el-table-column prop="enterprise" label="发货人企业代码" >
</el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button type="success" size="mini" @click="consignerClick(scope.row)">选择</el-button>
... ... @@ -1252,8 +758,6 @@
</el-table-column>
<el-table-column prop="conPhone" label="收货人电话" >
</el-table-column>
<el-table-column prop="enterprise" label="收货人企业代码" >
</el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button type="success" @click="consigneeClick(scope.row)" size="small">选择</el-button>
... ... @@ -1281,11 +785,13 @@
sendDeleteMt2201,
sendUpdateMt2201,
uploadFileExcel
} from '@/api/exitPre'
} from '@/api/exitPre';
import loginUserInfo from '../../api/base';
import {Message} from "element-ui";
import {getResponseForParam} from '@/api/responseDetail'
import { getList} from '../../api/consigner/consigner';
import { getList as neeList} from '../../api/consigner/consignee';
import {getListHzTypeList} from '../../api/shipper/shipper'
import {
validAwb,
validAlphabets,
... ... @@ -1350,6 +856,7 @@
limitSize: 5,
},
dialogSelectVisible: false,
loginUserInfo: loginUserInfo,
preQuery: {
pageSize: 1,
limitSize: 30,
... ... @@ -1359,9 +866,9 @@
flightdate: '',
originstation: '',
destinationstation: '',
userId:'',
userId:loginUserInfo.userId,
customCode:'',
enterpriseId:'',
enterpriseId:loginUserInfo.companyId,
messageType: ''
},
dialogMap: {
... ... @@ -1452,7 +959,7 @@
awba: [{required: true, trigger: 'blur', validator: validatorAwb}],
awbh: [{required: true, trigger: 'blur', validator: validatorAwbh}],
'awbinfo.paymodel': [{required: true, message: '付款方式必选', trigger: 'change'}],
goodsname: [{required: true, trigger: 'change', validator: validAlphabetsSpanceKey}],
goodsname: [{required: true, trigger: 'blur', validator: validAlphabetsSpanceKey}],
ex5: [{required: true, message: '货物描述不能为空', trigger: 'blur'}],
reason:[{required: true, message: '修改原因不能为空', trigger: 'blur'}],
contactName:[{required: true, message: '修改操作人不能为空', trigger: 'blur'}],
... ... @@ -1494,6 +1001,8 @@
contactTel: undefined,
bookingAgentId: undefined,
operatingAgentId: undefined,
userId: undefined,
enterpriseId: undefined,
awbinfo: {
pcs: undefined,
weight: undefined,
... ... @@ -1534,7 +1043,7 @@
awbtype: undefined
},
user: {
username: this.username
username: loginUserInfo.username
}
},
respModel: {
... ... @@ -1911,6 +1420,7 @@
this.preModel.customcode = this.preQuery.customcode
this.dialogStatus = 'create'
this.dialogFormVisible = true
this.userId();
this.$nextTick(() => {
this.$refs.preFormData.clearValidate()
})
... ... @@ -1947,7 +1457,8 @@
let para = {
pageSize: this.consignerQuery.pageSize,
limitSize: this.consignerQuery.limitSize,
companyName: this.consignerQuery.companyName
companyName: this.consignerQuery.companyName,
enterpriseId: loginUserInfo.companyId
};
getList(para).then((res) => {
this.consignerQuery.total = res.data.data.total;
... ... @@ -1972,7 +1483,8 @@
let para = {
pageSize: this.consigneeQuery.pageSize,
limitSize: this.consigneeQuery.limitSize,
companyName: this.consigneeQuery.companyName
companyName: this.consigneeQuery.companyName,
enterpriseId: loginUserInfo.companyId
};
neeList(para).then((res) => {
this.consigneeQuery.total = res.data.data.total;
... ... @@ -2076,6 +1588,7 @@
this.dialogStatus = undefined;
this.fenStatus = undefined;
this.preModel = Object.assign({}, row)
this.userId();
this.preModel.flightno = row.carrier+row.flightno;
this.dialogStatus = 'update'
if (row.awbh !== undefined && row.awbh !== ""){
... ... @@ -2303,10 +1816,9 @@
this.preModel.uuid = template.uuid
this.preModel.awba = template.awba
this.preModel.flightdate = template.flightdate
this.preModel.flightno = template.flightno
this.preModel.flightno = template.carrier+template.flightno
this.preModel.destinationstation = template.destinationstation
this.preModel.customcode = template.customcode
this.preModel.carrier = template.carrier
this.preModel.awbinfo.shprcountyr = template.awbinfo.shprcountyr
this.preModel.originstation = template.originstation
this.preModel.awbinfo.paymodel = template.awbinfo.paymodel
... ... @@ -2320,25 +1832,25 @@
this.preQuery.destinationstation = template.destinationstation
this.preQuery.customcode = template.customcode
this.preQuery.carrier = template.carrier
getMt2201ListForParam(this.preQuery).then(res => {
this.awbPiece = 0
this.awbWeight = 0
let residuePiece = 0
let residueWeight = 0
const childrenList = res.data.dataList[0].children
if (childrenList.length < 1) {
this.awbPiece = res.data.dataList[0].piece
this.awbWeight = res.data.dataList[0].weight
} else {
for (var i = 0; i < childrenList.length; i++) {
residuePiece += childrenList[i].piece
residueWeight += childrenList[i].weight
}
this.awbPiece = res.data.dataList[0].piece - residuePiece
this.awbWeight = res.data.dataList[0].weight - residueWeight
}
})
// getMt2201ListForParam(this.preQuery).then(res => {
// this.awbPiece = 0
// this.awbWeight = 0
// let residuePiece = 0
// let residueWeight = 0
// const childrenList = res.data.dataList[0].children
//
// if (childrenList.length < 1) {
// this.awbPiece = res.data.dataList[0].piece
// this.awbWeight = res.data.dataList[0].weight
// } else {
// for (var i = 0; i < childrenList.length; i++) {
// residuePiece += childrenList[i].piece
// residueWeight += childrenList[i].weight
// }
// this.awbPiece = res.data.dataList[0].piece - residuePiece
// this.awbWeight = res.data.dataList[0].weight - residueWeight
// }
// })
this.dialogStatus = 'create'
this.fenStatus = 'addAwbh'
this.dialogFormVisible = true
... ... @@ -2419,7 +1931,9 @@
uploadFile (item) {
const form = new FormData()
form.append('file', item.file)
form.append("username", JSON.parse(sessionStorage.getItem('user')).username);
form.append('userId', loginUserInfo.userId);
form.append('enterpriseId', loginUserInfo.companyId);
form.append("username", loginUserInfo.username);
uploadFileExcel(form).then(res =>{
if(res.data.count >0){
Message.success(res.data.respMessage)
... ... @@ -2429,6 +1943,15 @@
}
})
},
//模板下载
download () {
window.location.href = 'http://localhost:12021/static/excel导入模板.xls'
},
// 用户id 企业id 赋值
userId(){
this.preModel.userId = loginUserInfo.userId;
this.preModel.enterpriseId = loginUserInfo.companyId;
}
}
}
... ... @@ -2490,15 +2013,6 @@
text-align: center;
}
.el-dialog-div .flight-info .el-select--mini{
width: calc(100% - 100px)!important;
}
.el-dialog-div .flight-info .el-select--mini .el-input__inner,.el-dialog-div .flight-info .el-date-editor .el-input__inner{
border-top-left-radius: 0;
border-bottom-left-radius: 0;
}
.el-dialog-div .flight-info .select-lable{
line-height: 27px;
float:left;
... ...
... ... @@ -242,19 +242,19 @@
addFormVisible: false,
addFormRules: {
forShort: [
{ required: true, message: '请输入全称', trigger: 'blur' }
{ required: true, message: '请输入全称', trigger: 'change' }
],
fullName: [
{ required: true, message: '请输入简称', trigger: 'blur' }
{ required: true, message: '请输入简称', trigger: 'change' }
],
theShipperTypeList: [
{ required: true, message: '请选择货主类型', trigger: 'blur' }
{ required: true, message: '请选择货主类型', trigger: 'change' }
],
contacts: [
{ required: true, message: '请输入联系人', trigger: 'blur' }
{ required: true, message: '请输入联系人', trigger: 'change' }
],
phone: [
{ required: true, message: '请输入电话', trigger: 'blur' }
{ required: true, message: '请输入电话', trigger: 'change' }
]
},
... ...