Proyectos de Subversion LeadersLinked - Backend

Rev

Rev 15438 | Rev 16817 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 15438 Rev 15443
Línea 3... Línea 3...
3
$currentUser    = $this->currentUserHelper();
3
$currentUser    = $this->currentUserHelper();
Línea 4... Línea 4...
4
 
4
 
Línea 5... Línea 5...
5
$roleName = $currentUser->getUserTypeId();
5
$roleName = $currentUser->getUserTypeId();
6
 
6
 
7
 
7
 
8
$routeAdd       = $this->url('settings/behaviors/add');
8
$routeAdd       = $this->url('jobs-description/behaviors/add');
9
$routeDatatable = $this->url('settings/behaviors');
9
$routeDatatable = $this->url('jobs-description/behaviors');
10
$routeImport    = $this->url('settings/behaviors/import');
10
$routeImport    = $this->url('jobs-description/behaviors/import');
11
 
11
 
12
$allowAdd       = $acl->isAllowed($roleName, 'settings/behaviors/add') ? 1 : 0;
12
$allowAdd       = $acl->isAllowed($roleName, 'jobs-description/behaviors/add') ? 1 : 0;
Línea 13... Línea 13...
13
$allowEdit      = $acl->isAllowed($roleName, 'settings/behaviors/edit') ? 1 : 0;
13
$allowEdit      = $acl->isAllowed($roleName, 'jobs-description/behaviors/edit') ? 1 : 0;
14
$allowDelete    = $acl->isAllowed($roleName, 'settings/behaviors/delete') ? 1 : 0;
14
$allowDelete    = $acl->isAllowed($roleName, 'jobs-description/behaviors/delete') ? 1 : 0;
Línea 226... Línea 226...
226
            onclick: false,
226
            onclick: false,
227
            onkeyup: false,
227
            onkeyup: false,
228
            ignore: [],
228
            ignore: [],
229
            rules: {
229
            rules: {
230
                'description': {
230
                'description': {
231
                    updateCkeditor: function() {
-
 
232
                    CKEDITOR.instances.description.updateElement();
-
 
233
                },
-
 
-
 
231
                    
234
                    required: true,
232
                    required: true,
235
                    maxlength: 128,
233
                    maxlength: 128,
236
                },
234
                },
237
                'status': {
235
                'status': {
238
                    required: false,
236
                    required: false,
Línea 305... Línea 303...
305
                if(response['success']) {
303
                if(response['success']) {
Línea 306... Línea 304...
306
 
304
 
307
                    $('span[id="form-title"]').html('LABEL_EDIT');
305
                    $('span[id="form-title"]').html('LABEL_EDIT');
308
                    $('#form').attr('action', action);
306
                    $('#form').attr('action', action);
309
                    $('#form #status').bootstrapToggle(response['data']['status'] == '$status_active' ? 'on' : 'off')
307
                    $('#form #status').bootstrapToggle(response['data']['status'] == '$status_active' ? 'on' : 'off')
Línea 310... Línea 308...
310
                    CKEDITOR.instances.description.setData(response['data']['description']);
308
                    $('#form #description').val(response['data']['description']);
Línea 311... Línea 309...
311
 
309
 
312
                    validator.resetForm();
310
                    validator.resetForm();
Línea 365... Línea 363...
365
            });
363
            });
366
            return false;
364
            return false;
367
        });
365
        });
Línea 368... Línea -...
368
 
-
 
369
 
-
 
370
        CKEDITOR.replace('description', {
-
 
371
            toolbar: [
-
 
372
                    { name: 'editing', items: ['Scayt'] },
-
 
373
                    { name: 'links', items: ['Link', 'Unlink'] },
-
 
374
                    { name: 'paragraph', items: ['NumberedList', 'BulletedList', '-', 'Outdent', 'Indent', 'Blockquote'] },
-
 
375
                    { name: 'basicstyles', items: ['Bold', 'Italic', 'Strike', 'RemoveFormat'] },
-
 
376
                    '/',
-
 
377
                    { name: 'insert', items: ['Image', 'Table', 'HorizontalRule', 'SpecialChar'] },
-
 
378
                    { name: 'styles', items: ['Styles', 'Format'] },
-
 
379
                    { name: 'tools', items: ['Maximize'] }
-
 
380
                ],
-
 
381
                removePlugins: 'elementspath,Anchor',
366
 
382
                heigth: 100
367
 
383
        });
368
 
384
    });
369
    });
385
JS;
370
JS;
Línea 463... Línea 448...
463
                    $element = $form->get('description');
448
                    $element = $form->get('description');
464
                    $element->setOptions(['label' => 'LABEL_DESCRIPTION']);
449
                    $element->setOptions(['label' => 'LABEL_DESCRIPTION']);
465
                    $element->setAttributes(['class' => 'form-control']);
450
                    $element->setAttributes(['class' => 'form-control']);
Línea 466... Línea 451...
466
 
451
 
467
                    echo $this->formLabel($element);
452
                    echo $this->formLabel($element);
468
                    echo $this->formTextArea($element);
453
                    echo $this->formText($element);
469
                    ?>
454
                    ?>
470
                </div>
455
                </div>
471
                <div class="form-group">
456
                <div class="form-group">
472
                    <?php
457
                    <?php