修改配置
This commit is contained in:
parent
2b408d6584
commit
d01089d910
@ -51,9 +51,16 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
cost:{
|
cost:{
|
||||||
|
list:{
|
||||||
|
url: `${config.API_URL}/cost.config.const.list`,
|
||||||
|
name: "费用类别常量列表",
|
||||||
|
post: async function (data) {
|
||||||
|
return await http.post(this.url, data);
|
||||||
|
},
|
||||||
|
},
|
||||||
set:{
|
set:{
|
||||||
url: `${config.API_URL}/cost.category.add`,
|
url: `${config.API_URL}/cost.category.add`,
|
||||||
name: "新增费用列别配置",
|
name: "新增费用类别配置",
|
||||||
post: async function (data) {
|
post: async function (data) {
|
||||||
return await http.post(this.url, data);
|
return await http.post(this.url, data);
|
||||||
},
|
},
|
||||||
|
|||||||
@ -113,7 +113,7 @@ export default {
|
|||||||
return await http.post(this.url, params);
|
return await http.post(this.url, params);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
roleCode: {
|
roleCode: {
|
||||||
url: `${config.API_URL}/authorize.role.codes`,
|
url: `${config.API_URL}/authorize.role.codes`,
|
||||||
name: "角色对应CODE列表",
|
name: "角色对应CODE列表",
|
||||||
|
|||||||
@ -1,24 +1,17 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-main>
|
<el-main v-loading="listLoading" element-loading-text="加载中...">
|
||||||
<div class="mailView">
|
<div class="mailView">
|
||||||
<div class="headerBox ">
|
<div class="headerBox ">
|
||||||
<div class="title">费用类别配置</div>
|
<div class="title">费用类别配置</div>
|
||||||
<div class="item">
|
<div class="item" v-for="(item,index) in list" :key="index">
|
||||||
<span class="name">上架费</span>
|
<span class="name">{{item.label}}</span>
|
||||||
<el-input type="text" v-model="cost.name" :size="size" placeholder="上架费"></el-input>
|
<span class="inputView" v-if="item.cost">
|
||||||
</div>
|
<div class="inputItem" v-for="(em,ind) in item.cost" :key="ind">
|
||||||
<div class="item">
|
<el-input type="text" v-model="em.price" :size="size" placeholder="费用"></el-input>
|
||||||
<span class="name">服务费</span>
|
<el-input type="text" v-model="em.description" :size="size" placeholder="描述"></el-input>
|
||||||
<el-input type="text" v-model="cost.price" :size="size" placeholder="服务费"></el-input>
|
</div>
|
||||||
</div>
|
</span>
|
||||||
<div class="item">
|
|
||||||
<span class="name">物料厂商费</span>
|
|
||||||
<el-input type="text" v-model="cost.company_id" :size="size" placeholder="物料厂商费"></el-input>
|
|
||||||
</div>
|
|
||||||
<div class="item">
|
|
||||||
<span class="name">备件费</span>
|
|
||||||
<el-input type="text" v-model="cost.description" :size="size" placeholder="备件费"></el-input>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnView">
|
<div class="btnView">
|
||||||
@ -35,12 +28,9 @@ export default {
|
|||||||
data(){
|
data(){
|
||||||
return{
|
return{
|
||||||
size:'small',
|
size:'small',
|
||||||
|
listLoading:false,
|
||||||
loading:false,
|
loading:false,
|
||||||
cost:{
|
list:[],
|
||||||
code:'',
|
|
||||||
description:'',
|
|
||||||
price:''
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@ -48,17 +38,37 @@ export default {
|
|||||||
},
|
},
|
||||||
methods:{
|
methods:{
|
||||||
async getCost() {
|
async getCost() {
|
||||||
const res = await this.$API.setup.cost.get.post();
|
this.listLoading = true;
|
||||||
|
const res = await this.$API.setup.cost.list.post();
|
||||||
|
this.listLoading = false;
|
||||||
if(res.code == 200){
|
if(res.code == 200){
|
||||||
if(res.data && res.data.length>0){
|
if(res.data && res.data.length>0){
|
||||||
this.cost = res.data[0];
|
res.data.forEach(item=>{
|
||||||
|
if(item.cost && item.cost.length ===0){
|
||||||
|
item.cost = [
|
||||||
|
{code:item.value,description:'',price:''}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
this.list = res.data;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
setList(){
|
||||||
|
let arr = new Array();
|
||||||
|
this.list.forEach(item=>{
|
||||||
|
item.cost.forEach(em=>{
|
||||||
|
if(em.price!=''){
|
||||||
|
arr.push({code:em.code,price:em.price,description:em.description})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
return arr
|
||||||
|
},
|
||||||
async save() {
|
async save() {
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
let params = {
|
let params = {
|
||||||
cost:[this.cost]
|
cost:this.setList()
|
||||||
}
|
}
|
||||||
const res = await this.$API.setup.cost.set.post(params);
|
const res = await this.$API.setup.cost.set.post(params);
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
@ -74,26 +84,32 @@ export default {
|
|||||||
.mailView{
|
.mailView{
|
||||||
.headerBox{
|
.headerBox{
|
||||||
border-bottom: 1px solid #e8e8e8;
|
border-bottom: 1px solid #e8e8e8;
|
||||||
padding-bottom: 5px;
|
|
||||||
.title{
|
.title{
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
padding: 10px 0;
|
padding: 10px 0;
|
||||||
}
|
}
|
||||||
.item{
|
.item{
|
||||||
margin-bottom: 15px;
|
margin-bottom: 10px;
|
||||||
|
display: flex;
|
||||||
|
align-items: flex-start;
|
||||||
.name{
|
.name{
|
||||||
width: 90px;
|
width: 90px;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
}
|
}
|
||||||
|
.inputItem{
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.btnView{
|
.btnView{
|
||||||
padding: 15px 0;
|
padding: 15px 0;
|
||||||
}
|
}
|
||||||
::v-deep .el-input{
|
::v-deep .el-input{
|
||||||
width: 480px;
|
width: 280px;
|
||||||
|
margin-right: 20px;
|
||||||
|
margin-bottom: 5px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-main>
|
<el-main v-loading="listLoading" element-loading-text="加载中...">
|
||||||
<div class="mailView">
|
<div class="mailView">
|
||||||
<div class="headerBox">
|
<div class="headerBox">
|
||||||
<div class="title">K3接口配置</div>
|
<div class="title">K3接口配置</div>
|
||||||
@ -50,6 +50,7 @@ export default {
|
|||||||
return{
|
return{
|
||||||
size:'small',
|
size:'small',
|
||||||
loading:false,
|
loading:false,
|
||||||
|
listLoading:false,
|
||||||
inter:{
|
inter:{
|
||||||
active_status:false,
|
active_status:false,
|
||||||
account_id:'',
|
account_id:'',
|
||||||
@ -66,7 +67,9 @@ export default {
|
|||||||
},
|
},
|
||||||
methods:{
|
methods:{
|
||||||
async getMail() {
|
async getMail() {
|
||||||
|
this.listLoading = true;
|
||||||
const res = await this.$API.setup.k3.get.post();
|
const res = await this.$API.setup.k3.get.post();
|
||||||
|
this.listLoading = false;
|
||||||
if(res.code == 200){
|
if(res.code == 200){
|
||||||
if(res.data && res.data.account_id){
|
if(res.data && res.data.account_id){
|
||||||
this.inter = res.data;
|
this.inter = res.data;
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-main>
|
<el-main v-loading="listLoading" element-loading-text="加载中...">
|
||||||
<div class="mailView">
|
<div class="mailView">
|
||||||
<div class="headerBox">
|
<div class="headerBox">
|
||||||
<div class="title">自动维修邮件同步</div>
|
<div class="title">自动维修邮件同步</div>
|
||||||
@ -44,6 +44,7 @@ export default {
|
|||||||
data(){
|
data(){
|
||||||
return{
|
return{
|
||||||
size:'small',
|
size:'small',
|
||||||
|
listLoading:false,
|
||||||
loading:false,
|
loading:false,
|
||||||
mail:{
|
mail:{
|
||||||
active_status:false,
|
active_status:false,
|
||||||
@ -59,7 +60,9 @@ export default {
|
|||||||
},
|
},
|
||||||
methods:{
|
methods:{
|
||||||
async getMail() {
|
async getMail() {
|
||||||
|
this.listLoading = true;
|
||||||
const res = await this.$API.setup.mail.get.post();
|
const res = await this.$API.setup.mail.get.post();
|
||||||
|
this.listLoading = false;
|
||||||
if(res.code == 200){
|
if(res.code == 200){
|
||||||
if(res.data && res.data.alias){
|
if(res.data && res.data.alias){
|
||||||
this.mail = res.data;
|
this.mail = res.data;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user