app/templates/projrev/proposal/submit.html
author Madhusudan.C.S <madhusudancs@gmail.com>
Sun, 09 Aug 2009 23:24:48 +0530
changeset 23 91cf6872d853
parent 22 0321f984fb16
child 24 7257b66a6766
permissions -rw-r--r--
Add jqeury purr plugin for help text.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
     1
{% extends "projrev/base.html" %}
22
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
     2
{% block scripts %}
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
     3
{{ block.super }}
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
     4
<script language="JavaScript" type="text/javascript" src="/site-content/js/jquery.chainedSelects.js"></script>
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
     5
<script language="JavaScript" type="text/javascript">
23
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
     6
  $(function()
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
     7
  {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
     8
    $('#id_state').chainSelect('#id_district','/proposal/submit/get_dfors');
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
     9
  });
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    10
  $(document).ready(function() {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    11
	  $.get('/proposal/submit/get_dfors', function() {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    12
      $('#id_district').html('<option value="">---------</option>');
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    13
	  });
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    14
  });
22
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    15
</script>
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    16
{% endblock scripts %}
0
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    17
{% block content %}
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    18
<div class="post">
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    19
			
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    20
	<a name="TemplateInfo"></a>	
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    21
	<h1>Submit your proposal</h1>
4
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    22
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    23
  {% if created_now %}
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    24
    <p>An MICR Code has been assigned and e-mailed to you. Please remember it for future reference.</p>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    25
  {% else %}{% if micr_code %}
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    26
    <p>Edit your details and upload new version of the proposal in the form below.</p>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    27
  {% else %}
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    28
    <p>Fill up the form below, and upload your proposal file by clicking on Browse.</p>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    29
  {% endif %}{% endif %}
0
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    30
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    31
	<form enctype="multipart/form-data" method="post" action="">			
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
    32
		<p>
22
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    33
    {% for field in form %}
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    34
      <p>
23
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    35
      {% if field.help_text %}
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    36
        <script type="text/javascript">
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    37
          $(document).ready( function() {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    38
            var tooltip = [
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    39
            "<div class='tooltip'>",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    40
            "  <div class='tooltip-body'>",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    41
            "    <img src='/site-content/images/purrInfo.png' alt='' />",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    42
            "    <h3>Info</h3>",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    43
            "    <p>",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    44
            "      {% autoescape off %}",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    45
            "        {{ help_text|linebreaksbr|escapejs }}",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    46
            "      {% endautoescape %}",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    47
            "    </p>",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    48
            "  </div>",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    49
            "  <div class='tooltip-bottom'></div>",
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    50
            "</div>"
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    51
          ].join("");
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    52
          var tooltip_object=null;
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    53
          var documented = $("#{{ field_id }}");
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    54
          var not_fieldset = documented.attr('tagName') !== 'FIELDSET';
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    55
          if (not_fieldset) {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    56
            documented.focus(function() {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    57
              if (tooltip_object==null) {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    58
                tooltip_object = $(tooltip).purr({usingTransparentPNG: true,removeTimer: 10000});
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    59
              }
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    60
            });
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    61
            documented.blur(function() {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    62
              if (tooltip_object!==null) {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    63
                tooltip_object.remove();
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    64
                tooltip_object=null;
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    65
              }
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    66
            });
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    67
          }
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    68
          else {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    69
            documented.find("input").hover(function() {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    70
              if (tooltip_object==null) {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    71
                tooltip_object = $(tooltip).purr({usingTransparentPNG: true,removeTimer: 10000});
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    72
              }
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    73
            },
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    74
            function() {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    75
              if (tooltip_object!==null) {
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    76
                tooltip_object.remove();
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    77
                tooltip_object=null;
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    78
              }
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    79
            });
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    80
          }
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    81
        });
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    82
        </script>
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    83
      {% endif %}
22
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    84
      {{ field.errors }}
23
91cf6872d853 Add jqeury purr plugin for help text.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 22
diff changeset
    85
      {{ field.label_tag }}:{{ field }}{% if field.field.required %}<span class="special_class">&nbsp;&nbsp;(required)</span>{% endif %}
22
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    86
      </p>
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    87
    {% endfor %}
0321f984fb16 Made form changes.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 14
diff changeset
    88
4
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    89
      {% if proposal_path %}
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    90
        <p>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    91
          <label for="id_proposal">Previous Proposal Document:</label>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    92
          <a class="document-right" href="/site-content/{{ proposal_path }}">{{ proposal_name }}</a>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    93
        </p>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    94
      {% endif %}
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    95
      {% if micr_code %}
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    96
        <p>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    97
          <label for="id_micr_code">MICR Code:</label>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    98
          <input id="id_micr_code" type="text" maxlength="15" value="{{ micr_code }}" name="institution" DISABLED />
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
    99
        </p>
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
   100
      {% endif %}
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
   101
		  <br />	
8d9da911ed7d Withdraw of proposals.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 0
diff changeset
   102
		  <input class="button" type="submit" value="Submit Proposal" />		
0
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
   103
		</p>		
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
   104
	</form>
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
   105
				
13
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   106
	<p class="post-footer align-right">
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   107
		<span class="comments">Reviews:
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   108
		{% if nr_reviews %}
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   109
		  {{ nr_reviews }}
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   110
		{% else %}
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   111
		  (<i>None</i>)
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   112
		{% endif %}
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   113
		</span>
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   114
		<span class="date">Last reviewed:
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   115
		{% if last_reviewed %}
14
9d720dfded68 Footer for reviews.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 13
diff changeset
   116
      {{ last_reviewed|date:"jS F Y h:iA" }}
13
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   117
    {% else %}
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   118
      (<i>Not Reviewed</i>)
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   119
    {% endif %}
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   120
		</span>
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   121
		<span class="date">Last submitted:
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   122
		{% if last_submitted %}
14
9d720dfded68 Footer for reviews.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 13
diff changeset
   123
      {{ last_submitted|date:"jS F Y h:iA" }}
13
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   124
    {% else %}
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   125
      (<i>New Submission</i>)
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   126
    {% endif %} 
684540719344 Added footer line.
Madhusudan.C.S <madhusudancs@gmail.com>
parents: 4
diff changeset
   127
		</span>	
0
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
   128
	</p>
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
   129
				
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
   130
</div>
c94bd9ae70d2 First commit.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff changeset
   131
{% endblock content %}