show regno on options
All checks were successful
Build and test backend / Build-backend (push) Successful in 1m23s
deploy to production / deploy-frontend (push) Successful in 33s
deploy to production / deploy-backend (push) Successful in 18s
Build and test FrontEnd / Build-frontend (push) Successful in 30s

This commit is contained in:
Debucquoy Anthony 2024-04-22 09:22:19 +02:00
parent 060526c20d
commit 2cffe28720
Signed by: tonitch
GPG Key ID: A78D6421F083D42E

View File

@ -2,7 +2,7 @@
import { toast } from 'vue3-toastify'; import { toast } from 'vue3-toastify';
import { ref } from 'vue' import { ref } from 'vue'
import i18n, { setLang } from './i18n.js' import i18n, { setLang } from './i18n.js'
import { isLogged } from '@/rest/Users.js' import { isLogged, getSelf } from '@/rest/Users.js'
import { notifications, fetchNotifications, archiveNotification } from '@/rest/notifications.js' import { notifications, fetchNotifications, archiveNotification } from '@/rest/notifications.js'
import { appList, currentView } from '@/rest/apps.js' import { appList, currentView } from '@/rest/apps.js'
@ -14,9 +14,11 @@ window.onhashchange = function() {
currentURL = window.location.hash; currentURL = window.location.hash;
} }
const Logged = ref(isLogged()); const Logged = ref(isLogged());
const user = ref();
if(Logged.value){ if(Logged.value){
fetchNotifications(); fetchNotifications();
getSelf().then(e => user.value = e);
} }
window.addEventListener('hashchange', () => { window.addEventListener('hashchange', () => {
@ -75,6 +77,7 @@ window.addEventListener('hashchange', () => {
{{i18n("app.manage.profile")}} {{i18n("app.manage.profile")}}
</a> </a>
</div> </div>
<span v-if=Logged>RegNo - {{ user.regNo }}</span>
</div> </div>
</a></li> </a></li>
</ul> </ul>
@ -133,10 +136,12 @@ window.addEventListener('hashchange', () => {
.dropdown { .dropdown {
color:black;
margin-top:55px; margin-top:55px;
width:160px; width:160px;
display: inline-block; display: inline-block;
height:110px; /* height:110px; */
text-align: center;
font-size: 13px; font-size: 13px;
position: absolute; position: absolute;
z-index: 1; z-index: 1;