Proyectos de Subversion LeadersLinked - Backend

Rev

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

Rev 15259 Rev 15260
Línea 1... Línea 1...
1
<?php 
1
<?php
2
$acl            = $this->viewModel()->getRoot()->getVariable('acl');
2
$acl            = $this->viewModel()->getRoot()->getVariable('acl');
3
$currentUser    = $this->currentUserHelper();
3
$currentUser    = $this->currentUserHelper();
Línea 4... Línea 4...
4
 
4
 
Línea 254... Línea 254...
254
                        $.fn.showSuccess(response['data']);
254
                        $.fn.showSuccess(response['data']);
Línea 255... Línea 255...
255
                        
255
                        
Línea 256... Línea 256...
256
                        $('#modal').modal('hide');
256
                        $('#modal').modal('hide');
257
 
257
 
258
                        
258
                        
259
                         gridTable.api().ajax.reload(null, false);
259
                        gridTable.api().ajax.reload(null, false);
260
                    } else {
260
                    } else {
261
                        validator.resetForm();
261
                        validator.resetForm();
Línea 266... Línea 266...
266
                                $.fn.showFormErrorValidator('#form #' + fieldname, errors);
266
                                $.fn.showFormErrorValidator('#form #' + fieldname, errors);
267
                            });
267
                            });
268
                        }
268
                        }
269
                    }
269
                    }
270
                }).fail(function( jqXHR, textStatus, errorThrown) {
270
                }).fail(function( jqXHR, textStatus, errorThrown) {
271
                   $.fn.showError(textStatus);
271
                    $.fn.showError(textStatus);
272
                }).always(function() {
272
                }).always(function() {
273
                    NProgress.done();
273
                    NProgress.done();
-
 
274
                    $('#modal .btn-primary').removeAttr('disabled')
274
                });
275
                });
275
                return false;
276
                return false;
276
            },
277
            },
277
            invalidHandler: function(form, validator) {
278
            invalidHandler: function(form, validator) {
278
            
279
                
279
            }
280
            }
280
        });
281
        });
Línea 281... Línea 282...
281
        
282
        
282
        $('body').on('click', 'button.btn-add', function(e) {
283
        $('body').on('click', 'button.btn-add', function(e) {
Línea 369... Línea 370...
369
    });
370
    });
370
JS;
371
JS;
371
$this->inlineScript()->captureEnd();
372
$this->inlineScript()->captureEnd();
372
?>
373
?>
Línea 373... Línea 374...
373
 
374
 
374
			
375
 
375
			
376
 
376
<!-- Content Header (Page header) -->
377
<!-- Content Header (Page header) -->
377
<section class="content-header">
378
<section class="content-header">
378
	<div class="container-fluid">
379
    <div class="container-fluid">
379
    	<div class="row mb-2">
380
        <div class="row mb-2">
380
        	<div class="col-sm-12">
381
            <div class="col-sm-12">
381
            	<h1>LABEL_BEHAVIORS</h1>
382
                <h1>LABEL_BEHAVIORS</h1>
382
			</div>
383
            </div>
383
		</div>
384
        </div>
384
	</div><!-- /.container-fluid -->
385
    </div><!-- /.container-fluid -->
Línea 385... Línea 386...
385
</section>
386
</section>
386
 
387
 
387
<section class="content">
388
<section class="content">
388
	<div class="container-fluid">
389
    <div class="container-fluid">
389
    	<div class="row">
390
        <div class="row">
390
        	<div class="col-12">
391
            <div class="col-12">
391
				<div class="card">                    
392
                <div class="card">
392
					<div class="card-body">
393
                    <div class="card-body">
393
        	    		<table id="gridTable" class="table table-striped table-hover">
394
                        <table id="gridTable" class="table table-striped table-hover">
394
                      		<thead>
395
                            <thead>
395
        						<tr>
396
                                <tr>
396
                                	<th>LABEL_DESCRIPTION</th>
397
                                    <th>LABEL_DESCRIPTION</th>
397
                                  	<th>LABEL_ACTIVE</th>
398
                                    <th>LABEL_ACTIVE</th>
398
                                  	<th>LABEL_ACTIONS</th>
399
                                    <th>LABEL_ACTIONS</th>
399
                                </tr>
400
                                </tr>
400
                       		</thead>
401
                            </thead>
401
                         	<tbody>
402
                            <tbody>
402
                         	</tbody>
403
                            </tbody>
403
                    	</table>
404
                        </table>
404
                   	</div>
405
                    </div>
405
                   	<div class="card-footer clearfix">
406
                    <div class="card-footer clearfix">
406
                   		<div style="float:right;">
407
                        <div style="float:right;">
407
							<button type="button" class="btn btn-info btn-refresh"><i class="fa fa-refresh"></i> LABEL_REFRESH  </button>
408
                            <button type="button" class="btn btn-info btn-refresh"><i class="fa fa-refresh"></i> LABEL_REFRESH </button>
