fix: styles and i18n
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
parent
f305cee3ce
commit
17924dfeb3
|
@ -42,15 +42,12 @@ const onSynchronizeRoles = async () => {
|
||||||
>
|
>
|
||||||
<template #moreActions>
|
<template #moreActions>
|
||||||
<QBtn
|
<QBtn
|
||||||
round
|
style="margin-left: 0"
|
||||||
flat
|
|
||||||
color="primary"
|
color="primary"
|
||||||
:label="t('accounts.syncAll')"
|
:label="t('accounts.syncAll')"
|
||||||
@click="onSynchronizeAll()"
|
@click="onSynchronizeAll()"
|
||||||
/>
|
/>
|
||||||
<QBtn
|
<QBtn
|
||||||
round
|
|
||||||
flat
|
|
||||||
color="primary"
|
color="primary"
|
||||||
:label="t('accounts.syncRoles')"
|
:label="t('accounts.syncRoles')"
|
||||||
@click="onSynchronizeRoles()"
|
@click="onSynchronizeRoles()"
|
||||||
|
|
|
@ -38,7 +38,7 @@ const hasData = computed({
|
||||||
|
|
||||||
const initialDataLoaded = ref(false);
|
const initialDataLoaded = ref(false);
|
||||||
const urlCreate = ref(null);
|
const urlCreate = ref(null);
|
||||||
const urlUpdate = ref(null);
|
const urlUpdate = ref(`LdapConfigs/${1}`);
|
||||||
const customFn = ref(null);
|
const customFn = ref(null);
|
||||||
|
|
||||||
const onTestConection = async () => {
|
const onTestConection = async () => {
|
||||||
|
@ -53,7 +53,7 @@ const onTestConection = async () => {
|
||||||
const getInitialLdapConfig = async () => {
|
const getInitialLdapConfig = async () => {
|
||||||
try {
|
try {
|
||||||
initialDataLoaded.value = false;
|
initialDataLoaded.value = false;
|
||||||
const { data } = await axios.get(`LdapConfigs/${1}`);
|
const { data } = await axios.get(urlUpdate.value);
|
||||||
initialData.value = data;
|
initialData.value = data;
|
||||||
hasData.value = true;
|
hasData.value = true;
|
||||||
return data;
|
return data;
|
||||||
|
@ -62,10 +62,8 @@ const getInitialLdapConfig = async () => {
|
||||||
console.error('Error fetching initial LDAP config', error);
|
console.error('Error fetching initial LDAP config', error);
|
||||||
return null;
|
return null;
|
||||||
} finally {
|
} finally {
|
||||||
if (hasData.value) {
|
if (hasData.value) urlCreate.value = null;
|
||||||
urlUpdate.value = `LdapConfigs/${1}`;
|
else {
|
||||||
urlCreate.value = null;
|
|
||||||
} else {
|
|
||||||
urlUpdate.value = null;
|
urlUpdate.value = null;
|
||||||
urlCreate.value = `LdapConfigs`;
|
urlCreate.value = `LdapConfigs`;
|
||||||
}
|
}
|
||||||
|
@ -75,7 +73,7 @@ const getInitialLdapConfig = async () => {
|
||||||
|
|
||||||
const deleteMailForward = async () => {
|
const deleteMailForward = async () => {
|
||||||
try {
|
try {
|
||||||
await axios.delete(`LdapConfigs/${1}`);
|
await axios.delete(urlUpdate.value);
|
||||||
initialData.value = { ...DEFAULT_DATA };
|
initialData.value = { ...DEFAULT_DATA };
|
||||||
hasData.value = false;
|
hasData.value = false;
|
||||||
notify(t('globals.dataSaved'), 'positive');
|
notify(t('globals.dataSaved'), 'positive');
|
||||||
|
@ -89,7 +87,7 @@ onMounted(async () => await getInitialLdapConfig());
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<QPage>
|
<QPage>
|
||||||
<VnSubToolbar></VnSubToolbar>
|
<VnSubToolbar />
|
||||||
<FormModel
|
<FormModel
|
||||||
:key="initialDataLoaded"
|
:key="initialDataLoaded"
|
||||||
model="AccountLdap"
|
model="AccountLdap"
|
||||||
|
|
|
@ -40,7 +40,7 @@ const hasData = computed({
|
||||||
|
|
||||||
const initialDataLoaded = ref(false);
|
const initialDataLoaded = ref(false);
|
||||||
const urlCreate = ref(null);
|
const urlCreate = ref(null);
|
||||||
const urlUpdate = ref(null);
|
const urlUpdate = ref(`SambaConfigs/${1}`);
|
||||||
const customFn = ref(null);
|
const customFn = ref(null);
|
||||||
|
|
||||||
const onTestConection = async () => {
|
const onTestConection = async () => {
|
||||||
|
@ -55,7 +55,7 @@ const onTestConection = async () => {
|
||||||
const getInitialLdapConfig = async () => {
|
const getInitialLdapConfig = async () => {
|
||||||
try {
|
try {
|
||||||
initialDataLoaded.value = false;
|
initialDataLoaded.value = false;
|
||||||
const { data } = await axios.get(`SambaConfigs/${1}`);
|
const { data } = await axios.get(urlUpdate.value);
|
||||||
initialData.value = data;
|
initialData.value = data;
|
||||||
hasData.value = true;
|
hasData.value = true;
|
||||||
return data;
|
return data;
|
||||||
|
@ -64,10 +64,8 @@ const getInitialLdapConfig = async () => {
|
||||||
console.error('Error fetching initial LDAP config', error);
|
console.error('Error fetching initial LDAP config', error);
|
||||||
return null;
|
return null;
|
||||||
} finally {
|
} finally {
|
||||||
if (hasData.value) {
|
if (hasData.value) urlCreate.value = null;
|
||||||
urlUpdate.value = `SambaConfigs/${1}`;
|
else {
|
||||||
urlCreate.value = null;
|
|
||||||
} else {
|
|
||||||
urlUpdate.value = null;
|
urlUpdate.value = null;
|
||||||
urlCreate.value = `SambaConfigs`;
|
urlCreate.value = `SambaConfigs`;
|
||||||
}
|
}
|
||||||
|
@ -77,7 +75,7 @@ const getInitialLdapConfig = async () => {
|
||||||
|
|
||||||
const deleteMailForward = async () => {
|
const deleteMailForward = async () => {
|
||||||
try {
|
try {
|
||||||
await axios.delete(`SambaConfigs/${1}`);
|
await axios.delete(urlUpdate.value);
|
||||||
initialData.value = { ...DEFAULT_DATA };
|
initialData.value = { ...DEFAULT_DATA };
|
||||||
hasData.value = false;
|
hasData.value = false;
|
||||||
notify(t('globals.dataSaved'), 'positive');
|
notify(t('globals.dataSaved'), 'positive');
|
||||||
|
@ -91,7 +89,7 @@ onMounted(async () => await getInitialLdapConfig());
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<QPage>
|
<QPage>
|
||||||
<VnSubToolbar></VnSubToolbar>
|
<VnSubToolbar />
|
||||||
<FormModel
|
<FormModel
|
||||||
ref="formModel"
|
ref="formModel"
|
||||||
:key="initialDataLoaded"
|
:key="initialDataLoaded"
|
||||||
|
|
|
@ -54,6 +54,7 @@ ldap:
|
||||||
groupDN: Group DN
|
groupDN: Group DN
|
||||||
testConnection: Test connection
|
testConnection: Test connection
|
||||||
success: LDAP connection established!
|
success: LDAP connection established!
|
||||||
|
password: Password
|
||||||
samba:
|
samba:
|
||||||
enableSync: Enable synchronization
|
enableSync: Enable synchronization
|
||||||
domainController: Domain controller
|
domainController: Domain controller
|
||||||
|
|
|
@ -57,6 +57,7 @@ role:
|
||||||
name: Nombre
|
name: Nombre
|
||||||
description: Descripción
|
description: Descripción
|
||||||
ldap:
|
ldap:
|
||||||
|
password: Contraseña
|
||||||
enableSync: Habilitar sincronización
|
enableSync: Habilitar sincronización
|
||||||
server: Servidor
|
server: Servidor
|
||||||
rdn: RDN
|
rdn: RDN
|
||||||
|
@ -73,7 +74,7 @@ samba:
|
||||||
userAD: Usuario AD
|
userAD: Usuario AD
|
||||||
passwordAD: Contraseña AD
|
passwordAD: Contraseña AD
|
||||||
domainPart: DN usuarios (sin la parte del dominio)
|
domainPart: DN usuarios (sin la parte del dominio)
|
||||||
Verify certificate: Verificar certificado
|
verifyCertificate: Verificar certificado
|
||||||
testConnection: Probar conexión
|
testConnection: Probar conexión
|
||||||
success: ¡Conexión con Samba establecida!
|
success: ¡Conexión con Samba establecida!
|
||||||
accounts:
|
accounts:
|
||||||
|
|
Loading…
Reference in New Issue