diff --git a/src/pages/details/components/orderCount/index.module.scss b/src/pages/details/components/orderCount/index.module.scss
index d8d319c..f003bf6 100644
--- a/src/pages/details/components/orderCount/index.module.scss
+++ b/src/pages/details/components/orderCount/index.module.scss
@@ -96,11 +96,22 @@
font-weight: 700;
@include common_ellipsis();
}
- .num {
- font-size: $font_size;
- color: $color_main;
+ .flexBox {
padding-top: 10px;
+ display: flex;
+ align-items: center;
+ .numone {
+ font-size: $font_size;
+ color: #9e9e9e;
+ margin-right: 10px;
+ text-decoration: line-through;
+ }
+ .num {
+ font-size: $font_size;
+ color: $color_main;
+ }
}
+
.weight_error {
font-size: 28px;
color: #666666;
diff --git a/src/pages/details/components/orderCount/index.tsx b/src/pages/details/components/orderCount/index.tsx
index 6c46d4b..f05f225 100644
--- a/src/pages/details/components/orderCount/index.tsx
+++ b/src/pages/details/components/orderCount/index.tsx
@@ -29,8 +29,8 @@ const OrderCount = ({ show = false, onClose, title = '', productId = 0 }: param)
const { adminUserInfo } = useSelector(state => state.userInfo)
const [selectList, _] = useState([
- { id: 0, step: 1, digits: 0, maxNum: 100000, defaultNum: 1, title: '大货', unit: '条', eunit: 'kg', priceField: 'bulk_price' },
- { id: 1, step: 1, digits: 2, maxNum: 9.99, defaultNum: 1, title: '剪板', unit: '米', eunit: 'm', priceField: 'length_cut_price' },
+ { id: 0, step: 1, digits: 0, maxNum: 100000, defaultNum: 1, title: '大货', unit: '条', eunit: 'kg', priceField: 'bulk_price', originalPrice: 'last_bulk_price' },
+ { id: 1, step: 1, digits: 2, maxNum: 9.99, defaultNum: 1, title: '剪板', unit: '米', eunit: 'm', priceField: 'length_cut_price', originalPrice: 'last_length_cut_price' },
{
id: 2,
step: 1,
@@ -43,6 +43,7 @@ const OrderCount = ({ show = false, onClose, title = '', productId = 0 }: param)
unit: '米',
eunit: 'kg',
priceField: 'weight_cut_price',
+ originalPrice: 'last_weight_cut_price',
},
])
const [selectIndex, setSelectIndex] = useState(0)
@@ -216,6 +217,21 @@ const OrderCount = ({ show = false, onClose, title = '', productId = 0 }: param)
[selectIndex],
)
+ const formatOriginalPrice = useCallback(
+ (item) => {
+ if (selectIndex === 1 || selectIndex === 2) { return }
+ const price = Number(formatPriceDiv(item[selectList[selectIndex].originalPrice]))
+ return (
+
+ ¥
+ {price}
+ /{selectList[selectIndex].eunit}
+
+ )
+ },
+ [selectIndex],
+ )
+
// 显示图片弹窗
const [showLabImage, setShowLabImage] = useState(false)
const [labImageValue, setLabImageValue] = useState()
@@ -237,8 +253,12 @@ const OrderCount = ({ show = false, onClose, title = '', productId = 0 }: param)
{formatHashTag(item.code, item.name)}
- {selectIndex == 0 && 空差:{formatWeightDiv(item.weight_error)}kg}
- {formatPrice(item)}
+ {/* {selectIndex == 0 && 空差:{formatWeightDiv(item.weight_error)}kg} */}
+
+ {selectIndex === 0 && {formatOriginalPrice(item)}}
+ {formatPrice(item)}
+
+
{(!item.show && (