Commit 5b9747ec by fuqiang

【商家端】添加商品

parent 4f213b46
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
auto-complete="off" auto-complete="off"
placeholder="请输入用户名" placeholder="请输入用户名"
@keyup.enter.native="handleLogin" @keyup.enter.native="handleLogin"
maxlength="11"
> >
<i slot="prefix" class="icon-yonghuming" /> <i slot="prefix" class="icon-yonghuming" />
</el-input> </el-input>
......
...@@ -159,6 +159,7 @@ ...@@ -159,6 +159,7 @@
shopInfo: getStore({ shopInfo: getStore({
name: 'shopInfo' name: 'shopInfo'
}) || {}, }) || {},
uploadExampleDiaLog:'查看认证视频',
setUploadExampleDiaLog:false, setUploadExampleDiaLog:false,
//如果是编辑则需要加载数据 //如果是编辑则需要加载数据
loading: false, loading: false,
...@@ -323,7 +324,7 @@ ...@@ -323,7 +324,7 @@
titleValue() { titleValue() {
return (spec, row) => { return (spec, row) => {
for (let s of row.specs) { for (let s of row.specs) {
if (s.specId == spec.specId){ if (s.specId == spec.specId){
return s.name return s.name
}else if (s.id == spec.specId) { }else if (s.id == spec.specId) {
return s.specName return s.specName
...@@ -390,11 +391,13 @@ ...@@ -390,11 +391,13 @@
//回填数据 //回填数据
refill(data) { refill(data) {
let skus = data.skus let skus = data.skus
console.log(skus)
if(skus && skus.length > 0) { if(skus && skus.length > 0) {
let specs = skus[0].specs.map(r => { let specs = skus[0].specs.map(r => {
console.log(r)
return { return {
specId: r.id, specId: r.specId,
specName: r.name specName: r.specName
} }
}) })
this.specs = specs this.specs = specs
......
...@@ -102,6 +102,7 @@ ...@@ -102,6 +102,7 @@
}, },
// 添加 // 添加
add() { add() {
this.id = null;
this.goodsEditVue=true this.goodsEditVue=true
}, },
// 查看详情 // 查看详情
......
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