0
0
Fork 0

Compare commits

..

108 Commits

Author SHA1 Message Date
Alex Moreno fd72f4dd45 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix-front into dev 2024-10-24 14:45:34 +02:00
Alex Moreno 9daed096db Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix-front into test 2024-10-24 14:45:23 +02:00
Alex Moreno e86afd57a0 Merge pull request 'feat: refs #8039 canceledError not notify' (!850) from 8039-canceledError_not_notify into dev
Reviewed-on: verdnatura/salix-front#850
Reviewed-by: Jorge Penadés <jorgep@verdnatura.es>
2024-10-24 12:44:19 +00:00
Alex Moreno d529676ab5 Merge pull request 'fix: refs #7652 datakey' (!868) from 7652-hotfix-descriptorKey into master
Reviewed-on: verdnatura/salix-front#868
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-24 12:36:39 +00:00
Jorge Penadés 4828e32c9e fix: refs #7652 datakey 2024-10-24 14:26:16 +02:00
Jorge Penadés e26692fa51 Merge pull request '#7524 hotfix-vnProgressModal' (!866) from 7524-hotfix-vnProgressModal into master
Reviewed-on: verdnatura/salix-front#866
Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
2024-10-24 12:10:26 +00:00
Jorge Penadés 823c354ef1 fix: refs #7524 vnProgressModal 2024-10-24 13:27:08 +02:00
Jorge Penadés f52b4c9a59 fix: refs #7524 vnProgressModal 2024-10-24 13:24:45 +02:00
Alex Moreno cb2780fe6f Merge pull request 'refactor: refs #7524 use VnTable' (!861) from 7524-hotfix-useVnTable into master
Reviewed-on: verdnatura/salix-front#861
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-24 10:31:44 +00:00
Jorge Penadés c9cfb2b1cf fix: refs #7524 changes 2024-10-24 12:29:46 +02:00
Alex Moreno 48fdc9e624 Merge pull request '#7524 warmfix-useVnTable' (!862) from 7524-warmfix-useVnTable into test
Reviewed-on: verdnatura/salix-front#862
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-24 09:45:54 +00:00
Jorge Penadés f1350dece5 fix: refs #7524 changes 2024-10-24 11:43:29 +02:00
Jorge Penadés 2779e7ac8d Merge branch 'test' of https: refs #7524//gitea.verdnatura.es/verdnatura/salix-front into 7524-warmfix-useVnTable 2024-10-24 10:29:55 +02:00
Jorge Penadés d918b76010 chore: refs #7524 drop useless code 2024-10-24 10:24:28 +02:00
Jorge Penadés 6f57d9e490 refactor: refs #7524 use VnTable 2024-10-24 10:21:25 +02:00
Alex Moreno de7f55c589 Merge branch 'dev' of https: refs #8039//gitea.verdnatura.es/verdnatura/salix-front into 8039-canceledError_not_notify 2024-10-24 07:56:00 +02:00
Alex Moreno 32b4636706 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix-front into dev 2024-10-24 07:49:10 +02:00
Alex Moreno f26976b744 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix-front into test 2024-10-24 07:49:01 +02:00
Javi Gallego a0a37a68a0 Merge pull request '#8083 hotfix-insertRecord' (!859) from 8083-hotfix-insertRecord into master
Reviewed-on: verdnatura/salix-front#859
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-23 14:25:00 +00:00
Jorge Penadés 1bfede4a55 fix: refs #8083 drop useless code 2024-10-23 16:13:32 +02:00
Jorge Penadés 4e31566ddd fix: refs #8083 drop useless code 2024-10-23 16:13:04 +02:00
Jorge Penadés 33ee1ea01b fix: refs #8083 drop useless code 2024-10-23 16:11:58 +02:00
Jorge Penadés 126bb3f039 feat: refs #8083 insert 2024-10-23 16:10:14 +02:00
Jorge Penadés 9673f7be1e fix: refs #8083 update rightly 2024-10-23 15:17:06 +02:00
Alex Moreno d1e4017869 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix-front into dev 2024-10-23 13:59:11 +02:00
Alex Moreno 5d4b5ad598 Merge pull request 'fix: refs #8010 footer class' (!857) from 8010-fix_vnTable_footer_class into test
Reviewed-on: verdnatura/salix-front#857
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-10-23 11:58:46 +00:00
Alex Moreno 2420c6dee2 Merge branch 'dev' of https: refs #8039//gitea.verdnatura.es/verdnatura/salix-front into 8039-canceledError_not_notify 2024-10-23 13:14:30 +02:00
Alex Moreno 0528474250 chore: refs #8010 kebab-case 2024-10-23 13:13:00 +02:00
Alex Moreno e7acdfd4f7 fix: refs #8010 footer class 2024-10-23 10:48:30 +02:00
Javi Gallego 3cbd294168 Merge pull request '#7943 -permisosWorker' (!855) from 7349-permisosWorker into dev
Reviewed-on: verdnatura/salix-front#855
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-23 05:52:48 +00:00
Javi Gallego 1bf1844c8f fix: refs #7349 dependencia no usada 2024-10-23 07:46:52 +02:00
Javi Gallego ae56c06628 feat: refs #7349 usa back con permisos 2024-10-23 07:45:00 +02:00
Alex Moreno 735ee09ef8 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix-front into test 2024-10-22 15:08:20 +02:00
Alex Moreno aaf749db6c Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix-front into test 2024-10-22 15:08:11 +02:00
Alex Moreno 81a55a9e7a chore: test gitea 2024-10-22 14:55:47 +02:00
Jorge Penadés 41509c60dd Merge pull request '#8083 add change state btn' (!854) from 8083-hotfix-changeState into master
Reviewed-on: verdnatura/salix-front#854
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-22 12:47:58 +00:00
Jorge Penadés 033d6bddbe fix: refs #8083 move expeditions 2024-10-22 14:43:43 +02:00
Jorge Penadés da4c1e9c12 fix: refs #8083 add order 2024-10-22 14:36:30 +02:00
Jorge Penadés 9f3c834ce4 Merge branch 'master' of https: refs #8083//gitea.verdnatura.es/verdnatura/salix-front into 8083-hotfix-changeState 2024-10-22 14:24:41 +02:00
Jorge Penadés b1a511ff6f fix: refs #8083 delete btn & redirect 2024-10-22 14:21:03 +02:00
Alex Moreno f9392464e5 Merge branch '8039-canceledError_not_notify' of https://gitea.verdnatura.es/verdnatura/salix-front into 8039-canceledError_not_notify 2024-10-22 14:07:28 +02:00
Alex Moreno ee31bc8262 chore: refs #8039 not required 2024-10-22 14:07:27 +02:00
Alex Moreno 0d3e8bb5d2 Merge branch 'dev' into 8039-canceledError_not_notify 2024-10-22 12:06:41 +00:00
Alex Moreno dd2dc86eea fix: refs #8039 o not handle unnecessary errors 2024-10-22 14:05:15 +02:00
Javi Gallego 93025007f1 Merge pull request '#7524 add my team filter' (!849) from 7524-hotfix-myTeamFilter into master
Reviewed-on: verdnatura/salix-front#849
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-22 12:00:03 +00:00
Alex Moreno cd00a3c67f test: refs #8039 fix WorkerNotification e2e 2024-10-22 13:55:35 +02:00
Alex Moreno 0c9c01b6e9 test: refs #8039 fix ZoneWarehouse e2e 2024-10-22 13:53:01 +02:00
Alex Moreno 2d81cffb33 feat: refs #8039 show duplicate request in local 2024-10-22 13:34:20 +02:00
Jorge Penadés f751408de2 feat: refs #8083 add change state btn 2024-10-22 13:22:43 +02:00
Alex Moreno a732ec05fb test: refs #8039 add hasNotify and, refactor: agencyWorkCenter test 2024-10-22 13:21:16 +02:00
Alex Moreno 9db1c4f721 fix: refs #8039 bad tests 2024-10-22 12:29:33 +02:00
Alex Moreno ffd4a402ab Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix-front into 8039-canceledError_not_notify 2024-10-22 12:14:09 +02:00
Carlos Satorres c799d17e19 Merge pull request '8144-devToTest_2444' (!852) from 8144-devToTest_2444 into test
Reviewed-on: verdnatura/salix-front#852
Reviewed-by: Carlos Satorres <carlossa@verdnatura.es>
2024-10-22 08:55:43 +00:00
Alex Moreno 36221121f5 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix-front into dev 2024-10-22 07:43:07 +02:00
Alex Moreno b4d4844100 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix-front into test 2024-10-22 07:42:54 +02:00
Jorge Penadés 0fbd5f45e1 fix: refs #7524 select department 2024-10-21 14:29:29 +02:00
Jon Elias 665e84d338 Merge pull request '#7356: Changes to fix ticket section' (!806) from Fix-TicketsModule into dev
Reviewed-on: verdnatura/salix-front#806
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 11:41:08 +00:00
Jon Elias cd4b17048c Merge branch 'dev' into Fix-TicketsModule 2024-10-21 11:40:02 +00:00
Alex Moreno c69f7af390 test: refs #8039 axios not notify 2024-10-21 13:38:35 +02:00
Alex Moreno 8478d89183 Merge branch '8039-canceledError_not_notify' of https://gitea.verdnatura.es/verdnatura/salix-front into 8039-canceledError_not_notify 2024-10-21 13:33:14 +02:00
Alex Moreno 9780fe596f feat: refs #8039 notify error unify 2024-10-21 13:33:12 +02:00
Alex Moreno 6f79275521 Merge branch 'dev' into 8039-canceledError_not_notify 2024-10-21 11:24:08 +00:00
Alex Moreno 52981953f7 feat(): refs #8039 canceledError not notify 2024-10-21 13:23:45 +02:00
Javier Segarra bc1a082fe1 Merge pull request '#7679 Improve NewPostCodeForm' (!787) from 7679_improve_newPostcode_form into dev
Reviewed-on: verdnatura/salix-front#787
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 11:17:47 +00:00
Javier Segarra e5064e8a37 Merge branch 'dev' into 7679_improve_newPostcode_form 2024-10-21 11:17:01 +00:00
Javier Segarra 76b69a7588 Merge pull request '#6943 - Customer specs' (!822) from 6943_customer_spec into dev
Reviewed-on: verdnatura/salix-front#822
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 11:14:58 +00:00
Javier Segarra cdce4d063c Merge branch 'dev' into 6943_customer_spec 2024-10-21 11:14:14 +00:00
Alex Moreno fbd6633bdb Merge pull request 'fix(TicketBasicData_zone): refs #6233 add acls and fix get zones' (!847) from 6233-fix_ticketBasicData_zone into dev
Reviewed-on: verdnatura/salix-front#847
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-21 10:51:08 +00:00
Alex Moreno 0afcba0b07 Merge branch 'dev' into 6233-fix_ticketBasicData_zone 2024-10-21 10:49:43 +00:00
Alex Moreno d61c690a70 Merge pull request 'feat(navBar): refs #7632 isLoading' (!844) from 7632-axios_isLoading into dev
Reviewed-on: verdnatura/salix-front#844
Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
2024-10-21 10:48:57 +00:00
Jorge Penadés a4358ec0ed chore: refs #7524 refactor order 2024-10-21 12:36:16 +02:00
Jorge Penadés 2b2ccbc6a1 feat: refs #7524 myTeam filter & default params 2024-10-21 12:14:54 +02:00
Alex Moreno d221b8e3c4 chore: refs #7632 change requests 2024-10-21 12:04:20 +02:00
Alex Moreno fcc213f307 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix-front into 7632-axios_isLoading 2024-10-21 12:03:15 +02:00
Jon Elias 2a7bebb0b6 Merge pull request 'Added new filter param and refactored link colors in item request' (!827) from Fix-ItemRequest into dev
Reviewed-on: verdnatura/salix-front#827
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-21 09:35:07 +00:00
Alex Moreno f2147311d3 fix(TicketBasicData_zone): refs #6233 add acls and fix get zones 2024-10-21 08:41:19 +02:00
Alex Moreno 0cc1090739 Merge branch 'dev' into 7632-axios_isLoading 2024-10-21 06:23:05 +00:00
Jon Elias fbfb1c654a Merge branch 'Fix-TicketsModule' of https://gitea.verdnatura.es/verdnatura/salix-front into Fix-TicketsModule 2024-10-18 13:33:29 +02:00
Jon Elias 11092866b8 fix: merge conflicts 2024-10-18 13:33:28 +02:00
Jon Elias 64c0496f7a Merge branch 'dev' into Fix-ItemRequest 2024-10-18 11:20:43 +00:00
Alex Moreno f4caf6aecc test: refs #7632 not use hash word 2024-10-18 11:06:06 +02:00
Alex Moreno 175ebbc343 feat(navBar): refs #7632 isLoading 2024-10-18 11:03:43 +02:00
Jon Elias e47cdff4ca Merge pull request 'Hotfix: InvoiceOut summary' (!829) from Fix-InvoiceOutSummary into master
Reviewed-on: verdnatura/salix-front#829
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-10-17 09:00:06 +00:00
Jon Elias 98a380e026 Merge branch 'master' into Fix-InvoiceOutSummary 2024-10-17 08:58:49 +00:00
Javier Segarra 70ae50a5f1 Merge branch 'dev' into 7679_improve_newPostcode_form 2024-10-16 12:07:26 +00:00
Javier Segarra 4115b1b303 Merge branch 'dev' into 6943_customer_spec 2024-10-16 07:22:43 +00:00
Javier Segarra 6b9dc8f3a6 Merge branch '6943_customer_spec' of https://gitea.verdnatura.es/verdnatura/salix-front into 6943_customer_spec 2024-10-16 09:22:11 +02:00
Javier Segarra 8262406eda perf: refs #6943 Remove handle term 2024-10-16 09:21:57 +02:00
Jon Elias cdce0771c9 Merge branch 'dev' into Fix-TicketsModule 2024-10-15 06:49:32 +00:00
Jon Elias d416a34560 refactor: use docuware in ticket descriptor menu 2024-10-15 08:48:30 +02:00
Javier Segarra 6633e65ee2 Merge branch 'dev' into 6943_customer_spec 2024-10-14 12:35:51 +00:00
Jon Elias 1183d86867 Merge branch 'master' into Fix-InvoiceOutSummary 2024-10-14 11:10:31 +00:00
Jon Elias 0aab17becc fix: fixed customer descriptor proxy 2024-10-14 13:08:16 +02:00
Jon Elias 720042bed9 feat: added new filter param and refactored link colors 2024-10-14 11:30:31 +02:00
Javier Segarra 0fae36c239 Merge branch 'dev' into 7679_improve_newPostcode_form 2024-10-14 09:01:15 +00:00
Javier Segarra b6bce0c2f3 Merge branch 'dev' into 7679_improve_newPostcode_form 2024-10-14 09:27:56 +02:00
Javier Segarra 3d9d08146c test: refs #6943 add customer test 2024-10-11 15:46:30 +02:00
Jon Elias 2dd3e09928 refactor: requested changes 2024-10-10 08:26:16 +02:00
Javier Segarra 801b6585e8 perf: refs #7679 change limit value 2024-10-09 00:44:54 +02:00
Javier Segarra 9edf35fba2 Merge branch 'dev' into 7679_improve_newPostcode_form 2024-10-08 20:27:04 +00:00
Jon Elias 27dca7c35f Merge branch 'Fix-TicketsModule' of https://gitea.verdnatura.es/verdnatura/salix-front into Fix-TicketsModule 2024-10-07 13:29:46 +02:00
Jon Elias afc52f6cea fix: changes in sale and summary 2024-10-07 13:29:43 +02:00
Jon Elias 33d6d529c5 Merge branch 'dev' into Fix-TicketsModule 2024-10-07 07:11:52 +00:00
Jon Elias bd3de77cbd fix: changes in list and filter to fix section 2024-10-07 09:10:20 +02:00
Javier Segarra fef875270e Merge branch 'dev' into 7679_improve_newPostcode_form 2024-10-02 22:08:13 +00:00
Javier Segarra 692c649b8c perf: refs #7679 #7679 improve watch 2024-10-02 09:29:05 +02:00
Javier Segarra 2bd004f52b perf: refs #7679 add sortBy & limit whe retrieve Autonomies 2024-10-01 21:56:12 +02:00
Javier Segarra 1a697aa018 feat: refs #7679 #7679 add sortBy and limit 2024-10-01 15:02:42 +02:00
559 changed files with 3504 additions and 4100 deletions

