msb_beta
ch 2 years ago
parent 89d389c9f2
commit 1e8d4645c2

@ -2,7 +2,7 @@
* @Author: ch
* @Date: 2022-03-17 17:42:32
* @LastEditors: ch
* @LastEditTime: 2022-04-20 19:49:51
* @LastEditTime: 2022-04-21 11:38:48
* @Description: 项目接口请求统一处理器返回一个需要token和不需要token的请求封装方法
*/
@ -69,8 +69,6 @@ const repeatVerify = (option)=>{
* @param {*} option
*/
const clearRepeat = (option) =>{
console.log(repeatFlag)
repeatFlag = repeatFlag.filter( i => {
return i !== JSON.stringify({
url : option.url,
@ -78,7 +76,6 @@ const clearRepeat = (option) =>{
data : option.data
})
});
console.log(repeatFlag)
}
// 不需要token的接口封装

@ -0,0 +1,69 @@
<!--
* @Author: ch
* @Date: 2022-04-21 09:54:15
* @LastEditors: ch
* @LastEditTime: 2022-04-21 10:59:21
* @Description: file content
-->
<template>
<view class="ui-money">
<text v-if="prefix" class="ui-money--prefix"></text>
<text class="ui-money--price">{{moneyStr}}</text>
<text v-if="flaot && suffix" class="ui-money--suffix">.{{moneyArr[1]}}</text>
</view>
</template>
<script>
export default {
props : {
money : {
type : Number | String,
default : '0'
},
flaot : {
type : Boolean,
default : false
},
prefix : {
type : Boolean,
default : false
},
suffix : {
type : Boolean,
default : false
}
},
computed : {
moneyStr (){
let priceStr = '',
intNum = this.moneyArr[0],
floatNum = this.moneyArr[1];
//
if(!this.prefix){
priceStr = `${intNum}`;
}else{
priceStr = intNum;
}
//
if(!this.suffix){
priceStr += floatNum ? `.${floatNum}` : '';
}
return priceStr;
},
moneyArr (){
let moneyArr = this.money.toString().split('.');
// 0 00
if(this.flaot){
if(!moneyArr[1]){
moneyArr[1] = '00';
}else if(moneyArr[1] < 10){
moneyArr[1] = `0${moneyArr[1]}`;
}
}
return moneyArr;
}
}
}
</script>
<style lang="scss" scoped>
</style>

@ -1,2 +1,2 @@
<!DOCTYPE html><html lang=zh-CN><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><title>马士兵严选</title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/static/index.a5c69d49.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/static/js/chunk-vendors.b5602bf5.js></script><script src=/static/js/index.fe63b50a.js></script></body></html>
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/static/index.a5c69d49.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/static/js/chunk-vendors.b5602bf5.js></script><script src=/static/js/index.8a30f788.js></script></body></html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 539 B

After

Width:  |  Height:  |  Size: 619 B

File diff suppressed because one or more lines are too long

@ -1 +1 @@
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-cart-cart"],{"0ba2":function(n,t,a){"use strict";var e=a("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=e(a("734f")),c={components:{PageCtx:r.default},onShow:function(){this.$refs.page&&this.$refs.page.open()},mounted:function(){this.$refs.page.open()}};t.default=c},"0ddb":function(n,t,a){var e=a("24fb");t=e(!1),t.push([n.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场https://ext.dcloud.net.cn上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者建议你使用scss预处理并在插件代码中直接使用这些变量无需 import 这个文件方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者插件使用者你可以通过修改这些变量来定制自己的插件主题实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 透明度 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 间距 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */uni-page-body[data-v-529a9cda]{background:#f5f5f5;padding-bottom:%?120?%}body.?%PAGE?%[data-v-529a9cda]{background:#f5f5f5}',""]),n.exports=t},"4a3c":function(n,t,a){"use strict";var e=a("c267"),r=a.n(e);r.a},b408:function(n,t,a){"use strict";var e;a.d(t,"b",(function(){return r})),a.d(t,"c",(function(){return c})),a.d(t,"a",(function(){return e}));var r=function(){var n=this,t=n.$createElement,a=n._self._c||t;return a("PageCtx",{ref:"page",staticClass:"page",attrs:{type:"inner"}})},c=[]},c267:function(n,t,a){var e=a("0ddb");"string"===typeof e&&(e=[[n.i,e,""]]),e.locals&&(n.exports=e.locals);var r=a("4f06").default;r("1edb3d4a",e,!0,{sourceMap:!1,shadowMode:!1})},e81f:function(n,t,a){"use strict";a.r(t);var e=a("0ba2"),r=a.n(e);for(var c in e)"default"!==c&&function(n){a.d(t,n,(function(){return e[n]}))}(c);t["default"]=r.a},f662:function(n,t,a){"use strict";a.r(t);var e=a("b408"),r=a("e81f");for(var c in r)"default"!==c&&function(n){a.d(t,n,(function(){return r[n]}))}(c);a("4a3c");var o,u=a("f0c5"),s=Object(u["a"])(r["default"],e["b"],e["c"],!1,null,"529a9cda",null,!1,e["a"],o);t["default"]=s.exports}}]);
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-cart-cart"],{"0ba2":function(n,t,a){"use strict";var e=a("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=e(a("734f")),c={components:{PageCtx:r.default},onShow:function(){this.$refs.page&&this.$refs.page.open()},mounted:function(){this.$refs.page.open()}};t.default=c},"0ddb":function(n,t,a){var e=a("24fb");t=e(!1),t.push([n.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场https://ext.dcloud.net.cn上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者建议你使用scss预处理并在插件代码中直接使用这些变量无需 import 这个文件方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者插件使用者你可以通过修改这些变量来定制自己的插件主题实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 透明度 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 间距 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */uni-page-body[data-v-529a9cda]{background:#f5f5f5;padding-bottom:%?120?%}body.?%PAGE?%[data-v-529a9cda]{background:#f5f5f5}',""]),n.exports=t},"4a3ce":function(n,t,a){"use strict";var e=a("c267"),r=a.n(e);r.a},b408:function(n,t,a){"use strict";var e;a.d(t,"b",(function(){return r})),a.d(t,"c",(function(){return c})),a.d(t,"a",(function(){return e}));var r=function(){var n=this,t=n.$createElement,a=n._self._c||t;return a("PageCtx",{ref:"page",staticClass:"page",attrs:{type:"inner"}})},c=[]},c267:function(n,t,a){var e=a("0ddb");"string"===typeof e&&(e=[[n.i,e,""]]),e.locals&&(n.exports=e.locals);var r=a("4f06").default;r("1edb3d4a",e,!0,{sourceMap:!1,shadowMode:!1})},e81f:function(n,t,a){"use strict";a.r(t);var e=a("0ba2"),r=a.n(e);for(var c in e)"default"!==c&&function(n){a.d(t,n,(function(){return e[n]}))}(c);t["default"]=r.a},f662:function(n,t,a){"use strict";a.r(t);var e=a("b408"),r=a("e81f");for(var c in r)"default"!==c&&function(n){a.d(t,n,(function(){return r[n]}))}(c);a("4a3ce");var o,u=a("f0c5"),s=Object(u["a"])(r["default"],e["b"],e["c"],!1,null,"529a9cda",null,!1,e["a"],o);t["default"]=s.exports}}]);

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -2,7 +2,7 @@
* @Author: ch
* @Date: 2022-03-23 10:29:07
* @LastEditors: ch
* @LastEditTime: 2022-04-20 19:05:54
* @LastEditTime: 2022-04-21 11:04:56
* @Description: file content
-->
<template>
@ -11,7 +11,8 @@
<view class="title">{{max.name}}</view>
<view class="desc">{{max.name}}</view>
<!-- <view class="tag"></view> -->
<view class="price">{{max.startingPrice}}</view>
<!-- <view class="price">{{max.startingPrice}}</view> -->
<UiMoney class="price" :money="max.startingPrice" prefix></UiMoney>
<view class="img-box">
<image class="img" :src="max.mainPicture"/>
</view>
@ -22,7 +23,7 @@
<view class="min--info-box-right">
<view class="desc">{{minOne.name}}</view>
<!-- <view class="tag"></view> -->
<view class="price">{{minOne.startingPrice}}</view>
<UiMoney class="price" :money="minOne.startingPrice" prefix></UiMoney>
</view>
<view class="img-box">
<image class="img" :src="minOne.mainPicture"/>
@ -35,7 +36,7 @@
<view class="min--info-box-right">
<view class="desc">{{minTwo.name}}</view>
<view class="tag"></view>
<view class="price">{{minTwo.startingPrice}}</view>
<UiMoney class="price" :money="minTwo.startingPrice" prefix></UiMoney>
</view>
<view class="img-box">
<image class="img" :src="minTwo.mainPicture"/>
@ -46,7 +47,9 @@
</view>
</template>
<script>
import UiMoney from '../../../components/UiMoney.vue'
export default {
components: { UiMoney },
data(){
return{}
},
@ -93,7 +96,6 @@ export default {
}
.price{
margin: 24rpx 0 10rpx 20rpx;
color: $color-yellow4;
}
}
@ -130,5 +132,17 @@ export default {
width: 160rpx;
height: 160rpx;
}
.desc{
margin-top: 0;
}
}
/deep/ .price{
text{
color: $color-yellow4;
font-size: $font-size-lg;
}
.ui-money--prefix{
font-size: $font-size-sm;
}
}
</style>

@ -2,7 +2,7 @@
* @Author: ch
* @Date: 2022-03-23 10:07:48
* @LastEditors: ch
* @LastEditTime: 2022-04-20 18:21:52
* @LastEditTime: 2022-04-21 11:13:03
* @Description: file content
-->
<template>
@ -25,16 +25,19 @@
<view v-for="item in data.activityProductListVO" :key="item.activityProductId">
<image class="seckill--item-img" :src="item.productMainPicture"></image>
<view class="seckill--item-pirce-box">
<text class="seckill--item-pirce-title">秒杀价</text>
<text class="seckill--item-pirce">{{item.activityPrice}}</text>
<!-- <text class="seckill--item-pirce-title">秒杀价</text> -->
<UiMoney class="seckill--item-pirce" :money="item.activityPrice" prefix></UiMoney>
<!-- <text class="seckill--item-pirce">{{item.activityPrice}}</text> -->
</view>
<!-- <text class="seckill--item-original-pirce">50</text> -->
<text class="seckill--item-original-pirce">{{item.originalPrice}}</text>
</view>
</view>
</view>
</template>
<script>
import UiMoney from '../../../components/UiMoney.vue';
export default {
components: { UiMoney },
props : {
data : {
type : Object,
@ -206,7 +209,7 @@ export default {
line-height: 44rpx;
background: linear-gradient(90deg, #FFE7DE 0%, #FFFFFF 100%);
border-radius: 20rpx;
padding-left:20rpx;
text-align: center;
margin: 20rpx 0 10rpx 0;
}
&-pirce-title{
@ -229,6 +232,17 @@ export default {
}
/deep/ {
.seckill--item-pirce{
text{
color: $color-yellow4;
font-size: $font-size-lg;
}
.ui-money--prefix{
font-size: $font-size-base;
}
}
}
</style>

@ -2,7 +2,7 @@
* @Author: ch
* @Date: 2022-03-20 14:14:53
* @LastEditors: ch
* @LastEditTime: 2022-04-20 15:29:10
* @LastEditTime: 2022-04-21 11:27:13
* @Description: file content
-->
<template>
@ -45,13 +45,15 @@
<view class="play">
<text class="play--title">支付方式</text>
<radio-group>
<u-cell title="微信支付" :border="false">
<u-cell title="微信支付" :border="false" @click="payType = 'wxpay'">
<image class="play--icon" slot="icon" src="@/static/order/wx.png"/>
<radio class="play--radio" slot="right-icon" color="#FF875B"></radio>
<radio class="play--radio" slot="right-icon" color="#FF875B"
:checked="payType == 'wxpay'" ></radio>
</u-cell>
<u-cell title="支付宝支付" :border="false">
<u-cell title="支付宝支付" :border="false" @click="payType = 'alipay'">
<image class="play--icon" slot="icon" src="@/static/order/zfb.png"/>
<radio class="play--radio" slot="right-icon" color="#FF875B"></radio>
<radio class="play--radio" slot="right-icon" color="#FF875B"
:checked="payType == 'alipay'"></radio>
</u-cell>
</radio-group>
</view>
@ -85,7 +87,8 @@ export default {
return {
address : {},
userMessage : '',
orderInfo : {}
orderInfo : {},
payType : 'wxpay'
}
},
onLoad(){
@ -95,6 +98,7 @@ export default {
uni.$on('changeAddress',(item, type)=>{
if(type == 'submitOrder'){
this.address = item;
this.getBeforeOrder(item.id);
}
});
//
@ -104,12 +108,15 @@ export default {
/**
* 获取预订单信息将要提交的订单信息
*/
async getBeforeOrder(){
async getBeforeOrder(addressId){
const query = this.$Route.query;
let res = {};
//
if(query.mode === 'cart'){
res = await ApiGetBeforeCartOrder({cartIds: query.ids})
res = await ApiGetBeforeCartOrder({
cartIds: query.ids,
recipientAddressId : addressId
})
}
//
if(query.mode === 'buyNow'){
@ -117,7 +124,8 @@ export default {
productSkuId : query.skuId,
quantity : query.num,
// 1 2
activityType : query.activityType
activityType : query.activityType,
recipientAddressId : addressId
});
}
if(res.error){

Binary file not shown.

Before

Width:  |  Height:  |  Size: 539 B

After

Width:  |  Height:  |  Size: 619 B

Loading…
Cancel
Save