Proyectos de Subversion LeadersLinked - Backend

Rev

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

Rev 562 Rev 846
Línea 7... Línea 7...
7
$roleName = $currentUser->getUserTypeId();
7
$roleName = $currentUser->getUserTypeId();
Línea 8... Línea 8...
8
 
8
 
9
 
9
 
-
 
10
$routeAdd       = $this->url('settings/jobs-description/add');
10
$routeAdd       = $this->url('settings/jobs-description/add');
11
$routeDatatable = $this->url('settings/jobs-description');
Línea 11... Línea 12...
11
$routeDatatable = $this->url('settings/jobs-description');
12
$routeImport    = $this->url('settings/jobs-description/import');
12
$routeDashboard = $this->url('dashboard');
13
$routeDashboard = $this->url('dashboard');
13
 
14
 
14
$allowAdd               = $acl->isAllowed($roleName, 'settings/jobs-description/add') ? 1 : 0;
15
$allowAdd               = $acl->isAllowed($roleName, 'settings/jobs-description/add') ? 1 : 0;
-
 
16
$allowEdit              = $acl->isAllowed($roleName, 'settings/jobs-description/edit') ? 1 : 0;
Línea 15... Línea 17...
15
$allowEdit              = $acl->isAllowed($roleName, 'settings/jobs-description/edit') ? 1 : 0;
17
$allowDelete            = $acl->isAllowed($roleName, 'settings/jobs-description/delete') ? 1 : 0;
16
$allowDelete            = $acl->isAllowed($roleName, 'settings/jobs-description/delete') ? 1 : 0;
18
$allowReport            = $acl->isAllowed($roleName, 'settings/jobs-description/report') ? 1 : 0;
Línea 527... Línea 529...
527
            e.preventDefault();
529
            e.preventDefault();
528
            $('#modal').modal('hide');
530
            $('#modal').modal('hide');
529
            $('#div-listing').show();
531
            $('#div-listing').show();
530
        });
532
        });
Línea -... Línea 533...
-
 
533
 
-
 
534
        $('body').on('click', 'button.btn-import', function(e) {
-
 
535
            e.preventDefault();
-
 
536
            NProgress.start();
-
 
537
 
-
 
538
 
-
 
539
            $.ajax({
-
 
540
                'dataType'  : 'json',
-
 
541
                'method'    : 'post',
-
 
542
                'url'       : '$routeImport',
-
 
543
            }).done(function(response) {
-
 
544
                if(response['success']) {
-
 
545
                    $.fn.showSuccess(response['data']);
-
 
546
                    gridTable.api().ajax.reload(null, false);
-
 
547
                } else {
-
 
548
                    $.fn.showError(response['data']);
-
 
549
                }
-
 
550
            }).fail(function( jqXHR, textStatus, errorThrown) {
-
 
551
                $.fn.showError(textStatus);
-
 
552
            }).always(function() {
-
 
553
                NProgress.done();
-
 
554
            });
-
 
555
 
-
 
556
            return false;
-
 
557
        });
-
 
558
 
Línea 531... Línea 559...
531
 
559
 
532
 
560
 
533
        $('#form #status').bootstrapToggle({'on' : 'LABEL_ACTIVE',  'off' : 'LABEL_INACTIVE', 'width' : '160px', 'height' : '40px'});
561
        $('#form #status').bootstrapToggle({'on' : 'LABEL_ACTIVE',  'off' : 'LABEL_INACTIVE', 'width' : '160px', 'height' : '40px'});
534
        CKEDITOR.replace('functions');
562
        CKEDITOR.replace('functions');
Línea 574... Línea 602...
574
                   	</div>
602
                   	</div>
575
                   	<div class="card-footer clearfix">
603
                   	<div class="card-footer clearfix">
576
                   		<div style="float:right;">
604
                   		<div style="float:right;">
577
							<button type="button" class="btn btn-info btn-refresh"><i class="fa fa-refresh"></i> LABEL_REFRESH  </button>
605
							<button type="button" class="btn btn-info btn-refresh"><i class="fa fa-refresh"></i> LABEL_REFRESH  </button>
578
							<?php if($allowAdd) : ?>
606
							<?php if($allowAdd) : ?>
-
 
607
                            <?php if($allowImport) : ?>
-
 
608
							<button type="button" class="btn btn-primary btn-import"><i class="fa fa-upload"></i> LABEL_IMPORT </button>
-
 
609
							<?php endif; ?>
579
							<button type="button" class="btn btn-primary btn-add"><i class="fa fa-plus"></i> LABEL_ADD </button>
610
							<button type="button" class="btn btn-primary btn-add"><i class="fa fa-plus"></i> LABEL_ADD </button>
580
							<?php endif; ?>
611
							<?php endif; ?>
581
						</div>
612
						</div>
582
                 	</div>
613
                 	</div>
583
          		</div>
614
          		</div>