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
a42a47e2
authored
Jun 05, 2023
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
是否实体
parent
00197ede
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
3 deletions
app/Http/Controllers/Api/SupplierApiController.php
app/Http/Services/CompanyService.php
app/Http/Validators/SupplierValidator.php
app/Http/Controllers/Api/SupplierApiController.php
View file @
a42a47e2
...
...
@@ -340,7 +340,7 @@ class SupplierApiController extends Controller
//还要校验提交上来的公司是否有合法信息
$unitedInfo
=
$unitedCompanyInfo
[
'united_company_info'
];
if
(
$unitedInfo
)
{
if
(
$united
Info
[
'is_entity'
]
==
1
)
{
if
(
isset
(
$unitedCompanyInfo
[
'is_entity'
])
&&
$unitedCompany
Info
[
'is_entity'
]
==
1
)
{
$this
->
response
(
-
3
,
'该供应商已经被一体化系统加入黑名单,不能新增'
);
}
if
(
$unitedInfo
[
'company_category'
]
!=
''
)
{
...
...
app/Http/Services/CompanyService.php
View file @
a42a47e2
...
...
@@ -27,8 +27,9 @@ class CompanyService
$unitedCompanyInfo
=
[];
if
(
array_get
(
$result
,
'code'
)
===
0
)
{
$unitedCompanyInfo
[
'united_company_info'
]
=
!
empty
(
$result
[
'data'
][
'companyInfo'
])
?
$result
[
'data'
][
'companyInfo'
]
:
[];
$
company
=
[]
;
$
unitedCompanyInfo
[
'is_entity'
]
=
isset
(
$result
[
'data'
][
'is_entity'
])
?
$result
[
'data'
][
'is_entity'
]
:
0
;
$companyInfoList
=
array_get
(
array_get
(
$result
[
'data'
],
'tycList'
),
'company_info_list'
);
$company
=
[];
if
(
!
empty
(
$companyInfoList
))
{
$companyInfo
=
$companyInfoList
[
0
];
$companyInfo
[
'establishment_time'
]
=
$companyInfo
[
'establishment_time'
]
?
$companyInfo
[
'establishment_time'
]
/
1000
:
0
;
...
...
app/Http/Validators/SupplierValidator.php
View file @
a42a47e2
...
...
@@ -40,7 +40,7 @@ class SupplierValidator
$regionType
);
$unitedInfo
=
$unitedCompanyInfo
[
'united_company_info'
];
if
(
$unitedInfo
&&
$isAdd
)
{
if
(
$united
Info
[
'is_entity'
]
==
1
)
{
if
(
isset
(
$unitedCompanyInfo
[
'is_entity'
])
&&
$unitedCompany
Info
[
'is_entity'
]
==
1
)
{
return
'该供应商已经被一体化系统加入黑名单,不能新增'
;
}
...
...
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