28 lines
463 B
Plaintext
28 lines
463 B
Plaintext
|
print(params_kw, 'delete_code.dspy')
|
||
|
ns = {
|
||
|
'id':params_kw['id'],
|
||
|
'del_flg':'1'
|
||
|
}
|
||
|
dbname = get_definition('codesdb')
|
||
|
db = DBPools()
|
||
|
async with db.sqlorContext(dbname) as sor:
|
||
|
r = await sor.U('appcodes', ns)
|
||
|
print('delete success');
|
||
|
return {
|
||
|
"widgettype":"Message",
|
||
|
"options":{
|
||
|
"title":"Delete Success",
|
||
|
"message":"ok"
|
||
|
}
|
||
|
}
|
||
|
|
||
|
print('Delete failed');
|
||
|
return {
|
||
|
"widgettype":"Error",
|
||
|
"options":{
|
||
|
"title":"Delete Error",
|
||
|
"message":"failed"
|
||
|
}
|
||
|
}
|
||
|
|