예제 #1
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id          = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldId]);
     CreateOn    = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseLoginLogEntity.FieldCreateOn]);
     SystemCode  = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldSystemCode]);
     UserId      = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldUserId]);
     UserName    = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldUserName]);
     RealName    = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldRealName]);
     CompanyId   = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldCompanyId]);
     CompanyCode = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldCompanyCode]);
     CompanyName = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldCompanyName]);
     // Service = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldService]);
     // ElapsedTicks = BaseBusinessLogic.ConvertToInt(dr[BaseLoginLogEntity.FieldElapsedTicks]);
     LoginStatus   = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldLoginStatus]);
     MACAddress    = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldMACAddress]);
     IPAddress     = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldIPAddress]);
     IPAddressName = BaseBusinessLogic.ConvertToString(dr[BaseLoginLogEntity.FieldIPAddressName]);
     LogLevel      = BaseBusinessLogic.ConvertToInt(dr[BaseLoginLogEntity.FieldLogLevel]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
예제 #2
0
 /// <summary>
 /// 从数据流读取
 /// </summary>
 /// <param name="dataReader">数据流</param>
 public BaseFolderEntity GetFrom(IDataReader dataReader)
 {
     this.GetFromExpand(dataReader);;
     this.Id                = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldId]);
     this.ParentId          = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldParentId]);
     this.FolderName        = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldFolderName]);
     this.StateCode         = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldStateCode]);
     this.SortCode          = BaseBusinessLogic.ConvertToInt(dataReader[BaseFolderEntity.FieldSortCode]);
     this.AllowEdit         = BaseBusinessLogic.ConvertToInt(dataReader[BaseFolderEntity.FieldAllowEdit]);
     this.AllowDelete       = BaseBusinessLogic.ConvertToInt(dataReader[BaseFolderEntity.FieldAllowDelete]);
     this.IsPublic          = BaseBusinessLogic.ConvertToInt(dataReader[BaseFolderEntity.FieldIsPublic]);
     this.Enabled           = BaseBusinessLogic.ConvertToInt(dataReader[BaseFolderEntity.FieldEnabled]);
     this.DeletionStateCode = BaseBusinessLogic.ConvertToInt(dataReader[BaseFolderEntity.FieldDeletionStateCode]);
     this.Description       = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldDescription]);
     this.CreateOn          = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseFolderEntity.FieldCreateOn]);
     this.CreateUserId      = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldCreateUserId]);
     this.CreateBy          = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldCreateBy]);
     this.ModifiedOn        = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseFolderEntity.FieldModifiedOn]);
     this.ModifiedUserId    = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldModifiedUserId]);
     this.ModifiedBy        = BaseBusinessLogic.ConvertToString(dataReader[BaseFolderEntity.FieldModifiedBy]);
     return(this);
 }
예제 #3
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id                = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldId]);
     ParentId          = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldParentId]);
     FolderName        = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldFolderName]);
     SortCode          = BaseBusinessLogic.ConvertToInt(dr[BaseFolderEntity.FieldSortCode]);
     AllowEdit         = BaseBusinessLogic.ConvertToInt(dr[BaseFolderEntity.FieldAllowEdit]);
     AllowDelete       = BaseBusinessLogic.ConvertToInt(dr[BaseFolderEntity.FieldAllowDelete]);
     IsPublic          = BaseBusinessLogic.ConvertToInt(dr[BaseFolderEntity.FieldIsPublic]);
     Enabled           = BaseBusinessLogic.ConvertToInt(dr[BaseFolderEntity.FieldEnabled]);
     DeletionStateCode = BaseBusinessLogic.ConvertToInt(dr[BaseFolderEntity.FieldDeletionStateCode]);
     Description       = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldDescription]);
     CreateOn          = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseFolderEntity.FieldCreateOn]);
     CreateUserId      = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldCreateUserId]);
     CreateBy          = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldCreateBy]);
     ModifiedOn        = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseFolderEntity.FieldModifiedOn]);
     ModifiedUserId    = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldModifiedUserId]);
     ModifiedBy        = BaseBusinessLogic.ConvertToString(dr[BaseFolderEntity.FieldModifiedBy]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
예제 #4
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id                   = BaseBusinessLogic.ConvertToInt(dr[BasePermissionEntity.FieldId]);
     ResourceId           = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldResourceId]);
     ResourceCategory     = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldResourceCategory]);
     PermissionId         = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldPermissionId]);
     PermissionConstraint = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldPermissionConstraint]);
     CompanyId            = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldCompanyId]);
     CompanyName          = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldCompanyName]);
     Enabled              = BaseBusinessLogic.ConvertToInt(dr[BasePermissionEntity.FieldEnabled]);
     DeletionStateCode    = BaseBusinessLogic.ConvertToInt(dr[BasePermissionEntity.FieldDeletionStateCode]);
     Description          = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldDescription]);
     CreateOn             = BaseBusinessLogic.ConvertToNullableDateTime(dr[BasePermissionEntity.FieldCreateOn]);
     CreateBy             = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldCreateBy]);
     CreateUserId         = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldCreateUserId]);
     ModifiedOn           = BaseBusinessLogic.ConvertToNullableDateTime(dr[BasePermissionEntity.FieldModifiedOn]);
     ModifiedBy           = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldModifiedBy]);
     ModifiedUserId       = BaseBusinessLogic.ConvertToString(dr[BasePermissionEntity.FieldModifiedUserId]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
예제 #5
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id                       = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldId]);
     ProcessId                = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldProcessId]);
     Code                     = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldCode]);
     CommitmentDays           = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldCommitmentDays]);
     FullName                 = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldFullName]);
     AuditDepartmentId        = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldAuditDepartmentId]);
     AuditDepartmentName      = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldAuditDepartmentName]);
     AuditUserId              = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldAuditUserId]);
     AuditUserCode            = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldAuditUserCode]);
     AuditUserRealName        = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldAuditUserRealName]);
     AuditRoleId              = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldAuditRoleId]);
     AuditRoleRealName        = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldAuditRoleRealName]);
     ActivityType             = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldActivityType]);
     DefaultAuditUserId       = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldDefaultAuditUserId]);
     DefaultAuditUserRealName = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldDefaultAuditUserRealName]);
     EditFields               = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldEditFields]);
     AllowSkip                = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldAllowSkip]);
     AllowPrint               = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldAllowPrint]);
     AllowEditDocuments       = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldAllowEditDocuments]);
     AllowAuditQuash          = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldAllowAuditQuash]);
     AllowAuditPass           = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldAllowAuditPass]);
     EnterConstraint          = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldEnterConstraint]);
     EndConstraint            = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldEndConstraint]);
     SortCode                 = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldSortCode]);
     Enabled                  = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldEnabled]);
     DeletionStateCode        = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowActivityEntity.FieldDeletionStateCode]);
     Description              = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldDescription]);
     CreateOn                 = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowActivityEntity.FieldCreateOn]);
     CreateUserId             = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldCreateUserId]);
     CreateBy                 = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldCreateBy]);
     ModifiedOn               = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowActivityEntity.FieldModifiedOn]);
     ModifiedUserId           = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldModifiedUserId]);
     ModifiedBy               = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowActivityEntity.FieldModifiedBy]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
