Explorar o código

HUE-7420 [jb] Remove white space from impala title

jdesjean %!s(int64=8) %!d(string=hai) anos
pai
achega
97177b1
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      apps/jobbrowser/src/jobbrowser/apis/query_api.py

+ 1 - 1
apps/jobbrowser/src/jobbrowser/apis/query_api.py

@@ -59,7 +59,7 @@ class QueryApi(Api):
     return {
       'apps': sorted([{
         'id': job['query_id'],
-        'name': job['stmt'][:100] + ('...' if len(job['stmt']) > 100 else ''),
+        'name': job['stmt'].replace('\r\n', ' ')[:60] + ('...' if len(job['stmt']) > 60 else ''),
         'status': job['state'],
         'apiStatus': self._api_status(job['state']),
         'type': job['stmt_type'],