Commit 627c6bfb authored by youjie's avatar youjie

日历

parent 1c417703
...@@ -22,15 +22,18 @@ ...@@ -22,15 +22,18 @@
<!--x.isdateformat=1 改成日历模式 --> <!--x.isdateformat=1 改成日历模式 -->
<view class="sku-title">{{ x.attr_group_name }} </view> <view class="sku-title">{{ x.attr_group_name }} </view>
<view> <view>
<!--
<view class="sku-chi" :style="{ <view class="sku-chi" :style="{
background: y.attr_id == x.checkId ? mc : '#eee', background: y.attr_id == x.checkId ? mc : '#eee',
color: y.attr_id == x.checkId ? '#FFF' : '#333' 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)"> :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> <image :src="y.pic_url" class="img" v-if="i == 0 && y.pic_url"></image>
<text class="val">{{ y.attr_name }}</text> <text class="val">{{ y.attr_name }}</text>
</view> </view> -->
<calendar @finish="chosenDateResult" :immediately="true" :defaultDate="currentPrice.startDate" :priceList="x.attr_list"></calendar>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
...@@ -67,7 +70,11 @@ ...@@ -67,7 +70,11 @@
</template> </template>
<script> <script>
import calendar from "./sign/index.vue";
export default { export default {
components: {
calendar,
},
model: {}, model: {},
props: { props: {
borderRadius: { borderRadius: {
...@@ -102,6 +109,7 @@ ...@@ -102,6 +109,7 @@
data() { data() {
return { return {
currentPrice: {},
goodimage: '', goodimage: '',
goodprice: '', goodprice: '',
goodamount: '', goodamount: '',
...@@ -226,6 +234,15 @@ ...@@ -226,6 +234,15 @@
// this.g = this.good; // this.g = this.good;
}, },
methods: { methods: {
chosenDateResult(result) {
console.log(result,'----result')
return
let price
this.g.attr_groups.forEach(x=>{
price = x.attr_list[result.priceObj]
})
this.currentPrice = price;
},
getfu() { getfu() {
let fucolor = this.colorRgb(this.fu); let fucolor = this.colorRgb(this.fu);
...@@ -559,7 +576,8 @@ ...@@ -559,7 +576,8 @@
.goodsku .sku-box { .goodsku .sku-box {
padding: 0; padding: 0;
max-height: 300px; /* max-height: 300px; */
max-height: 400px;
overflow: hidden; overflow: hidden;
overflow-y: auto; overflow-y: auto;
display: block; display: block;
......
//节假日信息
const day=[
{
year:2022,
month:1,
festival:[
{name:'元旦',day:1},
{name:'除夕',day:31},
]
},
{
year:2022,
month:2,
festival:[
{name:'春节',day:1},
{name:'元宵',day:15},
{name:'情人节',day:14}
]
},
{
year:2022,
month:3,
festival:[
{name:'妇女节',day:8},
]
},
{
year:2022,
month:4,
festival:[
{name:'清明',day:4},
]
},
{
year:2022,
month:5,
festival:[
{name:'劳动节',day:1},
{name:'青年节',day:4},
{name:'母亲节',day:10},
]
},
{
year:2021,
month:6,
festival:[
{name:'儿童节',day:1},
{name:'父亲节',day:21},
{name:'端午',day:14},
]
},
{
year:2021,
month:7,
festival:[
{name:'建党节',day:1}
]
},
{
year:2021,
month:8,
festival:[
{name:'建军节',day:1},
{name:'七夕',day:14},
{name:'中元节',day:22},
]
},
{
year:2021,
month:9,
festival:[
{name:'教师节',day:10},
{name:'中秋',day:21}
]
},
{
year:2021,
month:10,
festival:[
{name:'国庆',day:1},
{name:'重阳',day:14}
]
},
{
year:2021,
month:11,
festival:[
{name:'感恩节',day:26}
]
},
{
year:2021,
month:12,
festival:[
{name:'平安夜',day:24},
{name:'圣诞节',day:25}
]
}
]
export default day
\ No newline at end of file
This diff is collapsed.
...@@ -503,7 +503,7 @@ ...@@ -503,7 +503,7 @@
secondary: "", secondary: "",
detailContent: "", detailContent: "",
recommend: [], recommend: [],
showSku: false, showSku: true,
ot: 0, ot: 0,
currentSku: {}, currentSku: {},
isExsitGoods: true, isExsitGoods: 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