优化订单打印
This commit is contained in:
@@ -130,6 +130,7 @@ export function formatPhoneNumber(phone, isFormat = true) {
|
||||
*/
|
||||
export async function getOrderByIdAjax(orderId) {
|
||||
try {
|
||||
if (!orderId) return;
|
||||
const res = await getOrderById({ orderId: orderId });
|
||||
|
||||
let arr = [];
|
||||
@@ -162,8 +163,8 @@ export function commOrderPrintData(orderInfo) {
|
||||
shop_name: userStore.shopInfo.shopName,
|
||||
loginAccount: userStore.userInfo.name,
|
||||
carts: [],
|
||||
amount: formatDecimal(orderInfo.payAmount),
|
||||
originAmount: formatDecimal(orderInfo.originAmount),
|
||||
amount: formatDecimal(+orderInfo.payAmount),
|
||||
originAmount: formatDecimal(+orderInfo.originAmount),
|
||||
discountAmount:
|
||||
orderInfo.status == "unpaid"
|
||||
? "0.00"
|
||||
@@ -182,7 +183,7 @@ export function commOrderPrintData(orderInfo) {
|
||||
name: item.productName,
|
||||
number: item.num,
|
||||
skuName: item.skuName,
|
||||
salePrice: formatDecimal(item.price),
|
||||
salePrice: formatDecimal(+item.price),
|
||||
totalAmount: formatDecimal(+item.payAmount),
|
||||
proGroupInfo: item.proGroupInfo
|
||||
? item.proGroupInfo.map((item) => item.goods).flat()
|
||||
|
||||
Reference in New Issue
Block a user