bugfix
This commit is contained in:
parent
bfa388b95e
commit
85d09720f1
@ -12,18 +12,18 @@ if params_kw.customerid == userorgid:
|
|||||||
db = DBPools()
|
db = DBPools()
|
||||||
dbname = get_module_dbname('unipay')
|
dbname = get_module_dbname('unipay')
|
||||||
async with db.sqlorContext(dbname) as sor:
|
async with db.sqlorContext(dbname) as sor:
|
||||||
|
pl = PaymentLog(request._run_ns)
|
||||||
|
biz_date = await get_business_date(sor)
|
||||||
recs = await sor.R('organization', {'id': params_kw.customerid})
|
recs = await sor.R('organization', {'id': params_kw.customerid})
|
||||||
if len(recs) < 0:
|
if len(recs) < 0:
|
||||||
return UiError(title="手工充值",
|
return UiError(title="手工充值",
|
||||||
message=f"客户机构不存在{params_kw.customerid}")
|
message=f"客户机构不存在{params_kw.customerid}")
|
||||||
|
|
||||||
pl = PaymentLog(request._run_ns)
|
plog = await pl.sor_new_log(sor, userid, params_kw.customerid, 'agent',
|
||||||
plog = await pl.new_log(userid, params_kw.customerid, 'agent',
|
|
||||||
'手工充值', params_kw.amount, 0.0,
|
'手工充值', params_kw.amount, 0.0,
|
||||||
request['client_ip'], currency='CNY')
|
request['client_ip'], currency='CNY')
|
||||||
|
|
||||||
async with db.sqlorContext(dbname) as sor:
|
|
||||||
biz_date = await get_business_date(sor)
|
|
||||||
await recharge_accounting(sor, params_kw.customerid, 'RECHARGE',
|
await recharge_accounting(sor, params_kw.customerid, 'RECHARGE',
|
||||||
plog['id'],
|
plog['id'],
|
||||||
biz_date,
|
biz_date,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user