Răsfoiți Sursa

常用产品配置

ztl 2 ani în urmă
părinte
comite
cf31f04b42

+ 3 - 3
wwwroot/mes/mst/CommonModelGood/commonmodel_add.html

@@ -38,11 +38,11 @@
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">商标:</div>  
-                    <input class="easyui-combobox" id="LOGONAME" name="LOGONAME" data-options="required:false,prompt:'',tipPosition:'top',url:'../../rpt/rpt.ashx?m=getLogoByGoods&select=1', method:'get',valueField:'ID',textField:'TEXT',panelHeight:'300px',editable:false,onChange:PLATELIMITNUM" style="width:100%;height:32px;">
+                    <input class="easyui-combobox" id="LOGONAME" name="LOGONAME" data-options="required:true,prompt:'',tipPosition:'top',url:'../../rpt/rpt.ashx?m=getLogoByGoods&select=1', method:'get',valueField:'ID',textField:'TEXT',panelHeight:'300px',editable:false,onChange:PLATELIMITNUM" style="width:100%;height:32px;">
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">坑距:</div>
-                    <div class="w-field"><input class="easyui-textbox" id="OUTLETDISTANCE" name="OUTLETDISTANCE" data-options="required:true,prompt:'',tipPosition:'top'" style="width:100%;height:32px;"></div>
+                    <div class="w-field"><input class="easyui-textbox" id="OUTLETDISTANCE" name="OUTLETDISTANCE" data-options="required:false,prompt:'',tipPosition:'top'" style="width:100%;height:32px;"></div>
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">物料号:</div>
@@ -58,7 +58,7 @@
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">常用标识:</div>
-                    <div class="w-field"><input class="easyui-textbox" value="1" id="COMMONFLAG" name="COMMONFLAG" data-options="required:true,prompt:'',tipPosition:'top'" style="width:100%;height:32px;"></div>
+                    <div class="w-field"><input class="easyui-combobox" value="1" id="COMMONFLAG" name="COMMONFLAG" data-options="required:true,prompt:'',tipPosition:'top',data:[{'text': '0', 'value': '0'}, {'text': '1', 'value': '1'}]" style="width:100%;height:32px;"></div>
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">生效时间:</div>

+ 5 - 4
wwwroot/mes/mst/CommonModelGood/commonmodel_edit.html

@@ -38,11 +38,11 @@
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">商标:</div>
-                    <input class="easyui-combobox" id="LOGONAME" name="LOGONAME" data-options="required:false,prompt:'',tipPosition:'top',url:'../../rpt/rpt.ashx?m=getLogoByGoods&select=1',method:'get',valueField:'ID',textField:'TEXT',panelHeight:'300px',editable:false,onChange:PLATELIMITNUM" style="width:100%;height:32px;">
+                    <input class="easyui-combobox" id="LOGONAME" name="LOGONAME" data-options="required:true,prompt:'',tipPosition:'top',url:'../../rpt/rpt.ashx?m=getLogoByGoods&select=1',method:'get',valueField:'ID',textField:'TEXT',panelHeight:'300px',editable:false,onChange:PLATELIMITNUM" style="width:100%;height:32px;">
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">坑距:</div>
-                    <div class="w-field"><input class="easyui-textbox" id="OUTLETDISTANCE" name="OUTLETDISTANCE" data-options="required:true,prompt:'',tipPosition:'top'" style="width:100%;height:32px;"></div>
+                    <div class="w-field"><input class="easyui-textbox" id="OUTLETDISTANCE" name="OUTLETDISTANCE" data-options="required:false,prompt:'',tipPosition:'top'" style="width:100%;height:32px;"></div>
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">物料号:</div>
@@ -58,7 +58,7 @@
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">常用标识:</div>
-                    <div class="w-field"><input class="easyui-textbox" id="COMMONFLAG" name="COMMONFLAG" data-options="required:true,prompt:'',tipPosition:'top'" style="width:100%;height:32px;"></div>
+                    <div class="w-field"><input class="easyui-combobox" id="COMMONFLAG" name="COMMONFLAG" data-options="required:true,prompt:'',tipPosition:'top',data:[{'text': '0', 'value': '0'}, {'text': '1', 'value': '1'}]" style="width:100%;height:32px;"></div>
                 </div>
                 <div class="w-div">
                     <div class="w-fieldname">生效时间:</div>
@@ -88,9 +88,10 @@
         });
 
         function submitForm() {
+            var logoid = $('#LOGONAME').combobox('getText').split("#");
             $.dialog.save({
                 formid: 'ff',
-                url: 'goodscommonmodel.ashx?m=u&id=' + request('id')
+                url: 'goodscommonmodel.ashx?m=u&id=' + request('id') + "&logoid=" + logoid[0].toString()
             });
         }
 

+ 0 - 53
wwwroot/mes/mst/CommonModelGood/getOrganization.ashx

@@ -1,53 +0,0 @@
-<%@ WebHandler Language="C#" Class="getOrganization" %>
-
-using System;
-using System.Web;
-using System.Web.SessionState;
-using System.Data;
-using System.Text;
-using System.Collections;
-using System.Collections.Generic;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
-using Curtain.DataAccess;
-using DK.XuWei.WebMes;
-
-public class getOrganization : IHttpHandler, IReadOnlySessionState
-{
-    public void ProcessRequest(HttpContext context)
-    {
-        context.Response.ContentType = "text/plain";
-        using(IDataAccess conn = DataAccess.Create())
-        {
-            DataTable dt = conn.ExecuteDatatable(@"
-                SELECT 
-                    ORGANIZATIONID AS id,
-                    ORGANIZATIONCODE AS code,
-                    ORGANIZATIONNAME AS text,
-                    '' AS url
-                FROM 
-                    TP_MST_ORGANIZATION
-                WHERE 
-                    VALUEFLAG = '1'
-                ORDER BY 
-                    ORGANIZATIONCODE
-            ");
-            string rootId = dt.Rows[0]["id"].ToString();
-            string rootCode = dt.Rows[0]["code"].ToString();
-            string rootText = dt.Rows[0]["text"].ToString();
-            string children = Easyui.TableToEasyUITree(dt, rootCode, 3);
-            string jsonStr = "[{\"id\":\"" + rootId + "\",\"text\":\"" + rootText + "\"" + children + "}]";
-            context.Response.Write(jsonStr);
-        }
-
-    }
-
-    public bool IsReusable
-    {
-        get
-        {
-            return false;
-        }
-    }
-
-}

+ 0 - 47
wwwroot/mes/mst/CommonModelGood/getUser.ashx

@@ -1,47 +0,0 @@
-<%@ WebHandler Language="C#" Class="getUser" %>
-
-using System;
-using System.Web;
-using System.Web.SessionState;
-using System.Data;
-using System.Text;
-using System.Collections;
-using System.Collections.Generic;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
-using Curtain.DataAccess;
-using DK.XuWei.WebMes;
-
-public class getUser : IHttpHandler, IReadOnlySessionState
-{
-    public void ProcessRequest(HttpContext context)
-    {
-        context.Response.ContentType = "text/plain";
-        using(IDataAccess conn = DataAccess.Create())
-        {
-            DataTable dt = conn.ExecuteDatatable(@"
-                SELECT 
-                    USERID AS ID,
-                    USERCODE AS CODE,
-                    USERNAME AS NAME
-                FROM 
-                    TP_MST_USER
-                WHERE 
-                    VALUEFLAG = '1'
-                ORDER BY 
-                    USERCODE
-            ");
-            context.Response.Write(dt.ToJson());
-        }
-
-    }
-
-    public bool IsReusable
-    {
-        get
-        {
-            return false;
-        }
-    }
-
-}

+ 0 - 46
wwwroot/mes/mst/CommonModelGood/getWorkstation.ashx

@@ -1,46 +0,0 @@
-<%@ WebHandler Language="C#" Class="getWorkstation" %>
-
-using System;
-using System.Web;
-using System.Web.SessionState;
-using System.Data;
-using System.Text;
-using System.Collections;
-using System.Collections.Generic;
-using Newtonsoft.Json;
-using Newtonsoft.Json.Linq;
-using Curtain.DataAccess;
-using DK.XuWei.WebMes;
-
-public class getWorkstation : IHttpHandler, IReadOnlySessionState
-{
-    public void ProcessRequest(HttpContext context)
-    {
-        context.Response.ContentType = "text/plain";
-        using(IDataAccess conn = DataAccess.Create())
-        {
-            DataTable dt = conn.ExecuteDatatable(@"
-                SELECT 
-                    WORKSTATIONID AS ID,
-                    WORKSTATIONNAME AS NAME
-                FROM 
-                    TP_MST_WORKSTATION
-                WHERE 
-                    VALUEFLAG = '1'
-                ORDER BY 
-                    DISPLAYNO
-            ");
-            context.Response.Write(dt.ToJson());
-        }
-
-    }
-
-    public bool IsReusable
-    {
-        get
-        {
-            return false;
-        }
-    }
-
-}

+ 3 - 3
wwwroot/mes/mst/CommonModelGood/goodscommonmodel.ashx

@@ -88,7 +88,7 @@ public class workstationuser : IHttpHandler, IRequiresSessionState
                     {
                         //修改
                         if (b.btnUpdate)
-                            context.Response.Write(update(context.Request.Form));
+                            context.Response.Write(update(context.Request.Form,context.Request["logoid"].ToString()));
                         else
                             context.Response.Write(new JsonResult(JsonStatus.rightError).ToJson());
                         break;
@@ -425,7 +425,7 @@ public class workstationuser : IHttpHandler, IRequiresSessionState
     /// 更新 TP_MST_WORKSTATIONUSER
     /// </summary>
     /// <returns>json</returns>
-    private string update(NameValueCollection form)
+    private string update(NameValueCollection form,string logoid)
     {
              var EFFECTIVETIME = "";
         var ENDTIME = "";
@@ -466,7 +466,7 @@ public class workstationuser : IHttpHandler, IRequiresSessionState
                     COMMONGOODSID = @COMMONGOODSID@
                 ",
                 new CDAParameter("GOODSCODE", form["GOODS"]),
-                new CDAParameter("LOGOID", form["LOGONAME"]),
+                new CDAParameter("LOGOID", logoid),
                 new CDAParameter("OUTLETDISTANCE", form["OUTLETDISTANCE"]),
                 new CDAParameter("MATERIALCODE", form["MATERIALCODE"]),
                 new CDAParameter("PLATELIMITNUM1", form["PLATELIMITNUM1"]),