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
a7fea8d6
Commit
a7fea8d6
authored
May 18, 2020
by
zhiwj
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
ed5d3ca1
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
32 additions
and
31 deletions
+32
-31
TabStoreBusinessTimeMapper.java
.../com/gic/store/dao/mapper/TabStoreBusinessTimeMapper.java
+1
-1
StoreServiceImpl.java
...ain/java/com/gic/store/service/impl/StoreServiceImpl.java
+7
-7
StoreBusinessTimeStrategyImpl.java
...ic/store/strategy/impl/StoreBusinessTimeStrategyImpl.java
+10
-10
StorePhoneStategyImpl.java
...va/com/gic/store/strategy/impl/StorePhoneStategyImpl.java
+4
-4
StoreStatusStrategyImpl.java
.../com/gic/store/strategy/impl/StoreStatusStrategyImpl.java
+9
-9
TabStoreBrandMapper.xml
...service/src/main/resources/mapper/TabStoreBrandMapper.xml
+1
-0
No files found.
gic-store-service/src/main/java/com/gic/store/dao/mapper/TabStoreBusinessTimeMapper.java
View file @
a7fea8d6
...
...
@@ -60,7 +60,7 @@ public interface TabStoreBusinessTimeMapper {
int
updateAllBuinessTime
(
@Param
(
"weekday"
)
String
weekday
,
@Param
(
"openTime"
)
Date
openTime
,
@Param
(
"closeTime"
)
Date
closeTime
,
@Param
(
"enterpriseId"
)
Integer
enterpriseId
);
int
updateBuinessTimeBystoreInfoIds
(
@Param
(
"weekday"
)
String
weekday
,
@Param
(
"openTime"
)
Date
openTime
,
@Param
(
"closeTime"
)
Date
closeTime
,
@Param
(
"storeIdList"
)
List
<
Integer
>
storeIdList
);
int
updateBuinessTimeBystoreInfoIds
(
@Param
(
"weekday"
)
String
weekday
,
@Param
(
"openTime"
)
Date
openTime
,
@Param
(
"closeTime"
)
Date
closeTime
,
@Param
(
"storeI
nfoI
dList"
)
List
<
Integer
>
storeIdList
);
int
deleteAllByEnterpriseId
(
@Param
(
"enterpriseId"
)
Integer
enterpriseId
);
...
...
gic-store-service/src/main/java/com/gic/store/service/impl/StoreServiceImpl.java
View file @
a7fea8d6
...
...
@@ -228,25 +228,25 @@ public class StoreServiceImpl implements StoreService {
if
(
"all"
.
equals
(
storeIds
))
{
return
this
.
tabStoreInfoMapper
.
updateAllStoreConactsPhone
(
enterpriseId
,
value
);
}
String
[]
storeIdArr
=
storeIds
.
split
(
","
);
String
[]
storeI
nfoI
dArr
=
storeIds
.
split
(
","
);
List
<
Integer
>
list
=
new
ArrayList
<>();
for
(
String
s
:
storeIdArr
)
{
for
(
String
s
:
storeI
nfoI
dArr
)
{
list
.
add
(
Integer
.
valueOf
(
s
));
}
return
this
.
tabStoreInfoMapper
.
updateStoreConactsPhoneBystoreInfoIds
(
value
,
list
);
}
@Override
public
int
bulkUpdateStoreBusinessTime
(
String
storeIds
,
Integer
enterpriseId
,
String
value
)
{
public
int
bulkUpdateStoreBusinessTime
(
String
storeI
nfoI
ds
,
Integer
enterpriseId
,
String
value
)
{
try
{
JSONArray
array
=
JSON
.
parseArray
(
value
);
SimpleDateFormat
simpleDateFormat
=
new
SimpleDateFormat
(
"HH:mm"
);
List
<
Integer
>
list
=
new
ArrayList
<>();
if
(
"all"
.
equals
(
storeIds
))
{
if
(
"all"
.
equals
(
storeI
nfoI
ds
))
{
this
.
tabStoreBusinessTimeMapper
.
deleteAllByEnterpriseId
(
enterpriseId
);
}
else
{
String
[]
storeI
dArr
=
store
Ids
.
split
(
","
);
for
(
String
s
:
storeIdArr
)
{
String
[]
storeI
nfoIdArr
=
storeInfo
Ids
.
split
(
","
);
for
(
String
s
:
storeI
nfoI
dArr
)
{
list
.
add
(
Integer
.
valueOf
(
s
));
}
this
.
tabStoreBusinessTimeMapper
.
deleteBystoreInfoIds
(
enterpriseId
,
list
);
...
...
@@ -258,7 +258,7 @@ public class StoreServiceImpl implements StoreService {
String
closeTimeStr
=
json
.
getString
(
"closeTime"
);
Date
openTime
=
simpleDateFormat
.
parse
(
openTimeStr
);
Date
closeTime
=
simpleDateFormat
.
parse
(
closeTimeStr
);
if
(
"all"
.
equals
(
storeIds
))
{
if
(
"all"
.
equals
(
storeI
nfoI
ds
))
{
this
.
tabStoreBusinessTimeMapper
.
updateAllBuinessTime
(
weekday
,
openTime
,
closeTime
,
enterpriseId
);
}
else
{
this
.
tabStoreBusinessTimeMapper
.
updateBuinessTimeBystoreInfoIds
(
weekday
,
openTime
,
closeTime
,
list
);
...
...
gic-store-service/src/main/java/com/gic/store/strategy/impl/StoreBusinessTimeStrategyImpl.java
View file @
a7fea8d6
...
...
@@ -23,17 +23,17 @@ public class StoreBusinessTimeStrategyImpl implements BulkUpdateStoreStrtegy {
private
StoreLogService
storeLogService
;
@Override
public
int
bulkUpdateStore
(
String
storeIds
,
Integer
enterpriseId
,
String
value
,
StoreService
storeService
,
Integer
operatorId
,
String
operatorName
)
{
int
i
=
storeService
.
bulkUpdateStoreBusinessTime
(
storeIds
,
enterpriseId
,
value
);
public
int
bulkUpdateStore
(
String
storeI
nfoI
ds
,
Integer
enterpriseId
,
String
value
,
StoreService
storeService
,
Integer
operatorId
,
String
operatorName
)
{
int
i
=
storeService
.
bulkUpdateStoreBusinessTime
(
storeI
nfoI
ds
,
enterpriseId
,
value
);
if
(
i
>
0
)
{
List
<
Integer
>
storeIdList
;
if
(
"all"
.
equals
(
storeIds
))
{
storeIdList
=
storeService
.
listAllStoreId
(
enterpriseId
);
List
<
Integer
>
storeI
nfoI
dList
;
if
(
"all"
.
equals
(
storeI
nfoI
ds
))
{
storeI
nfoI
dList
=
storeService
.
listAllStoreId
(
enterpriseId
);
}
else
{
storeIdList
=
new
ArrayList
<>();
String
[]
storeI
dArr
=
store
Ids
.
split
(
","
);
for
(
String
s
:
storeIdArr
)
{
storeIdList
.
add
(
Integer
.
valueOf
(
s
));
storeI
nfoI
dList
=
new
ArrayList
<>();
String
[]
storeI
nfoIdArr
=
storeInfo
Ids
.
split
(
","
);
for
(
String
s
:
storeI
nfoI
dArr
)
{
storeI
nfoI
dList
.
add
(
Integer
.
valueOf
(
s
));
}
}
// [{"weekday":"1,2","openTime":"09:42","closeTime":"09:42"}]
...
...
@@ -59,7 +59,7 @@ public class StoreBusinessTimeStrategyImpl implements BulkUpdateStoreStrtegy {
}
btSb
.
deleteCharAt
(
btSb
.
length
()
-
1
);
btSb
.
append
(
"】"
);
storeLogService
.
saveBulkStoreInfoLog
(
storeIdList
,
enterpriseId
,
operatorId
,
operatorName
,
btSb
.
toString
());
storeLogService
.
saveBulkStoreInfoLog
(
storeI
nfoI
dList
,
enterpriseId
,
operatorId
,
operatorName
,
btSb
.
toString
());
}
return
i
;
}
...
...
gic-store-service/src/main/java/com/gic/store/strategy/impl/StorePhoneStategyImpl.java
View file @
a7fea8d6
...
...
@@ -16,15 +16,15 @@ public class StorePhoneStategyImpl implements BulkUpdateStoreStrtegy {
private
StoreLogService
storeLogService
;
@Override
public
int
bulkUpdateStore
(
String
storeIds
,
Integer
enterpriseId
,
String
value
,
StoreService
storeService
,
Integer
operatorId
,
String
operatorName
)
{
int
i
=
storeService
.
bulkUpdateStoreConactsPhone
(
storeIds
,
enterpriseId
,
value
);
public
int
bulkUpdateStore
(
String
storeI
nfoI
ds
,
Integer
enterpriseId
,
String
value
,
StoreService
storeService
,
Integer
operatorId
,
String
operatorName
)
{
int
i
=
storeService
.
bulkUpdateStoreConactsPhone
(
storeI
nfoI
ds
,
enterpriseId
,
value
);
if
(
i
>
0
)
{
List
<
Integer
>
storeIdList
;
if
(
"all"
.
equals
(
storeIds
))
{
if
(
"all"
.
equals
(
storeI
nfoI
ds
))
{
storeIdList
=
storeService
.
listAllStoreId
(
enterpriseId
);
}
else
{
storeIdList
=
new
ArrayList
<>();
String
[]
storeIdArr
=
storeIds
.
split
(
","
);
String
[]
storeIdArr
=
storeI
nfoI
ds
.
split
(
","
);
for
(
String
s
:
storeIdArr
)
{
storeIdList
.
add
(
Integer
.
valueOf
(
s
));
}
...
...
gic-store-service/src/main/java/com/gic/store/strategy/impl/StoreStatusStrategyImpl.java
View file @
a7fea8d6
...
...
@@ -17,20 +17,20 @@ public class StoreStatusStrategyImpl implements BulkUpdateStoreStrtegy {
private
StoreLogService
storeLogService
;
@Override
public
int
bulkUpdateStore
(
String
storeIds
,
Integer
enterpriseId
,
String
value
,
StoreService
storeService
,
Integer
operatorId
,
String
operatorName
)
{
int
i
=
storeService
.
bulkUpdateStoreStatus
(
storeIds
,
enterpriseId
,
value
);
public
int
bulkUpdateStore
(
String
storeI
nfoI
ds
,
Integer
enterpriseId
,
String
value
,
StoreService
storeService
,
Integer
operatorId
,
String
operatorName
)
{
int
i
=
storeService
.
bulkUpdateStoreStatus
(
storeI
nfoI
ds
,
enterpriseId
,
value
);
if
(
i
>
0
)
{
List
<
Integer
>
storeIdList
;
if
(
"all"
.
equals
(
storeIds
))
{
storeIdList
=
storeService
.
listAllStoreId
(
enterpriseId
);
List
<
Integer
>
storeI
nfoI
dList
;
if
(
"all"
.
equals
(
storeI
nfoI
ds
))
{
storeI
nfoI
dList
=
storeService
.
listAllStoreId
(
enterpriseId
);
}
else
{
storeIdList
=
new
ArrayList
<>();
String
[]
storeIdArr
=
storeIds
.
split
(
","
);
storeI
nfoI
dList
=
new
ArrayList
<>();
String
[]
storeIdArr
=
storeI
nfoI
ds
.
split
(
","
);
for
(
String
s
:
storeIdArr
)
{
storeIdList
.
add
(
Integer
.
valueOf
(
s
));
storeI
nfoI
dList
.
add
(
Integer
.
valueOf
(
s
));
}
}
storeLogService
.
saveBulkStoreInfoLog
(
storeIdList
,
enterpriseId
,
operatorId
,
operatorName
,
"门店状态变更为【"
+
StoreStatusEnum
.
parseCode
(
Integer
.
parseInt
(
value
))
+
"】"
);
storeLogService
.
saveBulkStoreInfoLog
(
storeI
nfoI
dList
,
enterpriseId
,
operatorId
,
operatorName
,
"门店状态变更为【"
+
StoreStatusEnum
.
parseCode
(
Integer
.
parseInt
(
value
))
+
"】"
);
}
return
i
;
}
...
...
gic-store-service/src/main/resources/mapper/TabStoreBrandMapper.xml
View file @
a7fea8d6
...
...
@@ -227,6 +227,7 @@
<include
refid=
"Base_Column_List"
/>
from tab_store_brand
where status = 1
and enterprise_id = #{enterpriseId}
and store_brand_id
<>
#{storeBrandId}
order by sort
limit #{start}, #{size}
...
...
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