408
							<?php if($allowAdd) : ?>
409
                            <?php if ($allowAdd) : ?>
409
							<button type="button" class="btn btn-primary btn-add"><i class="fa fa-plus"></i> LABEL_ADD </button>
410
                                <button type="button" class="btn btn-primary btn-add"><i class="fa fa-plus"></i> LABEL_ADD </button>
410
							<?php endif; ?>
411
                            <?php endif; ?>
411
							<?php if($allowImport) : ?>
412
                            <?php if ($allowImport) : ?>
412
							<button type="button" class="btn btn-primary btn-import"><i class="fa fa-plus"></i> LABEL_IMPORT </button>
413
                                <button type="button" class="btn btn-primary btn-import"><i class="fa fa-plus"></i> LABEL_IMPORT </button>
413
							<?php endif; ?>
414
                            <?php endif; ?>
414
						</div>
415
                        </div>
415
                 	</div>
416
                    </div>
416
          		</div>
417
                </div>
417
           	</div>     
418
            </div>
418
        </div>          
419
        </div>
Línea 419... Línea 420...
419
 	</div>
420
    </div>
420
</section> 	
421
</section>
421
 
422
 
422
<!-- The Modal -->
423
<!-- The Modal -->
Línea 423... Línea 424...
423
<div class="modal" id="modal">
424
<div class="modal" id="modal">
424
	<div class="modal-dialog  modal-xl">
425
    <div class="modal-dialog  modal-xl">
425
    	<div class="modal-content">
426
        <div class="modal-content">
426
 
427
 
427
            <!-- Modal Header -->
428
            <!-- Modal Header -->
Línea 428... Línea 429...
428
      		<div class="modal-header">
429
            <div class="modal-header">
429
        		<h4 class="modal-title">LABEL_BEHAVIOR - <span id="form-title"></span></h4>
430
                <h4 class="modal-title">LABEL_BEHAVIOR - <span id="form-title"></span></h4>
430
        		<button type="button" class="close" data-dismiss="modal">&times;</button>
431
                <button type="button" class="close" data-dismiss="modal">&times;</button>
431
      		</div>
432
            </div>
432
 
433
 
433
            <!-- Modal body -->
434
            <!-- Modal body -->
434
      		<div class="modal-body">
435
            <div class="modal-body">
435
       			 <?php 
436
                <?php
436
                    $form = $this->form;
437
                $form = $this->form;
437
            		$form->setAttributes([
438
                $form->setAttributes([
438
                        'method'    => 'post',
439
                    'method'    => 'post',
439
                        'name'      => 'form',
440
                    'name'      => 'form',
440
                        'id'        => 'form'
441
                    'id'        => 'form'
441
                    ]);
442
                ]);
442
    
443
 
443
                    $form->prepare();
444
                $form->prepare();
444
                    echo $this->form()->openTag($form);
445
                echo $this->form()->openTag($form);
445
                    ?>					
446
                ?>
446
    					<div class="form-group">
447
                <div class="form-group">
447
        					<?php 
448
                    <?php
448
                            $element = $form->get('description');
449
                    $element = $form->get('description');
449
                            $element->setOptions(['label' => 'LABEL_DESCRIPTION']);
450
                    $element->setOptions(['label' => 'LABEL_DESCRIPTION']);
450
                            $element->setAttributes(['class' => 'form-control']); 
451
                    $element->setAttributes(['class' => 'form-control']);
451
                                            
452
 
452
                            echo $this->formLabel($element);
453
                    echo $this->formLabel($element);
453
                            echo $this->formTextArea($element);
454
                    echo $this->formTextArea($element);
454
                            ?>
455
                    ?>
455
						</div>
456
                </div>
456
						<div class="form-group">
457
                <div class="form-group">
457
                      	<?php 
458
                    <?php
458
                            $element = $form->get('status');
459
                    $element = $form->get('status');
459
                            echo $this->formCheckbox($element);
460
                    echo $this->formCheckbox($element);
460
                        ?>
461
                    ?>
461
						</div>
462
                </div>
462
								
463
 
463
        				<div class="text-right">
464
                <div class="text-right">
464
                    		<button type="submit" class="btn btn-primary">LABEL_SAVE</button>
465
                    <button type="submit" class="btn btn-primary">LABEL_SAVE</button>
465
                    		<button type="button" class="btn btn-light btn-cancel">LABEL_CANCEL</button>
466
                    <button type="button" class="btn btn-light btn-cancel">LABEL_CANCEL</button>
466
                   		</div>
467
                </div>
467
     	      		<?php echo $this->form()->closeTag($form); ?>
468
                <?php echo $this->form()->closeTag($form); ?>
468
      		</div>
469
            </div>
469
 
-
 
470
 
-
 
471
    	</div>
-
 
472
	</div>
-
 
473
</div>    			
470