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
a46e5618
authored
Jun 25, 2024
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
修复bug
parent
182117d0
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
2 deletions
app/Http/Controllers/Api/SupplierReceiptApiController.php
app/Http/Services/SupplierAddressService.php
app/Http/Services/SupplierService.php
app/Http/Controllers/Api/SupplierReceiptApiController.php
View file @
a46e5618
...
@@ -42,6 +42,9 @@ class SupplierReceiptApiController extends Controller
...
@@ -42,6 +42,9 @@ class SupplierReceiptApiController extends Controller
//先去表单验证
//先去表单验证
$validator
=
new
ReceiptValidator
();
$validator
=
new
ReceiptValidator
();
$requestData
=
$request
->
all
();
$requestData
=
$request
->
all
();
$requestData
=
array_map
(
function
(
$item
)
{
return
trim
(
$item
);
},
$requestData
);
$validateResult
=
$validator
->
checkSave
(
$requestData
);
$validateResult
=
$validator
->
checkSave
(
$requestData
);
if
(
$validateResult
)
{
if
(
$validateResult
)
{
$this
->
response
(
-
1
,
$validateResult
);
$this
->
response
(
-
1
,
$validateResult
);
...
...
app/Http/Services/SupplierAddressService.php
View file @
a46e5618
...
@@ -32,7 +32,7 @@ class SupplierAddressService
...
@@ -32,7 +32,7 @@ class SupplierAddressService
}
else
{
}
else
{
$result
=
$addressModel
->
insert
(
$shippingData
);
$result
=
$addressModel
->
insert
(
$shippingData
);
}
}
if
(
!
$result
)
{
if
(
$result
===
false
)
{
return
$result
;
return
$result
;
}
}
$returnData
=
[
$returnData
=
[
...
...
app/Http/Services/SupplierService.php
View file @
a46e5618
...
@@ -264,7 +264,6 @@ class SupplierService
...
@@ -264,7 +264,6 @@ class SupplierService
$supplierAddressService
->
updateUnitedAddress
(
$supplierId
,
$channel
[
'supplier_address'
],
$address
[
'shipping_address'
],
$address
[
'return_address'
]);
$supplierAddressService
->
updateUnitedAddress
(
$supplierId
,
$channel
[
'supplier_address'
],
$address
[
'shipping_address'
],
$address
[
'return_address'
]);
$model
->
where
(
'supplier_id'
,
$supplierId
)
->
update
(
$channel
);
$model
->
where
(
'supplier_id'
,
$supplierId
)
->
update
(
$channel
);
//保存地址
//保存地址
$supplierAddressService
->
saveAddress
(
$address
);
$supplierAddressService
->
saveAddress
(
$address
);
...
...
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