예제 #6
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id                 = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldId]);
     ParentId           = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldParentId]);
     Code               = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldCode]);
     FullName           = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldFullName]);
     CategoryCode       = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldCategoryCode]);
     ImageIndex         = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldImageIndex]);
     SelectedImageIndex = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldSelectedImageIndex]);
     NavigateUrl        = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldNavigateUrl]);
     /// WebBrowser = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldWebBrowser]);
     ImagUrl      = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldImagUrl]);
     Target       = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldTarget]);
     FormName     = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldFormName]);
     AssemblyName = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldAssemblyName]);
     // PermissionScopeTables = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldPermissionScopeTables]);
     AuthorizedDays    = BaseBusinessLogic.ConvertToNullableInt(dr[BaseModuleEntity.FieldAuthorizedDays]);
     SortCode          = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldSortCode]);
     Enabled           = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldEnabled]);
     DeletionStateCode = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldDeletionStateCode]);
     IsMenu            = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldIsMenu]);
     IsPublic          = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldIsPublic]);
     IsScope           = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldIsScope]);
     IsVisible         = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldIsVisible]);
     Expand            = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldExpand]);
     AllowEdit         = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldAllowEdit]);
     AllowDelete       = BaseBusinessLogic.ConvertToInt(dr[BaseModuleEntity.FieldAllowDelete]);
     Description       = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldDescription]);
     CreateOn          = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseModuleEntity.FieldCreateOn]);
     CreateUserId      = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldCreateUserId]);
     CreateBy          = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldCreateBy]);
     ModifiedOn        = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseModuleEntity.FieldModifiedOn]);
     ModifiedUserId    = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldModifiedUserId]);
     ModifiedBy        = BaseBusinessLogic.ConvertToString(dr[BaseModuleEntity.FieldModifiedBy]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
예제 #7
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dataRow">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     GetFromExpand(dr);
     UserId            = BaseBusinessLogic.ConvertToString(dr[UserByGUIDEntity.FieldUserId]);
     FullName          = BaseBusinessLogic.ConvertToString(dr[UserByGUIDEntity.FieldFullName]);
     Salary            = BaseBusinessLogic.ConvertToNullableDecimal(dr[UserByGUIDEntity.FieldSalary]);
     Age               = BaseBusinessLogic.ConvertToNullableInt(dr[UserByGUIDEntity.FieldAge]);
     Birthday          = BaseBusinessLogic.ConvertToNullableDateTime(dr[UserByGUIDEntity.FieldBirthday]);
     Photo             = BaseBusinessLogic.ConvertToByte(dr[UserByGUIDEntity.FieldPhoto]);
     AllowEdit         = BaseBusinessLogic.ConvertToNullableInt(dr[UserByGUIDEntity.FieldAllowEdit]);
     AllowDelete       = BaseBusinessLogic.ConvertToNullableInt(dr[UserByGUIDEntity.FieldAllowDelete]);
     Enabled           = BaseBusinessLogic.ConvertToInt(dr[UserByGUIDEntity.FieldEnabled]);
     DeletionStateCode = BaseBusinessLogic.ConvertToNullableInt(dr[UserByGUIDEntity.FieldDeletionStateCode]);
     SortCode          = BaseBusinessLogic.ConvertToInt(dr[UserByGUIDEntity.FieldSortCode]);
     Description       = BaseBusinessLogic.ConvertToString(dr[UserByGUIDEntity.FieldDescription]);
     CreateOn          = BaseBusinessLogic.ConvertToNullableDateTime(dr[UserByGUIDEntity.FieldCreateOn]);
     CreateUserId      = BaseBusinessLogic.ConvertToString(dr[UserByGUIDEntity.FieldCreateUserId]);
     CreateBy          = BaseBusinessLogic.ConvertToString(dr[UserByGUIDEntity.FieldCreateBy]);
     ModifiedOn        = BaseBusinessLogic.ConvertToNullableDateTime(dr[UserByGUIDEntity.FieldModifiedOn]);
     ModifiedUserId    = BaseBusinessLogic.ConvertToString(dr[UserByGUIDEntity.FieldModifiedUserId]);
     ModifiedBy        = BaseBusinessLogic.ConvertToString(dr[UserByGUIDEntity.FieldModifiedBy]);
     return(this);
 }
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dataRow">数据行</param>
 public BaseItemDetailsEntity GetFrom(DataRow dataRow)
 {
     this.GetFromExpand(dataRow);
     this.Id                = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldId]);
     this.ParentId          = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldParentId]);
     this.ItemCode          = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldItemCode]);
     this.ItemName          = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldItemName]);
     this.ItemValue         = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldItemValue]);
     this.AllowEdit         = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldAllowEdit]);
     this.AllowDelete       = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldAllowDelete]);
     this.IsPublic          = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldIsPublic]);
     this.Enabled           = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldEnabled]);
     this.DeletionStateCode = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldDeletionStateCode]);
     this.SortCode          = BaseBusinessLogic.ConvertToInt(dataRow[BaseItemDetailsEntity.FieldSortCode]);
     this.Description       = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldDescription]);
     this.CreateOn          = BaseBusinessLogic.ConvertToDateTime(dataRow[BaseItemDetailsEntity.FieldCreateOn]);
     this.CreateUserId      = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldCreateUserId]);
     this.CreateBy          = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldCreateBy]);
     this.ModifiedOn        = BaseBusinessLogic.ConvertToDateTime(dataRow[BaseItemDetailsEntity.FieldModifiedOn]);
     this.ModifiedUserId    = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldModifiedUserId]);
     this.ModifiedBy        = BaseBusinessLogic.ConvertToString(dataRow[BaseItemDetailsEntity.FieldModifiedBy]);
     return(this);
 }
