<commit_before>/**
 * Period overview (overview of an period).
 */
Ext.define('devilry_subjectadmin.view.period.Overview' ,{
    extend: 'Ext.panel.Panel',
    alias: 'widget.periodoverview',
    cls: 'devilry_subjectadmin_periodoverview',
    requires: [
        'Ext.layout.container.Column',
        'devilry_extjsextras.AlertMessage',
        'devilry_extjsextras.AlertMessageList',
        'devilry_subjectadmin.view.AdminsBox',
        'devilry_subjectadmin.utils.UrlLookup',
        'devilry_subjectadmin.view.DangerousActions',
        'devilry_subjectadmin.view.period.EditDurationWidget',
        'devilry_extjsextras.SingleActionBox'
    ],

    /**
     * @cfg {String} period_id (required)
     */


    initComponent: function() {
        Ext.apply(this, {
            frame: false,
            border: 0,
            bodyPadding: 40,
            autoScroll: true,

            items: [{
                xtype: 'alertmessagelist'
            }, {
                xtype: 'panel',
                frame: false,
                border: false,
                layout: 'column',
                items: [{
                    xtype: 'container',
                    columnWidth: 1.0,
                    items: [{
                        xtype: 'box',
                        cls: 'bootstrap',
                        margin: '0 0 20 0',
                        itemId: 'header',
                        tpl: '<h1>{heading}</h1>',
                        data: {
                            heading: gettext('Loading') + ' ...'
                        }
                    }, {
                        xtype: 'box',
                        cls: 'bootstrap devilry_subjectadmin_navigation',
                        itemId: 'createNewAssignmentBox',
                        tpl: [
                            '<p><strong><a href="{url}">{text}</a></strong></p>'
                        ],
                        data: {
                            url: devilry_subjectadmin.utils.UrlLookup.createNewAssignment(this.period_id),
                            text: gettext('Create new assignment')
                        }
                    }, {
                        xtype: 'alertmessage',
                        itemId: 'noRelatedStudentsMessage',
                        hidden: true,
                        type: 'error',
                        title: gettext('No students'),
                        message: interpolate(gettext('This %(period_term)s has no students. Go to the <a href="%(relatedstudents_url)s">manage related students</a> page and add some students. You will not be able to add any assignments until you have at least one student.'), {
                            period_term: gettext('period'),
                            relatedstudents_url: devilry_subjectadmin.utils.UrlLookup.manageRelatedStudents(this.period_id)
                        }, true)
                    }, {
                        xtype: 'alertmessage',
                        itemId: 'noRelatedExaminersMessage',
                        hidden: true,
                        type: 'warning',
                        title: gettext('No examiners'),
                        message: interpolate(gettext('This %(period_term)s has no examiners. Go to the <a href="%(relatedexaminers_url)s">manage related examiners</a> page and add some examiners.'), {
                            period_term: gettext('period'),
                            relatedexaminers_url: devilry_subjectadmin.utils.UrlLookup.manageRelatedExaminers(this.period_id)
                        }, true)
                    }, {
                        xtype: 'listofassignments'
                    }, {
                        xtype: 'box',
                        cls: 'bootstrap',
                        margin: '30 0 0 0',
                        tpl: [
                            '<h2>', gettext('Related {students_term} and examiners'), '</h2>',
                            '<p class="muted">',
                                gettext('Related {students_term} and examiners on a {period_term} are the only users available when you add {students_term} and examiners to assignments.'),
                            '</p>',
                            '<ul class="unstyled">',
                                '<li><p>',
                                    '<a href="', devilry_subjectadmin.utils.UrlLookup.manageRelatedStudents(this.period_id), '">',
                                        gettext('Manage related students'),
                                    '</a>',
                                '</p></li>',
                                '<li><p>',
                                    '<a href="', devilry_subjectadmin.utils.UrlLookup.manageRelatedExaminers(this.period_id), '">',
                                        gettext('Manage related examiners'),
                                    '</a>',
                                '</p></li>',
                            '</ul>'
                        ],
                        data: {
                            period_term: gettext('period'),
                            students_term: gettext('students')
                        }
                    }, {
                        xtype: 'dangerousactions',
                        margin: '20 0 0 0',
                        items: [{
                            xtype: 'singleactionbox',
                            margin: '0 0 0 0',
                            itemId: 'renameButton',
                            id: 'periodRenameButton',
                            titleText: gettext('Loading ...'),
                            bodyTpl: [<commit_msg>devilry_subjectadmin...period: Removed ekstra helptext for students and examiners.<commit_after>/**
 * Period overview (overview of an period).
 */
Ext.define('devilry_subjectadmin.view.period.Overview' ,{
    extend: 'Ext.panel.Panel',
    alias: 'widget.periodoverview',
    cls: 'devilry_subjectadmin_periodoverview',
    requires: [
        'Ext.layout.container.Column',
        'devilry_extjsextras.AlertMessage',
        'devilry_extjsextras.AlertMessageList',
        'devilry_subjectadmin.view.AdminsBox',
        'devilry_subjectadmin.utils.UrlLookup',
        'devilry_subjectadmin.view.DangerousActions',
        'devilry_subjectadmin.view.period.EditDurationWidget',
        'devilry_extjsextras.SingleActionBox'
    ],

    /**
     * @cfg {String} period_id (required)
     */


    initComponent: function() {
        Ext.apply(this, {
            frame: false,
            border: 0,
            bodyPadding: 40,
            autoScroll: true,

            items: [{
                xtype: 'alertmessagelist'
            }, {
                xtype: 'panel',
                frame: false,
                border: false,
                layout: 'column',
                items: [{
                    xtype: 'container',
                    columnWidth: 1.0,
                    items: [{
                        xtype: 'box',
                        cls: 'bootstrap',
                        margin: '0 0 20 0',
                        itemId: 'header',
                        tpl: '<h1>{heading}</h1>',
                        data: {
                            heading: gettext('Loading') + ' ...'
                        }
                    }, {
                        xtype: 'box',
                        cls: 'bootstrap devilry_subjectadmin_navigation',
                        itemId: 'createNewAssignmentBox',
                        tpl: [
                            '<p><strong><a href="{url}">{text}</a></strong></p>'
                        ],
                        data: {
                            url: devilry_subjectadmin.utils.UrlLookup.createNewAssignment(this.period_id),
                            text: gettext('Create new assignment')
                        }
                    }, {
                        xtype: 'alertmessage',
                        itemId: 'noRelatedStudentsMessage',
                        hidden: true,
                        type: 'error',
                        title: gettext('No students'),
                        message: interpolate(gettext('This %(period_term)s has no students. Go to the <a href="%(relatedstudents_url)s">manage related students</a> page and add some students. You will not be able to add any assignments until you have at least one student.'), {
                            period_term: gettext('period'),
                            relatedstudents_url: devilry_subjectadmin.utils.UrlLookup.manageRelatedStudents(this.period_id)
                        }, true)
                    }, {
                        xtype: 'alertmessage',
                        itemId: 'noRelatedExaminersMessage',
                        hidden: true,
                        type: 'warning',
                        title: gettext('No examiners'),
                        message: interpolate(gettext('This %(period_term)s has no examiners. Go to the <a href="%(relatedexaminers_url)s">manage related examiners</a> page and add some examiners.'), {
                            period_term: gettext('period'),
                            relatedexaminers_url: devilry_subjectadmin.utils.UrlLookup.manageRelatedExaminers(this.period_id)
                        }, true)
                    }, {
                        xtype: 'listofassignments'
                    }, {
                        xtype: 'box',
                        cls: 'bootstrap',
                        margin: '30 0 0 0',
                        tpl: [
                            '<h2>', gettext('Related {students_term} and examiners'), '</h2>',
                            '<ul class="unstyled">',
                                '<li><p>',
                                    '<a href="', devilry_subjectadmin.utils.UrlLookup.manageRelatedStudents(this.period_id), '">',
                                        gettext('Manage related students'),
                                    '</a>',
                                '</p></li>',
                                '<li><p>',
                                    '<a href="', devilry_subjectadmin.utils.UrlLookup.manageRelatedExaminers(this.period_id), '">',
                                        gettext('Manage related examiners'),
                                    '</a>',
                                '</p></li>',
                            '</ul>'
                        ],
                        data: {
                            period_term: gettext('period'),
                            students_term: gettext('students')
                        }
                    }, {
                        xtype: 'dangerousactions',
                        margin: '20 0 0 0',
                        items: [{
                            xtype: 'singleactionbox',
                            margin: '0 0 0 0',
                            itemId: 'renameButton',
                            id: 'periodRenameButton',
                            titleText: gettext('Loading ...'),
                            bodyTpl: [
{'fraction_non_alphanumeric': 0.10498332882761106, 'fraction_numerical': 0.005046408939352979, 'mean_word_length': 1.050249399593571, 'pattern_counts': {'":': 0, '<': 61, '<?xml version=': 0, '>': 61, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 12, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4560903', 'n_tokens_mistral': 2720, 'n_tokens_neox': 2525, 'n_words': 506}