Esempio n. 1
0
        public CMSMStruct.GoodsStruct GetGoodsInfo(string strGoodsid)
        {
            DataTable dtout = opa.GetGoodsInfo(strGoodsid);

            CMSMStruct.GoodsStruct gs = new CommCenter.CMSMStruct.GoodsStruct();
            if (dtout != null)
            {
                gs.strGoodsID   = dtout.Rows[0]["vcGoodsID"].ToString();
                gs.strGoodsName = dtout.Rows[0]["vcGoodsName"].ToString();
                gs.strSpell     = dtout.Rows[0]["vcSpell"].ToString();
                gs.dPrice       = double.Parse(dtout.Rows[0]["nPrice"].ToString());
                gs.iIgValue     = int.Parse(dtout.Rows[0]["iIgValue"].ToString());
                gs.strComments  = dtout.Rows[0]["vcComments"].ToString();
            }
            return(gs);
        }
Esempio n. 2
0
        public CMSMStruct.GoodsStruct GetGoodsInfo(string strGoodsid)
        {
            DataTable dtout = opa.GetGoodsInfo(strGoodsid);

            CMSMStruct.GoodsStruct gs = new CommCenter.CMSMStruct.GoodsStruct();
            if (dtout != null)
            {
                gs.strGoodsID   = dtout.Rows[0]["vcGoodsID"].ToString();
                gs.strGoodsName = dtout.Rows[0]["vcGoodsName"].ToString();
                gs.strSpell     = dtout.Rows[0]["vcSpell"].ToString();
                gs.dPrice       = double.Parse(dtout.Rows[0]["nPrice"].ToString());
                gs.iIgValue     = int.Parse(dtout.Rows[0]["iIgValue"].ToString());
                gs.strComments  = dtout.Rows[0]["vcComments"].ToString();
                gs.bPackage     = Convert.ToBoolean(dtout.Rows[0]["IsPackage"]);
                gs.bNew         = Convert.ToBoolean(dtout.Rows[0]["IsNew"].ToString());
                gs.bKey         = Convert.ToBoolean(dtout.Rows[0]["IsKey"].ToString());
                gs.Unit         = dtout.Rows[0]["Unit"].ToString();
                gs.NewDate      = dtout.Rows[0]["NewDate"].ToString();
                gs.bDeptPrice   = Convert.ToBoolean(dtout.Rows[0]["IsDeptPrice"].ToString());
            }
            return(gs);
        }