예제 #9
0
        /// <summary>
        /// 从数据行读取
        /// </summary>
        /// <param name="dr">数据行</param>
        protected override BaseEntity GetFrom(IDataRow dr)
        {
            Id = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldId]);

            // 2016-02-14 吉日嘎拉 改进日志的记录数据、把一些核心参数记录下来。
            TaskId       = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldTaskId]);
            Service      = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldService]);
            CompanyId    = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldCompanyId]);
            ElapsedTicks = BaseBusinessLogic.ConvertToInt(dr[BaseLogEntity.FieldElapsedTicks]);
            StartTime    = BaseBusinessLogic.ConvertToDateTime(dr[BaseLogEntity.FieldStartTime]);
            UserId       = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldUserId]);
            UserRealName = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldUserRealName]);
            Parameters   = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldParameters]);
            UrlReferrer  = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldUrlReferrer]);
            WebUrl       = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldWebUrl]);
            ClientIP     = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldClientIP]);
            ServerIP     = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldServerIP]);
            Description  = BaseBusinessLogic.ConvertToString(dr[BaseLogEntity.FieldDescription]);

            // 获取扩展属性
            GetFromExpand(dr);
            return(this);
        }
예제 #10
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     GetFromExpand(dr);
     Id                = BaseBusinessLogic.ConvertToInt(dr[BaseStationEntity.FieldId]);
     OrganizeId        = BaseBusinessLogic.ConvertToNullableInt(dr[BaseStationEntity.FieldOrganizeId]);
     Code              = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldCode]);
     RealName          = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldRealName]);
     CategoryCode      = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldCategoryCode]);
     MacAddress        = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldMacAddress]);
     UploadTime        = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseStationEntity.FieldUploadTime]);
     DownloadTime      = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseStationEntity.FieldDownloadTime]);
     SortCode          = BaseBusinessLogic.ConvertToNullableInt(dr[BaseStationEntity.FieldSortCode]);
     DeletionStateCode = BaseBusinessLogic.ConvertToInt(dr[BaseStationEntity.FieldDeletionStateCode]);
     Enabled           = BaseBusinessLogic.ConvertToInt(dr[BaseStationEntity.FieldEnabled]);
     Description       = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldDescription]);
     CreateOn          = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseStationEntity.FieldCreateOn]);
     CreateUserId      = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldCreateUserId]);
     CreateBy          = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldCreateBy]);
     ModifiedOn        = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseStationEntity.FieldModifiedOn]);
     ModifiedUserId    = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldModifiedUserId]);
     ModifiedBy        = BaseBusinessLogic.ConvertToString(dr[BaseStationEntity.FieldModifiedBy]);
     return(this);
 }
예제 #11
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldId]);
     // 2016-03-02 吉日嘎拉 防止程序出错,没有这个字段也可以正常运行
     if (dr.ContainsColumn(BaseUserLogOnEntity.FieldCompanyId))
     {
         CompanyId = BaseBusinessLogic.ConvertToString(dr[BaseUserLogOnEntity.FieldCompanyId]);
     }
     Mobile                 = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldMobile]);
     MobileValiated         = BaseBusinessLogic.ConvertToInt(dr[BaseUserContactEntity.FieldMobileValiated]);
     MobileVerificationDate = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseUserContactEntity.FieldMobileVerificationDate]);
     ShowMobile             = BaseBusinessLogic.ConvertToInt(dr[BaseUserContactEntity.FieldShowMobile]);
     Telephone              = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldTelephone]);
     Extension              = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldExtension]);
     ShortNumber            = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldShortNumber]);
     WW               = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldWW]);
     QQ               = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldQQ]);
     WeChat           = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldWeChat]);
     WeChatOpenId     = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldWeChatOpenId]);
     WeChatValiated   = BaseBusinessLogic.ConvertToInt(dr[BaseUserContactEntity.FieldWeChatValiated]);
     YiXin            = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldYiXin]);
     YiXinValiated    = BaseBusinessLogic.ConvertToInt(dr[BaseUserContactEntity.FieldYiXinValiated]);
     Email            = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldEmail]);
     EmailValiated    = BaseBusinessLogic.ConvertToInt(dr[BaseUserContactEntity.FieldEmailValiated]);
     CompanyMail      = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldCompanyMail]);
     EmergencyContact = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldEmergencyContact]);
     YY               = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldYY]);
     CreateOn         = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseUserContactEntity.FieldCreateOn]);
     CreateUserId     = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldCreateUserId]);
     CreateBy         = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldCreateBy]);
     ModifiedOn       = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseUserContactEntity.FieldModifiedOn]);
     ModifiedUserId   = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldModifiedUserId]);
     ModifiedBy       = BaseBusinessLogic.ConvertToString(dr[BaseUserContactEntity.FieldModifiedBy]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
 /// <summary>
 /// 从数据流读取
 /// </summary>
 /// <param name="dataReader">数据流</param>
 public BaseWorkFlowCurrentEntity GetFrom(IDataReader dataReader)
 {
     this.GetFromExpand(dataReader);;
     this.Id                = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldId]);
     this.CategoryCode      = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldCategoryCode]);
     this.CategoryFullName  = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldCategoryFullName]);
     this.ObjectId          = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldObjectId]);
     this.ObjectFullName    = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldObjectFullName]);
     this.WorkFlowId        = BaseBusinessLogic.ConvertToInt(dataReader[BaseWorkFlowCurrentEntity.FieldWorkFlowId]);
     this.ActivityId        = BaseBusinessLogic.ConvertToInt(dataReader[BaseWorkFlowCurrentEntity.FieldActivityId]);
     this.ActivityFullName  = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldActivityFullName]);
     this.ToDepartmentId    = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldToDepartmentId]);
     this.ToDepartmentName  = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldToDepartmentName]);
     this.ToUserId          = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldToUserId]);
     this.ToUserRealName    = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldToUserRealName]);
     this.ToRoleId          = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldToRoleId]);
     this.ToRoleRealName    = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldToRoleRealName]);
     this.AuditUserId       = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldAuditUserId]);
     this.AuditUserCode     = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldAuditUserCode]);
     this.AuditUserRealName = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldAuditUserRealName]);
     this.SendDate          = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseWorkFlowCurrentEntity.FieldSendDate]);
     this.AuditDate         = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseWorkFlowCurrentEntity.FieldAuditDate]);
     this.AuditIdea         = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldAuditIdea]);
     this.AuditStatus       = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldAuditStatus]);
     this.AuditStatusName   = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldAuditStatusName]);
     this.SortCode          = BaseBusinessLogic.ConvertToInt(dataReader[BaseWorkFlowCurrentEntity.FieldSortCode]);
     this.Enabled           = BaseBusinessLogic.ConvertToInt(dataReader[BaseWorkFlowCurrentEntity.FieldEnabled]);
     this.DeletionStateCode = BaseBusinessLogic.ConvertToInt(dataReader[BaseWorkFlowCurrentEntity.FieldDeletionStateCode]);
     this.Description       = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldDescription]);
     this.CreateOn          = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseWorkFlowCurrentEntity.FieldCreateOn]);
     this.CreateUserId      = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldCreateUserId]);
     this.CreateBy          = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldCreateBy]);
     this.ModifiedOn        = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseWorkFlowCurrentEntity.FieldModifiedOn]);
     this.ModifiedUserId    = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldModifiedUserId]);
     this.ModifiedBy        = BaseBusinessLogic.ConvertToString(dataReader[BaseWorkFlowCurrentEntity.FieldModifiedBy]);
     return(this);
 }
