Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_ht
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
pseer
gxpt_ht
Commits
94b4f0f9
Commit
94b4f0f9
authored
Nov 29, 2023
by
吕明尚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更改开门问题
parent
bec45265
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
15 additions
and
12 deletions
+15
-12
SConsumptionRecordsController.java
.../web/controller/system/SConsumptionRecordsController.java
+4
-3
SConsumptionRecordsController.java
.../web/controller/system/SConsumptionRecordsController.java
+2
-1
ISConsumptionRecordsService.java
...ava/share/system/service/ISConsumptionRecordsService.java
+2
-1
SConsumptionRecordsServiceImpl.java
...e/system/service/impl/SConsumptionRecordsServiceImpl.java
+2
-2
SOrderServiceImpl.java
...ain/java/share/system/service/impl/SOrderServiceImpl.java
+5
-5
No files found.
share-admin/src/main/java/share/web/controller/system/SConsumptionRecordsController.java
View file @
94b4f0f9
...
...
@@ -17,6 +17,7 @@ import share.common.core.controller.BaseController;
import
share.common.core.domain.AjaxResult
;
import
share.common.enums.BusinessType
;
import
share.system.domain.SConsumptionRecords
;
import
share.system.domain.vo.SConsumptionRecordsVo
;
import
share.system.service.ISConsumptionRecordsService
;
import
share.common.utils.poi.ExcelUtil
;
import
share.common.core.page.TableDataInfo
;
...
...
@@ -42,7 +43,7 @@ public class SConsumptionRecordsController extends BaseController
public
TableDataInfo
list
(
SConsumptionRecords
sConsumptionRecords
)
{
startPage
();
List
<
SConsumptionRecords
>
list
=
sConsumptionRecordsService
.
selectSConsumptionRecordsList
(
sConsumptionRecords
);
List
<
SConsumptionRecords
Vo
>
list
=
sConsumptionRecordsService
.
selectSConsumptionRecordsList
(
sConsumptionRecords
);
return
getDataTable
(
list
);
}
...
...
@@ -54,8 +55,8 @@ public class SConsumptionRecordsController extends BaseController
@PostMapping
(
"/export"
)
public
void
export
(
HttpServletResponse
response
,
SConsumptionRecords
sConsumptionRecords
)
{
List
<
SConsumptionRecords
>
list
=
sConsumptionRecordsService
.
selectSConsumptionRecordsList
(
sConsumptionRecords
);
ExcelUtil
<
SConsumptionRecords
>
util
=
new
ExcelUtil
<
SConsumptionRecords
>(
SConsumptionRecords
.
class
);
List
<
SConsumptionRecords
Vo
>
list
=
sConsumptionRecordsService
.
selectSConsumptionRecordsList
(
sConsumptionRecords
);
ExcelUtil
<
SConsumptionRecords
Vo
>
util
=
new
ExcelUtil
<
SConsumptionRecordsVo
>(
SConsumptionRecordsVo
.
class
);
util
.
exportExcel
(
response
,
list
,
"消费记录数据"
);
}
...
...
share-front/src/main/java/share/web/controller/system/SConsumptionRecordsController.java
View file @
94b4f0f9
...
...
@@ -19,6 +19,7 @@ import share.common.enums.BusinessType;
import
share.system.domain.SConsumer
;
import
share.system.domain.SConsumptionRecords
;
import
share.system.domain.vo.FrontTokenComponent
;
import
share.system.domain.vo.SConsumptionRecordsVo
;
import
share.system.service.ISConsumptionRecordsService
;
import
share.common.utils.poi.ExcelUtil
;
import
share.common.core.page.TableDataInfo
;
...
...
@@ -46,7 +47,7 @@ public class SConsumptionRecordsController extends BaseController
SConsumer
user
=
FrontTokenComponent
.
getWxSConsumerEntry
();
sConsumptionRecords
.
setConsumerId
(
user
.
getId
());
startPage
();
List
<
SConsumptionRecords
>
list
=
sConsumptionRecordsService
.
selectSConsumptionRecordsList
(
sConsumptionRecords
);
List
<
SConsumptionRecords
Vo
>
list
=
sConsumptionRecordsService
.
selectSConsumptionRecordsList
(
sConsumptionRecords
);
return
getDataTable
(
list
);
}
}
share-system/src/main/java/share/system/service/ISConsumptionRecordsService.java
View file @
94b4f0f9
...
...
@@ -2,6 +2,7 @@ package share.system.service;
import
java.util.List
;
import
share.system.domain.SConsumptionRecords
;
import
share.system.domain.vo.SConsumptionRecordsVo
;
/**
* 消费记录Service接口
...
...
@@ -25,7 +26,7 @@ public interface ISConsumptionRecordsService
* @param sConsumptionRecords 消费记录
* @return 消费记录集合
*/
public
List
<
SConsumptionRecords
>
selectSConsumptionRecordsList
(
SConsumptionRecords
sConsumptionRecords
);
public
List
<
SConsumptionRecords
Vo
>
selectSConsumptionRecordsList
(
SConsumptionRecords
sConsumptionRecords
);
/**
* 新增消费记录
...
...
share-system/src/main/java/share/system/service/impl/SConsumptionRecordsServiceImpl.java
View file @
94b4f0f9
...
...
@@ -55,7 +55,7 @@ public class SConsumptionRecordsServiceImpl implements ISConsumptionRecordsServi
* @return 消费记录
*/
@Override
public
List
<
SConsumptionRecords
>
selectSConsumptionRecordsList
(
SConsumptionRecords
sConsumptionRecords
)
public
List
<
SConsumptionRecords
Vo
>
selectSConsumptionRecordsList
(
SConsumptionRecords
sConsumptionRecords
)
{
List
<
SConsumptionRecords
>
sConsumptionRecordsList
=
sConsumptionRecordsMapper
.
selectSConsumptionRecordsList
(
sConsumptionRecords
);
//获取消费记录的用户id集合
...
...
@@ -79,7 +79,7 @@ public class SConsumptionRecordsServiceImpl implements ISConsumptionRecordsServi
}
});
});
return
sConsumptionRecordsList
;
return
sConsumptionRecords
Vo
List
;
}
/**
...
...
share-system/src/main/java/share/system/service/impl/SOrderServiceImpl.java
View file @
94b4f0f9
...
...
@@ -794,7 +794,7 @@ public class SOrderServiceImpl extends ServiceImpl<SOrderMapper, SOrder> impleme
sOrder
.
setEndDate
(
DateUtils
.
addHours
(
new
Date
(),
bigDecimal
.
intValue
()));
Map
<
String
,
String
>
map
=
new
HashMap
<>();
map
.
put
(
"orderNo"
,
sOrder
.
getOrderNo
());
map
.
put
(
"expirationTime"
,
sOrder
.
get
Start
Date
().
toString
());
map
.
put
(
"expirationTime"
,
sOrder
.
get
End
Date
().
toString
());
JSONObject
jsonObject
=
new
JSONObject
(
map
);
redisUtils
.
set
(
ReceiptRdeisEnum
.
ORDER_NO_KEY
.
getValue
()
+
sOrder
.
getOrderNo
(),
jsonObject
.
toString
());
baseMapper
.
updateById
(
sOrder
);
...
...
@@ -807,14 +807,14 @@ public class SOrderServiceImpl extends ServiceImpl<SOrderMapper, SOrder> impleme
throw
new
BaseException
(
"设备不存在!"
);
}
SStore
sStore
=
storeService
.
getById
(
sOrder
.
getStoreId
());
String
value
=
"欢迎来到凑角共享棋牌"
+
sStore
.
getName
(
);
mqttxService
.
actionExecute
(
device2
.
getDevId
(),
sOrder
.
getConsumerPhone
(),
VoiceEnum
.
OPEN
.
getValue
(
value
)
,
deviceOpService
.
openDoor
(
sRoomVo
.
getId
(),
sOrder
.
getConsumerPhone
()
);
deviceOpService
.
actionExecute
(
sOrder
.
getRoomId
(),
sOrder
.
getConsumerPhone
(),
"1"
,
cn
.
hutool
.
core
.
date
.
DateUtil
.
format
(
new
Date
(),
DatePattern
.
NORM_DATETIME_PATTERN
),
cn
.
hutool
.
core
.
date
.
DateUtil
.
format
(
cn
.
hutool
.
core
.
date
.
DateUtil
.
offsetMinute
(
new
Date
(),
1
),
DatePattern
.
NORM_DATETIME_PATTERN
),
"1"
);
//查询非当前用户,预约时间或使用时间为当前时间的订单,如果存在,房间不可开门
}
else
{
deviceOpService
.
openDoor
(
sRoomVo
.
getId
(),
sOrder
.
getConsumerPhone
());
}
SConsumer
user
=
FrontTokenComponent
.
getWxSConsumerEntry
();
deviceOpService
.
openDoor
(
sRoomVo
.
getId
(),
user
.
getPhone
());
return
"开锁成功"
;
}
...
...
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