bugfix
This commit is contained in:
parent
8355aacdab
commit
703b1b50bb
@ -22,12 +22,12 @@ async def sor_get_callerid(sor, orgid):
|
|||||||
sql = """select a.ownerid from upappkey a, users b
|
sql = """select a.ownerid from upappkey a, users b
|
||||||
where b.orgid = ${orgid}$
|
where b.orgid = ${orgid}$
|
||||||
and a.ownerid = b.id"""
|
and a.ownerid = b.id"""
|
||||||
recs = await sor.sqlExe(sql, {'orgid': orgid})
|
recs = await sor.sqlExe(sql, {'orgid': orgid})
|
||||||
cnt = len(recs)
|
cnt = len(recs)
|
||||||
if cnt == 0:
|
if cnt == 0:
|
||||||
return None
|
return None
|
||||||
i = randint(0, cnt - 1)
|
i = randint(0, cnt - 1)
|
||||||
return recs[i].ownerid
|
return recs[i].ownerid
|
||||||
|
|
||||||
async def get_uapi(upappid, apiname):
|
async def get_uapi(upappid, apiname):
|
||||||
dbname = get_dbname()
|
dbname = get_dbname()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user