提交 65de5e1b authored 作者: huaxinzhu's avatar huaxinzhu

添加商品,bug修复01

上级 d7bb2b7b
...@@ -215,16 +215,25 @@ ...@@ -215,16 +215,25 @@
}, },
mounted() { mounted() {
//debugger
//深拷贝一份最开始的数据,为初始化准备 //深拷贝一份最开始的数据,为初始化准备
//this.goodsInfoDataClone = this.deepClone(this.goodsinfodata); //this.goodsInfoDataClone = this.deepClone(this.goodsinfodata);
this.goodsInfoForm = this.goodsinfodata; if(this.goodsinfodata.goods_id) {
if( this.goodsInfoForm.imgs.length > 0 ) { this.goodsInfoForm = this.goodsinfodata;
this.goodsInfoForm.imgs.forEach( (item )=> { if( this.goodsInfoForm.imgs.length > 0 ) {
let objImg = { 'url': '' } this.goodsInfoForm.imgs.forEach( (item )=> {
objImg.url = item; let objImg = { 'url': '' }
this.goodsImgFileList.push(objImg); objImg.url = item;
}) this.goodsImgFileList.push(objImg);
})
}
}else {
this.goodsInfoForm.categoryStr = this.goodsinfodata.categoryStr;
this.goodsInfoForm.categoryList = this.goodsinfodata.categoryList;
} }
//console.log("tup",this.goodsImgFileList) //console.log("tup",this.goodsImgFileList)
// 获取 省 // 获取 省
this.getArea(); this.getArea();
......
...@@ -86,6 +86,12 @@ ...@@ -86,6 +86,12 @@
export default { export default {
name: 'Index', name: 'Index',
props: {
option: {
type: Number,
required: true
}
},
components: { components: {
Goodsinfomation, Goodsinfomation,
GoodsSpecifications, GoodsSpecifications,
...@@ -93,12 +99,6 @@ ...@@ -93,12 +99,6 @@
Goodsimg, Goodsimg,
Goodsaftersale, Goodsaftersale,
}, },
props: {
option: {
type: Number,
required: true
}
},
data() { data() {
return { return {
loading: false, loading: false,
...@@ -155,6 +155,7 @@ ...@@ -155,6 +155,7 @@
created() { created() {
// option 商品的id // option 商品的id
//debugger
if( this.option && this.option !== 0 ) { if( this.option && this.option !== 0 ) {
let data = { goodsId: this.option}; let data = { goodsId: this.option};
getGoodsNew(data).then(res => { getGoodsNew(data).then(res => {
...@@ -690,6 +691,9 @@ ...@@ -690,6 +691,9 @@
.blue-block-goods-title { .blue-block-goods-title {
margin: 0 20px 0 0; margin: 0 20px 0 0;
} }
.good-details-body {
height: 100%;
}
/deep/.good-details-body .el-card__body { /deep/.good-details-body .el-card__body {
height: 100%; height: 100%;
padding: 15px 20px 0px 20px; padding: 15px 20px 0px 20px;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论