public virtual object[] GetRow() { string typeOrgName = TypeOrg.ToString(); return(new object[] { ID, CrmID, ShortName, typeOrgName, INN, (RealRegion == null) ? string.Empty : RealRegion.Name, (City == null) ? string.Empty : City, string.Empty, string.Empty, string.Empty }); }
private Organization GetOrganization(OrganizationModel model) { Organization organization = organizationList.GetItem(model.NumberSF); if (organization == null) { try { TypeOrg typeOrg = GetTypeOrg(model); organization = new Organization(typeOrg); } catch (NullReferenceException) { if (model.RecordType == "RU_Other") { LogManager.WriteNotFound(model.ClientType, "Organization subtype", model.NumberSF); } else { LogManager.WriteNotFound(model.RecordType, "Organization type", model.NumberSF); } } } return(organization); }
public Organization(TypeOrg typeOrg) { _provider = Provider.GetProvider(); TypeOrg = typeOrg; NumberSF = string.Empty; ShortName = string.Empty; }
public static Organization CreateItem(TypeOrg typeOrg, Organization parentOrganization = null) { Organization organization = (typeOrg == TypeOrg.ЛПУ) ? new LPU(typeOrg) : new Organization(typeOrg); organization.ParentOrganization = parentOrganization; return(organization); }
private Organization GetOrganization(TypeOrg typeOrg, bool haveParent) { Organization organization = new Organization(typeOrg); if (haveParent) { organization.ParentOrganization = OrganizationList.GetUniqueInstance().GetFirst(); } return organization; }
private Organization GetOrganization(TypeOrg typeOrg, bool haveParent) { Organization organization = new Organization(typeOrg); if (haveParent) { organization.ParentOrganization = OrganizationList.GetUniqueInstance().GetFirst(); } return(organization); }
public OrganizationListController(DataGridView dgv) : base(dgv) { _dgv = dgv; _userList = UserList.GetUniqueInstance(); _lpuList = new LpuList(); _user = _userList.GetItem(globalData.UserID) as User; _typeOrg = TypeOrg.ЛПУ; }
public static Task <Organization> CreateItemAsync(DataRow row) { TypeOrg typeOrg = (TypeOrg)Convert.ToInt32(row["TypeOrg_id"].ToString()); Task <Organization> task = new Task <Organization>(() => { return((typeOrg == TypeOrg.ЛПУ) ? new LPU(row) : new Organization(row)); }); task.Start(); return(task); }
public static Organization CreateItem(TypeOrg typeOrg, Organization parentOrganization = null) { Organization organization = (typeOrg == TypeOrg.ЛПУ) ? new LPU(typeOrg) : new Organization(typeOrg); organization.ParentOrganization = parentOrganization; return organization; }
public string GetOrgType(TypeOrg typeOrg, bool haveParent) { Organization organization = GetOrganization(typeOrg, haveParent); return(_exportOrganization.GetRecordType(organization)); }
public static Organization CreateItem(DataRow row) { TypeOrg typeOrg = (TypeOrg)Convert.ToInt32(row["TypeOrg_id"].ToString()); return((typeOrg == TypeOrg.ЛПУ) ? new LPU(row) : new Organization(row)); }
public string GetOrgType(TypeOrg typeOrg, bool haveParent) { Organization organization = GetOrganization(typeOrg, haveParent); return _exportOrganization.GetRecordType(organization); }
public void SetTypeOrg(TypeOrg typeOrg) { _typeOrg = typeOrg; }
public LPU(TypeOrg typeOrg) : base(typeOrg) { }
public override object[] GetRow() { string typeOrgName = ((TypeOrg == TypeOrg.ЛПУ) && (ParentOrganization != null)) ? "Филиал ЛПУ" : TypeOrg.ToString(); return(new object[] { ID, CrmID, ShortName, typeOrgName, (ParentOrganization == null) ? INN : (ParentOrganization as LPU).INN, (RealRegion == null) ? string.Empty : RealRegion.Name, City, (LpuRR == null) ? "Прочие ЛПУ" : LpuRR.Name, ((LpuRR2 == null) || (LpuRR2.ID == 0)) ? String.Empty : LpuRR2.Name, (LpuRR == null) ? "Российская федерация" : LpuRR.RegionRR.Name }); }