Commit d6f27025 authored by 黄奎's avatar 黄奎

页面修改

parent 1c417703
......@@ -16,9 +16,21 @@
</view>
</view>
</view>
<scroll-view scroll-y class="sku-box">
<view class="sku-item" v-for="(x, i) in g.attr_groups" :key="i">
<view class="sku-item" v-for="(x, i) in g.attr_groups" :key="i" v-if="x.isdateformat==0">
<view class="sku-title">{{ x.attr_group_name }} </view>
<view>
<view class="sku-chi" :style="{
background: y.attr_id == x.checkId ? mc : '#eee',
color: y.attr_id == x.checkId ? '#FFF' : '#333'
}"
:class="{ disable: notStockGood.indexOf(y.attr_id) != -1 }" v-for="(y, yi) in x.attr_list" :key="yi" @click="clickSkuItemHandler(yi, i)">
<image :src="y.pic_url" class="img" v-if="i == 0 && y.pic_url"></image>
<text class="val">{{ y.attr_name }}</text>
</view>
</view>
</view>
<view class="sku-item" v-for="(x, i) in g.attr_groups" v-if="x.isdateformat==1">
<!--x.isdateformat=1 改成日历模式 -->
<view class="sku-title">{{ x.attr_group_name }} </view>
<view>
......@@ -30,7 +42,6 @@
<image :src="y.pic_url" class="img" v-if="i == 0 && y.pic_url"></image>
<text class="val">{{ y.attr_name }}</text>
</view>
</view>
</view>
</scroll-view>
......@@ -204,7 +215,6 @@
if (this.g.attr_groups && this.g.attr_groups.length > 0) {
this.g.attr_groups.forEach(x => {
if (!this.skuObj) {
//(x.checkId = 0), (x.checkName = x.attr_group_name);
(x.checkId = 0), (x.checkName = x.attr_list[0].attr_name);
x.checkId = x.attr_list[0].attr_id;
} else {
......@@ -223,16 +233,13 @@
this.formatChosenTips();
}
);
// this.g = this.good;
},
methods: {
getfu() {
let fucolor = this.colorRgb(this.fu);
var RgbValue = fucolor.replace("rgb(", "").replace(")", "");
var RgbValueArry = RgbValue.split(",");
var grayLevel = RgbValueArry[0] * 0.299 + RgbValueArry[1] * 0.587 + RgbValueArry[2] * 0.114;
console.log(grayLevel)
if (grayLevel >= 192) {
this.btn1.color = this.mc;
} else {
......
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