Please enable JavaScript.
Coggle requires JavaScript to display documents.
Upsert Supplier (email not exists in cm_business_partners (same tenant)…
Upsert Supplier
email
not exists in cm_business_partners
(same tenant)
email
exists in cm_invited_business_partner
with Status
= "CONNECTING" or "RE-CONNECTING"
in same tenant
means Invitation has been sent before
but has not been accepted
disconnect the current connection id
(delete connection request by Babelway)
generate new connection uuid
if input param is email or accounting_system_id
Call TS API through Babelway
Invite new
if companyAccountId does not exist
Send connection request
if companyAccountId exists
invite supplier with new connection id
send Sendgrid email
email
exists in cm_invited_business_partner
with Status
!= "CONNECTING" or "RE-CONNECTING"
in all tenants
means Invitation has been sent
to this Supplier by other tenant(s)
(Supplier account is already existed)
invite supplier with new connection id
Find the current company account id
Send Sendgrid email
Call TS API through Babelway (
Send connection request
)
email
not exists in cm_invited_business_partners
means new Invitation
generate new connection uuid
if input param is email or accounting_system_id
invite supplier with new connection id
Call TS API through Babelway
Invite new
if companyAccountId is not inputted
Send connection request
if companyAccountId is inputted
Send Sendgrid email
email
exist in cm_business_partners
del_flag = 1
(same tenant)
means Supplier account exists on TS
but connection has been disconnected
generate new connection uuid
if input param is email or accounting_system_id
RECONNECT Supplier
New connection id
Use
the old company account id
Insert new invitation
cm_invited_business_partners
send Sendgrid email
Call TS API through Babelway (
Send connection request
)
email
exists in cm_business_partners
del_flag = 0
(same tenant)
means Supplier is already existed on TS
update TSJ Database
Call TS API through Babelway (
Update existing connection
)