Commit ba5c2e24 authored by zhengke's avatar zhengke

修改页面

parent 9b58c74d
...@@ -53,8 +53,8 @@ ...@@ -53,8 +53,8 @@
</el-col> </el-col>
</el-row> </el-row>
<el-form-item label="样式选择"> <el-form-item label="样式选择">
<div class="block-box" v-for="(item,index) in styleList" :key="index" :class="isActive==index?'active':''" <div class="block-box" v-for="(item,index) in styleList" :key="index" :class="isActive==item.Id?'active':''"
@click="getStyleType(index,item.Style)"> @click="getStyleType(item.Id,item.Style)">
<img src="../../assets/img/storeDesign/select.png" class="Cubeselect" alt="" /> <img src="../../assets/img/storeDesign/select.png" class="Cubeselect" alt="" />
<div class="opacity"></div> <div class="opacity"></div>
<el-button class="choose-button" type="primary">启用该样式</el-button> <el-button class="choose-button" type="primary">启用该样式</el-button>
...@@ -150,27 +150,35 @@ ...@@ -150,27 +150,35 @@
}], }],
//样式选择枚举 //样式选择枚举
styleList: [{ styleList: [{
Id:0,
Style: 1, Style: 1,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-1.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-1.png'
}, { }, {
Id:1,
Style: 2, Style: 2,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-2.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-2.png'
}, { }, {
Id:2,
Style: 3, Style: 3,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-3.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-3.png'
}, { }, {
Id:3,
Style: 4, Style: 4,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-4.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube1-4.png'
}, { }, {
Id:4,
Style: 2, Style: 2,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube2-1.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube2-1.png'
}, { }, {
Id:5,
Style: 3, Style: 3,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube2-2.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube2-2.png'
}, { }, {
Id:6,
Style: 4, Style: 4,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube2-3.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube2-3.png'
}, { }, {
Id:7,
Style: 4, Style: 4,
ImgUrl: this.domainManager().ImageUrl + '/Static/cube3-1.png' ImgUrl: this.domainManager().ImageUrl + '/Static/cube3-1.png'
}], }],
...@@ -246,6 +254,7 @@ ...@@ -246,6 +254,7 @@
}, res => { }, res => {
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.addMsg = res.data.data; this.addMsg = res.data.data;
this.isActive=this.addMsg.Style;
if (this.addMsg.MagicDataList && this.addMsg.MagicDataList.length > 0) { if (this.addMsg.MagicDataList && this.addMsg.MagicDataList.length > 0) {
this.addMsg.MagicDataList.forEach((item, index) => { this.addMsg.MagicDataList.forEach((item, index) => {
this.defaultMsg[index] = item; this.defaultMsg[index] = item;
...@@ -273,8 +282,9 @@ ...@@ -273,8 +282,9 @@
}) })
}, },
//点击选择样式 //点击选择样式
getStyleType(index, Style) { getStyleType(Id, Style) {
this.isActive = index; this.isActive = Id;
this.addMsg.Style=Id;
this.addMsg.MagicDataList = []; this.addMsg.MagicDataList = [];
for (var i = 0; i < Style; i++) { for (var i = 0; i < Style; i++) {
this.addMsg.MagicDataList.push(this.defaultMsg[i]); this.addMsg.MagicDataList.push(this.defaultMsg[i]);
......
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