Commit 2741ef39 authored by 邓春圆's avatar 邓春圆

渠道修改添加页面

parent 1104af2a
<template>
<div style="width: 100%;min-width: 100px">
<el-select v-model="val">
<el-option :value="item.id" :label="$l(item, 'title') + item.fuhao" v-for="(item) in options"></el-option>
</el-select>
</div>
</template>
<script>
export default {
name: "currency-select",
props:{
options:{
type:Array,
default:()=>[]
},
value:{
type: [Number,String],
}
},
data(){
return{
val:''
}
},
watch:{
val(){
this.$emit('input',this.val)
}
}
}
</script>
<style scoped>
</style>
......@@ -19,14 +19,13 @@
</el-button>
</el-col>
</el-row>
<el-row :gutter="10">
<el-col :span="3">
第1阶梯
</el-col>
<el-col :span="6">
<div style="display: flex;align-items: center;">
<el-input></el-input> - <el-input></el-input> / <el-input></el-input>
<el-input></el-input> - <el-input></el-input> / <weight-select :options="unitList"></weight-select>
</div>
</el-col>
</el-row>
......@@ -37,7 +36,9 @@
</el-col>
<el-col :span="6">
<div style="display: flex;align-items: center;">
<el-input></el-input><el-input></el-input> / <el-input></el-input>
<el-input></el-input>
<currency-select :options="currencyList"></currency-select>
/ <weight-select :options="unitList"></weight-select>
</div>
</el-col>
</el-row>
......@@ -45,8 +46,23 @@
</template>
<script>
import {getCurrencyPage} from "@/api/ecw/currency";
import CurrencySelect from "@/views/ecw/channelMnage/componrnts/currency-select.vue";
import {getUnitList} from "@/api/ecw/unit";
import WeightSelect from "@/views/ecw/channelMnage/componrnts/weight-select.vue";
export default {
name: "packaging-type"
name: "packaging-type",
components: {WeightSelect, CurrencySelect},
created() {
getCurrencyPage(this.params).then(res => this.currencyList = res.data.list)
getUnitList().then(res => this.unitList = res.data)
},
data(){
return {
currencyList:[],
unitList:[]
}
}
}
</script>
......
<template>
<div style="min-width: 100px;width: 100%;">
<el-select v-model="val">
<el-option v-for="(item, index) in options" :value="item.id" :key="index" :label="$l(item ,'title')" ></el-option>
</el-select>
</div>
</template>
<script>
export default {
name: "weight-select",
props:{
options:{
type:Array,
default:()=>[]
},
value:{
type:[String,Number]
}
},
data(){
return{
val:''
}
},
watch:{
val(){
this.$emit('input', this.val)
}
}
}
</script>
<style scoped>
</style>
......@@ -44,6 +44,11 @@
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="归属仓库">
<el-checkbox-group v-model="value">
<el-checkbox v-for="(item ,index) in warehouseList" :key="item.id" :label="item.id">
{{$l(item,'title')}}
</el-checkbox>
</el-checkbox-group>
</el-form-item>
</el-col>
<el-col :span="12">
......@@ -72,7 +77,11 @@
</el-row>
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="可出商品特性"></el-form-item>
<el-form-item label="可出商品特性">
<el-select multiple value>
<el-option v-for="(item, index) in attrList" :value="item.id" :label="$l(item, 'attrName')"></el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<div style="display: flex; justify-content: space-between;">
......@@ -86,7 +95,7 @@
</div>
<el-row :gutter="20">
<el-col :span="2">包装类型1:</el-col>
<el-col :span="5"><el-input></el-input></el-col>
<el-col :span="5"> <dict-selector :type="DICT_TYPE.ECW_PACKAGING_TYPE"></dict-selector></el-col>
<el-col :span="16">
<packaging-type></packaging-type>
</el-col>
......@@ -108,10 +117,34 @@
<script>
import PackagingType from "@/views/ecw/channelMnage/componrnts/packaging-type.vue";
import {getProductAttrList} from "@/api/ecw/productAttr";
import {getWarehouseList} from "@/api/ecw/warehouse";
import {DICT_TYPE} from "@/utils/dict";
export default {
name: "edit",
components: {PackagingType}
computed: {
DICT_TYPE() {
return DICT_TYPE
}
},
components: {PackagingType},
data(){
return{
attrList:[],
warehouseList:[],
value:[]
}
},
created() {
getProductAttrList().then(response => {
this.attrList = response.data;
})
getWarehouseList({tradeType:2}).then(r =>{
console.log('r',r.data)
this.warehouseList = r.data
})
}
}
</script>
......
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