예제 #13
0
        /// <summary>
        /// 从数据行读取
        /// </summary>
        /// <param name="dr">数据行</param>
		protected override BaseEntity GetFrom(IDataRow dr)
        {
            Id = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldId]);
            OrganizeId = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldOrganizeId]);
            Code = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldCode]);
            RealName = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldRealName]);
            CategoryCode = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldCategoryCode]);
            AllowEdit = BaseBusinessLogic.ConvertToInt(dr[BaseRoleEntity.FieldAllowEdit]);
            AllowDelete = BaseBusinessLogic.ConvertToInt(dr[BaseRoleEntity.FieldAllowDelete]);
            IsVisible = BaseBusinessLogic.ConvertToInt(dr[BaseRoleEntity.FieldIsVisible]);
            SortCode = BaseBusinessLogic.ConvertToInt(dr[BaseRoleEntity.FieldSortCode]);
            DeletionStateCode = BaseBusinessLogic.ConvertToInt(dr[BaseRoleEntity.FieldDeletionStateCode]);
            Enabled = BaseBusinessLogic.ConvertToInt(dr[BaseRoleEntity.FieldEnabled]);
            Description = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldDescription]);
            CreateOn = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseRoleEntity.FieldCreateOn]);
            CreateUserId = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldCreateUserId]);
            CreateBy = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldCreateBy]);
            ModifiedOn = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseRoleEntity.FieldModifiedOn]);
            ModifiedUserId = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldModifiedUserId]);
            ModifiedBy = BaseBusinessLogic.ConvertToString(dr[BaseRoleEntity.FieldModifiedBy]);
            // 获取扩展属性
            GetFromExpand(dr);
            return this;
        }
예제 #14
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id                = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldId]);
     CompanyId         = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldCompanyId]);
     CompanyName       = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldCompanyName]);
     DepartmentId      = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldDepartmentId]);
     DepartmentName    = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldDepartmentName]);
     FolderId          = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldFolderId]);
     CategoryCode      = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldCategoryCode]);
     Code              = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldCode]);
     Title             = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldTitle]);
     FilePath          = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldFilePath]);
     Introduction      = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldIntroduction]);
     Contents          = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldContents]);
     Source            = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldSource]);
     Keywords          = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldKeywords]);
     FileSize          = BaseBusinessLogic.ConvertToInt(dr[BaseNewsEntity.FieldFileSize]);
     ImageUrl          = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldImageUrl]);
     SubPage           = BaseBusinessLogic.ConvertToInt(dr[BaseNewsEntity.FieldSubPage]);
     HomePage          = BaseBusinessLogic.ConvertToInt(dr[BaseNewsEntity.FieldHomePage]);
     AuditStatus       = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldAuditStatus]);
     ReadCount         = BaseBusinessLogic.ConvertToInt(dr[BaseNewsEntity.FieldReadCount]);
     DeletionStateCode = BaseBusinessLogic.ConvertToInt(dr[BaseNewsEntity.FieldDeletionStateCode]);
     Description       = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldDescription]);
     Enabled           = BaseBusinessLogic.ConvertToInt(dr[BaseNewsEntity.FieldEnabled]);
     SortCode          = BaseBusinessLogic.ConvertToInt(dr[BaseNewsEntity.FieldSortCode]);
     CreateOn          = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseNewsEntity.FieldCreateOn]);
     CreateBy          = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldCreateBy]);
     CreateUserId      = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldCreateUserId]);
     ModifiedOn        = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseNewsEntity.FieldModifiedOn]);
     ModifiedBy        = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldModifiedBy]);
     ModifiedUserId    = BaseBusinessLogic.ConvertToString(dr[BaseNewsEntity.FieldModifiedUserId]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
예제 #15
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id                = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowHistoryEntity.FieldId]);
     CurrentFlowId     = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldCurrentFlowId]);
     ProcessId         = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowHistoryEntity.FieldProcessId]);
     ActivityId        = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowHistoryEntity.FieldActivityId]);
     ActivityCode      = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldActivityCode]);
     ActivityFullName  = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldActivityFullName]);
     ToDepartmentId    = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldToDepartmentId]);
     ToDepartmentName  = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldToDepartmentName]);
     ToUserId          = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldToUserId]);
     ToUserRealName    = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldToUserRealName]);
     ToRoleId          = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldToRoleId]);
     ToRoleRealName    = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldToRoleRealName]);
     AuditUserId       = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldAuditUserId]);
     AuditUserCode     = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldAuditUserCode]);
     AuditUserRealName = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldAuditUserRealName]);
     SendDate          = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowHistoryEntity.FieldSendDate]);
     AuditDate         = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowHistoryEntity.FieldAuditDate]);
     AuditIdea         = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldAuditIdea]);
     AuditStatus       = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldAuditStatus]);
     AuditStatusName   = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldAuditStatusName]);
     SortCode          = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowHistoryEntity.FieldSortCode]);
     Enabled           = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowHistoryEntity.FieldEnabled]);
     DeletionStateCode = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowHistoryEntity.FieldDeletionStateCode]);
     Description       = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldDescription]);
     CreateOn          = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowHistoryEntity.FieldCreateOn]);
     CreateUserId      = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldCreateUserId]);
     CreateBy          = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldCreateBy]);
     ModifiedOn        = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowHistoryEntity.FieldModifiedOn]);
     ModifiedUserId    = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldModifiedUserId]);
     ModifiedBy        = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowHistoryEntity.FieldModifiedBy]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
 /// <summary>
 /// 从数据流读取
 /// </summary>
 /// <param name="dataReader">数据流</param>
 public BaseContactDetailsEntity GetFrom(IDataReader dataReader)
 {
     this.GetFromExpand(dataReader);
     this.Id                = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldId]);
     this.ContactId         = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldContactId]);
     this.Category          = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldCategory]);
     this.ReceiverId        = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldReceiverId]);
     this.ReceiverRealName  = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldReceiverRealName]);
     this.IsNew             = BaseBusinessLogic.ConvertToInt(dataReader[BaseContactDetailsEntity.FieldIsNew]);
     this.NewComment        = BaseBusinessLogic.ConvertToInt(dataReader[BaseContactDetailsEntity.FieldNewComment]);
     this.LastViewIP        = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldLastViewIP]);
     this.LastViewDate      = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldLastViewDate]);
     this.Enabled           = BaseBusinessLogic.ConvertToInt(dataReader[BaseContactDetailsEntity.FieldEnabled]);
     this.DeletionStateCode = BaseBusinessLogic.ConvertToInt(dataReader[BaseContactDetailsEntity.FieldDeletionStateCode]);
     this.SortCode          = BaseBusinessLogic.ConvertToInt(dataReader[BaseContactDetailsEntity.FieldSortCode]);
     this.Description       = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldDescription]);
     this.CreateOn          = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseContactDetailsEntity.FieldCreateOn]);
     this.CreateUserId      = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldCreateUserId]);
     this.CreateBy          = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldCreateBy]);
     this.ModifiedOn        = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseContactDetailsEntity.FieldModifiedOn]);
     this.ModifiedUserId    = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldModifiedUserId]);
     this.ModifiedBy        = BaseBusinessLogic.ConvertToString(dataReader[BaseContactDetailsEntity.FieldModifiedBy]);
     return(this);
 }
