This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
declare(strict_types=1); | |
class PasswordCheckTrait | |
{ | |
public static function check(string $password) | |
{ | |
$uppercase = preg_match('@[A-Z]@', $password); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Cuando hacemos una peticion por un cliente de peticiones http(Postman) si no indicamos en la cabecera el tipo de peticion o sea: | |
- Accept: application/json | |
No debera salir en nuestro cliente un error con formato HTML con error 404.Esto se debe a que nuestra API est谩 esperando una petici贸n de | |
tipo json. | |
Solucion | |
public function register() | |
{ | |
$this->renderable(function (NotFoundHttpException $e,$request) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Exception in thread "main" java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema | |
at com.android.repository.api.SchemaModule$SchemaModuleVersion.<init>(SchemaModule.java:156) | |
at com.android.repository.api.SchemaModule.<init>(SchemaModule.java:75) | |
at com.android.sdklib.repository.AndroidSdkHandler.<clinit>(AndroidSdkHandler.java:81) | |
at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:73) | |
at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:48) | |
Caused by: java.lang.ClassNotFoundException: javax.xml.bind.annotation.XmlSchema | |
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581) | |
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178) | |
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$query = People::where(DB::raw("CONCAT(first_name, ' ', last_name)"), 'like', "%" . $search . "%") | |
->orWhere('phone', 'like', '%' . $search . '%') | |
->orWhere('mobile_phone', 'like', '%' . $search . '%') | |
->orWhere('customer_type_id', 'like', '%' . $search . '%')->paginate(10); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Put this into filesystem.php | |
'spaces' => [ | |
'driver' => 's3', | |
'key' => env('DO_SPACES_KEY'), | |
'secret' => env('DO_SPACES_SECRET'), | |
'endpoint' => env('DO_SPACES_ENDPOINT'), | |
'region' => env('DO_SPACES_REGION'), | |
'bucket' => env('DO_SPACES_BUCKET'), | |
'url' => env('DO_URL'), | |
'visibility' => 'public' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { OpenStreetMapProvider } from 'leaflet-geosearch'; | |
const provider = new OpenStreetMapProvider(); | |
document.addEventListener('DOMContentLoaded', () => { | |
if(document.querySelector('#mapa')) { | |
// Recoje los datos de inputo escondidos o setea por default valores (Punto Cero Capitolio) | |
const lat = document.querySelector('#lat').value === '' ? 23.137101780277284 : document.querySelector('#lat').value; | |
const lng = document.querySelector('#lng').value === '' ? -82.35785485661802 : document.querySelector('#lng').value; |