feat: 完善协议管理、师傅资质认证、分账配置并完成测试环境全量部署与同步
这个提交包含在:
@@ -363,8 +363,9 @@
|
||||
<div class="od-item"><span class="od-item-k">支付状态:</span><span class="od-item-v"><span class="label {if $row.pay_status==1}label-success{elseif $row.pay_status==2/}label-danger{else/}label-default{/if}">{$row.pay_status_text}</span></span></div>
|
||||
<div class="od-item"><span class="od-item-k">支付渠道:</span><span class="od-item-v">{$row.pay_type|default='微信支付'|htmlentities}</span></div>
|
||||
<div class="od-item" style="grid-column: span 2;"><span class="od-item-k">交易流水号:</span><span class="od-item-v"><code>{$row.transaction_id|default='-'|htmlentities}</code></span></div>
|
||||
<div class="od-item"><span class="od-item-k">师傅结算款:</span><span class="od-item-v" style="color:#10b981; font-weight:700;">¥{if !empty($settle)}{$settle.settle_amount} (抽成¥{$settle.commission}){else/}{$row.settle_amount}{/if}</span></div>
|
||||
<div class="od-item"><span class="od-item-k">抽佣规则快照:</span><span class="od-item-v"><span class="label label-info">{if !empty($settle)}{$settle.commission_rate|htmlentities}%{else/}{$settlePreview.commission_rate|default='10.00'|htmlentities}%{/if}</span> <small class="text-muted">{$settlePreview.rule_name|default=''|htmlentities}</small></span></div>
|
||||
<div class="od-item"><span class="od-item-k">结算状态:</span><span class="od-item-v">{$row.settle_status_text}</span></div>
|
||||
<div class="od-item" style="grid-column: span 2;"><span class="od-item-k">师傅结算款:</span><span class="od-item-v" style="color:#10b981; font-weight:700;">{if !empty($settle)}¥{$settle.settle_amount}(平台抽佣 ¥{$settle.commission}){elseif $row.settle_status == 1/}¥{$row.settle_amount}{else/}预计 ¥{:number_format($settlePreview.settle_amount, 2, '.', '')}(预计抽佣 ¥{:number_format($settlePreview.commission, 2, '.', '')}){/if}</span></div>
|
||||
<div class="od-item" style="grid-column: span 2;">
|
||||
<span class="od-item-k">发票状态:</span>
|
||||
<span class="od-item-v">
|
||||
@@ -439,6 +440,94 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 3.5 微信支付与原路退款交易流水诊断 -->
|
||||
<div class="od-card">
|
||||
<div class="od-card-header">
|
||||
<h4 class="od-card-title"><i class="fa fa-wechat"></i> 微信支付与原路退款交易流水 ({:count($payOrders)})</h4>
|
||||
<span class="text-muted" style="font-size:12px;">展示网关真实回执、异常中文诊断与人工同步/重退入口</span>
|
||||
</div>
|
||||
<div class="od-card-body">
|
||||
{if !empty($payOrders)}
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered table-condensed" style="margin-bottom:0; font-size:12.5px;">
|
||||
<thead>
|
||||
<tr style="background:#f8fafc;">
|
||||
<th style="width:55px;">ID</th>
|
||||
<th style="width:105px;">支付场景</th>
|
||||
<th>商户单号 / 微信单号 / 退款单号</th>
|
||||
<th style="width:90px;">金额</th>
|
||||
<th style="width:130px;">流水 / 退款状态</th>
|
||||
<th>失败错误码与中文诊断</th>
|
||||
<th style="width:140px;">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{foreach name="payOrders" item="po"}
|
||||
<tr>
|
||||
<td>#{$po.id}</td>
|
||||
<td>{$po.scene_text|htmlentities}</td>
|
||||
<td>
|
||||
<div>商户:<code>{$po.out_trade_no|htmlentities}</code></div>
|
||||
{if !empty($po.transaction_id)}<div style="margin-top:2px;">微信:<code>{$po.transaction_id|htmlentities}</code></div>{/if}
|
||||
{if !empty($po.refund_no)}<div style="margin-top:2px;">退款单:<code>{$po.refund_no|htmlentities}</code>{if !empty($po.refund_id)}({$po.refund_id|htmlentities}){/if}</div>{/if}
|
||||
</td>
|
||||
<td>
|
||||
<div style="font-weight:700; color:#ea580c;">¥{$po.amount|number_format=2}</div>
|
||||
{if $po.refund_amount > 0}<div style="font-size:11px; color:#64748b;">退 ¥{$po.refund_amount|number_format=2}</div>{/if}
|
||||
</td>
|
||||
<td>
|
||||
{if $po.status == 'paid'}<span class="label label-success">{$po.status_text}</span>
|
||||
{elseif $po.status == 'refunded'/}<span class="label label-info">{$po.status_text}</span>
|
||||
{elseif $po.status == 'refunding'/}<span class="label label-warning">{$po.status_text}</span>
|
||||
{elseif $po.status == 'pay_failed' || $po.status == 'refund_failed'/}<span class="label label-danger">{$po.status_text}</span>
|
||||
{else/}<span class="label label-default">{$po.status_text}</span>{/if}
|
||||
{if $po.refund_status && $po.refund_status != 'none'}
|
||||
<div style="margin-top:4px; font-size:11px; color:#475569;">{$po.refund_status_text}</div>
|
||||
{/if}
|
||||
{if !empty($po.last_sync_time)}
|
||||
<div style="margin-top:2px; font-size:11px; color:#94a3b8;">同步于 {:date('m-d H:i:s', $po.last_sync_time)}</div>
|
||||
{/if}
|
||||
</td>
|
||||
<td>
|
||||
{if !empty($po.fail_reason) || !empty($po.fail_code)}
|
||||
<div style="background:#fef2f2; border:1px solid #fecaca; color:#b91c1c; border-radius:6px; padding:6px 8px; line-height:1.5;">
|
||||
{if !empty($po.fail_code)}<div><strong>错误码:</strong><code>{$po.fail_code|htmlentities}</code></div>{/if}
|
||||
<div><strong>原因:</strong>{$po.fail_reason|default='未知异常'|htmlentities}</div>
|
||||
</div>
|
||||
{else /}
|
||||
<span class="text-muted">-</span>
|
||||
{/if}
|
||||
</td>
|
||||
<td>
|
||||
{if $po.status == 'pending' || $po.status == 'pay_failed' || $po.status == 'refunding' || $po.status == 'refund_failed'}
|
||||
<button type="button" class="btn btn-xs btn-warning js-sync-pay-order" data-id="{$po.id}" style="margin-bottom:4px;">
|
||||
<i class="fa fa-refresh"></i> 同步微信状态
|
||||
</button>
|
||||
{/if}
|
||||
{if $po.status == 'refund_failed' || ($po.status == 'paid' && $row.status == 9 && $row.settle_status != 1)}
|
||||
<button type="button" class="btn btn-xs btn-danger js-retry-refund" data-id="{$po.id}" data-outno="{$po.out_trade_no|htmlentities}">
|
||||
<i class="fa fa-undo"></i> 重试原路退款
|
||||
</button>
|
||||
{/if}
|
||||
{if $po.status == 'refunded' || $po.status == 'closed' || ($po.status == 'paid' && ($row.status != 9 || $row.settle_status == 1))}
|
||||
<span class="text-muted" style="font-size:11px;">无需人工处置</span>
|
||||
{/if}
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{elseif $row.pay_status == 1 && ($row.pay_type == 'wechat' || $row.pay_type == '')/}
|
||||
<div style="background:#fef2f2; border:1px solid #fecaca; color:#b91c1c; border-radius:6px; padding:10px 12px;">
|
||||
<i class="fa fa-exclamation-triangle"></i> <strong>资金流水缺失告警:</strong>当前订单显示已支付(渠道:{$row.pay_type|default='未记录'|htmlentities}),但未关联任何 <code>fa_pay_order</code> 微信交易单,系统已禁止自动假退款,如需退款请先核查微信商户平台流水。
|
||||
</div>
|
||||
{else /}
|
||||
<div class="text-muted" style="padding:8px 0;">暂无微信支付交易流水记录</div>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 4. 现场施工取证照片画廊 -->
|
||||
<div class="od-card">
|
||||
<div class="od-card-header">
|
||||
|
||||
在新工单中引用
屏蔽一个用户