예제 #17
0
 /// <summary>
 /// 从数据流读取
 /// </summary>
 /// <param name="dataReader">数据流</param>
 public BaseRoleEntity GetFrom(IDataReader dataReader)
 {
     this.GetFromExpand(dataReader);
     this.Id                = BaseBusinessLogic.ConvertToInt(dataReader[BaseRoleEntity.FieldId]);
     this.SystemId          = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldSystemId]);
     this.OrganizeId        = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldOrganizeId]);
     this.Code              = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldCode]);
     this.RealName          = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldRealName]);
     this.CategoryCode      = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldCategoryCode]);
     this.AllowEdit         = BaseBusinessLogic.ConvertToInt(dataReader[BaseRoleEntity.FieldAllowEdit]);
     this.AllowDelete       = BaseBusinessLogic.ConvertToInt(dataReader[BaseRoleEntity.FieldAllowDelete]);
     this.IsVisible         = BaseBusinessLogic.ConvertToInt(dataReader[BaseRoleEntity.FieldIsVisible]);
     this.SortCode          = BaseBusinessLogic.ConvertToInt(dataReader[BaseRoleEntity.FieldSortCode]);
     this.DeletionStateCode = BaseBusinessLogic.ConvertToInt(dataReader[BaseRoleEntity.FieldDeletionStateCode]);
     this.Enabled           = BaseBusinessLogic.ConvertToInt(dataReader[BaseRoleEntity.FieldEnabled]);
     this.Description       = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldDescription]);
     this.CreateOn          = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseRoleEntity.FieldCreateOn]);
     this.CreateUserId      = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldCreateUserId]);
     this.CreateBy          = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldCreateBy]);
     this.ModifiedOn        = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseRoleEntity.FieldModifiedOn]);
     this.ModifiedUserId    = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldModifiedUserId]);
     this.ModifiedBy        = BaseBusinessLogic.ConvertToString(dataReader[BaseRoleEntity.FieldModifiedBy]);
     return(this);
 }
예제 #18
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id                  = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldId]);
     ProcessId           = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldProcessId]);
     Code                = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldCode]);
     FullName            = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldFullName]);
     AuditDepartmentId   = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldAuditDepartmentId]);
     AuditDepartmentName = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldAuditDepartmentName]);
     AuditUserId         = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldAuditUserId]);
     AuditUserCode       = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldAuditUserCode]);
     AuditUserRealName   = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldAuditUserRealName]);
     AuditRoleId         = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldAuditRoleId]);
     AuditRoleRealName   = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldAuditRoleRealName]);
     if (dr.ContainsColumn(BaseWorkFlowStepEntity.FieldActivityId))
     {
         ActivityId = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldActivityId]);
     }
     else
     {
         ActivityId = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldId]);
     }
     ActivityType       = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldActivityType]);
     AllowPrint         = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldAllowPrint]);
     AllowEditDocuments = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldAllowEditDocuments]);
     SortCode           = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldSortCode]);
     Enabled            = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldEnabled]);
     DeletionStateCode  = BaseBusinessLogic.ConvertToInt(dr[BaseWorkFlowStepEntity.FieldDeletionStateCode]);
     Description        = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldDescription]);
     CreateOn           = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowStepEntity.FieldCreateOn]);
     CreateUserId       = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldCreateUserId]);
     CreateBy           = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldCreateBy]);
     ModifiedOn         = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseWorkFlowStepEntity.FieldModifiedOn]);
     ModifiedUserId     = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldModifiedUserId]);
     ModifiedBy         = BaseBusinessLogic.ConvertToString(dr[BaseWorkFlowStepEntity.FieldModifiedBy]);
     return(this);
 }
