付款申请参数结构修改
This commit is contained in:
@@ -66,6 +66,7 @@ class FinPaymentApplyService
|
||||
$data['doc_user_id'] = $request->user->uid;
|
||||
$data['submit_files'] = json_encode($data['submit_files']);
|
||||
redis::set('stock_' . $data['doc_user_id'], json_encode($request->post('stock')), 'EX', 30);
|
||||
unset($data['stock']);
|
||||
return $data;
|
||||
}
|
||||
|
||||
@@ -75,12 +76,14 @@ class FinPaymentApplyService
|
||||
$data = [
|
||||
'payment_apply_id' => $res['id'],
|
||||
];
|
||||
$stock = json_decode(redis::get('stock_' . $res['doc_user_id']), true);
|
||||
$piStock = json_decode(redis::get('stock_' . $res['doc_user_id']), true);
|
||||
redis::del('stock' . $res['doc_user_id']);
|
||||
foreach ($stock as $k => $v) {
|
||||
$data['stock_id'] = $v['stock_id'];
|
||||
$data['pi_no'] = $v['pi_on'];
|
||||
FinPaymentStock::create($data);
|
||||
foreach ($piStock as $stock) {
|
||||
foreach ($stock['stock_id'] as $v) {
|
||||
$data['stock_id'] = $v;
|
||||
$data['pi_no'] = $stock['pi_on'];
|
||||
FinPaymentStock::create($data);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -90,7 +93,6 @@ class FinPaymentApplyService
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 生成唯一的付款申请编码
|
||||
* 格式:PA + 日期 + 6位字母数字组合
|
||||
|
||||
Reference in New Issue
Block a user