|
|
@ -53,6 +53,7 @@ import com.yxt.anrui.flowable.sqloperationsymbol.BusinessVariables; |
|
|
|
import com.yxt.anrui.portal.api.flow.PCHistTaskListAndCommentList; |
|
|
|
import com.yxt.anrui.portal.api.sysorganization.SysOrganizationFeign; |
|
|
|
import com.yxt.anrui.portal.api.sysorganization.SysOrganizationVo; |
|
|
|
import com.yxt.anrui.portal.api.sysparameter.SysParameterFeign; |
|
|
|
import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrg; |
|
|
|
import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrgFeign; |
|
|
|
import com.yxt.anrui.portal.api.sysuser.PrivilegeQuery; |
|
|
@ -144,7 +145,8 @@ public class ScmVehRebateWithApplyService extends MybatisBaseService<ScmVehRebat |
|
|
|
private MessageFeign messageFeign; |
|
|
|
@Autowired |
|
|
|
private MessageListFeign messageListFeign; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private SysParameterFeign sysParameterFeign; |
|
|
|
private QueryWrapper<ScmVehRebateWithApply> createQueryWrapper(ScmVehRebateWithApplyQuery query) { |
|
|
|
// todo: 这里根据具体业务调整查询条件
|
|
|
|
// 多字段Like示例:qw.and(wrapper -> wrapper.like("name", query.getName()).or().like("remark", query.getName()));
|
|
|
@ -450,18 +452,28 @@ public class ScmVehRebateWithApplyService extends MybatisBaseService<ScmVehRebat |
|
|
|
* @return |
|
|
|
*/ |
|
|
|
public String returnBusDate(Date date) { |
|
|
|
Date parse = null; |
|
|
|
Date ruleDate = null; |
|
|
|
Date nowDate = null; |
|
|
|
String rDate = ""; |
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM"); |
|
|
|
SimpleDateFormat sdf2 = new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
String format1 = sdf.format(date); |
|
|
|
String rDate = format1 + "-06"; |
|
|
|
String parameterVale = sysParameterFeign.fetchByParNo("CW_FLYJSRQ").getData(); |
|
|
|
int i = Integer.parseInt(parameterVale); |
|
|
|
if (i >= 10) { |
|
|
|
rDate = format1 + "-" + i; |
|
|
|
} else { |
|
|
|
rDate = format1 + "-0" + i; |
|
|
|
} |
|
|
|
String format2 = sdf2.format(date); |
|
|
|
try { |
|
|
|
parse = sdf2.parse(rDate); |
|
|
|
ruleDate = sdf2.parse(rDate); |
|
|
|
nowDate = sdf2.parse(format2); |
|
|
|
} catch (ParseException e) { |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
if (!(date.before(parse))) { |
|
|
|
return sdf2.format(date); |
|
|
|
if ((nowDate.after(ruleDate))) { |
|
|
|
return sdf2.format(nowDate); |
|
|
|
} else { |
|
|
|
Calendar calendar = Calendar.getInstance(); |
|
|
|
int month = calendar.get(Calendar.MONTH); |
|
|
|