diff --git a/src/assets/logo.svg b/src/assets/salix.svg similarity index 100% rename from src/assets/logo.svg rename to src/assets/salix.svg diff --git a/src/assets/salix_dark.svg b/src/assets/salix_dark.svg new file mode 100644 index 000000000..10de3af4f --- /dev/null +++ b/src/assets/salix_dark.svg @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/assets/logo_icon.svg b/src/assets/salix_icon.svg similarity index 100% rename from src/assets/logo_icon.svg rename to src/assets/salix_icon.svg diff --git a/src/assets/vn.svg b/src/assets/vn.svg new file mode 100644 index 000000000..23b6df49c --- /dev/null +++ b/src/assets/vn.svg @@ -0,0 +1,158 @@ + +image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/assets/vn_dark.svg b/src/assets/vn_dark.svg new file mode 100644 index 000000000..4d53b7b39 --- /dev/null +++ b/src/assets/vn_dark.svg @@ -0,0 +1,161 @@ + +image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/assets/vn_icon.svg b/src/assets/vn_icon.svg new file mode 100644 index 000000000..738c8157c --- /dev/null +++ b/src/assets/vn_icon.svg @@ -0,0 +1,72 @@ + + + +image/svg+xml \ No newline at end of file diff --git a/src/components/FormModel.vue b/src/components/FormModel.vue index 540c37d01..e8a9e4c17 100644 --- a/src/components/FormModel.vue +++ b/src/components/FormModel.vue @@ -122,9 +122,24 @@ watch(formUrl, async () => { {{ t('globals.changesToSave') }} - - - +
+ + + + + +
@@ -156,3 +171,12 @@ watch(formUrl, async () => { color="primary" /> + diff --git a/src/components/NavBar.vue b/src/components/NavBar.vue index 7d09b09b8..778f6bfb9 100644 --- a/src/components/NavBar.vue +++ b/src/components/NavBar.vue @@ -7,6 +7,7 @@ import { useStateStore } from 'stores/useStateStore'; import { useQuasar } from 'quasar'; import PinnedModules from './PinnedModules.vue'; import UserPanel from 'components/UserPanel.vue'; +import VnBreadcrumbs from './common/VnBreadcrumbs.vue'; const { t } = useI18n(); const session = useSession(); @@ -47,7 +48,7 @@ const pinnedModulesRef = ref(); > @@ -57,10 +58,7 @@ const pinnedModulesRef = ref(); - - {{ appName }} - - + @@ -112,6 +110,7 @@ const pinnedModulesRef = ref();
+ diff --git a/src/components/common/VnBreadcrumbs.vue b/src/components/common/VnBreadcrumbs.vue new file mode 100644 index 000000000..792671e21 --- /dev/null +++ b/src/components/common/VnBreadcrumbs.vue @@ -0,0 +1,82 @@ + + + diff --git a/src/components/ui/VnFilterPanel.vue b/src/components/ui/VnFilterPanel.vue index 68b3a7676..d78c3ba13 100644 --- a/src/components/ui/VnFilterPanel.vue +++ b/src/components/ui/VnFilterPanel.vue @@ -20,6 +20,10 @@ const props = defineProps({ required: false, default: null, }, + showAll: { + type: Boolean, + default: true, + }, }); const emit = defineEmits(['refresh', 'clear']); @@ -29,31 +33,34 @@ const store = arrayData.store; const userParams = ref({}); onMounted(() => { - if (props.params) userParams.value = props.params; - const params = store.userParams; - if (Object.keys(params).length > 0) { - userParams.value = Object.assign({}, params); + if (props.params) userParams.value = JSON.parse(JSON.stringify(props.params)); + if (Object.keys(store.userParams).length > 0) { + userParams.value = JSON.parse(JSON.stringify(store.userParams)); } }); const isLoading = ref(false); async function search() { - const params = userParams.value; - for (const param in params) { - if (params[param] === '' || params[param] === null) { + for (const param in userParams.value) { + if (userParams.value[param] === '' || userParams.value[param] === null) { delete userParams.value[param]; delete store.userParams[param]; } } - + const params = { ...userParams.value }; isLoading.value = true; await arrayData.addFilter({ params }); + if (!props.showAll && !Object.values(params).length) store.data = []; + isLoading.value = false; } async function reload() { isLoading.value = true; + const params = Object.values(userParams.value).filter((param) => param); + await arrayData.fetch({ append: false }); + if (!props.showAll && !params.length) store.data = []; isLoading.value = false; emit('refresh'); } @@ -62,6 +69,7 @@ async function clearFilters() { userParams.value = {}; isLoading.value = true; await arrayData.applyFilter({ params: {} }); + if (!props.showAll) store.data = []; isLoading.value = false; emit('clear'); diff --git a/src/components/ui/VnLogo.vue b/src/components/ui/VnLogo.vue new file mode 100644 index 000000000..3b955289d --- /dev/null +++ b/src/components/ui/VnLogo.vue @@ -0,0 +1,24 @@ + + + diff --git a/src/components/ui/VnRow.vue b/src/components/ui/VnRow.vue new file mode 100644 index 000000000..c3c951528 --- /dev/null +++ b/src/components/ui/VnRow.vue @@ -0,0 +1,12 @@ + + diff --git a/src/components/ui/VnSearchbar.vue b/src/components/ui/VnSearchbar.vue index af6999b5b..693d6fce2 100644 --- a/src/components/ui/VnSearchbar.vue +++ b/src/components/ui/VnSearchbar.vue @@ -105,7 +105,11 @@ async function search() { class="cursor-pointer" /> - + {{ props.info }} diff --git a/src/composables/getUrl.js b/src/composables/getUrl.js index e020d7f18..f2bd9ddb9 100644 --- a/src/composables/getUrl.js +++ b/src/composables/getUrl.js @@ -1,14 +1,11 @@ import axios from 'axios'; export async function getUrl(route, appName = 'salix') { - let url; const filter = { where: { and: [{ appName: appName }, { environment: process.env.NODE_ENV }] }, }; - await axios.get('Urls/findOne', { params: { filter } }).then((res) => { - url = res.data.url + route; - }); - - return url; + const { data } = await axios.get('Urls/findOne', { params: { filter } }); + const url = data.url; + return route ? url + route : url; } diff --git a/src/composables/useArrayData.js b/src/composables/useArrayData.js index 4535cde0f..9aff0eaa8 100644 --- a/src/composables/useArrayData.js +++ b/src/composables/useArrayData.js @@ -136,7 +136,7 @@ export function useArrayData(key, userOptions) { } async function refresh() { - await fetch({ append: false }); + if (Object.values(store.userParams).length) await fetch({ append: false }); } function updateStateParams() { diff --git a/src/composables/useCamelCase.js b/src/composables/useCamelCase.js new file mode 100644 index 000000000..5285b022a --- /dev/null +++ b/src/composables/useCamelCase.js @@ -0,0 +1,3 @@ +export function useCamelCase(value) { + return value.replace(/[-_](.)/g, (_, char) => char.toUpperCase()); +} diff --git a/src/css/quasar.variables.scss b/src/css/quasar.variables.scss index 808bf3468..6a3700561 100644 --- a/src/css/quasar.variables.scss +++ b/src/css/quasar.variables.scss @@ -21,6 +21,7 @@ $positive: #21ba45; $negative: #c10015; $info: #31ccec; $warning: #f2c037; +$vnColor: #8ebb27; // Pendiente de cuadrar con la base de datos $success: $positive; diff --git a/src/i18n/en/index.js b/src/i18n/en/index.js index eae06dbf0..792bd3965 100644 --- a/src/i18n/en/index.js +++ b/src/i18n/en/index.js @@ -77,6 +77,11 @@ export default { twoFactor: 'Two-Factor', }, }, + verifyEmail: { + pageTitles: { + verifyEmail: 'Email verification', + }, + }, dashboard: { pageTitles: { dashboard: 'Dashboard', diff --git a/src/i18n/es/index.js b/src/i18n/es/index.js index dc1ace47e..4ce8c23d6 100644 --- a/src/i18n/es/index.js +++ b/src/i18n/es/index.js @@ -77,6 +77,11 @@ export default { twoFactor: 'Doble factor', }, }, + verifyEmail: { + pageTitles: { + verifyEmail: 'Verificación de correo', + }, + }, dashboard: { pageTitles: { dashboard: 'Tablón', diff --git a/src/layouts/OutLayout.vue b/src/layouts/OutLayout.vue index 6ea14622f..f21e6e568 100644 --- a/src/layouts/OutLayout.vue +++ b/src/layouts/OutLayout.vue @@ -80,7 +80,7 @@ const langs = ['en', 'es'];
- +
@@ -97,15 +97,4 @@ const langs = ['en', 'es']; min-height: inherit; flex-direction: column; } - -.formCard { - max-width: 350px; - min-width: 300px; -} - -@media (max-width: $breakpoint-xs-max) { - .formCard { - min-width: 100%; - } -} diff --git a/src/pages/Claim/Card/ClaimBasicData.vue b/src/pages/Claim/Card/ClaimBasicData.vue index ddf669dd0..94e447e13 100644 --- a/src/pages/Claim/Card/ClaimBasicData.vue +++ b/src/pages/Claim/Card/ClaimBasicData.vue @@ -6,6 +6,7 @@ import { useI18n } from 'vue-i18n'; import { useSession } from 'src/composables/useSession'; import FetchData from 'components/FetchData.vue'; import FormModel from 'components/FormModel.vue'; +import VnRow from 'components/ui/VnRow.vue'; const route = useRoute(); const { t } = useI18n(); @@ -90,138 +91,119 @@ const statesFilter = { auto-load /> - -
- - - - - -
+ + + - - diff --git a/src/pages/Customer/Card/CustomerBasicData.vue b/src/pages/Customer/Card/CustomerBasicData.vue index ffd3c3476..08c661f0b 100644 --- a/src/pages/Customer/Card/CustomerBasicData.vue +++ b/src/pages/Customer/Card/CustomerBasicData.vue @@ -6,6 +6,7 @@ import { useI18n } from 'vue-i18n'; import { useSession } from 'src/composables/useSession'; import FetchData from 'components/FetchData.vue'; import FormModel from 'components/FormModel.vue'; +import VnRow from 'components/ui/VnRow.vue'; const route = useRoute(); const { t } = useI18n(); @@ -58,121 +59,109 @@ const filterOptions = { @on-fetch="(data) => (businessTypes = data)" auto-load /> -
- - - - - -
- - + + + + diff --git a/src/pages/Customer/CustomerPayments.vue b/src/pages/Customer/CustomerPayments.vue index 608aca2af..24e5efa39 100644 --- a/src/pages/Customer/CustomerPayments.vue +++ b/src/pages/Customer/CustomerPayments.vue @@ -110,12 +110,18 @@ function stateColor(row) {
- + - +
{{ t('Web Payments') }} @@ -138,7 +144,7 @@ function stateColor(row) { order="created DESC" :limit="20" :offset="50" - auto-load + :auto-load="!!$route?.query.params" >