✨ feat(ID1000835):【临】补充原单价、优惠价的价格显示;

This commit is contained in:
Haiyi
2022-12-20 16:17:45 +08:00
parent 35ef32584f
commit 4788f2dca2
10 changed files with 294 additions and 220 deletions
+129 -120
View File
@@ -1,133 +1,142 @@
.goodsBox {
display: flex;
margin-bottom: 32px;
// justify-content: space-between;
.pic {
width: 118px;
height: 118px;
border-radius: 8px;
margin-right: 32px;
}
.rightGoodbox {
padding-bottom: 31px;
border-bottom: 1px solid #efefef;
display: flex;
margin-bottom: 32px;
justify-content: space-between;
// margin-right: 32px;
width: 538px;
// justify-content: space-between;
.pic {
width: 118px;
height: 118px;
border-radius: 8px;
margin-right: 32px;
.leftFontsbox {
.title {
width: 260px;
height: 34px;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
margin-bottom: 8px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
background: 0, 124, 247;
}
.productName {
width: 260px;
height: 30px;
font-size: 24px;
font-weight: 400;
color: #000000;
margin-bottom: 16px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.productNums {
font-size: 24px;
font-weight: 400;
color: #000000;
}
.productName {
font-size: 24px;
font-weight: 400;
color: #000000;
height: 40px;
}
}
.rightGoodbox {
padding-bottom: 31px;
border-bottom: 1px solid #efefef;
.rightFontsbox {
.moneyFlex {
margin-bottom: 14px;
display: flex;
justify-content: space-between;
// margin-right: 32px;
width: 538px;
justify-content: flex-end;
.lastBox {
font-size: 28px;
font-weight: 500;
text-decoration: line-through;
color: #7f7f7f;
}
.money {
margin-left: 15px;
font-size: 28px;
font-weight: 500;
color: #f41a39;
}
}
.leftFontsbox {
.title {
width: 260px;
height: 34px;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
margin-bottom: 8px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
background: 0, 124, 247;
}
.inputBox {
width: 189px;
height: 64px;
border-radius: 8px;
border: 1px solid #979797;
display: flex;
.productName {
width: 260px;
height: 30px;
font-size: 24px;
font-weight: 400;
color: #000000;
margin-bottom: 16px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.reduceBox {
width: 64px;
height: 64px;
display: flex;
align-items: center;
justify-content: center;
.productNums {
font-size: 24px;
font-weight: 400;
color: #000000;
}
.productName {
font-size: 24px;
font-weight: 400;
color: #000000;
height: 40px;
}
.reduce {
width: 20px;
height: 3px;
background: #000000;
border-radius: 1px;
opacity: 0.8;
}
}
.rightFontsbox {
.money {
display: flex;
justify-content: flex-end;
font-size: 28px;
font-weight: 500;
color: #F41A39;
margin-bottom: 14px;
}
.inputBox {
width: 189px;
height: 64px;
border-radius: 8px;
border: 1px solid #979797;
display: flex;
.reduceBox {
width: 64px;
height: 64px;
display: flex;
align-items: center;
justify-content: center;
.reduce {
width: 20px;
height: 3px;
background: #000000;
border-radius: 1px;
opacity: 0.8;
}
}
.numsBox {
width: 61px;
display: flex;
align-items: center;
justify-content: center;
font-size: 24px;
font-weight: 400;
color: #000000;
text-align: center;
}
.addBox {
width: 64px;
height: 64px;
display: flex;
line-height: 64px;
align-items: center;
justify-content: center;
flex-direction: column;
color: #000;
font-size: 35px;
}
}
.addtine {
width: 64px;
height: 64px;
display: flex;
align-items: center;
justify-content: center;
color: #000;
font-size: 35px;
border-radius: 8px;
border: 1px solid #979797;
float: right;
}
.numsBox {
width: 61px;
display: flex;
align-items: center;
justify-content: center;
font-size: 24px;
font-weight: 400;
color: #000000;
text-align: center;
}
.addBox {
width: 64px;
height: 64px;
display: flex;
line-height: 64px;
align-items: center;
justify-content: center;
flex-direction: column;
color: #000;
font-size: 35px;
}
}
.addtine {
width: 64px;
height: 64px;
display: flex;
align-items: center;
justify-content: center;
color: #000;
font-size: 35px;
border-radius: 8px;
border: 1px solid #979797;
float: right;
}
}
}
}
}
+9 -1
View File
@@ -25,6 +25,9 @@ interface props {
buyNums?: number | string
id?: number
weight_error?: number | string
last_bulk_price?: number
last_length_cut_price?: number
last_weight_cut_price?: number
}
goodList?: any[]
onBlur?: (a: any, c: any) => void
@@ -85,7 +88,12 @@ const GoodsItem = (props: props) => {
}
</View>
<View className={styles.rightFontsbox}>
<View className={styles.money}>¥{props?.modeFont === 0 ? Number(props.value?.bulk_price) / 100 : props.modeFont === 1 ? Number(props.value?.length_cut_price) / 100 : Number(props.value?.weight_cut_price) / 100}{props.modeFont != 1 ? '/Kg' : '/m'}</View>
<View className={styles.moneyFlex}>
{
props?.modeFont === 0 && props.value?.last_bulk_price !== props.value?.bulk_price && <View className={styles.lastBox}>¥{props?.modeFont === 0 ? Number(props.value?.last_bulk_price) / 100 : props.modeFont === 1 ? Number(props.value?.last_length_cut_price) / 100 : Number(props.value?.last_weight_cut_price) / 100} {props.modeFont as any != 1 ? '/Kg' : '/m'}</View>
}
<View className={styles.money}>¥{props?.modeFont === 0 ? Number(props.value?.bulk_price) / 100 : props.modeFont === 1 ? Number(props.value?.length_cut_price) / 100 : Number(props.value?.weight_cut_price) / 100}{props.modeFont != 1 ? '/Kg' : '/m'}</View>
</View>
{
props.value.showInput && <View className={styles.inputBox}>
<View className={styles.reduceBox} onClick={() => { props.clickReduce?.(props.value) }}>
+28 -9
View File
@@ -176,11 +176,20 @@ page {
display: flex;
align-items: center;
justify-content: space-between;
.itemMoney {
font-size: 28px;
font-weight: 400;
color: #a5a5a5;
.flexBox {
display: flex;
.itemMoney {
font-size: 28px;
margin-right: 10px;
font-weight: 400;
color: #000000;
}
.lastBox {
font-size: 28px;
font-weight: 400;
text-decoration: line-through;
color: #7f7f7f;
}
}
.itemMoneyOne {
@@ -234,10 +243,20 @@ page {
align-items: center;
justify-content: space-between;
.itemMoney {
font-size: 28px;
font-weight: 400;
color: #a5a5a5;
.flexBox {
display: flex;
.itemMoney {
font-size: 28px;
margin-right: 10px;
font-weight: 400;
color: #000000;
}
.lastBox {
font-size: 28px;
font-weight: 400;
text-decoration: line-through;
color: #7f7f7f;
}
}
.itemMoneyOne {
+6 -1
View File
@@ -104,7 +104,12 @@ const GoodsItem = (porps: PropGoods) => {
<View className={styles.itemNums}>x{obj?.sale_mode === 0 ? it.roll : it.length / 100}{obj?.sale_mode === 0 ? '条' : 'm'}</View>
</View>
<View className={styles.item_right_Bottom}>
<View className={styles.itemMoney}>¥{formatPriceDiv(it.sale_price)}/{obj?.sale_mode === 1 ? 'm' : 'kg'}</View>
<View className={styles.flexBox}>
<View className={styles.itemMoney}>¥{formatPriceDiv(it.sale_price)}/{obj?.sale_mode === 1 ? 'm' : 'kg'}</View>
{
obj?.sale_mode === 0 && it?.sale_price !== it?.standard_sale_price && <View className={styles.lastBox}>¥{it?.standard_sale_price / 100}/{obj?.sale_mode === 1 ? 'm' : 'kg'}</View>
}
</View>
<View className={styles.itemMoneyOne}>¥{formatPriceDiv(it.total_sale_price)}</View>
</View>
</View>
@@ -54,13 +54,19 @@
font-weight: 550;
font-size: 28px;
}
&--yuanPrice {
font-size: 26px;
font-weight: 500;
text-decoration: line-through;
color: #7f7f7f;
}
&--counter {
}
}
}
.checkbox{
.checkbox {
padding: 0 24px;
}
.selected {
background-color: #F8FAFF;
background-color: #f8faff;
}
@@ -132,6 +132,10 @@ const ColorKindItem: FC<PropsType> = (props) => {
</View>
<View className={styles.colorKindItem__right}>
<View className={styles['colorKindItem__right--price']}>¥ {formatPrice(itemData.sale_price)}/{itemData.sale_mode == EnumSaleMode.Plate ? '米' : 'kg'}</View>
{
itemData.sale_mode === EnumSaleMode.Bulk && itemData?.standard_sale_price !== itemData?.sale_price && <View className={styles['colorKindItem__right--yuanPrice']}>¥ {formatPrice(itemData?.standard_sale_price)}/{itemData.sale_mode == EnumSaleMode.Plate ? '米' : 'kg'}</View>
}
<View className={styles['colorKindItem__right--counter']}>
<Counter
onBlue={getInputValue}
+50 -33
View File
@@ -10,7 +10,7 @@ page {
.pussName {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -18,7 +18,7 @@ page {
.pussPhone {
margin-left: 88px;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -27,7 +27,7 @@ page {
.total {
margin-top: 44px;
font-size: 24px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
margin-left: 32px;
@@ -56,7 +56,7 @@ page {
margin-left: 32px;
margin-right: 8px;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -68,7 +68,7 @@ page {
.shoudPay {
font-size: 28px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #f64861;
margin-right: 32px;
@@ -91,14 +91,14 @@ page {
.title {
font-size: 28px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #000000;
}
.modeName {
font-size: 28px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #337fff;
}
@@ -120,7 +120,7 @@ page {
.goodsProduct {
font-size: 28px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #000000;
margin-left: 32px;
@@ -161,14 +161,14 @@ page {
.itemName {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
.itemNums {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -179,16 +179,25 @@ page {
align-items: center;
justify-content: space-between;
.itemMoney {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
.flexBox {
display: flex;
.itemMoney {
font-size: 28px;
margin-right: 10px;
font-weight: 400;
color: #000000;
}
.lastBox {
font-size: 28px;
font-weight: 400;
text-decoration: line-through;
color: #7f7f7f;
}
}
.itemMoneyOne {
font-size: 28px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #000000;
}
@@ -222,14 +231,14 @@ page {
.itemName {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
.itemNums {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -239,17 +248,25 @@ page {
display: flex;
align-items: center;
justify-content: space-between;
.itemMoney {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
.flexBox {
display: flex;
.itemMoney {
font-size: 28px;
margin-right: 10px;
font-weight: 400;
color: #000000;
}
.lastBox {
font-size: 28px;
font-weight: 400;
text-decoration: line-through;
color: #7f7f7f;
}
}
.itemMoneyOne {
font-size: 28px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #000000;
}
@@ -274,7 +291,7 @@ page {
.detailRight {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -286,7 +303,7 @@ page {
border-radius: 8px;
border: 1px solid #337fff;
font-size: 24px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #337fff;
text-align: center;
@@ -296,7 +313,7 @@ page {
.detailFont {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -305,7 +322,7 @@ page {
.remarkFont {
margin-top: 24px;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -335,7 +352,7 @@ page {
.topFont {
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
margin-right: 10px;
@@ -343,7 +360,7 @@ page {
.topTotal {
font-size: 24px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #f64861;
}
@@ -352,7 +369,7 @@ page {
.bottomFlex {
margin-left: 48px;
font-size: 24px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #000000;
}
@@ -365,7 +382,7 @@ page {
background: #4581ff;
border-radius: 40px;
font-size: 32px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #ffffff;
text-align: center;
+7 -1
View File
@@ -88,7 +88,13 @@ const GoodsItem = (porps: PropGoods) => {
<View className={styles.itemNums}>x{obj?.sale_mode === 0 ? it.roll : it.length / 100}{obj?.sale_mode === 0 ? '条' : 'm'}</View>
</View>
<View className={styles.item_right_Bottom}>
<View className={styles.itemMoney}>¥{it.sale_price / 100}/{obj?.sale_mode === 1 ? 'm' : 'kg'}</View>
<View className={styles.flexBox}>
<View className={styles.itemMoney}>¥{it.sale_price / 100}/{obj?.sale_mode === 1 ? 'm' : 'kg'}</View>
{
obj?.sale_mode === 0 && it?.sale_price !== it?.standard_price && <View className={styles.lastBox}>¥{it?.standard_price / 100}/{obj?.sale_mode === 1 ? 'm' : 'kg'}</View>
}
</View>
<View className={styles.itemMoneyOne}>¥{formatPriceDiv(it.estimate_amount)}</View>
</View>
</View>