细节修改

version/0412
fanfan 9 months ago
parent 6b24ab0c96
commit 835ce3db59
  1. 4
      api/goods/index.js
  2. 37
      pages/goods/components/setPrice.vue
  3. 22
      pages/goods/detail.vue
  4. 4
      pages/news3/components/category.vue
  5. 13
      pages/news3/components/setRange.vue
  6. 4
      pages/news3/vipPrice.vue
  7. 5
      uni_modules/vk-uview-ui/components/u-calendar/u-calendar.vue

@ -86,3 +86,7 @@ export const skuInfo = (goodsId, goodsSkuId, param) => {
export const poster = param => {
return request.get(api.poster, param)
}
// 店长设置秒杀价
export const editGoodsSeckillPrice = param => {
return request.post('StoreKeeper/editGoodsSeckillPrice', param)
}

@ -7,8 +7,8 @@
</view>
<view class="priceContainer">
<view class="priceCon">
<!-- <text>秒杀价</text><input type="text" v-model="secondPrice" class="input" value=""
placeholder="秒杀价格可低于成本价" /> -->
<text>秒杀价</text><input type="text" v-model="secondPrice" class="input"
placeholder="秒杀价格可低于成本价" />
</view>
<view class="priceTime">
<view class="text">秒杀区间</view>
@ -24,10 +24,10 @@
</view>
<view class="priceCon" style="justify-content: space-between;">
<text>秒杀限购</text>
<u-switch v-model="secondQuota" @change="change" activeColor='#55BD6A' inactiveColor='#F1F1F1'>
<u-switch v-model="secondQuota" size='35' @change="change" activeColor='#55BD6A' inactiveColor='#F1F1F1'>
</u-switch>
</view>
<view class="priceCon">
<view class="priceCon" v-if="secondQuota">
<text>每人限购</text>
<input type="number" style="width: 130rpx;margin-right: 15rpx;" class="input" v-model="quotaNum"
placeholder="请输入" />
@ -44,7 +44,7 @@
</view>
</u-popup>
</view>
<u-calendar v-model="timeShow" mode="range" @change="getTime" range-color='#FF6257' range-bg-color='#FFBDBA'
<u-calendar v-model="timeShow" mode="multiple" minDate='0' @change="getTime" :pickerOptions="pickerOptions" range-color='#FF6257' range-bg-color='#FFBDBA'
active-bg-color='#FF6257'></u-calendar>
</template>
@ -57,9 +57,14 @@
startTime: '',
endTime: '',
secondPrice: '',
secondQuota: '1',
secondQuota: 1,
quotaNum: '',
fontColor:'#262626'
fontColor:'#262626',
pickerOptions:{
disabledDate(time){
return true
}
}
}
},
methods: {
@ -83,15 +88,15 @@
if (!this.endTime) {
return this.$toast('请选择结束时间')
}
if (!this.quotaNum) {
if (!this.quotaNum&&this.secondQuota) {
return this.$toast('请输入限购次数')
}
this.$emit('getprice', {
startTime: this.startTime,
endTime: this.endTime,
secondPrice: this.secondPrice,
quotaNum: this.quotaNum,
secondQuota: this.secondQuota
quotaNum: this.secondQuota?this.quotaNum:'',
secondQuota: this.secondQuota?1:2
})
}
}
@ -101,7 +106,7 @@
<style lang="scss" scoped>
::v-deep .u-btn--primary {
background-color: #FF6257 !important;
border-color: #FF6257;
border-color: #FF6257 !important;
}
.afterSales {
padding: 32upx;
@ -128,10 +133,10 @@
margin-bottom: 20rpx;
text {
width: 150rpx;
width: 140rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
line-height: 72rpx;
line-height: 70rpx;
text-align: left;
font-style: normal;
text-transform: none;
@ -139,7 +144,7 @@
.input {
width: 350rpx;
height: 72rpx;
height: 68rpx;
background: #FFFFFF;
border-radius: 4rpx;
border: 1rpx solid #EBEBEB;
@ -202,9 +207,9 @@
}
.btnGroup {
margin: 40upx 0;
margin: 40rpx;
display: flex;
justify-content: center;
justify-content: space-between;
align-items: center;
.reset {

@ -553,15 +553,19 @@
methods: {
getprice(e) {
console.log(e)
let that=this
let params = {
secondPrice: e.secondPrice,
startTime: e.startTime,
endTime: e.endTime,
secondQuota: e.secondQuota,
quotaNum: e.quotaNum
}
GoodsApi.editGoodsPrice(params).then(res => {
goods_id:that.goods.goods_id,
sku_id:that.goods.skuList[0].id,
seckill_price: e.secondPrice,
sec_start_time: e.startTime,
sec_end_time: e.endTime,
is_limit: e.secondQuota,
limit_times: e.quotaNum
}
GoodsApi.editGoodsSeckillPrice(params).then(res => {
if (res.status == 200) {
console.log(res)
that.$toast("设置成功");
this.$refs.setRange.afterSale = false;
setTimeout(() => {
@ -2001,4 +2005,8 @@
color: #ffffff;
transform: translate(40%, -20%);
}
::v-deep .u-btn--primary {
background-color: #FF6257 !important;
border-color: #FF6257 !important;
}
</style>

@ -85,9 +85,9 @@
padding: 32upx;
.btnGroup {
margin: 40upx 0;
margin: 40rpx;
display: flex;
justify-content: center;
justify-content: space-between;
align-items: center;
.reset {

@ -6,9 +6,9 @@
请设置价格区间
</view>
<view class="priceContainer">
<u-input placeholder="最低价格" @input="startPrice" v-model="min"></u-input>
<text style="margin:0 30upx;">-</text>
<u-input placeholder="最高价格" @input="endPrice" v-model="max"></u-input>
<u-input placeholder="最低价格" @input="startPrice" style="padding: 0 30rpx;background-color: #E9E9E9;text-align: center;width: 200rpx;border-radius: 46rpx;" v-model="min"></u-input>
<text style="margin:30rpx;">-</text>
<u-input placeholder="最高价格" @input="endPrice" style="padding: 0 30rpx;background-color: #E9E9E9;text-align: center;width: 200rpx;border-radius: 46rpx;" v-model="max"></u-input>
</view>
<view class="btnGroup">
<view class="reset" @click="reset">
@ -94,7 +94,7 @@
display: flex;
align-items: center;
justify-content: center;
padding-top: 56upx;
padding-top: 40upx;
margin-top: 34upx;
border-top: 1px solid #EAEAEA;
@ -104,6 +104,7 @@
border-radius: 22px 22px 22px 22px;
opacity: 1;
text-align: center;
background-color: #F3F3F3 !important
}
::v-deep .u-input__input {
@ -112,9 +113,9 @@
}
.btnGroup {
margin: 60upx 0;
margin: 40rpx;
display: flex;
justify-content: center;
justify-content: space-between;
align-items: center;
.reset {

@ -38,7 +38,7 @@
<text v-else style="color: #8F8F8F;">请设置</text>
</view>
<view class="rangeInput fix">
<input type="text" style="border: none;line-height:70rpx"
<input type="text" style="border: none;line-height:70rpx;height: 70rpx;"
@input="onRate($event,index_1,index_2)" placeholder="请设置"
v-model="val.add_price_rate" />
</view>
@ -62,7 +62,7 @@
<view class="price_rat" v-if="type==0">
<view class="price_set">
<view class="price_txt">
<text>最低利润率</text><input type="text" @input="onSetRate" :min="5" style="border: none;"
<text>最低利润率</text><input type="text" @input="onSetRate" :min="5" style="border: none;height: 60rpx;border-bottom: 1rpx solid #E6E6E6;padding-left: 10rpx;"
placeholder="请输入最低利润率" v-model="min_profit" /><text style="position: absolute;right: 10rpx;">%</text>
</view>
<view class="price_bnt" @click="onSubmitProfit" :style="{'opacity': min_profit?1:0.6 }">

@ -32,7 +32,6 @@
<view class="u-calendar__content__item"></view>
</block>
<view class="u-calendar__content__item" :class="{
'u-hover-class':openDisAbled(year,month,index+1),
'u-calendar__content--start-date': (mode == 'range' && startDate==`${year}-${month}-${index+1}`) || mode== 'date',
'u-calendar__content--end-date':(mode== 'range' && endDate==`${year}-${month}-${index+1}`) || mode == 'date'
}" :style="{backgroundColor: getColor(index,1)}" v-for="(item, index) in daysArr" :key="index"
@ -418,7 +417,7 @@
},
dateClick: function(day) {
day += 1;
if (!this.openDisAbled(this.year, this.month, day)) {
// if (!this.openDisAbled(this.year, this.month, day)) {
this.day = day;
let date = `${this.year}-${this.month}-${day}`;
if (this.mode == 'date') {
@ -444,7 +443,7 @@
this.isStart = true;
}
}
}
// }
},
close() {
// v-modelfalse

Loading…
Cancel
Save