diff --git a/admin/dashboard.py b/admin/dashboard.py index 30e55d1..321655a 100644 --- a/admin/dashboard.py +++ b/admin/dashboard.py @@ -519,6 +519,10 @@ def pastafari2_get_multiprogress(): ids=request.args.get('ids', '[]') + position=0 + + #position=int(request.args.get('position', '0')) + final_ids=[str(i) for i in json.loads(ids)] final_str=",".join(['%s']*len(final_ids)) @@ -531,7 +535,7 @@ def pastafari2_get_multiprogress(): logtask=LogTask(db) - arr_log=logtask.set_limit([20]).set_conditions('WHERE task_id IN ({})'.format(final_str), final_ids).select_to_array([], True) + arr_log=logtask.set_limit([position, 20]).set_conditions('WHERE task_id IN ({})'.format(final_str), final_ids).select_to_array([], True) resp=make_response(json.dumps(arr_log)) diff --git a/scripts/system/install_python.sh b/scripts/system/install_python.sh index 07746ad..005f24a 100644 --- a/scripts/system/install_python.sh +++ b/scripts/system/install_python.sh @@ -6,7 +6,24 @@ echo '{"error": 0, "status": 0, "progress": 0, "no_progress":0, "message": "Inst sleep 1 -sudo apt-get -y install python3 python3-pip +# Get distro version using lsb_release + +DISTRO=`( lsb_release -ds || cat /etc/*release || uname -om ) 2>/dev/null | head -n1` + +if [[ $DISTRO =~ ^Debian ]]; then + + sudo apt-get -y install python3 python3-pip + +elif [[ $DISTRO =~ ^NAME=\"Arch ]]; then + + sudo pacman -S python python-pip + +else + + echo "Sorry, Linux distro not supported" + exit 1; + +fi if [ $? -eq 0 ]; then diff --git a/templates/admin/multiprogress.phtml b/templates/admin/multiprogress.phtml index 3b7eac7..95b82f6 100644 --- a/templates/admin/multiprogress.phtml +++ b/templates/admin/multiprogress.phtml @@ -1,5 +1,6 @@ <%inherit file="dashboard.phtml"/> <%block name="content"> +
${lang('pastafari2', 'servers', 'Servers')} >> ${lang('pastafari2', 'task_progress', 'Task progress')}
${description_task}
${lang('pastafari2', 'servers', 'Servers')} >> ${lang('pastafari2', 'task_progress', 'Task progress')}
%block> <%block name="jscript_block">