View File

@ -25,7 +25,7 @@ module.exports = {
// 'plugin:vue/vue3-essential', // Priority A: Essential (Error Prevention)
'plugin:vue/vue3-strongly-recommended', // Priority B: Strongly Recommended (Improving Readability)
// 'plugin:vue/vue3-recommended', // Priority C: Recommended (Minimizing Arbitrary Choices and Cognitive Overhead)
'plugin:cypress/recommended',
// https://github.com/prettier/eslint-config-prettier#installation
// usage with Prettier, provided by 'eslint-config-prettier'.
'prettier',
@ -58,7 +58,7 @@ module.exports = {
rules: {
'prefer-promise-reject-errors': 'off',
'no-unused-vars': 'warn',
'vue/no-multiple-template-root': 'off',
"vue/no-multiple-template-root": "off" ,
// allow debugger during development only
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
},

15
.vscode/launch.json vendored
View File

@ -1,15 +0,0 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "msedge",
"request": "launch",
"name": "Launch Chrome against localhost",
"url": "http://localhost:5000",
"webRoot": "${workspaceFolder}"
}
]
}

View File

@ -1,12 +1,6 @@
const { defineConfig } = require('cypress');
const {
injectQuasarDevServerConfig,
} = require('@quasar/quasar-app-extension-testing-e2e-cypress/cct-dev-server');
module.exports = defineConfig({
env: {
baseUrl: 'http://localhost:9000/',
},
e2e: {
baseUrl: 'http://localhost:9000/',
experimentalStudio: true,
@ -24,29 +18,6 @@ module.exports = defineConfig({
},
setupNodeEvents(on, config) {
// implement node event listeners here
on('after:spec', (results) => {
// `results` is the tests results
console.error('results: ', results);
cy.exec('cd ../salix && gulp docker');
});
},
},
component: {
indexHtmlFile: 'test/cypress/support/component-index.html',
supportFile: 'test/cypress/support/component.js',
specPattern: 'test/cypress/components/**/*.spec.js',
devServer: {
framework: 'quasar',
bundler: 'vite',
},
setupNodeEvents(on, config) {
// implement node event listeners here
on('after:spec', (results) => {
// `results` is the tests results
console.error('results: ', results);
cy.exec('cd ../salix && gulp docker');
});
},
},
});

View File

@ -1,45 +0,0 @@
const fs = require('fs');
const path = require('path');
// Ruta de la carpeta de componentes
// Ruta de la carpeta de pruebas
// ['common', 'ui'].forEach((folder) => {
generateTest('folder');
// });
function generateTest(type) {
const componentsDir = path.join(__dirname, `src/components`);
const testDir = path.join(__dirname, `test/cypress/components`);
// Leer todos los archivos en la carpeta de componentes
fs.readdir(componentsDir, (err, files) => {
if (err) return console.error('Error leyendo la carpeta de componentes:', err);
// Filtrar solo archivos .vue
const vueFiles = files.filter((file) => file.endsWith('.vue'));
vueFiles.forEach((file) => {
const componentName = path.basename(file, '.vue');
const testFileName = `${componentName}.spec.js`;
const testFilePath = path.join(testDir, testFileName);
// Contenido del archivo de prueba
const testFileContent = `
import ${componentName} from 'src/components/${file}';
describe.skip('<${componentName} />', () => {
it('TODO: boilerplate', () => {
// see: https://on.cypress.io/mounting-vue
cy.createWrapper(${componentName});
});
});
`;
// Escribir el archivo de prueba
fs.writeFile(testFilePath, testFileContent, (err) => {
if (err)
return console.error('Error escribiendo el archivo de prueba:', err);
console.log(`Archivo de prueba generado: ${testFileName}`);
});
});
});
}

View File

@ -10,19 +10,15 @@
"lint": "eslint --ext .js,.vue ./",
"format": "prettier --write \"**/*.{js,vue,scss,html,md,json}\" --ignore-path .gitignore",
"test:e2e": "cypress open",
"test:e2e:unit": "cypress run --component",
"test:e2e:unit:ci": "cypress run -p 9000 --component",
"test:e2e:ci": "cd ../salix && gulp docker && cd ../salix-front && cypress run",
"test": "echo \"See package.json => scripts for available tests.\" && exit 0",
"test:unit": "vitest",
"test:unit:ci": "vitest run",
"cypr": "cross-env CYPRESS_REMOTE_DEBUGGING_PORT=9222 cypress open",
"commitlint": "commitlint --edit",
"prepare": "npx husky install",
"addReferenceTag": "node .husky/addReferenceTag.js"
},
"dependencies": {
"@modyfi/vite-plugin-yaml": "1.0.4",
"@quasar/cli": "^2.3.0",
"@quasar/extras": "^1.16.9",
"axios": "^1.4.0",
@ -42,9 +38,7 @@
"@pinia/testing": "^0.1.2",
"@quasar/app-vite": "^1.7.3",
"@quasar/quasar-app-extension-qcalendar": "4.0.0-beta.15",
"@quasar/quasar-app-extension-testing-e2e-cypress": "^6.1.0",
"@quasar/quasar-app-extension-testing-unit-vitest": "^0.4.0",
"@vitest/ui": "^1.6.0",
"@vue/test-utils": "^2.4.4",
"autoprefixer": "^10.4.14",
"cypress": "^13.6.6",

File diff suppressed because it is too large Load Diff

View File

@ -87,7 +87,6 @@ module.exports = configure(function (/* ctx */) {
alias: {
composables: path.join(__dirname, './src/composables'),
filters: path.join(__dirname, './src/filters'),
components: path.join(__dirname, './src/components'),
},
vitePlugins: [

View File

@ -2,9 +2,11 @@ import axios from 'axios';
import { useSession } from 'src/composables/useSession';
import { Router } from 'src/router';
import useNotify from 'src/composables/useNotify.js';
import { useStateQueryStore } from 'src/stores/useStateQueryStore';
const session = useSession();
const { notify } = useNotify();
const stateQuery = useStateQueryStore();
const baseUrl = '/api/';
axios.defaults.baseURL = baseUrl;
@ -15,7 +17,7 @@ const onRequest = (config) => {
if (token.length && !config.headers.Authorization) {
config.headers.Authorization = token;
}
stateQuery.add(config);
return config;
};
@ -24,10 +26,10 @@ const onRequestError = (error) => {
};
const onResponse = (response) => {
const { method } = response.config;
const config = response.config;
stateQuery.remove(config);
const isSaveRequest = method === 'patch';
if (isSaveRequest) {
if (config.method === 'patch') {
notify('globals.dataSaved', 'positive');
}
@ -35,37 +37,9 @@ const onResponse = (response) => {
};
const onResponseError = (error) => {
let message = '';
stateQuery.remove(error.config);
const response = error.response;
const responseData = response && response.data;
const responseError = responseData && response.data.error;
if (responseError) {
message = responseError.message;
}
switch (response?.status) {
case 422:
if (error.name == 'ValidationError')
message +=
' "' +
responseError.details.context +
'.' +
Object.keys(responseError.details.codes).join(',') +
'"';
break;
case 500:
message = 'errors.statusInternalServerError';
break;
case 502:
message = 'errors.statusBadGateway';
break;
case 504:
message = 'errors.statusGatewayTimeout';
break;
}
if (session.isLoggedIn() && response?.status === 401) {
if (session.isLoggedIn() && error.response?.status === 401) {
session.destroy(false);
const hash = window.location.hash;
const url = hash.slice(1);
@ -74,8 +48,6 @@ const onResponseError = (error) => {
return Promise.reject(error);
}
notify(message, 'negative');
return Promise.reject(error);
};

View File

@ -3,14 +3,51 @@ import qFormMixin from './qformMixin';
import mainShortcutMixin from './mainShortcutMixin';
import keyShortcut from './keyShortcut';
import useNotify from 'src/composables/useNotify.js';
import { CanceledError } from 'axios';
const { notify } = useNotify();
export default boot(({ app }) => {
app.mixin(qFormMixin);
app.mixin(mainShortcutMixin);
app.directive('shortcut', keyShortcut);
app.config.errorHandler = function (err) {
console.error(err);
notify('globals.error', 'negative', 'error');
app.config.errorHandler = (error) => {
let message;
const response = error.response;
const responseData = response?.data;
const responseError = responseData && response.data.error;
if (responseError) {
message = responseError.message;
}
switch (response?.status) {
case 422:
if (error.name == 'ValidationError')
message +=
' "' +
responseError.details.context +
'.' +
Object.keys(responseError.details.codes).join(',') +
'"';
break;
case 500:
message = 'errors.statusInternalServerError';
break;
case 502:
message = 'errors.statusBadGateway';
break;
case 504:
message = 'errors.statusGatewayTimeout';
break;
}
console.error(error);
if (error instanceof CanceledError) {
const env = process.env.NODE_ENV;
if (env && env !== 'development') return;
message = 'Duplicate request';
}
notify(message ?? 'globals.error', 'negative', 'error');
};
});

View File

@ -2,9 +2,10 @@
import { reactive, ref, onMounted, nextTick, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import VnInput from 'src/components/common/VnInput.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import FormModelPopup from './FormModelPopup.vue';
import { useState } from 'src/composables/useState';
@ -36,7 +37,7 @@ const onDataSaved = (...args) => {
onMounted(async () => {
await nextTick();
bicInputRef?.value?.focus();
bicInputRef.value.focus();
});
</script>
@ -97,7 +98,7 @@ onMounted(async () => {
</FormModelPopup>
</template>
<i18n lang="yml">
<i18n>
en:
title: New bank entity
subtitle: Please, ensure you put the correct data!

View File

@ -3,8 +3,8 @@ import { reactive, ref, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRouter } from 'vue-router';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import FormModelPopup from './FormModelPopup.vue';
@ -141,7 +141,7 @@ const onDataSaved = async (formData, requestResponse) => {
}
</style>
<i18n lang="yml">
<i18n>
es:
Create manual invoice: Crear factura manual
Ticket: Ticket

View File

@ -2,10 +2,9 @@
import { onMounted, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import VnSelectProvince from 'src/components/VnSelectProvince.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelectProvince from 'components/VnSelectProvince.vue';
import VnInput from 'components/common/VnInput.vue';
import FormModelPopup from './FormModelPopup.vue';
const emit = defineEmits(['onDataSaved']);
@ -64,7 +63,7 @@ const onDataSaved = (...args) => {
</FormModelPopup>
</template>
<i18n lang="yml">
<i18n>
es:
New city: Nueva ciudad
Please, ensure you put the correct data!: ¡Por favor, asegúrese de poner los datos correctos!

View File

@ -1,6 +1,6 @@
<script setup>
import { useI18n } from 'vue-i18n';
import VnRow from 'src/components/ui/VnRow.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
import FormModelPopup from './FormModelPopup.vue';
@ -43,7 +43,7 @@ const { t } = useI18n();
</FormModelPopup>
</template>
<i18n lang="yml">
<i18n>
es:
New expense: Nuevo gasto
It's a withholding: Es una retención

View File

@ -79,14 +79,20 @@ async function onProvinceCreated(data) {
watch(
() => [postcodeFormData.countryFk],
async (newCountryFk, oldValueFk) => {
if (!!oldValueFk[0] && newCountryFk[0] !== oldValueFk[0]) {
if (Array.isArray(newCountryFk)) {
newCountryFk = newCountryFk[0];
}
if (Array.isArray(oldValueFk)) {
oldValueFk = oldValueFk[0];
}
if (!!oldValueFk && newCountryFk !== oldValueFk) {
postcodeFormData.provinceFk = null;
postcodeFormData.townFk = null;
}
if ((newCountryFk, newCountryFk !== postcodeFormData.countryFk)) {
if (oldValueFk !== newCountryFk) {
await provincesFetchDataRef.value.fetch({
where: {
countryFk: newCountryFk[0],
countryFk: newCountryFk,
},
});
await townsFetchDataRef.value.fetch({
@ -103,9 +109,12 @@ watch(
watch(
() => postcodeFormData.provinceFk,
async (newProvinceFk) => {
if (newProvinceFk[0] && newProvinceFk[0] !== postcodeFormData.provinceFk) {
if (Array.isArray(newProvinceFk)) {
newProvinceFk = newProvinceFk[0];
}
if (newProvinceFk !== postcodeFormData.provinceFk) {
await townsFetchDataRef.value.fetch({
where: { provinceFk: newProvinceFk[0] },
where: { provinceFk: newProvinceFk },
});
}
}
@ -125,16 +134,26 @@ async function handleCountries(data) {
<FetchData
ref="provincesFetchDataRef"
@on-fetch="handleProvinces"
:sort-by="['name ASC']"
:limit="30"
auto-load
url="Provinces/location"
/>
<FetchData
ref="townsFetchDataRef"
:sort-by="['name ASC']"
:limit="30"
@on-fetch="handleTowns"
auto-load
url="Towns/location"
/>
<FetchData @on-fetch="handleCountries" auto-load url="Countries" />
<FetchData
@on-fetch="handleCountries"
:sort-by="['name ASC']"
:limit="30"
auto-load
url="Countries"
/>
<FormModelPopup
url-create="postcodes"
model="postcode"

View File

@ -2,8 +2,8 @@
import { reactive, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import FormModelPopup from './FormModelPopup.vue';
@ -46,6 +46,8 @@ const onDataSaved = (dataSaved, requestResponse) => {
},
}"
url="Autonomies/location"
:sort-by="['name ASC']"
:limit="30"
/>
<FormModelPopup
:title="t('New province')"
@ -85,7 +87,7 @@ const onDataSaved = (dataSaved, requestResponse) => {
</FormModelPopup>
</template>
<i18n lang="yml">
<i18n>
es:
New province: Nueva provincia
Please, ensure you put the correct data!: ¡Por favor, asegúrese de poner los datos correctos!

View File

@ -2,8 +2,8 @@
import { reactive, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import FormModelPopup from './FormModelPopup.vue';
@ -95,7 +95,7 @@ const onDataSaved = (dataSaved) => {
</FormModelPopup>
</template>
<i18n lang="yml">
<i18n>
es:
Identifier: Identificador
Model: Modelo

View File

@ -5,10 +5,10 @@ import { useRouter, onBeforeRouteLeave } from 'vue-router';
import { useI18n } from 'vue-i18n';
import { useQuasar } from 'quasar';
import { useValidator } from 'src/composables/useValidator';
import { useStateStore } from 'src/stores/useStateStore';
import VnPaginate from 'src/components/ui/VnPaginate.vue';
import VnConfirm from 'src/components/ui/VnConfirm.vue';
import SkeletonTable from 'src/components/ui/SkeletonTable.vue';
import { useStateStore } from 'stores/useStateStore';
import VnPaginate from 'components/ui/VnPaginate.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
import SkeletonTable from 'components/ui/SkeletonTable.vue';
import { tMobile } from 'src/composables/tMobile';
const { push } = useRouter();

View File

@ -3,8 +3,8 @@ import { reactive, computed, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import VnSelect from 'src/components/common/VnSelect.vue';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
import Croppie from 'croppie/croppie';
@ -336,7 +336,7 @@ const makeRequest = async () => {
}
</style>
<i18n lang="yml">
<i18n>
es:
Edit photo: Editar foto
Select from computer: Seleccionar desde ordenador

View File

@ -5,7 +5,7 @@ import { useI18n } from 'vue-i18n';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnInputDate from 'src/components/common/VnInputDate.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import VnRow from 'components/ui/VnRow.vue';
import { QCheckbox } from 'quasar';
import axios from 'axios';
@ -142,7 +142,7 @@ const closeForm = () => {
}
</style>
<i18n lang="yml">
<i18n>
es:
Edit: Editar
buy(s): compra(s)

View File

@ -2,10 +2,10 @@
import { ref, reactive, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelect from 'components/common/VnSelect.vue';
import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
import axios from 'axios';
@ -208,7 +208,7 @@ const selectItem = ({ id }) => {
</QForm>
</template>
<i18n lang="yml">
<i18n>
es:
Filter item: Filtrar artículo
Enter a new search: Introduce una nueva búsqueda

View File

@ -2,10 +2,10 @@
import { ref, reactive, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnInputDate from 'src/components/common/VnInputDate.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelect from 'components/common/VnSelect.vue';
import TravelDescriptorProxy from 'src/pages/Travel/Card/TravelDescriptorProxy.vue';
import axios from 'axios';
@ -207,7 +207,7 @@ const selectTravel = ({ id }) => {
</QForm>
</template>
<i18n lang="yml">
<i18n>
es:
Filter travels: Filtro envíos
Enter a new search: Introduce una nueva búsqueda

View File

@ -5,10 +5,10 @@ import { onBeforeRouteLeave, useRouter } from 'vue-router';
import { useI18n } from 'vue-i18n';
import { useQuasar } from 'quasar';
import { useState } from 'src/composables/useState';
import { useStateStore } from 'src/stores/useStateStore';
import { useStateStore } from 'stores/useStateStore';
import { useValidator } from 'src/composables/useValidator';
import useNotify from 'src/composables/useNotify.js';
import SkeletonForm from 'src/components/ui/SkeletonForm.vue';
import SkeletonForm from 'components/ui/SkeletonForm.vue';
import VnConfirm from './ui/VnConfirm.vue';
import { tMobile } from 'src/composables/tMobile';
import { useArrayData } from 'src/composables/useArrayData';
@ -217,9 +217,6 @@ async function save() {
updateAndEmit('onDataSaved', formData.value, response?.data);
if ($props.reload) await arrayData.fetch({});
hasChanges.value = false;
} catch (err) {
console.error(err);
notify('errors.writeRequest', 'negative');
} finally {
isLoading.value = false;
}
@ -302,7 +299,7 @@ defineExpose({
<Teleport
to="#st-actions"
v-if="
$props?.defaultActions &&
$props.defaultActions &&
stateStore?.isSubToolbarShown() &&
componentIsRendered
"
@ -363,7 +360,7 @@ defineExpose({
<QInnerLoading
:showing="isLoading"
:label="$t('globals.pleaseWait')"
:label="t('globals.pleaseWait')"
color="primary"
style="min-width: 100%"
/>

View File

@ -2,7 +2,7 @@
import { ref, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import FormModel from 'src/components/FormModel.vue';
import FormModel from 'components/FormModel.vue';
const emit = defineEmits(['onDataSaved', 'onDataCanceled']);
@ -61,6 +61,7 @@ defineExpose({
:loading="isLoading"
@click="emit('onDataCanceled')"
v-close-popup
data-cy="FormModelPopup_cancel"
/>
<QBtn
:label="t('globals.save')"
@ -70,6 +71,7 @@ defineExpose({
class="q-ml-sm"
:disabled="isLoading"
:loading="isLoading"
data-cy="FormModelPopup_save"
/>
</div>
</template>

View File

@ -2,11 +2,11 @@
import { computed, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import VnInput from 'src/components/common/VnInput.vue';
import FetchData from 'src/components/FetchData.vue';
import VnInput from 'components/common/VnInput.vue';
import FetchData from 'components/FetchData.vue';
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnFilterPanelChip from 'src/components/ui/VnFilterPanelChip.vue';
import VnSelect from 'components/common/VnSelect.vue';
import VnFilterPanelChip from 'components/ui/VnFilterPanelChip.vue';
import axios from 'axios';
@ -336,7 +336,7 @@ const removeTag = (index, params, search) => {
}
</style>
<i18n lang="yml">
<i18n>
en:
params:
supplier: Supplier

View File

@ -2,16 +2,18 @@
import { onMounted, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import { useState } from 'src/composables/useState';
import { useStateStore } from 'src/stores/useStateStore';
import { useStateStore } from 'stores/useStateStore';
import { useStateQueryStore } from 'src/stores/useStateQueryStore';
import { useQuasar } from 'quasar';
import PinnedModules from './PinnedModules.vue';
import UserPanel from 'src/components/UserPanel.vue';
import UserPanel from 'components/UserPanel.vue';
import VnBreadcrumbs from './common/VnBreadcrumbs.vue';
import VnAvatar from './ui/VnAvatar.vue';
const { t } = useI18n();
const stateStore = useStateStore();
const quasar = useQuasar();
const stateQuery = useStateQueryStore();
const state = useState();
const user = state.getUser();
const appName = 'Lilium';
@ -50,6 +52,14 @@ const pinnedModulesRef = ref();
</QBtn>
</RouterLink>
<VnBreadcrumbs v-if="$q.screen.gt.sm" />
<QSpinner
color="primary"
class="q-ml-md"
:class="{
'no-visible': !stateQuery.isLoading().value,
}"
size="xs"
/>
<QSpace />
<div id="searchbar" class="searchbar"></div>
<QSpace />
@ -98,8 +108,6 @@ const pinnedModulesRef = ref();
</template>
<style lang="scss" scoped>
@import '/src/css/quasar.variables.scss';
.searchbar {
width: max-content;
}
@ -107,7 +115,7 @@ const pinnedModulesRef = ref();
background-color: var(--vn-section-color);
}
</style>
<i18n lang="yml">
<i18n>
en:
Go to Salix: Go to Salix
es:

View File

@ -78,7 +78,7 @@ async function redirect() {
}
</style>
<i18n lang="yml">
<i18n>
en:
Home: Home
es:

View File

@ -3,9 +3,9 @@ import { ref, reactive } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRouter } from 'vue-router';
import { useDialogPluginComponent } from 'quasar';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'src/components/FetchData.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnRow from 'components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnSelect from 'components/common/VnSelect.vue';
import FormPopup from './FormPopup.vue';
import axios from 'axios';
import useNotify from 'src/composables/useNotify.js';
@ -150,7 +150,7 @@ const refund = async () => {
</QDialog>
</template>
<i18n lang="yml">
<i18n>
en:
Refund invoice: Refund invoice
Rectificative type: Rectificative type

View File

@ -3,8 +3,8 @@ import { reactive, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import VnSelect from 'src/components/common/VnSelect.vue';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import FormModelPopup from './FormModelPopup.vue';
const emit = defineEmits(['onDataSaved']);
@ -73,7 +73,7 @@ const onDataSaved = (data) => {
</FormModelPopup>
</template>
<i18n lang="yml">
<i18n>
es:
Warehouse: Almacén
Type the visible quantity: Introduce la cantidad visible

View File

@ -3,10 +3,10 @@ import { ref, reactive } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRouter } from 'vue-router';
import { useQuasar, useDialogPluginComponent } from 'quasar';
import VnConfirm from 'src/components/ui/VnConfirm.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'src/components/FetchData.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
import VnRow from 'components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnSelect from 'components/common/VnSelect.vue';
import FormPopup from './FormPopup.vue';
import axios from 'axios';
import useNotify from 'src/composables/useNotify.js';
@ -205,7 +205,7 @@ const makeInvoice = async () => {
</QDialog>
</template>
<i18n lang="yml">
<i18n>
en:
checkInfo: New tickets from the destination customer will be generated in the consignee by default.
transferInvoiceInfo: Destination customer is marked to bill in the consignee

View File

@ -8,8 +8,8 @@ import { useState } from 'src/composables/useState';
import { useSession } from 'src/composables/useSession';
import { localeEquivalence } from 'src/i18n/index';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import { useClipboard } from 'src/composables/useClipboard';
import { useRole } from 'src/composables/useRole';
import VnAvatar from './ui/VnAvatar.vue';

View File

@ -3,8 +3,8 @@ import { ref } from 'vue';
import { useValidator } from 'src/composables/useValidator';
import { useI18n } from 'vue-i18n';
import VnSelectDialog from 'src/components/common/VnSelectDialog.vue';
import FetchData from 'src/components/FetchData.vue';
import VnSelectDialog from 'components/common/VnSelectDialog.vue';
import FetchData from 'components/FetchData.vue';
import CreateNewProvinceForm from './CreateNewProvinceForm.vue';
const emit = defineEmits(['onProvinceCreated']);
@ -78,7 +78,7 @@ async function handleProvinces(data) {
</template>
</VnSelectDialog>
</template>
<i18n lang="yml">
<i18n>
es:
Province: Provincia
Create province: Crear provincia

View File

@ -4,14 +4,14 @@ import { QIcon, QCheckbox } from 'quasar';
import { dashIfEmpty } from 'src/filters';
/* basic input */
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelectCache from 'src/components/common/VnSelectCache.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnInputNumber from 'src/components/common/VnInputNumber.vue';
import VnInputDate from 'src/components/common/VnInputDate.vue';
import VnInputTime from 'src/components/common/VnInputTime.vue';
import VnComponent from 'src/components/common/VnComponent.vue';
import VnUserLink from 'src/components/ui/VnUserLink.vue';
import VnSelect from 'components/common/VnSelect.vue';
import VnSelectCache from 'components/common/VnSelectCache.vue';
import VnInput from 'components/common/VnInput.vue';
import VnInputNumber from 'components/common/VnInputNumber.vue';
import VnInputDate from 'components/common/VnInputDate.vue';
import VnInputTime from 'components/common/VnInputTime.vue';
import VnComponent from 'components/common/VnComponent.vue';
import VnUserLink from 'components/ui/VnUserLink.vue';
const model = defineModel(undefined, { required: true });
const $props = defineProps({

View File

@ -1,14 +1,14 @@
<script setup>
import { markRaw, computed, defineModel } from 'vue';
import { QCheckbox } from 'quasar';
import { useArrayData } from 'src/composables/useArrayData';
import { useArrayData } from 'composables/useArrayData';
/* basic input */
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnInputDate from 'src/components/common/VnInputDate.vue';
import VnInputTime from 'src/components/common/VnInputTime.vue';
import VnTableColumn from 'src/components/VnTable/VnColumn.vue';
import VnSelect from 'components/common/VnSelect.vue';
import VnInput from 'components/common/VnInput.vue';
import VnInputDate from 'components/common/VnInputDate.vue';
import VnInputTime from 'components/common/VnInputTime.vue';
import VnTableColumn from 'components/VnTable/VnColumn.vue';
const $props = defineProps({
column: {

View File

@ -1,6 +1,6 @@
<script setup>
import { ref } from 'vue';
import { useArrayData } from 'src/composables/useArrayData';
import { useArrayData } from 'composables/useArrayData';
const model = defineModel({ type: Object });
const $props = defineProps({
name: {

View File

@ -6,14 +6,14 @@ import { useQuasar } from 'quasar';
import { useStateStore } from 'stores/useStateStore';
import CrudModel from 'src/components/CrudModel.vue';
import FormModelPopup from 'src/components/FormModelPopup.vue';
import FormModelPopup from 'components/FormModelPopup.vue';
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
import VnTableColumn from 'src/components/VnTable/VnColumn.vue';
import VnFilter from 'src/components/VnTable/VnFilter.vue';
import VnTableChip from 'src/components/VnTable/VnChip.vue';
import VnFilterPanel from 'components/ui/VnFilterPanel.vue';
import VnTableColumn from 'components/VnTable/VnColumn.vue';
import VnFilter from 'components/VnTable/VnFilter.vue';
import VnTableChip from 'components/VnTable/VnChip.vue';
import VnVisibleColumn from 'src/components/VnTable/VnVisibleColumn.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import VnLv from 'components/ui/VnLv.vue';
import VnTableOrder from 'src/components/VnTable/VnOrder.vue';
const $props = defineProps({
@ -316,6 +316,7 @@ defineExpose({
selected,
CrudModelRef,
params,
tableRef,
});
function handleOnDataSaved(_) {
@ -416,6 +417,7 @@ function handleScroll() {
ref="tableRef"
v-bind="table"
class="vnTable"
:class="{ 'last-row-sticky': $props.footer }"
:columns="splittedColumns.columns"
:rows="rows"
v-model:selected="selected"
@ -455,7 +457,11 @@ function handleScroll() {
/>
</template>
<template #header-cell="{ col }">
<QTh v-if="col.visible ?? true">
<QTh
v-if="col.visible ?? true"
:style="col.headerStyle"
:class="col.headerClass"
>
<div
class="column self-start q-ml-xs ellipsis"
:class="`text-${col?.align ?? 'left'}`"
@ -751,7 +757,7 @@ function handleScroll() {
</FormModelPopup>
</QDialog>
</template>
<i18n lang="yml">
<i18n>
en:
status: Status
table view: Table view
@ -815,6 +821,7 @@ es:
top: 0;
}
}
.vnTable {
thead tr th {
position: sticky;
@ -853,6 +860,9 @@ es:
table tbody th {
position: relative;
}
}
.last-row-sticky {
tbody:nth-last-child(1) {
@extend .bg-header;
position: sticky;

View File

@ -181,7 +181,7 @@ onMounted(async () => {
}
</style>
<i18n lang="yml">
<i18n>
es:
Check the columns you want to see: Marca las columnas que quieres ver
Visible columns: Columnas visibles

View File

@ -1,7 +1,7 @@
<script setup>
import { ref, onMounted, useSlots } from 'vue';
import { useI18n } from 'vue-i18n';
import { useStateStore } from 'src/stores/useStateStore';
import { useStateStore } from 'stores/useStateStore';
const slots = useSlots();
const hasContent = ref(false);

View File

@ -78,7 +78,7 @@ async function confirm() {
}
</style>
<i18n lang="yml">
<i18n>
es:
Send email notification: Enviar notificación por correo
The notification will be sent to the following address: La notificación se enviará a la siguiente dirección

View File

@ -2,9 +2,9 @@
import {useDialogPluginComponent} from 'quasar';
import {useI18n} from 'vue-i18n';
import {computed, ref} from 'vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnInput from 'components/common/VnInput.vue';
import axios from 'axios';
import useNotify from 'src/composables/useNotify';
import useNotify from "composables/useNotify";
const MESSAGE_MAX_LENGTH = 160;
@ -144,7 +144,7 @@ const onSubmit = async () => {
max-width: 450px;
}
</style>
<i18n lang="yml">
<i18n>
es:
Message: Mensaje
Send: Enviar

View File

@ -191,7 +191,7 @@ onMounted(async () => {
}
</style>
<i18n lang="yml">
<i18n>
es:
Check the columns you want to see: Marca las columnas que quieres ver
Visible columns: Columnas visibles

View File

@ -67,10 +67,7 @@ function getBreadcrumb(param) {
/>
</QBreadcrumbs>
</template>
<style lang="scss" scoped>
@import '/src/css/quasar.variables.scss';
@import '/node_modules/quasar/src/css/variables.sass';
<style lang="scss">
.q-breadcrumbs {
&__el,
> div {

View File

@ -0,0 +1,19 @@
<script setup>
import VnSelect from './VnSelect.vue';
defineProps({
selectProps: { type: Object, required: true },
promise: { type: Function, default: () => {} },
});
</script>
<template>
<QBtnDropdown v-bind="$attrs" color="primary">
<VnSelect
v-bind="selectProps"
hide-selected
hide-dropdown-icon
focus-on-mount
@update:model-value="promise"
/>
</QBtnDropdown>
</template>

View File

@ -5,9 +5,9 @@ import { useArrayData } from 'src/composables/useArrayData';
import { useStateStore } from 'stores/useStateStore';
import useCardSize from 'src/composables/useCardSize';
import VnSubToolbar from '../ui/VnSubToolbar.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import LeftMenu from 'src/components/LeftMenu.vue';
import RightMenu from 'src/components/common/RightMenu.vue';
import VnSearchbar from 'components/ui/VnSearchbar.vue';
import LeftMenu from 'components/LeftMenu.vue';
import RightMenu from 'components/common/RightMenu.vue';
const props = defineProps({
dataKey: { type: String, required: true },
baseUrl: { type: String, default: undefined },

View File

@ -4,11 +4,11 @@ import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import axios from 'axios';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import FormModelPopup from 'src/components/FormModelPopup.vue';
import FormModelPopup from 'components/FormModelPopup.vue';
const route = useRoute();
const { t } = useI18n();
@ -195,7 +195,7 @@ function addDefaultData(data) {
row-gap: 20px;
}
</style>
<i18n lang="yml">
<i18n>
en:
contentTypesInfo: Allowed file types {allowedContentTypes}
EntryDmsDescription: Reference {reference}
@ -207,4 +207,5 @@ es:
EntryDmsDescription: Referencia {reference}
WorkersDescription: Laboral del empleado {reference}
SupplierDmsDescription: Referencia {reference}
</i18n>

View File

@ -7,11 +7,11 @@ import axios from 'axios';
import VnUserLink from '../ui/VnUserLink.vue';
import { downloadFile } from 'src/composables/downloadFile';
import VnImg from 'src/components/ui/VnImg.vue';
import VnPaginate from 'src/components/ui/VnPaginate.vue';
import VnImg from 'components/ui/VnImg.vue';
import VnPaginate from 'components/ui/VnPaginate.vue';
import VnDms from 'src/components/common/VnDms.vue';
import VnConfirm from 'src/components/ui/VnConfirm.vue';
import VnInputDate from 'src/components/common/VnInputDate.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
import VnInputDate from 'components/common/VnInputDate.vue';
import { useSession } from 'src/composables/useSession';
const route = useRoute();
@ -419,7 +419,7 @@ defineExpose({
color: var(--vn-label-color);
}
</style>
<i18n lang="yml">
<i18n>
en:
contentTypesInfo: Allowed file types {allowedContentTypes}
The documentation is available in paper form: The documentation is available in paper form

View File

@ -118,7 +118,7 @@ const mixinRules = [
</QInput>
</div>
</template>
<i18n lang="yml">
<i18n>
en:
inputMin: Must be more than {value}
inputMax: Must be less than {value}

View File

@ -161,7 +161,7 @@ const manageDate = (date) => {
border-style: solid;
}
</style>
<i18n lang="yml">
<i18n>
es:
Open date: Abrir fecha
</i18n>

View File

@ -140,7 +140,7 @@ function dateToTime(newDate) {
display: none;
}
</style>
<i18n lang="yml">
<i18n>
es:
Open time: Abrir tiempo
</i18n>

View File

@ -1,6 +1,6 @@
<script setup>
import CreateNewPostcode from 'src/components/CreateNewPostcodeForm.vue';
import VnSelectDialog from 'src/components/common/VnSelectDialog.vue';
import VnSelectDialog from 'components/common/VnSelectDialog.vue';
import { useI18n } from 'vue-i18n';
import { ref } from 'vue';
const { t } = useI18n();
@ -96,8 +96,6 @@ const handleModelValue = (data) => {
</VnSelectDialog>
</template>
<style lang="scss" scoped>
@import 'src/css/quasar.variables.scss';
.add-icon {
cursor: pointer;
background-color: $primary;
@ -105,7 +103,7 @@ const handleModelValue = (data) => {
}
</style>
<i18n lang="yml">
<i18n>
en:
search_by_postalcode: Search by postalcode, town, province or country
Create new location: Create new location

View File

@ -4,7 +4,7 @@ import { useI18n } from 'vue-i18n';
import { useRoute, useRouter } from 'vue-router';
import axios from 'axios';
import { date } from 'quasar';
import { useStateStore } from 'src/stores/useStateStore';
import { useStateStore } from 'stores/useStateStore';
import { toRelativeDate } from 'src/filters';
import { useColor } from 'src/composables/useColor';
import { useCapitalize } from 'src/composables/useCapitalize';
@ -852,8 +852,6 @@ watch(
</QPageSticky>
</template>
<style lang="scss" scoped>
@import 'src/css/quasar.variables.scss';
.q-card {
background-color: var(--vn-section-color);
}
@ -1040,7 +1038,7 @@ watch(
}
}
</style>
<i18n lang="yml">
<i18n>
en:
to: To
pointRecord: View record at this point in time

View File

@ -1,7 +1,7 @@
<script setup>
import { ref } from 'vue';
import { useI18n } from 'vue-i18n';
import FetchData from 'src/components/FetchData.vue';
import FetchData from 'components/FetchData.vue';
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
const { t } = useI18n();
@ -62,7 +62,7 @@ const workers = ref();
</VnFilterPanel>
</template>
<i18n lang="yml">
<i18n>
en:
params:
search: Contains

View File

@ -9,10 +9,6 @@ const $props = defineProps({
type: Number, //Progress value (1.0 > x > 0.0)
required: true,
},
showDialog: {
type: Boolean,
required: true,
},
cancelled: {
type: Boolean,
required: false,
@ -24,30 +20,22 @@ const emit = defineEmits(['cancel', 'close']);
const dialogRef = ref(null);
const _showDialog = computed({
get: () => $props.showDialog,
set: (value) => {
if (value) dialogRef.value.show();
},
const showDialog = defineModel('showDialog', {
type: Boolean,
default: false,
});
const _progress = computed(() => $props.progress);
const progressLabel = computed(() => `${Math.round($props.progress * 100)}%`);
const cancel = () => {
dialogRef.value.hide();
emit('cancel');
};
</script>
<template>
<QDialog ref="dialogRef" v-model="_showDialog" @hide="onDialogHide">
<QDialog ref="dialogRef" v-model="showDialog" @hide="emit('close')">
<QCard class="full-width dialog">
<QCardSection class="row">
<span class="text-h6">{{ t('Progress') }}</span>
<QSpace />
<QBtn icon="close" flat round dense @click="emit('close')" />
<QBtn icon="close" flat round dense v-close-popup />
</QCardSection>
<QCardSection>
<div class="column">
@ -80,7 +68,7 @@ const cancel = () => {
type="button"
flat
class="text-primary"
@click="cancel()"
v-close-popup
>
{{ t('globals.cancel') }}
</QBtn>
@ -89,7 +77,7 @@ const cancel = () => {
</QDialog>
</template>
<i18n lang="yml">
<i18n>
es:
Progress: Progreso
Total progress: Progreso total

View File

@ -1,6 +1,6 @@
<script setup>
import { useStateStore } from 'src/stores/useStateStore';
import LeftMenu from 'src/components/LeftMenu.vue';
import { useStateStore } from 'stores/useStateStore';
import LeftMenu from 'components/LeftMenu.vue';
import { onMounted } from 'vue';
import { useQuasar } from 'quasar';

View File

@ -86,10 +86,6 @@ const $props = defineProps({
type: Boolean,
default: false,
},
sortByWeight: {
type: Boolean,
default: false,
},
});
const { validations } = useValidator();
const requiredFieldRule = (val) => validations().required($attrs.required, val);
@ -145,6 +141,7 @@ function findKeyInOptions() {
function setOptions(data) {
myOptions.value = JSON.parse(JSON.stringify(data));
myOptionsOriginal.value = JSON.parse(JSON.stringify(data));
emit('update:options', data);
}
function filter(val, options) {

View File

@ -64,8 +64,6 @@ const isAllowedToCreate = computed(() => {
</template>
<style lang="scss" scoped>
@import 'src/css/quasar.variables.scss';
.default-icon {
cursor: pointer;
color: $primary;

View File

@ -1,7 +1,7 @@
<script setup>
import { onBeforeMount, ref, useAttrs } from 'vue';
import axios from 'axios';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelect from 'components/common/VnSelect.vue';
const { schema, table, column, translation, defaultOptions } = defineProps({
schema: {

View File

@ -176,7 +176,7 @@ async function send() {
}
</style>
<i18n lang="yml">
<i18n>
en:
templates:
pendingPayment: 'Your order is pending of payment.
@ -218,8 +218,7 @@ fr:
Message: Message
messageTooltip: Les caractères spéciaux comme les accents comptent comme plusieurs
templates:
pendingPayment:
'Verdnatura : Commande en attente de règlement. Veuillez régler votre commande avant 9h.
pendingPayment: 'Verdnatura : Commande en attente de règlement. Veuillez régler votre commande avant 9h.
Sinon elle sera décalée en fonction de vos jours de livraison . Merci'
minAmount: 'Verdnatura vous rappelle :
Montant minimum nécessaire de 50 euros pour recevoir la commande { orderId } livraison { landing }.

View File

@ -127,7 +127,7 @@ function cancel({ cancel }) {
</QPopupEdit>
</template>
<i18n lang="yml">
<i18n>
es:
New amount: Nuevo importe
Update discount: Actualizar descuento

View File

@ -1,16 +0,0 @@
import { mount } from '@cypress/vue'; import FetchData from
'../../src/components/FetchData.vue'; import axios from 'axios'; import { ref } from
'vue'; // Mock axios jest.mock('axios'); describe('FetchData Component', () => {
it('fetches data on mount when autoLoad is true', () => { const mockData = { data: [{ id:
1, name: 'Test' }] }; axios.get.mockResolvedValue(mockData); const onFetch =
cy.spy().as('onFetch'); mount(FetchData, { props: { autoLoad: true, url:
'https://api.example.com/data', }, attrs: { onFetch, }, });
cy.get('@onFetch').should('have.been.calledWith', mockData.data); }); it('does not fetch
data on mount when autoLoad is false', () => { const onFetch = cy.spy().as('onFetch');
mount(FetchData, { props: { autoLoad: false, url: 'https://api.example.com/data', },
attrs: { onFetch, }, }); cy.get('@onFetch').should('not.have.been.called'); });
it('fetches data when fetch method is called', () => { const mockData = { data: [{ id: 1,
name: 'Test' }] }; axios.get.mockResolvedValue(mockData); const onFetch =
cy.spy().as('onFetch'); const wrapper = mount(FetchData, { props: { autoLoad: false, url:
'https://api.example.com/data', }, attrs: { onFetch, }, }); wrapper.vm.fetch();
cy.get('@onFetch').should('have.been.calledWith', mockData.data); }); });

View File

@ -1,8 +1,8 @@
<script setup>
import { onBeforeMount, watch, computed, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import SkeletonDescriptor from 'src/components/ui/SkeletonDescriptor.vue';
import { useArrayData } from 'src/composables/useArrayData';
import SkeletonDescriptor from 'components/ui/SkeletonDescriptor.vue';
import { useArrayData } from 'composables/useArrayData';
import { useSummaryDialog } from 'src/composables/useSummaryDialog';
import { useState } from 'src/composables/useState';
import { useRoute } from 'vue-router';

View File

@ -124,7 +124,7 @@ const toggleCardCheck = (item) => {
}
</style>
<i18n lang="yml">
<i18n>
es:
ID: ID
</i18n>

View File

@ -1,7 +1,7 @@
<script setup>
import { ref, computed, watch, onBeforeMount } from 'vue';
import { useRoute } from 'vue-router';
import SkeletonSummary from 'src/components/ui/SkeletonSummary.vue';
import SkeletonSummary from 'components/ui/SkeletonSummary.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import { useArrayData } from 'src/composables/useArrayData';
@ -111,8 +111,6 @@ function existSummary(routes) {
</template>
<style lang="scss">
@import 'src/css/quasar.variables.scss';
.summary.container {
display: flex;
justify-content: center;
@ -207,8 +205,6 @@ function existSummary(routes) {
}
</style>
<style lang="scss" scoped>
@import 'src/css/quasar.variables.scss';
.summaryHeader .vn-label-value {
display: flex;
flex-direction: row;

View File

@ -2,7 +2,7 @@
import { ref } from 'vue';
import { useI18n } from 'vue-i18n';
import VnLv from 'src/components/ui/VnLv.vue';
import VnLv from 'components/ui/VnLv.vue';
import VnImg from 'src/components/ui/VnImg.vue';
import OrderCatalogItemDialog from 'pages/Order/Card/OrderCatalogItemDialog.vue';
import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
@ -101,8 +101,6 @@ const dialog = ref(null);
}
</style>
<style lang="scss" scoped>
@import 'src/css/quasar.variables.scss';
.container {
max-width: 448px;
width: 100%;
@ -181,7 +179,7 @@ const dialog = ref(null);
}
}
</style>
<i18n lang="yml">
<i18n>
es:
to: to
price-kg: Precio por Kg

View File

@ -46,8 +46,6 @@ const tags = computed(() => {
</template>
<style lang="scss" scoped>
@import 'src/css/quasar.variables.scss';
.fetchedTags {
align-items: center;
.wrap {

View File

@ -102,7 +102,7 @@ async function confirm() {
}
</style>
<i18n lang="yml">
<i18n>
es:
Confirm: Confirmar
Are you sure you want to continue?: ¿Seguro que quieres continuar?

View File

@ -1,10 +1,10 @@
<script setup>
import { onMounted, ref, computed, watch } from 'vue';
import { useI18n } from 'vue-i18n';
import { useArrayData } from 'src/composables/useArrayData';
import { useArrayData } from 'composables/useArrayData';
import { useRoute } from 'vue-router';
import toDate from 'filters/toDate';
import VnFilterPanelChip from 'src/components/ui/VnFilterPanelChip.vue';
import VnFilterPanelChip from 'components/ui/VnFilterPanelChip.vue';
const { t } = useI18n();
const $props = defineProps({
@ -283,7 +283,7 @@ function sanitizer(params) {
}
</style>
<i18n lang="yml">
<i18n>
es:
No filters applied: No se han aplicado filtros
Applied filters: Filtros aplicados

View File

@ -8,14 +8,14 @@ import { useQuasar } from 'quasar';
import { toDateHourMin } from 'src/filters';
import { useState } from 'src/composables/useState';
import VnPaginate from 'src/components/ui/VnPaginate.vue';
import VnUserLink from 'src/components/ui/VnUserLink.vue';
import VnConfirm from 'src/components/ui/VnConfirm.vue';
import VnAvatar from 'src/components/ui/VnAvatar.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import FetchData from 'src/components/FetchData.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnPaginate from 'components/ui/VnPaginate.vue';
import VnUserLink from 'components/ui/VnUserLink.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
import VnAvatar from 'components/ui/VnAvatar.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelect from 'components/common/VnSelect.vue';
import FetchData from 'components/FetchData.vue';
import VnInput from 'components/common/VnInput.vue';
const $props = defineProps({
url: { type: String, default: null },
@ -205,7 +205,7 @@ onBeforeRouteLeave((to, from, next) => {
}
}
</style>
<i18n lang="yml">
<i18n>
es:
Add note here...: Añadir nota aquí...
New note: Nueva nota

View File

@ -1,7 +1,7 @@
<script setup>
import { onBeforeUnmount, onMounted, ref, watch } from 'vue';
import { useI18n } from 'vue-i18n';
import { useArrayData } from 'src/composables/useArrayData';
import { useArrayData } from 'composables/useArrayData';
const { t } = useI18n();
@ -245,7 +245,7 @@ defineExpose({ fetch, addFilter, paginate });
}
</style>
<i18n lang="yml">
<i18n>
es:
No data to display: Sin datos que mostrar
No results found: No se han encontrado resultados

View File

@ -1,7 +1,7 @@
<script setup>
import { onMounted, ref, watch } from 'vue';
import { useQuasar } from 'quasar';
import { useArrayData } from 'src/composables/useArrayData';
import { useArrayData } from 'composables/useArrayData';
import VnInput from 'src/components/common/VnInput.vue';
import { useI18n } from 'vue-i18n';
import { useStateStore } from 'src/stores/useStateStore';

View File

@ -0,0 +1,33 @@
<script setup>
import { useRoute } from 'vue-router';
import { defineProps } from 'vue';
const props = defineProps({
routeName: {
type: String,
required: true,
},
entityId: {
type: [String, Number],
required: true,
},
url: {
type: String,
default: null,
},
});
const route = useRoute();
const id = props.entityId;
</script>
<template>
<router-link
v-if="route?.name !== routeName"
:to="{ name: routeName, params: { id: id } }"
class="header link"
:href="url"
>
<QIcon name="open_in_new" color="white" size="sm" />
</router-link>
</template>

View File

@ -0,0 +1,55 @@
<script setup>
import { defineProps, ref } from 'vue';
import { useI18n } from 'vue-i18n';
const { t } = useI18n();
const props = defineProps({
usesMana: {
type: Boolean,
required: true,
},
manaCode: {
type: String,
required: true,
},
manaVal: {
type: String,
default: 'mana',
},
manaLabel: {
type: String,
default: 'Promotion mana',
},
manaClaimVal: {
type: String,
default: 'manaClaim',
},
claimLabel: {
type: String,
default: 'Claim mana',
},
});
const manaCode = ref(props.manaCode);
</script>
<template>
<div class="column q-gutter-y-sm q-mt-sm">
<QRadio
v-model="manaCode"
dense
:val="manaVal"
:label="t(manaLabel)"
:dark="true"
class="q-mb-sm"
/>
<QRadio
v-model="manaCode"
dense
:val="manaClaimVal"
:label="t(claimLabel)"
:dark="true"
class="q-mb-sm"
/>
</div>
</template>

View File

@ -1,8 +1,10 @@
import { onMounted, computed } from 'vue';
import { useRouter, useRoute } from 'vue-router';
import axios from 'axios';
import { useArrayDataStore } from 'src/stores/useArrayDataStore';
import { buildFilter } from 'src/filters/filterPanel';
import { useArrayDataStore } from 'stores/useArrayDataStore';
import { buildFilter } from 'filters/filterPanel';
const arrayDataStore = useArrayDataStore();
export function useArrayData(key = useRoute().meta.moduleName, userOptions) {
if (!key) throw new Error('ArrayData: A key is required to use this composable');
@ -296,5 +298,3 @@ export function useArrayData(key = useRoute().meta.moduleName, userOptions) {
reset,
};
}
const arrayDataStore = useArrayDataStore();

View File

@ -1,4 +1,4 @@
import VnConfirm from 'src/components/ui/VnConfirm.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
import { useQuasar } from 'quasar';
export function useVnConfirm() {

View File

@ -288,3 +288,7 @@ input::-webkit-inner-spin-button {
color: $info;
}
}
.no-visible {
visibility: hidden;
}

View File

@ -1,4 +1,4 @@
import isValidDate from 'src/filters/isValidDate';
import isValidDate from 'filters/isValidDate';
export default function toHour(date) {
if (!isValidDate(date)) {

View File

@ -304,12 +304,14 @@ globals:
from: From
To: To
stateFk: State
departmentFk: Department
email: Email
SSN: SSN
fi: FI
myTeam: My team
departmentFk: Department
changePass: Change password
deleteConfirmTitle: Delete selected elements
changeState: Change state
errors:
statusUnauthorized: Access denied
statusInternalServerError: An internal server error has ocurred
@ -556,7 +558,6 @@ ticket:
package: Package
taxClass: Tax class
services: Services
changeState: Change state
requester: Requester
atender: Atender
request: Request

View File

@ -312,8 +312,10 @@ globals:
email: Correo
SSN: NSS
fi: NIF
myTeam: Mi equipo
changePass: Cambiar contraseña
deleteConfirmTitle: Eliminar los elementos seleccionados
changeState: Cambiar estado
errors:
statusUnauthorized: Acceso denegado
statusInternalServerError: Ha ocurrido un error interno del servidor
@ -565,7 +567,6 @@ ticket:
package: Embalaje
taxClass: Tipo IVA
services: Servicios
changeState: Cambiar estado
requester: Solicitante
atender: Comprador
request: Petición de compra

View File

@ -1,7 +1,7 @@
<script setup>
import { useI18n } from 'vue-i18n';
import FormModel from 'src/components/FormModel.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FormModel from 'components/FormModel.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import VnInput from 'src/components/common/VnInput.vue';
import axios from 'axios';
@ -95,7 +95,7 @@ const onSynchronizeRoles = async () => {
</QPage>
</template>
<i18n lang="yml">
<i18n>
es:
Roles synchronized!: ¡Roles sincronizados!
Synchronizing in the background: Sincronizando en segundo plano

View File

@ -6,9 +6,9 @@ import axios from 'axios';
import useNotify from 'src/composables/useNotify.js';
import { useQuasar } from 'quasar';
import VnTable from 'src/components/VnTable/VnTable.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import VnConfirm from 'src/components/ui/VnConfirm.vue';
import VnTable from 'components/VnTable/VnTable.vue';
import VnSearchbar from 'components/ui/VnSearchbar.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
defineProps({
id: {
@ -150,7 +150,7 @@ const deleteAcl = async ({ id }) => {
/>
</template>
<i18n lang="yml">
<i18n>
es:
New ACL: Nuevo ACL
ACL removed: ACL eliminado

View File

@ -1,8 +1,8 @@
<script setup>
import { useI18n } from 'vue-i18n';
import { ref, computed } from 'vue';
import VnTable from 'src/components/VnTable/VnTable.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import VnTable from 'components/VnTable/VnTable.vue';
import VnSearchbar from 'components/ui/VnSearchbar.vue';
import { useStateStore } from 'stores/useStateStore';
const tableRef = ref();
@ -74,7 +74,7 @@ const columns = computed(() => [
/>
</template>
<i18n lang="yml">
<i18n>
es:
Id: Id
Alias: Alias

View File

@ -2,13 +2,13 @@
import { ref } from 'vue';
import { useRouter } from 'vue-router';
import { useI18n } from 'vue-i18n';
import VnPaginate from 'src/components/ui/VnPaginate.vue';
import VnPaginate from 'components/ui/VnPaginate.vue';
import CardList from 'src/components/ui/CardList.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import { toDateTimeFormat } from 'src/filters/date.js';
import axios from 'axios';
import useNotify from 'src/composables/useNotify.js';
import { useVnConfirm } from 'src/composables/useVnConfirm';
import { useVnConfirm } from 'composables/useVnConfirm';
const { t } = useI18n();
const router = useRouter();
@ -102,7 +102,7 @@ const killSession = async ({ userId, created }) => {
</QPage>
</template>
<i18n lang="yml">
<i18n>
es:
Session killed: Sesión matada
Session will be killed: Se va a matar la sesión

View File

@ -2,9 +2,9 @@
import { reactive, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRouter } from 'vue-router';
import FormModelPopup from 'src/components/FormModelPopup.vue';
import FormModelPopup from 'components/FormModelPopup.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import FetchData from 'src/components/FetchData.vue';
import FetchData from 'components/FetchData.vue';
import VnInput from 'src/components/common/VnInput.vue';
const { t } = useI18n();

View File

@ -1,9 +1,9 @@
<script setup>
import { ref } from 'vue';
import { useI18n } from 'vue-i18n';
import FetchData from 'src/components/FetchData.vue';
import FetchData from 'components/FetchData.vue';
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelect from 'components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
const { t } = useI18n();

View File

@ -1,8 +1,8 @@
<script setup>
import { ref, onMounted, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import FormModel from 'src/components/FormModel.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FormModel from 'components/FormModel.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import { useArrayData } from 'src/composables/useArrayData';
@ -156,7 +156,7 @@ onMounted(async () => await getInitialLdapConfig());
</QPage>
</template>
<i18n lang="yml">
<i18n>
es:
LDAP connection established!: ¡Conexión con LDAP establecida!
</i18n>

View File

@ -1,8 +1,8 @@
<script setup>
import { useI18n } from 'vue-i18n';
import { ref, computed } from 'vue';
import VnTable from 'src/components/VnTable/VnTable.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import VnTable from 'components/VnTable/VnTable.vue';
import VnSearchbar from 'components/ui/VnSearchbar.vue';
import AccountSummary from './Card/AccountSummary.vue';
import { useSummaryDialog } from 'src/composables/useSummaryDialog';
import AccountFilter from './AccountFilter.vue';
@ -130,7 +130,7 @@ const exprBuilder = (param, value) => {
/>
</template>
<i18n lang="yml">
<i18n>
es:
Id: Id
Nickname: Nickname

View File

@ -1,8 +1,8 @@
<script setup>
import { ref, onMounted, computed } from 'vue';
import { useI18n } from 'vue-i18n';
import FormModel from 'src/components/FormModel.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FormModel from 'components/FormModel.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import { useArrayData } from 'src/composables/useArrayData';
@ -176,7 +176,7 @@ onMounted(async () => await getInitialSambaConfig());
</QPage>
</template>
<i18n lang="yml">
<i18n>
es:
Samba connection established!: ¡Conexión con LDAP establecida!
</i18n>

View File

@ -2,9 +2,9 @@
import { ref, onBeforeMount } from 'vue';
import { useI18n } from 'vue-i18n';
import FetchData from 'src/components/FetchData.vue';
import FetchData from 'components/FetchData.vue';
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelect from 'components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import { useValidator } from 'src/composables/useValidator';

View File

@ -4,7 +4,7 @@ import { ref, onBeforeMount, onMounted } from 'vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import FormModelPopup from 'src/components/FormModelPopup.vue';
import FormModelPopup from 'components/FormModelPopup.vue';
import { useValidator } from 'src/composables/useValidator';
import { useArrayData } from 'src/composables/useArrayData';

View File

@ -2,8 +2,8 @@
import { useRouter } from 'vue-router';
import { useI18n } from 'vue-i18n';
import FormModelPopup from 'src/components/FormModelPopup.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FormModelPopup from 'components/FormModelPopup.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
import { useArrayData } from 'src/composables/useArrayData';
@ -51,7 +51,7 @@ const onDataSaved = ({ id }) => {
</FormModelPopup>
</template>
<i18n lang="yml">
<i18n>
es:
Create alias: Crear alias
</i18n>

View File

@ -1,7 +1,7 @@
<script setup>
import { useI18n } from 'vue-i18n';
import FormModel from 'src/components/FormModel.vue';
import FormModel from 'components/FormModel.vue';
import VnInput from 'src/components/common/VnInput.vue';
const { t } = useI18n();

View File

@ -1,6 +1,6 @@
<script setup>
import { useI18n } from 'vue-i18n';
import VnCard from 'src/components/common/VnCard.vue';
import VnCard from 'components/common/VnCard.vue';
import AliasDescriptor from './AliasDescriptor.vue';
const { t } = useI18n();
</script>

View File

@ -4,7 +4,7 @@ import { useRoute, useRouter } from 'vue-router';
import { useI18n } from 'vue-i18n';
import { useQuasar } from 'quasar';
import CardDescriptor from 'src/components/ui/CardDescriptor.vue';
import CardDescriptor from 'components/ui/CardDescriptor.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import useCardDescription from 'src/composables/useCardDescription';
@ -76,7 +76,7 @@ const removeAlias = () => {
</CardDescriptor>
</template>
<i18n lang="yml">
<i18n>
en:
accountRate: Claming rate
es:

View File

@ -3,7 +3,7 @@ import { ref, computed } from 'vue';
import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import CardSummary from 'src/components/ui/CardSummary.vue';
import CardSummary from 'components/ui/CardSummary.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import { useArrayData } from 'src/composables/useArrayData';

View File

@ -3,10 +3,10 @@ import { useRoute } from 'vue-router';
import { computed, ref, watch } from 'vue';
import { useI18n } from 'vue-i18n';
import VnPaginate from 'src/components/ui/VnPaginate.vue';
import VnPaginate from 'components/ui/VnPaginate.vue';
import { useVnConfirm } from 'src/composables/useVnConfirm';
import { useArrayData } from 'src/composables/useArrayData';
import { useVnConfirm } from 'composables/useVnConfirm';
import { useArrayData } from 'composables/useArrayData';
import useNotify from 'src/composables/useNotify.js';
import axios from 'axios';
@ -46,13 +46,9 @@ const columns = computed(() => [
]);
const deleteAlias = async (row) => {
try {
await axios.delete(`${urlPath.value}/${row.id}`);
notify(t('User removed'), 'positive');
fetchAliases();
} catch (error) {
console.error(error);
}
};
watch(
@ -113,7 +109,7 @@ const fetchAliases = () => paginateRef.value.fetch();
</QPage>
</template>
<i18n lang="yml">
<i18n>
es:
User will be removed from alias: El usuario será borrado del alias
Are you sure you want to continue?: ¿Seguro que quieres continuar?

View File

@ -3,7 +3,7 @@ import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelectEnum from 'src/components/common/VnSelectEnum.vue';
import FormModel from 'src/components/FormModel.vue';
import FormModel from 'components/FormModel.vue';
import VnInput from 'src/components/common/VnInput.vue';
import { ref, watch } from 'vue';

View File

@ -1,6 +1,6 @@
<script setup>
import { useI18n } from 'vue-i18n';
import VnCard from 'src/components/common/VnCard.vue';
import VnCard from 'components/common/VnCard.vue';
import AccountDescriptor from './AccountDescriptor.vue';
const { t } = useI18n();

View File

@ -2,7 +2,7 @@
import { ref, computed } from 'vue';
import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import CardDescriptor from 'src/components/ui/CardDescriptor.vue';
import CardDescriptor from 'components/ui/CardDescriptor.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import useCardDescription from 'src/composables/useCardDescription';
import AccountDescriptorMenu from './AccountDescriptorMenu.vue';
@ -108,7 +108,7 @@ const hasAccount = ref(false);
margin-top: 0;
}
</style>
<i18n lang="yml">
<i18n>
en:
accountRate: Claming rate
es:

View File

@ -2,7 +2,7 @@
import axios from 'axios';
import { computed, ref, toRefs } from 'vue';
import { useI18n } from 'vue-i18n';
import { useVnConfirm } from 'src/composables/useVnConfirm';
import { useVnConfirm } from 'composables/useVnConfirm';
import { useRoute } from 'vue-router';
import { useAcl } from 'src/composables/useAcl';
import { useArrayData } from 'src/composables/useArrayData';

View File

@ -3,11 +3,11 @@ import { computed, ref, watch, onMounted, nextTick } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRoute } from 'vue-router';
import VnPaginate from 'src/components/ui/VnPaginate.vue';
import VnPaginate from 'components/ui/VnPaginate.vue';
import AccountMailAliasCreateForm from './AccountMailAliasCreateForm.vue';
import { useVnConfirm } from 'src/composables/useVnConfirm';
import { useArrayData } from 'src/composables/useArrayData';
import { useVnConfirm } from 'composables/useVnConfirm';
import { useArrayData } from 'composables/useArrayData';
import useNotify from 'src/composables/useNotify.js';
import axios from 'axios';
@ -61,23 +61,15 @@ const fetchAccountExistence = async () => {
};
const deleteMailAlias = async (row) => {
try {
await axios.delete(`${urlPath}/${row.id}`);
fetchMailAliases();
notify(t('Unsubscribed from alias!'), 'positive');
} catch (error) {
console.error(error);
}
};
const createMailAlias = async (mailAliasFormData) => {
try {
await axios.post(urlPath, mailAliasFormData);
notify(t('Subscribed to alias!'), 'positive');
fetchMailAliases();
} catch (error) {
console.error(error);
}
};
const fetchMailAliases = async () => {
@ -182,7 +174,7 @@ onMounted(async () => await getAccountData(false));
</QPage>
</template>
<i18n lang="yml">
<i18n>
es:
Unsubscribed from alias!: ¡Desuscrito del alias!
Subscribed to alias!: ¡Suscrito al alias!

View File

@ -4,9 +4,9 @@ import { useI18n } from 'vue-i18n';
import { useRoute } from 'vue-router';
import VnSelect from 'src/components/common/VnSelect.vue';
import FetchData from 'src/components/FetchData.vue';
import VnRow from 'src/components/ui/VnRow.vue';
import FormPopup from 'src/components/FormPopup.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import FormPopup from 'components/FormPopup.vue';
const emit = defineEmits(['onSubmitCreateAlias']);

Some files were not shown because too many files have changed in this diff Show More