Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
杨树贤
/
liexin_supplier
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
2982d81e
authored
Jun 09, 2023
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
重新修改审核流程
parent
7bad53a1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
6 deletions
app/Http/Services/SupplierService.php
app/Http/Services/SupplierService.php
View file @
2982d81e
...
...
@@ -72,7 +72,6 @@ class SupplierService
$oldSupplier
=
$model
->
where
(
'supplier_id'
,
$channel
[
'supplier_id'
])
->
first
();
$oldSupplier
=
$supplierTransformer
->
transformInfo
(
$oldSupplier
);
}
$needAudit
=
true
;
//走事务
$supplierId
=
DB
::
connection
(
'web'
)
->
transaction
(
function
()
use
(
$channel
,
$model
,
$oldSupplier
,
&
$needAudit
)
{
...
...
@@ -108,7 +107,7 @@ class SupplierService
$skuAuditRulerService
=
new
SupplierSkuAuditRulerService
();
$channel
[
'sku_audit_ruler'
]
=
$skuAuditRulerService
->
getSkuAuditRulerForDB
(
$channel
[
'sku_audit_ruler'
]);
/
/新增供应商操作
/
**新增供应商操作**/
if
(
empty
(
$channel
[
'supplier_id'
]))
{
//处理附件信息,新增的时候才会有附件信息提交过来
$attachmentField
=
[
...
...
@@ -317,7 +316,6 @@ class SupplierService
unset
(
$newSupplier
[
'update_time'
]);
if
(
$oldSupplier
==
$newSupplier
)
{
$logService
->
AddLog
(
$this
->
newSupplierId
,
LogModel
::
UPDATE_OPERATE
,
'修改供应商基本资料'
,
'没有内容变化'
);
return
$supplierId
;
}
}
...
...
@@ -327,9 +325,10 @@ class SupplierService
]));
//这里有个申请审核的判断逻辑
//如果是申请审核,
还要去修改审核状态
//如果是申请审核,
并且原来的状态不是已通过,无论什么情况,都要变成审核中,如果是已通过,那么就要走下面的判断是否要忽略审核流程
$isAudit
=
(
bool
)
request
()
->
input
(
'is_audit'
);
if
(
$isAudit
&&
$needAudit
)
{
if
(
$isAudit
&&
$oldSupplier
[
'status'
]
==
SupplierChannelModel
::
STATUS_PASSED
&&
!
$needAudit
&&
!
empty
(
$channel
[
'supplier_id'
]))
{
}
else
if
(
$isAudit
)
{
$auditData
[]
=
[
'supplier_id'
=>
$supplierId
,
//供应商类型为临时供应商,才会去存申请理由
...
...
@@ -337,7 +336,6 @@ class SupplierService
];
$this
->
batchApplyInReviewSupplier
(
$auditData
);
}
return
$supplierId
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment