web/web/GwProduct.ashx
@@ -265,6 +265,26 @@
        int ctGroupid = 0;
        int price = 0;
        int givingNum = 0;
        string parentId = context.GetString("parentId", "");
        string path = "";
        if (string.IsNullOrEmpty(parentId) )
        {
            path = "0";
        }
        else
        {
            GwProduct newProduct = _Dao.Get(parentId);
            if(newProduct!=null)
            {
                path = newProduct.Path=="" ? "0" : newProduct.Path + "," + newProduct.Id ;
            }
            else
            {
                path = "0";
            }
        }
        string info = "" ;
        if (classes == -1) {
@@ -278,6 +298,11 @@
                if (string.IsNullOrEmpty(name))
                {
                    throw new ArgumentException(info + "名称不能为空!");
                }
                if (string.IsNullOrEmpty(parentId))
                {
                    throw new ArgumentException("所属产品类别不能为空!");
                }
            }
@@ -326,25 +351,7 @@
            }
        }
        string parentId = context.GetString("parentId", "0");
        string path = "";
        if (parentId.Equals("0"))
        {
            path = "0";
        }
        else
        {
            GwProduct newProduct = _Dao.Get(parentId);
            if(newProduct!=null)
            {
                path = newProduct.Path=="" ? "0" : newProduct.Path + "," + newProduct.Id ;
            }
            else
            {
                path = "0";
            }
        }
        int isEnable = context.GetInt("isEnable", 0);
        //int price = context.GetInt("price", 0);
@@ -446,6 +453,26 @@
        int ctGroupid = 0;
        int price = 0;
        int givingNum = 0;
        string parentId = context.GetString("parentId", "");
        string path = "";
        if (string.IsNullOrEmpty(parentId) )
        {
            path = "0";
        }
        else
        {
            GwProduct newProduct = _Dao.Get(parentId);
            if(newProduct!=null)
            {
                path = newProduct.Path=="" ? "0" : newProduct.Path + "," + newProduct.Id ;
            }
            else
            {
                path = "0";
            }
        }
        string info = "" ;
        if (classes == -1) {
@@ -459,6 +486,11 @@
                if (string.IsNullOrEmpty(name))
                {
                    throw new ArgumentException(info + "名称不能为空!");
                }
                if (string.IsNullOrEmpty(parentId))
                {
                    throw new ArgumentException("所属产品类别不能为空!");
                }
            }
@@ -508,25 +540,7 @@
            }
        }
        string parentId = context.GetString("parentId", "0");
        string path = "";
        if (parentId.Equals("0"))
        {
            path = "0";
        }
        else
        {
            GwProduct newProduct = _Dao.Get(parentId);
            if(newProduct!=null)
            {
                path = newProduct.Path=="" ? "0" : newProduct.Path + "," + newProduct.Id ;
            }
            else
            {
                path = "0";
            }
        }
        int isEnable = context.GetInt("isEnable", 0);
        string remark = context.GetString("remark", "");