예제 #19
0
        /// <summary>
        /// 从数据流读取
        /// </summary>
        /// <param name="dataReader">数据流</param>
        public BaseUserEntity GetFrom(IDataReader dataReader)
        {
            this.GetFromExpand(dataReader);
            this.Id             = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldId]);
            this.Code           = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldCode]);
            this.UserName       = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldUserName]);
            this.RealName       = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldRealName]);
            this.QuickQuery     = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldQuickQuery]);
            this.RoleId         = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldRoleId]);
            this.SecurityLevel  = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldSecurityLevel]);
            this.UserFrom       = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldUserFrom]);
            this.WorkCategory   = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldWorkCategory]);
            this.CompanyId      = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldCompanyId]);
            this.CompanyName    = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldCompanyName]);
            this.SubCompanyId   = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldSubCompanyId]);
            this.SubCompanyName = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldSubCompanyName]);
            this.DepartmentId   = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldDepartmentId]);
            this.DepartmentName = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldDepartmentName]);
            this.WorkgroupId    = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldWorkgroupId]);
            this.WorkgroupName  = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldWorkgroupName]);
            this.Gender         = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldGender]);
            this.Mobile         = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldMobile]);
            this.Telephone      = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldTelephone]);

            this.Birthday              = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldBirthday]);
            this.Duty                  = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldDuty]);
            this.Title                 = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldTitle]);
            this.UserPassword          = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldUserPassword]);
            this.ChangePasswordDate    = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldChangePasswordDate]);
            this.CommunicationPassword = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldCommunicationPassword]);
            this.SignedPassword        = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldSignedPassword]);
            this.PublicKey             = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldPublicKey]);
            this.OICQ                  = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldOICQ]);
            this.Email                 = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldEmail]);
            this.Lang                  = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldLang]);
            this.Theme                 = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldTheme]);

            this.AllowStartTime = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldAllowStartTime]);
            this.AllowEndTime   = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldAllowEndTime]);
            this.LockStartDate  = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldLockStartDate]);
            this.LockEndDate    = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldLockEndDate]);

            this.FirstVisit        = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldFirstVisit]);
            this.PreviousVisit     = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldPreviousVisit]);
            this.LastVisit         = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldLastVisit]);
            this.LogOnCount        = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldLogOnCount]);
            this.IsStaff           = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldIsStaff]);
            this.AuditStatus       = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldAuditStatus]);
            this.IsVisible         = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldIsVisible]);
            this.UserOnLine        = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldUserOnLine]);
            this.IPAddress         = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldIPAddress]);
            this.MACAddress        = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldMACAddress]);
            this.OpenId            = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldOpenId]);
            this.Question          = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldQuestion]);
            this.AnswerQuestion    = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldAnswerQuestion]);
            this.UserAddressId     = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldUserAddressId]);
            this.DeletionStateCode = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldDeletionStateCode]);
            this.Enabled           = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldEnabled]);
            this.SortCode          = BaseBusinessLogic.ConvertToInt(dataReader[BaseUserEntity.FieldSortCode]);
            this.Description       = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldDescription]);
            this.CreateOn          = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldCreateOn]);
            this.CreateUserId      = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldCreateUserId]);
            this.CreateBy          = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldCreateBy]);
            this.ModifiedOn        = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseUserEntity.FieldModifiedOn]);
            this.ModifiedUserId    = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldModifiedUserId]);
            this.ModifiedBy        = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldModifiedBy]);
            this.Signature         = BaseBusinessLogic.ConvertToString(dataReader[BaseUserEntity.FieldSignature]);
            return(this);
        }
예제 #20
0
        public static void CachePreheatingSpelling(bool flushDb = false)
        {
            // 组织机构数据缓存预热实现
            BaseOrganizeManager organizeManager = new Business.BaseOrganizeManager();

            // 减少数据库连接、减少内存站用、一边度取、一边设置缓存,只读取需要的数据
            organizeManager.SelectFields = BaseOrganizeEntity.FieldId
                                           + ", " + BaseOrganizeEntity.FieldCode
                                           + ", " + BaseOrganizeEntity.FieldFullName
                                           + " , " + BaseOrganizeEntity.FieldSimpleSpelling
                                           + " , " + BaseOrganizeEntity.FieldCostCenterId
                                           + " , " + BaseOrganizeEntity.FieldProvinceId
                                           + " , " + BaseOrganizeEntity.FieldCompanyId
                                           + " , " + BaseOrganizeEntity.FieldCityId
                                           + " , " + BaseOrganizeEntity.FieldParentId
                                           + " , " + BaseOrganizeEntity.FieldSendAir
                                           + " , " + BaseOrganizeEntity.FieldEnabled
                                           + " , " + BaseOrganizeEntity.FieldDeletionStateCode
                                           + " , " + BaseOrganizeEntity.FieldSortCode;

            // 读取有效的,没有被删除的网点数据
            // List<KeyValuePair<string, object>> parameters = new List<KeyValuePair<string, object>>();
            // parameters.Add(new KeyValuePair<string, object>(BaseOrganizeEntity.FieldEnabled, 1));
            // parameters.Add(new KeyValuePair<string, object>(BaseOrganizeEntity.FieldDeletionStateCode, 0));

            // 2016-02-19 宋彪 PooledRedisHelper.GetClient() 改为 PooledRedisHelper.GetSpellingClient()
            using (var redisClient = PooledRedisHelper.GetSpellingClient())
            {
                if (flushDb)
                {
                    redisClient.FlushDb();
                }

                double score = 0;

                using (IDataReader dataReader = organizeManager.ExecuteReader(0, BaseOrganizeEntity.FieldFullName))
                {
                    while (dataReader.Read())
                    {
                        score++;

                        // 读取到的数据直接强制设置到缓存里
                        BaseOrganizeEntity entity = new BaseOrganizeEntity();
                        entity.Id             = dataReader[BaseOrganizeEntity.FieldId].ToString();
                        entity.Code           = dataReader[BaseOrganizeEntity.FieldCode].ToString();
                        entity.FullName       = dataReader[BaseOrganizeEntity.FieldFullName].ToString();
                        entity.SimpleSpelling = dataReader[BaseOrganizeEntity.FieldSimpleSpelling].ToString().ToLower();

                        entity.CostCenterId      = dataReader[BaseOrganizeEntity.FieldCostCenterId].ToString();
                        entity.ProvinceId        = dataReader[BaseOrganizeEntity.FieldProvinceId].ToString();
                        entity.CompanyId         = dataReader[BaseOrganizeEntity.FieldCompanyId].ToString();
                        entity.CityId            = dataReader[BaseOrganizeEntity.FieldCityId].ToString();
                        entity.ParentId          = dataReader[BaseOrganizeEntity.FieldParentId].ToString();
                        entity.SendAir           = BaseBusinessLogic.ConvertToInt(dataReader[BaseOrganizeEntity.FieldSendAir]);
                        entity.Enabled           = BaseBusinessLogic.ConvertToInt(dataReader[BaseOrganizeEntity.FieldEnabled]);
                        entity.DeletionStateCode = BaseBusinessLogic.ConvertToInt(dataReader[BaseOrganizeEntity.FieldDeletionStateCode]);
                        entity.SortCode          = BaseBusinessLogic.ConvertToInt(dataReader[BaseOrganizeEntity.FieldSortCode]);

                        if (!flushDb)
                        {
                            score = entity.SortCode.Value;
                        }

                        CachePreheatingSpelling(redisClient, entity, score);

                        if (flushDb)
                        {
                            // 2016-02-02 吉日嘎拉 设置一下排序属性
                            new Business.BaseManager(BaseOrganizeEntity.TableName).SetProperty(entity.Id, new KeyValuePair <string, object>(BaseOrganizeEntity.FieldSortCode, score));
                        }
                    }
                }
            }
        }
 /// <summary>
 /// 从数据流读取
 /// </summary>
 /// <param name="dataReader">数据流</param>
 public override void GetFromExpand(IDataReader dataReader)
 {
     this.Layer = BaseBusinessLogic.ConvertToInt(dataReader[BaseOrganizeEntity.FieldLayer]);
 }
