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
72f63409
authored
Aug 28, 2023
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
脚本
parent
34f41845
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
app/Http/Services/DataService.php
app/Http/Services/DataService.php
View file @
72f63409
...
...
@@ -1600,7 +1600,11 @@ class DataService
//初始化sku的规则
public
function
initFuturesSkuUploadRuler
()
{
$suppliers
=
SupplierChannelModel
::
where
(
'sku_upload_ruler'
,
'!='
,
''
)
->
get
()
->
toArray
();
$suppliers
=
SupplierChannelModel
::
where
(
'sku_upload_ruler'
,
'!='
,
''
)
->
select
([
'sku_upload_ruler'
,
'supplier_id'
])
->
get
()
->
toArray
();
$redis
=
new
RedisModel
();
foreach
(
$suppliers
as
$supplier
)
{
$uploadRuler
=
$supplier
[
'sku_upload_ruler'
];
$uploadRuler
=
json_decode
(
$uploadRuler
,
true
);
...
...
@@ -1611,8 +1615,7 @@ class DataService
SupplierChannelModel
::
where
(
'supplier_id'
,
$supplier
[
'supplier_id'
])
->
update
([
'sku_upload_ruler'
=>
$uploadRuler
,
]);
(
new
SupplierService
())
->
saveSkuUploadRulerToRedis
(
$supplier
[
'supplier_id'
],
$uploadRuler
);
$redis
->
hset
(
'supplier_sku_upload_ruler'
,
$supplier
[
'supplier_id'
],
$uploadRuler
);
}
}
...
...
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