update
@@ -9,7 +9,7 @@ LOG_DEPRECATIONS_CHANNEL=null
|
|||||||
LOG_LEVEL=debug
|
LOG_LEVEL=debug
|
||||||
|
|
||||||
DB_CONNECTION=mysql
|
DB_CONNECTION=mysql
|
||||||
DB_HOST=31.220.16.2
|
DB_HOST=82.180.168.2
|
||||||
DB_PORT=3306
|
DB_PORT=3306
|
||||||
DB_DATABASE=u111286300_sir
|
DB_DATABASE=u111286300_sir
|
||||||
DB_USERNAME=u111286300_sir
|
DB_USERNAME=u111286300_sir
|
||||||
|
|||||||
@@ -55,10 +55,10 @@ class ShowIndexServicio extends Component
|
|||||||
|
|
||||||
if (!empty($this->tarifa_id)) {
|
if (!empty($this->tarifa_id)) {
|
||||||
|
|
||||||
$this->fecha_final_1 = $today = Carbon::now()->addDays($tarifas->dias-15);
|
|
||||||
$this->fecha_final_2 = $today = Carbon::now()->addDays($tarifas->dias+15);
|
|
||||||
|
|
||||||
$tarifas = Tarifas::with('servicio')->where('id', $this->tarifa_id)->first();
|
$tarifas = Tarifas::with('servicio')->where('id', $this->tarifa_id)->first();
|
||||||
|
$this->fecha_final_1 = $today = Carbon::now()->addDays($tarifas->dias-15);
|
||||||
|
$this->fecha_final_2 = $today = Carbon::now()->addDays($tarifas->dias+15);
|
||||||
|
|
||||||
$cuentas_creadas = Cuentas::whereDate('inicio','>=',$this->fecha)->where('servicio_id',$this->servicio_id)->where('estado','activo')->get();
|
$cuentas_creadas = Cuentas::whereDate('inicio','>=',$this->fecha)->where('servicio_id',$this->servicio_id)->where('estado','activo')->get();
|
||||||
$cuentas_tomadas = Historial_cuenta::whereIn('cuenta_id', $cuentas_creadas->pluck('id'))->count();
|
$cuentas_tomadas = Historial_cuenta::whereIn('cuenta_id', $cuentas_creadas->pluck('id'))->count();
|
||||||
|
|||||||
@@ -274,7 +274,7 @@ class ShowServicios extends Component
|
|||||||
|
|
||||||
if ((int) $pantalla_servicio >= (int) $cantidad_solicitada && (int) $pantalla_servicio_completa != (int) $this->pantallas_tarjetaPlan) {
|
if ((int) $pantalla_servicio >= (int) $cantidad_solicitada && (int) $pantalla_servicio_completa != (int) $this->pantallas_tarjetaPlan) {
|
||||||
$suma = $pantalla_servicio - $cantidad_solicitada;
|
$suma = $pantalla_servicio - $cantidad_solicitada;
|
||||||
$cantidad_necesaria = 1;
|
$cantidad_necesaria = $this->cantidad_tarjetaPlan;
|
||||||
$cuenta = Cuentas::where('servicio_id', $this->servicio_id)->whereDate('inicio', '>=', $this->fecha)->Orderby('created_at', 'ASC')->withCount('historiales')->where('estado', 'activo')->having('historiales_count', '<=', $suma)->get();
|
$cuenta = Cuentas::where('servicio_id', $this->servicio_id)->whereDate('inicio', '>=', $this->fecha)->Orderby('created_at', 'ASC')->withCount('historiales')->where('estado', 'activo')->having('historiales_count', '<=', $suma)->get();
|
||||||
|
|
||||||
} elseif ((int) $pantalla_servicio_completa == (int) $this->pantallas_tarjetaPlan) {
|
} elseif ((int) $pantalla_servicio_completa == (int) $this->pantallas_tarjetaPlan) {
|
||||||
@@ -292,10 +292,11 @@ class ShowServicios extends Component
|
|||||||
$cuenta = null;
|
$cuenta = null;
|
||||||
$cantidad_necesaria = null;
|
$cantidad_necesaria = null;
|
||||||
}
|
}
|
||||||
|
//dd($cuenta, $cantidad_necesaria);
|
||||||
for ($h = 0; $h < (int) $cantidad_necesaria; $h++) {
|
for ($h = 0; $h < (int) $cantidad_necesaria; $h++) {
|
||||||
|
//dd($h);
|
||||||
if (!empty($cuenta)) {
|
if (!empty($cuenta)) {
|
||||||
|
|
||||||
$perfil = $cuenta[$h]->historiales_count;
|
$perfil = $cuenta[$h]->historiales_count;
|
||||||
|
|
||||||
for ($y = 0; $y < (int) $pantallas; $y++) {
|
for ($y = 0; $y < (int) $pantallas; $y++) {
|
||||||
@@ -315,6 +316,7 @@ class ShowServicios extends Component
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
//dd($historial->cuentas);
|
||||||
$descuento = Saldo::where('usuario_id', Auth::user()->id)->first();
|
$descuento = Saldo::where('usuario_id', Auth::user()->id)->first();
|
||||||
|
|
||||||
$saldo_anterior = $descuento->valor;
|
$saldo_anterior = $descuento->valor;
|
||||||
@@ -323,6 +325,7 @@ class ShowServicios extends Component
|
|||||||
$cobro = $descuento->update(['valor' => $nuevo_saldo]);
|
$cobro = $descuento->update(['valor' => $nuevo_saldo]);
|
||||||
if ($cobro) {
|
if ($cobro) {
|
||||||
$historial->update(['estado' => 'activo']);
|
$historial->update(['estado' => 'activo']);
|
||||||
|
|
||||||
$this->credenciales($historial);
|
$this->credenciales($historial);
|
||||||
} else {
|
} else {
|
||||||
$this->alert('warning', 'Error en el cobro, comuniquese con soporte!', [
|
$this->alert('warning', 'Error en el cobro, comuniquese con soporte!', [
|
||||||
|
|||||||
@@ -77,6 +77,7 @@ class ShowUsuarios extends Component
|
|||||||
public $precio_modTarifas = 0;
|
public $precio_modTarifas = 0;
|
||||||
public $consulta_saldo;
|
public $consulta_saldo;
|
||||||
public $modTarifas;
|
public $modTarifas;
|
||||||
|
public $modalSaldoDesc;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -173,6 +174,23 @@ class ShowUsuarios extends Component
|
|||||||
$this->saldo_actual = $this->consulta_saldo->valor;
|
$this->saldo_actual = $this->consulta_saldo->valor;
|
||||||
$this->modalSaldo = true;
|
$this->modalSaldo = true;
|
||||||
|
|
||||||
|
}
|
||||||
|
public function saldodesc($user_saldo)
|
||||||
|
{
|
||||||
|
$this->user_saldo = $user_saldo;
|
||||||
|
$this->consulta_saldo = Saldo::where('usuario_id', $this->user_saldo)->first();
|
||||||
|
|
||||||
|
if (is_null($this->consulta_saldo)) {
|
||||||
|
$saldo = new Saldo;
|
||||||
|
$saldo->valor = 0;
|
||||||
|
$saldo->usuario_id = $this->user_saldo;
|
||||||
|
$saldo->save();
|
||||||
|
$this->consulta_saldo = $saldo;
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->saldo_actual = $this->consulta_saldo->valor;
|
||||||
|
$this->modalSaldoDesc = true;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function addSaldo()
|
public function addSaldo()
|
||||||
@@ -200,6 +218,31 @@ class ShowUsuarios extends Component
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function descontar()
|
||||||
|
{
|
||||||
|
$recarga = new recarga;
|
||||||
|
$recarga->payment_method_id = 'manual';
|
||||||
|
$recarga->status = 'Descuento';
|
||||||
|
$recarga->usuario_id = $this->user_saldo;
|
||||||
|
$recarga->saldo_id = $this->consulta_saldo->id;
|
||||||
|
$recarga->monto = $this->valor_recargar;
|
||||||
|
$recarga->valor_recarga = $this->valor_recargar;
|
||||||
|
$recarga->save();
|
||||||
|
|
||||||
|
|
||||||
|
$this->consulta_saldo->update([
|
||||||
|
'valor' => $this->saldo_actual - $this->valor_recargar
|
||||||
|
]);
|
||||||
|
|
||||||
|
$this->alert('success', 'Saldo actualizado con exito!', [
|
||||||
|
'position' => 'top'
|
||||||
|
]);
|
||||||
|
|
||||||
|
|
||||||
|
$this->limpiarSaldo();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
public function editar($id)
|
public function editar($id)
|
||||||
{
|
{
|
||||||
$this->id_edit = $id;
|
$this->id_edit = $id;
|
||||||
@@ -455,6 +498,7 @@ $usuarioEliminado = User::where('name', 'usuarioEliminado')->value('id');
|
|||||||
{
|
{
|
||||||
$this->valor_recargar = null;
|
$this->valor_recargar = null;
|
||||||
$this->modalSaldo = false;
|
$this->modalSaldo = false;
|
||||||
|
$this->modalSaldoDesc = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ------------- ACTUALIZAR ------------- */
|
/* ------------- ACTUALIZAR ------------- */
|
||||||
|
|||||||
|
After Width: | Height: | Size: 6.6 KiB |
|
After Width: | Height: | Size: 5.3 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 6.6 KiB |
|
After Width: | Height: | Size: 175 KiB |
|
After Width: | Height: | Size: 5.3 KiB |
|
After Width: | Height: | Size: 46 KiB |
@@ -161,8 +161,9 @@
|
|||||||
$n++;
|
$n++;
|
||||||
$historiales=false;
|
$historiales=false;
|
||||||
|
|
||||||
if(now()->gt($cuenta->vencimiento)){
|
if(now()->addDay()->gt($cuenta->vencimiento)){
|
||||||
$historiales = $cuenta->historiales()->where('fecha_final', '>=', now()->toDateString())->count();
|
$historiales = $cuenta->historiales()->where('fecha_final', '>', now()->addDay()->toDateString())->count();
|
||||||
|
//var_dump(now()->toDateString(), $historiales);
|
||||||
}
|
}
|
||||||
|
|
||||||
@endphp
|
@endphp
|
||||||
|
|||||||
@@ -391,7 +391,7 @@
|
|||||||
@php
|
@php
|
||||||
$n = 0;
|
$n = 0;
|
||||||
@endphp
|
@endphp
|
||||||
|
{{ dd($cuentas->cuentas) }}
|
||||||
@foreach ($cuentas->cuentas->unique() as $cuenta)
|
@foreach ($cuentas->cuentas->unique() as $cuenta)
|
||||||
@php
|
@php
|
||||||
$n++;
|
$n++;
|
||||||
@@ -403,8 +403,8 @@
|
|||||||
- URL: <span
|
- URL: <span
|
||||||
class="font-semibold text-gray-600">{{ $cuenta->servicio->url }}</span>
|
class="font-semibold text-gray-600">{{ $cuenta->servicio->url }}</span>
|
||||||
@else
|
@else
|
||||||
@foreach ($cuenta->perfil as $perfil)
|
|
||||||
@if (!empty($cuenta->servicio->ver_perfiles))
|
@if (!empty($cuenta->servicio->ver_perfiles))
|
||||||
|
@foreach ($cuenta->perfil as $perfil)
|
||||||
@if ($cuentas->id == $perfil->historial_id && $cuenta->estado == 'activo')
|
@if ($cuentas->id == $perfil->historial_id && $cuenta->estado == 'activo')
|
||||||
- Perfil <span
|
- Perfil <span
|
||||||
class="font-semibold text-gray-600">{{ $perfil->perfil }}</span>
|
class="font-semibold text-gray-600">{{ $perfil->perfil }}</span>
|
||||||
@@ -445,9 +445,9 @@
|
|||||||
@endswitch
|
@endswitch
|
||||||
@endif
|
@endif
|
||||||
@endif
|
@endif
|
||||||
@endif
|
|
||||||
@endforeach
|
@endforeach
|
||||||
@endif
|
@endif
|
||||||
|
@endif
|
||||||
</h1>
|
</h1>
|
||||||
<h1 class="mt-4">
|
<h1 class="mt-4">
|
||||||
Usuario: <p class="font-semibold text-gray-600">{{ $cuenta->correo }}
|
Usuario: <p class="font-semibold text-gray-600">{{ $cuenta->correo }}
|
||||||
@@ -525,8 +525,8 @@
|
|||||||
@if (!empty($cuenta->servicio->ver_url))
|
@if (!empty($cuenta->servicio->ver_url))
|
||||||
*URL:* {{ $cuenta->servicio->url }}
|
*URL:* {{ $cuenta->servicio->url }}
|
||||||
@else
|
@else
|
||||||
@foreach ($cuenta->perfil as $perfil)
|
|
||||||
@if (!empty($cuenta->servicio->ver_perfiles))
|
@if (!empty($cuenta->servicio->ver_perfiles))
|
||||||
|
@foreach ($cuenta->perfil as $perfil)
|
||||||
@if ($cuentas->id == $perfil->historial_id && $cuenta->estado == 'activo')
|
@if ($cuentas->id == $perfil->historial_id && $cuenta->estado == 'activo')
|
||||||
*Perfil {{ $perfil->perfil }}* @if (!empty($cuenta->servicio->perfiles))
|
*Perfil {{ $perfil->perfil }}* @if (!empty($cuenta->servicio->perfiles))
|
||||||
@switch($perfil->perfil)
|
@switch($perfil->perfil)
|
||||||
@@ -558,9 +558,9 @@
|
|||||||
@endswitch
|
@endswitch
|
||||||
@endif
|
@endif
|
||||||
@endif
|
@endif
|
||||||
@endif
|
|
||||||
@endforeach
|
@endforeach
|
||||||
@endif
|
@endif
|
||||||
|
@endif
|
||||||
|
|
||||||
*Usuario:* {{ trim($cuenta->correo) }}
|
*Usuario:* {{ trim($cuenta->correo) }}
|
||||||
*Contraseña:* {{ trim($cuenta->password) }}
|
*Contraseña:* {{ trim($cuenta->password) }}
|
||||||
|
|||||||
@@ -1,12 +1,15 @@
|
|||||||
<div x-data="{ add : @entangle('add'),
|
<div x-data="{
|
||||||
|
add: @entangle('add'),
|
||||||
editar: @entangle('editar'),
|
editar: @entangle('editar'),
|
||||||
modalSaldo: @entangle('modalSaldo'),
|
modalSaldo: @entangle('modalSaldo'),
|
||||||
gestion: @entangle('gestion'),
|
gestion: @entangle('gestion'),
|
||||||
gestionPromo: @entangle('gestionPromo'),
|
gestionPromo: @entangle('gestionPromo'),
|
||||||
modalPassword: @entangle('modalPassword'),
|
modalPassword: @entangle('modalPassword'),
|
||||||
modTarifas: @entangle('modTarifas'),
|
modTarifas: @entangle('modTarifas'),
|
||||||
|
modalSaldoDesc:@entangle('modalSaldoDesc'),
|
||||||
}" class="h-full w-full md:my-2">
|
}" class="h-full w-full md:my-2">
|
||||||
<div class=" absolute backdrop-blur-sm bg-white/70 left-0 bottom-0 top-0 right-0 h-full z-40" wire:loading wire:target="gestionarPromociones,addpromos,eliminarUsuarioPromo,gestionar,eliminarUsuarioTarifa,addtarifas,crear,actualizar,editar,eliminar,limpiarInputAdd,limpiarInputEdit,editarPassword,limpiarContra,confirmarNewPassword,saldo,addSaldo">
|
<div class=" absolute backdrop-blur-sm bg-white/70 left-0 bottom-0 top-0 right-0 h-full z-40" wire:loading
|
||||||
|
wire:target="gestionarPromociones,addpromos,eliminarUsuarioPromo,gestionar,eliminarUsuarioTarifa,addtarifas,crear,actualizar,editar,eliminar,limpiarInputAdd,limpiarInputEdit,editarPassword,limpiarContra,confirmarNewPassword,saldo,addSaldo">
|
||||||
<div class="grid h-full place-items-center ">
|
<div class="grid h-full place-items-center ">
|
||||||
<div class="max-w-xs">
|
<div class="max-w-xs">
|
||||||
<img src="./img/loading.gif" alt="" class="w-full text-center">
|
<img src="./img/loading.gif" alt="" class="w-full text-center">
|
||||||
@@ -63,7 +66,8 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
|
|
||||||
{{-- Buscar --}}
|
{{-- Buscar --}}
|
||||||
<div class="flex relative">
|
<div class="flex relative">
|
||||||
<input id="buscar" type="search" wire:model="buscar" placeholder="Buscar" class="w-full md:w-auto shadow-md border-2 active:border-neutral-200 focus:ring-0 border-neutral-200 rounded-[0.8rem] px-4 py-1 m-auto focus:border-neutral-300 focus:outline-none focus:shadow-outline">
|
<input id="buscar" type="search" wire:model="buscar" placeholder="Buscar"
|
||||||
|
class="w-full md:w-auto shadow-md border-2 active:border-neutral-200 focus:ring-0 border-neutral-200 rounded-[0.8rem] px-4 py-1 m-auto focus:border-neutral-300 focus:outline-none focus:shadow-outline">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{-- -Tabla usuarios - --}}
|
{{-- -Tabla usuarios - --}}
|
||||||
@@ -84,8 +88,8 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
@foreach ($usuarios as $usuario)
|
@foreach ($usuarios as $usuario)
|
||||||
@if ($usuario->name == 'usuarioEliminado')
|
@if ($usuario->name == 'usuarioEliminado')
|
||||||
@else
|
@else
|
||||||
|
<tr class="border-gray-200 text-left w-full pl-4 hover:bg-gray-200 hover:ring-gray-500"
|
||||||
<tr class="border-gray-200 text-left w-full pl-4 hover:bg-gray-200 hover:ring-gray-500" x-data="{ openOption: false }">
|
x-data="{ openOption: false }">
|
||||||
<td class="pl-[2rem]">{{ $usuario->name ?? '' }}</td>
|
<td class="pl-[2rem]">{{ $usuario->name ?? '' }}</td>
|
||||||
|
|
||||||
<td class="pl-[2rem]">{{ $usuario->email ?? '' }}</td>
|
<td class="pl-[2rem]">{{ $usuario->email ?? '' }}</td>
|
||||||
@@ -95,13 +99,14 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
<td class="pl-[2rem]">{{ $usuario->historiales_venta_count ?? '' }}</td>
|
<td class="pl-[2rem]">{{ $usuario->historiales_venta_count ?? '' }}</td>
|
||||||
|
|
||||||
<td class="pl-[2rem]">{{ $usuario->saldo->valor ?? '' }}</td>
|
<td class="pl-[2rem]">{{ $usuario->saldo->valor ?? '' }}</td>
|
||||||
<td class="pl-[2rem]"><button wire:click="saldo({{$usuario->id}})" class="justify-center text-sm flex px-2 py-1 rounded-lg cursor-pointer text-white bg-[#B221FD] hover:bg-[#7a02b8] mb-0 md:mb-0">Recargar</button></td>
|
<td class="pl-[2rem]"><button wire:click="saldo({{ $usuario->id }})"
|
||||||
|
class="justify-center text-sm flex px-2 py-1 rounded-lg cursor-pointer text-white bg-[#B221FD] hover:bg-[#7a02b8] mb-0 md:mb-0">Recargar</button>
|
||||||
|
</td>
|
||||||
|
|
||||||
<td class="md:pl-[2rem] md:pr-[2rem]">
|
<td class="md:pl-[2rem] md:pr-[2rem]">
|
||||||
<button x-on:click="openOption=!openOption">
|
<button x-on:click="openOption=!openOption">
|
||||||
<svg xmlns="http://www.w3.org/2000/svg"
|
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
|
||||||
fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"
|
stroke-width="1.5" stroke="currentColor" class="w-6 h-6 cursor-pointer">
|
||||||
class="w-6 h-6 cursor-pointer">
|
|
||||||
<path stroke-linecap="round" stroke-linejoin="round"
|
<path stroke-linecap="round" stroke-linejoin="round"
|
||||||
d="M6.75 12a.75.75 0 11-1.5 0 .75.75 0 011.5 0zM12.75 12a.75.75 0 11-1.5 0 .75.75 0 011.5 0zM18.75 12a.75.75 0 11-1.5 0 .75.75 0 011.5 0z" />
|
d="M6.75 12a.75.75 0 11-1.5 0 .75.75 0 011.5 0zM12.75 12a.75.75 0 11-1.5 0 .75.75 0 011.5 0zM18.75 12a.75.75 0 11-1.5 0 .75.75 0 011.5 0z" />
|
||||||
</svg>
|
</svg>
|
||||||
@@ -111,16 +116,25 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
class="sm:absolute bg-white text-center w-[8rem] rounded-[1rem] border-b border-gray-200 shadow-lg">
|
class="sm:absolute bg-white text-center w-[8rem] rounded-[1rem] border-b border-gray-200 shadow-lg">
|
||||||
<button x-on:click="openOption=false" wire:click="editar({{ $usuario->id }})"
|
<button x-on:click="openOption=false" wire:click="editar({{ $usuario->id }})"
|
||||||
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 hover:rounded-t-[1rem]">Editar</button>
|
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 hover:rounded-t-[1rem]">Editar</button>
|
||||||
<button x-on:click="openOption=!openOption" wire:click="editarPassword({{$usuario->id}})"
|
<button x-on:click="openOption=!openOption"
|
||||||
|
wire:click="editarPassword({{ $usuario->id }})"
|
||||||
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Editar
|
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Editar
|
||||||
password</button>
|
password</button>
|
||||||
<button x-on:click="openOption=false" wire:click="saldo({{ $usuario->id }})"
|
<button x-on:click="openOption=false" wire:click="saldo({{ $usuario->id }})"
|
||||||
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Agregar saldo</button>
|
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Agregar
|
||||||
<button x-on:click="openOption=false,gestion=true" wire:click="gestionar({{$usuario->id}},'{{$usuario->rol_id}}','{{$usuario->name}}')"
|
saldo</button>
|
||||||
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Precio servicio</button>
|
<button x-on:click="openOption=false" wire:click="saldodesc({{ $usuario->id }})"
|
||||||
<button x-on:click="openOption=false,gestionPromo=true" wire:click="gestionarPromociones({{$usuario->id}},'{{$usuario->name}}')"
|
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Descontar saldo</button>
|
||||||
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Precio promocion</button>
|
<button x-on:click="openOption=false,gestion=true"
|
||||||
<button x-on:click="openOption=false" wire:click="eliminar({{$usuario->id}})"
|
wire:click="gestionar({{ $usuario->id }},'{{ $usuario->rol_id }}','{{ $usuario->name }}')"
|
||||||
|
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Precio
|
||||||
|
servicio</button>
|
||||||
|
<button x-on:click="openOption=false,gestionPromo=true"
|
||||||
|
wire:click="gestionarPromociones({{ $usuario->id }},'{{ $usuario->name }}')"
|
||||||
|
class="text-gray-500 w-full py-1 hover:bg-gray-200 border-b border-gray-300 ">Precio
|
||||||
|
promocion</button>
|
||||||
|
<button x-on:click="openOption=false"
|
||||||
|
wire:click="eliminar({{ $usuario->id }})"
|
||||||
class="text-white w-full py-1 bg-red-400 rounded-b-[1rem] hover:bg-red-600 hover:rounded-b-[1rem]">Eliminar</button>
|
class="text-white w-full py-1 bg-red-400 rounded-b-[1rem] hover:bg-red-600 hover:rounded-b-[1rem]">Eliminar</button>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
@@ -143,7 +157,9 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
<p class="text-gray-500 mb-2"> Personalización de precios para {{ $usuario_nombre }} </p>
|
<p class="text-gray-500 mb-2"> Personalización de precios para {{ $usuario_nombre }} </p>
|
||||||
|
|
||||||
<div class="flex mb-4">
|
<div class="flex mb-4">
|
||||||
<input id="buscar_servicio" type="search" wire:model="buscar_servicio" placeholder="Buscar servicio" class="w-full md:w-auto shadow-md border-2 active:border-neutral-200 focus:ring-0 border-neutral-200 rounded-[0.8rem] px-4 py-1 m-auto focus:border-neutral-300 focus:outline-none focus:shadow-outline">
|
<input id="buscar_servicio" type="search" wire:model="buscar_servicio"
|
||||||
|
placeholder="Buscar servicio"
|
||||||
|
class="w-full md:w-auto shadow-md border-2 active:border-neutral-200 focus:ring-0 border-neutral-200 rounded-[0.8rem] px-4 py-1 m-auto focus:border-neutral-300 focus:outline-none focus:shadow-outline">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
@@ -155,21 +171,31 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
@if (!empty($consulta_tarifas))
|
@if (!empty($consulta_tarifas))
|
||||||
@foreach ($consulta_tarifas as $consulta_tarifa)
|
@foreach ($consulta_tarifas as $consulta_tarifa)
|
||||||
@if ($consulta_tarifa->servicio->por_tiempo)
|
@if ($consulta_tarifa->servicio->por_tiempo)
|
||||||
<option value="{{ $consulta_tarifa->id }}">{{ $consulta_tarifa->servicio->nombre ?? '' }}: {{ $consulta_tarifa->dias ?? '' }} {{ $consulta_tarifa->dias == 1 ? 'día' : 'días' }}</option>
|
<option value="{{ $consulta_tarifa->id }}">
|
||||||
|
{{ $consulta_tarifa->servicio->nombre ?? '' }}:
|
||||||
|
{{ $consulta_tarifa->dias ?? '' }}
|
||||||
|
{{ $consulta_tarifa->dias == 1 ? 'día' : 'días' }}</option>
|
||||||
@else
|
@else
|
||||||
<option value="{{ $consulta_tarifa->id }}">{{ $consulta_tarifa->servicio->nombre ?? '' }}: {{ $consulta_tarifa->pantallas ?? '' }} {{ $consulta_tarifa->pantallas == 1 ? 'pantalla' : 'pantallas' }} - {{ $consulta_tarifa->dias ?? '' }} {{ $consulta_tarifa->dias == 1 ? 'día' : 'días' }}</option>
|
<option value="{{ $consulta_tarifa->id }}">
|
||||||
|
{{ $consulta_tarifa->servicio->nombre ?? '' }}:
|
||||||
|
{{ $consulta_tarifa->pantallas ?? '' }}
|
||||||
|
{{ $consulta_tarifa->pantallas == 1 ? 'pantalla' : 'pantallas' }} -
|
||||||
|
{{ $consulta_tarifa->dias ?? '' }}
|
||||||
|
{{ $consulta_tarifa->dias == 1 ? 'día' : 'días' }}</option>
|
||||||
@endif
|
@endif
|
||||||
@endforeach
|
@endforeach
|
||||||
@endif
|
@endif
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
<div class="w-[7rem]">
|
<div class="w-[7rem]">
|
||||||
<input placeholder="$25000" type="number" id="precioTarifasGestion" wire:model="precioTarifasGestion" min="0"
|
<input placeholder="$25000" type="number" id="precioTarifasGestion"
|
||||||
|
wire:model="precioTarifasGestion" min="0"
|
||||||
class="w-full border-2 border-neutral-200 rounded-[0.8rem] focus:ring-0 shadow apperance-none focus:border-neutral-300 py-2 pl-2 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="w-full border-2 border-neutral-200 rounded-[0.8rem] focus:ring-0 shadow apperance-none focus:border-neutral-300 py-2 pl-2 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
</div>
|
</div>
|
||||||
<div class="w-[5rem] self-center justify-self-center mx-auto">
|
<div class="w-[5rem] self-center justify-self-center mx-auto">
|
||||||
<label class="text-gray-500 text-base">Ocultar</label>
|
<label class="text-gray-500 text-base">Ocultar</label>
|
||||||
<input type="checkbox" wire:model="estadoTarifa" checked class="mx-auto p-2 rounded-full text-black">
|
<input type="checkbox" wire:model="estadoTarifa" checked
|
||||||
|
class="mx-auto p-2 rounded-full text-black">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -181,7 +207,8 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<table class="w-full sm-w-[20rem] text-center mt-4 border-separate border-spacing-y-2 bg-white shadow-md rounded-lg mb-2">
|
<table
|
||||||
|
class="w-full sm-w-[20rem] text-center mt-4 border-separate border-spacing-y-2 bg-white shadow-md rounded-lg mb-2">
|
||||||
<thead class="font-normal text-gray-500 h-9">
|
<thead class="font-normal text-gray-500 h-9">
|
||||||
<tr class="text-left">
|
<tr class="text-left">
|
||||||
<th class="rounded-l-lg font-normal pl-[2rem]">Servicio</th>
|
<th class="rounded-l-lg font-normal pl-[2rem]">Servicio</th>
|
||||||
@@ -195,28 +222,49 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
@if (!empty($consulta_usuarioTarifas))
|
@if (!empty($consulta_usuarioTarifas))
|
||||||
@foreach ($consulta_usuarioTarifas as $usuarioTarifa)
|
@foreach ($consulta_usuarioTarifas as $usuarioTarifa)
|
||||||
<tr class="border-gray-200 text-left w-full pl-4">
|
<tr class="border-gray-200 text-left w-full pl-4">
|
||||||
<td class="pl-[2rem]">{{ $usuarioTarifa->tarifa->servicio->nombre ?? '' }}</td>
|
<td class="pl-[2rem]">{{ $usuarioTarifa->tarifa->servicio->nombre ?? '' }}
|
||||||
|
</td>
|
||||||
|
|
||||||
<td class="pl-[2rem]">
|
<td class="pl-[2rem]">
|
||||||
@if ($usuarioTarifa->tarifa->servicio->por_tiempo)
|
@if ($usuarioTarifa->tarifa->servicio->por_tiempo)
|
||||||
{{ $usuarioTarifa->tarifa->dias ?? '' }} {{ $usuarioTarifa->tarifa->dias == 1 ? 'día' : 'días' }}
|
{{ $usuarioTarifa->tarifa->dias ?? '' }}
|
||||||
|
{{ $usuarioTarifa->tarifa->dias == 1 ? 'día' : 'días' }}
|
||||||
@else
|
@else
|
||||||
{{ $usuarioTarifa->tarifa->pantallas ?? '' }} {{ $usuarioTarifa->tarifa->pantallas == 1 ? 'pantalla' : 'pantallas' }} - {{ $usuarioTarifa->tarifa->dias ?? '' }} {{ $usuarioTarifa->tarifa->dias == 1 ? 'día' : 'días' }}
|
{{ $usuarioTarifa->tarifa->pantallas ?? '' }}
|
||||||
|
{{ $usuarioTarifa->tarifa->pantallas == 1 ? 'pantalla' : 'pantallas' }}
|
||||||
|
- {{ $usuarioTarifa->tarifa->dias ?? '' }}
|
||||||
|
{{ $usuarioTarifa->tarifa->dias == 1 ? 'día' : 'días' }}
|
||||||
@endif
|
@endif
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
@if ($usuarioTarifa->visible != 'true')
|
@if ($usuarioTarifa->visible != 'true')
|
||||||
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly checked class="mx-auto p-2 rounded-full text-black"></td>
|
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly
|
||||||
|
checked class="mx-auto p-2 rounded-full text-black"></td>
|
||||||
@else
|
@else
|
||||||
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly class="mx-auto p-2 rounded-full text-black"></td>
|
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly
|
||||||
|
class="mx-auto p-2 rounded-full text-black"></td>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
<td class="pl-[2rem]">${{ $usuarioTarifa->precio ?? '' }}</td>
|
<td class="pl-[2rem]">${{ $usuarioTarifa->precio ?? '' }}</td>
|
||||||
|
|
||||||
<td class="pl-[1rem] pr-[1rem]">
|
<td class="pl-[1rem] pr-[1rem]">
|
||||||
<svg wire:click="eliminarUsuarioTarifa({{$usuarioTarifa->id}})" xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.com/svgjs" class="w-6 cursor-pointer" x="0" y="0" viewBox="0 0 24 24" style="enable-background:new 0 0 512 512" xml:space="preserve"><g><g id="Flat_Color" data-name="Flat Color"><circle cx="12" cy="12" fill="#e63946" r="10" data-original="#e63946" class=""></circle><path d="m13.41 12 2.3-2.29a1 1 0 0 0 -1.42-1.42l-2.29 2.3-2.29-2.3a1 1 0 0 0 -1.42 1.42l2.3 2.29-2.3 2.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l2.29-2.3 2.29 2.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z" fill="#edebea" data-original="#edebea" class=""></path></g></g>
|
<svg wire:click="eliminarUsuarioTarifa({{ $usuarioTarifa->id }})"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" version="1.1"
|
||||||
|
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
|
xmlns:svgjs="http://svgjs.com/svgjs" class="w-6 cursor-pointer"
|
||||||
|
x="0" y="0" viewBox="0 0 24 24"
|
||||||
|
style="enable-background:new 0 0 512 512" xml:space="preserve">
|
||||||
|
<g>
|
||||||
|
<g id="Flat_Color" data-name="Flat Color">
|
||||||
|
<circle cx="12" cy="12" fill="#e63946"
|
||||||
|
r="10" data-original="#e63946" class="">
|
||||||
|
</circle>
|
||||||
|
<path
|
||||||
|
d="m13.41 12 2.3-2.29a1 1 0 0 0 -1.42-1.42l-2.29 2.3-2.29-2.3a1 1 0 0 0 -1.42 1.42l2.3 2.29-2.3 2.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l2.29-2.3 2.29 2.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z"
|
||||||
|
fill="#edebea" data-original="#edebea" class="">
|
||||||
|
</path>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -247,7 +295,9 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
<p class="text-gray-500 mb-2"> Personalización de precios para {{ $usuario_nombre }} </p>
|
<p class="text-gray-500 mb-2"> Personalización de precios para {{ $usuario_nombre }} </p>
|
||||||
|
|
||||||
<div class="flex mb-4">
|
<div class="flex mb-4">
|
||||||
<input id="buscar_promo" type="search" wire:model="buscar_promo" placeholder="Buscar promocion" class="w-full md:w-auto shadow-md border-2 active:border-neutral-200 focus:ring-0 border-neutral-200 rounded-[0.8rem] px-4 py-1 m-auto focus:border-neutral-300 focus:outline-none focus:shadow-outline">
|
<input id="buscar_promo" type="search" wire:model="buscar_promo"
|
||||||
|
placeholder="Buscar promocion"
|
||||||
|
class="w-full md:w-auto shadow-md border-2 active:border-neutral-200 focus:ring-0 border-neutral-200 rounded-[0.8rem] px-4 py-1 m-auto focus:border-neutral-300 focus:outline-none focus:shadow-outline">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
@@ -259,7 +309,8 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
@if (!empty($consulta_promo))
|
@if (!empty($consulta_promo))
|
||||||
@foreach ($consulta_promo as $promocion)
|
@foreach ($consulta_promo as $promocion)
|
||||||
@if (!empty($promocion->nombre))
|
@if (!empty($promocion->nombre))
|
||||||
<option value="{{ $promocion->id }}">{{ $promocion->nombre ?? '' }}</option>
|
<option value="{{ $promocion->id }}">{{ $promocion->nombre ?? '' }}
|
||||||
|
</option>
|
||||||
@endif
|
@endif
|
||||||
@endforeach
|
@endforeach
|
||||||
@endif
|
@endif
|
||||||
@@ -267,12 +318,14 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
<div class="w-[7rem]">
|
<div class="w-[7rem]">
|
||||||
<input placeholder="$25000" type="number" id="precioPromoGestion" wire:model="precioPromoGestion" min="0"
|
<input placeholder="$25000" type="number" id="precioPromoGestion"
|
||||||
|
wire:model="precioPromoGestion" min="0"
|
||||||
class="w-full border-2 border-neutral-200 rounded-[0.8rem] focus:ring-0 shadow apperance-none focus:border-neutral-300 py-2 pl-2 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="w-full border-2 border-neutral-200 rounded-[0.8rem] focus:ring-0 shadow apperance-none focus:border-neutral-300 py-2 pl-2 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
</div>
|
</div>
|
||||||
<div class="w-[5rem] self-center justify-self-center mx-auto">
|
<div class="w-[5rem] self-center justify-self-center mx-auto">
|
||||||
<label class="text-gray-500 text-base">Ocultar</label>
|
<label class="text-gray-500 text-base">Ocultar</label>
|
||||||
<input type="checkbox" wire:model="estadoPromo" checked class="mx-auto p-2 rounded-full text-black">
|
<input type="checkbox" wire:model="estadoPromo" checked
|
||||||
|
class="mx-auto p-2 rounded-full text-black">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -284,7 +337,8 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<table class="w-full sm-w-[20rem] text-center mt-4 border-separate border-spacing-y-2 bg-white shadow-md rounded-lg mb-2">
|
<table
|
||||||
|
class="w-full sm-w-[20rem] text-center mt-4 border-separate border-spacing-y-2 bg-white shadow-md rounded-lg mb-2">
|
||||||
<thead class="font-normal text-gray-500 h-9">
|
<thead class="font-normal text-gray-500 h-9">
|
||||||
<tr class="text-left">
|
<tr class="text-left">
|
||||||
<th class="rounded-l-lg font-normal pl-[2rem]">Promocion</th>
|
<th class="rounded-l-lg font-normal pl-[2rem]">Promocion</th>
|
||||||
@@ -301,15 +355,33 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
<td class="pl-[2rem]">{{ $usuarioPromo->promocion->nombre ?? '' }}</td>
|
<td class="pl-[2rem]">{{ $usuarioPromo->promocion->nombre ?? '' }}</td>
|
||||||
|
|
||||||
@if ($usuarioPromo->visible != 'true')
|
@if ($usuarioPromo->visible != 'true')
|
||||||
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly checked class="mx-auto p-2 rounded-full text-black"></td>
|
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly
|
||||||
|
checked class="mx-auto p-2 rounded-full text-black"></td>
|
||||||
@else
|
@else
|
||||||
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly class="mx-auto p-2 rounded-full text-black"></td>
|
<td class="pl-[2rem] flex"><input type="checkbox" disabled readonly
|
||||||
|
class="mx-auto p-2 rounded-full text-black"></td>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
<td class="pl-[2rem]">${{ $usuarioPromo->precio ?? '' }}</td>
|
<td class="pl-[2rem]">${{ $usuarioPromo->precio ?? '' }}</td>
|
||||||
|
|
||||||
<td class="pl-[1rem] pr-[1rem]">
|
<td class="pl-[1rem] pr-[1rem]">
|
||||||
<svg wire:click="eliminarUsuarioPromo({{$usuarioPromo->id}})" xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.com/svgjs" class="w-6 cursor-pointer" x="0" y="0" viewBox="0 0 24 24" style="enable-background:new 0 0 512 512" xml:space="preserve"><g><g id="Flat_Color" data-name="Flat Color"><circle cx="12" cy="12" fill="#e63946" r="10" data-original="#e63946" class=""></circle><path d="m13.41 12 2.3-2.29a1 1 0 0 0 -1.42-1.42l-2.29 2.3-2.29-2.3a1 1 0 0 0 -1.42 1.42l2.3 2.29-2.3 2.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l2.29-2.3 2.29 2.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z" fill="#edebea" data-original="#edebea" class=""></path></g></g>
|
<svg wire:click="eliminarUsuarioPromo({{ $usuarioPromo->id }})"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" version="1.1"
|
||||||
|
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
|
xmlns:svgjs="http://svgjs.com/svgjs" class="w-6 cursor-pointer"
|
||||||
|
x="0" y="0" viewBox="0 0 24 24"
|
||||||
|
style="enable-background:new 0 0 512 512" xml:space="preserve">
|
||||||
|
<g>
|
||||||
|
<g id="Flat_Color" data-name="Flat Color">
|
||||||
|
<circle cx="12" cy="12" fill="#e63946"
|
||||||
|
r="10" data-original="#e63946" class="">
|
||||||
|
</circle>
|
||||||
|
<path
|
||||||
|
d="m13.41 12 2.3-2.29a1 1 0 0 0 -1.42-1.42l-2.29 2.3-2.29-2.3a1 1 0 0 0 -1.42 1.42l2.3 2.29-2.3 2.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l2.29-2.3 2.29 2.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z"
|
||||||
|
fill="#edebea" data-original="#edebea" class="">
|
||||||
|
</path>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -340,19 +412,21 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
<form>
|
<form>
|
||||||
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4 rounded-[1rem] shadow-md">
|
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4 rounded-[1rem] shadow-md">
|
||||||
<div class="mb-4">
|
<div class="mb-4">
|
||||||
<label for="nombre"
|
<label for="nombre" class="block text-gray-700 text-sm font-bold mb-2">Nombre:</label>
|
||||||
class="block text-gray-700 text-sm font-bold mb-2">Nombre:</label>
|
|
||||||
<input type="text" id="nombre" wire:model="nombre"
|
<input type="text" id="nombre" wire:model="nombre"
|
||||||
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
@error('nombre') <span class="text-red-400 text-sm ">Requerido*</span> @enderror
|
@error('nombre')
|
||||||
|
<span class="text-red-400 text-sm ">Requerido*</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-4">
|
<div class="mb-4">
|
||||||
<label for="email"
|
<label for="email" class="block text-gray-700 text-sm font-bold mb-2">Email:</label>
|
||||||
class="block text-gray-700 text-sm font-bold mb-2">Email:</label>
|
|
||||||
<input type="text" id="email" wire:model="email"
|
<input type="text" id="email" wire:model="email"
|
||||||
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
@error('email') <span class="text-red-400 text-sm ">Requerido*</span> @enderror
|
@error('email')
|
||||||
|
<span class="text-red-400 text-sm ">Requerido*</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-4">
|
<div class="mb-4">
|
||||||
@@ -360,7 +434,9 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
class="block text-gray-700 text-sm font-bold mb-2">Contraseña:</label>
|
class="block text-gray-700 text-sm font-bold mb-2">Contraseña:</label>
|
||||||
<input type="text" id="password" wire:model="password"
|
<input type="text" id="password" wire:model="password"
|
||||||
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
@error('password') <span class="text-red-400 text-sm ">Requerido*</span> @enderror
|
@error('password')
|
||||||
|
<span class="text-red-400 text-sm ">Requerido*</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-4">
|
<div class="mb-4">
|
||||||
@@ -372,7 +448,9 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
<option value="{{ $rol->id }}">{{ $rol->nombre }}</option>
|
<option value="{{ $rol->id }}">{{ $rol->nombre }}</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
</select>
|
</select>
|
||||||
@error('rol') <span class="text-red-400 text-sm ">Requerido*</span> @enderror
|
@error('rol')
|
||||||
|
<span class="text-red-400 text-sm ">Requerido*</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
@@ -405,15 +483,18 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
class="block text-gray-700 text-sm font-bold mb-2">Nombre:</label>
|
class="block text-gray-700 text-sm font-bold mb-2">Nombre:</label>
|
||||||
<input type="text" id="nombre_edit" wire:model="nombre_edit"
|
<input type="text" id="nombre_edit" wire:model="nombre_edit"
|
||||||
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
@error('nombre_edit') <span class="text-red-400 text-sm ">Requerido*</span> @enderror
|
@error('nombre_edit')
|
||||||
|
<span class="text-red-400 text-sm ">Requerido*</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-4">
|
<div class="mb-4">
|
||||||
<label for="email_edit"
|
<label for="email_edit" class="block text-gray-700 text-sm font-bold mb-2">Email:</label>
|
||||||
class="block text-gray-700 text-sm font-bold mb-2">Email:</label>
|
|
||||||
<input type="text" id="email_edit" wire:model="email_edit"
|
<input type="text" id="email_edit" wire:model="email_edit"
|
||||||
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
@error('email_edit') <span class="text-red-400 text-sm ">Requerido*</span> @enderror
|
@error('email_edit')
|
||||||
|
<span class="text-red-400 text-sm ">Requerido*</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-4">
|
<div class="mb-4">
|
||||||
@@ -426,7 +507,9 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
@endforeach
|
@endforeach
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
@error('rol_edit') <span class="text-red-400 text-sm ">Requerido*</span> @enderror
|
@error('rol_edit')
|
||||||
|
<span class="text-red-400 text-sm ">Requerido*</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
@@ -446,13 +529,11 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{-- Modal contraseña --}}
|
{{-- Modal contraseña --}}
|
||||||
<div x-cloak x-show="modalPassword"
|
<div x-cloak x-show="modalPassword" x-transition:enter="transition duration-350"
|
||||||
x-transition:enter="transition duration-350"
|
x-transition:enter-start="opacity-0 scale-100" x-transition:enter-end="opacity-100 scale-100"
|
||||||
x-transition:enter-start="opacity-0 scale-100"
|
x-transition:leave="transition duration-350" x-transition:leave-start="opacity-100 scale-100"
|
||||||
x-transition:enter-end="opacity-100 scale-100"
|
x-transition:leave-end="opacity-0 scale-100"
|
||||||
x-transition:leave="transition duration-350"
|
class="absolute backdrop-blur-sm bg-black/20 left-0 bottom-0 top-0 right-0 h-full">
|
||||||
x-transition:leave-start="opacity-100 scale-100"
|
|
||||||
x-transition:leave-end="opacity-0 scale-100" class="absolute backdrop-blur-sm bg-black/20 left-0 bottom-0 top-0 right-0 h-full">
|
|
||||||
<div class="grid h-full place-items-center">
|
<div class="grid h-full place-items-center">
|
||||||
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4 rounded-[1rem] shadow-md">
|
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4 rounded-[1rem] shadow-md">
|
||||||
<div class="text-center bg-[#000029] text-white text-lg font-semibold rounded-lg py-2 mb-4">
|
<div class="text-center bg-[#000029] text-white text-lg font-semibold rounded-lg py-2 mb-4">
|
||||||
@@ -460,17 +541,23 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-4 mt-4">
|
<div class="mb-4 mt-4">
|
||||||
<label for="newPassword" class="block text-gray-700 text-sm font-bold mb-2">Nueva contraseña:</label>
|
<label for="newPassword" class="block text-gray-700 text-sm font-bold mb-2">Nueva
|
||||||
<input type="text" id="newPassword" wire:model="newPassword" class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:ring-0 focus:border-neutral-300 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
contraseña:</label>
|
||||||
@error('newPassword') <span class="error text-red-400">{{ 'Diligencie correctamente*'}}</span> @enderror
|
<input type="text" id="newPassword" wire:model="newPassword"
|
||||||
|
class="border-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:ring-0 focus:border-neutral-300 w-full py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
|
@error('newPassword')
|
||||||
|
<span class="error text-red-400">{{ 'Diligencie correctamente*' }}</span>
|
||||||
|
@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="bg-white px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse sm:justify-evenly gap-5 mt-4">
|
<div class="bg-white px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse sm:justify-evenly gap-5 mt-4">
|
||||||
<span>
|
<span>
|
||||||
<button wire:click="confirmarNewPassword" type="button" class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 sm:mb-[0] mb-2 text-white bg-[#B221FD] hover:bg-[#7a02b8] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Guardar</button>
|
<button wire:click="confirmarNewPassword" type="button"
|
||||||
|
class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 sm:mb-[0] mb-2 text-white bg-[#B221FD] hover:bg-[#7a02b8] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Guardar</button>
|
||||||
</span>
|
</span>
|
||||||
<span>
|
<span>
|
||||||
<button wire:click="limpiarContra" type="button" class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 text-white bg-[#585858] hover:bg-[#3a3a3a] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Cerrar</button>
|
<button wire:click="limpiarContra" type="button"
|
||||||
|
class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 text-white bg-[#585858] hover:bg-[#3a3a3a] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Cerrar</button>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -478,13 +565,11 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{-- Modal add saldo --}}
|
{{-- Modal add saldo --}}
|
||||||
<div x-cloak x-show="modalSaldo"
|
<div x-cloak x-show="modalSaldo" x-transition:enter="transition duration-350"
|
||||||
x-transition:enter="transition duration-350"
|
x-transition:enter-start="opacity-0 scale-100" x-transition:enter-end="opacity-100 scale-100"
|
||||||
x-transition:enter-start="opacity-0 scale-100"
|
x-transition:leave="transition duration-350" x-transition:leave-start="opacity-100 scale-100"
|
||||||
x-transition:enter-end="opacity-100 scale-100"
|
x-transition:leave-end="opacity-0 scale-100"
|
||||||
x-transition:leave="transition duration-350"
|
class="absolute backdrop-blur-sm bg-black/20 left-0 bottom-0 top-0 right-0 h-full">
|
||||||
x-transition:leave-start="opacity-100 scale-100"
|
|
||||||
x-transition:leave-end="opacity-0 scale-100" class="absolute backdrop-blur-sm bg-black/20 left-0 bottom-0 top-0 right-0 h-full">
|
|
||||||
<div class="grid h-full place-items-center">
|
<div class="grid h-full place-items-center">
|
||||||
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4 rounded-[1rem] shadow-md">
|
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4 rounded-[1rem] shadow-md">
|
||||||
<div class="text-center bg-[#000029] text-white text-lg font-semibold rounded-lg py-2 mb-4">
|
<div class="text-center bg-[#000029] text-white text-lg font-semibold rounded-lg py-2 mb-4">
|
||||||
@@ -498,21 +583,74 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
Monto a recargar
|
Monto a recargar
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<input type="number" min="0" name="monto" wire:model="valor_recargar" placeholder="$100.000" required
|
<input type="number" min="0" name="monto" wire:model="valor_recargar"
|
||||||
|
placeholder="$100.000" required
|
||||||
class="border-2 w-1/2 md:w-auto mb-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="border-2 w-1/2 md:w-auto mb-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
|
|
||||||
<div class="flex text-sm justify-center">Tu valor total seria: $<p> {{$saldo_actual + $valor_recargar}}
|
<div class="flex text-sm justify-center">Tu valor total seria: $<p>
|
||||||
|
{{ $saldo_actual + $valor_recargar }}
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="bg-white px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse sm:justify-evenly gap-5 mt-4">
|
<div
|
||||||
|
class="bg-white px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse sm:justify-evenly gap-5 mt-4">
|
||||||
<span>
|
<span>
|
||||||
<button wire:click="addSaldo" type="button" class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 sm:mb-[0] mb-2 text-white bg-[#B221FD] hover:bg-[#7a02b8] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Guardar</button>
|
<button wire:click="addSaldo" type="button"
|
||||||
|
class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 sm:mb-[0] mb-2 text-white bg-[#B221FD] hover:bg-[#7a02b8] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Guardar</button>
|
||||||
</span>
|
</span>
|
||||||
<span>
|
<span>
|
||||||
<button wire:click="limpiarSaldo" x-on:click="modalSaldo=false" type="button" class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 text-white bg-[#585858] hover:bg-[#3a3a3a] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Cerrar</button>
|
<button wire:click="limpiarSaldo" x-on:click="modalSaldo=false" type="button"
|
||||||
|
class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 text-white bg-[#585858] hover:bg-[#3a3a3a] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Cerrar</button>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- Modal quitar saldo --}}
|
||||||
|
<div x-cloak x-show="modalSaldoDesc" x-transition:enter="transition duration-350"
|
||||||
|
x-transition:enter-start="opacity-0 scale-100" x-transition:enter-end="opacity-100 scale-100"
|
||||||
|
x-transition:leave="transition duration-350" x-transition:leave-start="opacity-100 scale-100"
|
||||||
|
x-transition:leave-end="opacity-0 scale-100"
|
||||||
|
class="absolute backdrop-blur-sm bg-black/20 left-0 bottom-0 top-0 right-0 h-full">
|
||||||
|
<div class="grid h-full place-items-center">
|
||||||
|
<div class="bg-white px-4 pt-5 pb-4 sm:p-6 sm:pb-4 rounded-[1rem] shadow-md">
|
||||||
|
<div class="text-center bg-[#000029] text-white text-lg font-semibold rounded-lg py-2 mb-4">
|
||||||
|
Descontar saldo
|
||||||
|
</div>
|
||||||
|
<div class="text-center">
|
||||||
|
<div class="flex justify-center mb-4">
|
||||||
|
Saldo actual: $<p class="font-semibold">{{ number_format($saldo_actual) }}</p>
|
||||||
|
</div>
|
||||||
|
<div class="mt-2">
|
||||||
|
Monto a descontar
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<input type="number" min="0" name="monto" wire:model="valor_recargar"
|
||||||
|
placeholder="$100.000" required
|
||||||
|
class="border-2 w-1/2 md:w-auto mb-2 border-neutral-200 rounded-[0.8rem] shadow apperance-none focus:border-neutral-300 focus:ring-0 py-2 px-3 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
|
|
||||||
|
<div class="flex text-sm justify-center">Tu valor total seria: $<p>
|
||||||
|
{{ $saldo_actual - $valor_recargar }}
|
||||||
|
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div
|
||||||
|
class="bg-white px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse sm:justify-evenly gap-5 mt-4">
|
||||||
|
<span>
|
||||||
|
<button wire:click="descontar" type="button"
|
||||||
|
class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 sm:mb-[0] mb-2 text-white bg-[#B221FD] hover:bg-[#7a02b8] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Guardar</button>
|
||||||
|
</span>
|
||||||
|
<span>
|
||||||
|
<button wire:click="limpiarSaldo" x-on:click="modalSaldo=false" type="button"
|
||||||
|
class="inline-flex justify-center w-full rounded-md border border-transparent px-4 py-2 text-white bg-[#585858] hover:bg-[#3a3a3a] focus:shadow-outline-green ease-in-out sm-text-sm sm-leading-5">Cerrar</button>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -559,7 +697,8 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
|
|
||||||
<div class="w-[8rem]">
|
<div class="w-[8rem]">
|
||||||
<label class="text-gray-500 text-sm">Precio</label>
|
<label class="text-gray-500 text-sm">Precio</label>
|
||||||
<input type="number" id="precio_modTarifas" wire:model="precio_modTarifas" min="0"
|
<input type="number" id="precio_modTarifas" wire:model="precio_modTarifas"
|
||||||
|
min="0"
|
||||||
class="w-full border-2 border-neutral-200 rounded-[0.8rem] focus:ring-0 shadow apperance-none focus:border-neutral-300 py-2 pl-2 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
class="w-full border-2 border-neutral-200 rounded-[0.8rem] focus:ring-0 shadow apperance-none focus:border-neutral-300 py-2 pl-2 text-gray-700 leading-tight focus:outline-none focus:shadow-outline">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -587,7 +726,24 @@ modTarifas: @entangle('modTarifas'),
|
|||||||
<td class="pl-[1rem]">{{ $tarifa->rol->nombre ?? '' }}</td>
|
<td class="pl-[1rem]">{{ $tarifa->rol->nombre ?? '' }}</td>
|
||||||
<td class="pl-[1rem]">{{ $tarifa->precio ?? '' }}</td>
|
<td class="pl-[1rem]">{{ $tarifa->precio ?? '' }}</td>
|
||||||
<td class="pl-[1rem]">
|
<td class="pl-[1rem]">
|
||||||
<svg wire:click="eliminarModTarifa({{ $tarifa->id ?? ''}})" xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.com/svgjs" class="w-6 cursor-pointer" x="0" y="0" viewBox="0 0 24 24" style="enable-background:new 0 0 512 512" xml:space="preserve" class=""><g><g id="Flat_Color" data-name="Flat Color"><circle cx="12" cy="12" fill="#e63946" r="10" data-original="#e63946" class=""></circle><path d="m13.41 12 2.3-2.29a1 1 0 0 0 -1.42-1.42l-2.29 2.3-2.29-2.3a1 1 0 0 0 -1.42 1.42l2.3 2.29-2.3 2.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l2.29-2.3 2.29 2.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z" fill="#edebea" data-original="#edebea" class=""></path></g></g>
|
<svg wire:click="eliminarModTarifa({{ $tarifa->id ?? '' }})"
|
||||||
|
xmlns="http://www.w3.org/2000/svg" version="1.1"
|
||||||
|
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
|
xmlns:svgjs="http://svgjs.com/svgjs" class="w-6 cursor-pointer"
|
||||||
|
x="0" y="0" viewBox="0 0 24 24"
|
||||||
|
style="enable-background:new 0 0 512 512" xml:space="preserve"
|
||||||
|
class="">
|
||||||
|
<g>
|
||||||
|
<g id="Flat_Color" data-name="Flat Color">
|
||||||
|
<circle cx="12" cy="12" fill="#e63946"
|
||||||
|
r="10" data-original="#e63946"
|
||||||
|
class=""></circle>
|
||||||
|
<path
|
||||||
|
d="m13.41 12 2.3-2.29a1 1 0 0 0 -1.42-1.42l-2.29 2.3-2.29-2.3a1 1 0 0 0 -1.42 1.42l2.3 2.29-2.3 2.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l2.29-2.3 2.29 2.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z"
|
||||||
|
fill="#edebea" data-original="#edebea"
|
||||||
|
class=""></path>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|||||||
|
After Width: | Height: | Size: 6.6 KiB |
|
After Width: | Height: | Size: 5.3 KiB |
|
After Width: | Height: | Size: 13 KiB |
|
After Width: | Height: | Size: 6.6 KiB |
|
After Width: | Height: | Size: 175 KiB |
|
After Width: | Height: | Size: 5.3 KiB |
|
After Width: | Height: | Size: 46 KiB |