update revoke

This commit is contained in:
2026-05-05 10:14:48 +03:30
parent 6a48f203a9
commit 4af07fe3e8
10 changed files with 84 additions and 57 deletions
@@ -77,8 +77,8 @@ export class NamaProviderUtils {
inno: payload.invoice_number.toString(),
ins: this.mapTspProviderRequestType(TspProviderRequestType.REVOKE),
irtaxid: payload.last_attempt_tax_id,
indatim: new Date().getTime() + '',
},
body: {},
}
}
@@ -140,17 +140,17 @@ export class NamaProviderUtils {
case CustomerType.LEGAL:
return '2'
default:
return '5'
return ''
}
}
private mapCustomerInfo(customer?: CustomerInfoDto) {
const info = {} as any
info.tob = this.mapCustomerType(customer?.type)
if (customer?.type === CustomerType.LEGAL && customer.legal_info) {
info.name = customer.legal_info.name
info.bid = customer.legal_info.economic_code
info.address = ''
info.tob = '2'
} else if (customer?.type === CustomerType.INDIVIDUAL && customer.individual_info) {
info.name = `${customer.individual_info?.first_name || ''} ${
customer.individual_info?.last_name || ''
@@ -158,6 +158,7 @@ export class NamaProviderUtils {
info.bid = customer.individual_info.national_id
info.mobile = customer.individual_info.mobile_number
info.address = ''
info.tob = '1'
}
return info
}