How to test email message from notifications in Laravel (MailMessage).
<?php
namespace App\Notifications;
Sanctum loguje zawsze guardy z ustawień 'guard' => ['web', 'admin'] trzeba sprawdzać który user jest zalogowany (sanctum guard nie działają podwójne logowania, zawsze brany jest pierwszy guard) można to zmienić dodając auth:web,sanctum i auth:admin,sanctum middleware.
<?php
// Działa to z tokenem i guardami, nawet z podwójnie zalogowanymi userami SPA z testów!
// Użyj web guard a jak nie to sanctum guard
<?php | |
namespace App\Http\Middleware\Api; | |
use Closure; | |
use Illuminate\Http\Request; | |
use Laravel\Sanctum\PersonalAccessToken; | |
/** | |
* Sanctum expired token middleware. |
<script setup> | |
import { ref } from 'vue'; | |
let selector_slot = ref('accept'); | |
</script> | |
<template> | |
<SelectorSlot v-model="selector_slot" name="selector_slot"> | |
<template v-slot:default="{ onClick }"> | |
<SelectorSlotButton v-model="selector_slot" value="accept" @click="onClick('accept')">✔️ Accept</SelectorSlotButton> | |
<SelectorSlotButton v-model="selector_slot" value="reject" @click="onClick('reject')">🚩 Reject</SelectorSlotButton> |
<script setup> | |
import { onBeforeMount, ref, watch } from 'vue'; | |
import { useI18n } from 'vue-i18n'; | |
let { locale } = useI18n({ useScope: 'global' }); | |
let list = ref(null); | |
onBeforeMount(async () => { | |
await load(); | |
}); |
<script setup> | |
// See: https://vue-i18n.intlify.dev/guide/advanced/composition | |
import { computed } from 'vue' | |
import { useI18n } from 'vue-i18n' | |
const { t } = useI18n({ | |
// useScope: 'global', // Overwrite global | |
locale: 'en', | |
messages: { | |
en: { |