Proyectos de Subversion Moodle

Rev

Ir a la última revisión | | Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
96 efrain 1
<?php
2
 
3
class block_cesa_course_rating_edit_form extends block_edit_form
4
{
5
    protected function specific_definition($mform)
6
    {
7
        global $CFG;
8
 
9
        // Section header title according to language file.
10
        $mform->addElement('header', 'config_header', get_string('blocksettings', 'block'));
11
 
12
        // Title
13
        $mform->addElement('text', 'config_title', get_string('config_title', 'theme_edumy'));
14
        $mform->setDefault('config_title', 'Student feedback');
15
        $mform->setType('config_title', PARAM_RAW);
16
 
17
       // include($CFG->dirroot . '/theme/edumy/ccn/block_handler/edit.php');
18
 
19
        $mform->addElement('header', 'config_cocoon_block_settings', get_string('block_settings', 'block_cesa_course_rating'));
20
        // Margin top
21
        $options = array(
22
            '-200' => '-200',
23
            '-195' => '-195',
24
            '-190' => '-190',
25
            '-185' => '-185',
26
            '-180' => '-180',
27
            '-175' => '-175',
28
            '-170' => '-170',
29
            '-165' => '-165',
30
            '-160' => '-160',
31
            '-155' => '-155',
32
            '-150' => '-150',
33
            '-145' => '-145',
34
            '-140' => '-140',
35
            '-135' => '-135',
36
            '-130' => '-130',
37
            '-125' => '-125',
38
            '-120' => '-120',
39
            '-115' => '-115',
40
            '-110' => '-110',
41
            '-105' => '-105',
42
            '-100' => '-100',
43
            '-95' => '-95',
44
            '-90' => '-90',
45
            '-85' => '-85',
46
            '-80' => '-80',
47
            '-75' => '-75',
48
            '-70' => '-70',
49
            '-65' => '-65',
50
            '-60' => '-60',
51
            '-55' => '-55',
52
            '-50' => '-50',
53
            '-45' => '-45',
54
            '-40' => '-40',
55
            '-35' => '-35',
56
            '-30' => '-30',
57
            '-25' => '-25',
58
            '-20' => '-20',
59
            '-15' => '-15',
60
            '-10' => '-10',
61
            '-5' => '-5',
62
            '0' => 'Default',
63
            'zero' => '0',
64
            '5' => '5',
65
            '10' => '10',
66
            '15' => '15',
67
            '20' => '20',
68
            '25' => '25',
69
            '30' => '30',
70
            '35' => '35',
71
            '40' => '40',
72
            '45' => '45',
73
            '50' => '50',
74
            '55' => '55',
75
            '60' => '60',
76
            '65' => '65',
77
            '70' => '70',
78
            '75' => '75',
79
            '80' => '80',
80
            '85' => '85',
81
            '90' => '90',
82
            '95' => '95',
83
            '100' => '100',
84
            '105' => '105',
85
            '110' => '110',
86
            '115' => '115',
87
            '120' => '120',
88
            '125' => '125',
89
            '130' => '130',
90
            '135' => '135',
91
            '140' => '140',
92
            '145' => '145',
93
            '150' => '150',
94
            '155' => '155',
95
            '160' => '160',
96
            '165' => '165',
97
            '170' => '170',
98
            '175' => '175',
99
            '180' => '180',
100
            '185' => '185',
101
            '190' => '190',
102
            '195' => '195',
103
            '200' => '200'
104
        );
105
        $select = $mform->addElement('select', 'config_ccn_margin_top', get_string('config__margin_top', 'block_cesa_course_rating'), $options);
106
        $select->setSelected('0');
107
 
108
        // Margin bottom
109
        $options = array(
110
            '-200' => '-200',
111
            '-195' => '-195',
112
            '-190' => '-190',
113
            '-185' => '-185',
114
            '-180' => '-180',
115
            '-175' => '-175',
116
            '-170' => '-170',
117
            '-165' => '-165',
118
            '-160' => '-160',
119
            '-155' => '-155',
120
            '-150' => '-150',
121
            '-145' => '-145',
122
            '-140' => '-140',
123
            '-135' => '-135',
124
            '-130' => '-130',
125
            '-125' => '-125',
126
            '-120' => '-120',
127
            '-115' => '-115',
128
            '-110' => '-110',
129
            '-105' => '-105',
130
            '-100' => '-100',
131
            '-95' => '-95',
132
            '-90' => '-90',
133
            '-85' => '-85',
134
            '-80' => '-80',
135
            '-75' => '-75',
136
            '-70' => '-70',
137
            '-65' => '-65',
138
            '-60' => '-60',
139
            '-55' => '-55',
140
            '-50' => '-50',
141
            '-45' => '-45',
142
            '-40' => '-40',
143
            '-35' => '-35',
144
            '-30' => '-30',
145
            '-25' => '-25',
146
            '-20' => '-20',
147
            '-15' => '-15',
148
            '-10' => '-10',
149
            '-5' => '-5',
150
            '0' => 'Default',
151
            'zero' => '0',
152
            '5' => '5',
153
            '10' => '10',
154
            '15' => '15',
155
            '20' => '20',
156
            '25' => '25',
157
            '30' => '30',
158
            '35' => '35',
159
            '40' => '40',
160
            '45' => '45',
161
            '50' => '50',
162
            '55' => '55',
163
            '60' => '60',
164
            '65' => '65',
165
            '70' => '70',
166
            '75' => '75',
167
            '80' => '80',
168
            '85' => '85',
169
            '90' => '90',
170
            '95' => '95',
171
            '100' => '100',
172
            '105' => '105',
173
            '110' => '110',
174
            '115' => '115',
175
            '120' => '120',
176
            '125' => '125',
177
            '130' => '130',
178
            '135' => '135',
179
            '140' => '140',
180
            '145' => '145',
181
            '150' => '150',
182
            '155' => '155',
183
            '160' => '160',
184
            '165' => '165',
185
            '170' => '170',
186
            '175' => '175',
187
            '180' => '180',
188
            '185' => '185',
189
            '190' => '190',
190
            '195' => '195',
191
            '200' => '200'
192
        );
193
        $select = $mform->addElement('select', 'config_ccn_margin_bottom', get_string('config_margin_bottom', 'block_cesa_course_rating'), $options);
194
        $select->setSelected('0');
195
 
196
        // // Padding top
197
        // $options = array(
198
        //     '0' => 'Default',
199
        //     'zero' => '0',
200
        //     '5' => '5',
201
        //     '10' => '10',
202
        //     '15' => '15',
203
        //     '20' => '20',
204
        //     '25' => '25',
205
        //     '30' => '30',
206
        //     '35' => '35',
207
        //     '40' => '40',
208
        //     '45' => '45',
209
        //     '50' => '50',
210
        //     '55' => '55',
211
        //     '60' => '60',
212
        //     '65' => '65',
213
        //     '70' => '70',
214
        //     '75' => '75',
215
        //     '80' => '80',
216
        //     '85' => '85',
217
        //     '90' => '90',
218
        //     '95' => '95',
219
        //     '100' => '100',
220
        //     '105' => '105',
221
        //     '110' => '110',
222
        //     '115' => '115',
223
        //     '120' => '120',
224
        //     '125' => '125',
225
        //     '130' => '130',
226
        //     '135' => '135',
227
        //     '140' => '140',
228
        //     '145' => '145',
229
        //     '150' => '150',
230
        //     '155' => '155',
231
        //     '160' => '160',
232
        //     '165' => '165',
233
        //     '170' => '170',
234
        //     '175' => '175',
235
        //     '180' => '180',
236
        //     '185' => '185',
237
        //     '190' => '190',
238
        //     '195' => '195',
239
        //     '200' => '200'
240
        // );
241
        // $select = $mform->addElement('select', 'config_ccn_padding_top', get_string('config_ccn_padding_top', 'theme_edumy'), $options);
242
        // $select->setSelected('0');
243
        //
244
        // // Padding bottom
245
        // $options = array(
246
        //     '0' => 'Default',
247
        //     'zero' => '0',
248
        //     '5' => '5',
249
        //     '10' => '10',
250
        //     '15' => '15',
251
        //     '20' => '20',
252
        //     '25' => '25',
253
        //     '30' => '30',
254
        //     '35' => '35',
255
        //     '40' => '40',
256
        //     '45' => '45',
257
        //     '50' => '50',
258
        //     '55' => '55',
259
        //     '60' => '60',
260
        //     '65' => '65',
261
        //     '70' => '70',
262
        //     '75' => '75',
263
        //     '80' => '80',
264
        //     '85' => '85',
265
        //     '90' => '90',
266
        //     '95' => '95',
267
        //     '100' => '100',
268
        //     '105' => '105',
269
        //     '110' => '110',
270
        //     '115' => '115',
271
        //     '120' => '120',
272
        //     '125' => '125',
273
        //     '130' => '130',
274
        //     '135' => '135',
275
        //     '140' => '140',
276
        //     '145' => '145',
277
        //     '150' => '150',
278
        //     '155' => '155',
279
        //     '160' => '160',
280
        //     '165' => '165',
281
        //     '170' => '170',
282
        //     '175' => '175',
283
        //     '180' => '180',
284
        //     '185' => '185',
285
        //     '190' => '190',
286
        //     '195' => '195',
287
        //     '200' => '200'
288
        // );
289
        // $select = $mform->addElement('select', 'config_ccn_padding_bottom', get_string('config_ccn_padding_bottom', 'theme_edumy'), $options);
290
        // $select->setSelected('0');
291
 
292
        // Custom CSS Class
293
        $mform->addElement('text', 'config_ccn_css_class', get_string('config_css_class', 'block_cesa_course_rating'));
294
        $mform->setDefault('config_ccn_css_class', '');
295
        $mform->setType('config_ccn_css_class', PARAM_RAW);
296
    }
297
 
298
}