示例#1
0
 /// <summary>
 /// 获得实体
 /// </summary>
 /// <returns></returns>
 private HttSoft.MLTERP.Data.ItemType EntityGet()
 {
     HttSoft.MLTERP.Data.ItemType entity = new HttSoft.MLTERP.Data.ItemType();
     entity.ID = HTDataID;
     entity.SelectByID();
     entity.ID           = SysConvert.ToInt32(txtID.Text.Trim());
     entity.Name         = txtName.Text.Trim();
     entity.Code         = txtCode.Text.Trim();
     entity.VendorTypeID = SysConvert.ToInt32(drpVendorTypeID.EditValue);
     return(entity);
 }
示例#2
0
        /// <summary>
        /// 设置
        /// </summary>
        public override void EntitySet()
        {
            HttSoft.MLTERP.Data.ItemType entity = new HttSoft.MLTERP.Data.ItemType();
            entity.ID = HTDataID;
            bool findFlag = entity.SelectByID();

            txtID.Text   = entity.ID.ToString();
            txtCode.Text = entity.Code.ToString();
            txtName.Text = entity.Name.ToString();
            drpVendorTypeID.EditValue = entity.VendorTypeID;
            if (!findFlag)//处理默认值
            {
                txtID.Text = "";
            }
        }