public async Task AfterUnregistered(IEnumerable <Guid> idsToUpdate, Guid identityWorkId, params object[] parameters) { LicenseParams licenseParams = parameters[0] as LicenseParams; var service = new LicensingService(LicensingServiceProviderFactory.GetProvider()); service.AumentEmployeeLicense(licenseParams.LicenseID, licenseParams.LicenseServiceID); //Vacío (corte) }
public async Task AfterDeleteAsync(List <Guid> lstObjectsToValidate, IParams parameters) { LicenseParams licenseParams = parameters as LicenseParams; var service = new LicensingService(LicensingServiceProviderFactory.GetProvider()); service.AumentEmployeeLicense(licenseParams.LicenseID, licenseParams.LicenseServiceID); }
public async Task AfterCreate(List <Employee> lstObjectsToValidate, IParams parameters) { var overdraftManager = new OverdraftManager(); overdraftManager.CreateByEmployeesAsync(lstObjectsToValidate).Wait(); LicenseParams licenseParams = parameters as LicenseParams; //Calculation async fire and forget IEnumerable <Guid> employeeIds = lstObjectsToValidate.Select(p => p.ID); var company = lstObjectsToValidate.FirstOrDefault().company; var instanceID = lstObjectsToValidate.FirstOrDefault().InstanceID; var userId = lstObjectsToValidate.FirstOrDefault().IdentityID; new OverdraftCalculationManager().CalculationFireAndForgetByEmployeesAsync(employeeIds, company, instanceID, userId); //Updatefeature var service = new LicensingService(LicensingServiceProviderFactory.GetProvider()); await service.ConsumeEmployeeLicense(licenseParams.LicenseID, licenseParams.LicenseServiceID); }
public async Task DeleteAsync(List <Guid> lstGuids, LicenseParams licenseParams) { var middlewareManager = new MiddlewareManager <T>(new BaseRecordManager <T>(), Validator); await middlewareManager.DeleteAsync(lstGuids, licenseParams); }
public async Task CreateAsync(List <T> lstObjects, LicenseParams licenseParams) { var middlewareManager = new MiddlewareManager <T>(new BaseRecordManager <T>(), Validator); await middlewareManager.CreateAsync(lstObjects, licenseParams); }
public Task CreateAsync(List <T> lstObjects, LicenseParams licenseParams) { return(_client.CreateAsync(lstObjects, licenseParams)); }
public Task DeleteAsync(List <Guid> lstGuids, LicenseParams licenseParams) { return(_client.DeleteAsync(lstGuids, licenseParams)); }