Exemple #1
0
 def search_autorunresult_byname(autorunresultname):
     result = None
     try:
         result = DAL_AutoRunResult.get_all().filter(AName__icontains=autorunresultname)
     except Exception as ex:
         print(ex)
     return result
Exemple #2
0
 def search_autorunresult_byid(autorunresultid):
     autorunresult = None
     try:
         autorunresult = DAL_AutoRunResult.get_all().filter(id=autorunresultid)
     except Exception as ex:
         SimpleLogger.error(ex.message)
     return autorunresult
Exemple #3
0
 def search_autorunresult(searchkeyword):
     if searchkeyword == "ALL":
         result = DAL_AutoRunResult.get_all()
     else:
         result = AutoRunResultService.search_autorunresult_byid(searchkeyword)
         if  result ==None or len(result)==0:
             result = AutoRunResultService.search_autorunresult_byname(searchkeyword.strip())
     return result.order_by("-id")
Exemple #4
0
 def get_autorunresult_namelist():
     autorunresultlist = DAL_AutoRunResult.get_all()
     return str([item.TaskName for item in autorunresultlist]).replace("u'","'")