///////////////////////////////////////////////////////////////// // // (C) Copyright 2013, Kenneth, Inc. // All rights reserved. Confidential. Except as pursuant // to a written agreement with Kenneth, this software may // not be used or distributed. This software may be covered // by one or more patents. // // 本软件为Kenneth开发,版权所有,违者必究,320325198102218110,23810511@qq.com // ///////////////////////////////////////////////////////////////// using System; using System.Collections.Generic; using System.Data; using System.Reflection; using System.Windows; using GummingCommon; namespace GummingEntity { public partial class SysSettingEntity { public SysSettingEntity Copy { get; set; } private bool _Status; public bool Status { get { return _Status; } set { _Status = value; OnPropertyChanged("Status"); } } private Visibility _StatusVisible; public Visibility StatusVisible { get { return _StatusVisible; } set { _StatusVisible = value; OnPropertyChanged("StatusVisible"); } } private Visibility _InputVisible; public Visibility InputVisible { get { return _InputVisible; } set { _InputVisible = value; OnPropertyChanged("InputVisible"); } } } /// /// SysSetting /// [Serializable] public partial class SysSettingEntity : ViewModelBase, ICloneable { /// /// /// private string _RecId; public string RecId { get { return _RecId; } set { _RecId = value; OnPropertyChanged("RecId"); } } /// /// 分组 /// private string _SettingGroup; public string SettingGroup { get { return _SettingGroup; } set { _SettingGroup = value; OnPropertyChanged("SettingGroup"); } } /// /// 关联分组 /// private string _RefGroup; public string RefGroup { get { return _RefGroup; } set { _RefGroup = value; OnPropertyChanged("RefGroup"); } } /// /// 关联Id /// private string _RefId; public string RefId { get { return _RefId; } set { _RefId = value; OnPropertyChanged("RefId"); } } /// /// 设定值 /// private decimal _SettingValue; public decimal SettingValue { get { return _SettingValue; } set { _SettingValue = value; OnPropertyChanged("SettingValue"); } } /// /// 是否开启 /// private int? _SettingStatus; public int? SettingStatus { get { return _SettingStatus; } set { _SettingStatus = value; OnPropertyChanged("SettingStatus"); } } /// /// 编码 /// private string _SettingCode; public string SettingCode { get { return _SettingCode; } set { _SettingCode = value; OnPropertyChanged("SettingCode"); } } /// /// 名称 /// private string _SettingName; public string SettingName { get { return _SettingName; } set { _SettingName = value; OnPropertyChanged("SettingName"); } } /// /// /// private int? _OrderBy; public int? OrderBy { get { return _OrderBy; } set { _OrderBy = value; OnPropertyChanged("OrderBy"); } } /// /// /// private string _CreateBy; public string CreateBy { get { return _CreateBy; } set { _CreateBy = value; OnPropertyChanged("CreateBy"); } } /// /// /// private DateTime? _CreateTime; public DateTime? CreateTime { get { return _CreateTime; } set { _CreateTime = value; OnPropertyChanged("CreateTime"); } } /// /// /// private string _ModifyBy; public string ModifyBy { get { return _ModifyBy; } set { _ModifyBy = value; OnPropertyChanged("ModifyBy"); } } /// /// /// private DateTime? _ModifyTime; public DateTime? ModifyTime { get { return _ModifyTime; } set { _ModifyTime = value; OnPropertyChanged("ModifyTime"); } } /// /// /// private int? _IsActive; public int? IsActive { get { return _IsActive; } set { _IsActive = value; OnPropertyChanged("IsActive"); } } public object Clone() { SysSettingEntity obj = new SysSettingEntity(); Type t = this.GetType(); PropertyInfo[] properties = t.GetProperties(); foreach (PropertyInfo pi in properties) { if (pi.CanWrite) { object value = pi.GetValue(this, null); if (obj.GetType().GetProperty(pi.Name) != null) { pi.SetValue(obj, value, null); } } } return obj; } } }