public DB.Stru.基层科.民主管理信息管理 GetFirst_ByWhere(string strWhere)
        {
            DB.Stru.基层科.民主管理信息管理 stru = new DB.Stru.基层科.民主管理信息管理();
            List<DB.Stru.基层科.民主管理信息管理> list = Get_ByWhere(strWhere);

            if (list != null && list.Count > 0)
                stru = list[0];

            return stru;
        }
        protected override void Save()
        {
            _stru = uc.stru;

            _stru = BL.基层科.民主管理信息管理.Save(_stru);

            if ( _stru.IsValid() )
                FF.Ctrl.MsgBox.Show( Def.Str.Msg.Save_OK );
            else
                FF.Ctrl.MsgBox.Show( Def.Str.Msg.Save_Err );
        }
        protected override void Delete()
        {
            _stru = uc.stru;

            if ( _stru.IsNotValid() )
            {
                return;
            }

            _stru = BL.基层科.民主管理信息管理.Delete(_stru);

            if ( !_stru.IsValid() )
                FF.Ctrl.MsgBox.Show( Def.Str.Msg.Delete_OK );
            else
                FF.Ctrl.MsgBox.Show( Def.Str.Msg.Delete_Err );
        }
        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            DB.Stru.基层科.民主管理信息管理 民主管理信息管理1 = new DB.Stru.基层科.民主管理信息管理();
            this.uc = new UI.UC.基层科.民主管理();
            this.SuspendLayout();
            // 
            // uc
            // 
            this.uc.Dock = System.Windows.Forms.DockStyle.Fill;
            this.uc.Location = new System.Drawing.Point(0, 40);
            this.uc.Name = "uc";
            this.uc.Size = new System.Drawing.Size(487, 251);
            民主管理信息管理1.办公电话 = "";
            民主管理信息管理1.面积 = "";
            民主管理信息管理1.人口数 = "";
            民主管理信息管理1.委员会地址 = "";
            民主管理信息管理1.委员会名称 = "";
            民主管理信息管理1.辖区范围 = "";
            民主管理信息管理1.组织机构代码 = "";
            民主管理信息管理1.所属街道1 = "";
            民主管理信息管理1.所属街道2 = "";


            this.uc.stru = 民主管理信息管理1;
            this.uc.TabIndex = 0;
            // 
            // FEdit
            // 
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(487, 331);
            this.Controls.Add(this.uc);
            this.Name = "FEdit";
            this.Text = "Edit";
            this.Load += new System.EventHandler(this.Edit_Load);
            this.Controls.SetChildIndex(this.uc, 0);
            this.ResumeLayout(false);

        }
        public static List<DB.Stru.基层科.民主管理信息管理> Dt2List(ref DataTable dt)
        {
            List<DB.Stru.基层科.民主管理信息管理> lst = new List<DB.Stru.基层科.民主管理信息管理>();

            if (SQL.IsNotValid(ref dt))
                return lst;

            foreach (DataRow dr in dt.Rows)
            {
                DB.Stru.基层科.民主管理信息管理 stru = new DB.Stru.基层科.民主管理信息管理();
                stru.Dr2Stru(dr);
                lst.Add(stru);
            }

            return lst;
        }