| 1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- package xin.glue.nui.E.E03;
- import com.posdata.glue.biz.activity.PosActivity;
- import com.posdata.glue.biz.constants.PosBizControlConstants;
- import com.posdata.glue.context.PosContext;
- import com.posdata.glue.dao.PosGenericDao;
- import com.posdata.glue.dao.vo.PosRowSet;
- public class RepHandled extends PosActivity {
- /*
- * step:
- * 1 - 充当对象订单选取
- * 2 - 充当对象物料选取
- * 3 - 充当结果录入
- */
- public String runActivity(PosContext ctx) {
- int step = 1;
- if (getProperty("step") != null)
- step = Integer.parseInt(getProperty("step"));
- PosGenericDao dao = getDao();
- if (step == 1) {
- PosRowSet rowSet = dao.findByQueryStatement("SELECT PRC_STS FROM TBE05_JOB WHERE PLT = 'R' AND MAIN_PGMID = 'NIE031000'");
- if ("C".equals(rowSet.next().getAttribute("PRC_STS"))) {
- return "F";
- }
- } else {
- PosRowSet rowSet = dao.findByQueryStatement("SELECT PRC_STS FROM TBE05_JOB_DET WHERE PLT = 'R' AND MAIN_PGMID = 'NIE031000' AND SEQ = 2");
- if ("A".equals(rowSet.next().getAttribute("PRC_STS"))) {
- return "F";
- }
- }
- return PosBizControlConstants.SUCCESS;
- }
- private PosGenericDao getDao() {
- String testdao = getProperty("dao");
- if (testdao == null)
- testdao = "mesdao";
- else
- testdao = testdao.trim();
- return getDao(testdao);
- }
- }
|