This commit is contained in:
yumoqing 2025-01-21 19:39:05 +08:00
parent 44b3c24e0c
commit 9c370c5ddb
6 changed files with 87 additions and 0 deletions

View File

@ -0,0 +1,18 @@
username = params_kw.username
db = DBPools()
dbname = await rfexe('get_module_dbname', 'platformbiz')
async with db.sqlorContext(dbname) as sor:
if username:
sql = "select * from users where username = ${username}$"
recs = await sor.sqlExe(sql, {'username':username})
if len(recs) > 0:
userorgid = recs[0].orgid
else:
e = Exception(f'{user}:user not found')
exception(f'Eeception:{e}')
raise e
else:
userorgid = await get_userorgid()
await openCustomerAccounts(sor, '0', userorgid)
return "开帐成功"
return "开帐失败"

View File

@ -0,0 +1,6 @@
db = DBPools()
dbname = await rfexe('get_module_dbname', 'accounting')
async with db.sqlorContext(dbname) as sor:
await openOwnerAccounts(sor, '0')
return 'OK'
return 'error'

View File

@ -0,0 +1,33 @@
[
{
"name":"agree",
"label":"供应商管理",
"url":"{{entire_url('/platformbiz/provider')}}"
},
{
"name":"paychannel",
"label":"支付渠道",
"url":"{{entire_url('paychannel')}}"
},
{
"name":"prodtype",
"label":"产品类型",
"url":"{{entire_url('/platformbiz/prodtype')}}"
},
{
"name":"recharge",
"label":"充值",
"items":[
{
"name":"recharge_log",
"label":"充值日志"
"url":"{{entire_url('/platformbiz/recharge_log')}}"
},
{
"name":"recharge_4u",
"label":"充值错账处理",
"url":"{{entire_url('/platformbiz/rechange_accounting.ui')}}"
}
]
}
]

View File

@ -0,0 +1,30 @@
[
{
"name":"product",
"label":"产品管理",
"url":"{{entire_url('/platformbiz/product')}}"
},
{
"name":"coupon",
"label":"代金券",
"items":[
{
"name":"coupontype",
"label":"代金券设置"
"url":"{{entire_url('/platformbiz/coupontype')}}"
},
{
"name":"coupon_issue",
"label":"代金券发放",
"url":"{{entire_url('/platformbiz/coupon_issue.ui')}}"
},
{
"name":"coupon",
"label":"代金券管理",
"url":"{{entire_url('/platformbiz/coupon')}}"
}
]
}
]