微信支付 {$sceneText|htmlentities}
{$row.out_trade_no|htmlentities}
创建时间:{:date('Y-m-d H:i:s', $row.createtime)} {if !empty($row.pay_time)} 支付完成:{:date('Y-m-d H:i:s', $row.pay_time)} {/if}
{php} $st = $row['status']; $statusClass = 'status-pending'; $statusIcon = 'fa-clock-o'; if ($st === 'paid') { $statusClass = 'status-paid'; $statusIcon = 'fa-check-circle'; } elseif ($st === 'refunding') { $statusClass = 'status-refunding'; $statusIcon = 'fa-refresh fa-spin'; } elseif ($st === 'refunded') { $statusClass = 'status-refunded'; $statusIcon = 'fa-undo'; } elseif ($st === 'refund_failed' || $st === 'pay_failed') { $statusClass = 'status-failed'; $statusIcon = 'fa-exclamation-triangle'; } elseif ($st === 'closed') { $statusClass = 'status-closed'; $statusIcon = 'fa-ban'; } {/php}
{$statusText|htmlentities}
交易支付金额
¥{$row.amount}
累计原路已退
¥{$row.refund_amount}
剩余可退金额
¥{$refundableAmount}
退款进度
{$refundStatusText|htmlentities}
{if !empty($row.fail_code) || !empty($row.fail_reason) || $row.status == 'refund_failed' || $row.status == 'pay_failed'}
异常原因说明
{$row.fail_reason|default='支付或退款未能正常完成,请尝试同步状态或联系技术人员核查'|htmlentities}
处理建议: {if strpos($row.fail_code, 'CURL_60') !== false} 系统支付安全配置异常,请联系技术人员处理。 {elseif $row.status == 'refund_failed'} 退款未能成功,请确认微信商户号可用余额充足后,点击下方【重发原路退款】重新发起。 {else /} 可点击下方【同步微信状态】获取最新结果,或登录微信商户平台核对。 {/if}
{/if}

支付与对账信息

商户支付单号 {$row.out_trade_no|htmlentities}
微信交易单号 {if !empty($row.transaction_id)} {$row.transaction_id|htmlentities} {else /} 暂无(未完成支付) {/if}
支付完成时间 {if !empty($row.pay_time)} {:date('Y-m-d H:i:s', $row.pay_time)} {else /} 未完成支付 {/if}
最近核对时间 {if !empty($row.last_sync_time)} {:date('Y-m-d H:i:s', $row.last_sync_time)} {else /} 暂未核对 {/if}

业务订单与客户信息

业务类型 {$sceneText|htmlentities} {if $row.scene == 'batch' && !empty($row.batch_no)} 批次号: {$row.batch_no} {elseif $row.scene == 'quote' && !empty($row.quote_id)} 报价单号: #{$row.quote_id} {/if}
关联订单号 {if !empty($order)} {$order.order_no|htmlentities} {else /} 无关联订单(账户充值或批量付款) {/if}
{if !empty($order)}
服务项目 {$order.service_name|default='-'|htmlentities}
订单状态 {$order.status_text|default='-'|htmlentities} 订单金额: ¥{$order.pay_amount|default='0.00'}
{/if}
付款客户 {if !empty($user)} {$user.nickname|default=$user.username|htmlentities} {else /} 未关联用户 {/if}
联系电话 {if !empty($user) && !empty($user.mobile)} {$user.mobile|htmlentities} {else /} - {/if}
{if !empty($row.refund_no) || !empty($row.refund_id) || $row.refund_amount > 0 || in_array($row.refund_status, ['processing', 'success', 'abnormal'])}

退款记录详情

商户退款单号 {if !empty($row.refund_no)} {$row.refund_no|htmlentities} {else /} - {/if}
微信退款单号 {if !empty($row.refund_id)} {$row.refund_id|htmlentities} {else /} 暂无(退款处理中或未生成) {/if}
已退金额 ¥{$row.refund_amount}
退款进度 {php} $rfStatus = $row['refund_status']; $rfLabel = 'label-default'; if ($rfStatus === 'success') $rfLabel = 'label-success'; elseif ($rfStatus === 'processing') $rfLabel = 'label-warning'; elseif ($rfStatus === 'abnormal') $rfLabel = 'label-danger'; {/php} {$refundStatusText|htmlentities}
退款到账时间 {if !empty($row.refund_time)} {:date('Y-m-d H:i:s', $row.refund_time)} {else /} 尚未到账 {/if}
{/if}