记得上下班打卡 | git大法好,push需谨慎

Commit aaa1b232 authored by 胡佳晨's avatar 胡佳晨

提交merchant

parent b1dd5fc7
......@@ -247,3 +247,6 @@ create index permission_id_index on merchant_authorization_permissions (permissi
-- >>------------------------------------------------------------------------------------
-- >>------------------------------------------------------------------------------------
-- >>------------------------------------------------------------------------------------
alter table kylin_ticket_status modify qr_code_show_time datetime default '2030-01-01 12:00:00' null comment '二维码显示时间';
alter table kylin_tickets modify time_end_express datetime default '2030-01-01 12:00:00' null comment '快递票结束时间';
......@@ -354,7 +354,7 @@ public class KylinTicketsPartnerServiceImpl implements IKylinTicketsPartnerServi
ticketPartnerVo.setTicketsId(ticketsId);
ticketPartnerVo.setStatus(9);
mongoMerchantUtils.updateTicketPartnerVo(ticketPartnerVo);
performanceUtils.performanceVoStatus(performancesId);
performanceUtils.performanceVoStatus(performancesId,null);
log.info(UserPathDto.setPartnerData("0", "onLine", "performancesId=" + performancesId + ",ticketsId=" + ticketsId, "上线成功"));
return ResponseDto.success("上线成功");
} else {
......@@ -397,7 +397,7 @@ public class KylinTicketsPartnerServiceImpl implements IKylinTicketsPartnerServi
ticketPartnerVo.setTicketsId(ticketsId);
ticketPartnerVo.setStatus(7);
mongoMerchantUtils.updateTicketPartnerVo(ticketPartnerVo);
performanceUtils.performanceVoStatus(performancesId);
performanceUtils.performanceVoStatus(performancesId,null);
log.info(UserPathDto.setPartnerData("0", "outLine", "performancesId=" + performancesId + ",ticketsId=" + ticketsId, "下线成功"));
return ResponseDto.success("下线成功");
} else {
......
......@@ -35,6 +35,8 @@ public class MongoMerchantUtils {
private MongoTemplate mongoTemplate;
@Autowired
private MongoConverter mongoConverter;
@Autowired
private RedisMerchantUtils redisMerchantUtils;
public PerformancePartnerVo getPerformancePartnerVo(String performanceId,String merchantId) {
......@@ -175,15 +177,8 @@ public class MongoMerchantUtils {
return mongoTemplate.insert(data, KylinPerformanceVo.class.getSimpleName());
}
public void updatePerformanceVo(HashMap<String, Object> map, String performanceId) {
BasicDBObject objectTicketVo = new BasicDBObject("$set", mongoConverter.convertToMongoType(map));
mongoTemplate.getCollection(KylinPerformanceVo.class.getSimpleName()).updateOne(
Query.query(Criteria.where("performancesId").is(performanceId)).getQueryObject(),
objectTicketVo
);
}
public Object delPerformanceVo(String performanceId) {
redisMerchantUtils.delPerformanceVo(performanceId);
return mongoTemplate.remove(Query.query(Criteria.where("performancesId").is(performanceId)), KylinPerformanceVo.class, KylinPerformanceVo.class.getSimpleName());
}
......
......@@ -55,7 +55,7 @@ public class PerformanceUtils {
*
* @param performanceSingleId
*/
public void performanceVoStatus(String performanceSingleId) {
public void performanceVoStatus(String performanceSingleId,Integer voStatus) {
LinkedList<String> sqls = CollectionUtil.linkedListString();
sqls.add(SqlMapping.get("kylin_ticket_status.VoStatus"));
sqls.add(SqlMapping.get("kylin_performance_status.VoStatus"));
......@@ -74,6 +74,9 @@ public class PerformanceUtils {
for (String performancesId : performanceIdList) {
KylinPerformanceVo vo = combinePerformanceVoData(performancesId);
if(voStatus!=null){
vo.setAppStatus(voStatus);
}
//场次
List<KylinTicketTimesVo> timesData = vo.getTicketTimeList();
if (timesData.size() == 0) {
......
......@@ -52,17 +52,27 @@ public class RedisMerchantUtils {
* @param performanceId
* @return
*/
public KylinPerformanceVo getPerformanceVo(String performanceId,String merchantId) {
public KylinPerformanceVo getPerformanceVo(String performanceId, String merchantId) {
Object obj = redisUtil.get(KylinRedisConst.PERFORMANCES + performanceId);
if (obj != null) {
return (KylinPerformanceVo) obj;
} else {
KylinPerformanceVo performanceData = mongoMerchantUtils.getPerformanceVo(performanceId,merchantId);
KylinPerformanceVo performanceData = mongoMerchantUtils.getPerformanceVo(performanceId, merchantId);
redisUtil.set(KylinRedisConst.PERFORMANCES + performanceId, performanceData);
return performanceData;
}
}
/**
* 根据演出id 删除 演出vo 详情
*
* @param performanceId
* @return
*/
public void delPerformanceVo(String performanceId) {
redisUtil.del(KylinRedisConst.PERFORMANCES+performanceId);
}
public KylinPerformanceVo getPerformanceVoNoMerchant(String performanceId) {
Object obj = redisUtil.get(KylinRedisConst.PERFORMANCES + performanceId);
if (obj != null) {
......
......@@ -26,8 +26,8 @@ kylin_ticket_status.onLine=UPDATE kylin_ticket_status SET status = ?, updated_at
# ---- 演出第二步骤操作 ----
kylin_performance.updateStep2=UPDATE kylin_performances SET audit_time = ? , notice_image = ? WHERE performances_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
kylin_performance_status.updateStep2=UPDATE kylin_performance_status SET audit_status = ? , is_true_name = ? , limit_count = ? WHERE performance_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
kylin_ticket.updateStep2=UPDATE kylin_tickets SET time_end = ? , time_start = ? ,time_end_express = ? ,pay_countdown_minute = ? WHERE tickets_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
kylin_ticket_status.updateStep2=UPDATE kylin_ticket_status SET WHERE ticket_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
kylin_ticket.updateStep2=UPDATE kylin_tickets SET time_end = ? , time_start = ? ,time_end_express = ? ,pay_countdown_minute = ? ,price = ? WHERE tickets_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
kylin_ticket_status.updateStep2=UPDATE kylin_ticket_status SET total_exchange = ? , total_general = ? , is_true_name = ? , limit_count = ? , is_lack_register = ? , is_express = ? , is_electronic = ? ,counts = ? , is_show_code = ? ,qr_code_show_time = ? WHERE ticket_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
# ---- VoStatus ----
kylin_ticket_status.VoStatus=UPDATE kylin_ticket_status SET status = ?, surplus_general = ? WHERE ticket_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
kylin_performance_status.VoStatus=UPDATE kylin_performance_status SET status = ? WHERE performance_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment