order
parent
a571e18aa1
commit
e0c45b34fc
|
|
@ -183,10 +183,16 @@ class OrderController extends AdminController
|
||||||
$show->field('cost_price')->as(function ($value) {
|
$show->field('cost_price')->as(function ($value) {
|
||||||
return bcdiv($value, 100, 2);
|
return bcdiv($value, 100, 2);
|
||||||
});
|
});
|
||||||
$show->field('products_total_amount')->as(fn($value) => bcdiv($value, 100, 2));
|
$show->field('products_total_amount')->as(fn($value) => bcdiv($value, 100, 2))->prepend('¥');
|
||||||
$show->field('coupon_discount_amount')->as(fn($value) => bcdiv($value, 100, 2));
|
$show->field('vip_discount_amount')->as(fn ($v) => bcdiv($v, 100, 2))->prepend('- ¥');
|
||||||
// $show->field('vip_discount_amount')->as(fn($value) => bcdiv($value, 100, 2));
|
|
||||||
$show->field('total_amount', '支付金额')->as(fn($value) => bcdiv($value, 100, 2));
|
$userCouponId = $show->model()->user_coupon_id;
|
||||||
|
if ($userCouponId) {
|
||||||
|
$show->field('coupon_discount_amount')->as(fn($value) => bcdiv($value, 100, 2))->prepend('- ¥');
|
||||||
|
}
|
||||||
|
$show->field('shipping_fee')->as(fn ($v) => bcdiv($v, 100, 2))->prepend('+ ¥');
|
||||||
|
$show->field('reduced_amount')->as(fn($value) => bcdiv($value, 100, 2))->prepend('- ¥');
|
||||||
|
$show->field('total_amount', '支付金额')->as(fn($value) => bcdiv($value, 100, 2))->prepend('¥');
|
||||||
$show->field('sales_value');
|
$show->field('sales_value');
|
||||||
$show->field('order_status')->as(function ($v) {
|
$show->field('order_status')->as(function ($v) {
|
||||||
return $this->order_status;
|
return $this->order_status;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue