Commit 36f59792 authored by dragondean@qq.com's avatar dragondean@qq.com
parents 122eb611 a1a34dec
...@@ -5,7 +5,7 @@ ENV = 'development' ...@@ -5,7 +5,7 @@ ENV = 'development'
VUE_APP_TITLE = 捷道管理系统 VUE_APP_TITLE = 捷道管理系统
# 捷道管理系统/开发环境 # 捷道管理系统/开发环境
VUE_APP_BASE_API = 'http://jd.apitest.jdshangmen.com' VUE_APP_BASE_API = 'http://localhost:48080'
# VUE_APP_BASE_API = '/api' # VUE_APP_BASE_API = '/api'
# 路由懒加载 # 路由懒加载
......
import request from '@/utils/request'
// 创建广告设置
export function createBanner(data) {
return request({
url: '/ecw/banner/create',
method: 'post',
data: data
})
}
// 更新广告设置
export function updateBanner(data) {
return request({
url: '/ecw/banner/update',
method: 'put',
data: data
})
}
// 删除广告设置
export function deleteBanner(id) {
return request({
url: '/ecw/banner/delete?id=' + id,
method: 'delete'
})
}
// 获得广告设置
export function getBanner(id) {
return request({
url: '/ecw/banner/get?id=' + id,
method: 'get'
})
}
// 获得广告设置分页
export function getBannerPage(query) {
return request({
url: '/ecw/banner/page',
method: 'get',
params: query
})
}
// 导出广告设置 Excel
export function exportBannerExcel(query) {
return request({
url: '/ecw/banner/export-excel',
method: 'get',
params: query,
responseType: 'blob'
})
}
import request from '@/utils/request'
// 创建广告弹窗
export function createBannerPop(data) {
return request({
url: '/ecw/banner-pop/create',
method: 'post',
data: data
})
}
// 更新广告弹窗
export function updateBannerPop(data) {
return request({
url: '/ecw/banner-pop/update',
method: 'put',
data: data
})
}
// 删除广告弹窗
export function deleteBannerPop(id) {
return request({
url: '/ecw/banner-pop/delete?id=' + id,
method: 'delete'
})
}
// 获得广告弹窗
export function getBannerPop(id) {
return request({
url: '/ecw/banner-pop/get?id=' + id,
method: 'get'
})
}
// 获得广告弹窗分页
export function getBannerPopPage(query) {
return request({
url: '/ecw/banner-pop/page',
method: 'get',
params: query
})
}
// 导出广告弹窗 Excel
export function exportBannerPopExcel(query) {
return request({
url: '/ecw/banner-pop/export-excel',
method: 'get',
params: query,
responseType: 'blob'
})
}
...@@ -68,3 +68,18 @@ export function customerDropDownList(query){ ...@@ -68,3 +68,18 @@ export function customerDropDownList(query){
query, query,
}) })
} }
//商品
export function commodityList(){
return request({
url:'/ecw/product/list',
method:'get',
})
}
export function createCommission(query){
return request({
url:'/ecw/customer-commission/create',
method:'post',
data:query
})
}
...@@ -34,6 +34,14 @@ export function getCustomerContacts(id) { ...@@ -34,6 +34,14 @@ export function getCustomerContacts(id) {
}) })
} }
// 获得客户联系人列表
export function getCustomerContactsList() {
return request({
url: '/ecw/customer-contacts/page',
method: 'get'
})
}
// 获得客户联系人分页 // 获得客户联系人分页
export function getCustomerContactsPage(query) { export function getCustomerContactsPage(query) {
return request({ return request({
......
import request from '@/utils/request'
// 创建跟进
export function createCustomerFollow(data) {
return request({
url: '/ecw/customer-follow/create',
method: 'post',
data: data
})
}
// 更新跟进
export function updateCustomerFollow(data) {
return request({
url: '/ecw/customer-follow/update',
method: 'put',
data: data
})
}
// 删除跟进
export function deleteCustomerFollow(id) {
return request({
url: '/ecw/customer-follow/delete?id=' + id,
method: 'delete'
})
}
// 获得跟进
export function getCustomerFollow(id) {
return request({
url: '/ecw/customer-follow/get?id=' + id,
method: 'get'
})
}
// 获得跟进分页
export function getCustomerFollowPage(query) {
return request({
url: '/ecw/customer-follow/page',
method: 'get',
params: query
})
}
// 导出跟进 Excel
export function exportCustomerFollowExcel(query) {
return request({
url: '/ecw/customer-follow/export-excel',
method: 'get',
params: query,
responseType: 'blob'
})
}
...@@ -34,6 +34,14 @@ export function getProduct(id) { ...@@ -34,6 +34,14 @@ export function getProduct(id) {
}) })
} }
// 获得产品列表
export function getProductList() {
return request({
url: '/ecw/product/list',
method: 'get'
})
}
// 获得产品分页 // 获得产品分页
export function getProductPage(query) { export function getProductPage(query) {
return request({ return request({
......
<template>
<el-table
border
:data="tableData"
style="">
<el-table-column
width="250px"
label="始发地">
<template v-slot="{ row, column, $index }">
<el-checkbox v-model="row.checked" @change="updateValue(true)">{{ warehouseList[$index].titleZh }}</el-checkbox>
</template>
</el-table-column>
<el-table-column
prop="objectiveId"
label="目的地">
<template v-slot="{ row, column, $index }">
<el-select v-model="tableData[$index].objectiveIds" multiple placeholder="请选择" style="width:100%" @change="updateValue(row.checked)">
<el-option
v-for="item in importCityList"
:key="item.id"
:label="item.titleZh"
:value="item.id">
</el-option>
</el-select>
</template>
</el-table-column>
</el-table>
</template>
<script>
export default {
name: 'CustomerLineTable',
props: {
warehouseList: Array,
importCityList: Array,
value: Array,
zhongPaoType: {
type: Number,
default: 0
}
},
data() {
return {
tableData: []
}
},
mounted() {
this.freshTableData()
},
methods: {
/**
* 解析 value
*/
freshTableData(){
const foo = []
let index = 0
this.warehouseList.forEach(e => {
let bar = this.tableData.length > 0 ? this.tableData[index] : {
departureId: e.id,
objectiveIds: [],
checked: false
}
const valueIndex = this.value.findIndex(v => v.departureId === e.id)
if(valueIndex !== -1) {
bar = { ...this.value[valueIndex], checked: true }
if(bar.objectiveIds.length === 0) {
bar.objectiveIds = []
} else {
bar.objectiveIds = bar.objectiveIds.split(',').map(m => parseInt(m))
}
}
foo.push(bar)
index++
})
this.tableData = foo
},
/**
* 更新 value
*/
updateValue(really = true){
if (!really) return
const result = []
this.tableData.forEach(e => {
if(e.checked){
const { departureId } = e
let objectiveIds = e.objectiveIds.join(',')
result.push({ departureId, objectiveIds, zhongPaoType: this.zhongPaoType })
}
})
this.$emit('input', result)
}
},
watch: {
value() {
this.freshTableData()
},
warehouseList() {
this.freshTableData()
}
}
}
</script>
<style scoped>
</style>
...@@ -172,11 +172,11 @@ export default { ...@@ -172,11 +172,11 @@ export default {
// 获取富文本组件实例 // 获取富文本组件实例
let quill = this.Quill; let quill = this.Quill;
// 如果上传成功 // 如果上传成功
if (res.code == 200) { if (res.code == 0) {
// 获取光标所在位置 // 获取光标所在位置
let length = quill.getSelection().index; let length = quill.getSelection().index;
// 插入图片 res.url为服务器返回的图片地址 // 插入图片 res.url为服务器返回的图片地址
quill.insertEmbed(length, "image", process.env.VUE_APP_BASE_API + res.fileName); quill.insertEmbed(length, "image", res.data);
// 调整光标到最后 // 调整光标到最后
quill.setSelection(length + 1); quill.setSelection(length + 1);
} else { } else {
...@@ -186,6 +186,20 @@ export default { ...@@ -186,6 +186,20 @@ export default {
handleUploadError() { handleUploadError() {
this.$message.error("图片插入失败"); this.$message.error("图片插入失败");
}, },
uuid() {
var s = [];
var hexDigits = "0123456789abcdef";
for (var i = 0; i < 36; i++) {
s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);
}
s[14] = "4"; // bits 12-15 of the time_hi_and_version field to 0010
s[19] = hexDigits.substr((s[19] & 0x3) | 0x8, 1); // bits 6-7 of the clock_seq_hi_and_reserved to 01
s[8] = s[13] = s[18] = s[23] = "-";
var uuid = s.join("");
return uuid;
},
}, },
}; };
</script> </script>
......
...@@ -2,6 +2,7 @@ import Vue from 'vue' ...@@ -2,6 +2,7 @@ import Vue from 'vue'
import Router from 'vue-router' import Router from 'vue-router'
/* Layout */ /* Layout */
import Layout from '@/layout' import Layout from '@/layout'
import query from '@/views/ecw/customer/query'
Vue.use(Router) Vue.use(Router)
...@@ -91,16 +92,6 @@ export const constantRoutes = [ ...@@ -91,16 +92,6 @@ export const constantRoutes = [
meta: {title: '字典数据', icon: '', activeMenu: '/system/dict'} meta: {title: '字典数据', icon: '', activeMenu: '/system/dict'}
} }
] ]
}, {
path: '/c',
component: Layout,
hidden: true,
children: [{
path: 'ecw/customer/edit/:customerId(\\d+)',
component: (resolve) => require(['@/views/ecw/customer/edit'], resolve),
name: 'Data',
meta: {title: '字典数据', icon: '', activeMenu: '/system/dict'}
}]
}, { }, {
path: '/job', path: '/job',
component: Layout, component: Layout,
...@@ -247,12 +238,28 @@ export const constantRoutes = [ ...@@ -247,12 +238,28 @@ export const constantRoutes = [
component: Layout, component: Layout,
hidden: true, hidden: true,
redirect: 'noredirect', redirect: 'noredirect',
children: [{ children: [
{
path: '/customerCommissionInfo/:dictId(\\d+)', path: '/customerCommissionInfo/:dictId(\\d+)',
component: (resolve) => require(['@/views/ecw/customerCommissionInfo/index'], resolve), component: (resolve) => require(['@/views/ecw/customerCommissionInfo/index'], resolve),
name: 'customerCommissionInfo', name: 'customerCommissionInfo',
meta: {title: '佣金详情', icon: '', activeMenu: '/customer/customerCommissionInfo'} meta: {title: '佣金详情', icon: '', activeMenu: '/customer/customerCommissionInfo'}
}] },
{
path: 'edit/:customerId(\\d+)',
component: (resolve) => import('@/views/ecw/customer/edit'),
props: true,
name: 'customerEdit',
meta: {title: '编辑客户', icon: '', activeMenu: '/customer/customer'}
},
{
path: 'query/:customerId(\\d+)',
component: (resolve) => import('@/views/ecw/customer/query'),
props: true,
name: 'customerQuery',
meta: {title: '客户详情', icon: '', activeMenu: '/customer/customer'}
}
]
}, },
] ]
......
...@@ -100,12 +100,15 @@ export const DICT_TYPE = { ...@@ -100,12 +100,15 @@ export const DICT_TYPE = {
AREA_CODE: 'area_code', // 区号 AREA_CODE: 'area_code', // 区号
SOCIAL: 'customer_social_tools', // 社交软件 SOCIAL: 'customer_social_tools', // 社交软件
IS_DEFAULT: 'is_default', // 默认联系人 IS_DEFAULT: 'is_default', // 默认联系人
CUSTOMER_FOLLOW_TYPE: 'customer_follow_type', // 跟进类型
CUSTOMER_FOLLOW_METHOD: 'customer_follow_method', // 跟进方式
COMMISSION_PRODUCT_APPROVAL:'commission_product_approval', //佣金备案 COMMISSION_PRODUCT_APPROVAL:'commission_product_approval', //佣金备案
SHIPPING_DECLARATION_TYPE:'shipping_declaration_type',//出货报关方式(与订单报关方式相同) SHIPPING_DECLARATION_TYPE:'shipping_declaration_type',//出货报关方式(与订单报关方式相同)
COMMISSION_TYPE:'commission_type',//佣金类型 COMMISSION_TYPE:'commission_type',//佣金类型
COMMISSION_DARK_TYPE :'commission_dark_type',//暗涌类型 COMMISSION_DARK_TYPE :'commission_dark_type',//暗涌类型
COMMISSION_CURRENCY_TYPE:'commission_currency_type',//佣金货币类型 COMMISSION_CURRENCY_TYPE:'commission_currency_type',//佣金货币类型
COMMISSION_UNIT:'commission_unit'//佣金货物单位 COMMISSION_UNIT:'commission_unit',//佣金货物单位
ECW_PORT_TYPE:'port_type', //港口类型
} }
......
This diff is collapsed.
This diff is collapsed.
...@@ -61,12 +61,12 @@ ...@@ -61,12 +61,12 @@
</el-table-column> </el-table-column>
<el-table-column label="汇率" align="center" prop="huilv" /> <el-table-column label="汇率" align="center" prop="huilv" />
<el-table-column label="排序" align="center" prop="aorder" /> <el-table-column label="排序" align="center" prop="aorder" />
<el-table-column label="" align="center" prop="createAt" width="180"> <!-- <el-table-column label="" align="center" prop="createAt" width="180">-->
<template slot-scope="scope"> <!-- <template slot-scope="scope">-->
<span>{{ parseTime(scope.row.createAt) }}</span> <!-- <span>{{ parseTime(scope.row.createAt) }}</span>-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column label="" align="center" prop="updateAt" width="180"> <el-table-column label="最后更新时间" align="center" prop="updateAt" width="180">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.updateAt) }}</span> <span>{{ parseTime(scope.row.updateAt) }}</span>
</template> </template>
......
This diff is collapsed.
...@@ -91,6 +91,8 @@ ...@@ -91,6 +91,8 @@
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button size="mini" type="text" icon="el-icon-view" @click="handleView(scope.row)"
v-hasPermi="['ecw:customer:query']">查看</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['ecw:customer:update']">修改</el-button> v-hasPermi="['ecw:customer:update']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)" <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
...@@ -600,6 +602,10 @@ export default { ...@@ -600,6 +602,10 @@ export default {
// this.open = true; // this.open = true;
// this.title = "添加客户"; // this.title = "添加客户";
}, },
/** 查看按钮操作 */
handleView(row) {
this.$router.push('/customer/query/' + row.id)
},
/** 修改按钮操作 */ /** 修改按钮操作 */
handleUpdate(row) { handleUpdate(row) {
this.$router.push('/customer/edit/' + row.id) this.$router.push('/customer/edit/' + row.id)
......
This diff is collapsed.
<template>
<view>
<el-row type="flex" style="margin-top: 15px;margin-bottom: 15px" justify="center">
<el-col :xs="24" :sm="24" :md="24" :lg="20" :xl="16">
<h2></h2>
<el-row :gutter="10">
<el-col>
<h2>查看</h2>
</el-col>
<el-col>
<el-button type="primary">主要按钮</el-button>
<el-button type="primary">主要按钮</el-button>
<el-button type="primary">主要按钮</el-button>
<el-button type="primary">主要按钮</el-button>
<el-button type="primary">主要按钮</el-button>
<el-button type="danger">危险按钮</el-button>
</el-col>
</el-row>
</el-col>
</el-row>
</view>
</template>
<script>
export default {
name: 'view'
}
</script>
<style scoped>
</style>
...@@ -17,7 +17,7 @@ export default { ...@@ -17,7 +17,7 @@ export default {
type:Array, type:Array,
default:()=>[] default:()=>[]
}, },
value:String, value:[String , Number],
labelKey:{ labelKey:{
type:String, type:String,
default:'label' default:'label'
...@@ -32,9 +32,15 @@ export default { ...@@ -32,9 +32,15 @@ export default {
selectVal:'' selectVal:''
} }
}, },
mounted() {
this.selectVal = this.value;
},
watch:{ watch:{
selectVal(val){ selectVal(val){
this.$emit('input',val) this.$emit('input',val)
},
value(val){
this.selectVal = val;
} }
} }
} }
......
<template>
<el-form>
<el-form-item label="商品类型">
<div class="shanping-type">
<div class="tool">
<el-input placeholder="商品"></el-input>
</div>
<div class="box">
<div class="label">
商品类型
</div>
<div class="custom">
<custom-selectors-dictionary label-key="attrName" value-key="id" :options="commodityType"></custom-selectors-dictionary>
</div>
</div>
<div class="box">
<div class="label">
佣金
</div>
<div class="custom">
<el-input></el-input>
</div>
<div class="custom">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_CURRENCY_TYPE)"></custom-selectors-dictionary>
</div>
<div class="custom">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_UNIT)"></custom-selectors-dictionary>
</div>
</div>
<div>
<el-button type="primary">添加</el-button>
</div>
</div>
</el-form-item>
</el-form>
</template>
<script>
//暗涌加产品
import {DICT_TYPE, getDictDatas} from "@/utils/dict";
import customSelectorsDictionary from "@/views/ecw/customerCommissionInfo/customSelectorsDictionary";
export default {
name: "darkServantAndProduct",
components:{
customSelectorsDictionary
},
props:{
commodityType:{
type:Array,
default:()=>[]
}
},
data(){
return{
DICT_TYPE,
getDictDatas,
}
},
mounted() {
console.log(this.commodityType,'commodityType')
},
watch:{
}
}
</script>
<style scoped lang="scss">
.shanping-type {
display: flex;
.tool {
width: 150px;
}
.box {
margin-left: 20px;
display: flex;
.label {
width: 80px;
vertical-align: middle;
font-size: 14px;
color: #606266;
font-weight: 700;
}
.custom {
width: 150px;
margin-right:10px;
}
}
}
</style>
<template>
<div>
<div class="column">
<div class="label">
佣金:
</div>
<div class="content">
<div class="item label"></div>
<div class="item"><el-input></el-input></div>
<div class="item"> <custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_CURRENCY_TYPE)"></custom-selectors-dictionary></div>
<div class="item">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_UNIT)"></custom-selectors-dictionary>
</div>
</div>
<div class="content">
<div class="item label"></div>
<div class="item"><el-input></el-input></div>
<div class="item"> <custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_CURRENCY_TYPE)"></custom-selectors-dictionary></div>
<div class="item">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_UNIT)"></custom-selectors-dictionary>
</div>
</div>
<el-button>添加</el-button>
</div>
</div>
</template>
<script>
//暗佣-达标返佣
import customSelectorsDictionary from "@/views/ecw/customerCommissionInfo/customSelectorsDictionary";
import {DICT_TYPE, getDictDatas} from "@/utils/dict";
export default {
name: "darkServantAndRebate",
components:{
customSelectorsDictionary
},
data(){
return{
DICT_TYPE,
getDictDatas
}
}
}
</script>
<style scoped lang="scss">
.column{
display: flex;
align-items: center;
.label{
width: 50px;
white-space: nowrap;
vertical-align: middle;
font-size: 14px;
color: #606266;
font-weight: 700;
}
}
.content{
display: flex;
align-items: center;
margin-right: 10px;
.item{
text-align: right;
width: 150px;
margin: 0 5px;
}
.label{
width: 50px;
}
}
</style>
<template>
<div>
<div class="mingServantAndDarkServant">
<div class="box">
<div class="label">暗佣佣金:</div>
<div class="content">
<div class="item">
<el-input></el-input>
</div>
<div class="item">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_CURRENCY_TYPE)"></custom-selectors-dictionary>
</div>
<div class="item">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_UNIT)"></custom-selectors-dictionary>
</div>
</div>
</div>
<div class="title">
<span class="label">成本价:</span>原价-暗佣佣金
</div>
<div class="box">
<div class="label">销售价上调:</div>
<div class="content">
<div class="item">
<el-input></el-input>
</div>
<div class="item">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_CURRENCY_TYPE)"></custom-selectors-dictionary>
</div>
<div class="item">
<custom-selectors-dictionary :options="getDictDatas(DICT_TYPE.COMMISSION_UNIT)"></custom-selectors-dictionary>
</div>
</div>
</div>
<div class="title">
<span class="label"> 实际佣金返点:</span>销售价-成本价
</div>
</div>
</div>
</template>
<script>
//暗佣+明佣
import customSelectorsDictionary from "@/views/ecw/customerCommissionInfo/customSelectorsDictionary";
import {DICT_TYPE, getDictDatas} from "@/utils/dict";
export default {
name: "mingServantAndDarkServant",
components:{
customSelectorsDictionary
},
data(){
return{
getDictDatas,
DICT_TYPE
}
}
}
</script>
<style scoped lang="scss">
.mingServantAndDarkServant{
margin-top: 10px;
.box{
display: flex;
align-items: center;
.label{
vertical-align: middle;
font-size: 14px;
color: #606266;
font-weight: 700;
}
.content{
display: flex;
align-items: center;
.item{
margin-right: 20px;
}
}
}
.title{
margin: 15px 0;
.label{
vertical-align: middle;
font-size: 14px;
color: #606266;
font-weight: 700;
}
}
}
</style>
...@@ -20,6 +20,15 @@ ...@@ -20,6 +20,15 @@
<el-table-column label="中文名称" align="center" prop="titleZh" /> <el-table-column label="中文名称" align="center" prop="titleZh" />
<el-table-column label="英文名称" align="center" prop="titleEn" /> <el-table-column label="英文名称" align="center" prop="titleEn" />
<el-table-column prop="portType" label="港口类型" align="center">
<template slot-scope="scope">
<div>
{{ portTypeName(scope.row.portType) }}
</div>
</template>
</el-table-column>
<el-table-column label="国家" align="center" prop="countryZh" /> <el-table-column label="国家" align="center" prop="countryZh" />
<el-table-column label="省" align="center" prop="provinceZh" /> <el-table-column label="省" align="center" prop="provinceZh" />
<el-table-column label="城市" align="center" prop="cityZh" /> <el-table-column label="城市" align="center" prop="cityZh" />
...@@ -88,6 +97,11 @@ ...@@ -88,6 +97,11 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="港口类型" prop="portType">
<el-select v-model="form.portType" placeholder="请选择">
<el-option v-for="dict in portTypeDatas" :key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</el-form-item>
<el-form-item label="码头编号" prop="number"> <el-form-item label="码头编号" prop="number">
<el-input v-model="form.number" placeholder="请输入码头编号" /> <el-input v-model="form.number" placeholder="请输入码头编号" />
...@@ -107,6 +121,7 @@ ...@@ -107,6 +121,7 @@
<script> <script>
import { createDock, updateDock, deleteDock, getDock, getDockPage, exportDockExcel } from "@/api/ecw/dock"; import { createDock, updateDock, deleteDock, getDock, getDockPage, exportDockExcel } from "@/api/ecw/dock";
import { getListTree } from "@/api/ecw/region"; import { getListTree } from "@/api/ecw/region";
import { getDictDatas, DICT_TYPE } from '@/utils/dict';
export default { export default {
name: "Dock", name: "Dock",
...@@ -163,10 +178,24 @@ export default { ...@@ -163,10 +178,24 @@ export default {
titleZh: [{ required: true, message: "中文名称不能为空", trigger: "blur" }], titleZh: [{ required: true, message: "中文名称不能为空", trigger: "blur" }],
titleEn: [{ required: true, message: "英文名称不能为空", trigger: "blur" }], titleEn: [{ required: true, message: "英文名称不能为空", trigger: "blur" }],
sort: [{ required: true, message: "排序不能为空", trigger: "blur" }] sort: [{ required: true, message: "排序不能为空", trigger: "blur" }]
} },
portTypeDatas: getDictDatas(DICT_TYPE.ECW_PORT_TYPE)
}; };
}, },
computed: {
portTypeName() {
return portType => {
for(let index in this.portTypeDatas) {
let portTypeItem = this.portTypeDatas[index];
if(portTypeItem.value == portType) {
return portTypeItem.label;
}
}
}
},
},
watch: { watch: {
'form.countryId'(newV, oldV) { 'form.countryId'(newV, oldV) {
if(oldV && oldV != newV) { if(oldV && oldV != newV) {
......
...@@ -121,9 +121,6 @@ ...@@ -121,9 +121,6 @@
</el-dialog> </el-dialog>
<!-- 留言详情--> <!-- 留言详情-->
<el-dialog title="留言详情" :visible.sync="leavingShow" width="500px" append-to-body> <el-dialog title="留言详情" :visible.sync="leavingShow" width="500px" append-to-body>
<el-row class="el-row-leaving" :gutter="10">
<el-col :span="4">客户编号:</el-col><el-col :span="12">{{}}</el-col>
</el-row>
<el-row class="el-row-leaving" :gutter="10"> <el-row class="el-row-leaving" :gutter="10">
<el-col :span="4">姓名:</el-col><el-col :span="12">{{messageVal.name ? messageVal.name : ''}}</el-col> <el-col :span="4">姓名:</el-col><el-col :span="12">{{messageVal.name ? messageVal.name : ''}}</el-col>
</el-row> </el-row>
......
...@@ -213,7 +213,7 @@ export default { ...@@ -213,7 +213,7 @@ export default {
let text = row.status === CommonStatusEnum.ENABLE ? "启用" : "停用"; let text = row.status === CommonStatusEnum.ENABLE ? "启用" : "停用";
this.$modal.confirm('确认要' + text + '"' + row.titleZh + '"吗?').then(function() { this.$modal.confirm('确认要' + text + '"' + row.titleZh + '"吗?').then(function() {
// return changeUserStatus(row.id, row.status); // return changeUserStatus(row.id, row.status);
return updateUnitStatus({id:row.id,status:!row.status?CommonStatusEnum.DISABLE:CommonStatusEnum.ENABLE}); return updateUnitStatus({id:row.id,status:row.status});
}).then(() => { }).then(() => {
this.$modal.msgSuccess(text + "成功"); this.$modal.msgSuccess(text + "成功");
......
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