⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cdrug_catalog_list.cs

📁 .net 开发的基础框架
💻 CS
字号:
using System;
using System.Collections.Generic;
using System.Text;
using Sybase.DataWindow;
using HPIResource;
using SPRFrame;

namespace HPIResource.CDrug
{
    public class CDrug_Catalog_List : DataStore
    {
        public CDrug_Catalog_List()
        {
            this.LibraryList = HPIR.PbdFile;
            this.DataWindowObject = "dw_cdrug_catalog";
            this.SetTransaction(SPRF.GetDB());
        }

        #region 属性
        public int ID
        {
            get
            {
                if (this.RowCount == 0) return 0;
                return Convert.ToInt32(this.GetItemDouble(this.CurrentRow,"id"));
            }
            set
            {
                if(this.RowCount == 0) return;
                this.SetItemDouble(this.CurrentRow,"id",value);
            }
        }
        public int F_ID  
        {
            get
            {
                if (this.RowCount == 0) return 0;
                return Convert.ToInt32(this.GetItemDouble(this.CurrentRow,"f_id"));
            }
            set
            {
                if(this.RowCount == 0) return ;
                this.SetItemDouble(this.CurrentRow,"f_id",value);
            }
        }
        public string CDrug_LB_MC
        {
            get
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "LeiBieMC");
            }
            set
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "LeiBieMC", value);
            }
        }
        public string CDrug_LB  //分类代码
        {
            get 
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "CDrug_LB");
            }
            set 
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "CDrug_LB", value);
            }
        }
        public string CDrug_LB_F   //分类名称
        {
            get
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "CDrug_LB_F");
            }
            set 
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "CDrug_LB_F", value);
            }
        }
        #endregion

        #region 取数据方法
        public void SetDataById(int iCatalogId)
        {
            string SqlString = this.GetSqlSelect();
            SqlString += "where id = " + iCatalogId.ToString();
            this.SetSqlSelect(SqlString);
        }
        public void SetDataByFId(int iCatalogId)
        {
            string SqlString = this.GetSqlSelect();
            SqlString += "where f_id = " + iCatalogId.ToString();
            this.SetSqlSelect(SqlString);
        }
        public void SetDataByCDrug_LB(string sLB)
        {
            string SqlString = this.GetSqlSelect();
            SqlString += "where CDrug_LB = " + sLB + " order by CDrug_LB";
            this.SetSqlSelect(SqlString);
        }
        public void SetDataByCDrug_LB_F(string sLB_F)
        {
            string SqlString = this.GetSqlSelect();
            SqlString += "where CDrug_LB_F = " + sLB_F + " order by CDrug_LB_F";
            this.SetSqlSelect(SqlString);
        }
        #endregion
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -