diff options
| author | it-fixcomart <it@fixcomart.co.id> | 2024-08-28 13:14:07 +0700 |
|---|---|---|
| committer | it-fixcomart <it@fixcomart.co.id> | 2024-08-28 13:14:07 +0700 |
| commit | 0633f4fa379370de41195e20058e6e671d27b4a9 (patch) | |
| tree | 728e005776e95ad5a20f2943f17876326608b234 /indoteknik_api/controllers/api_v1/user.py | |
| parent | 161d234409fa146f8bab98697f568d7a4c1348e1 (diff) | |
<iman> update make user individu data
Diffstat (limited to 'indoteknik_api/controllers/api_v1/user.py')
| -rw-r--r-- | indoteknik_api/controllers/api_v1/user.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/indoteknik_api/controllers/api_v1/user.py b/indoteknik_api/controllers/api_v1/user.py index 4a61270f..3fb10333 100644 --- a/indoteknik_api/controllers/api_v1/user.py +++ b/indoteknik_api/controllers/api_v1/user.py @@ -109,7 +109,6 @@ class User(controller.Controller): phone = kw.get('phone') # Form Data - # Form Data npwp = kw.get('npwp') npwp_document = kw.get('npwp_document', False) npwp_filename = kw.get('npwp_filename', 'npwp_document') @@ -170,6 +169,11 @@ class User(controller.Controller): if match_ratio > 0.8: # Set the user's partner's parent to the matched company user.partner_id.parent_id = match_company.id + user.partner_id.customer_type = match_company.customer_type + user.partner_id.npwp = match_company.npwp + user.partner_id.sppkp = match_company.sppkp + user.partner_id.nama_wajib_pajak = match_company.nama_wajib_pajak + user.partner_id.alamat_lengkap_text = match_company.alamat_lengkap_text # Create a user company request request.env['user.company.request'].create({ @@ -233,6 +237,11 @@ class User(controller.Controller): }) new_company.message_post(body="SPPKP Uploaded", attachment_ids=[sppkp_attachment.id]) + if type_acc == 'individu': + user.partner_id.customer_type = 'nonpkp' + user.partner_id.npwp = '0.000.000.0-000.000' + user.partner_id.nama_wajib_pajak = name + user.send_activation_mail() response['register'] = True |
