From 8e788ac9ca0ebb6ff38d13bb6fd4bea8348c097f Mon Sep 17 00:00:00 2001 From: Maciej Tronowski Date: Fri, 24 Apr 2015 11:04:32 +0200 Subject: [PATCH] rename job new to submit --- qcg/static/qcg/main.css | 2 +- qcg/templates/qcg/base.html | 4 +- qcg/templates/qcg/job_new.html | 351 ------------------------------------- qcg/templates/qcg/job_submit.html | 351 +++++++++++++++++++++++++++++++++++++ qcg/urls.py | 2 +- qcg/views.py | 4 +- 6 files changed, 357 insertions(+), 357 deletions(-) delete mode 100644 qcg/templates/qcg/job_new.html create mode 100644 qcg/templates/qcg/job_submit.html diff --git a/qcg/static/qcg/main.css b/qcg/static/qcg/main.css index 3a47bf9..a27898f 100644 --- a/qcg/static/qcg/main.css +++ b/qcg/static/qcg/main.css @@ -29,7 +29,7 @@ footer.navbar-fixed-bottom { } -/* new job view */ +/* submit job view */ textarea { resize: vertical; diff --git a/qcg/templates/qcg/base.html b/qcg/templates/qcg/base.html index 8318ed3..eeb792c 100644 --- a/qcg/templates/qcg/base.html +++ b/qcg/templates/qcg/base.html @@ -32,8 +32,8 @@ Zadania - - Zleć zadanie + + Zleć zadanie GridFTP diff --git a/qcg/templates/qcg/job_new.html b/qcg/templates/qcg/job_new.html deleted file mode 100644 index 77f6fc7..0000000 --- a/qcg/templates/qcg/job_new.html +++ /dev/null @@ -1,351 +0,0 @@ -{% extends 'qcg/base.html' %} -{% load staticfiles bootstrap3 qcg_utils %} - -{% block extra_css %} - -{% endblock %} - -{% block extra_js %} - - - - {% include 'filex/source.js.html' %} - - -{% endblock %} - -{% block container %} -

{% block title %}Zleć zadanie{% endblock %}

- - {% if errors %} -
- Uwaga! Formularz zawiera błędy. - {{ form.non_field_errors }} - {{ env_formset.non_field_errors }} -
- {% endif %} - -
- {% csrf_token %} - - - - -
-
- {% bootstrap_field form.application layout="horizontal" %} - {% bootstrap_field form.master_file layout="horizontal" %} - {% bootstrap_field form.executable layout="horizontal" form_group_class="form-group collapse" %} - {% bootstrap_field form.script layout="horizontal" form_group_class="form-group collapse" %} - {% bootstrap_field form.arguments layout="horizontal" %} - {% bootstrap_field form.note layout="horizontal" %} - {% bootstrap_field form.grant layout="horizontal" form_group_class="form-group collapse" %} -
- -
- {% bootstrap_field form.hosts layout="horizontal" %} - {% bootstrap_field form.queue layout="horizontal" %} - {% bootstrap_field form.properties layout="horizontal" form_group_class="form-group collapse" %} - {% bootstrap_field form.modules layout="horizontal" form_group_class="form-group collapse" %} - {% bootstrap_field form.procs layout="horizontal" %} - {% bootstrap_field form.nodes layout="horizontal" form_group_class="form-group collapse" %} - {% bootstrap_field form.wall_time layout="horizontal" form_group_class="form-group timerange" %} - {% bootstrap_field form.memory layout="horizontal" form_group_class="form-group collapse" %} - {% bootstrap_field form.memory_per_slot layout="horizontal" form_group_class="form-group collapse" %} - {% bootstrap_field form.reservation layout="horizontal" form_group_class="form-group collapse" %} -
- -
- {% bootstrap_field form.input layout="horizontal" %} - {% bootstrap_field form.stage_in layout="horizontal" %} -{# {% bootstrap_field form.stage_out layout="horizontal" form_group_class="form-group collapse" %}#} -
- -
- {{ env_formset.management_form }} - -
- -
-
- {% for env_form in env_formset %} -
{% bootstrap_form env_form layout='inline' %}
- {% endfor %} -
-
- -
-
-
- -
- {% bootstrap_checkbox form.monitoring %} - -
- -
-
- {% for option in form.notify_type %} - - {% endfor %} -
-
-
- -
-
- -
- {% bootstrap_field form.notify_address layout="horizontal" %} -
-
- -
-
- -
-
- {% for option in form.watch_output_type %} - - {% endfor %} -
-
-
- -
-
- -
- {% bootstrap_field form.watch_output_address layout="horizontal" %} - {% bootstrap_field form.watch_output_pattern layout="horizontal" %} -
-
-
-
- -
-
- -
-
- {% for option in form.preprocess_type %} - - {% endfor %} -
-
-
- -
-
- -
- {% bootstrap_field form.preprocess_cmd layout="horizontal" %} -
- -
- {% bootstrap_field form.preprocess_script layout="horizontal" %} -
-
- -
- -
-
- {% for option in form.postprocess_type %} - - {% endfor %} -
-
-
- -
-
- -
- {% bootstrap_field form.postprocess_cmd layout="horizontal" %} -
- -
- {% bootstrap_field form.postprocess_script layout="horizontal" %} -
-
- - {% bootstrap_field form.native layout="horizontal" %} - {% bootstrap_checkbox form.persistent %} -
-
- -
- -
-
- - - Pokaż zaawansowane -
-
-
- - - -{% endblock %} diff --git a/qcg/templates/qcg/job_submit.html b/qcg/templates/qcg/job_submit.html new file mode 100644 index 0000000..77f6fc7 --- /dev/null +++ b/qcg/templates/qcg/job_submit.html @@ -0,0 +1,351 @@ +{% extends 'qcg/base.html' %} +{% load staticfiles bootstrap3 qcg_utils %} + +{% block extra_css %} + +{% endblock %} + +{% block extra_js %} + + + + {% include 'filex/source.js.html' %} + + +{% endblock %} + +{% block container %} +

{% block title %}Zleć zadanie{% endblock %}

+ + {% if errors %} +
+ Uwaga! Formularz zawiera błędy. + {{ form.non_field_errors }} + {{ env_formset.non_field_errors }} +
+ {% endif %} + +
+ {% csrf_token %} + + + + +
+
+ {% bootstrap_field form.application layout="horizontal" %} + {% bootstrap_field form.master_file layout="horizontal" %} + {% bootstrap_field form.executable layout="horizontal" form_group_class="form-group collapse" %} + {% bootstrap_field form.script layout="horizontal" form_group_class="form-group collapse" %} + {% bootstrap_field form.arguments layout="horizontal" %} + {% bootstrap_field form.note layout="horizontal" %} + {% bootstrap_field form.grant layout="horizontal" form_group_class="form-group collapse" %} +
+ +
+ {% bootstrap_field form.hosts layout="horizontal" %} + {% bootstrap_field form.queue layout="horizontal" %} + {% bootstrap_field form.properties layout="horizontal" form_group_class="form-group collapse" %} + {% bootstrap_field form.modules layout="horizontal" form_group_class="form-group collapse" %} + {% bootstrap_field form.procs layout="horizontal" %} + {% bootstrap_field form.nodes layout="horizontal" form_group_class="form-group collapse" %} + {% bootstrap_field form.wall_time layout="horizontal" form_group_class="form-group timerange" %} + {% bootstrap_field form.memory layout="horizontal" form_group_class="form-group collapse" %} + {% bootstrap_field form.memory_per_slot layout="horizontal" form_group_class="form-group collapse" %} + {% bootstrap_field form.reservation layout="horizontal" form_group_class="form-group collapse" %} +
+ +
+ {% bootstrap_field form.input layout="horizontal" %} + {% bootstrap_field form.stage_in layout="horizontal" %} +{# {% bootstrap_field form.stage_out layout="horizontal" form_group_class="form-group collapse" %}#} +
+ +
+ {{ env_formset.management_form }} + +
+ +
+
+ {% for env_form in env_formset %} +
{% bootstrap_form env_form layout='inline' %}
+ {% endfor %} +
+
+ +
+
+
+ +
+ {% bootstrap_checkbox form.monitoring %} + +
+ +
+
+ {% for option in form.notify_type %} + + {% endfor %} +
+
+
+ +
+
+ +
+ {% bootstrap_field form.notify_address layout="horizontal" %} +
+
+ +
+
+ +
+
+ {% for option in form.watch_output_type %} + + {% endfor %} +
+
+
+ +
+
+ +
+ {% bootstrap_field form.watch_output_address layout="horizontal" %} + {% bootstrap_field form.watch_output_pattern layout="horizontal" %} +
+
+
+
+ +
+
+ +
+
+ {% for option in form.preprocess_type %} + + {% endfor %} +
+
+
+ +
+
+ +
+ {% bootstrap_field form.preprocess_cmd layout="horizontal" %} +
+ +
+ {% bootstrap_field form.preprocess_script layout="horizontal" %} +
+
+ +
+ +
+
+ {% for option in form.postprocess_type %} + + {% endfor %} +
+
+
+ +
+
+ +
+ {% bootstrap_field form.postprocess_cmd layout="horizontal" %} +
+ +
+ {% bootstrap_field form.postprocess_script layout="horizontal" %} +
+
+ + {% bootstrap_field form.native layout="horizontal" %} + {% bootstrap_checkbox form.persistent %} +
+
+ +
+ +
+
+ + + Pokaż zaawansowane +
+
+
+ + + +{% endblock %} diff --git a/qcg/urls.py b/qcg/urls.py index 3bb2d7d..798950b 100644 --- a/qcg/urls.py +++ b/qcg/urls.py @@ -13,7 +13,7 @@ urlpatterns = patterns('', url(r'^$', views.index, name='index'), url(r'^jobs/$', views.jobs_list, name='jobs'), - url(r'^job/new/$', views.job_new, name='job_new'), + url(r'^job/submit/$', views.job_submit, name='job_submit'), url(r'^job/(?P[\w]+)/?$', views.job_details, name='job'), url(r'^job/(?P[\w]+)/(?P[\w]+)/?$', views.task_details, name='task'), diff --git a/qcg/views.py b/qcg/views.py index a1986ad..09812a4 100644 --- a/qcg/views.py +++ b/qcg/views.py @@ -155,7 +155,7 @@ def task_details(request, job_id, task_id): @login_required -def job_new(request): +def job_submit(request): if request.method == 'POST': form = JobDescriptionForm(request.POST) env_formset = EnvFormSet(request.POST) @@ -181,7 +181,7 @@ def job_new(request): errors = form.errors or (env_formset.is_bound and not env_formset.is_valid) - return render(request, 'qcg/job_new.html', {'form': form, 'env_formset': env_formset, 'errors': errors}) + return render(request, 'qcg/job_submit.html', {'form': form, 'env_formset': env_formset, 'errors': errors}) @login_required -- 1.7.9.5