Пример #1
0
 /*打开从表*/
 public final void openDetailTable(boolean isMasterAdd) {
   htid = dsMasterTable.getValue("htid"); // 关链
   // isMasterAdd为真是返回空的从表数据集(主表新增时,从表要打开)
   dsDetailTable.setQueryString(
       DETAIL_SQL
           + (isMasterAdd
               ? "-1"
               : ("'" + htid + "' and (storeid is null or storeid='" + storeid + "')")));
   if (dsDetailTable.isOpen()) dsDetailTable.refresh();
   else dsDetailTable.open();
 }
Пример #2
0
 /**
  * JSP调用的函数
  *
  * @param request 网页的请求对象
  * @param response 网页的响应对象
  * @return 返回HTML或javascipt的语句
  * @throws Exception 异常
  */
 public String doService(HttpServletRequest request, HttpServletResponse response) {
   try {
     String opearate = request.getParameter(OPERATE_KEY);
     if (opearate != null && opearate.trim().length() > 0) {
       RunData data = notifyObactioners(opearate, request, response, null);
       if (data.hasMessage()) return data.getMessage();
     }
     return "";
   } catch (Exception ex) {
     if (dsxs_khcpzkTable.isOpen() && dsxs_khcpzkTable.changesPending()) dsxs_khcpzkTable.reset();
     log.error("doService", ex);
     return showMessage(ex.getMessage(), true);
   }
 }
Пример #3
0
 /**
  * 初始化查询的各个列
  *
  * @param request web请求对象
  */
 private void initQueryItem(HttpServletRequest request) {
   if (isInitQuery) return;
   EngineDataSet master = dsxs_khcpzkTable;
   if (!master.isOpen()) master.open();
   // 初始化固定的查询项目
   fixedQuery.addShowColumn(
       "",
       new QueryColumn[] {
         new QueryColumn(master.getColumn("dwtxid"), null, null, null, null, "="),
         new QueryColumn(master.getColumn("cpid"), null, null, null, null, "="),
         new QueryColumn(master.getColumn("zk"), null, null, null, "a", ">="),
         new QueryColumn(master.getColumn("zk"), null, null, null, "b", "<=")
       });
   isInitQuery = true;
 }
Пример #4
0
 /**
  * 初始化查询的各个列
  *
  * @param request web请求对象
  */
 private void initQueryItem(HttpServletRequest request) {
   if (isInitQuery) return;
   EngineDataSet master = dsSaleOrderProduct;
   // EngineDataSet detail = dsDetailTable;
   if (!master.isOpen()) master.open();
   // 初始化固定的查询项目
   fixedQuery = new QueryFixedItem();
   fixedQuery.addShowColumn(
       "",
       new QueryColumn[] {
         new QueryColumn(master.getColumn("tdbh"), null, null, null, null, "="), // 提单编号
         new QueryColumn(master.getColumn("dwtxid"), null, null, null, null, "="), // 购货单位
         new QueryColumn(master.getColumn("sfrq"), null, null, null, "a", ">="), // 提单日期
         new QueryColumn(master.getColumn("sfrq"), null, null, null, "b", "<="), // 提单日期
         new QueryColumn(master.getColumn("deptid"), null, null, null, null, "=") // 部门id
       });
   isInitQuery = true;
 }
Пример #5
0
 /**
  * 初始化查询的各个列
  *
  * @param request web请求对象
  */
 private void initQueryItem(HttpServletRequest request) {
   if (isInitQuery) return; // 已初始化查询条件
   EngineDataSet master = dsMasterTable;
   if (!master.isOpen()) master.open(); // 打开主表数据集
   // 初始化固定的查询项目
   fixedQuery = new QueryFixedItem();
   fixedQuery.addShowColumn(
       "",
       new QueryColumn[] {
         new QueryColumn(master.getColumn("htbh"), null, null, null),
         new QueryColumn(master.getColumn("htrq"), null, null, null, "a", ">="),
         new QueryColumn(master.getColumn("htrq"), null, null, null, "b", "<="),
         new QueryColumn(master.getColumn("ksrq"), null, null, null, "a", ">="),
         new QueryColumn(master.getColumn("ksrq"), null, null, null, "b", "<="),
         new QueryColumn(master.getColumn("jsrq"), null, null, null, "a", ">="),
         new QueryColumn(master.getColumn("jsrq"), null, null, null, "b", "<="),
         new QueryColumn(master.getColumn("dwtxid"), null, null, null, null, "="),
       });
   isInitQuery = true; // 初始化完成
 }
Пример #6
0
 /*得到从表表对象*/
 public final EngineDataSet getDetailTable() {
   if (!dsDetailTable.isOpen()) dsDetailTable.open();
   return dsDetailTable;
 }