mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
Actualizacion automatica: 2024-07-02 01:01:40
This commit is contained in:
@ -1,35 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Controllers\Tarifas;
|
||||
use App\Controllers\BaseController;
|
||||
|
||||
|
||||
class Tarifaimpresion extends BaseController
|
||||
{
|
||||
function __construct()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public function index()
|
||||
{
|
||||
echo 'Tarifa impresion';
|
||||
}
|
||||
|
||||
public function delete()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public function add()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public function edit()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -55,6 +55,8 @@ class Tarifasencuadernacion extends \App\Controllers\BaseResourceController
|
||||
|
||||
public function index()
|
||||
{
|
||||
// Check if the user is allowed to list items
|
||||
parent::checkPermission('tarifa-encuadernacion.menu');
|
||||
|
||||
$viewData = [
|
||||
'currentModule' => static::$controllerSlug,
|
||||
@ -73,8 +75,7 @@ class Tarifasencuadernacion extends \App\Controllers\BaseResourceController
|
||||
public function add()
|
||||
{
|
||||
|
||||
|
||||
|
||||
parent::checkPermission('tarifa-encuadernacion.create', $this->indexRoute);
|
||||
|
||||
if ($this->request->getPost()) :
|
||||
|
||||
@ -157,6 +158,7 @@ class Tarifasencuadernacion extends \App\Controllers\BaseResourceController
|
||||
public function edit($requestedId = null)
|
||||
{
|
||||
|
||||
parent::checkPermission('tarifa-encuadernacion.create', $this->indexRoute);
|
||||
|
||||
if ($requestedId == null) :
|
||||
return $this->redirect2listView();
|
||||
@ -248,6 +250,12 @@ class Tarifasencuadernacion extends \App\Controllers\BaseResourceController
|
||||
return $this->displayForm(__METHOD__, $id);
|
||||
} // end function edit(...)
|
||||
|
||||
/*public function delete($id =null){
|
||||
if (!auth()->user()->can('tarifa-encuadernacion.delete')) {
|
||||
return $this->fail('No tiene permisos');
|
||||
}
|
||||
parent::delete($id);
|
||||
}*/
|
||||
|
||||
public function datatable()
|
||||
{
|
||||
|
||||
@ -55,7 +55,10 @@ class Tarifasenvios extends \App\Controllers\BaseResourceController {
|
||||
|
||||
|
||||
public function index() {
|
||||
|
||||
|
||||
// Check if the user is allowed to list items
|
||||
parent::checkPermission('tarifa-envio.menu');
|
||||
|
||||
$viewData = [
|
||||
'currentModule' => static::$controllerSlug,
|
||||
'pageSubTitle' => lang('Basic.global.ManageAllRecords', [lang('TarifasEnvios.tarifaEnvio')]),
|
||||
@ -71,9 +74,8 @@ class Tarifasenvios extends \App\Controllers\BaseResourceController {
|
||||
|
||||
|
||||
public function add() {
|
||||
|
||||
|
||||
|
||||
parent::checkPermission('tarifa-envio.create', $this->indexRoute);
|
||||
|
||||
if ($this->request->getPost()) :
|
||||
|
||||
@ -142,6 +144,8 @@ class Tarifasenvios extends \App\Controllers\BaseResourceController {
|
||||
|
||||
public function edit($requestedId = null) {
|
||||
|
||||
parent::checkPermission('tarifa-envio.edit', $this->indexRoute);
|
||||
|
||||
|
||||
if ($requestedId == null) :
|
||||
return $this->redirect2listView();
|
||||
@ -227,6 +231,10 @@ class Tarifasenvios extends \App\Controllers\BaseResourceController {
|
||||
// JJO
|
||||
public function delete($id = null)
|
||||
{
|
||||
if (!auth()->user()->can('tarifa-envio.delete')) {
|
||||
return $this->fail('Error');
|
||||
}
|
||||
|
||||
if (!empty(static::$pluralObjectNameCc) && !empty(static::$singularObjectNameCc)) {
|
||||
$objName = mb_strtolower(lang(ucfirst(static::$pluralObjectNameCc).'.'.static::$singularObjectNameCc));
|
||||
} else {
|
||||
@ -242,7 +250,6 @@ class Tarifasenvios extends \App\Controllers\BaseResourceController {
|
||||
else{
|
||||
$datetime = (new \CodeIgniter\I18n\Time("now"));
|
||||
|
||||
|
||||
$zonaModel = new TarifaEnvioZonaModel();
|
||||
$zonaResult = $zonaModel->removeAllZonasLineas($id, $datetime, $this->delete_flag);
|
||||
|
||||
|
||||
@ -51,6 +51,8 @@ class Tarifasmanipulado extends \App\Controllers\BaseResourceController
|
||||
|
||||
public function index()
|
||||
{
|
||||
// Check if the user is allowed to list items
|
||||
parent::checkPermission('tarifa-manipulado.menu');
|
||||
|
||||
$viewData = [
|
||||
'currentModule' => static::$controllerSlug,
|
||||
|
||||
Reference in New Issue
Block a user