Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
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
haoban3.0
haoban-manage3.0
Commits
06ca9274
Commit
06ca9274
authored
Apr 10, 2023
by
jinxin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
是否显示弹窗
parent
dcf8b068
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
33 additions
and
16 deletions
+33
-16
LicenceOrderApiService.java
...an/manage/api/service/licence/LicenceOrderApiService.java
+2
-2
TabHaobanLicenceOrderMapper.java
...rvice/dao/mapper/licence/TabHaobanLicenceOrderMapper.java
+1
-1
LicenceOrderService.java
...n/manage/service/service/licence/LicenceOrderService.java
+1
-1
LicenceOrderApiServiceImpl.java
.../service/out/impl/licence/LicenceOrderApiServiceImpl.java
+21
-6
TabHaobanLicenceOrderMapper.xml
.../resources/mapper/licence/TabHaobanLicenceOrderMapper.xml
+2
-1
LicenceOrderServiceTest.java
...anage3-service/src/test/java/LicenceOrderServiceTest.java
+1
-1
LicenceOrderController.java
...manage/web/controller/licence/LicenceOrderController.java
+5
-4
No files found.
haoban-manage3-api/src/main/java/com/gic/haoban/manage/api/service/licence/LicenceOrderApiService.java
View file @
06ca9274
...
...
@@ -145,11 +145,11 @@ public interface LicenceOrderApiService {
ServiceResponse
<
Boolean
>
cancelQywxOrder
(
Long
orderId
);
/**
*
查询企业是否有历史订单
*
是否显示弹窗 true 显示 false 不显示
* @param wxEnterpriseId
* @return
*/
ServiceResponse
<
Boolean
>
isOrder
(
String
wxEnterpriseId
);
ServiceResponse
<
HashMap
<
String
,
Integer
>>
hasPopup
(
String
wxEnterpriseId
);
}
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/dao/mapper/licence/TabHaobanLicenceOrderMapper.java
View file @
06ca9274
...
...
@@ -130,7 +130,7 @@ public interface TabHaobanLicenceOrderMapper {
Integer
saveCallBackTime
(
@Param
(
"orderId"
)
Long
orderId
,
@Param
(
"type"
)
Integer
type
,
@Param
(
"time"
)
Date
time
);
/**
* 根据wxEnterpriseId查询企业订单数量
* 根据wxEnterpriseId查询企业订单
已支付
数量
*
* @param wxEnterpriseId
*/
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/licence/LicenceOrderService.java
View file @
06ca9274
...
...
@@ -141,7 +141,7 @@ public interface LicenceOrderService {
*/
Boolean
saveCallBackTime
(
Long
orderId
,
Integer
type
,
Date
time
);
/**
* 根据wxEnterpriseId查询企业订单数量
* 根据wxEnterpriseId查询企业订单
已支付
数量
*
* @param wxEnterpriseId
*/
...
...
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/licence/LicenceOrderApiServiceImpl.java
View file @
06ca9274
...
...
@@ -11,6 +11,7 @@ import com.gic.commons.util.DateUtil;
import
com.gic.commons.util.EntityUtil
;
import
com.gic.enterprise.api.dto.EnterpriseDTO
;
import
com.gic.enterprise.api.service.EnterpriseService
;
import
com.gic.haoban.manage.api.dto.StaffActiveDataDTO
;
import
com.gic.haoban.manage.api.dto.WxEnterpriseDTO
;
import
com.gic.haoban.manage.api.dto.licence.LicenceOrderDTO
;
import
com.gic.haoban.manage.api.dto.licence.LicenceOrderPageDTO
;
...
...
@@ -23,6 +24,8 @@ import com.gic.haoban.manage.service.config.Config;
import
com.gic.haoban.manage.service.entity.fee.TabHaobanQywxFeeOrder
;
import
com.gic.haoban.manage.service.entity.licence.TabHaobanLicenceOrder
;
import
com.gic.haoban.manage.service.entity.licence.TabHaobanLicenceOrderProgress
;
import
com.gic.haoban.manage.service.service.StaffClerkRelationService
;
import
com.gic.haoban.manage.service.service.WxEnterpriseActiveDataService
;
import
com.gic.haoban.manage.service.service.WxEnterpriseService
;
import
com.gic.haoban.manage.service.service.fee.HaobanQywxFeeOrderService
;
import
com.gic.haoban.manage.service.service.licence.LicenceOrderProgressService
;
...
...
@@ -82,7 +85,9 @@ public class LicenceOrderApiServiceImpl implements LicenceOrderApiService {
@Autowired
private
QywxUserApiService
qywxUserApiService
;
@Autowired
private
HaobanQywxFeeOrderService
haobanQywxFeeOrderService
;
private
StaffClerkRelationService
staffClerkRelationService
;
@Autowired
private
WxEnterpriseActiveDataService
wxEnterpriseActiveDataService
;
@Override
public
ServiceResponse
<
LicenceOrderDTO
>
getLicenceOrderDetail
(
Long
orderId
,
Integer
type
)
{
...
...
@@ -421,15 +426,25 @@ public class LicenceOrderApiServiceImpl implements LicenceOrderApiService {
}
@Override
public
ServiceResponse
<
Boolean
>
isOrder
(
String
wxEnterpriseId
)
{
public
ServiceResponse
<
HashMap
<
String
,
Integer
>>
hasPopup
(
String
wxEnterpriseId
)
{
HashMap
<
String
,
Integer
>
map
=
new
HashMap
<>();
map
.
put
(
"hasPopup"
,
0
);
map
.
put
(
"count"
,
0
);
List
<
String
>
list
=
staffClerkRelationService
.
listByWxEnterpriseId
(
wxEnterpriseId
);
if
(
CollUtil
.
isEmpty
(
list
)){
return
ServiceResponse
.
success
(
map
);
}
Integer
count
=
licenceOrderService
.
selectCountByWxEnterpriseId
(
wxEnterpriseId
);
if
(
count
==
0
){
List
<
TabHaobanQywxFeeOrder
>
qywxFeeOrderList
=
haobanQywxFeeOrderService
.
listOrder
(
wxEnterpriseId
);
if
(
CollUtil
.
isEmpty
(
qywxFeeOrderList
)
){
return
ServiceResponse
.
success
(
false
);
StaffActiveDataDTO
dto
=
wxEnterpriseActiveDataService
.
getWxEnterpriseActiveDataByWxEnterpriseId
(
wxEnterpriseId
);
if
(
null
!=
dto
&&
dto
.
getPurchased
()
>
0
){
return
ServiceResponse
.
success
(
map
);
}
map
.
put
(
"hasPopup"
,
1
);
map
.
put
(
"count"
,
list
.
size
());
return
ServiceResponse
.
success
(
map
);
}
return
ServiceResponse
.
success
(
true
);
return
ServiceResponse
.
success
(
map
);
}
}
haoban-manage3-service/src/main/resources/mapper/licence/TabHaobanLicenceOrderMapper.xml
View file @
06ca9274
...
...
@@ -349,7 +349,7 @@
SELECT count(*)
FROM tab_haoban_licence_order
WHERE wx_enterprise_id = #{wxEnterpriseId}
and delete_flag = 0
and delete_flag = 0
and order_status = 1
</select>
</mapper>
\ No newline at end of file
haoban-manage3-service/src/test/java/LicenceOrderServiceTest.java
View file @
06ca9274
...
...
@@ -66,6 +66,6 @@ public class LicenceOrderServiceTest {
}
@Test
public
void
test7
(){
ServiceResponse
<
Boolean
>
response
=
licenceOrderApiService
.
isOrder
(
"ca66a01b79474c40b3e7c7f93daf1a3b"
);
licenceOrderApiService
.
hasPopup
(
"ca66a01b79474c40b3e7c7f93daf1a3b"
);
}
}
haoban-manage3-web/src/main/java/com/gic/haoban/manage/web/controller/licence/LicenceOrderController.java
View file @
06ca9274
...
...
@@ -350,15 +350,16 @@ public class LicenceOrderController {
}
/**
* 查询企业是否存在历史订单
* 是否显示弹窗 hasPopup 0不弹出 1弹出
* count 关联数量
*/
@RequestMapping
(
"licence-order-has
Order
"
)
public
RestResponse
<
Boolean
>
hasOrder
()
{
@RequestMapping
(
"licence-order-has
Popup
"
)
public
RestResponse
<
HashMap
<
String
,
Integer
>>
hasPopup
()
{
WebLoginDTO
loginUser
=
AuthWebRequestUtil
.
getLoginUser
();
if
(
loginUser
==
null
||
StringUtils
.
isBlank
(
loginUser
.
getEnterpriseId
()))
{
return
RestResponse
.
failure
(
Convert
.
toStr
(
HaoBanErrCode
.
ERR_4
.
getCode
()),
HaoBanErrCode
.
ERR_4
.
getMsg
());
}
ServiceResponse
<
Boolean
>
response
=
licenceOrderApiService
.
isOrder
(
loginUser
.
getWxEnterpriseId
());
ServiceResponse
<
HashMap
<
String
,
Integer
>>
response
=
licenceOrderApiService
.
hasPopup
(
loginUser
.
getWxEnterpriseId
());
return
RestResponse
.
successResult
(
response
.
getResult
());
}
...
...
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