db35e1f648a40d431924aecf43d1ce0b13a8111c.svn-base 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. package xin.glue.ui.G.G04;
  2. import com.posdata.glue.biz.activity.PosActivity;
  3. import com.posdata.glue.biz.constants.PosBizControlConstants;
  4. import com.posdata.glue.context.PosContext;
  5. import com.posdata.glue.dao.vo.PosParameter;
  6. import com.posdata.glue.dao.vo.PosRow;
  7. import com.posdata.glue.dao.vo.PosRowSet;
  8. /*
  9. *
  10. *
  11. * @author tangliang
  12. * @date 2008.11.03
  13. */
  14. public class DeleteCrCommand extends PosActivity{
  15. public String runActivity(PosContext context)
  16. {
  17. String[] SEQ_NO = (String[])context.get("SEQ_NO");
  18. PosParameter param1 = new PosParameter();
  19. param1.setWhereClauseParameter(0, SEQ_NO[0]);
  20. PosRowSet CrCmdVO = getDao("mesdao").find("UIG040041_04.select", param1);
  21. String FromAddr = null;
  22. String SlabNo = null;
  23. if (CrCmdVO.hasNext()) {
  24. PosRow CrCmdROW = CrCmdVO.next();
  25. FromAddr = (String)CrCmdROW.getAttribute("FROM_ADDR");
  26. SlabNo = (String)CrCmdROW.getAttribute("ORD_SLAB_NO1");
  27. PosParameter param2 = new PosParameter();
  28. param2.setValueParamter(0, "");
  29. param2.setValueParamter(1, SlabNo);
  30. param2.setValueParamter(2, FromAddr);
  31. getDao("mesdao").update("UIG040041_01.update", param2);
  32. //when delete crane command set tbg02_charge_comm 'MILL_SCH_STAT' to ""
  33. PosParameter param3 = new PosParameter();
  34. param3.setValueParamter(0, "");
  35. param3.setValueParamter(1, SlabNo);
  36. getDao("mesdao").update("UIG040042_SLAB_COMM.update", param3);
  37. // Crane Command set 'CRD' TO CUR_LOAD_LOC column of TBG02_SLAB_COMM
  38. }
  39. PosParameter param3 = new PosParameter();
  40. param3.setValueParamter(0, SEQ_NO[0]);
  41. getDao("mesdao").update("UIG040041_01.delete", param3);
  42. return PosBizControlConstants.SUCCESS;
  43. }
  44. }