- 新增 credit_limit 表定义和DDL - 修改 accounting_config.py 支持信用额度透支检查 - 新增 creditlimit.py 信用额度管理模块 - 新增信用额度管理界面和CRUD API - 支持设置/查询/更新客户信用额度
34 lines
538 B
Plaintext
34 lines
538 B
Plaintext
|
|
ns = {
|
|
'id':params_kw['id'],
|
|
}
|
|
|
|
|
|
db = DBPools()
|
|
dbname = get_module_dbname('accounting')
|
|
async with db.sqlorContext(dbname) as sor:
|
|
r = await sor.D('credit_limit', ns)
|
|
debug('delete credit_limit success')
|
|
return {
|
|
"widgettype":"Message",
|
|
"options":{
|
|
"title":"删除成功",
|
|
"timeout":3,
|
|
"cwidth":16,
|
|
"cheight":9,
|
|
"message":"ok"
|
|
}
|
|
}
|
|
|
|
debug('Delete credit_limit failed')
|
|
return {
|
|
"widgettype":"Error",
|
|
"options":{
|
|
"title":"删除失败",
|
|
"timeout":3,
|
|
"cwidth":16,
|
|
"cheight":9,
|
|
"message":"failed"
|
|
}
|
|
}
|