1;默认时间

2;帐分扣减逻辑优化
This commit is contained in:
wangshuai 2024-08-09 02:08:58 +08:00
parent 7d20fb4f77
commit 9e42550ea2
3 changed files with 15 additions and 7 deletions

View File

@ -166,7 +166,7 @@ public class AiConsumer {
int a = 1; int a = 1;
if("AI".equals(busStoreInfo.getMarketingChannels())){ if("AI".equals(busStoreInfo.getMarketingChannels())){
int reduce = busAgentInfo.getAiRealTimeNum() - a; int reduce = busAgentInfo.getAiRealTimeNum() - a;
busAgentInfo.setAiDurationBalance(reduce); busAgentInfo.setAiRealTimeNum(reduce);
record.setIntegralType("AI"); record.setIntegralType("AI");
record.setAiIntegralBalance(reduce); record.setAiIntegralBalance(reduce);
returnVisitInfo.setIsCharging("AI-0"); returnVisitInfo.setIsCharging("AI-0");

View File

@ -268,7 +268,7 @@ public class AiServiceImpl implements IAiService {
if (cha < list.size()&&(cha - 1)>0) { if (cha < list.size()&&(cha - 1)>0) {
list.subList(0, cha - 1); list.subList(0, cha - 1);
log.error("安全账分不足截取部分订单营销"); log.error("安全账分不足截取部分订单营销");
} else if(cha < 0){ } else if(cha <= 0){
continue; continue;
} }
}else if("AI".equals(busStoreInfo.getMarketingChannels())){ }else if("AI".equals(busStoreInfo.getMarketingChannels())){
@ -276,7 +276,7 @@ public class AiServiceImpl implements IAiService {
if (cha < list.size()&&(cha - 1)>0) { if (cha < list.size()&&(cha - 1)>0) {
list.subList(0, cha - 1); list.subList(0, cha - 1);
log.error("普通账分不足截取部分订单营销"); log.error("普通账分不足截取部分订单营销");
} else if(cha < 0){ } else if(cha <= 0){
continue; continue;
} }
}else{ }else{

View File

@ -47,6 +47,7 @@
<el-date-picker <el-date-picker
v-model="dateRange" v-model="dateRange"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
type="daterange" type="daterange"
range-separator="至" range-separator="至"
start-placeholder="开始日期" start-placeholder="开始日期"
@ -122,6 +123,7 @@ export default {
deptNodeAll: false, deptNodeAll: false,
// //
dateRange: [], dateRange: [],
defaultTime: [],
// //
dataScopeOptions: [ dataScopeOptions: [
{ {
@ -179,14 +181,20 @@ export default {
}; };
}, },
created() { created() {
this.setDefaultDateRange(); this.initDateRange();
this.userAccount = this.$store.state.user.name; this.userAccount = this.$store.state.user.name;
this.getList(); this.getList();
}, },
methods: { methods: {
setDefaultDateRange() { initDateRange() {
const now = new Date(); const today = this.formatDate(new Date());
this.dateRange = [now, now]; this.dateRange = [today, today];
},
formatDate(date) {
const year = date.getFullYear();
const month = (date.getMonth() + 1).toString().padStart(2, '0');
const day = date.getDate().toString().padStart(2, '0');
return `${year}-${month}-${day}`;
}, },
/** 查询角色列表 */ /** 查询角色列表 */
getList() { getList() {