예제 #22
0
 /// <summary>
 /// 从数据行读取
 /// </summary>
 /// <param name="dr">数据行</param>
 protected override BaseEntity GetFrom(IDataRow dr)
 {
     Id             = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldId]);
     UserFrom       = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldUserFrom]);
     Code           = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldCode]);
     UserName       = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldUserName]);
     NickName       = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldNickName]);
     RealName       = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldRealName]);
     QuickQuery     = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldQuickQuery]);
     SimpleSpelling = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldSimpleSpelling]);
     SecurityLevel  = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldSecurityLevel]);
     WorkCategory   = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldWorkCategory]);
     CompanyId      = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldCompanyId]);
     // 2015-12-29 吉日嘎拉 防止程序出错,没有这个字段也可以正常运行
     if (dr.ContainsColumn(BaseUserEntity.FieldCompanyCode))
     {
         CompanyCode = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldCompanyCode]);
     }
     CompanyName       = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldCompanyName]);
     SubCompanyId      = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldSubCompanyId]);
     SubCompanyName    = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldSubCompanyName]);
     DepartmentId      = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldDepartmentId]);
     DepartmentName    = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldDepartmentName]);
     SubDepartmentId   = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldSubDepartmentId]);
     SubDepartmentName = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldSubDepartmentName]);
     WorkgroupId       = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldWorkgroupId]);
     WorkgroupName     = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldWorkgroupName]);
     IDCard            = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldIDCard]);
     Gender            = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldGender]);
     Birthday          = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldBirthday]);
     Duty               = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldDuty]);
     Title              = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldTitle]);
     Province           = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldProvince]);
     City               = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldCity]);
     District           = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldDistrict]);
     HomeAddress        = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldHomeAddress]);
     Score              = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldScore]);
     IsAdministrator    = BaseBusinessLogic.ConvertToBoolean(dr[BaseUserEntity.FieldIsAdministrator]);
     Lang               = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldLang]);
     Theme              = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldTheme]);
     Signature          = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldSignature]);
     IsStaff            = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldIsStaff]);
     IsCheckBalance     = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldIsCheckBalance]);
     AuditStatus        = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldAuditStatus]);
     ManagerId          = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldManagerId]);
     ManagerAuditStatus = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldManagerAuditStatus]);
     ManagerAuditDate   = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseUserEntity.FieldManagerAuditDate]);
     IsVisible          = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldIsVisible]);
     DeletionStateCode  = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldDeletionStateCode]);
     Enabled            = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldEnabled]);
     SortCode           = BaseBusinessLogic.ConvertToInt(dr[BaseUserEntity.FieldSortCode]);
     Description        = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldDescription]);
     CreateOn           = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseUserEntity.FieldCreateOn]);
     CreateUserId       = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldCreateUserId]);
     CreateBy           = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldCreateBy]);
     ModifiedOn         = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseUserEntity.FieldModifiedOn]);
     ModifiedUserId     = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldModifiedUserId]);
     ModifiedBy         = BaseBusinessLogic.ConvertToString(dr[BaseUserEntity.FieldModifiedBy]);
     // 获取扩展属性
     GetFromExpand(dr);
     return(this);
 }
