Index: trunk/extensions/EducationProgram/EducationProgram.i18n.php |
— | — | @@ -399,7 +399,8 @@ |
400 | 400 | 'ep-instructor-add-text' => 'You are adding an instructor for course $1. Enter the username of the instructor and a brief description why this person is being added.', |
401 | 401 | 'ep-instructor-add-self-text' => 'You are adding yourself as {{GENDER:$1|instructor}} for course $1. Please add a brief description why you are doing so.', |
402 | 402 | 'ep-instructor-add-cancel-button' => 'Cancel', |
403 | | - |
| 403 | + 'ep-instructor-summary-input' => 'Summary', |
| 404 | + 'ep-instructor-name-input' => 'User name', |
404 | 405 | |
405 | 406 | // EPInstrucor |
406 | 407 | 'ep-instructor-remove' => 'remove from course', |
Index: trunk/extensions/EducationProgram/EducationProgram.php |
— | — | @@ -375,6 +375,8 @@ |
376 | 376 | 'ep-instructor-add-self-text', |
377 | 377 | 'ep-instructor-add-self-title', |
378 | 378 | 'ep-instructor-add-cancel-button', |
| 379 | + 'ep-instructor-summary-input', |
| 380 | + 'ep-instructor-name-input', |
379 | 381 | ), |
380 | 382 | ); |
381 | 383 | |
Index: trunk/extensions/EducationProgram/resources/ep.instructor.js |
— | — | @@ -96,14 +96,16 @@ |
97 | 97 | |
98 | 98 | this.nameInput = $( '<input>' ).attr( { |
99 | 99 | 'type': 'text', |
100 | | - 'size': 60, |
101 | | - 'maxlength': 250 |
| 100 | + 'size': 30, |
| 101 | + 'maxlength': 250, |
| 102 | + 'id': 'ep-instructor-nameinput' |
102 | 103 | } ); |
103 | 104 | |
104 | 105 | this.summaryInput = $( '<input>' ).attr( { |
105 | 106 | 'type': 'text', |
106 | 107 | 'size': 60, |
107 | | - 'maxlength': 250 |
| 108 | + 'maxlength': 250, |
| 109 | + 'id': 'ep-instructor-summaryinput' |
108 | 110 | } ); |
109 | 111 | |
110 | 112 | this.doAdd = function() { |
— | — | @@ -159,12 +161,26 @@ |
160 | 162 | ) ) ); |
161 | 163 | |
162 | 164 | if ( !this.selfMode ) { |
163 | | - this.$dialog.append( this.nameInput ); |
| 165 | + this.$dialog.append( |
| 166 | + $( '<label>' ).attr( { |
| 167 | + 'for': 'ep-instructor-nameinput' |
| 168 | + } ).text( ep.msg( 'ep-instructor-name-input' ) + ' ' ), |
| 169 | + this.nameInput, |
| 170 | + '<br />', |
| 171 | + $( '<label>' ).attr( { |
| 172 | + 'for': 'ep-instructor-summaryinput' |
| 173 | + } ).text( ep.msg( 'ep-instructor-summary-input' ) ) |
| 174 | + ); |
164 | 175 | } |
165 | 176 | |
166 | 177 | this.$dialog.append( this.summaryInput ); |
167 | 178 | |
168 | | - this.nameInput.focus(); |
| 179 | + if ( this.selfMode ) { |
| 180 | + this.summaryInput.focus(); |
| 181 | + } |
| 182 | + else { |
| 183 | + this.nameInput.focus(); |
| 184 | + } |
169 | 185 | |
170 | 186 | var enterHandler = function( event ) { |
171 | 187 | if ( event.which == '13' ) { |