更新细节

This commit is contained in:
yaooo 2023-12-25 10:47:50 +08:00
parent fd84b91a6a
commit 3c09f05bef

View File

@ -128,9 +128,16 @@ class FinanceRefundApplyLogic extends BaseLogic
$financeRefundApply = FinanceRefundApply::findOrEmpty($params['id']);
$financeRefundApply->contract;
$financeRefundApply->custom;
$financeRefundApply->document = $financeRefundApply->contract->document;
$financeRefundApply->project = $financeRefundApply->document->project;
unset($financeRefundApply->contract->document, $financeRefundApply->document->project);
$financeRefundApply->document = null;
$financeRefundApply->project = null;
if (!empty($financeRefundApply->contract->document)) {
$financeRefundApply->document = $financeRefundApply->contract->document;
unset($financeRefundApply->contract->document);
}
if (!empty($financeRefundApply->document->project)) {
$financeRefundApply->project = $financeRefundApply->document->project;
unset($financeRefundApply->document->project);
}
$financeRefundApply->annex = json_decode($financeRefundApply->annex, true);
return $financeRefundApply->toArray();
}