Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-store
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
base_platform_enterprise
gic-store
Commits
19d81797
Commit
19d81797
authored
Jul 08, 2019
by
zhiwj
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
门店批量插入任务
parent
81b640af
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
6 deletions
+11
-6
StoreTaskServiceImpl.java
...ava/com/gic/store/service/outer/StoreTaskServiceImpl.java
+11
-6
No files found.
gic-store-service/src/main/java/com/gic/store/service/outer/StoreTaskServiceImpl.java
View file @
19d81797
...
...
@@ -69,10 +69,7 @@ public class StoreTaskServiceImpl extends AbstractTaskAllocationOperation implem
public
void
dealSingle
(
Object
o
)
throws
TaskAllocationException
{
StoreTmpDTO
t
=
(
StoreTmpDTO
)
o
;
try
{
ServiceResponse
<
Integer
>
serviceResponse
=
this
.
importDataToStore
(
t
);
if
(!
serviceResponse
.
isSuccess
())
{
t
.
setErrorMessage
(
serviceResponse
.
getMessage
());
}
this
.
importDataToStore
(
t
);
}
catch
(
Exception
e
)
{
logger
.
warn
(
"写入门店表和成员表异常"
,
e
);
t
.
setErrorMessage
(
"导入异常"
);
...
...
@@ -80,7 +77,7 @@ public class StoreTaskServiceImpl extends AbstractTaskAllocationOperation implem
}
}
public
ServiceResponse
<
Integer
>
importDataToStore
(
StoreTmpDTO
t
)
{
public
void
importDataToStore
(
StoreTmpDTO
t
)
{
StoreDTO
storeDTO
=
new
StoreDTO
();
storeDTO
.
setEnterpriseId
(
t
.
getEnterpriseId
());
storeDTO
.
setStoreName
(
t
.
getStoreName
());
...
...
@@ -162,7 +159,15 @@ public class StoreTaskServiceImpl extends AbstractTaskAllocationOperation implem
List
<
StoreExtendDTO
>
extendList
=
JSON
.
parseArray
(
customField
,
StoreExtendDTO
.
class
);
storeDTO
.
setStoreExtendList
(
extendList
);
return
storeApiService
.
saveOrUpdate
(
storeDTO
);
ServiceResponse
<
Integer
>
serviceResponse
=
storeApiService
.
saveOrUpdate
(
storeDTO
);
String
msg
;
if
(
serviceResponse
.
isSuccess
())
{
msg
=
"success"
;
}
else
{
msg
=
serviceResponse
.
getMessage
();
}
t
.
setErrorMessage
(
msg
);
storeImportService
.
updateData
(
t
);
}
@Override
...
...
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