public async Task DeleteCreditCardCompanyUnit(IdInput<long> input) { DeleteAddressUnitInput dto = new DeleteAddressUnitInput { TypeofObjectId = TypeofObject.BankAccountUnit, ObjectId = input.Id }; // await _addressAppService.DeleteAddressUnit(dto); await _bankAccountUnitManager.DeleteAsync(input); }
public async Task DeleteCustomerUnit(IdInput input) { DeleteAddressUnitInput dto = new DeleteAddressUnitInput { TypeofObjectId = TypeofObject.CustomerUnit, ObjectId = input.Id }; await _addressUnitAppService.DeleteAddressUnitByEntity(dto); await _customerUnitManager.DeleteAsync(input.Id); }
public async Task DeleteEmployeeUnit(IdInput input) { await _employeeUnitManager.DeleteAsync(input.Id); DeleteAddressUnitInput dto = new DeleteAddressUnitInput { TypeofObjectId = TypeofObject.EmployeeUnit, ObjectId = input.Id }; await _addressAppService.DeleteAddressUnitByEntity(dto); }
public async Task DeleteVendorUnit(IdInput input) { DeleteAddressUnitInput dto = new DeleteAddressUnitInput { TypeofObjectId = TypeofObject.VendorUnit, ObjectId = input.Id }; await _addressAppService.DeleteAddressUnitByEntity(dto); await _vendorAliasUnitManager.DeleteAsync(Convert.ToInt32(dto.ObjectId)); await _vendorUnitManager.DeleteAsync(input.Id); }
public async Task DeleteBankAccountUnit(IdInput <long> input) { await _bankAccountPaymentRangeRepository.DeleteAsync(p => p.BankAccountId == input.Id); DeleteAddressUnitInput dto = new DeleteAddressUnitInput { TypeofObjectId = TypeofObject.BankAccountUnit, ObjectId = input.Id }; await _addressAppService.DeleteAddressUnitByEntity(dto); await _bankAccountUnitManager.DeleteAsync(input); }
/// <summary> /// Deleting the addresses by ObjectId and TypeofObject /// </summary> /// <param name="input"></param> /// <returns></returns> public async Task DeleteAddressUnitByEntity(DeleteAddressUnitInput input) { await _addressUnitRepository.DeleteAsync(p => p.TypeofObjectId == input.TypeofObjectId && p.ObjectId == input.ObjectId); }