|
|
|
@ -1,5 +1,6 @@ |
|
|
|
package org.springblade.desk.quality.service.impl; |
|
|
|
package org.springblade.desk.quality.service.impl; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil; |
|
|
|
import cn.hutool.core.util.StrUtil; |
|
|
|
import cn.hutool.core.util.StrUtil; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
@ -187,13 +188,12 @@ public class DispatchConfigApprovalServiceImpl extends EnBaseServiceImpl<Dispatc |
|
|
|
* 格式:YYYYMMDD + 3位序号 |
|
|
|
* 格式:YYYYMMDD + 3位序号 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private String generateApplicationNo() { |
|
|
|
private String generateApplicationNo() { |
|
|
|
String dateStr = cn.hutool.core.date.DateUtil.format(new Date(), "yyyyMMdd"); |
|
|
|
String dateStr = DateUtil.format(new Date(), "yyyyMMdd"); |
|
|
|
|
|
|
|
|
|
|
|
// 查询当天最大序号
|
|
|
|
// 查询当天最大序号
|
|
|
|
QueryWrapper<DispatchConfigApproval> queryWrapper = new QueryWrapper<>(); |
|
|
|
QueryWrapper<DispatchConfigApproval> queryWrapper = new QueryWrapper<>(); |
|
|
|
queryWrapper.likeRight("APPLICATION_NO", dateStr) |
|
|
|
queryWrapper.likeRight("APPLICATION_NO", dateStr) |
|
|
|
.orderByDesc("APPLICATION_NO") |
|
|
|
.orderByDesc("APPLICATION_NO"); |
|
|
|
.last("LIMIT 1"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
DispatchConfigApproval last = getOne(queryWrapper); |
|
|
|
DispatchConfigApproval last = getOne(queryWrapper); |
|
|
|
int seq = 1; |
|
|
|
int seq = 1; |
|
|
|
|