protected Company(string name, CompanyCodeType codeType, string code, string address)
 {
     Id       = null;
     Name     = name;
     CodeType = codeType;
     Code     = code;
     Address  = address;
 }
 public static Company New(string name, CompanyCodeType codeType, string code, string address)
 {
     return(new Company(name, codeType, code, address));
 }
Exemple #3
0
 public async Task <Company> FindByCode(CompanyCodeType codeType, string code)
 {
     return(await employeeDbContext.Companies.FirstOrDefaultAsync(p => p.CodeType == codeType && p.Code == code));
 }
 public async Task <Company> WithCode(CompanyCodeType codeType, string code)
 {
     return(await session.Query <Company>().FirstOrDefaultAsync(p => p.CodeType == codeType && p.Code == code));
 }
 public static Company ForEmployee(int id, CompanyCodeType codeType, string code)
 {
     return(new Company(id, codeType, code));
 }
 private Company(int id, CompanyCodeType codeType, string code)
 {
     Id       = id;
     CodeType = codeType;
     Code     = code;
 }