{% compress js %}
  <script type="text/javascript" src="{{ '/js/moderation_queue/errors_alert.js'|media }}"></script>
  <script type="text/javascript" src="{{ '/js/moderation_queue/decline_and_explain_menu.js'|media }}"></script>
  <script type="text/javascript" src="{{ '/js/moderation_queue/post_moderation_controls.js'|media }}"></script>
  <script type="text/javascript" src="{{ '/js/moderation_queue/errors_alert.js'|media }}"></script>
  <script type="text/javascript" src="{{ '/js/moderation_queue/reject_reason_selector.js'|media }}"></script>
  <script type="text/javascript" src="{{ '/js/moderation_queue/reject_reason_editor.js'|media }}"></script>
  <script type="text/javascript" src="{{ '/js/moderation_queue/manage_reject_reasons_dialog.js'|media }}"></script>
{% endcompress %}
<script type="text/javascript">
  (function() {
    askbot['urls']['save_post_reject_reason'] = '{{ url('save_post_reject_reason') }}';
    askbot['urls']['delete_post_reject_reason'] = '{{ url('delete_post_reject_reason') }}';
    {% if request.user.is_administrator_or_moderator() %}
      askbot['data']['postRejectReasons'] = [
        {% for reason in post_reject_reasons %}
          {
            'id': {{reason.id}},
            'title': '{{reason.title|escapejs}}',
            'description': '{{reason.details.text|escapejs}}'
          },
        {% endfor %}
      ];
    {% endif %}
    askbot['urls']['moderatePostEdits'] = '{{ url('moderate_post_edits') }}';
    var modControls = new PostModerationControls();
    modControls.decorate($('body'));
  })();
</script>