예제 #23
0
        /// <summary>
        /// 从数据行读取
        /// </summary>
        /// <param name="dr">数据行</param>
        protected override BaseEntity GetFrom(IDataRow dr)
        {
            Id           = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldId]);
            ParentId     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldParentId]);
            ParentName   = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldParentName]);
            Layer        = BaseBusinessLogic.ConvertToInt(dr[BaseOrganizeEntity.FieldLayer]);
            Code         = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCode]);
            FullName     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldFullName]);
            ShortName    = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldShortName]);
            StandardName = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldStandardName]);
            StandardCode = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldStandardCode]);

            QuickQuery     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldQuickQuery]);
            SimpleSpelling = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldSimpleSpelling]);
            CategoryCode   = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCategoryCode]);
            OuterPhone     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldOuterPhone]);
            InnerPhone     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldInnerPhone]);
            Fax            = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldFax]);
            Postalcode     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldPostalcode]);

            ProvinceId = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldProvinceId]);
            Province   = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldProvince]);
            CityId     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCityId]);
            City       = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCity]);
            DistrictId = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldDistrictId]);
            District   = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldDistrict]);
            StreetId   = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldStreetId]);
            Street     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldStreet]);

            Address         = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldAddress]);
            Web             = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldWeb]);
            IsInnerOrganize = BaseBusinessLogic.ConvertToInt(dr[BaseOrganizeEntity.FieldIsInnerOrganize]);
            Bank            = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldBank]);
            BankAccount     = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldBankAccount]);

            CompanyId   = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCompanyId]);
            CompanyCode = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCompanyCode]);
            CompanyName = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCompanyName]);

            if (dr.ContainsColumn(BaseOrganizeEntity.FieldCostCenterId))
            {
                CostCenterId = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCostCenterId]);
            }
            CostCenter = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCostCenter]);
            if (dr.ContainsColumn(BaseOrganizeEntity.FieldFinancialCenterId))
            {
                FinancialCenterId = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldFinancialCenterId]);
            }
            FinancialCenter = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldFinancialCenter]);
            if (dr.ContainsColumn(BaseOrganizeEntity.FieldManageId))
            {
                ManageId = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldManageId]);
            }
            if (dr.ContainsColumn(BaseOrganizeEntity.FieldManageName))
            {
                ManageName = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldManageName]);
            }
            Area           = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldArea]);
            JoiningMethods = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldJoiningMethods]);

            DeletionStateCode = BaseBusinessLogic.ConvertToInt(dr[BaseOrganizeEntity.FieldDeletionStateCode]);
            Enabled           = BaseBusinessLogic.ConvertToInt(dr[BaseOrganizeEntity.FieldEnabled]);
            SortCode          = BaseBusinessLogic.ConvertToInt(dr[BaseOrganizeEntity.FieldSortCode]);
            Description       = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldDescription]);
            CreateOn          = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseOrganizeEntity.FieldCreateOn]);
            CreateUserId      = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCreateUserId]);
            CreateBy          = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldCreateBy]);
            ModifiedOn        = BaseBusinessLogic.ConvertToNullableDateTime(dr[BaseOrganizeEntity.FieldModifiedOn]);
            ModifiedUserId    = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldModifiedUserId]);
            ModifiedBy        = BaseBusinessLogic.ConvertToString(dr[BaseOrganizeEntity.FieldModifiedBy]);
            // 获取扩展属性
            GetFromExpand(dr);
            return(this);
        }
예제 #24
0
 /// <summary>
 /// 从数据流读取
 /// </summary>
 /// <param name="dataReader">数据流</param>
 public BaseStaffEntity GetFrom(IDataReader dataReader)
 {
     this.GetFromExpand(dataReader);;
     this.Id                 = BaseBusinessLogic.ConvertToInt(dataReader[BaseStaffEntity.FieldId]);
     this.UserId             = BaseBusinessLogic.ConvertToInt(dataReader[BaseStaffEntity.FieldUserId]);
     this.UserName           = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldUserName]);
     this.RealName           = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldRealName]);
     this.Code               = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldCode]);
     this.Gender             = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldGender]);
     this.SubCompanyId       = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldSubCompanyId]);
     this.CompanyId          = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldCompanyId]);
     this.DepartmentId       = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldDepartmentId]);
     this.WorkgroupId        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldWorkgroupId]);
     this.QuickQuery         = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldQuickQuery]);
     this.DutyId             = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldDutyId]);
     this.IdentificationCode = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldIdentificationCode]);
     this.IDCard             = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldIDCard]);
     this.BankCode           = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldBankCode]);
     this.Email              = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldEmail]);
     this.Mobile             = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldMobile]);
     this.ShortNumber        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldShortNumber]);
     this.Telephone          = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldTelephone]);
     this.OICQ               = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldOICQ]);
     this.OfficePhone        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldOfficePhone]);
     this.OfficeZipCode      = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldOfficeZipCode]);
     this.OfficeAddress      = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldOfficeAddress]);
     this.OfficeFax          = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldOfficeFax]);
     this.Age                = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldAge]);
     this.Birthday           = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldBirthday]);
     this.Education          = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldEducation]);
     this.School             = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldSchool]);
     this.GraduationDate     = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldGraduationDate]);
     this.Major              = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldMajor]);
     this.Degree             = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldDegree]);
     this.TitleId            = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldTitleId]);
     this.TitleDate          = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldTitleDate]);
     this.TitleLevel         = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldTitleLevel]);
     this.WorkingDate        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldWorkingDate]);
     this.JoinInDate         = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldJoinInDate]);
     this.HomeZipCode        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldHomeZipCode]);
     this.HomeAddress        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldHomeAddress]);
     this.HomePhone          = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldHomePhone]);
     this.HomeFax            = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldHomeFax]);
     this.Province           = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldProvince]);
     this.CarCode            = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldCarCode]);
     this.City               = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldCity]);
     this.Area               = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldArea]);
     this.NativePlace        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldNativePlace]);
     this.Party              = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldParty]);
     this.Nation             = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldNation]);
     this.Nationality        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldNationality]);
     this.WorkingProperty    = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldWorkingProperty]);
     this.Competency         = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldCompetency]);
     this.EmergencyContact   = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldEmergencyContact]);
     this.IsDimission        = BaseBusinessLogic.ConvertToInt(dataReader[BaseStaffEntity.FieldIsDimission]);
     this.DimissionDate      = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldDimissionDate]);
     this.DimissionCause     = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldDimissionCause]);
     this.DimissionWhither   = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldDimissionWhither]);
     this.Enabled            = BaseBusinessLogic.ConvertToInt(dataReader[BaseStaffEntity.FieldEnabled]);
     this.DeletionStateCode  = BaseBusinessLogic.ConvertToInt(dataReader[BaseStaffEntity.FieldDeletionStateCode]);
     this.SortCode           = BaseBusinessLogic.ConvertToInt(dataReader[BaseStaffEntity.FieldSortCode]);
     this.Description        = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldDescription]);
     this.CreateOn           = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseStaffEntity.FieldCreateOn]);
     this.CreateUserId       = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldCreateUserId]);
     this.CreateBy           = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldCreateBy]);
     this.ModifiedOn         = BaseBusinessLogic.ConvertToDateTime(dataReader[BaseStaffEntity.FieldModifiedOn]);
     this.ModifiedUserId     = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldModifiedUserId]);
     this.ModifiedBy         = BaseBusinessLogic.ConvertToString(dataReader[BaseStaffEntity.FieldModifiedBy]);
     return(this);
 }