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
4610898b
Commit
4610898b
authored
Aug 27, 2024
by
吕明尚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增月卡后台管理系统
parent
712a9911
Show whitespace changes
Inline
Side-by-side
Showing
28 changed files
with
2100 additions
and
20 deletions
+2100
-20
ConsumerMonthlyCardController.java
.../web/controller/system/ConsumerMonthlyCardController.java
+91
-0
MonthlyCardConfController.java
...hare/web/controller/system/MonthlyCardConfController.java
+91
-0
MonthlyCardLogController.java
...share/web/controller/system/MonthlyCardLogController.java
+91
-0
MonthlyCardOrderController.java
...are/web/controller/system/MonthlyCardOrderController.java
+91
-0
ConsumerMonthlyCard.java
...rc/main/java/share/system/domain/ConsumerMonthlyCard.java
+88
-0
MonthlyCardConf.java
...em/src/main/java/share/system/domain/MonthlyCardConf.java
+77
-0
MonthlyCardLog.java
...tem/src/main/java/share/system/domain/MonthlyCardLog.java
+82
-0
MonthlyCardOrder.java
...m/src/main/java/share/system/domain/MonthlyCardOrder.java
+122
-0
ConsumerMonthlyCardMapper.java
...n/java/share/system/mapper/ConsumerMonthlyCardMapper.java
+62
-0
MonthlyCardConfMapper.java
.../main/java/share/system/mapper/MonthlyCardConfMapper.java
+62
-0
MonthlyCardLogMapper.java
...c/main/java/share/system/mapper/MonthlyCardLogMapper.java
+62
-0
MonthlyCardOrderMapper.java
...main/java/share/system/mapper/MonthlyCardOrderMapper.java
+62
-0
ConsumerMonthlyCardService.java
...java/share/system/service/ConsumerMonthlyCardService.java
+62
-0
MonthlyCardConfService.java
...ain/java/share/system/service/MonthlyCardConfService.java
+62
-0
MonthlyCardLogService.java
...main/java/share/system/service/MonthlyCardLogService.java
+62
-0
MonthlyCardOrderService.java
...in/java/share/system/service/MonthlyCardOrderService.java
+62
-0
ConsumerMonthlyCardServiceImpl.java
...e/system/service/impl/ConsumerMonthlyCardServiceImpl.java
+91
-0
MonthlyCardConfServiceImpl.java
...share/system/service/impl/MonthlyCardConfServiceImpl.java
+91
-0
MonthlyCardLogServiceImpl.java
.../share/system/service/impl/MonthlyCardLogServiceImpl.java
+91
-0
MonthlyCardOrderServiceImpl.java
...hare/system/service/impl/MonthlyCardOrderServiceImpl.java
+91
-0
ConsumerMonthlyCardMapper.xml
...ain/resources/mapper/system/ConsumerMonthlyCardMapper.xml
+122
-0
ConsumerSecondaryCardMapper.xml
...n/resources/mapper/system/ConsumerSecondaryCardMapper.xml
+0
-2
MonthlyCardConfMapper.xml
...rc/main/resources/mapper/system/MonthlyCardConfMapper.xml
+110
-0
MonthlyCardLogMapper.xml
...src/main/resources/mapper/system/MonthlyCardLogMapper.xml
+116
-0
MonthlyCardOrderMapper.xml
...c/main/resources/mapper/system/MonthlyCardOrderMapper.xml
+146
-0
SecondaryCardConfMapper.xml
.../main/resources/mapper/system/SecondaryCardConfMapper.xml
+1
-2
SecondaryCardLogMapper.xml
...c/main/resources/mapper/system/SecondaryCardLogMapper.xml
+1
-3
SecondaryCardOrderMapper.xml
...main/resources/mapper/system/SecondaryCardOrderMapper.xml
+11
-13
No files found.
share-admin/src/main/java/share/web/controller/system/ConsumerMonthlyCardController.java
0 → 100644
View file @
4610898b
package
share
.
web
.
controller
.
system
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.security.access.prepost.PreAuthorize
;
import
org.springframework.web.bind.annotation.*
;
import
share.common.annotation.Log
;
import
share.common.core.controller.BaseController
;
import
share.common.core.domain.AjaxResult
;
import
share.common.core.page.TableDataInfo
;
import
share.common.enums.BusinessType
;
import
share.common.utils.poi.ExcelUtil
;
import
share.system.domain.ConsumerMonthlyCard
;
import
share.system.service.ConsumerMonthlyCardService
;
import
javax.servlet.http.HttpServletResponse
;
import
java.util.List
;
/**
* 用户月卡Controller
*
* @author wuwenlong
* @date 2024-08-27
*/
@RestController
@RequestMapping
(
"/system/consumerMonthlyCard"
)
public
class
ConsumerMonthlyCardController
extends
BaseController
{
@Autowired
private
ConsumerMonthlyCardService
consumerMonthlyCardService
;
/**
* 查询用户月卡列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:consumerMonthlyCard:list')"
)
@GetMapping
(
"/list"
)
public
TableDataInfo
list
(
ConsumerMonthlyCard
consumerMonthlyCard
)
{
startPage
();
List
<
ConsumerMonthlyCard
>
list
=
consumerMonthlyCardService
.
selectConsumerMonthlyCardList
(
consumerMonthlyCard
);
return
getDataTable
(
list
);
}
/**
* 导出用户月卡列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:consumerMonthlyCard:export')"
)
@Log
(
title
=
"用户月卡"
,
businessType
=
BusinessType
.
EXPORT
)
@PostMapping
(
"/export"
)
public
void
export
(
HttpServletResponse
response
,
ConsumerMonthlyCard
consumerMonthlyCard
)
{
List
<
ConsumerMonthlyCard
>
list
=
consumerMonthlyCardService
.
selectConsumerMonthlyCardList
(
consumerMonthlyCard
);
ExcelUtil
<
ConsumerMonthlyCard
>
util
=
new
ExcelUtil
<
ConsumerMonthlyCard
>(
ConsumerMonthlyCard
.
class
);
util
.
exportExcel
(
response
,
list
,
"用户月卡数据"
);
}
/**
* 获取用户月卡详细信息
*/
@PreAuthorize
(
"@ss.hasPermi('system:consumerMonthlyCard:query')"
)
@GetMapping
(
value
=
"/{id}"
)
public
AjaxResult
getInfo
(
@PathVariable
(
"id"
)
Long
id
)
{
return
success
(
consumerMonthlyCardService
.
selectConsumerMonthlyCardById
(
id
));
}
/**
* 新增用户月卡
*/
@PreAuthorize
(
"@ss.hasPermi('system:consumerMonthlyCard:add')"
)
@Log
(
title
=
"用户月卡"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
public
AjaxResult
add
(
@RequestBody
ConsumerMonthlyCard
consumerMonthlyCard
)
{
return
toAjax
(
consumerMonthlyCardService
.
insertConsumerMonthlyCard
(
consumerMonthlyCard
));
}
/**
* 修改用户月卡
*/
@PreAuthorize
(
"@ss.hasPermi('system:consumerMonthlyCard:edit')"
)
@Log
(
title
=
"用户月卡"
,
businessType
=
BusinessType
.
UPDATE
)
@PutMapping
public
AjaxResult
edit
(
@RequestBody
ConsumerMonthlyCard
consumerMonthlyCard
)
{
return
toAjax
(
consumerMonthlyCardService
.
updateConsumerMonthlyCard
(
consumerMonthlyCard
));
}
/**
* 删除用户月卡
*/
@PreAuthorize
(
"@ss.hasPermi('system:consumerMonthlyCard:remove')"
)
@Log
(
title
=
"用户月卡"
,
businessType
=
BusinessType
.
DELETE
)
@DeleteMapping
(
"/{ids}"
)
public
AjaxResult
remove
(
@PathVariable
Long
[]
ids
)
{
return
toAjax
(
consumerMonthlyCardService
.
deleteConsumerMonthlyCardByIds
(
ids
));
}
}
share-admin/src/main/java/share/web/controller/system/MonthlyCardConfController.java
0 → 100644
View file @
4610898b
package
share
.
web
.
controller
.
system
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.security.access.prepost.PreAuthorize
;
import
org.springframework.web.bind.annotation.*
;
import
share.common.annotation.Log
;
import
share.common.core.controller.BaseController
;
import
share.common.core.domain.AjaxResult
;
import
share.common.core.page.TableDataInfo
;
import
share.common.enums.BusinessType
;
import
share.common.utils.poi.ExcelUtil
;
import
share.system.domain.MonthlyCardConf
;
import
share.system.service.MonthlyCardConfService
;
import
javax.servlet.http.HttpServletResponse
;
import
java.util.List
;
/**
* 月卡配置Controller
*
* @author wuwenlong
* @date 2024-08-27
*/
@RestController
@RequestMapping
(
"/system/monthlyCardConf"
)
public
class
MonthlyCardConfController
extends
BaseController
{
@Autowired
private
MonthlyCardConfService
monthlyCardConfService
;
/**
* 查询月卡配置列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardConf:list')"
)
@GetMapping
(
"/list"
)
public
TableDataInfo
list
(
MonthlyCardConf
monthlyCardConf
)
{
startPage
();
List
<
MonthlyCardConf
>
list
=
monthlyCardConfService
.
selectMonthlyCardConfList
(
monthlyCardConf
);
return
getDataTable
(
list
);
}
/**
* 导出月卡配置列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardConf:export')"
)
@Log
(
title
=
"月卡配置"
,
businessType
=
BusinessType
.
EXPORT
)
@PostMapping
(
"/export"
)
public
void
export
(
HttpServletResponse
response
,
MonthlyCardConf
monthlyCardConf
)
{
List
<
MonthlyCardConf
>
list
=
monthlyCardConfService
.
selectMonthlyCardConfList
(
monthlyCardConf
);
ExcelUtil
<
MonthlyCardConf
>
util
=
new
ExcelUtil
<
MonthlyCardConf
>(
MonthlyCardConf
.
class
);
util
.
exportExcel
(
response
,
list
,
"月卡配置数据"
);
}
/**
* 获取月卡配置详细信息
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardConf:query')"
)
@GetMapping
(
value
=
"/{id}"
)
public
AjaxResult
getInfo
(
@PathVariable
(
"id"
)
Long
id
)
{
return
success
(
monthlyCardConfService
.
selectMonthlyCardConfById
(
id
));
}
/**
* 新增月卡配置
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardConf:add')"
)
@Log
(
title
=
"月卡配置"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
public
AjaxResult
add
(
@RequestBody
MonthlyCardConf
monthlyCardConf
)
{
return
toAjax
(
monthlyCardConfService
.
insertMonthlyCardConf
(
monthlyCardConf
));
}
/**
* 修改月卡配置
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardConf:edit')"
)
@Log
(
title
=
"月卡配置"
,
businessType
=
BusinessType
.
UPDATE
)
@PutMapping
public
AjaxResult
edit
(
@RequestBody
MonthlyCardConf
monthlyCardConf
)
{
return
toAjax
(
monthlyCardConfService
.
updateMonthlyCardConf
(
monthlyCardConf
));
}
/**
* 删除月卡配置
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardConf:remove')"
)
@Log
(
title
=
"月卡配置"
,
businessType
=
BusinessType
.
DELETE
)
@DeleteMapping
(
"/{ids}"
)
public
AjaxResult
remove
(
@PathVariable
Long
[]
ids
)
{
return
toAjax
(
monthlyCardConfService
.
deleteMonthlyCardConfByIds
(
ids
));
}
}
share-admin/src/main/java/share/web/controller/system/MonthlyCardLogController.java
0 → 100644
View file @
4610898b
package
share
.
web
.
controller
.
system
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.security.access.prepost.PreAuthorize
;
import
org.springframework.web.bind.annotation.*
;
import
share.common.annotation.Log
;
import
share.common.core.controller.BaseController
;
import
share.common.core.domain.AjaxResult
;
import
share.common.core.page.TableDataInfo
;
import
share.common.enums.BusinessType
;
import
share.common.utils.poi.ExcelUtil
;
import
share.system.domain.MonthlyCardLog
;
import
share.system.service.MonthlyCardLogService
;
import
javax.servlet.http.HttpServletResponse
;
import
java.util.List
;
/**
* 月卡使用记录Controller
*
* @author wuwenlong
* @date 2024-08-27
*/
@RestController
@RequestMapping
(
"/system/monthlyCardLog"
)
public
class
MonthlyCardLogController
extends
BaseController
{
@Autowired
private
MonthlyCardLogService
monthlyCardLogService
;
/**
* 查询月卡使用记录列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardLog:list')"
)
@GetMapping
(
"/list"
)
public
TableDataInfo
list
(
MonthlyCardLog
monthlyCardLog
)
{
startPage
();
List
<
MonthlyCardLog
>
list
=
monthlyCardLogService
.
selectMonthlyCardLogList
(
monthlyCardLog
);
return
getDataTable
(
list
);
}
/**
* 导出月卡使用记录列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardLog:export')"
)
@Log
(
title
=
"月卡使用记录"
,
businessType
=
BusinessType
.
EXPORT
)
@PostMapping
(
"/export"
)
public
void
export
(
HttpServletResponse
response
,
MonthlyCardLog
monthlyCardLog
)
{
List
<
MonthlyCardLog
>
list
=
monthlyCardLogService
.
selectMonthlyCardLogList
(
monthlyCardLog
);
ExcelUtil
<
MonthlyCardLog
>
util
=
new
ExcelUtil
<
MonthlyCardLog
>(
MonthlyCardLog
.
class
);
util
.
exportExcel
(
response
,
list
,
"月卡使用记录数据"
);
}
/**
* 获取月卡使用记录详细信息
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardLog:query')"
)
@GetMapping
(
value
=
"/{id}"
)
public
AjaxResult
getInfo
(
@PathVariable
(
"id"
)
Long
id
)
{
return
success
(
monthlyCardLogService
.
selectMonthlyCardLogById
(
id
));
}
/**
* 新增月卡使用记录
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardLog:add')"
)
@Log
(
title
=
"月卡使用记录"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
public
AjaxResult
add
(
@RequestBody
MonthlyCardLog
monthlyCardLog
)
{
return
toAjax
(
monthlyCardLogService
.
insertMonthlyCardLog
(
monthlyCardLog
));
}
/**
* 修改月卡使用记录
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardLog:edit')"
)
@Log
(
title
=
"月卡使用记录"
,
businessType
=
BusinessType
.
UPDATE
)
@PutMapping
public
AjaxResult
edit
(
@RequestBody
MonthlyCardLog
monthlyCardLog
)
{
return
toAjax
(
monthlyCardLogService
.
updateMonthlyCardLog
(
monthlyCardLog
));
}
/**
* 删除月卡使用记录
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardLog:remove')"
)
@Log
(
title
=
"月卡使用记录"
,
businessType
=
BusinessType
.
DELETE
)
@DeleteMapping
(
"/{ids}"
)
public
AjaxResult
remove
(
@PathVariable
Long
[]
ids
)
{
return
toAjax
(
monthlyCardLogService
.
deleteMonthlyCardLogByIds
(
ids
));
}
}
share-admin/src/main/java/share/web/controller/system/MonthlyCardOrderController.java
0 → 100644
View file @
4610898b
package
share
.
web
.
controller
.
system
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.security.access.prepost.PreAuthorize
;
import
org.springframework.web.bind.annotation.*
;
import
share.common.annotation.Log
;
import
share.common.core.controller.BaseController
;
import
share.common.core.domain.AjaxResult
;
import
share.common.core.page.TableDataInfo
;
import
share.common.enums.BusinessType
;
import
share.common.utils.poi.ExcelUtil
;
import
share.system.domain.MonthlyCardOrder
;
import
share.system.service.MonthlyCardOrderService
;
import
javax.servlet.http.HttpServletResponse
;
import
java.util.List
;
/**
* 月卡订单Controller
*
* @author wuwenlong
* @date 2024-08-27
*/
@RestController
@RequestMapping
(
"/system/monthlyCardOrder"
)
public
class
MonthlyCardOrderController
extends
BaseController
{
@Autowired
private
MonthlyCardOrderService
monthlyCardOrderService
;
/**
* 查询月卡订单列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardOrder:list')"
)
@GetMapping
(
"/list"
)
public
TableDataInfo
list
(
MonthlyCardOrder
monthlyCardOrder
)
{
startPage
();
List
<
MonthlyCardOrder
>
list
=
monthlyCardOrderService
.
selectMonthlyCardOrderList
(
monthlyCardOrder
);
return
getDataTable
(
list
);
}
/**
* 导出月卡订单列表
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardOrder:export')"
)
@Log
(
title
=
"月卡订单"
,
businessType
=
BusinessType
.
EXPORT
)
@PostMapping
(
"/export"
)
public
void
export
(
HttpServletResponse
response
,
MonthlyCardOrder
monthlyCardOrder
)
{
List
<
MonthlyCardOrder
>
list
=
monthlyCardOrderService
.
selectMonthlyCardOrderList
(
monthlyCardOrder
);
ExcelUtil
<
MonthlyCardOrder
>
util
=
new
ExcelUtil
<
MonthlyCardOrder
>(
MonthlyCardOrder
.
class
);
util
.
exportExcel
(
response
,
list
,
"月卡订单数据"
);
}
/**
* 获取月卡订单详细信息
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardOrder:query')"
)
@GetMapping
(
value
=
"/{id}"
)
public
AjaxResult
getInfo
(
@PathVariable
(
"id"
)
Long
id
)
{
return
success
(
monthlyCardOrderService
.
selectMonthlyCardOrderById
(
id
));
}
/**
* 新增月卡订单
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardOrder:add')"
)
@Log
(
title
=
"月卡订单"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
public
AjaxResult
add
(
@RequestBody
MonthlyCardOrder
monthlyCardOrder
)
{
return
toAjax
(
monthlyCardOrderService
.
insertMonthlyCardOrder
(
monthlyCardOrder
));
}
/**
* 修改月卡订单
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardOrder:edit')"
)
@Log
(
title
=
"月卡订单"
,
businessType
=
BusinessType
.
UPDATE
)
@PutMapping
public
AjaxResult
edit
(
@RequestBody
MonthlyCardOrder
monthlyCardOrder
)
{
return
toAjax
(
monthlyCardOrderService
.
updateMonthlyCardOrder
(
monthlyCardOrder
));
}
/**
* 删除月卡订单
*/
@PreAuthorize
(
"@ss.hasPermi('system:monthlyCardOrder:remove')"
)
@Log
(
title
=
"月卡订单"
,
businessType
=
BusinessType
.
DELETE
)
@DeleteMapping
(
"/{ids}"
)
public
AjaxResult
remove
(
@PathVariable
Long
[]
ids
)
{
return
toAjax
(
monthlyCardOrderService
.
deleteMonthlyCardOrderByIds
(
ids
));
}
}
share-system/src/main/java/share/system/domain/ConsumerMonthlyCard.java
0 → 100644
View file @
4610898b
package
share
.
system
.
domain
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
share.common.annotation.Excel
;
import
share.common.core.domain.BaseEntity
;
import
java.util.Date
;
/**
* 用户月卡对象 s_consumer_monthly_card
*
* @author wuwenlong
* @date 2024-08-27
*/
@Data
public
class
ConsumerMonthlyCard
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 主键
*/
private
Long
id
;
/**
* 月卡配置表id
*/
@Excel
(
name
=
"月卡配置表id"
)
private
Long
monthlyCardConfId
;
/**
* 用户ID
*/
@Excel
(
name
=
"用户ID"
)
private
Long
consumerId
;
/**
* 用户手机号
*/
@Excel
(
name
=
"用户手机号"
)
private
String
phone
;
/**
* 免费时长
*/
@Excel
(
name
=
"免费时长"
)
private
Long
freeDuration
;
/**
* 月卡天数
*/
@Excel
(
name
=
"月卡天数"
)
private
Long
monthlyCardDays
;
/**
* 次卡有效期
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"次卡有效期"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
expirationDate
;
/**
* 删除标记:1-删除,0-正常
*/
private
Long
isDelete
;
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"id"
,
getId
())
.
append
(
"monthlyCardConfId"
,
getMonthlyCardConfId
())
.
append
(
"consumerId"
,
getConsumerId
())
.
append
(
"phone"
,
getPhone
())
.
append
(
"freeDuration"
,
getFreeDuration
())
.
append
(
"monthlyCardDays"
,
getMonthlyCardDays
())
.
append
(
"expirationDate"
,
getExpirationDate
())
.
append
(
"isDelete"
,
getIsDelete
())
.
append
(
"createBy"
,
getCreateBy
())
.
append
(
"createTime"
,
getCreateTime
())
.
append
(
"updateBy"
,
getUpdateBy
())
.
append
(
"updateTime"
,
getUpdateTime
())
.
append
(
"remark"
,
getRemark
())
.
toString
();
}
}
share-system/src/main/java/share/system/domain/MonthlyCardConf.java
0 → 100644
View file @
4610898b
package
share
.
system
.
domain
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableLogic
;
import
lombok.Data
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
share.common.annotation.Excel
;
import
share.common.core.domain.BaseEntity
;
import
java.math.BigDecimal
;
/**
* 月卡配置对象 s_monthly_card_conf
*
* @author wuwenlong
* @date 2024-08-27
*/
@Data
public
class
MonthlyCardConf
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 主键
*/
private
Long
id
;
/**
* 配置名称
*/
@Excel
(
name
=
"配置名称"
)
private
String
name
;
/**
* 月卡金额
*/
@Excel
(
name
=
"月卡金额"
)
private
BigDecimal
monthlyCardAmount
;
/**
* 免费时长
*/
@Excel
(
name
=
"免费时长"
)
private
Long
freeDuration
;
/**
* 月卡天数
*/
@Excel
(
name
=
"月卡天数"
)
private
Long
monthlyCardDays
;
/**
* 是否删除(0:否,1:是)
*/
//逻辑删除注解(0 未删除 1 已删除)
@TableLogic
@TableField
(
select
=
false
)
private
Long
isDelete
;
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"id"
,
getId
())
.
append
(
"name"
,
getName
())
.
append
(
"monthlyCardAmount"
,
getMonthlyCardAmount
())
.
append
(
"freeDuration"
,
getFreeDuration
())
.
append
(
"monthlyCardDays"
,
getMonthlyCardDays
())
.
append
(
"isDelete"
,
getIsDelete
())
.
append
(
"createBy"
,
getCreateBy
())
.
append
(
"createTime"
,
getCreateTime
())
.
append
(
"updateBy"
,
getUpdateBy
())
.
append
(
"updateTime"
,
getUpdateTime
())
.
append
(
"remark"
,
getRemark
())
.
toString
();
}
}
share-system/src/main/java/share/system/domain/MonthlyCardLog.java
0 → 100644
View file @
4610898b
package
share
.
system
.
domain
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableLogic
;
import
lombok.Data
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
share.common.annotation.Excel
;
import
share.common.core.domain.BaseEntity
;
/**
* 月卡使用记录对象 s_monthly_card_log
*
* @author wuwenlong
* @date 2024-08-27
*/
@Data
public
class
MonthlyCardLog
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 主键
*/
private
Long
id
;
/**
* 用户月卡id
*/
@Excel
(
name
=
"用户月卡id"
)
private
Long
consumerMonthlyCardId
;
/**
* 用户ID
*/
@Excel
(
name
=
"用户ID"
)
private
Long
consumerId
;
/**
* 用户手机号
*/
@Excel
(
name
=
"用户手机号"
)
private
String
phone
;
/**
* 使用时长
*/
@Excel
(
name
=
"使用时长"
)
private
Long
useDuration
;
/**
* 剩余时长
*/
@Excel
(
name
=
"剩余时长"
)
private
Long
residueDuration
;
/**
* 删除标记:1-删除,0-正常
*/
//逻辑删除注解(0 未删除 1 已删除)
@TableLogic
@TableField
(
select
=
false
)
private
Long
isDelete
;
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"id"
,
getId
())
.
append
(
"consumerMonthlyCardId"
,
getConsumerMonthlyCardId
())
.
append
(
"consumerId"
,
getConsumerId
())
.
append
(
"phone"
,
getPhone
())
.
append
(
"useDuration"
,
getUseDuration
())
.
append
(
"residueDuration"
,
getResidueDuration
())
.
append
(
"isDelete"
,
getIsDelete
())
.
append
(
"createBy"
,
getCreateBy
())
.
append
(
"createTime"
,
getCreateTime
())
.
append
(
"updateBy"
,
getUpdateBy
())
.
append
(
"updateTime"
,
getUpdateTime
())
.
append
(
"remark"
,
getRemark
())
.
toString
();
}
}
share-system/src/main/java/share/system/domain/MonthlyCardOrder.java
0 → 100644
View file @
4610898b
package
share
.
system
.
domain
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableLogic
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
share.common.annotation.Excel
;
import
share.common.core.domain.BaseEntity
;
import
java.math.BigDecimal
;
import
java.util.Date
;
/**
* 月卡订单对象 s_monthly_card_order
*
* @author wuwenlong
* @date 2024-08-27
*/
@Data
public
class
MonthlyCardOrder
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 主键
*/
private
Long
id
;
/**
* 月卡购买记录编号
*/
@Excel
(
name
=
"月卡购买记录编号"
)
private
String
monthlyCardNo
;
/**
* 扫呗平台唯一订单号
*/
@Excel
(
name
=
"扫呗平台唯一订单号"
)
private
String
outTradeNo
;
/**
* 商户订单号
*/
@Excel
(
name
=
"商户订单号"
)
private
String
terminalTrace
;
/**
* 月卡购买金额
*/
@Excel
(
name
=
"月卡购买金额"
)
private
BigDecimal
monthlyCardAmount
;
/**
* 月卡配置id
*/
@Excel
(
name
=
"月卡配置id"
)
private
Long
monthlyCardConfId
;
/**
* 用户ID
*/
@Excel
(
name
=
"用户ID"
)
private
Long
consumerId
;
/**
* 用户手机号
*/
@Excel
(
name
=
"用户手机号"
)
private
String
phone
;
/**
* 支付方式
*/
@Excel
(
name
=
"支付方式"
)
private
Long
payType
;
/**
* 状态:0-待支付,1-支付成功,2-退款中,3-退款完成
*/
@Excel
(
name
=
"状态:0-待支付,1-支付成功,2-退款中,3-退款完成"
)
private
Long
payStatus
;
/**
* 支付时间
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"支付时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
payTime
;
/**
* 是否删除(0:否,1:是)
*/
//逻辑删除注解(0 未删除 1 已删除)
@TableLogic
@TableField
(
select
=
false
)
private
Long
isDelete
;
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"id"
,
getId
())
.
append
(
"monthlyCardNo"
,
getMonthlyCardNo
())
.
append
(
"outTradeNo"
,
getOutTradeNo
())
.
append
(
"terminalTrace"
,
getTerminalTrace
())
.
append
(
"monthlyCardAmount"
,
getMonthlyCardAmount
())
.
append
(
"monthlyCardConfId"
,
getMonthlyCardConfId
())
.
append
(
"consumerId"
,
getConsumerId
())
.
append
(
"phone"
,
getPhone
())
.
append
(
"payType"
,
getPayType
())
.
append
(
"payStatus"
,
getPayStatus
())
.
append
(
"payTime"
,
getPayTime
())
.
append
(
"isDelete"
,
getIsDelete
())
.
append
(
"createBy"
,
getCreateBy
())
.
append
(
"createTime"
,
getCreateTime
())
.
append
(
"updateBy"
,
getUpdateBy
())
.
append
(
"updateTime"
,
getUpdateTime
())
.
append
(
"remark"
,
getRemark
())
.
toString
();
}
}
share-system/src/main/java/share/system/mapper/ConsumerMonthlyCardMapper.java
0 → 100644
View file @
4610898b
package
share
.
system
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
share.system.domain.ConsumerMonthlyCard
;
import
java.util.List
;
/**
* 用户月卡Mapper接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
ConsumerMonthlyCardMapper
extends
BaseMapper
<
ConsumerMonthlyCard
>
{
/**
* 查询用户月卡
*
* @param id 用户月卡主键
* @return 用户月卡
*/
public
ConsumerMonthlyCard
selectConsumerMonthlyCardById
(
Long
id
);
/**
* 查询用户月卡列表
*
* @param consumerMonthlyCard 用户月卡
* @return 用户月卡集合
*/
public
List
<
ConsumerMonthlyCard
>
selectConsumerMonthlyCardList
(
ConsumerMonthlyCard
consumerMonthlyCard
);
/**
* 新增用户月卡
*
* @param consumerMonthlyCard 用户月卡
* @return 结果
*/
public
int
insertConsumerMonthlyCard
(
ConsumerMonthlyCard
consumerMonthlyCard
);
/**
* 修改用户月卡
*
* @param consumerMonthlyCard 用户月卡
* @return 结果
*/
public
int
updateConsumerMonthlyCard
(
ConsumerMonthlyCard
consumerMonthlyCard
);
/**
* 删除用户月卡
*
* @param id 用户月卡主键
* @return 结果
*/
public
int
deleteConsumerMonthlyCardById
(
Long
id
);
/**
* 批量删除用户月卡
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public
int
deleteConsumerMonthlyCardByIds
(
Long
[]
ids
);
}
share-system/src/main/java/share/system/mapper/MonthlyCardConfMapper.java
0 → 100644
View file @
4610898b
package
share
.
system
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
share.system.domain.MonthlyCardConf
;
import
java.util.List
;
/**
* 月卡配置Mapper接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
MonthlyCardConfMapper
extends
BaseMapper
<
MonthlyCardConf
>
{
/**
* 查询月卡配置
*
* @param id 月卡配置主键
* @return 月卡配置
*/
public
MonthlyCardConf
selectMonthlyCardConfById
(
Long
id
);
/**
* 查询月卡配置列表
*
* @param monthlyCardConf 月卡配置
* @return 月卡配置集合
*/
public
List
<
MonthlyCardConf
>
selectMonthlyCardConfList
(
MonthlyCardConf
monthlyCardConf
);
/**
* 新增月卡配置
*
* @param monthlyCardConf 月卡配置
* @return 结果
*/
public
int
insertMonthlyCardConf
(
MonthlyCardConf
monthlyCardConf
);
/**
* 修改月卡配置
*
* @param monthlyCardConf 月卡配置
* @return 结果
*/
public
int
updateMonthlyCardConf
(
MonthlyCardConf
monthlyCardConf
);
/**
* 删除月卡配置
*
* @param id 月卡配置主键
* @return 结果
*/
public
int
deleteMonthlyCardConfById
(
Long
id
);
/**
* 批量删除月卡配置
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public
int
deleteMonthlyCardConfByIds
(
Long
[]
ids
);
}
share-system/src/main/java/share/system/mapper/MonthlyCardLogMapper.java
0 → 100644
View file @
4610898b
package
share
.
system
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
share.system.domain.MonthlyCardLog
;
import
java.util.List
;
/**
* 月卡使用记录Mapper接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
MonthlyCardLogMapper
extends
BaseMapper
<
MonthlyCardLog
>
{
/**
* 查询月卡使用记录
*
* @param id 月卡使用记录主键
* @return 月卡使用记录
*/
public
MonthlyCardLog
selectMonthlyCardLogById
(
Long
id
);
/**
* 查询月卡使用记录列表
*
* @param monthlyCardLog 月卡使用记录
* @return 月卡使用记录集合
*/
public
List
<
MonthlyCardLog
>
selectMonthlyCardLogList
(
MonthlyCardLog
monthlyCardLog
);
/**
* 新增月卡使用记录
*
* @param monthlyCardLog 月卡使用记录
* @return 结果
*/
public
int
insertMonthlyCardLog
(
MonthlyCardLog
monthlyCardLog
);
/**
* 修改月卡使用记录
*
* @param monthlyCardLog 月卡使用记录
* @return 结果
*/
public
int
updateMonthlyCardLog
(
MonthlyCardLog
monthlyCardLog
);
/**
* 删除月卡使用记录
*
* @param id 月卡使用记录主键
* @return 结果
*/
public
int
deleteMonthlyCardLogById
(
Long
id
);
/**
* 批量删除月卡使用记录
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public
int
deleteMonthlyCardLogByIds
(
Long
[]
ids
);
}
share-system/src/main/java/share/system/mapper/MonthlyCardOrderMapper.java
0 → 100644
View file @
4610898b
package
share
.
system
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
share.system.domain.MonthlyCardOrder
;
import
java.util.List
;
/**
* 月卡订单Mapper接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
MonthlyCardOrderMapper
extends
BaseMapper
<
MonthlyCardOrder
>
{
/**
* 查询月卡订单
*
* @param id 月卡订单主键
* @return 月卡订单
*/
public
MonthlyCardOrder
selectMonthlyCardOrderById
(
Long
id
);
/**
* 查询月卡订单列表
*
* @param monthlyCardOrder 月卡订单
* @return 月卡订单集合
*/
public
List
<
MonthlyCardOrder
>
selectMonthlyCardOrderList
(
MonthlyCardOrder
monthlyCardOrder
);
/**
* 新增月卡订单
*
* @param monthlyCardOrder 月卡订单
* @return 结果
*/
public
int
insertMonthlyCardOrder
(
MonthlyCardOrder
monthlyCardOrder
);
/**
* 修改月卡订单
*
* @param monthlyCardOrder 月卡订单
* @return 结果
*/
public
int
updateMonthlyCardOrder
(
MonthlyCardOrder
monthlyCardOrder
);
/**
* 删除月卡订单
*
* @param id 月卡订单主键
* @return 结果
*/
public
int
deleteMonthlyCardOrderById
(
Long
id
);
/**
* 批量删除月卡订单
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public
int
deleteMonthlyCardOrderByIds
(
Long
[]
ids
);
}
share-system/src/main/java/share/system/service/ConsumerMonthlyCardService.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
share.system.domain.ConsumerMonthlyCard
;
import
java.util.List
;
/**
* 用户月卡Service接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
ConsumerMonthlyCardService
extends
IService
<
ConsumerMonthlyCard
>
{
/**
* 查询用户月卡
*
* @param id 用户月卡主键
* @return 用户月卡
*/
public
ConsumerMonthlyCard
selectConsumerMonthlyCardById
(
Long
id
);
/**
* 查询用户月卡列表
*
* @param consumerMonthlyCard 用户月卡
* @return 用户月卡集合
*/
public
List
<
ConsumerMonthlyCard
>
selectConsumerMonthlyCardList
(
ConsumerMonthlyCard
consumerMonthlyCard
);
/**
* 新增用户月卡
*
* @param consumerMonthlyCard 用户月卡
* @return 结果
*/
public
int
insertConsumerMonthlyCard
(
ConsumerMonthlyCard
consumerMonthlyCard
);
/**
* 修改用户月卡
*
* @param consumerMonthlyCard 用户月卡
* @return 结果
*/
public
int
updateConsumerMonthlyCard
(
ConsumerMonthlyCard
consumerMonthlyCard
);
/**
* 批量删除用户月卡
*
* @param ids 需要删除的用户月卡主键集合
* @return 结果
*/
public
int
deleteConsumerMonthlyCardByIds
(
Long
[]
ids
);
/**
* 删除用户月卡信息
*
* @param id 用户月卡主键
* @return 结果
*/
public
int
deleteConsumerMonthlyCardById
(
Long
id
);
}
share-system/src/main/java/share/system/service/MonthlyCardConfService.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
share.system.domain.MonthlyCardConf
;
import
java.util.List
;
/**
* 月卡配置Service接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
MonthlyCardConfService
extends
IService
<
MonthlyCardConf
>
{
/**
* 查询月卡配置
*
* @param id 月卡配置主键
* @return 月卡配置
*/
public
MonthlyCardConf
selectMonthlyCardConfById
(
Long
id
);
/**
* 查询月卡配置列表
*
* @param monthlyCardConf 月卡配置
* @return 月卡配置集合
*/
public
List
<
MonthlyCardConf
>
selectMonthlyCardConfList
(
MonthlyCardConf
monthlyCardConf
);
/**
* 新增月卡配置
*
* @param monthlyCardConf 月卡配置
* @return 结果
*/
public
int
insertMonthlyCardConf
(
MonthlyCardConf
monthlyCardConf
);
/**
* 修改月卡配置
*
* @param monthlyCardConf 月卡配置
* @return 结果
*/
public
int
updateMonthlyCardConf
(
MonthlyCardConf
monthlyCardConf
);
/**
* 批量删除月卡配置
*
* @param ids 需要删除的月卡配置主键集合
* @return 结果
*/
public
int
deleteMonthlyCardConfByIds
(
Long
[]
ids
);
/**
* 删除月卡配置信息
*
* @param id 月卡配置主键
* @return 结果
*/
public
int
deleteMonthlyCardConfById
(
Long
id
);
}
share-system/src/main/java/share/system/service/MonthlyCardLogService.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
share.system.domain.MonthlyCardLog
;
import
java.util.List
;
/**
* 月卡使用记录Service接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
MonthlyCardLogService
extends
IService
<
MonthlyCardLog
>
{
/**
* 查询月卡使用记录
*
* @param id 月卡使用记录主键
* @return 月卡使用记录
*/
public
MonthlyCardLog
selectMonthlyCardLogById
(
Long
id
);
/**
* 查询月卡使用记录列表
*
* @param monthlyCardLog 月卡使用记录
* @return 月卡使用记录集合
*/
public
List
<
MonthlyCardLog
>
selectMonthlyCardLogList
(
MonthlyCardLog
monthlyCardLog
);
/**
* 新增月卡使用记录
*
* @param monthlyCardLog 月卡使用记录
* @return 结果
*/
public
int
insertMonthlyCardLog
(
MonthlyCardLog
monthlyCardLog
);
/**
* 修改月卡使用记录
*
* @param monthlyCardLog 月卡使用记录
* @return 结果
*/
public
int
updateMonthlyCardLog
(
MonthlyCardLog
monthlyCardLog
);
/**
* 批量删除月卡使用记录
*
* @param ids 需要删除的月卡使用记录主键集合
* @return 结果
*/
public
int
deleteMonthlyCardLogByIds
(
Long
[]
ids
);
/**
* 删除月卡使用记录信息
*
* @param id 月卡使用记录主键
* @return 结果
*/
public
int
deleteMonthlyCardLogById
(
Long
id
);
}
share-system/src/main/java/share/system/service/MonthlyCardOrderService.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
share.system.domain.MonthlyCardOrder
;
import
java.util.List
;
/**
* 月卡订单Service接口
*
* @author wuwenlong
* @date 2024-08-27
*/
public
interface
MonthlyCardOrderService
extends
IService
<
MonthlyCardOrder
>
{
/**
* 查询月卡订单
*
* @param id 月卡订单主键
* @return 月卡订单
*/
public
MonthlyCardOrder
selectMonthlyCardOrderById
(
Long
id
);
/**
* 查询月卡订单列表
*
* @param monthlyCardOrder 月卡订单
* @return 月卡订单集合
*/
public
List
<
MonthlyCardOrder
>
selectMonthlyCardOrderList
(
MonthlyCardOrder
monthlyCardOrder
);
/**
* 新增月卡订单
*
* @param monthlyCardOrder 月卡订单
* @return 结果
*/
public
int
insertMonthlyCardOrder
(
MonthlyCardOrder
monthlyCardOrder
);
/**
* 修改月卡订单
*
* @param monthlyCardOrder 月卡订单
* @return 结果
*/
public
int
updateMonthlyCardOrder
(
MonthlyCardOrder
monthlyCardOrder
);
/**
* 批量删除月卡订单
*
* @param ids 需要删除的月卡订单主键集合
* @return 结果
*/
public
int
deleteMonthlyCardOrderByIds
(
Long
[]
ids
);
/**
* 删除月卡订单信息
*
* @param id 月卡订单主键
* @return 结果
*/
public
int
deleteMonthlyCardOrderById
(
Long
id
);
}
share-system/src/main/java/share/system/service/impl/ConsumerMonthlyCardServiceImpl.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
share.common.utils.DateUtils
;
import
share.system.domain.ConsumerMonthlyCard
;
import
share.system.mapper.ConsumerMonthlyCardMapper
;
import
share.system.service.ConsumerMonthlyCardService
;
import
java.util.List
;
/**
* 用户月卡Service业务层处理
*
* @author wuwenlong
* @date 2024-08-27
*/
@Service
public
class
ConsumerMonthlyCardServiceImpl
extends
ServiceImpl
<
ConsumerMonthlyCardMapper
,
ConsumerMonthlyCard
>
implements
ConsumerMonthlyCardService
{
@Autowired
private
ConsumerMonthlyCardMapper
consumerMonthlyCardMapper
;
/**
* 查询用户月卡
*
* @param id 用户月卡主键
* @return 用户月卡
*/
@Override
public
ConsumerMonthlyCard
selectConsumerMonthlyCardById
(
Long
id
)
{
return
consumerMonthlyCardMapper
.
selectConsumerMonthlyCardById
(
id
);
}
/**
* 查询用户月卡列表
*
* @param consumerMonthlyCard 用户月卡
* @return 用户月卡
*/
@Override
public
List
<
ConsumerMonthlyCard
>
selectConsumerMonthlyCardList
(
ConsumerMonthlyCard
consumerMonthlyCard
)
{
return
consumerMonthlyCardMapper
.
selectConsumerMonthlyCardList
(
consumerMonthlyCard
);
}
/**
* 新增用户月卡
*
* @param consumerMonthlyCard 用户月卡
* @return 结果
*/
@Override
public
int
insertConsumerMonthlyCard
(
ConsumerMonthlyCard
consumerMonthlyCard
)
{
consumerMonthlyCard
.
setCreateTime
(
DateUtils
.
getNowDate
());
return
consumerMonthlyCardMapper
.
insertConsumerMonthlyCard
(
consumerMonthlyCard
);
}
/**
* 修改用户月卡
*
* @param consumerMonthlyCard 用户月卡
* @return 结果
*/
@Override
public
int
updateConsumerMonthlyCard
(
ConsumerMonthlyCard
consumerMonthlyCard
)
{
consumerMonthlyCard
.
setUpdateTime
(
DateUtils
.
getNowDate
());
return
consumerMonthlyCardMapper
.
updateConsumerMonthlyCard
(
consumerMonthlyCard
);
}
/**
* 批量删除用户月卡
*
* @param ids 需要删除的用户月卡主键
* @return 结果
*/
@Override
public
int
deleteConsumerMonthlyCardByIds
(
Long
[]
ids
)
{
return
consumerMonthlyCardMapper
.
deleteConsumerMonthlyCardByIds
(
ids
);
}
/**
* 删除用户月卡信息
*
* @param id 用户月卡主键
* @return 结果
*/
@Override
public
int
deleteConsumerMonthlyCardById
(
Long
id
)
{
return
consumerMonthlyCardMapper
.
deleteConsumerMonthlyCardById
(
id
);
}
}
share-system/src/main/java/share/system/service/impl/MonthlyCardConfServiceImpl.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
share.common.utils.DateUtils
;
import
share.system.domain.MonthlyCardConf
;
import
share.system.mapper.MonthlyCardConfMapper
;
import
share.system.service.MonthlyCardConfService
;
import
java.util.List
;
/**
* 月卡配置Service业务层处理
*
* @author wuwenlong
* @date 2024-08-27
*/
@Service
public
class
MonthlyCardConfServiceImpl
extends
ServiceImpl
<
MonthlyCardConfMapper
,
MonthlyCardConf
>
implements
MonthlyCardConfService
{
@Autowired
private
MonthlyCardConfMapper
monthlyCardConfMapper
;
/**
* 查询月卡配置
*
* @param id 月卡配置主键
* @return 月卡配置
*/
@Override
public
MonthlyCardConf
selectMonthlyCardConfById
(
Long
id
)
{
return
monthlyCardConfMapper
.
selectMonthlyCardConfById
(
id
);
}
/**
* 查询月卡配置列表
*
* @param monthlyCardConf 月卡配置
* @return 月卡配置
*/
@Override
public
List
<
MonthlyCardConf
>
selectMonthlyCardConfList
(
MonthlyCardConf
monthlyCardConf
)
{
return
monthlyCardConfMapper
.
selectMonthlyCardConfList
(
monthlyCardConf
);
}
/**
* 新增月卡配置
*
* @param monthlyCardConf 月卡配置
* @return 结果
*/
@Override
public
int
insertMonthlyCardConf
(
MonthlyCardConf
monthlyCardConf
)
{
monthlyCardConf
.
setCreateTime
(
DateUtils
.
getNowDate
());
return
monthlyCardConfMapper
.
insertMonthlyCardConf
(
monthlyCardConf
);
}
/**
* 修改月卡配置
*
* @param monthlyCardConf 月卡配置
* @return 结果
*/
@Override
public
int
updateMonthlyCardConf
(
MonthlyCardConf
monthlyCardConf
)
{
monthlyCardConf
.
setUpdateTime
(
DateUtils
.
getNowDate
());
return
monthlyCardConfMapper
.
updateMonthlyCardConf
(
monthlyCardConf
);
}
/**
* 批量删除月卡配置
*
* @param ids 需要删除的月卡配置主键
* @return 结果
*/
@Override
public
int
deleteMonthlyCardConfByIds
(
Long
[]
ids
)
{
return
monthlyCardConfMapper
.
deleteMonthlyCardConfByIds
(
ids
);
}
/**
* 删除月卡配置信息
*
* @param id 月卡配置主键
* @return 结果
*/
@Override
public
int
deleteMonthlyCardConfById
(
Long
id
)
{
return
monthlyCardConfMapper
.
deleteMonthlyCardConfById
(
id
);
}
}
share-system/src/main/java/share/system/service/impl/MonthlyCardLogServiceImpl.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
share.common.utils.DateUtils
;
import
share.system.domain.MonthlyCardLog
;
import
share.system.mapper.MonthlyCardLogMapper
;
import
share.system.service.MonthlyCardLogService
;
import
java.util.List
;
/**
* 月卡使用记录Service业务层处理
*
* @author wuwenlong
* @date 2024-08-27
*/
@Service
public
class
MonthlyCardLogServiceImpl
extends
ServiceImpl
<
MonthlyCardLogMapper
,
MonthlyCardLog
>
implements
MonthlyCardLogService
{
@Autowired
private
MonthlyCardLogMapper
monthlyCardLogMapper
;
/**
* 查询月卡使用记录
*
* @param id 月卡使用记录主键
* @return 月卡使用记录
*/
@Override
public
MonthlyCardLog
selectMonthlyCardLogById
(
Long
id
)
{
return
monthlyCardLogMapper
.
selectMonthlyCardLogById
(
id
);
}
/**
* 查询月卡使用记录列表
*
* @param monthlyCardLog 月卡使用记录
* @return 月卡使用记录
*/
@Override
public
List
<
MonthlyCardLog
>
selectMonthlyCardLogList
(
MonthlyCardLog
monthlyCardLog
)
{
return
monthlyCardLogMapper
.
selectMonthlyCardLogList
(
monthlyCardLog
);
}
/**
* 新增月卡使用记录
*
* @param monthlyCardLog 月卡使用记录
* @return 结果
*/
@Override
public
int
insertMonthlyCardLog
(
MonthlyCardLog
monthlyCardLog
)
{
monthlyCardLog
.
setCreateTime
(
DateUtils
.
getNowDate
());
return
monthlyCardLogMapper
.
insertMonthlyCardLog
(
monthlyCardLog
);
}
/**
* 修改月卡使用记录
*
* @param monthlyCardLog 月卡使用记录
* @return 结果
*/
@Override
public
int
updateMonthlyCardLog
(
MonthlyCardLog
monthlyCardLog
)
{
monthlyCardLog
.
setUpdateTime
(
DateUtils
.
getNowDate
());
return
monthlyCardLogMapper
.
updateMonthlyCardLog
(
monthlyCardLog
);
}
/**
* 批量删除月卡使用记录
*
* @param ids 需要删除的月卡使用记录主键
* @return 结果
*/
@Override
public
int
deleteMonthlyCardLogByIds
(
Long
[]
ids
)
{
return
monthlyCardLogMapper
.
deleteMonthlyCardLogByIds
(
ids
);
}
/**
* 删除月卡使用记录信息
*
* @param id 月卡使用记录主键
* @return 结果
*/
@Override
public
int
deleteMonthlyCardLogById
(
Long
id
)
{
return
monthlyCardLogMapper
.
deleteMonthlyCardLogById
(
id
);
}
}
share-system/src/main/java/share/system/service/impl/MonthlyCardOrderServiceImpl.java
0 → 100644
View file @
4610898b
package
share
.
system
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
share.common.utils.DateUtils
;
import
share.system.domain.MonthlyCardOrder
;
import
share.system.mapper.MonthlyCardOrderMapper
;
import
share.system.service.MonthlyCardOrderService
;
import
java.util.List
;
/**
* 月卡订单Service业务层处理
*
* @author wuwenlong
* @date 2024-08-27
*/
@Service
public
class
MonthlyCardOrderServiceImpl
extends
ServiceImpl
<
MonthlyCardOrderMapper
,
MonthlyCardOrder
>
implements
MonthlyCardOrderService
{
@Autowired
private
MonthlyCardOrderMapper
monthlyCardOrderMapper
;
/**
* 查询月卡订单
*
* @param id 月卡订单主键
* @return 月卡订单
*/
@Override
public
MonthlyCardOrder
selectMonthlyCardOrderById
(
Long
id
)
{
return
monthlyCardOrderMapper
.
selectMonthlyCardOrderById
(
id
);
}
/**
* 查询月卡订单列表
*
* @param monthlyCardOrder 月卡订单
* @return 月卡订单
*/
@Override
public
List
<
MonthlyCardOrder
>
selectMonthlyCardOrderList
(
MonthlyCardOrder
monthlyCardOrder
)
{
return
monthlyCardOrderMapper
.
selectMonthlyCardOrderList
(
monthlyCardOrder
);
}
/**
* 新增月卡订单
*
* @param monthlyCardOrder 月卡订单
* @return 结果
*/
@Override
public
int
insertMonthlyCardOrder
(
MonthlyCardOrder
monthlyCardOrder
)
{
monthlyCardOrder
.
setCreateTime
(
DateUtils
.
getNowDate
());
return
monthlyCardOrderMapper
.
insertMonthlyCardOrder
(
monthlyCardOrder
);
}
/**
* 修改月卡订单
*
* @param monthlyCardOrder 月卡订单
* @return 结果
*/
@Override
public
int
updateMonthlyCardOrder
(
MonthlyCardOrder
monthlyCardOrder
)
{
monthlyCardOrder
.
setUpdateTime
(
DateUtils
.
getNowDate
());
return
monthlyCardOrderMapper
.
updateMonthlyCardOrder
(
monthlyCardOrder
);
}
/**
* 批量删除月卡订单
*
* @param ids 需要删除的月卡订单主键
* @return 结果
*/
@Override
public
int
deleteMonthlyCardOrderByIds
(
Long
[]
ids
)
{
return
monthlyCardOrderMapper
.
deleteMonthlyCardOrderByIds
(
ids
);
}
/**
* 删除月卡订单信息
*
* @param id 月卡订单主键
* @return 结果
*/
@Override
public
int
deleteMonthlyCardOrderById
(
Long
id
)
{
return
monthlyCardOrderMapper
.
deleteMonthlyCardOrderById
(
id
);
}
}
share-system/src/main/resources/mapper/system/ConsumerMonthlyCardMapper.xml
0 → 100644
View file @
4610898b
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"share.system.mapper.ConsumerMonthlyCardMapper"
>
<resultMap
type=
"ConsumerMonthlyCard"
id=
"ConsumerMonthlyCardResult"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"monthlyCardConfId"
column=
"monthly_card_conf_id"
/>
<result
property=
"consumerId"
column=
"consumer_id"
/>
<result
property=
"phone"
column=
"phone"
/>
<result
property=
"freeDuration"
column=
"free_duration"
/>
<result
property=
"monthlyCardDays"
column=
"monthly_card_days"
/>
<result
property=
"expirationDate"
column=
"expiration_date"
/>
<result
property=
"isDelete"
column=
"is_delete"
/>
<result
property=
"createBy"
column=
"create_by"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"updateBy"
column=
"update_by"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"remark"
column=
"remark"
/>
</resultMap>
<sql
id=
"selectConsumerMonthlyCardVo"
>
select id,
monthly_card_conf_id,
consumer_id,
phone,
free_duration,
monthly_card_days,
expiration_date,
is_delete,
create_by,
create_time,
update_by,
update_time,
remark
from s_consumer_monthly_card
</sql>
<select
id=
"selectConsumerMonthlyCardList"
parameterType=
"ConsumerMonthlyCard"
resultMap=
"ConsumerMonthlyCardResult"
>
<include
refid=
"selectConsumerMonthlyCardVo"
/>
<where>
<if
test=
"monthlyCardConfId != null "
>
and monthly_card_conf_id = #{monthlyCardConfId}
</if>
<if
test=
"consumerId != null "
>
and consumer_id = #{consumerId}
</if>
<if
test=
"phone != null and phone != ''"
>
and phone = #{phone}
</if>
<if
test=
"freeDuration != null "
>
and free_duration = #{freeDuration}
</if>
<if
test=
"monthlyCardDays != null "
>
and monthly_card_days = #{monthlyCardDays}
</if>
<if
test=
"expirationDate != null "
>
and expiration_date = #{expirationDate}
</if>
</where>
</select>
<select
id=
"selectConsumerMonthlyCardById"
parameterType=
"Long"
resultMap=
"ConsumerMonthlyCardResult"
>
<include
refid=
"selectConsumerMonthlyCardVo"
/>
where id = #{id}
</select>
<insert
id=
"insertConsumerMonthlyCard"
parameterType=
"ConsumerMonthlyCard"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
insert into s_consumer_monthly_card
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"monthlyCardConfId != null"
>
monthly_card_conf_id,
</if>
<if
test=
"consumerId != null"
>
consumer_id,
</if>
<if
test=
"phone != null and phone != ''"
>
phone,
</if>
<if
test=
"freeDuration != null"
>
free_duration,
</if>
<if
test=
"monthlyCardDays != null"
>
monthly_card_days,
</if>
<if
test=
"expirationDate != null"
>
expiration_date,
</if>
<if
test=
"isDelete != null"
>
is_delete,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
<if
test=
"updateBy != null"
>
update_by,
</if>
<if
test=
"updateTime != null"
>
update_time,
</if>
<if
test=
"remark != null"
>
remark,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"monthlyCardConfId != null"
>
#{monthlyCardConfId},
</if>
<if
test=
"consumerId != null"
>
#{consumerId},
</if>
<if
test=
"phone != null and phone != ''"
>
#{phone},
</if>
<if
test=
"freeDuration != null"
>
#{freeDuration},
</if>
<if
test=
"monthlyCardDays != null"
>
#{monthlyCardDays},
</if>
<if
test=
"expirationDate != null"
>
#{expirationDate},
</if>
<if
test=
"isDelete != null"
>
#{isDelete},
</if>
<if
test=
"createBy != null"
>
#{createBy},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
<if
test=
"updateBy != null"
>
#{updateBy},
</if>
<if
test=
"updateTime != null"
>
#{updateTime},
</if>
<if
test=
"remark != null"
>
#{remark},
</if>
</trim>
</insert>
<update
id=
"updateConsumerMonthlyCard"
parameterType=
"ConsumerMonthlyCard"
>
update s_consumer_monthly_card
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"monthlyCardConfId != null"
>
monthly_card_conf_id = #{monthlyCardConfId},
</if>
<if
test=
"consumerId != null"
>
consumer_id = #{consumerId},
</if>
<if
test=
"phone != null and phone != ''"
>
phone = #{phone},
</if>
<if
test=
"freeDuration != null"
>
free_duration = #{freeDuration},
</if>
<if
test=
"monthlyCardDays != null"
>
monthly_card_days = #{monthlyCardDays},
</if>
<if
test=
"expirationDate != null"
>
expiration_date = #{expirationDate},
</if>
<if
test=
"isDelete != null"
>
is_delete = #{isDelete},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime},
</if>
<if
test=
"updateBy != null"
>
update_by = #{updateBy},
</if>
<if
test=
"updateTime != null"
>
update_time = #{updateTime},
</if>
<if
test=
"remark != null"
>
remark = #{remark},
</if>
</trim>
where id = #{id}
</update>
<delete
id=
"deleteConsumerMonthlyCardById"
parameterType=
"Long"
>
delete
from s_consumer_monthly_card
where id = #{id}
</delete>
<delete
id=
"deleteConsumerMonthlyCardByIds"
parameterType=
"String"
>
delete from s_consumer_monthly_card where id in
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
</delete>
</mapper>
\ No newline at end of file
share-system/src/main/resources/mapper/system/ConsumerSecondaryCardMapper.xml
View file @
4610898b
...
@@ -74,8 +74,6 @@
...
@@ -74,8 +74,6 @@
<if
test=
"packId != null "
>
and c.pack_id = #{packId}
</if>
<if
test=
"packId != null "
>
and c.pack_id = #{packId}
</if>
<if
test=
"expirationDate != null "
>
and c.expiration_date = #{expirationDate}
</if>
<if
test=
"expirationDate != null "
>
and c.expiration_date = #{expirationDate}
</if>
<if
test=
"number != null "
>
and c.number = #{number}
</if>
<if
test=
"number != null "
>
and c.number = #{number}
</if>
<if
test=
"isDelete != null "
>
and c.is_delete = #{isDelete}
</if>
</select>
</select>
<select
id=
"selectConsumerSecondaryCardById"
parameterType=
"Long"
resultMap=
"ConsumerSecondaryCardResult"
>
<select
id=
"selectConsumerSecondaryCardById"
parameterType=
"Long"
resultMap=
"ConsumerSecondaryCardResult"
>
...
...
share-system/src/main/resources/mapper/system/MonthlyCardConfMapper.xml
0 → 100644
View file @
4610898b
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"share.system.mapper.MonthlyCardConfMapper"
>
<resultMap
type=
"MonthlyCardConf"
id=
"MonthlyCardConfResult"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"name"
column=
"name"
/>
<result
property=
"monthlyCardAmount"
column=
"monthly_card_amount"
/>
<result
property=
"freeDuration"
column=
"free_duration"
/>
<result
property=
"monthlyCardDays"
column=
"monthly_card_days"
/>
<result
property=
"isDelete"
column=
"is_delete"
/>
<result
property=
"createBy"
column=
"create_by"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"updateBy"
column=
"update_by"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"remark"
column=
"remark"
/>
</resultMap>
<sql
id=
"selectMonthlyCardConfVo"
>
select id,
name,
monthly_card_amount,
free_duration,
monthly_card_days,
is_delete,
create_by,
create_time,
update_by,
update_time,
remark
from s_monthly_card_conf
</sql>
<select
id=
"selectMonthlyCardConfList"
parameterType=
"MonthlyCardConf"
resultMap=
"MonthlyCardConfResult"
>
<include
refid=
"selectMonthlyCardConfVo"
/>
<where>
<if
test=
"name != null and name != ''"
>
and name like concat('%', #{name}, '%')
</if>
<if
test=
"monthlyCardAmount != null "
>
and monthly_card_amount = #{monthlyCardAmount}
</if>
<if
test=
"freeDuration != null "
>
and free_duration = #{freeDuration}
</if>
<if
test=
"monthlyCardDays != null "
>
and monthly_card_days = #{monthlyCardDays}
</if>
<if
test=
"isDelete != null "
>
and is_delete = #{isDelete}
</if>
</where>
</select>
<select
id=
"selectMonthlyCardConfById"
parameterType=
"Long"
resultMap=
"MonthlyCardConfResult"
>
<include
refid=
"selectMonthlyCardConfVo"
/>
where id = #{id}
</select>
<insert
id=
"insertMonthlyCardConf"
parameterType=
"MonthlyCardConf"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
insert into s_monthly_card_conf
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"name != null"
>
name,
</if>
<if
test=
"monthlyCardAmount != null"
>
monthly_card_amount,
</if>
<if
test=
"freeDuration != null"
>
free_duration,
</if>
<if
test=
"monthlyCardDays != null"
>
monthly_card_days,
</if>
<if
test=
"isDelete != null"
>
is_delete,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
<if
test=
"updateBy != null"
>
update_by,
</if>
<if
test=
"updateTime != null"
>
update_time,
</if>
<if
test=
"remark != null"
>
remark,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"name != null"
>
#{name},
</if>
<if
test=
"monthlyCardAmount != null"
>
#{monthlyCardAmount},
</if>
<if
test=
"freeDuration != null"
>
#{freeDuration},
</if>
<if
test=
"monthlyCardDays != null"
>
#{monthlyCardDays},
</if>
<if
test=
"isDelete != null"
>
#{isDelete},
</if>
<if
test=
"createBy != null"
>
#{createBy},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
<if
test=
"updateBy != null"
>
#{updateBy},
</if>
<if
test=
"updateTime != null"
>
#{updateTime},
</if>
<if
test=
"remark != null"
>
#{remark},
</if>
</trim>
</insert>
<update
id=
"updateMonthlyCardConf"
parameterType=
"MonthlyCardConf"
>
update s_monthly_card_conf
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"name != null"
>
name = #{name},
</if>
<if
test=
"monthlyCardAmount != null"
>
monthly_card_amount = #{monthlyCardAmount},
</if>
<if
test=
"freeDuration != null"
>
free_duration = #{freeDuration},
</if>
<if
test=
"monthlyCardDays != null"
>
monthly_card_days = #{monthlyCardDays},
</if>
<if
test=
"isDelete != null"
>
is_delete = #{isDelete},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime},
</if>
<if
test=
"updateBy != null"
>
update_by = #{updateBy},
</if>
<if
test=
"updateTime != null"
>
update_time = #{updateTime},
</if>
<if
test=
"remark != null"
>
remark = #{remark},
</if>
</trim>
where id = #{id}
</update>
<delete
id=
"deleteMonthlyCardConfById"
parameterType=
"Long"
>
delete
from s_monthly_card_conf
where id = #{id}
</delete>
<delete
id=
"deleteMonthlyCardConfByIds"
parameterType=
"String"
>
delete from s_monthly_card_conf where id in
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
</delete>
</mapper>
\ No newline at end of file
share-system/src/main/resources/mapper/system/MonthlyCardLogMapper.xml
0 → 100644
View file @
4610898b
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"share.system.mapper.MonthlyCardLogMapper"
>
<resultMap
type=
"MonthlyCardLog"
id=
"MonthlyCardLogResult"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"consumerMonthlyCardId"
column=
"consumer_monthly_card_id"
/>
<result
property=
"consumerId"
column=
"consumer_id"
/>
<result
property=
"phone"
column=
"phone"
/>
<result
property=
"useDuration"
column=
"use_duration"
/>
<result
property=
"residueDuration"
column=
"residue_duration"
/>
<result
property=
"isDelete"
column=
"is_delete"
/>
<result
property=
"createBy"
column=
"create_by"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"updateBy"
column=
"update_by"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"remark"
column=
"remark"
/>
</resultMap>
<sql
id=
"selectMonthlyCardLogVo"
>
select id,
consumer_monthly_card_id,
consumer_id,
phone,
use_duration,
residue_duration,
is_delete,
create_by,
create_time,
update_by,
update_time,
remark
from s_monthly_card_log
</sql>
<select
id=
"selectMonthlyCardLogList"
parameterType=
"MonthlyCardLog"
resultMap=
"MonthlyCardLogResult"
>
<include
refid=
"selectMonthlyCardLogVo"
/>
<where>
<if
test=
"consumerMonthlyCardId != null "
>
and consumer_monthly_card_id = #{consumerMonthlyCardId}
</if>
<if
test=
"consumerId != null "
>
and consumer_id = #{consumerId}
</if>
<if
test=
"phone != null and phone != ''"
>
and phone = #{phone}
</if>
<if
test=
"useDuration != null "
>
and use_duration = #{useDuration}
</if>
<if
test=
"residueDuration != null "
>
and residue_duration = #{residueDuration}
</if>
<if
test=
"isDelete != null "
>
and is_delete = #{isDelete}
</if>
</where>
</select>
<select
id=
"selectMonthlyCardLogById"
parameterType=
"Long"
resultMap=
"MonthlyCardLogResult"
>
<include
refid=
"selectMonthlyCardLogVo"
/>
where id = #{id}
</select>
<insert
id=
"insertMonthlyCardLog"
parameterType=
"MonthlyCardLog"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
insert into s_monthly_card_log
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"consumerMonthlyCardId != null"
>
consumer_monthly_card_id,
</if>
<if
test=
"consumerId != null"
>
consumer_id,
</if>
<if
test=
"phone != null and phone != ''"
>
phone,
</if>
<if
test=
"useDuration != null"
>
use_duration,
</if>
<if
test=
"residueDuration != null"
>
residue_duration,
</if>
<if
test=
"isDelete != null"
>
is_delete,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
<if
test=
"updateBy != null"
>
update_by,
</if>
<if
test=
"updateTime != null"
>
update_time,
</if>
<if
test=
"remark != null"
>
remark,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"consumerMonthlyCardId != null"
>
#{consumerMonthlyCardId},
</if>
<if
test=
"consumerId != null"
>
#{consumerId},
</if>
<if
test=
"phone != null and phone != ''"
>
#{phone},
</if>
<if
test=
"useDuration != null"
>
#{useDuration},
</if>
<if
test=
"residueDuration != null"
>
#{residueDuration},
</if>
<if
test=
"isDelete != null"
>
#{isDelete},
</if>
<if
test=
"createBy != null"
>
#{createBy},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
<if
test=
"updateBy != null"
>
#{updateBy},
</if>
<if
test=
"updateTime != null"
>
#{updateTime},
</if>
<if
test=
"remark != null"
>
#{remark},
</if>
</trim>
</insert>
<update
id=
"updateMonthlyCardLog"
parameterType=
"MonthlyCardLog"
>
update s_monthly_card_log
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"consumerMonthlyCardId != null"
>
consumer_monthly_card_id = #{consumerMonthlyCardId},
</if>
<if
test=
"consumerId != null"
>
consumer_id = #{consumerId},
</if>
<if
test=
"phone != null and phone != ''"
>
phone = #{phone},
</if>
<if
test=
"useDuration != null"
>
use_duration = #{useDuration},
</if>
<if
test=
"residueDuration != null"
>
residue_duration = #{residueDuration},
</if>
<if
test=
"isDelete != null"
>
is_delete = #{isDelete},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime},
</if>
<if
test=
"updateBy != null"
>
update_by = #{updateBy},
</if>
<if
test=
"updateTime != null"
>
update_time = #{updateTime},
</if>
<if
test=
"remark != null"
>
remark = #{remark},
</if>
</trim>
where id = #{id}
</update>
<delete
id=
"deleteMonthlyCardLogById"
parameterType=
"Long"
>
delete
from s_monthly_card_log
where id = #{id}
</delete>
<delete
id=
"deleteMonthlyCardLogByIds"
parameterType=
"String"
>
delete from s_monthly_card_log where id in
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
</delete>
</mapper>
\ No newline at end of file
share-system/src/main/resources/mapper/system/MonthlyCardOrderMapper.xml
0 → 100644
View file @
4610898b
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"share.system.mapper.MonthlyCardOrderMapper"
>
<resultMap
type=
"MonthlyCardOrder"
id=
"MonthlyCardOrderResult"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"monthlyCardNo"
column=
"monthly_card_no"
/>
<result
property=
"outTradeNo"
column=
"out_trade_no"
/>
<result
property=
"terminalTrace"
column=
"terminal_trace"
/>
<result
property=
"monthlyCardAmount"
column=
"monthly_card_amount"
/>
<result
property=
"monthlyCardConfId"
column=
"monthly_card_conf_id"
/>
<result
property=
"consumerId"
column=
"consumer_id"
/>
<result
property=
"phone"
column=
"phone"
/>
<result
property=
"payType"
column=
"pay_type"
/>
<result
property=
"payStatus"
column=
"pay_status"
/>
<result
property=
"payTime"
column=
"pay_time"
/>
<result
property=
"isDelete"
column=
"is_delete"
/>
<result
property=
"createBy"
column=
"create_by"
/>
<result
property=
"createTime"
column=
"create_time"
/>
<result
property=
"updateBy"
column=
"update_by"
/>
<result
property=
"updateTime"
column=
"update_time"
/>
<result
property=
"remark"
column=
"remark"
/>
</resultMap>
<sql
id=
"selectMonthlyCardOrderVo"
>
select id,
monthly_card_no,
out_trade_no,
terminal_trace,
monthly_card_amount,
monthly_card_conf_id,
consumer_id,
phone,
pay_type,
pay_status,
pay_time,
is_delete,
create_by,
create_time,
update_by,
update_time,
remark
from s_monthly_card_order
</sql>
<select
id=
"selectMonthlyCardOrderList"
parameterType=
"MonthlyCardOrder"
resultMap=
"MonthlyCardOrderResult"
>
<include
refid=
"selectMonthlyCardOrderVo"
/>
<where>
<if
test=
"monthlyCardNo != null and monthlyCardNo != ''"
>
and monthly_card_no = #{monthlyCardNo}
</if>
<if
test=
"outTradeNo != null and outTradeNo != ''"
>
and out_trade_no = #{outTradeNo}
</if>
<if
test=
"terminalTrace != null and terminalTrace != ''"
>
and terminal_trace = #{terminalTrace}
</if>
<if
test=
"monthlyCardAmount != null "
>
and monthly_card_amount = #{monthlyCardAmount}
</if>
<if
test=
"monthlyCardConfId != null "
>
and monthly_card_conf_id = #{monthlyCardConfId}
</if>
<if
test=
"consumerId != null "
>
and consumer_id = #{consumerId}
</if>
<if
test=
"phone != null and phone != ''"
>
and phone = #{phone}
</if>
<if
test=
"payType != null "
>
and pay_type = #{payType}
</if>
<if
test=
"payStatus != null "
>
and pay_status = #{payStatus}
</if>
<if
test=
"payTime != null "
>
and pay_time = #{payTime}
</if>
<if
test=
"isDelete != null "
>
and is_delete = #{isDelete}
</if>
</where>
</select>
<select
id=
"selectMonthlyCardOrderById"
parameterType=
"Long"
resultMap=
"MonthlyCardOrderResult"
>
<include
refid=
"selectMonthlyCardOrderVo"
/>
where id = #{id}
</select>
<insert
id=
"insertMonthlyCardOrder"
parameterType=
"MonthlyCardOrder"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
insert into s_monthly_card_order
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"monthlyCardNo != null and monthlyCardNo != ''"
>
monthly_card_no,
</if>
<if
test=
"outTradeNo != null"
>
out_trade_no,
</if>
<if
test=
"terminalTrace != null"
>
terminal_trace,
</if>
<if
test=
"monthlyCardAmount != null"
>
monthly_card_amount,
</if>
<if
test=
"monthlyCardConfId != null"
>
monthly_card_conf_id,
</if>
<if
test=
"consumerId != null"
>
consumer_id,
</if>
<if
test=
"phone != null and phone != ''"
>
phone,
</if>
<if
test=
"payType != null"
>
pay_type,
</if>
<if
test=
"payStatus != null"
>
pay_status,
</if>
<if
test=
"payTime != null"
>
pay_time,
</if>
<if
test=
"isDelete != null"
>
is_delete,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
<if
test=
"updateBy != null"
>
update_by,
</if>
<if
test=
"updateTime != null"
>
update_time,
</if>
<if
test=
"remark != null"
>
remark,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"monthlyCardNo != null and monthlyCardNo != ''"
>
#{monthlyCardNo},
</if>
<if
test=
"outTradeNo != null"
>
#{outTradeNo},
</if>
<if
test=
"terminalTrace != null"
>
#{terminalTrace},
</if>
<if
test=
"monthlyCardAmount != null"
>
#{monthlyCardAmount},
</if>
<if
test=
"monthlyCardConfId != null"
>
#{monthlyCardConfId},
</if>
<if
test=
"consumerId != null"
>
#{consumerId},
</if>
<if
test=
"phone != null and phone != ''"
>
#{phone},
</if>
<if
test=
"payType != null"
>
#{payType},
</if>
<if
test=
"payStatus != null"
>
#{payStatus},
</if>
<if
test=
"payTime != null"
>
#{payTime},
</if>
<if
test=
"isDelete != null"
>
#{isDelete},
</if>
<if
test=
"createBy != null"
>
#{createBy},
</if>
<if
test=
"createTime != null"
>
#{createTime},
</if>
<if
test=
"updateBy != null"
>
#{updateBy},
</if>
<if
test=
"updateTime != null"
>
#{updateTime},
</if>
<if
test=
"remark != null"
>
#{remark},
</if>
</trim>
</insert>
<update
id=
"updateMonthlyCardOrder"
parameterType=
"MonthlyCardOrder"
>
update s_monthly_card_order
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"monthlyCardNo != null and monthlyCardNo != ''"
>
monthly_card_no = #{monthlyCardNo},
</if>
<if
test=
"outTradeNo != null"
>
out_trade_no = #{outTradeNo},
</if>
<if
test=
"terminalTrace != null"
>
terminal_trace = #{terminalTrace},
</if>
<if
test=
"monthlyCardAmount != null"
>
monthly_card_amount = #{monthlyCardAmount},
</if>
<if
test=
"monthlyCardConfId != null"
>
monthly_card_conf_id = #{monthlyCardConfId},
</if>
<if
test=
"consumerId != null"
>
consumer_id = #{consumerId},
</if>
<if
test=
"phone != null and phone != ''"
>
phone = #{phone},
</if>
<if
test=
"payType != null"
>
pay_type = #{payType},
</if>
<if
test=
"payStatus != null"
>
pay_status = #{payStatus},
</if>
<if
test=
"payTime != null"
>
pay_time = #{payTime},
</if>
<if
test=
"isDelete != null"
>
is_delete = #{isDelete},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime},
</if>
<if
test=
"updateBy != null"
>
update_by = #{updateBy},
</if>
<if
test=
"updateTime != null"
>
update_time = #{updateTime},
</if>
<if
test=
"remark != null"
>
remark = #{remark},
</if>
</trim>
where id = #{id}
</update>
<delete
id=
"deleteMonthlyCardOrderById"
parameterType=
"Long"
>
delete
from s_monthly_card_order
where id = #{id}
</delete>
<delete
id=
"deleteMonthlyCardOrderByIds"
parameterType=
"String"
>
delete from s_monthly_card_order where id in
<foreach
item=
"id"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{id}
</foreach>
</delete>
</mapper>
\ No newline at end of file
share-system/src/main/resources/mapper/system/SecondaryCardConfMapper.xml
View file @
4610898b
...
@@ -53,13 +53,12 @@
...
@@ -53,13 +53,12 @@
c.update_time,
c.update_time,
c.remark
c.remark
from s_secondary_card_conf c join s_pack p on c.pack_id = p.id
from s_secondary_card_conf c join s_pack p on c.pack_id = p.id
<where>
where c.is_delete = 0
<if
test=
"name != null and name != ''"
>
and c.name like concat('%', #{name}, '%')
</if>
<if
test=
"name != null and name != ''"
>
and c.name like concat('%', #{name}, '%')
</if>
<if
test=
"secondaryCardAmount != null "
>
and c.secondary_card_amount = #{secondaryCardAmount}
</if>
<if
test=
"secondaryCardAmount != null "
>
and c.secondary_card_amount = #{secondaryCardAmount}
</if>
<if
test=
"packId != null "
>
and c.pack_id = #{packId}
</if>
<if
test=
"packId != null "
>
and c.pack_id = #{packId}
</if>
<if
test=
"validityPeriod != null "
>
and c.validity_period = #{validityPeriod}
</if>
<if
test=
"validityPeriod != null "
>
and c.validity_period = #{validityPeriod}
</if>
<if
test=
"number != null "
>
and c.number = #{number}
</if>
<if
test=
"number != null "
>
and c.number = #{number}
</if>
</where>
</select>
</select>
<select
id=
"selectSecondaryCardConfById"
parameterType=
"Long"
resultMap=
"SecondaryCardConfResult"
>
<select
id=
"selectSecondaryCardConfById"
parameterType=
"Long"
resultMap=
"SecondaryCardConfResult"
>
...
...
share-system/src/main/resources/mapper/system/SecondaryCardLogMapper.xml
View file @
4610898b
...
@@ -66,7 +66,7 @@
...
@@ -66,7 +66,7 @@
from s_secondary_card_log l join s_pack p on l.pack_id = p.id join s_consumer c on l.consumer_id = c.id
from s_secondary_card_log l join s_pack p on l.pack_id = p.id join s_consumer c on l.consumer_id = c.id
join s_consumer_secondary_card s on l.consumer_secondary_card_id = s.id join s_secondary_card_conf c1 on
join s_consumer_secondary_card s on l.consumer_secondary_card_id = s.id join s_secondary_card_conf c1 on
s.secondary_card_conf_id = c1.id
s.secondary_card_conf_id = c1.id
<where>
where l.is_delete = 0
<if
test=
"consumerSecondaryCardId != null "
>
and l.consumer_secondary_card_id = #{consumerSecondaryCardId}
<if
test=
"consumerSecondaryCardId != null "
>
and l.consumer_secondary_card_id = #{consumerSecondaryCardId}
</if>
</if>
<if
test=
"consumerId != null "
>
and l.consumer_id = #{consumerId}
</if>
<if
test=
"consumerId != null "
>
and l.consumer_id = #{consumerId}
</if>
...
@@ -74,8 +74,6 @@
...
@@ -74,8 +74,6 @@
<if
test=
"packId != null "
>
and l.pack_id = #{packId}
</if>
<if
test=
"packId != null "
>
and l.pack_id = #{packId}
</if>
<if
test=
"usageCount != null "
>
and l.usage_count = #{usageCount}
</if>
<if
test=
"usageCount != null "
>
and l.usage_count = #{usageCount}
</if>
<if
test=
"residueCount != null "
>
and l.residue_count = #{residueCount}
</if>
<if
test=
"residueCount != null "
>
and l.residue_count = #{residueCount}
</if>
<if
test=
"isDelete != null "
>
and l.is_delete = #{isDelete}
</if>
</where>
</select>
</select>
<select
id=
"selectSecondaryCardLogById"
parameterType=
"Long"
resultMap=
"SecondaryCardLogResult"
>
<select
id=
"selectSecondaryCardLogById"
parameterType=
"Long"
resultMap=
"SecondaryCardLogResult"
>
...
...
share-system/src/main/resources/mapper/system/SecondaryCardOrderMapper.xml
View file @
4610898b
...
@@ -77,20 +77,18 @@
...
@@ -77,20 +77,18 @@
o. remark
o. remark
from s_secondary_card_order o join s_secondary_card_conf c on o.secondary_card_conf_id = c.id
from s_secondary_card_order o join s_secondary_card_conf c on o.secondary_card_conf_id = c.id
join s_consumer c1 on o.consumer_id = c1.id join s_pack p on p.id = c.pack_id
join s_consumer c1 on o.consumer_id = c1.id join s_pack p on p.id = c.pack_id
<where>
where o.is_delete = 0
<if
test=
"secondaryCardNo != null and secondaryCardNo != ''"
>
and
secondary_card_no = #{secondaryCardNo}
<if
test=
"secondaryCardNo != null and secondaryCardNo != ''"
>
and o.
secondary_card_no = #{secondaryCardNo}
</if>
</if>
<if
test=
"outTradeNo != null and outTradeNo != ''"
>
and out_trade_no = #{outTradeNo}
</if>
<if
test=
"outTradeNo != null and outTradeNo != ''"
>
and o.out_trade_no = #{outTradeNo}
</if>
<if
test=
"terminalTrace != null and terminalTrace != ''"
>
and terminal_trace = #{terminalTrace}
</if>
<if
test=
"terminalTrace != null and terminalTrace != ''"
>
and o.terminal_trace = #{terminalTrace}
</if>
<if
test=
"secondaryCardAmount != null "
>
and secondary_card_amount = #{secondaryCardAmount}
</if>
<if
test=
"secondaryCardAmount != null "
>
and o.secondary_card_amount = #{secondaryCardAmount}
</if>
<if
test=
"secondaryCardConfId != null "
>
and secondary_card_conf_id = #{secondaryCardConfId}
</if>
<if
test=
"secondaryCardConfId != null "
>
and o.secondary_card_conf_id = #{secondaryCardConfId}
</if>
<if
test=
"consumerId != null "
>
and consumer_id = #{consumerId}
</if>
<if
test=
"consumerId != null "
>
and o.consumer_id = #{consumerId}
</if>
<if
test=
"phone != null and phone != ''"
>
and phone = #{phone}
</if>
<if
test=
"phone != null and phone != ''"
>
and o.phone = #{phone}
</if>
<if
test=
"payType != null "
>
and pay_type = #{payType}
</if>
<if
test=
"payType != null "
>
and o.pay_type = #{payType}
</if>
<if
test=
"payStatus != null "
>
and pay_status = #{payStatus}
</if>
<if
test=
"payStatus != null "
>
and o.pay_status = #{payStatus}
</if>
<if
test=
"payTime != null "
>
and pay_time = #{payTime}
</if>
<if
test=
"payTime != null "
>
and o.pay_time = #{payTime}
</if>
<if
test=
"isDelete != null "
>
and is_delete = #{isDelete}
</if>
</where>
</select>
</select>
<select
id=
"selectSecondaryCardOrderById"
parameterType=
"Long"
resultMap=
"SecondaryCardOrderResult"
>
<select
id=
"selectSecondaryCardOrderById"
parameterType=
"Long"
resultMap=
"SecondaryCardOrderResult"
>
...
...
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