记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
Project
Project
Details
Activity
Releases
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
董敬伟
liquidnet-bus-v1
Commits
247314a9
Commit
247314a9
authored
May 28, 2021
by
胡佳晨
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
admin 暂时提交
parent
3d0e62cc
Changes
19
Show whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
1556 additions
and
1950 deletions
+1556
-1950
RuoYiApplication.java
...ain/java/com/liquidnet/client/admin/RuoYiApplication.java
+3
-1
KylinOrderTicketsController.java
...ontroller/zhengzai/kylin/KylinOrderTicketsController.java
+84
-87
KylinPerformancesController.java
...ontroller/zhengzai/kylin/KylinPerformancesController.java
+84
-84
PerformanceCalendarController.java
...troller/zhengzai/kylin/PerformanceCalendarController.java
+22
-30
pom.xml
...dnet-client-admin/liquidnet-client-admin-zhengzai/pom.xml
+20
-1
KylinOrderTickets.java
...client/admin/zhengzai/kylin/domain/KylinOrderTickets.java
+0
-477
KylinPerformances.java
...client/admin/zhengzai/kylin/domain/KylinPerformances.java
+0
-436
KylinOrderTicketsMapper.java
.../admin/zhengzai/kylin/mapper/KylinOrderTicketsMapper.java
+0
-62
KylinPerformancesMapper.java
.../admin/zhengzai/kylin/mapper/KylinPerformancesMapper.java
+0
-61
IKylinOrderTicketsService.java
...min/zhengzai/kylin/service/IKylinOrderTicketsService.java
+0
-62
IKylinPerformancesService.java
...min/zhengzai/kylin/service/IKylinPerformancesService.java
+0
-61
KylinOrderTicketsServiceImpl.java
...gzai/kylin/service/impl/KylinOrderTicketsServiceImpl.java
+0
-95
KylinPerformancesAdminServiceImpl.java
...kylin/service/impl/KylinPerformancesAdminServiceImpl.java
+579
-0
KylinPerformancesServiceImpl.java
...gzai/kylin/service/impl/KylinPerformancesServiceImpl.java
+0
-94
KylinRoadShowsAdminServiceImpl.java
...ai/kylin/service/impl/KylinRoadShowsAdminServiceImpl.java
+128
-0
DataUtils.java
...iquidnet/client/admin/zhengzai/kylin/utils/DataUtils.java
+134
-0
PerformanceVoUtils.java
...client/admin/zhengzai/kylin/utils/PerformanceVoUtils.java
+502
-0
KylinOrderTicketsMapper.xml
...sources/mapper/zhengzai/kylin/KylinOrderTicketsMapper.xml
+0
-207
KylinPerformancesMapper.xml
...sources/mapper/zhengzai/kylin/KylinPerformancesMapper.xml
+0
-192
No files found.
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/RuoYiApplication.java
View file @
247314a9
package
com
.
liquidnet
.
client
.
admin
;
import
org.mybatis.spring.annotation.MapperScan
;
import
org.springframework.boot.SpringApplication
;
import
org.springframework.boot.autoconfigure.SpringBootApplication
;
import
org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration
;
...
...
@@ -9,7 +10,8 @@ import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
*
* @author ruoyi
*/
@SpringBootApplication
(
exclude
=
{
DataSourceAutoConfiguration
.
class
})
@SpringBootApplication
(
exclude
=
{
DataSourceAutoConfiguration
.
class
},
scanBasePackages
=
{
"com.liquidnet"
})
@MapperScan
(
basePackages
=
{
"com.liquidnet.service.kylin.mapper"
})
//,"com.liquidnet.service.adam.mapper"
public
class
RuoYiApplication
{
public
static
void
main
(
String
[]
args
)
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/kylin/KylinOrderTicketsController.java
View file @
247314a9
...
...
@@ -5,9 +5,6 @@ import com.liquidnet.client.admin.common.core.controller.BaseController;
import
com.liquidnet.client.admin.common.core.domain.AjaxResult
;
import
com.liquidnet.client.admin.common.core.page.TableDataInfo
;
import
com.liquidnet.client.admin.common.enums.BusinessType
;
import
com.liquidnet.client.admin.common.utils.poi.ExcelUtil
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinOrderTickets
;
import
com.liquidnet.client.admin.zhengzai.kylin.service.IKylinOrderTicketsService
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
...
...
@@ -28,8 +25,8 @@ public class KylinOrderTicketsController extends BaseController
{
private
String
prefix
=
"zhengzai/kylin/tickets"
;
@Autowired
private
IKylinOrderTicketsService
kylinOrderTicketsService
;
//
@Autowired
//
private IKylinOrderTicketsService kylinOrderTicketsService;
@RequiresPermissions
(
"kylin:tickets:view"
)
@GetMapping
()
...
...
@@ -38,86 +35,86 @@ public class KylinOrderTicketsController extends BaseController
return
prefix
+
"/tickets"
;
}
/**
* 查询订单列表
*/
@RequiresPermissions
(
"kylin:tickets:list"
)
@PostMapping
(
"/list"
)
@ResponseBody
public
TableDataInfo
list
(
KylinOrderTickets
kylinOrderTickets
)
{
startPage
();
List
<
KylinOrderTickets
>
list
=
kylinOrderTicketsService
.
selectKylinOrderTicketsList
(
kylinOrderTickets
);
return
getDataTable
(
list
);
}
/**
* 导出订单列表
*/
@RequiresPermissions
(
"kylin:tickets:export"
)
@Log
(
title
=
"订单"
,
businessType
=
BusinessType
.
EXPORT
)
@PostMapping
(
"/export"
)
@ResponseBody
public
AjaxResult
export
(
KylinOrderTickets
kylinOrderTickets
)
{
List
<
KylinOrderTickets
>
list
=
kylinOrderTicketsService
.
selectKylinOrderTicketsList
(
kylinOrderTickets
);
ExcelUtil
<
KylinOrderTickets
>
util
=
new
ExcelUtil
<
KylinOrderTickets
>(
KylinOrderTickets
.
class
);
return
util
.
exportExcel
(
list
,
"订单数据"
);
}
/**
* 新增订单
*/
@GetMapping
(
"/add"
)
public
String
add
()
{
return
prefix
+
"/add"
;
}
/**
* 新增保存订单
*/
@RequiresPermissions
(
"kylin:tickets:add"
)
@Log
(
title
=
"订单"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
(
"/add"
)
@ResponseBody
public
AjaxResult
addSave
(
KylinOrderTickets
kylinOrderTickets
)
{
return
toAjax
(
kylinOrderTicketsService
.
insertKylinOrderTickets
(
kylinOrderTickets
));
}
/**
* 修改订单
*/
@GetMapping
(
"/edit/{mid}"
)
public
String
edit
(
@PathVariable
(
"mid"
)
Integer
mid
,
ModelMap
mmap
)
{
KylinOrderTickets
kylinOrderTickets
=
kylinOrderTicketsService
.
selectKylinOrderTicketsById
(
mid
);
mmap
.
put
(
"kylinOrderTickets"
,
kylinOrderTickets
);
return
prefix
+
"/edit"
;
}
/**
* 修改保存订单
*/
@RequiresPermissions
(
"kylin:tickets:edit"
)
@Log
(
title
=
"订单"
,
businessType
=
BusinessType
.
UPDATE
)
@PostMapping
(
"/edit"
)
@ResponseBody
public
AjaxResult
editSave
(
KylinOrderTickets
kylinOrderTickets
)
{
return
toAjax
(
kylinOrderTicketsService
.
updateKylinOrderTickets
(
kylinOrderTickets
));
}
/**
* 删除订单
*/
@RequiresPermissions
(
"kylin:tickets:remove"
)
@Log
(
title
=
"订单"
,
businessType
=
BusinessType
.
DELETE
)
@PostMapping
(
"/remove"
)
@ResponseBody
public
AjaxResult
remove
(
String
ids
)
{
return
toAjax
(
kylinOrderTicketsService
.
deleteKylinOrderTicketsByIds
(
ids
));
}
//
/**
//
* 查询订单列表
//
*/
//
@RequiresPermissions("kylin:tickets:list")
//
@PostMapping("/list")
//
@ResponseBody
//
public TableDataInfo list(KylinOrderTickets kylinOrderTickets)
//
{
//
startPage();
//
List<KylinOrderTickets> list = kylinOrderTicketsService.selectKylinOrderTicketsList(kylinOrderTickets);
//
return getDataTable(list);
//
}
//
//
/**
//
* 导出订单列表
//
*/
//
@RequiresPermissions("kylin:tickets:export")
//
@Log(title = "订单", businessType = BusinessType.EXPORT)
//
@PostMapping("/export")
//
@ResponseBody
//
public AjaxResult export(KylinOrderTickets kylinOrderTickets)
//
{
//
List<KylinOrderTickets> list = kylinOrderTicketsService.selectKylinOrderTicketsList(kylinOrderTickets);
//
ExcelUtil<KylinOrderTickets> util = new ExcelUtil<KylinOrderTickets>(KylinOrderTickets.class);
//
return util.exportExcel(list, "订单数据");
//
}
//
//
/**
//
* 新增订单
//
*/
//
@GetMapping("/add")
//
public String add()
//
{
//
return prefix + "/add";
//
}
//
//
/**
//
* 新增保存订单
//
*/
//
@RequiresPermissions("kylin:tickets:add")
//
@Log(title = "订单", businessType = BusinessType.INSERT)
//
@PostMapping("/add")
//
@ResponseBody
//
public AjaxResult addSave(KylinOrderTickets kylinOrderTickets)
//
{
//
return toAjax(kylinOrderTicketsService.insertKylinOrderTickets(kylinOrderTickets));
//
}
//
//
/**
//
* 修改订单
//
*/
//
@GetMapping("/edit/{mid}")
//
public String edit(@PathVariable("mid") Integer mid, ModelMap mmap)
//
{
//
KylinOrderTickets kylinOrderTickets = kylinOrderTicketsService.selectKylinOrderTicketsById(mid);
//
mmap.put("kylinOrderTickets", kylinOrderTickets);
//
return prefix + "/edit";
//
}
//
//
/**
//
* 修改保存订单
//
*/
//
@RequiresPermissions("kylin:tickets:edit")
//
@Log(title = "订单", businessType = BusinessType.UPDATE)
//
@PostMapping("/edit")
//
@ResponseBody
//
public AjaxResult editSave(KylinOrderTickets kylinOrderTickets)
//
{
//
return toAjax(kylinOrderTicketsService.updateKylinOrderTickets(kylinOrderTickets));
//
}
//
//
/**
//
* 删除订单
//
*/
//
@RequiresPermissions("kylin:tickets:remove")
//
@Log(title = "订单", businessType = BusinessType.DELETE)
//
@PostMapping( "/remove")
//
@ResponseBody
//
public AjaxResult remove(String ids)
//
{
//
return toAjax(kylinOrderTicketsService.deleteKylinOrderTicketsByIds(ids));
//
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/kylin/KylinPerformancesController.java
View file @
247314a9
package
com
.
liquidnet
.
client
.
admin
.
web
.
controller
.
zhengzai
.
kylin
;
import
com.
liquidnet.client.admin.common.annotation.Log
;
import
com.
github.pagehelper.PageInfo
;
import
com.liquidnet.client.admin.common.core.controller.BaseController
;
import
com.liquidnet.client.admin.common.core.domain.AjaxResult
;
import
com.liquidnet.client.admin.common.core.page.TableDataInfo
;
import
com.liquidnet.client.admin.common.enums.BusinessType
;
import
com.liquidnet.client.admin.common.utils.poi.ExcelUtil
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinPerformances
;
import
com.liquidnet.client.admin.zhengzai.kylin.service.IKylinPerformancesService
;
import
com.liquidnet.service.base.ResponseDto
;
import
com.liquidnet.service.kylin.dao.PerformanceAdminListDao
;
import
com.liquidnet.service.kylin.dto.param.PerformanceAdminListParam
;
import
com.liquidnet.service.kylin.service.admin.IKylinPerformancesAdminService
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.ui.ModelMap
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.List
;
/**
* 演出Controller
...
...
@@ -29,7 +25,7 @@ public class KylinPerformancesController extends BaseController
private
String
prefix
=
"zhengzai/kylin/performances"
;
@Autowired
private
IKylinPerformancesService
kylinPerformancesService
;
private
IKylinPerformances
Admin
Service
kylinPerformancesService
;
@RequiresPermissions
(
"kylin:performances:view"
)
@GetMapping
()
...
...
@@ -44,80 +40,84 @@ public class KylinPerformancesController extends BaseController
@RequiresPermissions
(
"kylin:performances:list"
)
@PostMapping
(
"/list"
)
@ResponseBody
public
TableDataInfo
list
(
KylinPerformances
kylinPerformances
)
public
ResponseDto
<
PageInfo
<
PerformanceAdminListDao
>>
list
(
PerformanceAdminListParam
performanceAdminListParam
)
{
startPage
();
List
<
KylinPerformances
>
list
=
kylinPerformancesService
.
selectKylinPerformancesList
(
kylinPerformances
);
return
getDataTable
(
list
);
PageInfo
<
PerformanceAdminListDao
>
result
=
null
;
result
=
kylinPerformancesService
.
getList
(
performanceAdminListParam
);
if
(
null
!=
result
)
{
return
ResponseDto
.
success
(
result
);
}
else
{
return
ResponseDto
.
failure
(
"获取演出详情失败"
);
}
/**
* 导出演出列表
*/
@RequiresPermissions
(
"kylin:performances:export"
)
@Log
(
title
=
"演出"
,
businessType
=
BusinessType
.
EXPORT
)
@PostMapping
(
"/export"
)
@ResponseBody
public
AjaxResult
export
(
KylinPerformances
kylinPerformances
)
{
List
<
KylinPerformances
>
list
=
kylinPerformancesService
.
selectKylinPerformancesList
(
kylinPerformances
);
ExcelUtil
<
KylinPerformances
>
util
=
new
ExcelUtil
<
KylinPerformances
>(
KylinPerformances
.
class
);
return
util
.
exportExcel
(
list
,
"演出数据"
);
}
/**
* 新增演出
*/
@GetMapping
(
"/add"
)
public
String
add
()
{
return
prefix
+
"/add"
;
}
/**
* 新增保存演出
*/
@RequiresPermissions
(
"kylin:performances:add"
)
@Log
(
title
=
"演出"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
(
"/add"
)
@ResponseBody
public
AjaxResult
addSave
(
KylinPerformances
kylinPerformances
)
{
return
toAjax
(
kylinPerformancesService
.
insertKylinPerformances
(
kylinPerformances
));
}
/**
* 修改演出
*/
@GetMapping
(
"/edit/{mid}"
)
public
String
edit
(
@PathVariable
(
"mid"
)
Long
mid
,
ModelMap
mmap
)
{
KylinPerformances
kylinPerformances
=
kylinPerformancesService
.
selectKylinPerformancesById
(
mid
);
mmap
.
put
(
"kylinPerformances"
,
kylinPerformances
);
return
prefix
+
"/edit"
;
}
/**
* 修改保存演出
*/
@RequiresPermissions
(
"kylin:performances:edit"
)
@Log
(
title
=
"演出"
,
businessType
=
BusinessType
.
UPDATE
)
@PostMapping
(
"/edit"
)
@ResponseBody
public
AjaxResult
editSave
(
KylinPerformances
kylinPerformances
)
{
return
toAjax
(
kylinPerformancesService
.
updateKylinPerformances
(
kylinPerformances
));
}
/**
* 删除演出
*/
@RequiresPermissions
(
"kylin:performances:remove"
)
@Log
(
title
=
"演出"
,
businessType
=
BusinessType
.
DELETE
)
@PostMapping
(
"/remove"
)
@ResponseBody
public
AjaxResult
remove
(
String
ids
)
{
return
toAjax
(
kylinPerformancesService
.
deleteKylinPerformancesByIds
(
ids
));
}
//
// /**
// * 导出演出列表
// */
// @RequiresPermissions("kylin:performances:export")
// @Log(title = "演出", businessType = BusinessType.EXPORT)
// @PostMapping("/export")
// @ResponseBody
// public AjaxResult export(KylinPerformances kylinPerformances)
// {
// List<KylinPerformances> list = kylinPerformancesService.selectKylinPerformancesList(kylinPerformances);
// ExcelUtil<KylinPerformances> util = new ExcelUtil<KylinPerformances>(KylinPerformances.class);
// return util.exportExcel(list, "演出数据");
// }
//
// /**
// * 新增演出
// */
// @GetMapping("/add")
// public String add()
// {
// return prefix + "/add";
// }
//
// /**
// * 新增保存演出
// */
// @RequiresPermissions("kylin:performances:add")
// @Log(title = "演出", businessType = BusinessType.INSERT)
// @PostMapping("/add")
// @ResponseBody
// public AjaxResult addSave(KylinPerformances kylinPerformances)
// {
// return toAjax(kylinPerformancesService.insertKylinPerformances(kylinPerformances));
// }
//
// /**
// * 修改演出
// */
// @GetMapping("/edit/{mid}")
// public String edit(@PathVariable("mid") Long mid, ModelMap mmap)
// {
// KylinPerformances kylinPerformances = kylinPerformancesService.selectKylinPerformancesById(mid);
// mmap.put("kylinPerformances", kylinPerformances);
// return prefix + "/edit";
// }
//
// /**
// * 修改保存演出
// */
// @RequiresPermissions("kylin:performances:edit")
// @Log(title = "演出", businessType = BusinessType.UPDATE)
// @PostMapping("/edit")
// @ResponseBody
// public AjaxResult editSave(KylinPerformances kylinPerformances)
// {
// return toAjax(kylinPerformancesService.updateKylinPerformances(kylinPerformances));
// }
//
// /**
// * 删除演出
// */
// @RequiresPermissions("kylin:performances:remove")
// @Log(title = "演出", businessType = BusinessType.DELETE)
// @PostMapping( "/remove")
// @ResponseBody
// public AjaxResult remove(String ids)
// {
// return toAjax(kylinPerformancesService.deleteKylinPerformancesByIds(ids));
// }
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-web/src/main/java/com/liquidnet/client/admin/web/controller/zhengzai/kylin/PerformanceCalendarController.java
View file @
247314a9
package
com
.
liquidnet
.
client
.
admin
.
web
.
controller
.
zhengzai
.
kylin
;
import
com.liquidnet.client.admin.common.core.controller.BaseController
;
import
com.liquidnet.client.admin.common.core.page.TableDataInfo
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinPerformances
;
import
com.liquidnet.client.admin.zhengzai.kylin.service.IKylinPerformancesService
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
java.util.List
;
...
...
@@ -28,26 +20,26 @@ import java.util.List;
public
class
PerformanceCalendarController
extends
BaseController
{
private
String
prefix
=
"zhengzai/kylin/performanceCalendar"
;
@Autowired
private
IKylinPerformancesService
kylinPerformancesService
;
@RequiresPermissions
(
"kylin:performanceCalendar:view"
)
@GetMapping
()
public
String
performances
()
{
return
prefix
+
"/performanceCalendar"
;
}
/**
* 查询演出列表
*/
@RequiresPermissions
(
"kylin:performanceCalendar:list"
)
@PostMapping
(
"/list"
)
@ResponseBody
public
TableDataInfo
list
(
KylinPerformances
kylinPerformances
)
{
startPage
();
List
<
KylinPerformances
>
list
=
kylinPerformancesService
.
selectKylinPerformancesList
(
kylinPerformances
);
return
getDataTable
(
list
);
}
//
@Autowired
//
private IKylinPerformancesService kylinPerformancesService;
//
//
@RequiresPermissions("kylin:performanceCalendar:view")
//
@GetMapping()
//
public String performances()
//
{
//
return prefix + "/performanceCalendar";
//
}
//
//
/**
//
* 查询演出列表
//
*/
//
@RequiresPermissions("kylin:performanceCalendar:list")
//
@PostMapping("/list")
//
@ResponseBody
//
public TableDataInfo list(KylinPerformances kylinPerformances)
//
{
//
startPage();
//
List<KylinPerformances> list = kylinPerformancesService.selectKylinPerformancesList(kylinPerformances);
//
return getDataTable(list);
//
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/pom.xml
View file @
247314a9
...
...
@@ -28,11 +28,30 @@
<artifactId>
liquidnet-service-kylin-api
</artifactId>
<version>
1.0-SNAPSHOT
</version>
</dependency>
<!-- <dependency>-->
<!-- <groupId>com.liquidnet</groupId>-->
<!-- <artifactId>liquidnet-service-adam-api</artifactId>-->
<!-- <version>1.0-SNAPSHOT</version>-->
<!-- </dependency>-->
<dependency>
<groupId>
com.liquidnet
</groupId>
<artifactId>
liquidnet-common-cache-redis
</artifactId>
<version>
1.0-SNAPSHOT
</version>
</dependency>
<dependency>
<groupId>
com.liquidnet
</groupId>
<artifactId>
liquidnet-
service-adam-api
</artifactId>
<artifactId>
liquidnet-
common-mq
</artifactId>
<version>
1.0-SNAPSHOT
</version>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-data-mongodb
</artifactId>
</dependency>
<dependency>
<groupId>
org.projectlombok
</groupId>
<artifactId>
lombok
</artifactId>
</dependency>
</dependencies>
...
...
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/domain/KylinOrderTickets.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
domain
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.liquidnet.client.admin.common.annotation.Excel
;
import
com.liquidnet.client.admin.common.core.domain.BaseEntity
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
java.math.BigDecimal
;
import
java.util.Date
;
/**
* 订单对象 kylin_order_tickets
*
* @author ruoyi
* @date 2021-05-24
*/
public
class
KylinOrderTickets
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/** $column.columnComment */
private
Integer
mid
;
/** order_tickets_id */
@Excel
(
name
=
"order_tickets_id"
)
private
String
orderTicketsId
;
/** 用户id */
@Excel
(
name
=
"用户id"
)
private
String
userId
;
/** 用户昵称 */
@Excel
(
name
=
"用户昵称"
)
private
String
userName
;
/** 用户手机号 */
@Excel
(
name
=
"用户手机号"
)
private
String
userMobile
;
/** 演出名称 */
@Excel
(
name
=
"演出名称"
)
private
String
performanceTitle
;
/** 订单号 */
@Excel
(
name
=
"订单号"
)
private
String
orderCode
;
/** 二维码地址 */
@Excel
(
name
=
"二维码地址"
)
private
String
qrCode
;
/** 下单方式 */
@Excel
(
name
=
"下单方式"
)
private
String
orderType
;
/** 下单版本 */
@Excel
(
name
=
"下单版本"
)
private
String
orderVersion
;
/** 数量 */
@Excel
(
name
=
"数量"
)
private
String
number
;
/** 单价 */
@Excel
(
name
=
"单价"
)
private
BigDecimal
price
;
/** 会员单价 */
@Excel
(
name
=
"会员单价"
)
private
BigDecimal
priceMember
;
/** 应付价格 */
@Excel
(
name
=
"应付价格"
)
private
BigDecimal
priceTotal
;
/** 优惠价格 */
@Excel
(
name
=
"优惠价格"
)
private
BigDecimal
priceVoucher
;
/** 实付价格 */
@Excel
(
name
=
"实付价格"
)
private
BigDecimal
priceActual
;
/** 快递价格 */
@Excel
(
name
=
"快递价格"
)
private
BigDecimal
priceExpress
;
/** 退款价格 */
@Excel
(
name
=
"退款价格"
)
private
BigDecimal
priceRefund
;
/** 退款张数 */
@Excel
(
name
=
"退款张数"
)
private
BigDecimal
priceNumber
;
/** 选择支付方式 */
@Excel
(
name
=
"选择支付方式"
)
private
String
payType
;
/** 实际支付方式 */
@Excel
(
name
=
"实际支付方式"
)
private
String
paymentType
;
/** 支付时间 */
@Excel
(
name
=
"支付时间"
)
private
String
timePay
;
/** 收货人 */
@Excel
(
name
=
"收货人"
)
private
String
expressContacts
;
/** 收货地址 */
@Excel
(
name
=
"收货地址"
)
private
String
expressAddress
;
/** 收货人联系方式 */
@Excel
(
name
=
"收货人联系方式"
)
private
String
expressPhone
;
/** 券使用类别 */
@Excel
(
name
=
"券使用类别"
)
private
String
couponType
;
/** 取票方式 电子票electronic快递票express */
@Excel
(
name
=
"取票方式 电子票electronic快递票express"
)
private
String
getTicketType
;
/** 直播用取票观演码,隔开 */
@Excel
(
name
=
"直播用取票观演码,隔开"
)
private
String
getTicketDescribe
;
/** 订单过期时间 */
@Excel
(
name
=
"订单过期时间"
)
private
String
payCountdownMinute
;
/** comment */
@Excel
(
name
=
"comment"
)
private
String
comment
;
/** 创建时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"创建时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
createdAt
;
/** 修改时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"修改时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
updatedAt
;
public
void
setMid
(
Integer
mid
)
{
this
.
mid
=
mid
;
}
public
Integer
getMid
()
{
return
mid
;
}
public
void
setOrderTicketsId
(
String
orderTicketsId
)
{
this
.
orderTicketsId
=
orderTicketsId
;
}
public
String
getOrderTicketsId
()
{
return
orderTicketsId
;
}
public
void
setUserId
(
String
userId
)
{
this
.
userId
=
userId
;
}
public
String
getUserId
()
{
return
userId
;
}
public
void
setUserName
(
String
userName
)
{
this
.
userName
=
userName
;
}
public
String
getUserName
()
{
return
userName
;
}
public
void
setUserMobile
(
String
userMobile
)
{
this
.
userMobile
=
userMobile
;
}
public
String
getUserMobile
()
{
return
userMobile
;
}
public
void
setPerformanceTitle
(
String
performanceTitle
)
{
this
.
performanceTitle
=
performanceTitle
;
}
public
String
getPerformanceTitle
()
{
return
performanceTitle
;
}
public
void
setOrderCode
(
String
orderCode
)
{
this
.
orderCode
=
orderCode
;
}
public
String
getOrderCode
()
{
return
orderCode
;
}
public
void
setQrCode
(
String
qrCode
)
{
this
.
qrCode
=
qrCode
;
}
public
String
getQrCode
()
{
return
qrCode
;
}
public
void
setOrderType
(
String
orderType
)
{
this
.
orderType
=
orderType
;
}
public
String
getOrderType
()
{
return
orderType
;
}
public
void
setOrderVersion
(
String
orderVersion
)
{
this
.
orderVersion
=
orderVersion
;
}
public
String
getOrderVersion
()
{
return
orderVersion
;
}
public
void
setNumber
(
String
number
)
{
this
.
number
=
number
;
}
public
String
getNumber
()
{
return
number
;
}
public
void
setPrice
(
BigDecimal
price
)
{
this
.
price
=
price
;
}
public
BigDecimal
getPrice
()
{
return
price
;
}
public
void
setPriceMember
(
BigDecimal
priceMember
)
{
this
.
priceMember
=
priceMember
;
}
public
BigDecimal
getPriceMember
()
{
return
priceMember
;
}
public
void
setPriceTotal
(
BigDecimal
priceTotal
)
{
this
.
priceTotal
=
priceTotal
;
}
public
BigDecimal
getPriceTotal
()
{
return
priceTotal
;
}
public
void
setPriceVoucher
(
BigDecimal
priceVoucher
)
{
this
.
priceVoucher
=
priceVoucher
;
}
public
BigDecimal
getPriceVoucher
()
{
return
priceVoucher
;
}
public
void
setPriceActual
(
BigDecimal
priceActual
)
{
this
.
priceActual
=
priceActual
;
}
public
BigDecimal
getPriceActual
()
{
return
priceActual
;
}
public
void
setPriceExpress
(
BigDecimal
priceExpress
)
{
this
.
priceExpress
=
priceExpress
;
}
public
BigDecimal
getPriceExpress
()
{
return
priceExpress
;
}
public
void
setPriceRefund
(
BigDecimal
priceRefund
)
{
this
.
priceRefund
=
priceRefund
;
}
public
BigDecimal
getPriceRefund
()
{
return
priceRefund
;
}
public
void
setPriceNumber
(
BigDecimal
priceNumber
)
{
this
.
priceNumber
=
priceNumber
;
}
public
BigDecimal
getPriceNumber
()
{
return
priceNumber
;
}
public
void
setPayType
(
String
payType
)
{
this
.
payType
=
payType
;
}
public
String
getPayType
()
{
return
payType
;
}
public
void
setPaymentType
(
String
paymentType
)
{
this
.
paymentType
=
paymentType
;
}
public
String
getPaymentType
()
{
return
paymentType
;
}
public
void
setTimePay
(
String
timePay
)
{
this
.
timePay
=
timePay
;
}
public
String
getTimePay
()
{
return
timePay
;
}
public
void
setExpressContacts
(
String
expressContacts
)
{
this
.
expressContacts
=
expressContacts
;
}
public
String
getExpressContacts
()
{
return
expressContacts
;
}
public
void
setExpressAddress
(
String
expressAddress
)
{
this
.
expressAddress
=
expressAddress
;
}
public
String
getExpressAddress
()
{
return
expressAddress
;
}
public
void
setExpressPhone
(
String
expressPhone
)
{
this
.
expressPhone
=
expressPhone
;
}
public
String
getExpressPhone
()
{
return
expressPhone
;
}
public
void
setCouponType
(
String
couponType
)
{
this
.
couponType
=
couponType
;
}
public
String
getCouponType
()
{
return
couponType
;
}
public
void
setGetTicketType
(
String
getTicketType
)
{
this
.
getTicketType
=
getTicketType
;
}
public
String
getGetTicketType
()
{
return
getTicketType
;
}
public
void
setGetTicketDescribe
(
String
getTicketDescribe
)
{
this
.
getTicketDescribe
=
getTicketDescribe
;
}
public
String
getGetTicketDescribe
()
{
return
getTicketDescribe
;
}
public
void
setPayCountdownMinute
(
String
payCountdownMinute
)
{
this
.
payCountdownMinute
=
payCountdownMinute
;
}
public
String
getPayCountdownMinute
()
{
return
payCountdownMinute
;
}
public
void
setComment
(
String
comment
)
{
this
.
comment
=
comment
;
}
public
String
getComment
()
{
return
comment
;
}
public
void
setCreatedAt
(
Date
createdAt
)
{
this
.
createdAt
=
createdAt
;
}
public
Date
getCreatedAt
()
{
return
createdAt
;
}
public
void
setUpdatedAt
(
Date
updatedAt
)
{
this
.
updatedAt
=
updatedAt
;
}
public
Date
getUpdatedAt
()
{
return
updatedAt
;
}
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"mid"
,
getMid
())
.
append
(
"orderTicketsId"
,
getOrderTicketsId
())
.
append
(
"userId"
,
getUserId
())
.
append
(
"userName"
,
getUserName
())
.
append
(
"userMobile"
,
getUserMobile
())
.
append
(
"performanceTitle"
,
getPerformanceTitle
())
.
append
(
"orderCode"
,
getOrderCode
())
.
append
(
"qrCode"
,
getQrCode
())
.
append
(
"orderType"
,
getOrderType
())
.
append
(
"orderVersion"
,
getOrderVersion
())
.
append
(
"number"
,
getNumber
())
.
append
(
"price"
,
getPrice
())
.
append
(
"priceMember"
,
getPriceMember
())
.
append
(
"priceTotal"
,
getPriceTotal
())
.
append
(
"priceVoucher"
,
getPriceVoucher
())
.
append
(
"priceActual"
,
getPriceActual
())
.
append
(
"priceExpress"
,
getPriceExpress
())
.
append
(
"priceRefund"
,
getPriceRefund
())
.
append
(
"priceNumber"
,
getPriceNumber
())
.
append
(
"payType"
,
getPayType
())
.
append
(
"paymentType"
,
getPaymentType
())
.
append
(
"timePay"
,
getTimePay
())
.
append
(
"expressContacts"
,
getExpressContacts
())
.
append
(
"expressAddress"
,
getExpressAddress
())
.
append
(
"expressPhone"
,
getExpressPhone
())
.
append
(
"couponType"
,
getCouponType
())
.
append
(
"getTicketType"
,
getGetTicketType
())
.
append
(
"getTicketDescribe"
,
getGetTicketDescribe
())
.
append
(
"payCountdownMinute"
,
getPayCountdownMinute
())
.
append
(
"comment"
,
getComment
())
.
append
(
"createdAt"
,
getCreatedAt
())
.
append
(
"updatedAt"
,
getUpdatedAt
())
.
toString
();
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/domain/KylinPerformances.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
domain
;
import
java.util.Date
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
org.apache.commons.lang3.builder.ToStringBuilder
;
import
org.apache.commons.lang3.builder.ToStringStyle
;
import
com.liquidnet.client.admin.common.annotation.Excel
;
import
com.liquidnet.client.admin.common.core.domain.BaseEntity
;
/**
* 演出对象 kylin_performances
*
* @author ruoyi
* @date 2021-05-24
*/
public
class
KylinPerformances
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/** $column.columnComment */
private
Long
mid
;
/** performances_id */
@Excel
(
name
=
"performances_id"
)
private
String
performancesId
;
/** 演出名称 */
@Excel
(
name
=
"演出名称"
)
private
String
title
;
/** 1音乐节 2演唱会 3小型演出 4展览 6舞台剧 101音乐节 102小型演出(livehouse演出) 103巡演 */
@Excel
(
name
=
"1音乐节 2演唱会 3小型演出 4展览 6舞台剧 101音乐节 102小型演出(livehouse演出) 103巡演"
)
private
Integer
type
;
/** 演出海报 */
@Excel
(
name
=
"演出海报"
)
private
String
imgPoster
;
/** 省id */
@Excel
(
name
=
"省id"
)
private
String
provinceId
;
/** 省名称 */
@Excel
(
name
=
"省名称"
)
private
String
provinceName
;
/** 城市id */
@Excel
(
name
=
"城市id"
)
private
Long
cityId
;
/** 城市名称 */
@Excel
(
name
=
"城市名称"
)
private
String
cityName
;
/** 县id */
@Excel
(
name
=
"县id"
)
private
Long
districtId
;
/** 县名称 */
@Excel
(
name
=
"县名称"
)
private
String
districtName
;
/** 批文地址 */
@Excel
(
name
=
"批文地址"
)
private
String
approvalUrl
;
/** 演出公告 */
@Excel
(
name
=
"演出公告"
)
private
String
notice
;
/** 主办方id */
@Excel
(
name
=
"主办方id"
)
private
String
sponsorId
;
/** 主办方类型 */
@Excel
(
name
=
"主办方类型"
)
private
String
sponsorType
;
/** 主办方 */
@Excel
(
name
=
"主办方"
)
private
String
sponsor
;
/** 联系人 */
@Excel
(
name
=
"联系人"
)
private
String
contacts
;
/** 联系电话 */
@Excel
(
name
=
"联系电话"
)
private
String
mobile
;
/** 演出简介 */
@Excel
(
name
=
"演出简介"
)
private
String
describes
;
/** 演出详情 */
@Excel
(
name
=
"演出详情"
)
private
String
details
;
/** 购票须知 */
@Excel
(
name
=
"购票须知"
)
private
String
noticeImage
;
/** 演出开始时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"演出开始时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
timeStart
;
/** 演出结束时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"演出结束时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
timeEnd
;
/** 提审时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"提审时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
auditTime
;
/** 拒绝理由 */
@Excel
(
name
=
"拒绝理由"
)
private
String
rejectTxt
;
/** 权重 高则在上 */
@Excel
(
name
=
"权重 高则在上"
)
private
Long
sort
;
/** comment */
@Excel
(
name
=
"comment"
)
private
String
comment
;
/** 创建时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"创建时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
createdAt
;
/** 修改时间 */
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@Excel
(
name
=
"修改时间"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
updatedAt
;
public
void
setMid
(
Long
mid
)
{
this
.
mid
=
mid
;
}
public
Long
getMid
()
{
return
mid
;
}
public
void
setPerformancesId
(
String
performancesId
)
{
this
.
performancesId
=
performancesId
;
}
public
String
getPerformancesId
()
{
return
performancesId
;
}
public
void
setTitle
(
String
title
)
{
this
.
title
=
title
;
}
public
String
getTitle
()
{
return
title
;
}
public
void
setType
(
Integer
type
)
{
this
.
type
=
type
;
}
public
Integer
getType
()
{
return
type
;
}
public
void
setImgPoster
(
String
imgPoster
)
{
this
.
imgPoster
=
imgPoster
;
}
public
String
getImgPoster
()
{
return
imgPoster
;
}
public
void
setProvinceId
(
String
provinceId
)
{
this
.
provinceId
=
provinceId
;
}
public
String
getProvinceId
()
{
return
provinceId
;
}
public
void
setProvinceName
(
String
provinceName
)
{
this
.
provinceName
=
provinceName
;
}
public
String
getProvinceName
()
{
return
provinceName
;
}
public
void
setCityId
(
Long
cityId
)
{
this
.
cityId
=
cityId
;
}
public
Long
getCityId
()
{
return
cityId
;
}
public
void
setCityName
(
String
cityName
)
{
this
.
cityName
=
cityName
;
}
public
String
getCityName
()
{
return
cityName
;
}
public
void
setDistrictId
(
Long
districtId
)
{
this
.
districtId
=
districtId
;
}
public
Long
getDistrictId
()
{
return
districtId
;
}
public
void
setDistrictName
(
String
districtName
)
{
this
.
districtName
=
districtName
;
}
public
String
getDistrictName
()
{
return
districtName
;
}
public
void
setApprovalUrl
(
String
approvalUrl
)
{
this
.
approvalUrl
=
approvalUrl
;
}
public
String
getApprovalUrl
()
{
return
approvalUrl
;
}
public
void
setNotice
(
String
notice
)
{
this
.
notice
=
notice
;
}
public
String
getNotice
()
{
return
notice
;
}
public
void
setSponsorId
(
String
sponsorId
)
{
this
.
sponsorId
=
sponsorId
;
}
public
String
getSponsorId
()
{
return
sponsorId
;
}
public
void
setSponsorType
(
String
sponsorType
)
{
this
.
sponsorType
=
sponsorType
;
}
public
String
getSponsorType
()
{
return
sponsorType
;
}
public
void
setSponsor
(
String
sponsor
)
{
this
.
sponsor
=
sponsor
;
}
public
String
getSponsor
()
{
return
sponsor
;
}
public
void
setContacts
(
String
contacts
)
{
this
.
contacts
=
contacts
;
}
public
String
getContacts
()
{
return
contacts
;
}
public
void
setMobile
(
String
mobile
)
{
this
.
mobile
=
mobile
;
}
public
String
getMobile
()
{
return
mobile
;
}
public
void
setDescribes
(
String
describes
)
{
this
.
describes
=
describes
;
}
public
String
getDescribes
()
{
return
describes
;
}
public
void
setDetails
(
String
details
)
{
this
.
details
=
details
;
}
public
String
getDetails
()
{
return
details
;
}
public
void
setNoticeImage
(
String
noticeImage
)
{
this
.
noticeImage
=
noticeImage
;
}
public
String
getNoticeImage
()
{
return
noticeImage
;
}
public
void
setTimeStart
(
Date
timeStart
)
{
this
.
timeStart
=
timeStart
;
}
public
Date
getTimeStart
()
{
return
timeStart
;
}
public
void
setTimeEnd
(
Date
timeEnd
)
{
this
.
timeEnd
=
timeEnd
;
}
public
Date
getTimeEnd
()
{
return
timeEnd
;
}
public
void
setAuditTime
(
Date
auditTime
)
{
this
.
auditTime
=
auditTime
;
}
public
Date
getAuditTime
()
{
return
auditTime
;
}
public
void
setRejectTxt
(
String
rejectTxt
)
{
this
.
rejectTxt
=
rejectTxt
;
}
public
String
getRejectTxt
()
{
return
rejectTxt
;
}
public
void
setSort
(
Long
sort
)
{
this
.
sort
=
sort
;
}
public
Long
getSort
()
{
return
sort
;
}
public
void
setComment
(
String
comment
)
{
this
.
comment
=
comment
;
}
public
String
getComment
()
{
return
comment
;
}
public
void
setCreatedAt
(
Date
createdAt
)
{
this
.
createdAt
=
createdAt
;
}
public
Date
getCreatedAt
()
{
return
createdAt
;
}
public
void
setUpdatedAt
(
Date
updatedAt
)
{
this
.
updatedAt
=
updatedAt
;
}
public
Date
getUpdatedAt
()
{
return
updatedAt
;
}
@Override
public
String
toString
()
{
return
new
ToStringBuilder
(
this
,
ToStringStyle
.
MULTI_LINE_STYLE
)
.
append
(
"mid"
,
getMid
())
.
append
(
"performancesId"
,
getPerformancesId
())
.
append
(
"title"
,
getTitle
())
.
append
(
"type"
,
getType
())
.
append
(
"imgPoster"
,
getImgPoster
())
.
append
(
"provinceId"
,
getProvinceId
())
.
append
(
"provinceName"
,
getProvinceName
())
.
append
(
"cityId"
,
getCityId
())
.
append
(
"cityName"
,
getCityName
())
.
append
(
"districtId"
,
getDistrictId
())
.
append
(
"districtName"
,
getDistrictName
())
.
append
(
"approvalUrl"
,
getApprovalUrl
())
.
append
(
"notice"
,
getNotice
())
.
append
(
"sponsorId"
,
getSponsorId
())
.
append
(
"sponsorType"
,
getSponsorType
())
.
append
(
"sponsor"
,
getSponsor
())
.
append
(
"contacts"
,
getContacts
())
.
append
(
"mobile"
,
getMobile
())
.
append
(
"describes"
,
getDescribes
())
.
append
(
"details"
,
getDetails
())
.
append
(
"noticeImage"
,
getNoticeImage
())
.
append
(
"timeStart"
,
getTimeStart
())
.
append
(
"timeEnd"
,
getTimeEnd
())
.
append
(
"auditTime"
,
getAuditTime
())
.
append
(
"rejectTxt"
,
getRejectTxt
())
.
append
(
"sort"
,
getSort
())
.
append
(
"comment"
,
getComment
())
.
append
(
"createdAt"
,
getCreatedAt
())
.
append
(
"updatedAt"
,
getUpdatedAt
())
.
toString
();
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/mapper/KylinOrderTicketsMapper.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
mapper
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinOrderTickets
;
import
java.util.List
;
/**
* 订单Mapper接口
*
* @author ruoyi
* @date 2021-05-24
*/
public
interface
KylinOrderTicketsMapper
{
/**
* 查询订单
*
* @param mid 订单ID
* @return 订单
*/
public
KylinOrderTickets
selectKylinOrderTicketsById
(
Integer
mid
);
/**
* 查询订单列表
*
* @param kylinOrderTickets 订单
* @return 订单集合
*/
public
List
<
KylinOrderTickets
>
selectKylinOrderTicketsList
(
KylinOrderTickets
kylinOrderTickets
);
/**
* 新增订单
*
* @param kylinOrderTickets 订单
* @return 结果
*/
public
int
insertKylinOrderTickets
(
KylinOrderTickets
kylinOrderTickets
);
/**
* 修改订单
*
* @param kylinOrderTickets 订单
* @return 结果
*/
public
int
updateKylinOrderTickets
(
KylinOrderTickets
kylinOrderTickets
);
/**
* 删除订单
*
* @param mid 订单ID
* @return 结果
*/
public
int
deleteKylinOrderTicketsById
(
Integer
mid
);
/**
* 批量删除订单
*
* @param mids 需要删除的数据ID
* @return 结果
*/
public
int
deleteKylinOrderTicketsByIds
(
String
[]
mids
);
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/mapper/KylinPerformancesMapper.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
mapper
;
import
java.util.List
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinPerformances
;
/**
* 演出Mapper接口
*
* @author ruoyi
* @date 2021-05-24
*/
public
interface
KylinPerformancesMapper
{
/**
* 查询演出
*
* @param mid 演出ID
* @return 演出
*/
public
KylinPerformances
selectKylinPerformancesById
(
Long
mid
);
/**
* 查询演出列表
*
* @param kylinPerformances 演出
* @return 演出集合
*/
public
List
<
KylinPerformances
>
selectKylinPerformancesList
(
KylinPerformances
kylinPerformances
);
/**
* 新增演出
*
* @param kylinPerformances 演出
* @return 结果
*/
public
int
insertKylinPerformances
(
KylinPerformances
kylinPerformances
);
/**
* 修改演出
*
* @param kylinPerformances 演出
* @return 结果
*/
public
int
updateKylinPerformances
(
KylinPerformances
kylinPerformances
);
/**
* 删除演出
*
* @param mid 演出ID
* @return 结果
*/
public
int
deleteKylinPerformancesById
(
Long
mid
);
/**
* 批量删除演出
*
* @param mids 需要删除的数据ID
* @return 结果
*/
public
int
deleteKylinPerformancesByIds
(
String
[]
mids
);
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/IKylinOrderTicketsService.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinOrderTickets
;
import
java.util.List
;
/**
* 订单Service接口
*
* @author ruoyi
* @date 2021-05-24
*/
public
interface
IKylinOrderTicketsService
{
/**
* 查询订单
*
* @param mid 订单ID
* @return 订单
*/
public
KylinOrderTickets
selectKylinOrderTicketsById
(
Integer
mid
);
/**
* 查询订单列表
*
* @param kylinOrderTickets 订单
* @return 订单集合
*/
public
List
<
KylinOrderTickets
>
selectKylinOrderTicketsList
(
KylinOrderTickets
kylinOrderTickets
);
/**
* 新增订单
*
* @param kylinOrderTickets 订单
* @return 结果
*/
public
int
insertKylinOrderTickets
(
KylinOrderTickets
kylinOrderTickets
);
/**
* 修改订单
*
* @param kylinOrderTickets 订单
* @return 结果
*/
public
int
updateKylinOrderTickets
(
KylinOrderTickets
kylinOrderTickets
);
/**
* 批量删除订单
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public
int
deleteKylinOrderTicketsByIds
(
String
ids
);
/**
* 删除订单信息
*
* @param mid 订单ID
* @return 结果
*/
public
int
deleteKylinOrderTicketsById
(
Integer
mid
);
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/IKylinPerformancesService.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
;
import
java.util.List
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinPerformances
;
/**
* 演出Service接口
*
* @author ruoyi
* @date 2021-05-24
*/
public
interface
IKylinPerformancesService
{
/**
* 查询演出
*
* @param mid 演出ID
* @return 演出
*/
public
KylinPerformances
selectKylinPerformancesById
(
Long
mid
);
/**
* 查询演出列表
*
* @param kylinPerformances 演出
* @return 演出集合
*/
public
List
<
KylinPerformances
>
selectKylinPerformancesList
(
KylinPerformances
kylinPerformances
);
/**
* 新增演出
*
* @param kylinPerformances 演出
* @return 结果
*/
public
int
insertKylinPerformances
(
KylinPerformances
kylinPerformances
);
/**
* 修改演出
*
* @param kylinPerformances 演出
* @return 结果
*/
public
int
updateKylinPerformances
(
KylinPerformances
kylinPerformances
);
/**
* 批量删除演出
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public
int
deleteKylinPerformancesByIds
(
String
ids
);
/**
* 删除演出信息
*
* @param mid 演出ID
* @return 结果
*/
public
int
deleteKylinPerformancesById
(
Long
mid
);
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinOrderTicketsServiceImpl.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
.
impl
;
import
com.liquidnet.client.admin.common.core.text.Convert
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinOrderTickets
;
import
com.liquidnet.client.admin.zhengzai.kylin.mapper.KylinOrderTicketsMapper
;
import
com.liquidnet.client.admin.zhengzai.kylin.service.IKylinOrderTicketsService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.List
;
/**
* 订单Service业务层处理
*
* @author ruoyi
* @date 2021-05-24
*/
@Service
public
class
KylinOrderTicketsServiceImpl
implements
IKylinOrderTicketsService
{
@Autowired
private
KylinOrderTicketsMapper
kylinOrderTicketsMapper
;
/**
* 查询订单
*
* @param mid 订单ID
* @return 订单
*/
@Override
public
KylinOrderTickets
selectKylinOrderTicketsById
(
Integer
mid
)
{
return
kylinOrderTicketsMapper
.
selectKylinOrderTicketsById
(
mid
);
}
/**
* 查询订单列表
*
* @param kylinOrderTickets 订单
* @return 订单
*/
@Override
public
List
<
KylinOrderTickets
>
selectKylinOrderTicketsList
(
KylinOrderTickets
kylinOrderTickets
)
{
return
kylinOrderTicketsMapper
.
selectKylinOrderTicketsList
(
kylinOrderTickets
);
}
/**
* 新增订单
*
* @param kylinOrderTickets 订单
* @return 结果
*/
@Override
public
int
insertKylinOrderTickets
(
KylinOrderTickets
kylinOrderTickets
)
{
return
kylinOrderTicketsMapper
.
insertKylinOrderTickets
(
kylinOrderTickets
);
}
/**
* 修改订单
*
* @param kylinOrderTickets 订单
* @return 结果
*/
@Override
public
int
updateKylinOrderTickets
(
KylinOrderTickets
kylinOrderTickets
)
{
return
kylinOrderTicketsMapper
.
updateKylinOrderTickets
(
kylinOrderTickets
);
}
/**
* 删除订单对象
*
* @param ids 需要删除的数据ID
* @return 结果
*/
@Override
public
int
deleteKylinOrderTicketsByIds
(
String
ids
)
{
return
kylinOrderTicketsMapper
.
deleteKylinOrderTicketsByIds
(
Convert
.
toStrArray
(
ids
));
}
/**
* 删除订单信息
*
* @param mid 订单ID
* @return 结果
*/
@Override
public
int
deleteKylinOrderTicketsById
(
Integer
mid
)
{
return
kylinOrderTicketsMapper
.
deleteKylinOrderTicketsById
(
mid
);
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinPerformancesAdminServiceImpl.java
0 → 100644
View file @
247314a9
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.client.admin.zhengzai.kylin.utils.DataUtils
;
import
com.liquidnet.client.admin.zhengzai.kylin.utils.PerformanceVoUtils
;
import
com.liquidnet.commons.lang.util.BeanUtil
;
import
com.liquidnet.service.kylin.dao.*
;
import
com.liquidnet.service.kylin.dto.param.*
;
import
com.liquidnet.service.kylin.dto.vo.KylinPerformanceVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinTicketVo
;
import
com.liquidnet.service.kylin.dto.vo.admin.KylinPerformanceMemberHistoryVo
;
import
com.liquidnet.service.kylin.dto.vo.partner.KylinPerformanceMisVo
;
import
com.liquidnet.service.kylin.dto.vo.partner.KylinTicketPartnerVo
;
import
com.liquidnet.service.kylin.dto.vo.partner.KylinTicketTimesPartnerVo
;
import
com.liquidnet.service.kylin.entity.*
;
import
com.liquidnet.service.kylin.mapper.*
;
import
com.liquidnet.service.kylin.service.admin.IKylinPerformancesAdminService
;
import
com.mongodb.BasicDBObject
;
import
com.mongodb.client.model.FindOneAndUpdateOptions
;
import
com.mongodb.client.model.ReturnDocument
;
import
lombok.extern.slf4j.Slf4j
;
import
org.bson.Document
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.domain.PageRequest
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.data.domain.Sort
;
import
org.springframework.data.mongodb.core.MongoTemplate
;
import
org.springframework.data.mongodb.core.convert.MongoConverter
;
import
org.springframework.data.mongodb.core.query.Criteria
;
import
org.springframework.data.mongodb.core.query.Query
;
import
org.springframework.stereotype.Service
;
import
java.math.BigDecimal
;
import
java.time.LocalDateTime
;
import
java.time.format.DateTimeFormatter
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
/**
* <p>
* 演出 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-05-05
*/
@Service
@Slf4j
public
class
KylinPerformancesAdminServiceImpl
extends
ServiceImpl
<
KylinPerformancesMapper
,
KylinPerformances
>
implements
IKylinPerformancesAdminService
{
@Autowired
MongoTemplate
mongoTemplate
;
@Autowired
private
MongoConverter
mongoConverter
;
@Autowired
private
PerformanceVoUtils
performanceVoUtils
;
@Autowired
private
DataUtils
dataUtils
;
@Autowired
private
KylinPerformancesMapper
performancesMapper
;
@Autowired
private
KylinPerformanceStatusMapper
performanceStatusMapper
;
@Autowired
private
KylinPerformanceRelationsMapper
performanceRelationsMapper
;
@Autowired
private
KylinTicketsMapper
ticketsMapper
;
@Autowired
private
KylinTicketStatusMapper
ticketStatusMapper
;
@Autowired
private
KylinTicketRelationsMapper
ticketRelationsMapper
;
@Autowired
private
KylinTicketTimesMapper
ticketTimesMapper
;
@Autowired
private
KylinTicketTimeRelationMapper
ticketTimeRelationMapper
;
@Override
public
KylinPerformanceMisVo
performanceDetails
(
String
performancesId
)
{
log
.
info
(
" PERFORMANCE mis演出详情"
);
KylinPerformanceMisVo
createMisVo
=
performanceVoUtils
.
getPerformanceMisVo
(
performancesId
);
return
createMisVo
;
}
@Override
public
boolean
performanceAudit
(
String
performancesId
,
int
status
,
String
rejectTxt
)
{
try
{
LocalDateTime
updatedAt
=
LocalDateTime
.
now
();
HashMap
<
String
,
Object
>
map
=
new
HashMap
<>();
int
auditStatus
=
0
;
if
(
status
==
3
)
{
log
.
info
(
" PERFORMANCE 演出审核 通过"
);
rejectTxt
=
""
;
auditStatus
=
1
;
//修改演出
map
.
put
(
"rejectTxt"
,
rejectTxt
);
map
.
put
(
"status"
,
status
);
map
.
put
(
"auditStatus"
,
auditStatus
);
map
.
put
(
"updatedAt"
,
updatedAt
.
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
)));
BasicDBObject
objectPerformanceVo
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map
));
Document
doc
=
mongoTemplate
.
getCollection
(
PerformancePartnerVo
.
class
.
getSimpleName
()).
findOneAndUpdate
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performancesId
)).
getQueryObject
(),
objectPerformanceVo
,
new
FindOneAndUpdateOptions
().
returnDocument
(
ReturnDocument
.
AFTER
)
);
KylinPerformanceStatus
sqlStatus
=
performanceStatusMapper
.
selectOne
(
new
UpdateWrapper
<
KylinPerformanceStatus
>().
eq
(
"performance_id"
,
performancesId
));
if
(
sqlStatus
.
getStatus
()
==
1
)
{
log
.
info
(
" PERFORMANCE 演出审核 第一次"
);
//修改
KylinPerformanceStatus
performanceStatus
=
new
KylinPerformanceStatus
();
performanceStatus
.
setStatus
(
status
);
performanceStatus
.
setAuditStatus
(
auditStatus
);
performanceStatus
.
setUpdatedAt
(
updatedAt
);
performanceStatusMapper
.
update
(
performanceStatus
,
new
UpdateWrapper
<
KylinPerformanceStatus
>().
eq
(
"performance_id"
,
performancesId
));
KylinPerformances
performances
=
new
KylinPerformances
();
performances
.
setUpdatedAt
(
updatedAt
);
performances
.
setRejectTxt
(
rejectTxt
);
performancesMapper
.
update
(
performances
,
new
UpdateWrapper
<
KylinPerformances
>().
eq
(
"performances_id"
,
performancesId
));
List
<
KylinTicketTimesPartnerVo
>
kylinTicketTimesPartnerVos
=
performanceVoUtils
.
getTimesMongoList
(
performancesId
);
for
(
KylinTicketTimesPartnerVo
ticketTimeItem
:
kylinTicketTimesPartnerVos
)
{
for
(
KylinTicketPartnerVo
ticketItem
:
performanceVoUtils
.
getTicketMongoList
(
ticketTimeItem
.
getTicketTimesId
()))
{
BasicDBObject
objectTicketVo
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map
));
mongoTemplate
.
getCollection
(
KylinTicketPartnerVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"ticketsId"
).
is
(
ticketItem
.
getTicketsId
())).
getQueryObject
(),
objectTicketVo
);
KylinTickets
tickets
=
new
KylinTickets
();
tickets
.
setUpdatedAt
(
updatedAt
);
ticketsMapper
.
update
(
tickets
,
new
UpdateWrapper
<
KylinTickets
>().
eq
(
"tickets_id"
,
ticketItem
.
getTicketsId
()));
KylinTicketStatus
ticketStatus
=
new
KylinTicketStatus
();
ticketStatus
.
setUpdatedAt
(
updatedAt
);
ticketStatus
.
setStatus
(
status
);
ticketStatusMapper
.
update
(
ticketStatus
,
new
UpdateWrapper
<
KylinTicketStatus
>().
eq
(
"ticket_id"
,
ticketItem
.
getTicketsId
()));
}
}
}
else
{
//只修改演出相关 场次 票 (不包括 库存 售卖时间 限购)
log
.
info
(
" PERFORMANCE 演出审核 修改"
);
HashMap
<
String
,
Object
>
mapSql
=
new
HashMap
<>();
mapSql
.
put
(
"status"
,
9
);
mapSql
.
put
(
"updatedAt"
,
updatedAt
.
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
)));
performanceVoUtils
.
updatePerformanceMySql
(
performancesId
,
mapSql
,
performanceVoUtils
.
getPerformanceMisVo
(
performancesId
),
updatedAt
,
auditStatus
);
if
(
sqlStatus
.
getStatus
()
==
6
)
{
//若 演出上 则 线判断状态
performanceVoUtils
.
performanceVoStatus
(
performancesId
);
}
}
dataUtils
.
delPerformanceRedis
(
performancesId
);
}
else
if
(
status
==
4
)
{
log
.
info
(
" PERFORMANCE 演出审核 拒绝"
);
auditStatus
=
2
;
map
.
put
(
"rejectTxt"
,
rejectTxt
);
map
.
put
(
"auditStatus"
,
auditStatus
);
map
.
put
(
"status"
,
status
);
map
.
put
(
"updatedAt"
,
updatedAt
.
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
)));
BasicDBObject
object
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map
));
mongoTemplate
.
getCollection
(
PerformancePartnerVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performancesId
)).
getQueryObject
(),
object
);
KylinPerformanceStatus
statusData
=
performanceStatusMapper
.
selectOne
(
new
UpdateWrapper
<
KylinPerformanceStatus
>().
eq
(
"performance_id"
,
performancesId
));
KylinPerformanceStatus
performanceStatus
=
new
KylinPerformanceStatus
();
if
(
statusData
.
getStatus
()
==
1
||
statusData
.
getStatus
()
==
4
)
{
performanceStatus
.
setStatus
(
status
);
}
performanceStatus
.
setAuditStatus
(
auditStatus
);
performanceStatus
.
setUpdatedAt
(
updatedAt
);
performanceStatusMapper
.
update
(
performanceStatus
,
new
UpdateWrapper
<
KylinPerformanceStatus
>().
eq
(
"performance_id"
,
performancesId
));
KylinPerformances
performances
=
new
KylinPerformances
();
performances
.
setRejectTxt
(
rejectTxt
);
performances
.
setUpdatedAt
(
updatedAt
);
performancesMapper
.
update
(
performances
,
new
UpdateWrapper
<
KylinPerformances
>().
eq
(
"performances_id"
,
performancesId
));
}
else
{
return
false
;
}
return
true
;
}
catch
(
Exception
e
)
{
System
.
out
.
println
(
"ERROR DATA = "
+
e
.
getMessage
());
e
.
printStackTrace
();
return
false
;
}
}
@Override
public
PageInfo
<
PerformanceAdminListDao
>
getList
(
PerformanceAdminListParam
performanceAdminListParam
)
{
PageInfo
<
PerformanceAdminListDao
>
pageInfoTmp
=
null
;
try
{
PageHelper
.
startPage
(
performanceAdminListParam
.
getPage
(),
performanceAdminListParam
.
getSize
());
List
<
PerformanceAdminListDao
>
voList
=
performancesMapper
.
misPerformanceList
(
BeanUtil
.
convertBeanToMap
(
performanceAdminListParam
));
pageInfoTmp
=
new
PageInfo
(
voList
);
}
catch
(
Exception
e
)
{
return
null
;
}
return
pageInfoTmp
;
}
@Override
public
List
<
PerformanceTitleDao
>
getListByRoadShowId
(
String
roadShowId
)
{
try
{
List
<
PerformanceTitleDao
>
voList
=
performancesMapper
.
misTitleByRoadShowIdList
(
roadShowId
);
return
voList
;
}
catch
(
Exception
e
)
{
return
new
ArrayList
<>();
}
}
@Override
public
List
<
PerformanceTitleDao
>
getListByStatus
(
String
status
)
{
List
<
PerformanceTitleDao
>
voList
=
performancesMapper
.
misTitleByStatusList
(
status
);
return
voList
;
}
@Override
public
boolean
changeRoadShowId
(
String
performancesId
,
String
roadShowId
)
{
try
{
//mysql
KylinPerformanceRelations
performanceRelations
=
new
KylinPerformanceRelations
();
performanceRelations
.
setRoadShowId
(
roadShowId
);
performanceRelationsMapper
.
update
(
performanceRelations
,
new
UpdateWrapper
<
KylinPerformanceRelations
>().
eq
(
"performance_id"
,
performancesId
));
//mongodb
HashMap
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"roadShowId"
,
roadShowId
);
BasicDBObject
object
=
new
BasicDBObject
(
"$set"
,
map
);
mongoTemplate
.
getCollection
(
KylinPerformanceVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performancesId
)).
getQueryObject
(),
object
);
dataUtils
.
delPerformanceRedis
(
performancesId
);
return
true
;
}
catch
(
Exception
e
)
{
return
false
;
}
}
@Override
public
boolean
setRecommend
(
List
<
PerformanceRecommendAdminParam
>
performancesIdList
)
{
try
{
KylinPerformanceStatus
performanceStatus
=
new
KylinPerformanceStatus
();
performanceStatus
.
setIsRecommend
(
0
);
performanceStatus
.
setStatus
(
null
);
performanceStatusMapper
.
update
(
performanceStatus
,
new
UpdateWrapper
<
KylinPerformanceStatus
>().
gt
(
"is_recommend"
,
0
));
HashMap
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"isRecommend"
,
0
);
BasicDBObject
object
=
new
BasicDBObject
(
"$set"
,
map
);
mongoTemplate
.
getCollection
(
KylinPerformanceVo
.
class
.
getSimpleName
()).
updateMany
(
Query
.
query
(
Criteria
.
where
(
"isRecommend"
).
gt
(
0
)).
getQueryObject
(),
object
);
for
(
PerformanceRecommendAdminParam
item
:
performancesIdList
)
{
performanceStatus
.
setIsRecommend
(
item
.
getIsRecommend
());
performanceStatusMapper
.
update
(
performanceStatus
,
new
UpdateWrapper
<
KylinPerformanceStatus
>().
eq
(
"performance_id"
,
item
.
getPerformanceId
()));
HashMap
<
String
,
Object
>
map2
=
new
HashMap
<>();
map2
.
put
(
"isRecommend"
,
item
.
getIsRecommend
());
BasicDBObject
object2
=
new
BasicDBObject
(
"$set"
,
map2
);
mongoTemplate
.
getCollection
(
KylinPerformanceVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
item
.
getPerformanceId
())).
getQueryObject
(),
object2
);
}
// dataUtils.delPerformanceRecommendRedis(item.getPerformanceId());
return
true
;
}
catch
(
Exception
e
)
{
return
false
;
}
}
@Override
public
PageInfo
<
PerformanceRecommendAdminDao
>
listRecommend
()
{
PageInfo
<
PerformanceRecommendAdminDao
>
pageInfoTmp
=
null
;
try
{
PageHelper
.
startPage
(
1
,
10
);
List
<
PerformanceRecommendAdminDao
>
voList
=
performancesMapper
.
reCommendPerformanceList
();
pageInfoTmp
=
new
PageInfo
(
voList
);
}
catch
(
Exception
e
)
{
return
null
;
}
return
pageInfoTmp
;
}
@Override
public
PerformanceMemberAuditDao
performanceMemberInfo
(
String
performanceId
)
{
PerformanceMemberAuditDao
performanceMemberAuditDao
=
new
PerformanceMemberAuditDao
();
PerformanceTitleDao
data
=
performancesMapper
.
misPerformanceMemberInfo
(
performanceId
);
List
<
TicketMemberAuditDao
>
ticketData
=
performancesMapper
.
misTicketMemberInfo
(
performanceId
);
performanceMemberAuditDao
.
setPerformancesId
(
data
.
getPerformancesId
());
performanceMemberAuditDao
.
setTitle
(
data
.
getTitle
());
performanceMemberAuditDao
.
setIsExclusive
(
0
);
performanceMemberAuditDao
.
setIsMember
(
0
);
performanceMemberAuditDao
.
setTicketMemberAudit
(
ticketData
);
for
(
TicketMemberAuditDao
item
:
ticketData
)
{
if
(
item
.
getIsMember
()
==
1
)
{
performanceMemberAuditDao
.
setIsMember
(
1
);
}
if
(
item
.
getIsExclusive
()
==
1
)
{
performanceMemberAuditDao
.
setIsExclusive
(
1
);
}
}
PerformanceMemberAuditParam
memberAuditVo
=
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performanceId
)),
PerformanceMemberAuditParam
.
class
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
if
(
memberAuditVo
!=
null
)
{
if
(
memberAuditVo
.
getStatus
()
==
1
)
{
performanceMemberAuditDao
.
setIsSubmit
(
1
);
}
else
{
performanceMemberAuditDao
.
setIsSubmit
(
0
);
}
}
else
{
performanceMemberAuditDao
.
setIsSubmit
(
0
);
}
return
performanceMemberAuditDao
;
}
@Override
public
boolean
performanceMemberChange
(
PerformanceMemberAuditParam
performanceMemberAuditParam
)
{
try
{
performanceMemberAuditParam
.
setStatus
(
1
);
mongoTemplate
.
insert
(
performanceMemberAuditParam
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
return
true
;
}
catch
(
Exception
e
)
{
return
false
;
}
}
@Override
public
PageInfo
<
PerformanceTitleDao
>
performanceMemberList
(
String
title
,
int
page
,
int
size
)
{
PageInfo
<
PerformanceTitleDao
>
pageInfoTmp
=
null
;
// 排序 分页
Pageable
pageable
=
PageRequest
.
of
(
page
,
size
,
Sort
.
by
(
Sort
.
Direction
.
DESC
,
"createdAt"
));
//条件
Criteria
criteria
=
Criteria
.
where
(
"status"
).
is
(
1
);
if
(!
title
.
isEmpty
())
{
criteria
.
and
(
"title"
).
regex
(
".*?\\"
+
title
);
}
Query
query
=
Query
.
query
(
criteria
);
// 查询总数
long
count
=
mongoTemplate
.
count
(
query
,
PerformanceMemberAuditParam
.
class
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
List
<
PerformanceMemberAuditParam
>
paramList
=
mongoTemplate
.
find
(
query
,
PerformanceMemberAuditParam
.
class
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
query
.
with
(
pageable
);
//处理Vo
List
<
PerformanceTitleDao
>
voList
=
new
ArrayList
<>();
for
(
PerformanceMemberAuditParam
item
:
paramList
)
{
PerformanceTitleDao
voData
=
new
PerformanceTitleDao
();
voData
.
setPerformancesId
(
item
.
getPerformancesId
());
voData
.
setTitle
(
item
.
getTitle
());
voList
.
add
(
voData
);
}
pageInfoTmp
=
new
PageInfo
(
voList
);
pageInfoTmp
.
setTotal
(
count
);
return
pageInfoTmp
;
}
@Override
public
PerformanceMemberAuditDao
performanceMemberAuditInfo
(
String
performanceId
,
int
status
)
{
PerformanceMemberAuditParam
memberAuditVo
=
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performanceId
).
and
(
"status"
).
is
(
status
)),
PerformanceMemberAuditParam
.
class
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
if
(
memberAuditVo
==
null
)
{
return
null
;
}
PerformanceMemberAuditDao
performanceMemberAuditDao
=
new
PerformanceMemberAuditDao
();
PerformanceTitleDao
data
=
performancesMapper
.
misPerformanceMemberInfo
(
performanceId
);
List
<
TicketMemberAuditDao
>
ticketData
=
performancesMapper
.
misTicketMemberInfo
(
performanceId
);
performanceMemberAuditDao
.
setPerformancesId
(
data
.
getPerformancesId
());
performanceMemberAuditDao
.
setTitle
(
data
.
getTitle
());
performanceMemberAuditDao
.
setIsExclusive
(
0
);
performanceMemberAuditDao
.
setIsMember
(
0
);
for
(
TicketMemberAuditDao
item
:
ticketData
)
{
if
(
memberAuditVo
.
getIsMember
()
==
1
)
{
performanceMemberAuditDao
.
setIsMember
(
1
);
}
if
(
memberAuditVo
.
getIsExclusive
()
==
1
)
{
performanceMemberAuditDao
.
setIsExclusive
(
1
);
}
}
for
(
TicketMemberAuditParam
item
:
memberAuditVo
.
getTicketMemberAudit
())
{
for
(
TicketMemberAuditDao
item2
:
ticketData
)
{
if
(
item
.
getTicketsId
().
equals
(
item2
.
getTicketsId
()))
{
item2
.
setAdvanceMinuteMember
(
item
.
getAdvanceMinuteMember
());
item2
.
setPriceDiscountMember
(
item
.
getPriceDiscountMember
());
item2
.
setMemberLimitCount
(
item
.
getMemberLimitCount
());
item2
.
setIsMember
(
performanceMemberAuditDao
.
getIsMember
());
item2
.
setIsExclusive
(
performanceMemberAuditDao
.
getIsExclusive
());
break
;
}
}
}
performanceMemberAuditDao
.
setTicketMemberAudit
(
ticketData
);
return
performanceMemberAuditDao
;
}
@Override
public
boolean
performanceMemberAudit
(
String
performanceId
,
int
status
,
String
rejectTxt
)
{
try
{
LocalDateTime
updatedAt
=
LocalDateTime
.
now
();
if
(
status
==
3
)
{
PerformanceMemberAuditParam
memberAuditVo
=
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performanceId
).
and
(
"status"
).
is
(
1
)),
PerformanceMemberAuditParam
.
class
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
int
isAdvance
=
0
;
int
isDiscount
=
0
;
for
(
TicketMemberAuditParam
item
:
memberAuditVo
.
getTicketMemberAudit
())
{
if
(
item
.
getPriceDiscountMember
().
compareTo
(
new
BigDecimal
(
"0"
))
==
1
)
{
isDiscount
=
1
;
}
if
(
item
.
getAdvanceMinuteMember
()
>
0
)
{
isAdvance
=
1
;
}
//修改数据库
KylinTicketStatus
ticketStatus
=
new
KylinTicketStatus
();
ticketStatus
.
setMemberLimitCount
(
item
.
getMemberLimitCount
());
ticketStatus
.
setIsMember
(
memberAuditVo
.
getIsMember
());
ticketStatus
.
setIsExclusive
(
memberAuditVo
.
getIsExclusive
());
ticketStatus
.
setUpdatedAt
(
updatedAt
);
ticketStatusMapper
.
update
(
ticketStatus
,
new
UpdateWrapper
<
KylinTicketStatus
>().
eq
(
"ticket_id"
,
item
.
getTicketsId
()));
KylinTickets
tickets
=
new
KylinTickets
();
tickets
.
setAdvanceMinuteMember
(
item
.
getAdvanceMinuteMember
());
tickets
.
setPriceDiscountMember
(
item
.
getPriceDiscountMember
());
tickets
.
setUpdatedAt
(
updatedAt
);
ticketsMapper
.
update
(
tickets
,
new
UpdateWrapper
<
KylinTickets
>().
eq
(
"tickets_id"
,
item
.
getTicketsId
()));
KylinTickets
ticketsTime
=
ticketsMapper
.
selectOne
(
new
UpdateWrapper
<
KylinTickets
>().
eq
(
"tickets_id"
,
item
.
getTicketsId
()));
//修改mongo
HashMap
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"isMember"
,
memberAuditVo
.
getIsMember
());
map
.
put
(
"isExclusive"
,
memberAuditVo
.
getIsExclusive
());
map
.
put
(
"updatedAt"
,
updatedAt
);
map
.
put
(
"memberPrice"
,
ticketsTime
.
getPrice
().
subtract
(
item
.
getPriceDiscountMember
()));
map
.
put
(
"memberTimeStart"
,
ticketsTime
.
getTimeStart
().
plusMinutes
(-
ticketsTime
.
getAdvanceMinuteMember
()).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
)));
map
.
put
(
"limitCountMember"
,
item
.
getMemberLimitCount
());
BasicDBObject
object
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map
));
mongoTemplate
.
getCollection
(
KylinTicketVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"ticketsId"
).
is
(
item
.
getTicketsId
())).
getQueryObject
(),
object
);
}
//修改 演出vo
HashMap
<
String
,
Object
>
mapPerformanceVo
=
new
HashMap
<>();
mapPerformanceVo
.
put
(
"isMember"
,
memberAuditVo
.
getIsMember
());
mapPerformanceVo
.
put
(
"isExclusive"
,
memberAuditVo
.
getIsExclusive
());
mapPerformanceVo
.
put
(
"isAdvance"
,
isAdvance
);
mapPerformanceVo
.
put
(
"isDiscount"
,
isDiscount
);
BasicDBObject
objectPerformanceVo
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
mapPerformanceVo
));
mongoTemplate
.
getCollection
(
KylinPerformanceVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performanceId
)).
getQueryObject
(),
objectPerformanceVo
);
HashMap
<
String
,
Object
>
map2
=
new
HashMap
<>();
map2
.
put
(
"status"
,
3
);
map2
.
put
(
"updatedAt"
,
updatedAt
);
map2
.
put
(
"rejectTxt"
,
""
);
BasicDBObject
object
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map2
));
mongoTemplate
.
getCollection
(
PerformanceMemberAuditParam
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performanceId
)).
getQueryObject
(),
object
);
performanceVoUtils
.
performanceVoStatus
(
performanceId
);
dataUtils
.
delPerformanceRedis
(
performanceId
);
}
else
{
HashMap
<
String
,
Object
>
map2
=
new
HashMap
<>();
map2
.
put
(
"status"
,
2
);
map2
.
put
(
"updatedAt"
,
updatedAt
);
map2
.
put
(
"rejectTxt"
,
rejectTxt
);
BasicDBObject
object
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map2
));
mongoTemplate
.
getCollection
(
PerformanceMemberAuditParam
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performanceId
)).
getQueryObject
(),
object
);
}
return
true
;
}
catch
(
Exception
e
)
{
return
false
;
}
}
@Override
public
PageInfo
<
PerformanceMemberAuditParam
>
performanceAuditHistory
(
String
performanceId
)
{
PageInfo
<
PerformanceMemberAuditParam
>
pageInfoTmp
=
null
;
// 排序 分页
Pageable
pageable
=
PageRequest
.
of
(
1
,
100
,
Sort
.
by
(
Sort
.
Direction
.
DESC
,
"createdAt"
));
//条件
Query
query
=
Query
.
query
(
Criteria
.
where
(
"status"
).
ne
(
1
).
and
(
"status"
).
ne
(
0
));
// 查询总数
long
count
=
mongoTemplate
.
count
(
query
,
PerformanceMemberAuditParam
.
class
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
List
<
PerformanceMemberAuditParam
>
paramList
=
mongoTemplate
.
find
(
query
,
PerformanceMemberAuditParam
.
class
,
PerformanceMemberAuditParam
.
class
.
getSimpleName
());
query
.
with
(
pageable
);
//处理Vo
List
<
KylinPerformanceMemberHistoryVo
>
voList
=
new
ArrayList
<>();
for
(
PerformanceMemberAuditParam
item
:
paramList
)
{
KylinPerformanceMemberHistoryVo
voData
=
new
KylinPerformanceMemberHistoryVo
();
voData
.
setAuditTime
(
item
.
getUpdatedAt
());
voData
.
setRejectTxt
(
item
.
getRejectTxt
());
voData
.
setStatus
(
item
.
getStatus
());
voList
.
add
(
voData
);
}
pageInfoTmp
=
new
PageInfo
(
paramList
);
pageInfoTmp
.
setTotal
(
count
);
return
pageInfoTmp
;
}
@Override
public
boolean
changeTicketAgent
(
String
ticketId
,
Integer
status
)
{
try
{
LocalDateTime
updatedAt
=
LocalDateTime
.
now
();
if
(
status
!=
0
&&
status
!=
1
)
{
return
false
;
}
//修改 mysql
KylinTicketStatus
ticketStatus
=
new
KylinTicketStatus
();
ticketStatus
.
setUpdatedAt
(
updatedAt
);
ticketStatus
.
setIsAgent
(
status
);
ticketStatusMapper
.
update
(
ticketStatus
,
new
UpdateWrapper
<
KylinTicketStatus
>().
eq
(
"ticket_id"
,
ticketId
));
//修改 mongo
HashMap
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"updatedAt"
,
updatedAt
.
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
)));
map
.
put
(
"isAgent"
,
status
);
BasicDBObject
object
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map
));
mongoTemplate
.
getCollection
(
KylinTicketVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"ticketsId"
).
is
(
ticketId
)).
getQueryObject
(),
object
);
dataUtils
.
delTicketRedis
(
ticketId
);
return
true
;
}
catch
(
Exception
e
)
{
return
false
;
}
}
@Override
public
boolean
changeSysDamai
(
List
<
SysDamaiParam
>
params
)
{
try
{
LocalDateTime
updatedAt
=
LocalDateTime
.
now
();
for
(
SysDamaiParam
item
:
params
)
{
if
(
item
.
getStatus
()
!=
0
&&
item
.
getStatus
()
!=
1
)
{
return
false
;
}
//修改 mysql
if
(
item
.
getType
().
equals
(
"ticket"
))
{
KylinTicketStatus
ticketStatus
=
new
KylinTicketStatus
();
ticketStatus
.
setUpdatedAt
(
updatedAt
);
ticketStatus
.
setSyncDamai
(
item
.
getStatus
());
ticketStatusMapper
.
update
(
ticketStatus
,
new
UpdateWrapper
<
KylinTicketStatus
>().
eq
(
"ticket_id"
,
item
.
getId
()));
}
else
if
(
item
.
getType
().
equals
(
"performance"
))
{
KylinPerformanceStatus
performanceStatus
=
new
KylinPerformanceStatus
();
performanceStatus
.
setUpdatedAt
(
updatedAt
);
performanceStatus
.
setSyncDamai
(
item
.
getStatus
());
performanceStatusMapper
.
update
(
performanceStatus
,
new
UpdateWrapper
<
KylinPerformanceStatus
>().
eq
(
"performance_id"
,
item
.
getId
()));
}
}
return
true
;
}
catch
(
Exception
e
)
{
return
false
;
}
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinPerformancesServiceImpl.java
deleted
100644 → 0
View file @
3d0e62cc
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
.
impl
;
import
java.util.List
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
com.liquidnet.client.admin.zhengzai.kylin.mapper.KylinPerformancesMapper
;
import
com.liquidnet.client.admin.zhengzai.kylin.domain.KylinPerformances
;
import
com.liquidnet.client.admin.zhengzai.kylin.service.IKylinPerformancesService
;
import
com.liquidnet.client.admin.common.core.text.Convert
;
/**
* 演出Service业务层处理
*
* @author ruoyi
* @date 2021-05-24
*/
@Service
public
class
KylinPerformancesServiceImpl
implements
IKylinPerformancesService
{
@Autowired
private
KylinPerformancesMapper
kylinPerformancesMapper
;
/**
* 查询演出
*
* @param mid 演出ID
* @return 演出
*/
@Override
public
KylinPerformances
selectKylinPerformancesById
(
Long
mid
)
{
return
kylinPerformancesMapper
.
selectKylinPerformancesById
(
mid
);
}
/**
* 查询演出列表
*
* @param kylinPerformances 演出
* @return 演出
*/
@Override
public
List
<
KylinPerformances
>
selectKylinPerformancesList
(
KylinPerformances
kylinPerformances
)
{
return
kylinPerformancesMapper
.
selectKylinPerformancesList
(
kylinPerformances
);
}
/**
* 新增演出
*
* @param kylinPerformances 演出
* @return 结果
*/
@Override
public
int
insertKylinPerformances
(
KylinPerformances
kylinPerformances
)
{
return
kylinPerformancesMapper
.
insertKylinPerformances
(
kylinPerformances
);
}
/**
* 修改演出
*
* @param kylinPerformances 演出
* @return 结果
*/
@Override
public
int
updateKylinPerformances
(
KylinPerformances
kylinPerformances
)
{
return
kylinPerformancesMapper
.
updateKylinPerformances
(
kylinPerformances
);
}
/**
* 删除演出对象
*
* @param ids 需要删除的数据ID
* @return 结果
*/
@Override
public
int
deleteKylinPerformancesByIds
(
String
ids
)
{
return
kylinPerformancesMapper
.
deleteKylinPerformancesByIds
(
Convert
.
toStrArray
(
ids
));
}
/**
* 删除演出信息
*
* @param mid 演出ID
* @return 结果
*/
@Override
public
int
deleteKylinPerformancesById
(
Long
mid
)
{
return
kylinPerformancesMapper
.
deleteKylinPerformancesById
(
mid
);
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/service/impl/KylinRoadShowsAdminServiceImpl.java
0 → 100644
View file @
247314a9
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.kylin.dao.RoadShowAdminListDao
;
import
com.liquidnet.service.kylin.dto.param.CreateRoadShowParam
;
import
com.liquidnet.service.kylin.dto.vo.KylinRoadShowVo
;
import
com.liquidnet.service.kylin.dto.vo.admin.KylinRoadShowAdminVo
;
import
com.liquidnet.service.kylin.entity.KylinRoadShows
;
import
com.liquidnet.service.kylin.mapper.KylinRoadShowsMapper
;
import
com.liquidnet.service.kylin.service.admin.IKylinRoadShowsAdminService
;
import
com.mongodb.BasicDBObject
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.mongodb.core.MongoTemplate
;
import
org.springframework.data.mongodb.core.convert.MongoConverter
;
import
org.springframework.data.mongodb.core.query.Criteria
;
import
org.springframework.data.mongodb.core.query.Query
;
import
org.springframework.stereotype.Service
;
import
java.time.LocalDateTime
;
import
java.util.HashMap
;
import
java.util.List
;
/**
* <p>
* 巡演 服务实现类
* </p>
*
* @author liquidnet
* @since 2021-05-11
*/
@Service
public
class
KylinRoadShowsAdminServiceImpl
extends
ServiceImpl
<
KylinRoadShowsMapper
,
KylinRoadShows
>
implements
IKylinRoadShowsAdminService
{
@Autowired
private
MongoTemplate
mongoTemplate
;
@Autowired
private
MongoConverter
mongoConverter
;
@Autowired
private
KylinRoadShowsMapper
kylinRoadShowsMapper
;
@Override
public
String
createRoadShow
(
CreateRoadShowParam
createRoadShowParam
)
{
try
{
String
roadShowId
=
IDGenerator
.
nextSnowId
().
toString
();
createRoadShowParam
.
setStatus
(
1
);
createRoadShowParam
.
setRoadShowsId
(
roadShowId
);
createRoadShowParam
.
setCreatedAt
(
LocalDateTime
.
now
());
KylinRoadShows
roadShows
=
new
KylinRoadShows
();
BeanUtils
.
copyProperties
(
createRoadShowParam
,
roadShows
);
kylinRoadShowsMapper
.
insert
(
roadShows
);
KylinRoadShowVo
kylinRoadShowVo
=
new
KylinRoadShowVo
();
BeanUtils
.
copyProperties
(
createRoadShowParam
,
kylinRoadShowVo
);
mongoTemplate
.
insert
(
roadShows
,
KylinRoadShowVo
.
class
.
getSimpleName
());
return
roadShowId
;
}
catch
(
Exception
e
)
{
return
""
;
}
}
@Override
public
boolean
updateRoadShow
(
CreateRoadShowParam
createRoadShowParam
)
{
try
{
KylinRoadShows
roadShows
=
new
KylinRoadShows
();
createRoadShowParam
.
setUpdatedAt
(
LocalDateTime
.
now
());
createRoadShowParam
.
setStatus
(
null
);
BeanUtils
.
copyProperties
(
createRoadShowParam
,
roadShows
);
kylinRoadShowsMapper
.
update
(
roadShows
,
new
UpdateWrapper
<
KylinRoadShows
>().
eq
(
"road_shows_id"
,
createRoadShowParam
.
getRoadShowsId
()));
KylinRoadShowVo
kylinRoadShowVo
=
new
KylinRoadShowVo
();
BeanUtils
.
copyProperties
(
createRoadShowParam
,
kylinRoadShowVo
);
BasicDBObject
objectRoadShowVo
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
roadShows
));
mongoTemplate
.
getCollection
(
KylinRoadShows
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"roadShowsId"
).
is
(
createRoadShowParam
.
getRoadShowsId
())).
getQueryObject
(),
objectRoadShowVo
);
return
true
;
}
catch
(
Exception
e
)
{
return
false
;
}
}
@Override
public
boolean
deleteRoadShow
(
String
roadShowId
,
int
status
)
{
KylinRoadShows
roadShows
=
new
KylinRoadShows
();
roadShows
.
setStatus
(
status
);
roadShows
.
setUpdatedAt
(
LocalDateTime
.
now
());
kylinRoadShowsMapper
.
update
(
roadShows
,
new
UpdateWrapper
<
KylinRoadShows
>().
eq
(
"road_shows_id"
,
roadShowId
));
BasicDBObject
objectRoadShowVo
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
roadShows
));
mongoTemplate
.
getCollection
(
KylinRoadShows
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"roadShowsId"
).
is
(
roadShowId
)).
getQueryObject
(),
objectRoadShowVo
);
return
false
;
}
@Override
public
KylinRoadShowAdminVo
detailsRoadShow
(
String
roadShowId
)
{
KylinRoadShows
data
=
kylinRoadShowsMapper
.
selectOne
(
new
UpdateWrapper
<
KylinRoadShows
>().
eq
(
"road_shows_id"
,
roadShowId
));
KylinRoadShowAdminVo
vo
=
new
KylinRoadShowAdminVo
();
vo
.
setTitle
(
data
.
getTitle
());
vo
.
setRoadShowId
(
data
.
getRoadShowsId
());
vo
.
setStatus
(
data
.
getStatus
());
return
vo
;
}
@Override
public
PageInfo
<
RoadShowAdminListDao
>
listRoadShow
(
String
title
,
int
page
,
int
size
)
{
PageInfo
<
RoadShowAdminListDao
>
pageInfoTmp
=
null
;
try
{
HashMap
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"title"
,
title
);
PageHelper
.
startPage
(
page
,
size
);
List
<
RoadShowAdminListDao
>
voList
=
kylinRoadShowsMapper
.
misRoadShowList
(
map
);
pageInfoTmp
=
new
PageInfo
(
voList
);
}
catch
(
Exception
e
)
{
return
null
;
}
return
pageInfoTmp
;
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/utils/DataUtils.java
0 → 100644
View file @
247314a9
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
utils
;
import
com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper
;
import
com.liquidnet.common.cache.redis.util.RedisUtil
;
import
com.liquidnet.commons.lang.util.JsonUtils
;
import
com.liquidnet.service.kylin.constant.KylinRedisConst
;
import
com.liquidnet.service.kylin.dto.vo.*
;
import
com.liquidnet.service.kylin.entity.KylinBuyNotice
;
import
com.liquidnet.service.kylin.mapper.KylinBuyNoticeMapper
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.mongodb.core.MongoTemplate
;
import
org.springframework.data.mongodb.core.query.Criteria
;
import
org.springframework.data.mongodb.core.query.Query
;
import
org.springframework.stereotype.Component
;
import
java.util.List
;
@Component
public
class
DataUtils
{
@Autowired
private
KylinBuyNoticeMapper
buyNoticeMapper
;
@Autowired
private
MongoTemplate
mongoTemplate
;
@Autowired
private
RedisUtil
redisUtil
;
/**
* 初始化普通库存
*
* @param ticketId 票id
* @param totalGeneral 普通库存
*/
public
void
setSurplusGeneral
(
String
ticketId
,
int
totalGeneral
)
{
redisUtil
.
set
(
KylinRedisConst
.
PERFORMANCES_INVENTORY
+
ticketId
+
":"
+
KylinRedisConst
.
SURPLUS_GENERAL
,
totalGeneral
);
}
/**
* 获取普通剩余库存
*
* @param ticketId 票id
* @return 普通剩余库存
*/
public
int
getSurplusGeneral
(
String
ticketId
)
{
return
(
int
)
redisUtil
.
get
(
KylinRedisConst
.
PERFORMANCES_INVENTORY
+
ticketId
+
":"
+
KylinRedisConst
.
SURPLUS_GENERAL
);
}
/**
* 初始化兑换库存
*
* @param ticketId 票id
* @param totalExchange 兑换库存
*/
public
void
setSurplusExchange
(
String
ticketId
,
int
totalExchange
)
{
redisUtil
.
set
(
KylinRedisConst
.
PERFORMANCES_INVENTORY
+
ticketId
+
":"
+
KylinRedisConst
.
SURPLUS_EXCHANGE
,
totalExchange
);
}
/**
* 删除演出redis
*
* @param performanceId
*/
public
void
delPerformanceRedis
(
String
performanceId
)
{
redisUtil
.
del
(
KylinRedisConst
.
PERFORMANCES
+
performanceId
);
}
/**
* 删除场次redis
*
* @param ticketTimeId
*/
public
void
delTicketTimesRedis
(
String
ticketTimeId
)
{
redisUtil
.
del
(
KylinRedisConst
.
TIMES
+
ticketTimeId
);
}
/**
* 删除票种redis
*
* @param ticketId
*/
public
void
delTicketRedis
(
String
ticketId
)
{
redisUtil
.
del
(
KylinRedisConst
.
TICKET
+
ticketId
);
}
/**
* 删除订单redis
*
* @param orderId
*/
public
void
delOrderTicketRedis
(
String
orderId
)
{
redisUtil
.
del
(
KylinRedisConst
.
ORDER
+
orderId
);
}
/**
* 删除订单redis
*
* @param orderEntitiesId
*/
public
void
delOrderTicketEntitiesRedis
(
String
orderEntitiesId
)
{
redisUtil
.
del
(
KylinRedisConst
.
ORDER_ENTITIES
+
orderEntitiesId
);
}
/**
* 删除 banner redis
* @param bannerId
*/
public
void
delBannersRedis
(
String
bannerId
)
{
redisUtil
.
del
(
KylinRedisConst
.
BANNERS
+
bannerId
);
}
/**
* 删除 推荐演出 redis
* @param recommendId
*/
public
void
delPerformanceRecommendRedis
(
String
recommendId
)
{
redisUtil
.
del
(
KylinRedisConst
.
PERFORMANCES_RECOMMEND
+
recommendId
);
}
/**
* 删除 验票账号 redis
* @param checkUserId
*/
public
void
delCheckUserRedis
(
String
checkUserId
)
{
redisUtil
.
del
(
KylinRedisConst
.
CHECK_USER
+
checkUserId
);
}
/**
* 删除 验票账号关系 vo
* @param checkUserId
*/
public
void
delCheckUserRelationRedis
(
String
checkUserId
)
{
redisUtil
.
del
(
KylinRedisConst
.
CHECK_USER_RELATION
+
checkUserId
);
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/java/com/liquidnet/client/admin/zhengzai/kylin/utils/PerformanceVoUtils.java
0 → 100644
View file @
247314a9
package
com
.
liquidnet
.
client
.
admin
.
zhengzai
.
kylin
.
utils
;
import
com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper
;
import
com.liquidnet.common.cache.redis.util.RedisUtil
;
import
com.liquidnet.commons.lang.util.DateUtil
;
import
com.liquidnet.commons.lang.util.IDGenerator
;
import
com.liquidnet.service.kylin.dto.param.PerformancePartnerVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinPerformanceVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinTicketTimesVo
;
import
com.liquidnet.service.kylin.dto.vo.KylinTicketVo
;
import
com.liquidnet.service.kylin.dto.vo.partner.KylinPerformanceMisVo
;
import
com.liquidnet.service.kylin.dto.vo.partner.KylinTicketPartnerVo
;
import
com.liquidnet.service.kylin.dto.vo.partner.KylinTicketTimesPartnerVo
;
import
com.liquidnet.service.kylin.dto.vo.partner.TicketTimesTicketCreatePartnerVo
;
import
com.liquidnet.service.kylin.entity.*
;
import
com.liquidnet.service.kylin.mapper.*
;
import
com.mongodb.BasicDBObject
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.mongodb.core.MongoTemplate
;
import
org.springframework.data.mongodb.core.convert.MongoConverter
;
import
org.springframework.data.mongodb.core.query.Criteria
;
import
org.springframework.data.mongodb.core.query.Query
;
import
org.springframework.stereotype.Component
;
import
java.math.BigDecimal
;
import
java.text.SimpleDateFormat
;
import
java.time.LocalDateTime
;
import
java.time.format.DateTimeFormatter
;
import
java.util.ArrayList
;
import
java.util.Comparator
;
import
java.util.HashMap
;
import
java.util.List
;
@Component
public
class
PerformanceVoUtils
{
@Autowired
private
MongoTemplate
mongoTemplate
;
@Autowired
private
MongoConverter
mongoConverter
;
@Autowired
private
RedisUtil
redisUtil
;
@Autowired
private
DataUtils
dataUtils
;
@Autowired
private
KylinPerformancesMapper
performancesMapper
;
@Autowired
private
KylinPerformanceStatusMapper
performanceStatusMapper
;
@Autowired
private
KylinPerformanceRelationsMapper
performanceRelationsMapper
;
@Autowired
private
KylinTicketsMapper
ticketsMapper
;
@Autowired
private
KylinTicketStatusMapper
ticketStatusMapper
;
@Autowired
private
KylinTicketRelationsMapper
ticketRelationsMapper
;
@Autowired
private
KylinTicketTimesMapper
ticketTimesMapper
;
@Autowired
private
KylinTicketTimeRelationMapper
ticketTimeRelationMapper
;
/**
* 根据票状态判断 演出状态 票状态
*
* @param performanceSingleId
*/
public
void
performanceVoStatus
(
String
performanceSingleId
)
{
LocalDateTime
timeNow
=
LocalDateTime
.
now
();
List
<
String
>
performanceIdList
=
new
ArrayList
<>();
if
(
performanceSingleId
.
isEmpty
())
{
List
<
KylinPerformanceVo
>
kylinPerformanceVoList
=
mongoTemplate
.
findAll
(
KylinPerformanceVo
.
class
);
for
(
KylinPerformanceVo
kylinPerformanceVoItem
:
kylinPerformanceVoList
)
{
performanceIdList
.
add
(
kylinPerformanceVoItem
.
getPerformancesId
());
}
}
else
{
performanceIdList
.
add
(
performanceSingleId
);
}
for
(
String
performancesId
:
performanceIdList
)
{
//场次
List
<
KylinTicketTimesVo
>
timesData
=
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"performanceId"
).
is
(
performancesId
)),
KylinTicketTimesVo
.
class
,
KylinTicketTimesVo
.
class
.
getSimpleName
()
);
if
(
timesData
.
size
()==
0
){
continue
;
}
//总循环次数
int
ticketCount
=
0
;
//未开售次数
int
status9Count
=
0
;
//售罄次数
int
status8Count
=
0
;
//已结束次数
int
status10Count
=
0
;
//缺票登记
int
isLackRegister
=
0
;
//会员
int
isMember
=
0
;
//专属
int
isExclusive
=
0
;
//提前
int
isAdvance
=
0
;
//优惠
int
isDiscount
=
0
;
//价格
BigDecimal
price
=
new
BigDecimal
(
"0.00"
);
LocalDateTime
stopSellTime
=
null
;
LocalDateTime
sellTime
=
null
;
//演出数据
HashMap
<
String
,
Object
>
mapPerformance
=
new
HashMap
<>();
int
appStatus
=
6
;
for
(
KylinTicketTimesVo
kylinTicketTimesVoItem
:
timesData
)
{
//票
List
<
KylinTicketVo
>
kylinTicketVoList
=
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"timeId"
).
is
(
kylinTicketTimesVoItem
.
getTimeId
())),
KylinTicketVo
.
class
,
KylinTicketVo
.
class
.
getSimpleName
()
);
ticketCount
+=
kylinTicketVoList
.
size
();
for
(
KylinTicketVo
kylinTicketVoItem
:
kylinTicketVoList
)
{
KylinTickets
tickets
=
ticketsMapper
.
selectOne
(
new
UpdateWrapper
<
KylinTickets
>().
eq
(
"tickets_id"
,
kylinTicketVoItem
.
getTicketsId
()
)
);
//时间判断
LocalDateTime
timeStart
=
LocalDateTime
.
parse
(
kylinTicketVoItem
.
getMemberTimeStart
(),
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
));
LocalDateTime
timeEnd
=
LocalDateTime
.
parse
(
kylinTicketVoItem
.
getTimeEnd
(),
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
));
int
status
=
0
;
if
(
timeStart
.
isAfter
(
timeNow
))
{
//未开始
status
=
9
;
status9Count
+=
1
;
}
else
if
(
timeEnd
.
isBefore
(
timeNow
))
{
//结束
status
=
10
;
status10Count
+=
1
;
}
else
{
//库存判断
int
surplusGeneral
=
dataUtils
.
getSurplusGeneral
(
kylinTicketVoItem
.
getTicketsId
());
if
(
surplusGeneral
>
0
)
{
status
=
6
;
}
else
{
status
=
8
;
status8Count
+=
1
;
}
}
//修改票状态
HashMap
<
String
,
Object
>
mapTicket
=
new
HashMap
<>();
mapTicket
.
put
(
"status"
,
status
);
BasicDBObject
objectTicket
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
mapTicket
));
mongoTemplate
.
getCollection
(
KylinTicketVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"ticketsId"
).
is
(
kylinTicketVoItem
.
getTicketsId
())).
getQueryObject
(),
objectTicket
);
//演出状态
if
(
status
==
6
)
{
//单一票 可购买 则为可购买
appStatus
=
6
;
}
else
if
(
ticketCount
==
status8Count
)
{
//全票售罄为售罄
appStatus
=
8
;
}
else
if
(
ticketCount
==
status9Count
)
{
//全票未开始 为未开始
appStatus
=
9
;
}
else
if
(
ticketCount
==
status10Count
)
{
//全票结束 为结束
appStatus
=
10
;
}
if
(
kylinTicketVoItem
.
getIsMember
()
==
1
)
{
if
(
kylinTicketVoItem
.
getMemberPrice
().
compareTo
(
kylinTicketVoItem
.
getPrice
())
!=
0
)
{
isDiscount
=
1
;
}
if
(!
kylinTicketVoItem
.
getTimeStart
().
equalsIgnoreCase
(
kylinTicketVoItem
.
getMemberTimeStart
()))
{
isAdvance
=
1
;
}
if
(
kylinTicketVoItem
.
getIsMember
()
==
1
)
{
isMember
=
1
;
}
if
(
kylinTicketVoItem
.
getIsExclusive
()
==
1
)
{
isExclusive
=
1
;
}
}
if
(
kylinTicketVoItem
.
getIsLackRegister
()
==
1
)
{
isLackRegister
=
1
;
}
if
(
price
.
subtract
(
kylinTicketVoItem
.
getMemberPrice
()).
compareTo
(
new
BigDecimal
(
"0.00"
))
<
0
)
{
price
=
kylinTicketVoItem
.
getMemberPrice
();
}
if
(
stopSellTime
==
null
||
stopSellTime
.
isBefore
(
tickets
.
getTimeEnd
()))
{
stopSellTime
=
tickets
.
getTimeEnd
();
}
if
(
sellTime
==
null
||
sellTime
.
isAfter
(
tickets
.
getTimeStart
().
plusMinutes
(-
tickets
.
getAdvanceMinuteMember
())))
{
sellTime
=
tickets
.
getTimeStart
().
plusMinutes
(-
tickets
.
getAdvanceMinuteMember
());
}
}
}
//修改演出状态
mapPerformance
.
put
(
"appStatus"
,
appStatus
);
mapPerformance
.
put
(
"isLackRegister"
,
isLackRegister
);
mapPerformance
.
put
(
"isExclusive"
,
isExclusive
);
mapPerformance
.
put
(
"isMember"
,
isMember
);
mapPerformance
.
put
(
"isAdvance"
,
isAdvance
);
mapPerformance
.
put
(
"isDiscount"
,
isDiscount
);
mapPerformance
.
put
(
"sellTime"
,
sellTime
.
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
)));
mapPerformance
.
put
(
"stopSellTime"
,
stopSellTime
.
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd HH:mm:ss"
)));
mapPerformance
.
put
(
"price"
,
price
+
"起"
);
BasicDBObject
objectPerformance
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
mapPerformance
));
mongoTemplate
.
getCollection
(
KylinPerformanceVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performancesId
)).
getQueryObject
(),
objectPerformance
);
}
}
/**
* 生成 PerformanceCreatePartnerVo(用于审核第一次提交数据)
*
* @param performancesId
* @return
*/
public
KylinPerformanceMisVo
getPerformanceMisVo
(
String
performancesId
)
{
PerformancePartnerVo
performanceData
=
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performancesId
)),
PerformancePartnerVo
.
class
,
PerformancePartnerVo
.
class
.
getSimpleName
());
List
<
KylinTicketTimesPartnerVo
>
kylinTicketTimesPartnerVos
=
getTimesMongoList
(
performancesId
);
List
<
TicketTimesTicketCreatePartnerVo
>
ticketTimesTicketCreatePartnerVoList
=
new
ArrayList
<
TicketTimesTicketCreatePartnerVo
>();
ArrayList
<
BigDecimal
>
floatList
=
new
ArrayList
<>();
ArrayList
<
String
>
StringList
=
new
ArrayList
<>();
for
(
KylinTicketTimesPartnerVo
ticketTimes
:
kylinTicketTimesPartnerVos
)
{
TicketTimesTicketCreatePartnerVo
ticketTimesTicketCreatePartnerVo
=
new
TicketTimesTicketCreatePartnerVo
();
BeanUtils
.
copyProperties
(
ticketTimes
,
ticketTimesTicketCreatePartnerVo
);
List
<
KylinTicketPartnerVo
>
kylinTicketPartnerVos
=
getTicketMongoList
(
ticketTimes
.
getTicketTimesId
());
ticketTimesTicketCreatePartnerVo
.
setTicket
(
kylinTicketPartnerVos
);
ticketTimesTicketCreatePartnerVoList
.
add
(
ticketTimesTicketCreatePartnerVo
);
for
(
KylinTicketPartnerVo
kylinTicketPartnerVoItem
:
kylinTicketPartnerVos
)
{
floatList
.
add
(
kylinTicketPartnerVoItem
.
getPrice
());
StringList
.
add
(
kylinTicketPartnerVoItem
.
getTimeEnd
());
}
}
KylinPerformanceMisVo
kylinPerformanceMisVo
=
new
KylinPerformanceMisVo
();
BeanUtils
.
copyProperties
(
performanceData
,
kylinPerformanceMisVo
);
floatList
.
sort
(
Comparator
.
reverseOrder
());
StringList
.
sort
(
Comparator
.
naturalOrder
());
kylinPerformanceMisVo
.
setPrice
(
floatList
.
get
(
0
)
+
"起"
);
kylinPerformanceMisVo
.
setStopSellTime
(
StringList
.
get
(
0
));
kylinPerformanceMisVo
.
setTicketTimes
(
ticketTimesTicketCreatePartnerVoList
);
// if (performanceMisVo.getStatus() != 0) {
// performanceMisVo.setStatus(null);
// performanceMisVo.setStatusSell(null);
// performanceMisVo.setRejectTxt("");
// performanceMisVo.setIsShow(1);
kylinPerformanceMisVo
.
setIsDistribution
(
0
);
kylinPerformanceMisVo
.
setSyncAgent
(
0
);
kylinPerformanceMisVo
.
setAuditStatus
(
0
);
// }
// boolean exists = mongoTemplate.exists(Query.query(Criteria.where("performancesId").is(performancesId)), PerformanceMisVo.class, PerformanceMisVo.class.getSimpleName());
//
// if (!exists) {
// PerformanceMisVo data = mongoTemplate.insert(
// performanceMisVo, PerformanceMisVo.class.getSimpleName()
// );
// }
return
kylinPerformanceMisVo
;
}
/**
* 修改数据库
*
* @param performancesId
* @param map
* @param performanceUpdateMisVo
* @param updatedAt
*/
public
void
updatePerformanceMySql
(
String
performancesId
,
HashMap
<
String
,
Object
>
map
,
KylinPerformanceMisVo
performanceUpdateMisVo
,
LocalDateTime
updatedAt
,
Integer
auditStatus
)
{
try
{
//创建演出
KylinPerformances
performances
=
new
KylinPerformances
();
BeanUtils
.
copyProperties
(
performanceUpdateMisVo
,
performances
);
KylinPerformanceStatus
performanceStatus
=
new
KylinPerformanceStatus
();
BeanUtils
.
copyProperties
(
performanceUpdateMisVo
,
performanceStatus
);
KylinPerformanceRelations
performanceRelations
=
new
KylinPerformanceRelations
();
BeanUtils
.
copyProperties
(
performanceUpdateMisVo
,
performanceRelations
);
performances
.
setCreatedAt
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
performanceUpdateMisVo
.
getCreatedAt
())));
performances
.
setTimeStart
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
performanceUpdateMisVo
.
getTimeStart
())));
performances
.
setTimeEnd
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
performanceUpdateMisVo
.
getTimeEnd
())));
performances
.
setUpdatedAt
(
updatedAt
);
performanceStatus
.
setPerformanceId
(
performances
.
getPerformancesId
());
performanceStatus
.
setPerformanceStatusId
(
IDGenerator
.
nextSnowId
().
toString
());
performanceStatus
.
setCreatedAt
(
null
);
performanceStatus
.
setStatus
(
null
);
performanceStatus
.
setStatusSell
(
null
);
performanceStatus
.
setAuditStatus
(
auditStatus
);
performanceStatus
.
setUpdatedAt
(
updatedAt
);
performanceRelations
.
setPerformanceId
(
performances
.
getPerformancesId
());
performanceRelations
.
setPerformanceRelationsId
(
IDGenerator
.
nextSnowId
().
toString
());
performanceRelations
.
setCreatedAt
(
null
);
performanceRelations
.
setUpdatedAt
(
updatedAt
);
performancesMapper
.
update
(
performances
,
new
UpdateWrapper
<
KylinPerformances
>().
eq
(
"performances_id"
,
performances
.
getPerformancesId
()));
performanceStatusMapper
.
update
(
performanceStatus
,
new
UpdateWrapper
<
KylinPerformanceStatus
>().
eq
(
"performance_id"
,
performances
.
getPerformancesId
()));
performanceRelationsMapper
.
update
(
performanceRelations
,
new
UpdateWrapper
<
KylinPerformanceRelations
>().
eq
(
"performance_id"
,
performances
.
getPerformancesId
()));
//场次数据
List
<
KylinTicketTimesPartnerVo
>
kylinTicketTimesPartnerVos
=
getTimesMongoList
(
performancesId
);
for
(
KylinTicketTimesPartnerVo
ticketTimeItem
:
kylinTicketTimesPartnerVos
)
{
//创建场次
KylinTicketTimes
ticketTimes
=
new
KylinTicketTimes
();
BeanUtils
.
copyProperties
(
ticketTimeItem
,
ticketTimes
);
KylinTicketTimeRelation
ticketTimeRelation
=
new
KylinTicketTimeRelation
();
BeanUtils
.
copyProperties
(
ticketTimeItem
,
ticketTimeRelation
);
ticketTimes
.
setUseStart
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketTimeItem
.
getUseStart
())));
ticketTimes
.
setUseEnd
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketTimeItem
.
getUseEnd
())));
ticketTimes
.
setCreatedAt
(
null
);
ticketTimes
.
setUpdatedAt
(
updatedAt
);
ticketTimeRelation
.
setPerformanceId
(
performancesId
);
ticketTimeRelation
.
setTicketTimeRelationId
(
IDGenerator
.
nextSnowId
().
toString
());
ticketTimeRelation
.
setTimesId
(
ticketTimes
.
getTicketTimesId
());
ticketTimeRelation
.
setCreatedAt
(
null
);
ticketTimeRelation
.
setUpdatedAt
(
updatedAt
);
if
(
ticketTimeItem
.
getStatus
()
==
-
1
)
{
ticketTimes
.
setStatus
(
1
);
ticketTimesMapper
.
insert
(
ticketTimes
);
ticketTimeRelationMapper
.
insert
(
ticketTimeRelation
);
KylinTicketTimesVo
kylinTicketTimesVo
=
new
KylinTicketTimesVo
();
kylinTicketTimesVo
.
setTicketTimes
(
ticketTimes
);
kylinTicketTimesVo
.
setPerformanceId
(
ticketTimeRelation
.
getPerformanceId
());
kylinTicketTimesVo
.
setTimeId
(
ticketTimeRelation
.
getTimesId
());
// HashMap<String ,Object> map2 = new HashMap<>();
// map2.put("status",1);
// BasicDBObject obj = new BasicDBObject("$set", mongoConverter.convertToMongoType(map2));
// mongoTemplate.getCollection(TicketTimesPartnerVo.class.getSimpleName()).updateOne(
// Query.query(Criteria.where("ticketTimesId").is(ticketTimes.getTicketTimesId())).getQueryObject(),
// obj
// );
boolean
ticketTimesExists
=
mongoTemplate
.
exists
(
Query
.
query
(
Criteria
.
where
(
"ticketTimesId"
).
is
(
kylinTicketTimesVo
.
getTicketTimesId
())),
KylinTicketTimesVo
.
class
,
KylinTicketTimesVo
.
class
.
getSimpleName
());
if
(!
ticketTimesExists
)
{
mongoTemplate
.
insert
(
kylinTicketTimesVo
,
KylinTicketTimesVo
.
class
.
getSimpleName
()
);
}
}
else
{
ticketTimesMapper
.
update
(
ticketTimes
,
new
UpdateWrapper
<
KylinTicketTimes
>().
eq
(
"ticket_times_id"
,
ticketTimes
.
getTicketTimesId
()));
ticketTimeRelationMapper
.
update
(
ticketTimeRelation
,
new
UpdateWrapper
<
KylinTicketTimeRelation
>().
eq
(
"times_id"
,
ticketTimes
.
getTicketTimesId
()));
}
//修改票
for
(
KylinTicketPartnerVo
ticketItem
:
getTicketMongoList
(
ticketTimeItem
.
getTicketTimesId
()))
{
KylinTicketPartnerVo
kylinTicketPartnerVo
;
kylinTicketPartnerVo
=
mongoTemplate
.
findOne
(
Query
.
query
(
Criteria
.
where
(
"ticketsId"
).
is
(
ticketItem
.
getTicketsId
())),
KylinTicketPartnerVo
.
class
,
KylinTicketPartnerVo
.
class
.
getSimpleName
()
);
//创建演出
KylinTickets
tickets
=
new
KylinTickets
();
BeanUtils
.
copyProperties
(
kylinTicketPartnerVo
,
tickets
);
KylinTicketStatus
ticketStatus
=
new
KylinTicketStatus
();
BeanUtils
.
copyProperties
(
kylinTicketPartnerVo
,
ticketStatus
);
KylinTicketRelations
ticketRelations
=
new
KylinTicketRelations
();
BeanUtils
.
copyProperties
(
kylinTicketPartnerVo
,
ticketRelations
);
tickets
.
setPriceExpress
(
new
BigDecimal
(
"0.00"
));
tickets
.
setPriceDiscountMember
(
new
BigDecimal
(
"0.00"
));
tickets
.
setPriceDiscount
(
new
BigDecimal
(
"0.00"
));
tickets
.
setTimeStart
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketItem
.
getTimeStart
())));
tickets
.
setTimeEnd
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketItem
.
getTimeEnd
())));
if
(
ticketItem
.
getIsExpress
()
==
1
)
{
tickets
.
setTimeEndExpress
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketItem
.
getTimeEndExpress
())));
}
tickets
.
setUseStart
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketTimeItem
.
getUseStart
())));
tickets
.
setUseEnd
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketTimeItem
.
getUseEnd
())));
tickets
.
setSaleRemindMinute
(
60
);
tickets
.
setUpdatedAt
(
updatedAt
);
ticketStatus
.
setTicketStatusId
(
IDGenerator
.
nextSnowId
().
toString
());
ticketStatus
.
setTicketId
(
tickets
.
getTicketsId
());
ticketStatus
.
setStatusExchange
(
7
);
if
(
ticketItem
.
getIsShowCode
()
==
1
)
{
ticketStatus
.
setQrCodeShowTime
(
DateUtil
.
asLocalDateTime
(
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
).
parse
(
ticketItem
.
getQrCodeShowTime
())));
}
ticketRelations
.
setUpdatedAt
(
updatedAt
);
ticketRelations
.
setTicketRelationsId
(
IDGenerator
.
nextSnowId
().
toString
());
ticketRelations
.
setTicketId
(
tickets
.
getTicketsId
());
ticketRelations
.
setUpdatedAt
(
updatedAt
);
if
(
ticketItem
.
getStatus
()
==
-
2
)
{
// ticketStatus.setLimitCount(null);
// ticketStatus.setTotalGeneral(null);
// ticketStatus.setTotalExchange(null);
// tickets.setTimeStart(null);
// tickets.setTimeEnd(null);
tickets
.
setAdvanceMinuteMember
(
5
);
ticketStatus
.
setIsMember
(
1
);
ticketRelations
.
setCreatedAt
(
LocalDateTime
.
now
());
tickets
.
setCreatedAt
(
LocalDateTime
.
now
());
ticketsMapper
.
insert
(
tickets
);
ticketStatus
.
setStatus
(
9
);
ticketStatusMapper
.
insert
(
ticketStatus
);
ticketRelationsMapper
.
insert
(
ticketRelations
);
KylinTicketVo
kylinTicketVo
=
new
KylinTicketVo
();
kylinTicketVo
.
setTimeId
(
ticketRelations
.
getTimesId
());
kylinTicketVo
.
setTicket
(
tickets
);
kylinTicketVo
.
setTicketStatus
(
ticketStatus
);
dataUtils
.
setSurplusExchange
(
kylinTicketVo
.
getTicketsId
(),
ticketStatus
.
getSurplusExchange
());
dataUtils
.
setSurplusGeneral
(
kylinTicketVo
.
getTicketsId
(),
ticketStatus
.
getSurplusGeneral
());
BasicDBObject
objectTicketVo
=
new
BasicDBObject
(
"$set"
,
mongoConverter
.
convertToMongoType
(
map
));
mongoTemplate
.
getCollection
(
KylinTicketPartnerVo
.
class
.
getSimpleName
()).
updateOne
(
Query
.
query
(
Criteria
.
where
(
"ticketsId"
).
is
(
ticketItem
.
getTicketsId
())).
getQueryObject
(),
objectTicketVo
);
boolean
ticketExists
=
mongoTemplate
.
exists
(
Query
.
query
(
Criteria
.
where
(
"ticketsId"
).
is
(
kylinTicketVo
.
getTicketsId
())),
KylinTicketVo
.
class
,
KylinTicketVo
.
class
.
getSimpleName
());
if
(!
ticketExists
)
{
mongoTemplate
.
insert
(
kylinTicketVo
,
KylinTicketVo
.
class
.
getSimpleName
()
);
}
}
else
{
//不改动数据 价格 限购 购票时间
ticketStatus
.
setLimitCount
(
null
);
ticketStatus
.
setTotalGeneral
(
null
);
ticketStatus
.
setTotalExchange
(
null
);
tickets
.
setTimeStart
(
null
);
tickets
.
setTimeEnd
(
null
);
ticketStatus
.
setCounts
(
null
);
ticketStatus
.
setIsMember
(
null
);
ticketRelations
.
setCreatedAt
(
null
);
tickets
.
setCreatedAt
(
null
);
ticketsMapper
.
update
(
tickets
,
new
UpdateWrapper
<
KylinTickets
>().
eq
(
"tickets_id"
,
tickets
.
getTicketsId
()));
ticketStatusMapper
.
update
(
ticketStatus
,
new
UpdateWrapper
<
KylinTicketStatus
>().
eq
(
"ticket_id"
,
tickets
.
getTicketsId
()));
ticketRelationsMapper
.
update
(
ticketRelations
,
new
UpdateWrapper
<
KylinTicketRelations
>().
eq
(
"ticket_id"
,
tickets
.
getTicketsId
()));
}
}
}
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
public
List
<
KylinTicketPartnerVo
>
getTicketMongoList
(
String
timesId
)
{
return
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"timesId"
).
is
(
timesId
)),
KylinTicketPartnerVo
.
class
,
KylinTicketPartnerVo
.
class
.
getSimpleName
());
}
public
List
<
KylinTicketTimesPartnerVo
>
getTimesMongoList
(
String
performancesId
)
{
return
mongoTemplate
.
find
(
Query
.
query
(
Criteria
.
where
(
"performancesId"
).
is
(
performancesId
)),
KylinTicketTimesPartnerVo
.
class
,
KylinTicketTimesPartnerVo
.
class
.
getSimpleName
());
}
}
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/resources/mapper/zhengzai/kylin/KylinOrderTicketsMapper.xml
deleted
100644 → 0
View file @
3d0e62cc
<?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=
"com.liquidnet.client.admin.zhengzai.kylin.mapper.KylinOrderTicketsMapper"
>
<resultMap
type=
"KylinOrderTickets"
id=
"KylinOrderTicketsResult"
>
<result
property=
"mid"
column=
"mid"
/>
<result
property=
"orderTicketsId"
column=
"order_tickets_id"
/>
<result
property=
"userId"
column=
"user_id"
/>
<result
property=
"userName"
column=
"user_name"
/>
<result
property=
"userMobile"
column=
"user_mobile"
/>
<result
property=
"performanceTitle"
column=
"performance_title"
/>
<result
property=
"orderCode"
column=
"order_code"
/>
<result
property=
"qrCode"
column=
"qr_code"
/>
<result
property=
"orderType"
column=
"order_type"
/>
<result
property=
"orderVersion"
column=
"order_version"
/>
<result
property=
"number"
column=
"number"
/>
<result
property=
"price"
column=
"price"
/>
<result
property=
"priceMember"
column=
"price_member"
/>
<result
property=
"priceTotal"
column=
"price_total"
/>
<result
property=
"priceVoucher"
column=
"price_voucher"
/>
<result
property=
"priceActual"
column=
"price_actual"
/>
<result
property=
"priceExpress"
column=
"price_express"
/>
<result
property=
"priceRefund"
column=
"price_refund"
/>
<result
property=
"priceNumber"
column=
"price_number"
/>
<result
property=
"payType"
column=
"pay_type"
/>
<result
property=
"paymentType"
column=
"payment_type"
/>
<result
property=
"timePay"
column=
"time_pay"
/>
<result
property=
"expressContacts"
column=
"express_contacts"
/>
<result
property=
"expressAddress"
column=
"express_address"
/>
<result
property=
"expressPhone"
column=
"express_phone"
/>
<result
property=
"couponType"
column=
"coupon_type"
/>
<result
property=
"getTicketType"
column=
"get_ticket_type"
/>
<result
property=
"getTicketDescribe"
column=
"get_ticket_describe"
/>
<result
property=
"payCountdownMinute"
column=
"pay_countdown_minute"
/>
<result
property=
"comment"
column=
"comment"
/>
<result
property=
"createdAt"
column=
"created_at"
/>
<result
property=
"updatedAt"
column=
"updated_at"
/>
</resultMap>
<sql
id=
"selectKylinOrderTicketsVo"
>
select mid, order_tickets_id, user_id, user_name, user_mobile, performance_title, order_code, qr_code, order_type, order_version, number, price, price_member, price_total, price_voucher, price_actual, price_express, price_refund, price_number, pay_type, payment_type, time_pay, express_contacts, express_address, express_phone, coupon_type, get_ticket_type, get_ticket_describe, pay_countdown_minute, comment, created_at, updated_at from kylin_order_tickets
</sql>
<select
id=
"selectKylinOrderTicketsList"
parameterType=
"KylinOrderTickets"
resultMap=
"KylinOrderTicketsResult"
>
<include
refid=
"selectKylinOrderTicketsVo"
/>
<where>
<if
test=
"orderTicketsId != null and orderTicketsId != ''"
>
and order_tickets_id = #{orderTicketsId}
</if>
<if
test=
"userId != null and userId != ''"
>
and user_id = #{userId}
</if>
<if
test=
"userName != null and userName != ''"
>
and user_name like concat('%', #{userName}, '%')
</if>
<if
test=
"userMobile != null and userMobile != ''"
>
and user_mobile = #{userMobile}
</if>
<if
test=
"performanceTitle != null and performanceTitle != ''"
>
and performance_title = #{performanceTitle}
</if>
<if
test=
"orderCode != null and orderCode != ''"
>
and order_code = #{orderCode}
</if>
<if
test=
"qrCode != null and qrCode != ''"
>
and qr_code = #{qrCode}
</if>
<if
test=
"orderType != null and orderType != ''"
>
and order_type = #{orderType}
</if>
<if
test=
"orderVersion != null and orderVersion != ''"
>
and order_version = #{orderVersion}
</if>
<if
test=
"number != null and number != ''"
>
and number = #{number}
</if>
<if
test=
"price != null "
>
and price = #{price}
</if>
<if
test=
"priceMember != null "
>
and price_member = #{priceMember}
</if>
<if
test=
"priceTotal != null "
>
and price_total = #{priceTotal}
</if>
<if
test=
"priceVoucher != null "
>
and price_voucher = #{priceVoucher}
</if>
<if
test=
"priceActual != null "
>
and price_actual = #{priceActual}
</if>
<if
test=
"priceExpress != null "
>
and price_express = #{priceExpress}
</if>
<if
test=
"priceRefund != null "
>
and price_refund = #{priceRefund}
</if>
<if
test=
"priceNumber != null "
>
and price_number = #{priceNumber}
</if>
<if
test=
"payType != null and payType != ''"
>
and pay_type = #{payType}
</if>
<if
test=
"paymentType != null and paymentType != ''"
>
and payment_type = #{paymentType}
</if>
<if
test=
"timePay != null and timePay != ''"
>
and time_pay = #{timePay}
</if>
<if
test=
"expressContacts != null and expressContacts != ''"
>
and express_contacts = #{expressContacts}
</if>
<if
test=
"expressAddress != null and expressAddress != ''"
>
and express_address = #{expressAddress}
</if>
<if
test=
"expressPhone != null and expressPhone != ''"
>
and express_phone = #{expressPhone}
</if>
<if
test=
"couponType != null and couponType != ''"
>
and coupon_type = #{couponType}
</if>
<if
test=
"getTicketType != null and getTicketType != ''"
>
and get_ticket_type = #{getTicketType}
</if>
<if
test=
"getTicketDescribe != null and getTicketDescribe != ''"
>
and get_ticket_describe = #{getTicketDescribe}
</if>
<if
test=
"payCountdownMinute != null and payCountdownMinute != ''"
>
and pay_countdown_minute = #{payCountdownMinute}
</if>
<if
test=
"comment != null and comment != ''"
>
and comment = #{comment}
</if>
<if
test=
"createdAt != null "
>
and created_at = #{createdAt}
</if>
<if
test=
"updatedAt != null "
>
and updated_at = #{updatedAt}
</if>
</where>
</select>
<select
id=
"selectKylinOrderTicketsById"
parameterType=
"Integer"
resultMap=
"KylinOrderTicketsResult"
>
<include
refid=
"selectKylinOrderTicketsVo"
/>
where mid = #{mid}
</select>
<insert
id=
"insertKylinOrderTickets"
parameterType=
"KylinOrderTickets"
useGeneratedKeys=
"true"
keyProperty=
"mid"
>
insert into kylin_order_tickets
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"orderTicketsId != null and orderTicketsId != ''"
>
order_tickets_id,
</if>
<if
test=
"userId != null and userId != ''"
>
user_id,
</if>
<if
test=
"userName != null and userName != ''"
>
user_name,
</if>
<if
test=
"userMobile != null and userMobile != ''"
>
user_mobile,
</if>
<if
test=
"performanceTitle != null and performanceTitle != ''"
>
performance_title,
</if>
<if
test=
"orderCode != null and orderCode != ''"
>
order_code,
</if>
<if
test=
"qrCode != null and qrCode != ''"
>
qr_code,
</if>
<if
test=
"orderType != null and orderType != ''"
>
order_type,
</if>
<if
test=
"orderVersion != null and orderVersion != ''"
>
order_version,
</if>
<if
test=
"number != null and number != ''"
>
number,
</if>
<if
test=
"price != null"
>
price,
</if>
<if
test=
"priceMember != null"
>
price_member,
</if>
<if
test=
"priceTotal != null"
>
price_total,
</if>
<if
test=
"priceVoucher != null"
>
price_voucher,
</if>
<if
test=
"priceActual != null"
>
price_actual,
</if>
<if
test=
"priceExpress != null"
>
price_express,
</if>
<if
test=
"priceRefund != null"
>
price_refund,
</if>
<if
test=
"priceNumber != null"
>
price_number,
</if>
<if
test=
"payType != null and payType != ''"
>
pay_type,
</if>
<if
test=
"paymentType != null and paymentType != ''"
>
payment_type,
</if>
<if
test=
"timePay != null and timePay != ''"
>
time_pay,
</if>
<if
test=
"expressContacts != null and expressContacts != ''"
>
express_contacts,
</if>
<if
test=
"expressAddress != null and expressAddress != ''"
>
express_address,
</if>
<if
test=
"expressPhone != null and expressPhone != ''"
>
express_phone,
</if>
<if
test=
"couponType != null and couponType != ''"
>
coupon_type,
</if>
<if
test=
"getTicketType != null and getTicketType != ''"
>
get_ticket_type,
</if>
<if
test=
"getTicketDescribe != null and getTicketDescribe != ''"
>
get_ticket_describe,
</if>
<if
test=
"payCountdownMinute != null and payCountdownMinute != ''"
>
pay_countdown_minute,
</if>
<if
test=
"comment != null and comment != ''"
>
comment,
</if>
<if
test=
"createdAt != null"
>
created_at,
</if>
<if
test=
"updatedAt != null"
>
updated_at,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"orderTicketsId != null and orderTicketsId != ''"
>
#{orderTicketsId},
</if>
<if
test=
"userId != null and userId != ''"
>
#{userId},
</if>
<if
test=
"userName != null and userName != ''"
>
#{userName},
</if>
<if
test=
"userMobile != null and userMobile != ''"
>
#{userMobile},
</if>
<if
test=
"performanceTitle != null and performanceTitle != ''"
>
#{performanceTitle},
</if>
<if
test=
"orderCode != null and orderCode != ''"
>
#{orderCode},
</if>
<if
test=
"qrCode != null and qrCode != ''"
>
#{qrCode},
</if>
<if
test=
"orderType != null and orderType != ''"
>
#{orderType},
</if>
<if
test=
"orderVersion != null and orderVersion != ''"
>
#{orderVersion},
</if>
<if
test=
"number != null and number != ''"
>
#{number},
</if>
<if
test=
"price != null"
>
#{price},
</if>
<if
test=
"priceMember != null"
>
#{priceMember},
</if>
<if
test=
"priceTotal != null"
>
#{priceTotal},
</if>
<if
test=
"priceVoucher != null"
>
#{priceVoucher},
</if>
<if
test=
"priceActual != null"
>
#{priceActual},
</if>
<if
test=
"priceExpress != null"
>
#{priceExpress},
</if>
<if
test=
"priceRefund != null"
>
#{priceRefund},
</if>
<if
test=
"priceNumber != null"
>
#{priceNumber},
</if>
<if
test=
"payType != null and payType != ''"
>
#{payType},
</if>
<if
test=
"paymentType != null and paymentType != ''"
>
#{paymentType},
</if>
<if
test=
"timePay != null and timePay != ''"
>
#{timePay},
</if>
<if
test=
"expressContacts != null and expressContacts != ''"
>
#{expressContacts},
</if>
<if
test=
"expressAddress != null and expressAddress != ''"
>
#{expressAddress},
</if>
<if
test=
"expressPhone != null and expressPhone != ''"
>
#{expressPhone},
</if>
<if
test=
"couponType != null and couponType != ''"
>
#{couponType},
</if>
<if
test=
"getTicketType != null and getTicketType != ''"
>
#{getTicketType},
</if>
<if
test=
"getTicketDescribe != null and getTicketDescribe != ''"
>
#{getTicketDescribe},
</if>
<if
test=
"payCountdownMinute != null and payCountdownMinute != ''"
>
#{payCountdownMinute},
</if>
<if
test=
"comment != null and comment != ''"
>
#{comment},
</if>
<if
test=
"createdAt != null"
>
#{createdAt},
</if>
<if
test=
"updatedAt != null"
>
#{updatedAt},
</if>
</trim>
</insert>
<update
id=
"updateKylinOrderTickets"
parameterType=
"KylinOrderTickets"
>
update kylin_order_tickets
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"orderTicketsId != null and orderTicketsId != ''"
>
order_tickets_id = #{orderTicketsId},
</if>
<if
test=
"userId != null and userId != ''"
>
user_id = #{userId},
</if>
<if
test=
"userName != null and userName != ''"
>
user_name = #{userName},
</if>
<if
test=
"userMobile != null and userMobile != ''"
>
user_mobile = #{userMobile},
</if>
<if
test=
"performanceTitle != null and performanceTitle != ''"
>
performance_title = #{performanceTitle},
</if>
<if
test=
"orderCode != null and orderCode != ''"
>
order_code = #{orderCode},
</if>
<if
test=
"qrCode != null and qrCode != ''"
>
qr_code = #{qrCode},
</if>
<if
test=
"orderType != null and orderType != ''"
>
order_type = #{orderType},
</if>
<if
test=
"orderVersion != null and orderVersion != ''"
>
order_version = #{orderVersion},
</if>
<if
test=
"number != null and number != ''"
>
number = #{number},
</if>
<if
test=
"price != null"
>
price = #{price},
</if>
<if
test=
"priceMember != null"
>
price_member = #{priceMember},
</if>
<if
test=
"priceTotal != null"
>
price_total = #{priceTotal},
</if>
<if
test=
"priceVoucher != null"
>
price_voucher = #{priceVoucher},
</if>
<if
test=
"priceActual != null"
>
price_actual = #{priceActual},
</if>
<if
test=
"priceExpress != null"
>
price_express = #{priceExpress},
</if>
<if
test=
"priceRefund != null"
>
price_refund = #{priceRefund},
</if>
<if
test=
"priceNumber != null"
>
price_number = #{priceNumber},
</if>
<if
test=
"payType != null and payType != ''"
>
pay_type = #{payType},
</if>
<if
test=
"paymentType != null and paymentType != ''"
>
payment_type = #{paymentType},
</if>
<if
test=
"timePay != null and timePay != ''"
>
time_pay = #{timePay},
</if>
<if
test=
"expressContacts != null and expressContacts != ''"
>
express_contacts = #{expressContacts},
</if>
<if
test=
"expressAddress != null and expressAddress != ''"
>
express_address = #{expressAddress},
</if>
<if
test=
"expressPhone != null and expressPhone != ''"
>
express_phone = #{expressPhone},
</if>
<if
test=
"couponType != null and couponType != ''"
>
coupon_type = #{couponType},
</if>
<if
test=
"getTicketType != null and getTicketType != ''"
>
get_ticket_type = #{getTicketType},
</if>
<if
test=
"getTicketDescribe != null and getTicketDescribe != ''"
>
get_ticket_describe = #{getTicketDescribe},
</if>
<if
test=
"payCountdownMinute != null and payCountdownMinute != ''"
>
pay_countdown_minute = #{payCountdownMinute},
</if>
<if
test=
"comment != null and comment != ''"
>
comment = #{comment},
</if>
<if
test=
"createdAt != null"
>
created_at = #{createdAt},
</if>
<if
test=
"updatedAt != null"
>
updated_at = #{updatedAt},
</if>
</trim>
where mid = #{mid}
</update>
<delete
id=
"deleteKylinOrderTicketsById"
parameterType=
"Integer"
>
delete from kylin_order_tickets where mid = #{mid}
</delete>
<delete
id=
"deleteKylinOrderTicketsByIds"
parameterType=
"String"
>
delete from kylin_order_tickets where mid in
<foreach
item=
"mid"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{mid}
</foreach>
</delete>
</mapper>
\ No newline at end of file
liquidnet-bus-client/liquidnet-client-admin/liquidnet-client-admin-zhengzai/src/main/resources/mapper/zhengzai/kylin/KylinPerformancesMapper.xml
deleted
100644 → 0
View file @
3d0e62cc
<?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=
"com.liquidnet.client.admin.zhengzai.kylin.mapper.KylinPerformancesMapper"
>
<resultMap
type=
"KylinPerformances"
id=
"KylinPerformancesResult"
>
<result
property=
"mid"
column=
"mid"
/>
<result
property=
"performancesId"
column=
"performances_id"
/>
<result
property=
"title"
column=
"title"
/>
<result
property=
"type"
column=
"type"
/>
<result
property=
"imgPoster"
column=
"img_poster"
/>
<result
property=
"provinceId"
column=
"province_id"
/>
<result
property=
"provinceName"
column=
"province_name"
/>
<result
property=
"cityId"
column=
"city_id"
/>
<result
property=
"cityName"
column=
"city_name"
/>
<result
property=
"districtId"
column=
"district_id"
/>
<result
property=
"districtName"
column=
"district_name"
/>
<result
property=
"approvalUrl"
column=
"approval_url"
/>
<result
property=
"notice"
column=
"notice"
/>
<result
property=
"sponsorId"
column=
"sponsor_id"
/>
<result
property=
"sponsorType"
column=
"sponsor_type"
/>
<result
property=
"sponsor"
column=
"sponsor"
/>
<result
property=
"contacts"
column=
"contacts"
/>
<result
property=
"mobile"
column=
"mobile"
/>
<result
property=
"describes"
column=
"describes"
/>
<result
property=
"details"
column=
"details"
/>
<result
property=
"noticeImage"
column=
"notice_image"
/>
<result
property=
"timeStart"
column=
"time_start"
/>
<result
property=
"timeEnd"
column=
"time_end"
/>
<result
property=
"auditTime"
column=
"audit_time"
/>
<result
property=
"rejectTxt"
column=
"reject_txt"
/>
<result
property=
"sort"
column=
"sort"
/>
<result
property=
"comment"
column=
"comment"
/>
<result
property=
"createdAt"
column=
"created_at"
/>
<result
property=
"updatedAt"
column=
"updated_at"
/>
</resultMap>
<sql
id=
"selectKylinPerformancesVo"
>
select mid, performances_id, title, type, img_poster, province_id, province_name, city_id, city_name, district_id, district_name, approval_url, notice, sponsor_id, sponsor_type, sponsor, contacts, mobile, describes, details, notice_image, time_start, time_end, audit_time, reject_txt, sort, comment, created_at, updated_at from kylin_performances
</sql>
<select
id=
"selectKylinPerformancesList"
parameterType=
"KylinPerformances"
resultMap=
"KylinPerformancesResult"
>
<include
refid=
"selectKylinPerformancesVo"
/>
<where>
<if
test=
"performancesId != null and performancesId != ''"
>
and performances_id = #{performancesId}
</if>
<if
test=
"title != null and title != ''"
>
and title = #{title}
</if>
<if
test=
"type != null "
>
and type = #{type}
</if>
<if
test=
"imgPoster != null and imgPoster != ''"
>
and img_poster = #{imgPoster}
</if>
<if
test=
"provinceId != null and provinceId != ''"
>
and province_id = #{provinceId}
</if>
<if
test=
"provinceName != null and provinceName != ''"
>
and province_name like concat('%', #{provinceName}, '%')
</if>
<if
test=
"cityId != null "
>
and city_id = #{cityId}
</if>
<if
test=
"cityName != null and cityName != ''"
>
and city_name like concat('%', #{cityName}, '%')
</if>
<if
test=
"districtId != null "
>
and district_id = #{districtId}
</if>
<if
test=
"districtName != null and districtName != ''"
>
and district_name like concat('%', #{districtName}, '%')
</if>
<if
test=
"approvalUrl != null and approvalUrl != ''"
>
and approval_url = #{approvalUrl}
</if>
<if
test=
"notice != null and notice != ''"
>
and notice = #{notice}
</if>
<if
test=
"sponsorId != null and sponsorId != ''"
>
and sponsor_id = #{sponsorId}
</if>
<if
test=
"sponsorType != null and sponsorType != ''"
>
and sponsor_type = #{sponsorType}
</if>
<if
test=
"sponsor != null and sponsor != ''"
>
and sponsor = #{sponsor}
</if>
<if
test=
"contacts != null and contacts != ''"
>
and contacts = #{contacts}
</if>
<if
test=
"mobile != null and mobile != ''"
>
and mobile = #{mobile}
</if>
<if
test=
"describes != null and describes != ''"
>
and describes = #{describes}
</if>
<if
test=
"details != null and details != ''"
>
and details = #{details}
</if>
<if
test=
"noticeImage != null and noticeImage != ''"
>
and notice_image = #{noticeImage}
</if>
<if
test=
"timeStart != null "
>
and time_start = #{timeStart}
</if>
<if
test=
"timeEnd != null "
>
and time_end = #{timeEnd}
</if>
<if
test=
"auditTime != null "
>
and audit_time = #{auditTime}
</if>
<if
test=
"rejectTxt != null and rejectTxt != ''"
>
and reject_txt = #{rejectTxt}
</if>
<if
test=
"sort != null "
>
and sort = #{sort}
</if>
<if
test=
"comment != null and comment != ''"
>
and comment = #{comment}
</if>
<if
test=
"createdAt != null "
>
and created_at = #{createdAt}
</if>
<if
test=
"updatedAt != null "
>
and updated_at = #{updatedAt}
</if>
</where>
</select>
<select
id=
"selectKylinPerformancesById"
parameterType=
"Long"
resultMap=
"KylinPerformancesResult"
>
<include
refid=
"selectKylinPerformancesVo"
/>
where mid = #{mid}
</select>
<insert
id=
"insertKylinPerformances"
parameterType=
"KylinPerformances"
useGeneratedKeys=
"true"
keyProperty=
"mid"
>
insert into kylin_performances
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"performancesId != null and performancesId != ''"
>
performances_id,
</if>
<if
test=
"title != null and title != ''"
>
title,
</if>
<if
test=
"type != null"
>
type,
</if>
<if
test=
"imgPoster != null and imgPoster != ''"
>
img_poster,
</if>
<if
test=
"provinceId != null and provinceId != ''"
>
province_id,
</if>
<if
test=
"provinceName != null and provinceName != ''"
>
province_name,
</if>
<if
test=
"cityId != null"
>
city_id,
</if>
<if
test=
"cityName != null and cityName != ''"
>
city_name,
</if>
<if
test=
"districtId != null"
>
district_id,
</if>
<if
test=
"districtName != null and districtName != ''"
>
district_name,
</if>
<if
test=
"approvalUrl != null and approvalUrl != ''"
>
approval_url,
</if>
<if
test=
"notice != null and notice != ''"
>
notice,
</if>
<if
test=
"sponsorId != null and sponsorId != ''"
>
sponsor_id,
</if>
<if
test=
"sponsorType != null and sponsorType != ''"
>
sponsor_type,
</if>
<if
test=
"sponsor != null and sponsor != ''"
>
sponsor,
</if>
<if
test=
"contacts != null and contacts != ''"
>
contacts,
</if>
<if
test=
"mobile != null and mobile != ''"
>
mobile,
</if>
<if
test=
"describes != null and describes != ''"
>
describes,
</if>
<if
test=
"details != null"
>
details,
</if>
<if
test=
"noticeImage != null"
>
notice_image,
</if>
<if
test=
"timeStart != null"
>
time_start,
</if>
<if
test=
"timeEnd != null"
>
time_end,
</if>
<if
test=
"auditTime != null"
>
audit_time,
</if>
<if
test=
"rejectTxt != null and rejectTxt != ''"
>
reject_txt,
</if>
<if
test=
"sort != null"
>
sort,
</if>
<if
test=
"comment != null and comment != ''"
>
comment,
</if>
<if
test=
"createdAt != null"
>
created_at,
</if>
<if
test=
"updatedAt != null"
>
updated_at,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"performancesId != null and performancesId != ''"
>
#{performancesId},
</if>
<if
test=
"title != null and title != ''"
>
#{title},
</if>
<if
test=
"type != null"
>
#{type},
</if>
<if
test=
"imgPoster != null and imgPoster != ''"
>
#{imgPoster},
</if>
<if
test=
"provinceId != null and provinceId != ''"
>
#{provinceId},
</if>
<if
test=
"provinceName != null and provinceName != ''"
>
#{provinceName},
</if>
<if
test=
"cityId != null"
>
#{cityId},
</if>
<if
test=
"cityName != null and cityName != ''"
>
#{cityName},
</if>
<if
test=
"districtId != null"
>
#{districtId},
</if>
<if
test=
"districtName != null and districtName != ''"
>
#{districtName},
</if>
<if
test=
"approvalUrl != null and approvalUrl != ''"
>
#{approvalUrl},
</if>
<if
test=
"notice != null and notice != ''"
>
#{notice},
</if>
<if
test=
"sponsorId != null and sponsorId != ''"
>
#{sponsorId},
</if>
<if
test=
"sponsorType != null and sponsorType != ''"
>
#{sponsorType},
</if>
<if
test=
"sponsor != null and sponsor != ''"
>
#{sponsor},
</if>
<if
test=
"contacts != null and contacts != ''"
>
#{contacts},
</if>
<if
test=
"mobile != null and mobile != ''"
>
#{mobile},
</if>
<if
test=
"describes != null and describes != ''"
>
#{describes},
</if>
<if
test=
"details != null"
>
#{details},
</if>
<if
test=
"noticeImage != null"
>
#{noticeImage},
</if>
<if
test=
"timeStart != null"
>
#{timeStart},
</if>
<if
test=
"timeEnd != null"
>
#{timeEnd},
</if>
<if
test=
"auditTime != null"
>
#{auditTime},
</if>
<if
test=
"rejectTxt != null and rejectTxt != ''"
>
#{rejectTxt},
</if>
<if
test=
"sort != null"
>
#{sort},
</if>
<if
test=
"comment != null and comment != ''"
>
#{comment},
</if>
<if
test=
"createdAt != null"
>
#{createdAt},
</if>
<if
test=
"updatedAt != null"
>
#{updatedAt},
</if>
</trim>
</insert>
<update
id=
"updateKylinPerformances"
parameterType=
"KylinPerformances"
>
update kylin_performances
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"performancesId != null and performancesId != ''"
>
performances_id = #{performancesId},
</if>
<if
test=
"title != null and title != ''"
>
title = #{title},
</if>
<if
test=
"type != null"
>
type = #{type},
</if>
<if
test=
"imgPoster != null and imgPoster != ''"
>
img_poster = #{imgPoster},
</if>
<if
test=
"provinceId != null and provinceId != ''"
>
province_id = #{provinceId},
</if>
<if
test=
"provinceName != null and provinceName != ''"
>
province_name = #{provinceName},
</if>
<if
test=
"cityId != null"
>
city_id = #{cityId},
</if>
<if
test=
"cityName != null and cityName != ''"
>
city_name = #{cityName},
</if>
<if
test=
"districtId != null"
>
district_id = #{districtId},
</if>
<if
test=
"districtName != null and districtName != ''"
>
district_name = #{districtName},
</if>
<if
test=
"approvalUrl != null and approvalUrl != ''"
>
approval_url = #{approvalUrl},
</if>
<if
test=
"notice != null and notice != ''"
>
notice = #{notice},
</if>
<if
test=
"sponsorId != null and sponsorId != ''"
>
sponsor_id = #{sponsorId},
</if>
<if
test=
"sponsorType != null and sponsorType != ''"
>
sponsor_type = #{sponsorType},
</if>
<if
test=
"sponsor != null and sponsor != ''"
>
sponsor = #{sponsor},
</if>
<if
test=
"contacts != null and contacts != ''"
>
contacts = #{contacts},
</if>
<if
test=
"mobile != null and mobile != ''"
>
mobile = #{mobile},
</if>
<if
test=
"describes != null and describes != ''"
>
describes = #{describes},
</if>
<if
test=
"details != null"
>
details = #{details},
</if>
<if
test=
"noticeImage != null"
>
notice_image = #{noticeImage},
</if>
<if
test=
"timeStart != null"
>
time_start = #{timeStart},
</if>
<if
test=
"timeEnd != null"
>
time_end = #{timeEnd},
</if>
<if
test=
"auditTime != null"
>
audit_time = #{auditTime},
</if>
<if
test=
"rejectTxt != null and rejectTxt != ''"
>
reject_txt = #{rejectTxt},
</if>
<if
test=
"sort != null"
>
sort = #{sort},
</if>
<if
test=
"comment != null and comment != ''"
>
comment = #{comment},
</if>
<if
test=
"createdAt != null"
>
created_at = #{createdAt},
</if>
<if
test=
"updatedAt != null"
>
updated_at = #{updatedAt},
</if>
</trim>
where mid = #{mid}
</update>
<delete
id=
"deleteKylinPerformancesById"
parameterType=
"Long"
>
delete from kylin_performances where mid = #{mid}
</delete>
<delete
id=
"deleteKylinPerformancesByIds"
parameterType=
"String"
>
delete from kylin_performances where mid in
<foreach
item=
"mid"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{mid}
</foreach>
</delete>
</mapper>
\ No newline at end of file
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