|
@@ -6,6 +6,7 @@ import com.miniframe.generate.business.system.model.D00008BaseModel;
|
|
|
import com.miniframe.model.system.DAccident;
|
|
|
import com.miniframe.model.system.DAccidentSQLBuilder;
|
|
|
import com.miniframe.model.system.DJob;
|
|
|
+import com.miniframe.model.system.DJobSQLBuilder;
|
|
|
import com.miniframe.model.system.dao.DAccidentMapper;
|
|
|
import com.miniframe.model.system.dao.DJobMapper;
|
|
|
import com.miniframe.service.impl.FileServiceImpl;
|
|
@@ -49,7 +50,7 @@ public class D00008Service extends D00008BaseModel implements ExecProcessFlow {
|
|
|
|
|
|
DAccidentMapper accidentDao = UtilTools.getBean(DAccidentMapper.class);
|
|
|
DAccident accident= accidentDao.selectByPrimaryKey(aid);
|
|
|
- DJobMapper dJobMapperDao = UtilTools.getBean(DJobMapper.class);
|
|
|
+ DJobMapper dJobDao = UtilTools.getBean(DJobMapper.class);
|
|
|
DJob job =new DJob();
|
|
|
job.setAid(aid);
|
|
|
job.setTotaltime(totaltime);
|
|
@@ -59,7 +60,15 @@ public class D00008Service extends D00008BaseModel implements ExecProcessFlow {
|
|
|
job.setInteractionstep(interactionstep);
|
|
|
job.setStarttime(XIDateTimeUtils.getNowStr());
|
|
|
job.setState("0");//未执行
|
|
|
- int jid=dJobMapperDao.insertSelective(job);
|
|
|
+ dJobDao.insertSelective(job);
|
|
|
+ //获取最新JOB
|
|
|
+ DJobSQLBuilder jsb = new DJobSQLBuilder();
|
|
|
+ DJobSQLBuilder.Criteria jsc =jsb.createCriteria();
|
|
|
+ jsc.andAidEqualTo(aid);
|
|
|
+ jsb.setOrderByClause("starttime desc");
|
|
|
+ DJob newJob= dJobDao.selectOneByExample(jsb);
|
|
|
+ Integer jid =newJob.getId();
|
|
|
+ //存储最新求解ID
|
|
|
accident.setJid(jid);
|
|
|
accidentDao.updateByPrimaryKey(accident);
|
|
|
|