Changeset - e7c6055b3fc6
[Not reviewed]
0 2 0
James Tauber - 12 years ago 2012-09-08 23:07:34
jtauber@jtauber.com
added cancel and disable next
2 files changed with 7 insertions and 1 deletions:
0 comments (0 inline, 0 general)
symposion/templates/reviews/result_notification.html
Show inline comments
...
 
@@ -19,25 +19,25 @@
 
        
 
        <p>
 
            Select one or more proposals (<span class="action-counter">0</span> currently selected)
 
            <br/>
 
            then pick an email template
 
            <select name="notification_template">
 
                <option value="">[blank]</option>
 
                {% for template in notification_templates %}
 
                    <option value="{{ template.pk }}">{{ template.label }}</option>
 
                {% endfor %}
 
            </select>
 
            <br/>
 
            <button type="submit" class="btn btn-primary">Next <i class="icon icon-chevron-right"></i></button>
 
            <button id="next-button" type="submit" class="btn btn-primary" disabled>Next <i class="icon icon-chevron-right"></i></button>
 
        </p>
 
        
 
        <table class="table table-striped table-bordered">
 
            <thead>
 
                <th><input type="checkbox" id="action-toggle"></th>
 
                <th>#</th>
 
                <th>{% trans "Speaker / Title" %}</th>
 
                <th>{% trans "Category" %}</th>
 
                <th>{% trans "Status" %}</th>
 
                <th>{% trans "Notified?" %}</th>
 
            </thead>
 
            
...
 
@@ -84,24 +84,29 @@
 
                }
 
                updateCounter = function() {
 
                    var sel = $(actionCheckboxes).filter(":checked").length;
 
                    $(options.counterContainer).html(sel);
 
                    $(options.allToggle).prop("checked", function() {
 
                        if (sel == actionCheckboxes.length) {
 
                            value = true;
 
                        } else {
 
                            value = false;
 
                        }
 
                        return value;
 
                    });
 
                    if (sel == 0) {
 
                        $("#next-button").prop("disabled", true);
 
                    } else {
 
                        $("#next-button").prop("disabled", false);
 
                    }
 
                }
 
                // Check state of checkboxes and reinit state if needed
 
                $(this).filter(":checked").each(function(i) {
 
                    $(this).parent().parent().toggleClass(options.selectedClass);
 
                    updateCounter();
 
                });
 
                $(options.allToggle).click(function() {
 
                    checker($(this).prop("checked"));
 
                    updateCounter();
 
                });
 
                lastChecked = null;
 
                $(actionCheckboxes).click(function(event) {
symposion/templates/reviews/result_notification_prepare.html
Show inline comments
...
 
@@ -28,16 +28,17 @@
 
                <input type="text" name="subject" class="span5" value="{{ notification_template.subject }}" />
 
                <br/>
 
                <label>Body</label>
 
                <textarea class="span5" rows="10" name="body">{{ notification_template.body }}</textarea>
 
                <br/>
 
                <input type="hidden" name="notification_template" value="{{ notification_template.pk }}" />
 
                <input type="hidden" name="proposal_pks" value="{{ proposal_pks }}" />
 
                <p>
 
                    If the <b>Body</b> includes the string <code>{% templatetag openvariable %} proposal {% templatetag closevariable %}</code> then it will be
 
                    replaced with the title of the proposal when the email is sent.
 
                </p>
 
                <button type="submit" class="btn btn-primary">Send {{ proposals|length }} Email{{ proposals|length|pluralize }}</button>
 
                <a class="btn" href="{% url result_notification section_slug status %}">Cancel</a>
 
            </form>
 
        </div>
 
    </form>
 
{% endblock %}
0 comments (0 inline, 0 general)