system_info_list.cs

来自「.net 开发的基础框架」· CS 代码 · 共 123 行

CS
123
字号
using System;
using System.Collections.Generic;
using System.Text;
using Sybase.DataWindow;

namespace SPRFrame.DataType
{
    // 程序信息表
    public class System_Info_List : Sybase.DataWindow.DataStore
    {
        public System_Info_List()
        {
            this.LibraryList = SPRF.PbdFile;
            this.DataWindowObject = "dw_system_info_list";
            this.SetTransaction(SPRF.GetDB());
        }
        #region 属性
        public string SYS_ID
        {
            get
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "sys_id");
            }
            set
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "sys_id", value);
            }
        }
        public string SYS_NAME
        {
            get
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "sys_name");
            }
            set
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "sys_name", value);
            }
        }
        public string SYS_VERSION
        {
            get
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "sys_version");
            }
            set
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "sys_version", value);
            }
        }
        public string SYS_BUILD
        {
            get
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "sys_build");
            }
            set
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "sys_build", value);
            }
        }
        public DateTime SYS_STARTDATE
        {
            get
            {
                if (this.RowCount == 0) return Convert.ToDateTime("2000-01-01 00:00:00");
                return this.GetItemDateTime(this.CurrentRow, "sys_startdate");
            }
            set
            {
                if (this.RowCount == 0) return;
                this.SetItemDateTime(this.CurrentRow, "sys_startdate", value);
            }
        }
        public string STS
        {
            get
            {
                if (this.RowCount == 0) return "NoData";
                return this.GetItemString(this.CurrentRow, "sts");
            }
            set
            {
                if (this.RowCount == 0) return;
                this.SetItemString(this.CurrentRow, "sts", value);
            }
        }
        public bool IsNULL
        {
            get
            {
                if (this.RowCount == 0)
                {
                    return true;
                }
                else
                {
                    return false;
                }
            }
        }
        #endregion

        #region 设定取得数据的方法
        public void SetDataBySysId(string sSysId)
        {
            string SqlString = this.GetSqlSelect();
            SqlString += "where sys_id = '" + sSysId + "'";
            this.SetSqlSelect(SqlString);
        }
        #endregion
    }
}

⌨️ 快捷键说明

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