Compare commits

...

412 Commits

Author SHA1 Message Date
Robert Ferrús 55fced363e Merge branch 'master' into 8169-itemTextureTag
gitea/salix/pipeline/pr-master This commit looks good Details
2024-11-12 07:42:58 +00:00
Guillermo Bonet 3158644032 fix: refs #7994 commented alter
gitea/salix/pipeline/head There was a failure building this commit Details
2024-11-12 07:59:07 +01:00
Alex Moreno 732dd02a19 Merge pull request '8179-testToMaster' (!3176) from 8179-testToMaster into master
gitea/salix/pipeline/head There was a failure building this commit Details
Reviewed-on: #3176
Reviewed-by: Guillermo Bonet <guillermo@verdnatura.es>
2024-11-12 06:41:51 +00:00
Pablo Natek ffe947c73d Merge pull request 'fix: refs #7404 remove volume from ticket sold on holland' (!3169) from 7404-fix-remove-tickets-volume into test
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-dev This commit looks good Details
gitea/salix/pipeline/pr-master This commit looks good Details
Reviewed-on: #3169
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-11-12 06:31:32 +00:00
Pablo Natek 3d3bc0dbaa Merge branch 'test' into 7404-fix-remove-tickets-volume
gitea/salix/pipeline/pr-test This commit looks good Details
2024-11-12 06:24:06 +00:00
Pablo Natek 395e6997dd Merge branch '7404-fix-remove-tickets-volume' of https://gitea.verdnatura.es/verdnatura/salix into 7404-fix-remove-tickets-volume
gitea/salix/pipeline/pr-test This commit looks good Details
2024-11-12 07:23:47 +01:00
Pablo Natek 2dd3ae1c75 fix: refs #7404 empty commit 2024-11-12 07:23:46 +01:00
Alex Moreno c8d9cfd623 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix into test
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-master This commit looks good Details
2024-11-11 14:09:03 +01:00
Pako Natek b62b33d175 Merge pull request 'fix(collection_new): remove agency condition for suitable tickets' (!3171) from hotFix-remove-notOwn-agency-collection-advantage into master
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3171
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-11-11 10:02:42 +00:00
Pako Natek 35f4f161ab fix(collection_new): remove agency condition for suitable tickets
gitea/salix/pipeline/pr-master This commit looks good Details
Refs: #0000
2024-11-11 09:02:04 +01:00
Pablo Natek 82e62e8ee7 Merge branch 'test' into 7404-fix-remove-tickets-volume 2024-11-11 05:53:30 +00:00
Pablo Natek f8c3d69c5d fix: refs #7404 remove volume from ticket sold on holland
gitea/salix/pipeline/pr-test This commit looks good Details
2024-11-08 13:44:20 +01:00
Javi Gallego d95e455ccf fix: refs #7935 sin modificar autonomy
gitea/salix/pipeline/head This commit looks good Details
2024-11-07 14:48:31 +01:00
Guillermo Bonet 765d125219 Merge branch 'master' into test
gitea/salix/pipeline/head This commit looks good Details
2024-10-28 07:11:21 +01:00
Alex Moreno 4660118211 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix into test
gitea/salix/pipeline/head This commit looks good Details
2024-10-24 07:47:41 +02:00
Guillermo Bonet fc56dbc5fb Merge branch 'master' into test
gitea/salix/pipeline/head This commit looks good Details
2024-10-23 12:44:35 +02:00
Guillermo Bonet fe3e7342bc fix: refs #7935 version
gitea/salix/pipeline/pr-dev This commit looks good Details
gitea/salix/pipeline/head This commit looks good Details
2024-10-23 07:14:07 +02:00
Alex Moreno f47043cae4 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix into test
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-22 15:07:24 +02:00
Alex Moreno db8573dd40 Merge pull request '8144-devToTest_2444' (!3137) from 8144-devToTest_2444 into test
gitea/salix/pipeline/pr-dev This commit looks good Details
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3137
Reviewed-by: Carlos Satorres <carlossa@verdnatura.es>
2024-10-22 06:07:14 +00:00
Carlos Satorres 56cba385cf Merge pull request 'fix: refs #6850 remove notifyPickUp' (!3132) from 6850-removeChandgeUpdateClaim into dev
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-test This commit looks good Details
Reviewed-on: #3132
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 12:31:30 +00:00
Carlos Satorres aad616ff83 Merge branch 'dev' into 6850-removeChandgeUpdateClaim
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-21 12:26:53 +00:00
Carlos Satorres f8c83c8f68 Merge pull request 'fix: refs #6831 filter observation' (!3131) from 6831-observationDefaulterEmail into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3131
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 12:26:04 +00:00
Carlos Satorres c3ffb31348 Merge branch 'dev' into 6831-observationDefaulterEmail
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-21 12:23:39 +00:00
Jorge Penadés b76b1c6d50 Merge pull request '#7919 delete if ticketRefund' (!3091) from 7919-deleteTicketRefund into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3091
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 11:21:34 +00:00
Jorge Penadés 2f77359892 Merge branch 'dev' into 7919-deleteTicketRefund
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-21 11:00:31 +00:00
Pablo Natek 69a34ab0fa Merge pull request 'fix: add date format on insert data' (!3135) from fixNightProc into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3135
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-21 10:25:41 +00:00
Pablo Natek 1731af13ea Merge branch 'fixNightProc' of https://gitea.verdnatura.es/verdnatura/salix into fixNightProc
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-21 12:19:22 +02:00
Pablo Natek e479873547 fix: restore cursor 2024-10-21 12:19:20 +02:00
Pablo Natek 92f699aac3 Merge branch 'dev' into fixNightProc
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-21 09:37:07 +00:00
Pablo Natek e38c061deb fix: add date format on insert data
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-21 11:36:44 +02:00
Jon Elias d75a032d75 Merge pull request 'Added new filter param in item request' (!3094) from Fix-ItemRequest into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3094
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-21 09:34:53 +00:00
Jon Elias 158f701f1e Merge branch 'dev' into Fix-ItemRequest
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-21 09:31:29 +00:00
Carlos Satorres bf0cc687e1 Merge branch 'dev' into 6850-removeChandgeUpdateClaim
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-21 07:27:46 +00:00
Guillermo Bonet 5d55fb287d Merge branch 'test' into dev
gitea/salix/pipeline/head Build queued... Details
2024-10-21 09:25:39 +02:00
Guillermo Bonet dead904c19 Merge branch 'master' into test
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-21 09:25:29 +02:00
Carlos Satorres eea09a9d4a fix: refs #6850 add code
gitea/salix/pipeline/pr-dev Build queued... Details
2024-10-21 09:24:53 +02:00
Javi Gallego be9f711cc1 Merge pull request 'feat: refs #7348 hasDailyInvoice from client' (!3110) from 7348-autonomyDailyInvoice into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3110
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 06:31:17 +00:00
Carlos Satorres 19fbb836a6 fix: refs #6850 fix model
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-21 08:30:39 +02:00
Javi Gallego da772cf504 Merge pull request '7744-closeAllTest' (!3114) from 7744-closeAllTest into dev
gitea/salix/pipeline/head There was a failure building this commit Details
Reviewed-on: #3114
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-21 06:29:17 +00:00
Carlos Satorres b88dc1c70f fix: refs #6850 remove notifyPickUp
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-20 16:23:24 +02:00
Carlos Satorres b8e782d3a5 fix: refs #6831 filter observation
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-20 15:59:24 +02:00
Jon Elias 9e9773578a Merge branch 'dev' into Fix-ItemRequest
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 11:22:35 +00:00
Carlos Satorres a5bbdd7a01 Merge pull request 'fix: refs #7906 remake method' (!3109) from 7906-notDeleteZone into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3109
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-18 08:33:03 +00:00
Carlos Satorres ed69604767 Merge branch 'dev' into 7906-notDeleteZone
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 08:31:38 +00:00
Guillermo Bonet 939f083671 Merge pull request 'refactor: refs #8106 Optimized ticket_getTax' (!3122) from 8106-negativeBasesOptimize into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3122
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-10-18 08:27:08 +00:00
Jon Elias 35621e9051 Merge pull request '#7010 added filter fields to show packing type field in ticket list' (!3024) from 7010-AddPackingField into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3024
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-18 07:40:35 +00:00
Carlos Satorres 5a14aed73a Merge branch 'dev' into 7906-notDeleteZone
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 07:40:04 +00:00
Jon Elias 3139d99130 Merge branch 'dev' into 7010-AddPackingField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 07:30:43 +00:00
Guillermo Bonet 46c7745128 Merge pull request 'refactor: refs #7811 Deleted pm2' (!3127) from 7811-byePm2 into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3127
Reviewed-by: Juan Ferrer <juan@verdnatura.es>
2024-10-18 07:30:13 +00:00
Jon Elias 46993ad103 refactor: refs #7010 deleted distinct
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 09:29:01 +02:00
Carlos Satorres 1273e895af fix: refs #7906 fix test back
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-18 09:27:43 +02:00
Carlos Satorres 8609e85ba1 Merge pull request '7986-workerMoto' (!3095) from 7986-workerMoto into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3095
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-18 07:24:49 +00:00
Carlos Satorres 50a2f6081e Merge branch 'dev' into 7986-workerMoto
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 07:20:06 +00:00
Jon Elias f68584b3fa Merge branch 'dev' into Fix-ItemRequest
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 06:53:38 +00:00
Carlos Satorres 02dc952024 fix: refs #7906 add test
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 08:28:08 +02:00
Ivan Mas d7fd1b7ee5 Merge pull request 'refactor: refs #7865 delete client.gestdocFk from TPV' (!3123) from 7865-deleteClientGestdocFkTPV into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3123
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-18 06:22:58 +00:00
Ivan Mas f4b041c9b1 Merge branch 'dev' into 7865-deleteClientGestdocFkTPV
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 06:20:38 +00:00
Guillermo Bonet 44dc84be9f Merge branch 'dev' into 7811-byePm2
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 06:02:20 +00:00
Guillermo Bonet 93494c3eb0 refactor: refs #7811 Deleted pm2
gitea/salix/pipeline/pr-dev Build queued... Details
2024-10-18 08:02:06 +02:00
Carlos Satorres b15b2d578d Merge pull request 'fix: refs #7230 producer fix' (!3112) from 7230-deliveryNoteProducer into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3112
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-18 05:56:29 +00:00
Carlos Satorres 541990efb7 Merge branch 'dev' into 7230-deliveryNoteProducer
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 05:53:34 +00:00
Guillermo Bonet 865da7bba2 refactor: refs #8106 Requested changes
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-18 07:15:26 +02:00
Alex Moreno d93653372a Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-18 07:12:18 +02:00
Alex Moreno 08e22db950 Merge pull request 'master' (!3125) from master into test
gitea/salix/pipeline/pr-dev This commit looks good Details
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3125
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-18 05:09:32 +00:00
Guillermo Bonet 5017b344d4 Merge pull request 'refactor: refs #7930 Deleted HEALTHCHECK of back dockerfile' (!3118) from 7930-healthcheckDockerfile into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3118
Reviewed-by: Juan Ferrer <juan@verdnatura.es>
2024-10-18 05:06:52 +00:00
Ivan Mas 7dc35458e8 refactor: refs #7865 delete client.gestdocFk from TPV
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-17 17:05:08 +02:00
Guillermo Bonet 28e957fecd refactor: refs #8106 refs #1406 Optimized ticket_getTax
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-17 14:46:19 +02:00
Guillermo Bonet a188efb1e3 refactor: refs #7930 Deleted HEALTHCHECK of back dockerfile
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-17 11:45:13 +02:00
Javi Gallego 681f82a3ae feat: refs #7744 test back ok
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 16:09:53 +02:00
Carlos Satorres 37d3ef5f16 Merge branch 'dev' into 7986-workerMoto
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 12:10:13 +00:00
Carlos Satorres 3f3b936255 fix: refs #7906 remove code
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 13:56:42 +02:00
Carlos Satorres 5de4a11e8b fix: refs #7230 fix line
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 13:53:20 +02:00
Carlos Satorres 3e443ad5ce fix: refs #7230 producer fix
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 12:22:57 +02:00
Carlos Satorres a282170016 fix: refs #7906 fix method
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 11:36:48 +02:00
Alex Moreno cb7575d821 Merge pull request 'fix: refs #7353 redirect to lilium' (!3111) from 7353-fixRedirect into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3111
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-16 07:39:10 +00:00
Jorge Penadés 8f01e4d110 fix: refs #7353 redirect to lilium
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 09:32:15 +02:00
Carlos Satorres c5aa7dc44e fix: refs #7906 edit test
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 09:30:37 +02:00
Jorge Penadés 8ca097d4a9 chore: refs #7919 change var name
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 09:23:39 +02:00
Javi Gallego f78aad0874 Merge branch 'dev' into 7744-closeAllTest 2024-10-16 09:09:41 +02:00
Javi Gallego aac4dd0a6d feat: refs #7348 minor bug
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 08:52:27 +02:00
Javi Gallego c6e764b478 feat: refs #7348 hasDailyInvoice from client
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-16 08:32:10 +02:00
Carlos Satorres 46e657675b fix: refs #7906 remake method
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-16 08:26:39 +02:00
Sergio De la torre a989bef78c Merge pull request 'master' (!3108) from master into test
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-dev This commit looks good Details
Reviewed-on: #3108
Reviewed-by: Robert Ferrús <robert@verdnatura.es>
2024-10-16 06:16:36 +00:00
Jorge Penadés d57f4fc44a chore: refs #7919 refactor, drop relation on back
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-15 17:24:14 +02:00
Jorge Penadés 6f8a005726 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7919-deleteTicketRefund
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-15 17:01:29 +02:00
Javi Gallego 4a88ba5078 feat: refs #7744 closeAll Test 2024-10-15 15:43:12 +02:00
Carlos Satorres 099fe8f950 fix: refs #7986 fix model
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-15 14:42:35 +02:00
Guillermo Bonet 5a2058865d Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-15 14:02:39 +02:00
Ivan Mas 6cb8bea783 Merge pull request 'feat: refs #7994 update sale.originalQuantity' (!3104) from 7994-sale.originalQuantity into test
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-dev This commit looks good Details
Reviewed-on: #3104
Reviewed-by: Guillermo Bonet <guillermo@verdnatura.es>
2024-10-15 12:01:02 +00:00
Ivan Mas 536c2fa5b5 feat: refs #7994 update sale.originalQuantity
gitea/salix/pipeline/pr-test This commit looks good Details
2024-10-15 13:54:02 +02:00
Carlos Satorres c73fd51a9c fix: refs #7986 add acl
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-15 09:45:14 +02:00
Alex Moreno 85f8b6fd20 build: init version 24.44
gitea/salix/pipeline/head This commit looks good Details
2024-10-15 09:29:38 +02:00
Alex Moreno 6eab66340f Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-15 09:21:31 +02:00
Javi Gallego 36bf2f89c7 Merge pull request '8098-closureTransation' (!3101) from 8098-closureTransation into dev
gitea/salix/pipeline/head There was a failure building this commit Details
Reviewed-on: #3101
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-15 07:20:06 +00:00
Alex Moreno cf78a12f3a fix(sql): addClientObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
gitea/salix/pipeline/head This commit looks good Details
2024-10-15 09:18:20 +02:00
Alex Moreno 8ff06d63c5 fix(sql): addClientObservationType
gitea/salix/pipeline/head There was a failure building this commit Details
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-15 09:16:07 +02:00
Jon Elias e334152acc refactor: deleted comment
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-15 09:03:15 +02:00
Alex Moreno a2b9a59eb5 fix(sql): addClientObservationType
gitea/salix/pipeline/head There was a failure building this commit Details
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-15 08:58:57 +02:00
Alex Moreno f61c2fa083 Merge pull request '8093-devToTest_2442_3' (!3100) from 8093-devToTest_2442_3 into test
gitea/salix/pipeline/pr-dev This commit looks good Details
gitea/salix/pipeline/head There was a failure building this commit Details
Reviewed-on: #3100
Reviewed-by: Carlos Satorres <carlossa@verdnatura.es>
2024-10-15 06:51:41 +00:00
Javi Gallego c5f987d04c fix: refs #8098 renew token test fixed
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-15 08:44:08 +02:00
Javi Gallego 976e50b566 feat: refs #8098 identation
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-15 08:25:53 +02:00
Javi Gallego 4526873bbe feat: refs #8098 without Date 2024-10-15 08:24:13 +02:00
Javi Gallego 5e2edad6de Merge branch 'dev' into 8098-closureTransation 2024-10-15 08:21:40 +02:00
Alex Moreno 63f062a069 fix(renewToken): refs #8093 test & fix(sql) addClientObservationType
gitea/salix/pipeline/pr-test This commit looks good Details
2024-10-15 08:19:35 +02:00
Javi Gallego f2d1aa5f16 feat: refs #8098 closureDaysAgo 2024-10-15 08:17:03 +02:00
Alex Moreno 5b938a6f78 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head There was a failure building this commit Details
gitea/salix/pipeline/pr-test This commit looks good Details
2024-10-15 08:00:39 +02:00
Sergio De la torre f27566ac0f Merge pull request 'master' (!3098) from master into test
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
Reviewed-on: #3098
Reviewed-by: Robert Ferrús <robert@verdnatura.es>
2024-10-15 05:18:30 +00:00
Jorge Penadés 6d4c71d465 feat: refs #7919 test
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-14 17:14:40 +02:00
Jorge Penadés a35208d903 feat: refs #7919 test 2024-10-14 17:14:01 +02:00
Jorge Penadés ccf9dbde8e feat: refs #7919 test
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-14 17:11:12 +02:00
Jorge Penadés 32756dabae Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7919-deleteTicketRefund
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-14 16:49:11 +02:00
Jorge Penadés 48e4c68561 Merge pull request '#7874 clientObservationType' (!2960) from 7874-createObservationType into dev
gitea/salix/pipeline/head Build queued... Details
Reviewed-on: #2960
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-14 14:16:40 +00:00
Jorge Penadés 0549e22720 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-14 15:38:30 +02:00
Jorge Penadés d02e942dd2 Merge pull request 'feat: refs #7323 show right error' (!3096) from 7323-showRightError into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3096
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-14 13:31:59 +00:00
Jorge Penadés cedb1b570d Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-showRightError
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-14 14:42:37 +02:00
Jorge Penadés f3b5a70b67 feat: refs #7323 show right error
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-14 14:41:25 +02:00
Alex Moreno e0b252e6bb Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-14 14:12:16 +02:00
Alex Moreno 0063591089 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix into test
gitea/salix/pipeline/head This commit looks good Details
2024-10-14 14:11:57 +02:00
Carlos Satorres 68469e2ba8 Merge branch 'dev' of https: refs #7986//gitea.verdnatura.es/verdnatura/salix into 7986-workerMoto
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-14 13:52:08 +02:00
Jon Elias 07849ebeb8 fix: myTeam param
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-14 13:25:09 +02:00
Jon Elias 4ee6a46bd5 feat: added new filter param
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-14 11:29:49 +02:00
Jorge Penadés b39a749bee Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-14 08:37:58 +02:00
Alex Moreno d8e0c1debe Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-14 07:27:19 +02:00
Jorge Penadés 770c604d6b chore: refs #7919 delete if ticketRefund
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-10 16:30:04 +02:00
Jorge Penadés 295c31a5f0 feat: refs #7874 add finance obs type
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-10 11:01:25 +02:00
Jorge Penadés 2b17e6da4c Merge branch 'dev' into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-10 08:16:29 +00:00
Jorge Penadés 9a7aa315e5 Merge pull request 'feat: refs #7207 show queue in worker summary' (!3007) from 7207-showPbx into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3007
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-10 07:20:17 +00:00
Jorge Penadés f5a43962fd Merge branch 'dev' into 7207-showPbx
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-10 07:18:06 +00:00
Pako Natek 209e65180e Merge pull request 'feat: refs #8075 itemShelvingMoving' (!3089) from 8075-test-itemShelvingMoving into test
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3089
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-10-10 05:36:06 +00:00
Pako Natek 5eda0af20f feat: refs #8075 itemShelvingMoving
gitea/salix/pipeline/pr-test This commit looks good Details
2024-10-09 07:24:34 +02:00
Alex Moreno 040304d04f fix: merge
gitea/salix/pipeline/head This commit looks good Details
2024-10-08 17:10:19 +02:00
Alex Moreno 0c6541372e Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix into test 2024-10-08 17:09:26 +02:00
Carlos Satorres 39e808bca7 fix: refs #7986 fix model 2024-10-08 16:06:38 +02:00
Carlos Andrés d497ffc781 Actualizar modules/ticket/back/methods/ticket/closure.js
gitea/salix/pipeline/head This commit looks good Details
2024-10-08 13:32:57 +00:00
Alex Moreno 02adc6473a fix: duplicate variable
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-test This commit looks good Details
2024-10-08 12:22:47 +02:00
Alex Moreno 5cdb0b7eb6 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head There was a failure building this commit Details
gitea/salix/pipeline/pr-test There was a failure building this commit Details
2024-10-08 12:19:10 +02:00
Alex Moreno f8a3527680 Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix into test
gitea/salix/pipeline/head This commit looks good Details
2024-10-08 12:17:02 +02:00
Carlos Satorres b4dc5276dd fix: refs #7986 create fk 2024-10-08 08:36:17 +02:00
Guillermo Bonet 023842ac33 feat: refs #7994 comment changes
gitea/salix/pipeline/head This commit looks good Details
2024-10-08 08:33:04 +02:00
Pako Natek c7269e77a6 Merge pull request 'feat: refs #8075 itemShelving' (!3081) from 8075-itemShelvingMoving into dev
gitea/salix/pipeline/head There was a failure building this commit Details
Reviewed-on: #3081
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-08 05:48:05 +00:00
Pako Natek ff43533b5a Merge branch 'dev' into 8075-itemShelvingMoving
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-08 05:33:14 +00:00
Pako Natek 34f85fdcc4 Merge pull request 'feat: refs #8069 overStocking protocol' (!3082) from 8069-test-overStocking into test
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3082
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-08 05:32:57 +00:00
Jorge Penadés 330c1f3de6 chore: refs #7207 drop transaction
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-07 17:50:36 +02:00
Jorge Penadés ebe763dc9b Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7207-showPbx
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-07 17:45:07 +02:00
Ivan Mas 249e37f605 Merge pull request 'feat: refs #7994 update sale.originalQuantity' (!3000) from 7994-UpdateSale.OriginalQuantity into dev
gitea/salix/pipeline/head There was a failure building this commit Details
Reviewed-on: #3000
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-10-07 14:51:19 +00:00
Ivan Mas 0358157b2c Merge branch 'dev' into 7994-UpdateSale.OriginalQuantity
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-07 14:48:20 +00:00
Jorge Penadés 3755c5a15b Merge branch 'dev' into 7207-showPbx
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-07 14:27:09 +00:00
Pako Natek 22719820fd feat: refs #8069 overStocking protocol
gitea/salix/pipeline/pr-test This commit looks good Details
2024-10-07 14:21:18 +02:00
Pako Natek 12a1a065f6 Merge branch 'dev' into 8075-itemShelvingMoving
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-07 11:47:54 +00:00
Pako Natek e105fba227 feat: refs #8075 itemShelving
new field movingState
2024-10-07 13:46:56 +02:00
Pako Natek ed4dff1914 Merge pull request 'feat: refs #8075 autoupdating' (!3078) from 8075-itemShelvingMoving into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3078
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-07 08:24:30 +00:00
Pako Natek df0db41994 Merge branch 'dev' into 8075-itemShelvingMoving
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-07 07:05:35 +00:00
Pako Natek de769efc0f feat: refs #8075 autoupdating
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-07 09:05:03 +02:00
Pako Natek 2871810ec6 Merge pull request 'feat(itemShelving): refs #8075 new field' (!3077) from 8075-itemShelvingMoving into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3077
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-07 06:46:54 +00:00
Pako Natek 3cc31b7779 Merge branch 'dev' into 8075-itemShelvingMoving
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-07 06:41:45 +00:00
Jorge Penadés 6d973fd4ff Merge pull request '#7323 worker/filter' (!2978) from 7323-fineTunningWorker into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2978
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-07 06:41:31 +00:00
Pako Natek 542d0dcbd2 feat(itemShelving): refs #8075 new field
isMoving indicates the record must be transferred to another sector

Refs: #8075
2024-10-07 08:41:07 +02:00
Jorge Penadés 4fb0936399 Merge branch 'dev' into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-07 06:39:11 +00:00
Jorge Penadés 53f590af61 Merge branch 'dev' into 7207-showPbx
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-07 06:31:14 +00:00
Guillermo Bonet 701b8d3c14 Merge pull request 'refactor: refs #6824 Throw for no delete itemShelving with itemShelvingSale' (!3057) from 6824-itemShelvingSaleNoDelete into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3057
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-07 05:50:48 +00:00
Guillermo Bonet d6e2200227 Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-07 07:48:23 +02:00
Guillermo Bonet eb5da0f9cc Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-07 07:39:23 +02:00
Guillermo Bonet 7b4d15cb23 refactor: refs #6824 Requested changes
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-07 07:30:36 +02:00
Guillermo Bonet 1ae60f51dd Merge branch '6824-itemShelvingSaleNoDelete' of https://gitea.verdnatura.es/verdnatura/salix into 6824-itemShelvingSaleNoDelete
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-06 10:54:53 +02:00
Guillermo Bonet 7fc2e34af9 refactor: refs #6824 Fix tests 2024-10-06 10:54:51 +02:00
Guillermo Bonet 9a327a1c39 Merge branch 'dev' into 6824-itemShelvingSaleNoDelete
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-06 08:21:07 +00:00
Guillermo Bonet ba9d0743b5 refactor: refs #6824 Throw for no delete itemShelving with itemShelvingSale
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-06 10:20:34 +02:00
Guillermo Bonet 12bf7f07c5 Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-06 09:13:07 +02:00
Pako Natek 4b497108dc Merge pull request 'fix: refs #8069 call moved upper than transaction start' (!3075) from 8069-Overstocking into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3075
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-04 16:21:22 +00:00
Pako Natek cf29b1bd82 Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 16:19:59 +00:00
Jorge Penadés e0d0b66963 feat: refs #7207 add transaction
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-04 16:48:38 +02:00
Jorge Penadés 6fcd883f4b Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7207-showPbx
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 16:37:01 +02:00
Jorge Penadés 475d0bde38 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-04 16:12:44 +02:00
Jorge Penadés 49305f77df Merge pull request '#7353 takeout monitor' (!2866) from 7353-takeoutMonitor into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2866
Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
2024-10-04 14:11:10 +00:00
Jorge Penadés 9f97de021a chore: refs #7874 fix e2e
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 16:04:31 +02:00
Jorge Penadés 4411f0cfb3 Merge branch 'dev' into 7353-takeoutMonitor
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 13:56:49 +00:00
Pako Natek 04e5018bc9 Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 11:59:14 +00:00
Pako Natek 6766cebd2a fix: refs #8069 call moved upper than transaction start
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 13:56:54 +02:00
Jorge Penadés 3d831e290b Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 13:46:41 +02:00
Jorge Penadés e1133bcc07 Merge branch 'dev' into 7207-showPbx
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 11:45:21 +00:00
Jorge Penadés c799a9d894 Merge branch 'dev' into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 11:32:30 +00:00
Pako Natek 5d00eb793c Merge pull request 'fix: refs #8069 wrong field name' (!3063) from 8069-Overstocking into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3063
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-10-04 10:01:32 +00:00
Pako Natek e4d386c65f Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 09:47:49 +00:00
Alex Moreno f8f205a4f8 feat: update myt version
gitea/salix/pipeline/head This commit looks good Details
2024-10-04 10:29:50 +02:00
Jorge Penadés c4faac7446 Merge branch 'dev' into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 07:47:38 +00:00
Jorge Penadés 70a2189e30 Merge branch 'dev' into 7207-showPbx
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 07:46:18 +00:00
Guillermo Bonet 0b1756ff3a Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-04 09:13:53 +02:00
Carlos Satorres 505fff82a9 Merge pull request 'fix: refs #6896 remove files' (!2899) from 6896-ordersMigration into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2899
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
2024-10-04 06:40:19 +00:00
Pako Natek a6cc7cd2a5 Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 06:35:18 +00:00
Carlos Satorres 3385f4136d Merge branch 'dev' into 6896-ordersMigration
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 06:31:13 +00:00
Pablo Natek c01e5aee27 Merge pull request 'fix: refs #7404 add rounding to volume detail' (!3035) from 7404-roundDetailVolume into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3035
Reviewed-by: Javier Segarra <jsegarra@verdnatura.es>
2024-10-04 05:31:32 +00:00
Pablo Natek f019214002 Merge branch 'dev' into 7404-roundDetailVolume
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-04 05:22:07 +00:00
Pablo Natek 229d5369a1 fix: refs #7404 spec for new entry fixture
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-04 07:20:10 +02:00
Carlos Satorres db6cea6cbb Merge branch 'dev' into 6896-ordersMigration
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-04 05:19:20 +00:00
Jorge Penadés 3638e9abb6 refactor: refs #7207 simplify code
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 16:50:31 +02:00
Jorge Penadés 23d2d2b1ea Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7207-showPbx
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 15:39:37 +02:00
Jorge Penadés 5416d38255 feat: refs #7874 redirect to lilium
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 15:25:56 +02:00
Jorge Penadés 3f1de126c9 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 15:13:49 +02:00
Pablo Natek 46e2ffd6c2 fix: refs #7404 add fixtures
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 14:39:58 +02:00
Guillermo Bonet 9499819eec Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-03 12:43:21 +02:00
Pablo Natek 02f74e4215 Merge branch 'dev' into 7404-roundDetailVolume
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-03 10:08:43 +00:00
Pablo Natek 3f325d865f fix: refs #7404 test for lasEntriesFilter
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-03 12:08:23 +02:00
Pako Natek 57cd6cc882 Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 08:47:38 +00:00
Jorge Penadés 2071518f57 fix: refs #7874 rollback
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 10:35:04 +02:00
Jorge Penadés fd877119a9 chore: refs #7874 drop useless locale
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 10:34:01 +02:00
Jorge Penadés 1930bc450f Merge branch 'dev' into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 07:59:06 +00:00
Jorge Penadés 530617ce6c Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 09:57:53 +02:00
Alex Moreno cb69ed8a7b Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-03 09:56:53 +02:00
Pablo Natek 616c328681 Merge branch 'dev' into 7404-roundDetailVolume
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 07:55:51 +00:00
Guillermo Bonet 0c4637030c Merge pull request 'refactor: refs #7886 Deleted proc buy_getVolumeByAgency' (!2965) from 7886-buy_getVolumeByAgency into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2965
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-10-03 07:51:06 +00:00
Guillermo Bonet a994f0c1c1 Merge pull request 'refactor: refs #7980 Deleted table buyMark' (!3052) from 7980-byeBuyMark into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3052
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-10-03 07:49:07 +00:00
Jorge Penadés 546bb85484 Merge branch 'dev' of https: refs #7874//gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 09:27:51 +02:00
Jorge Penadés 0311069f00 Merge branch 'dev' into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 07:16:55 +00:00
Jon Elias cbc8cc6210 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7010-AddPackingField 2024-10-03 09:14:16 +02:00
Pako Natek 1b254b138e Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-03 06:40:03 +00:00
Pako Natek b34727a436 fix: refs #8069 wrong field name 2024-10-03 08:39:30 +02:00
Javi Gallego 91d9a6e417 Merge pull request '#7346 - manualInvoice' (!3060) from 7346-manualInvoice into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3060
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-03 05:45:09 +00:00
Javi Gallego 5f695f63b3 Merge pull request 'refactor: refs #7817 itemShelving_addList change' (!2882) from 7817-isChecked into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2882
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-03 05:34:44 +00:00
Javi Gallego ee52c8b45f fix: refs #7346 findByid con fields
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 15:34:53 +02:00
Javi Gallego 43df98598c feat: refs #7346 manual invoice with address 2024-10-02 15:27:09 +02:00
Pako Natek 3a5eb00a45 Merge pull request '8069-Overstocking' (!3051) from 8069-Overstocking into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3051
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-02 12:34:13 +00:00
Pako Natek abb39ec0e7 Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 12:32:45 +00:00
Pako Natek fc1ea280fa fix: refs #8069 new conception
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 14:03:57 +02:00
Guillermo Bonet a49d6aaf12 Merge branch '6824-itemShelvingSaleNoDelete' of https://gitea.verdnatura.es/verdnatura/salix into 6824-itemShelvingSaleNoDelete
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-02 11:32:23 +02:00
Guillermo Bonet 2655e20ef6 refactor: refs #6824 Throw for no delete itemShelving with itemShelvingSale 2024-10-02 11:32:20 +02:00
Carlos Satorres 5b75ffdbba Merge pull request '7366-travelMigration' (!3054) from 7366-travelMigration into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3054
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-02 09:31:42 +00:00
Carlos Satorres 1b78aa1985 Merge branch 'dev' into 7366-travelMigration
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 09:30:15 +00:00
Guillermo Bonet c4c08934a7 Merge branch 'dev' into 6824-itemShelvingSaleNoDelete
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-02 09:27:57 +00:00
Guillermo Bonet 62bd2ae03b refactor: refs #6824 Throw for no delete itemShelving with itemShelvingSale
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-02 11:27:09 +02:00
Robert Ferrús 47ed9a8f4e Merge pull request 'test' (!3056) from test into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3056
Reviewed-by: Guillermo Bonet <guillermo@verdnatura.es>
2024-10-02 09:22:26 +00:00
Carlos Satorres c8abf153e5 Merge branch 'dev' of https: refs #7366//gitea.verdnatura.es/verdnatura/salix into 7366-travelMigration
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 10:38:21 +02:00
Guillermo Bonet 724ddd5fe8 refactor: refs #7980 Deleted table buyMark
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 09:26:23 +02:00
Guillermo Bonet c15b4f1bdf Merge pull request 'feat: ref#7902 Triggers vn.ticketRefund to control deleted tickets' (!2908) from 7902-Trigger-ticketRefund-para-no-añadir-ticket-eliminado into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2908
Reviewed-by: Guillermo Bonet <guillermo@verdnatura.es>
2024-10-02 07:10:31 +00:00
Guillermo Bonet 26a9e8ca50 Merge branch '7902-Trigger-ticketRefund-para-no-añadir-ticket-eliminado' of https://gitea.verdnatura.es/verdnatura/salix into 7902-Trigger-ticketRefund-para-no-añadir-ticket-eliminado
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 09:09:05 +02:00
Guillermo Bonet b556903d6d feat: refs #7902 Changed definer and throw msg 2024-10-02 09:09:04 +02:00
Guillermo Bonet 2baf433d1a Merge branch 'dev' into 7902-Trigger-ticketRefund-para-no-añadir-ticket-eliminado
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 07:07:48 +00:00
Guillermo Bonet 9ba017d352 feat: refs #7902 Changed definer and throw msg
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 09:06:21 +02:00
Pako Natek b53f6d4008 Merge branch 'dev' into 8069-Overstocking
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 06:53:43 +00:00
Pako Natek 9d84c39fce feat: refs #8069 orderRow_updateOverstocking
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 08:52:20 +02:00
Guillermo Bonet dc0a4f35f3 Merge branch 'dev' into 7886-buy_getVolumeByAgency
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 05:36:02 +00:00
Jon Elias 2fbf8478c0 Merge pull request '#7884 added new filter field' (!2981) from 7884-AddLabelerField into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2981
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-02 05:04:17 +00:00
Jon Elias 2267b2c6b1 Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-02 04:55:56 +00:00
Pablo Natek 48c387be75 Merge pull request 'refactor: refs #7404 deprecated stockBuyed' (!3046) from 7404-deprecateStockBuyedAndRelatedProcs into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3046
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-01 13:57:53 +00:00
Javi Gallego 40512ca67e feat: existingRefund without ticketRefunds
gitea/salix/pipeline/head This commit looks good Details
2024-10-01 15:49:51 +02:00
Jon Elias d73f790221 Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-01 13:10:19 +00:00
Jon Elias b7b5334a99 refactor: refs #7884 modified filter
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-01 15:08:42 +02:00
Pablo Natek c6a823e6aa Merge branch 'dev' into 7404-deprecateStockBuyedAndRelatedProcs
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-01 13:05:54 +00:00
Pablo Natek 435fec03da refactor: refs #7404 deprecated stockBuyed
gitea/salix/pipeline/pr-dev Build queued... Details
2024-10-01 15:05:02 +02:00
Pako Natek 03ea7580d8 feat: refs #8069 new proc 2024-10-01 15:02:24 +02:00
Pako Natek fd262e32c1 feat: refs #8069 new trigger hedera.orderRow_afterInsert 2024-10-01 14:25:10 +02:00
Pako Natek 304992e7cf feat: refs #8069 starting branch 2024-10-01 13:40:33 +02:00
Guillermo Bonet e2d30ef933 Merge pull request 'fix: refs #7935 Fix boolens' (!3044) from 7935-fixBool into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3044
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-10-01 10:48:36 +00:00
Guillermo Bonet 0525081c52 Merge branch 'dev' into 7935-fixBool
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-01 10:46:48 +00:00
Javi Gallego aba70f4a82 Merge pull request 'feat: refs #6722 fixtures' (!3027) from 9722-travelThermographTrigger into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3027
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-01 10:41:20 +00:00
Carlos Satorres 99bd78db36 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7366-travelMigration 2024-10-01 12:40:12 +02:00
Carlos Satorres 0740acfb91 fix: refs #7366 remove back Travel 2024-10-01 12:38:52 +02:00
Carlos Satorres 5c3d1ca531 Merge pull request 'feat: refs #7354 deleted code and redirect to Lilium' (!2906) from 7354_ZoneMigration_End into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2906
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-10-01 10:32:45 +00:00
Carlos Satorres 9b41b3e54b Merge branch 'dev' into 7354_ZoneMigration_End
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-01 10:31:19 +00:00
Javi Gallego 4c9a199418 Merge branch 'dev' into 9722-travelThermographTrigger
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-01 12:29:55 +02:00
Alex Moreno f54a9a1348 fix(fixtures): revert bad merge master to test
gitea/salix/pipeline/head This commit looks good Details
2024-10-01 12:27:16 +02:00
Carlos Satorres 48ade26595 Merge branch 'dev' into 7354_ZoneMigration_End
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-01 10:20:59 +00:00
Javi Gallego 863c9ec068 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-01 12:19:53 +02:00
Javi Gallego 6685ade299 fix: getSimilar daysInforward 2024-10-01 12:19:51 +02:00
Carlos Satorres ca8cffff94 Merge branch 'dev' into 7354_ZoneMigration_End
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-01 09:37:19 +00:00
Alex Moreno c2e89002cd Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-01 11:31:47 +02:00
Guillermo Bonet 19dcedbce5 fix: refs #7935 Fix boolens
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-01 11:31:35 +02:00
Guillermo Bonet 4243cdbf50 fix: refs #7817 Tests back
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-10-01 09:18:16 +02:00
Guillermo Bonet f94ace05cc Merge branch 'dev' into 7817-isChecked
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-01 06:59:43 +00:00
Guillermo Bonet 45e87a5d94 Merge branch 'test' into dev
gitea/salix/pipeline/head This commit looks good Details
2024-10-01 08:53:10 +02:00
Guillermo Bonet 94636e1c19 Merge branch 'dev' into 7817-isChecked
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-10-01 05:56:48 +00:00
Javi Gallego 36e1cfd51a fix: myOptions error
gitea/salix/pipeline/head This commit looks good Details
2024-09-30 15:47:50 +02:00
Alex Moreno 61f806b0c9 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-09-30 14:40:35 +02:00
Carlos Andrés 41af809917 feat: ref#7902 Triggers vn.ticketRefund to control deleted tickets
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 14:33:58 +02:00
Jon Elias b55db4bdc0 feat: refs #7010 added subquery to avoid using group by in sql
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 14:09:57 +02:00
Pako Natek de3d7fc925 Merge pull request 'feat(collection_new): refs #8058 urgent state' (!3038) from 8058-Tickets-Urgentes into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3038
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-09-30 12:01:16 +00:00
Pako Natek 54d9125c21 feat(collection_new): refs #8058 urgent state
gitea/salix/pipeline/pr-dev This commit looks good Details
Urgent tickets will be priorized as asigned ones

Refs: #8058
2024-09-30 13:49:06 +02:00
Jon Elias c4f26094d5 fix: refs #7884 fixed filter
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 12:46:41 +02:00
Pako Natek 477c7f7903 Merge pull request 'fix: refs #8030 buyer prefers to add multiple zoneGeoFk' (!3037) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3037
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-09-30 10:30:47 +00:00
Pako Natek e6e7876fb1 Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 10:26:54 +00:00
Jon Elias eacc2d5d2a Merge branch '7884-AddLabelerField' of https://gitea.verdnatura.es/verdnatura/salix into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-30 12:07:56 +02:00
Jon Elias c680c4a059 refactor: refs #7884 modified sql 2024-09-30 12:07:55 +02:00
Pako Natek 2962bd13c7 fix: refs #8030 buyer prefers to add multiple zoneGeoFk
gitea/salix/pipeline/pr-dev This commit looks good Details
Instead of choosing the deepest zoneGeo, buyer wants all to be merged

Refs: #8030
2024-09-30 11:59:22 +02:00
Pako Natek de93e477f8 Merge pull request 'feat(previaDelta): refs #8030 new algorithym for coincident records' (!3036) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3036
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-09-30 08:32:44 +00:00
Pako Natek 1e64028b02 Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 08:25:27 +00:00
Pako Natek 25680994dd feat(previaDelta): refs #8030 new algorithym for coincident records
gitea/salix/pipeline/pr-dev Build queued... Details
when many records target the same zoneGeoFk, the deepest must be chosen

Refs: #8030
2024-09-30 10:24:45 +02:00
Pablo Natek 751c0ee39e Merge branch 'dev' into 7404-roundDetailVolume
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-30 08:17:22 +00:00
Pablo Natek e7d07e496e fix: refs #7404 add rounding to volume detail
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 10:16:45 +02:00
Robert Ferrús 2d289bc8ac Merge pull request 'feat: refs #7981 deprecated showAgencyName' (!3016) from 7981-showAgencyName into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3016
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-09-30 06:35:23 +00:00
Robert Ferrús e6d950e33f Merge branch 'dev' into 7981-showAgencyName
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 06:31:27 +00:00
Pako Natek c2aa33bf3c Merge pull request 'feat(priceDelta): refs #8030 new field zoneGeoFk' (!3032) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3032
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-09-30 06:25:05 +00:00
Pablo Natek f7e13e8ac9 Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-30 06:21:51 +00:00
Pako Natek 95601b139b feat(priceDelta): refs #8030 new field zoneGeoFk
gitea/salix/pipeline/pr-dev This commit looks good Details
Buyers need zone restriction field for the new component bonus

Refs: #8030
2024-09-30 08:15:57 +02:00
Carlos Andrés 4156a0f0fe Merge pull request 'fix: refs #7779 refactor collection' (!3021) from 7779-refactor-collection into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3021
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
Reviewed-by: Pako Natek <pako@verdnatura.es>
2024-09-27 09:29:36 +00:00
Robert Ferrús a7c858dbba Merge branch 'dev' into 7981-showAgencyName
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-27 08:13:35 +00:00
Jon Elias b547858820 perf: refs #7010 showing field correctly
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-27 08:28:12 +02:00
Carlos Andrés 5270db2abe fix: refs #7779 refactor collection
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 17:53:54 +02:00
Carlos Andrés 0ad1d838d9 fix: refs #7779 refactor collection
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 17:44:29 +02:00
Jorge Penadés f3bf0b7432 feat: refs #7874 validate required field
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 17:20:50 +02:00
Javi Gallego 6b4b5f2338 fix: e2e not necesary
gitea/salix/pipeline/head This commit looks good Details
2024-09-26 16:26:50 +02:00
Jorge Penadés 20e894257d fix: refs #7874 rollback
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 16:07:14 +02:00
Javi Gallego f68ed48081 feat: refs #9722 testFixed
gitea/salix/pipeline/pr-dev Build queued... Details
2024-09-26 15:25:51 +02:00
Javi Gallego c825191823 feat: refs #9722 fixtures
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-26 15:22:40 +02:00
Jon Elias 4ebda1a06f feat: refs #7010 added filter fields to show packing type field in ticket list
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 14:06:45 +02:00
Carlos Andrés 0851c6fb97 fix: refs #7779 refactor collection
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 12:48:18 +02:00
Carlos Andrés eb2a30f0d9 fix: refs #7779 refactor collection
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 10:36:19 +02:00
Jorge Penadés 5e56034105 fix: refs #7323 rollback
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 09:48:07 +02:00
Jorge Penadés f62d11dab2 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 09:17:14 +02:00
Jorge Penadés d1529c808e Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 09:09:07 +02:00
Jorge Penadés 7c23acde64 feat: refs #7874 add observationTypeFk col
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-26 09:08:42 +02:00
Javi Gallego 40f3b6b67a Merge pull request '6722-thermograph' (!3019) from 6722-thermograph into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3019
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
2024-09-26 06:07:38 +00:00
Javi Gallego 6ce4ff1311 Merge branch 'dev' into 6722-thermograph
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 13:31:12 +02:00
Javi Gallego 80c6497d3c feat: refs #6722 traduccion 2024-09-25 13:29:11 +02:00
Javi Gallego 9ef44d8d8d feat: refs #6722 refactor createThermograph 2024-09-25 13:23:31 +02:00
Jorge Penadés 0cd20503d2 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 12:52:16 +02:00
Jorge Penadés 3e270befa5 chore: refs #7874 refactor table
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 12:19:12 +02:00
Alex Moreno 4f97deb0c9 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 12:08:16 +02:00
Jorge Penadés ddebd31648 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 10:57:53 +02:00
Jorge Penadés 1c42303a75 chore: refs #7207 drop useless relation
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 09:18:10 +02:00
Jorge Penadés eb0f8ec23c Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7207-showPbx
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 08:59:22 +02:00
Sergio De la torre 112aeaba91 Merge pull request 'feat: refs #7855 delete isChecked' (!3017) from 7855-BoxPicking into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3017
Reviewed-by: Robert Ferrús <robert@verdnatura.es>
2024-09-25 06:49:06 +00:00
Sergio De la torre eb85181ea0 feat: refs #7855 delete isChecked
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 08:43:38 +02:00
Sergio De la torre b776788714 feat: refs #7855 delete isChecked
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 08:35:15 +02:00
Jon Elias 26d7866ec8 Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 06:02:44 +00:00
Jon Elias 6d4614d56f Merge pull request 'fix: refs #7356 ticket weekly filter' (!2939) from 7356-FixTicketWeekly into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #2939
Reviewed-by: Carlos Andrés <carlosap@verdnatura.es>
2024-09-25 05:27:17 +00:00
Jon Elias fe178ea396 Merge branch 'dev' into 7356-FixTicketWeekly
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-25 05:24:52 +00:00
Robert Ferrús 3f81d624cb feat: refs #7981 deprecated showAgencyName
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 18:52:55 +02:00
Jorge Penadés 16b059a14a refactor: refs #7207 tab
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 15:49:45 +02:00
Jorge Penadés 02e837ebb6 feat: refs #7207 add queue on department change
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 15:43:33 +02:00
Jorge Penadés 0f8db9ee7e Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7207-showPbx
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-24 14:38:58 +02:00
Pako Natek 171033f870 Merge pull request 'fix: refs #8030 new table version' (!3014) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3014
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-09-24 12:25:35 +00:00
Pako Natek ac1d2ee48b Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 12:05:25 +00:00
Pako Natek 64376b7503 fix: refs #8030 new table version
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 14:04:29 +02:00
Pako Natek b82b3bd004 Merge pull request 'feat: refs #8030 new fields for vn.priceDelta' (!3013) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3013
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-09-24 11:59:52 +00:00
Pako Natek 785778e58a fix: refs #8030 database selected for grant
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 13:56:41 +02:00
Pako Natek e33429f474 fix: refs #8030 grant actions to buyer
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-24 13:53:24 +02:00
Pako Natek 142ee2b96f Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 11:04:54 +00:00
Pako Natek 7a343d60e6 feat: refs #8030 new fields for vn.priceDelta
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 13:04:03 +02:00
Jon Elias ae039d6ce2 Merge branch 'dev' into 7356-FixTicketWeekly
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 10:51:25 +00:00
Pako Natek 0822996f20 Merge pull request '8030-newPriceComponent' (!3012) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3012
Reviewed-by: Pablo Natek <pablone@verdnatura.es>
2024-09-24 10:39:04 +00:00
Pako Natek 403637dd8c Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 10:37:44 +00:00
Alex Moreno 63a4cb1847 Merge branch 'test' of https://gitea.verdnatura.es/verdnatura/salix into dev
gitea/salix/pipeline/head This commit looks good Details
2024-09-24 12:25:41 +02:00
Alex Moreno 4ed6f35912 build: init version 24.42
gitea/salix/pipeline/head This commit looks good Details
2024-09-24 12:24:56 +02:00
Pako Natek ed656836b1 Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 10:06:38 +00:00
Pako Natek f6e1880634 fix: refs #8030 test change
gitea/salix/pipeline/pr-dev Build queued... Details
2024-09-24 12:06:08 +02:00
Pako Natek 7e449c5716 fix: refs #8030 bugs 2024-09-24 11:54:12 +02:00
Jon Elias d221611382 Merge branch 'dev' into 7356-FixTicketWeekly
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 09:33:47 +00:00
Pablo Natek d608b3b9c8 Merge pull request '7404-fixStockBought' (!3004) from 7404-fixStockBought into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3004
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-09-24 09:32:49 +00:00
Pako Natek 47f4b2f3d4 Merge pull request 'fix: refs #8030 little bugs' (!3011) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3011
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-09-24 09:08:33 +00:00
Pako Natek 1dbf29ccd1 Merge branch 'dev' into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 09:00:57 +00:00
Pako Natek 1be5fced3c fix: refs #8030 little bugs
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 10:59:15 +02:00
Jon Elias 1e07a2fc59 Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 08:44:36 +00:00
Pako Natek 5c4849b60d Merge pull request '8030-newPriceComponent' (!3010) from 8030-newPriceComponent into dev
gitea/salix/pipeline/head This commit looks good Details
Reviewed-on: #3010
Reviewed-by: Javi Gallego <jgallego@verdnatura.es>
2024-09-24 08:43:58 +00:00
Pako Natek a39b28f1a8 Merge branch '8030-newPriceComponent' of https://gitea.verdnatura.es/verdnatura/salix into 8030-newPriceComponent
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 10:39:28 +02:00
Pako Natek 5c8f42a3ae fix: refs #8030 redmine revision updates
Changes recomended by the reviewer

Refs: #8030
2024-09-24 10:38:56 +02:00
Jorge Penadés 11b54666d0 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 10:34:16 +02:00
Pako Natek 91801b1979 fix: refs #8030 redmine revision updates
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
Changes recomended by the reviewer

Refs: #8030
2024-09-24 10:27:27 +02:00
Jorge Penadés 78b500e452 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-24 10:15:25 +02:00
Jorge Penadés c6a3004d12 feat: refs #7207 allocate new queue on dept change
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-24 10:15:01 +02:00
Pako Natek fb7208d898 fix: refs #8030 warehouse filter
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
Warehouse is also needed to make the filter

Refs: #8030
2024-09-24 09:05:30 +02:00
Pablo Natek f9b37541eb Merge branch '7404-fixStockBought' of https://gitea.verdnatura.es/verdnatura/salix into 7404-fixStockBought
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 08:55:47 +02:00
Pablo Natek a5f3dbc15a fix: refs #7404 last entries spec 2024-09-24 08:55:24 +02:00
Pako Natek acabd3e154 feat(catalog_componentCalculate): refs #8030 new component improved
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
The procedure has now the component "bonus", a special price increasing for a group of items

Refs: #8030
2024-09-24 08:50:34 +02:00
Pablo Natek bfd52b8773 Merge branch 'dev' into 7404-fixStockBought
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-24 05:31:34 +00:00
Pablo Natek 166ca42e32 Merge branch '7404-fixStockBought' of https://gitea.verdnatura.es/verdnatura/salix into 7404-fixStockBought
gitea/salix/pipeline/pr-dev Build queued... Details
2024-09-24 07:31:24 +02:00
Pablo Natek 3988eb0d97 fix: refs #7404 back and e2e 2024-09-24 07:31:22 +02:00
Jorge Penadés 6ff76fd74b feat: refs #7207 show queue in worker summary
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-23 14:40:38 +02:00
Pako Natek 9a0b487d20 feat: refs #8030 new table 2024-09-23 13:12:53 +02:00
Pablo Natek ab89c8f3ba Merge branch 'dev' into 7404-fixStockBought
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-23 08:16:16 +00:00
Pablo Natek 80985fbd56 fix: refs #7404 round data and fix specs
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-23 10:14:09 +02:00
Pablo Natek 459f6601b7 fix: refs #7404 add transaction on detail calculate
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-23 10:02:01 +02:00
Jorge Penadés 8ff0dc06fe Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-23 09:29:51 +02:00
Jon Elias 6650673c7d Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-23 06:52:00 +00:00
Ivan Mas 0bf2935c23 Merge branch 'dev' into 7994-UpdateSale.OriginalQuantity
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-22 05:29:26 +00:00
Ivan Mas 753f6d7866 feat: refs #7994 add schema
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-22 07:27:43 +02:00
Ivan Mas 1ec8d8d5a0 feat: refs #7994 update sale.originalQuantity
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-22 07:24:21 +02:00
Pablo Natek fb1e77f9c4 fix: refs #7404 fix back data source 2024-09-20 11:06:38 +02:00
Jon Elias 2fc07e651f Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-20 08:24:42 +00:00
Jon Elias fa4f75fbb9 Merge branch '7356-FixTicketWeekly' of https://gitea.verdnatura.es/verdnatura/salix into 7356-FixTicketWeekly
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-19 13:14:24 +02:00
Jon Elias b642147d82 feat: refs #7356 added new filter field 2024-09-19 13:14:22 +02:00
Carlos Satorres 6b90690924 Merge branch 'dev' into 7354_ZoneMigration_End
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-19 06:10:15 +00:00
Jorge Penadés c0c8548216 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-18 09:41:40 +02:00
Jon Elias 35358834d9 Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-18 06:23:44 +00:00
Jorge Penadés 75b7e603c9 fix: refs #7323 drop acl
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-17 16:08:51 +02:00
Jorge Penadés eb430ea5c4 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-17 15:44:19 +02:00
Jon Elias 59c6d316dd Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7884-AddLabelerField 2024-09-17 14:21:14 +02:00
Jorge Penadés 24780c4511 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-fineTunningWorker
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-17 13:27:11 +02:00
Jon Elias 33c3ceaf33 Merge branch 'dev' into 7884-AddLabelerField
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-17 10:44:30 +00:00
Jon Elias 71362baa66 feat: refs #7884 added filter when daysOnward and daysAgo have value and refactor ifs block
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-17 12:42:47 +02:00
Guillermo Bonet be30e5ae1f Merge branch 'dev' into 7817-isChecked
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-17 10:30:29 +00:00
Guillermo Bonet acdaa96211 refactor: refs #7817 Requested changes
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-17 12:30:11 +02:00
Jorge Penadés e293dff7c9 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7323-fineTunningWorker 2024-09-17 09:47:43 +02:00
Jon Elias 1d47690bb4 feat: refs #7884 added new filter field
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-17 08:31:58 +02:00
Jorge Penadés 4d0bb81632 fix: refs #7323 worker/filter
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-16 16:33:22 +02:00
Guillermo Bonet 738a390ef7 refactor: refs #7886 Deleted proc buy_getVolumeByAgency
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-16 10:08:23 +02:00
Guillermo Bonet d7e7647b52 Merge branch 'dev' into 7817-isChecked
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-16 09:17:20 +02:00
Jorge Penadés b083b267b2 Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 7874-createObservationType
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-13 11:59:51 +02:00
Jorge Penadés cfbc3692e9 feat: refs #7874 clientObservationType
gitea/salix/pipeline/pr-dev Build queued... Details
2024-09-13 11:59:28 +02:00
Carlos Satorres 757cd78cfc fix: refs #7354 fix files
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-11 14:42:21 +02:00
Carlos Satorres f696c4043d Merge branch 'dev' of https: refs #7354//gitea.verdnatura.es/verdnatura/salix into 7354_ZoneMigration_End
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-11 13:47:30 +02:00
Jon Elias 662ede981b Merge branch 'dev' into 7356-FixTicketWeekly
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-09 11:59:42 +00:00
Jon Elias 97b07ea561 fix: refs #7356 ticket weekly filter
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-09 13:56:30 +02:00
Jon Elias 3e9f472447 Merge branch 'dev' into 7354_ZoneMigration_End
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-09 05:33:34 +00:00
Jorge Penadés 30c7475fcb Merge branch 'dev' into 7353-takeoutMonitor
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-03 07:11:05 +00:00
Carlos Andrés 08c7bd2c42 feat: ref#7902 Triggers vn.ticketRefund to control deleted tickets
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-02 17:59:31 +02:00
Carlos Andrés 0ca1db7633 feat: ref#7902 Triggers vn.ticketRefund to control deleted tickets
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-02 17:57:39 +02:00
Jon Elias 0e849086a0 Merge branch 'dev' into 7354_ZoneMigration_End
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-02 11:07:42 +00:00
Jon Elias 4c29ef862f refactor: refs #7354 deleted test
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-09-02 13:05:46 +02:00
Jon Elias 943c27142f feat: refs #7354 deleted code and redirect to Lilium
gitea/salix/pipeline/pr-dev There was a failure building this commit Details
2024-09-02 13:00:22 +02:00
Carlos Satorres 0ab490f9b9 Merge branch 'dev' into 6896-ordersMigration
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-08-29 08:21:02 +00:00
Carlos Satorres 3d69d1ad62 fix: refs #6896 remove files
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-08-28 14:37:45 +02:00
Guillermo Bonet 5a22f009f2 refactor: refs #7817 itemShelving_addList change
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-08-26 14:06:10 +02:00
Jorge Penadés 6b1001ec6a feat: refs #7353 drop section
gitea/salix/pipeline/pr-dev This commit looks good Details
2024-08-19 16:29:36 +02:00
335 changed files with 1799 additions and 13765 deletions

View File

@ -32,8 +32,7 @@ RUN apt-get update \
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
samba-common-bin samba-dsdb-modules\
&& rm -rf /var/lib/apt/lists/* \
&& npm -g install pm2
&& rm -rf /var/lib/apt/lists/*
# Salix
@ -55,7 +54,4 @@ COPY \
README.md \
./
CMD ["pm2-runtime", "./back/process.yml"]
HEALTHCHECK --interval=15s --timeout=10s \
CMD curl -f http://localhost:3000/api/Applications/status || exit 1
CMD ["node", "--tls-min-v1.0", "--openssl-legacy-provider", "./loopback/server/server.js"]

View File

@ -38,7 +38,7 @@ module.exports = Self => {
{
arg: 'hasFile',
type: 'Boolean',
description: 'True if has an attached file'
description: 'True if has the original in paper'
},
{
arg: 'hasFileAttached',

View File

@ -175,6 +175,9 @@
"PrintConfig": {
"dataSource": "vn"
},
"QueueMember": {
"dataSource": "vn"
},
"ViaexpressConfig": {
"dataSource": "vn"
},

View File

@ -16,6 +16,10 @@
"name": {
"type": "string",
"required": true
},
"hasDailyInvoice": {
"type": "boolean",
"description": "Indicates if the autonomy has daily invoice enabled"
}
},
"relations": {
@ -40,4 +44,4 @@
"permission": "ALLOW"
}
]
}
}

View File

@ -28,6 +28,10 @@
},
"continentFk": {
"type": "number"
},
"hasDailyInvoice": {
"type": "boolean",
"description": "Indicates if the autonomy has daily invoice enabled"
}
},
"relations": {

View File

@ -16,6 +16,9 @@
"name": {
"type": "string",
"required": true
},
"autonomyFk": {
"type": "number"
}
},
"relations": {
@ -55,4 +58,4 @@
"permission": "ALLOW"
}
]
}
}

View File

@ -0,0 +1,38 @@
{
"name": "QueueMember",
"base": "VnModel",
"options": {
"mysql": {
"table": "pbx.queueMember"
}
},
"properties": {
"id": {
"type": "number",
"id": true
},
"queue": {
"type": "string"
},
"extension": {
"type": "string"
}
},
"relations": {
"queueRelation": {
"type": "belongsTo",
"model": "Queue",
"foreignKey": "queue",
"primaryKey": "name"
}
},
"acls": [
{
"property": "*",
"accessType": "READ",
"principalType": "ROLE",
"principalId": "employee",
"permission": "ALLOW"
}
]
}

View File

@ -1,7 +0,0 @@
apps:
- script: ./loopback/server/server.js
name: salix-back
instances: 1
max_restarts: 0
autorestart: false
node_args: --tls-min-v1.0 --openssl-legacy-provider

View File

@ -185,6 +185,7 @@ INSERT INTO `vn`.`warehouse`(`id`, `name`, `code`, `isComparative`, `isInventory
(3, 'Warehouse Three', NULL, 1, 1, 1, 1, 0, 0, 1, 1, 1, 0),
(4, 'Warehouse Four', NULL, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1),
(5, 'Warehouse Five', NULL, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0),
(6, 'Warehouse six', 'vnh', 1, 1, 1, 1, 0, 0, 1, 1, 0, 0),
(13, 'Inventory', 'inv', 1, 1, 1, 0, 0, 0, 1, 0, 0, 0),
(60, 'Algemesi', NULL, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0);
@ -387,23 +388,23 @@ INSERT INTO `vn`.`contactChannel`(`id`, `name`)
(4, 'GCN Channel'),
(5, 'The Newspaper');
INSERT INTO `vn`.`client`(`id`,`name`,`fi`,`socialName`,`contact`,`street`,`city`,`postcode`,`phone`,`mobile`,`isRelevant`,`email`,`iban`,`dueDay`,`accountingAccount`,`isEqualizated`,`provinceFk`,`hasToInvoice`,`credit`,`countryFk`,`isActive`,`gestdocFk`,`quality`,`payMethodFk`,`created`,`isToBeMailed`,`contactChannelFk`,`hasSepaVnl`,`hasCoreVnl`,`hasCoreVnh`,`riskCalculated`, `hasToInvoiceByAddress`,`isTaxDataChecked`,`isFreezed`,`creditInsurance`,`isCreatedAsServed`,`hasInvoiceSimplified`,`salesPersonFk`,`isVies`,`businessTypeFk`,`typeFk`)
INSERT INTO `vn`.`client`(`id`,`name`,`fi`,`socialName`,`contact`,`street`,`city`,`postcode`,`phone`,`mobile`,`isRelevant`,`email`,`iban`,`dueDay`,`accountingAccount`,`isEqualizated`,`provinceFk`,`hasToInvoice`,`credit`,`countryFk`,`isActive`,`quality`,`payMethodFk`,`created`,`isToBeMailed`,`contactChannelFk`,`hasSepaVnl`,`hasCoreVnl`,`hasCoreVnh`,`riskCalculated`, `hasToInvoiceByAddress`,`isTaxDataChecked`,`isFreezed`,`creditInsurance`,`isCreatedAsServed`,`hasInvoiceSimplified`,`salesPersonFk`,`isVies`,`businessTypeFk`,`typeFk`)
VALUES
(1101, 'Bruce Wayne', '84612325V', 'BATMAN', 'Alfred', '1007 MOUNTAIN DRIVE, GOTHAM', 'Gotham', 46460, 1111111111, 222222222, 1, 'BruceWayne@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1102, 'Petter Parker', '87945234L', 'SPIDER MAN', 'Aunt May', '20 INGRAM STREET, QUEENS, USA', 'Gotham', 46460, 1111111111, 222222222, 1, 'PetterParker@mydomain.com', NULL, 0, 1234567890, 0, 2, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1103, 'Clark Kent', '06815934E', 'SUPER MAN', 'lois lane', '344 CLINTON STREET, APARTAMENT 3-D', 'Gotham', 46460, 1111111111, 222222222, 1, 'ClarkKent@mydomain.com', NULL, 0, 1234567890, 0, 3, 1, 0, 19, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1104, 'Tony Stark', '06089160W', 'IRON MAN', 'Pepper Potts', '10880 MALIBU POINT, 90265', 'Gotham', 46460, 1111111111, 222222222, 1, 'TonyStark@mydomain.com', NULL, 0, 1234567890, 0, 2, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1105, 'Max Eisenhardt', '251628698', 'MAGNETO', 'Rogue', 'UNKNOWN WHEREABOUTS', 'Gotham', 46460, 1111111111, 222222222, 1, 'MaxEisenhardt@mydomain.com', NULL, 0, 1234567890, 0, 3, 1, 300, 8, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 1, NULL, 0, 0, 18, 0, 'florist','normal'),
(1106, 'DavidCharlesHaller', '53136686Q', 'LEGION', 'Charles Xavier', 'CITY OF NEW YORK, NEW YORK, USA', 'Gotham', 46460, 1111111111, 222222222, 1, 'DavidCharlesHaller@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 0, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 19, 0, 'florist','normal'),
(1107, 'Hank Pym', '09854837G', 'ANT MAN', 'Hawk', 'ANTHILL, SAN FRANCISCO, CALIFORNIA', 'Gotham', 46460, 1111111111, 222222222, 1, 'HankPym@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 0, 0, NULL, 0, 0, 19, 0, 'florist','normal'),
(1108, 'Charles Xavier', '22641921P', 'PROFESSOR X', 'Beast', '3800 VICTORY PKWY, CINCINNATI, OH 45207, USA', 'Gotham', 46460, 1111111111, 222222222, 1, 'CharlesXavier@mydomain.com', NULL, 0, 1234567890, 0, 5, 1, 300, 13, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 1, NULL, 0, 0, 19, 0, 'florist','normal'),
(1109, 'Bruce Banner', '16104829E', 'HULK', 'Black widow', 'SOMEWHERE IN NEW YORK', 'Gotham', 46460, 1111111111, 222222222, 1, 'BruceBanner@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 0, 0, NULL, 0, 0, 9, 0, 'florist','normal'),
(1110, 'Jessica Jones', '58282869H', 'JESSICA JONES', 'Luke Cage', 'NYCC 2015 POSTER', 'Gotham', 46460, 1111111111, 222222222, 1, 'JessicaJones@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, NULL, 1, 'florist','normal'),
(1111, 'Missing', NULL, 'MISSING MAN', 'Anton', 'THE SPACE, UNIVERSE FAR AWAY', 'Gotham', 46460, 1111111111, 222222222, 1, NULL, NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 0, 1, 0, NULL, 1, 0, NULL, 0, 'others','loses'),
(1112, 'Trash', NULL, 'GARBAGE MAN', 'Unknown name', 'NEW YORK CITY, UNDERGROUND', 'Gotham', 46460, 1111111111, 222222222, 1, NULL, NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, NULL, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 0, 1, 0, NULL, 1, 0, NULL, 0, 'others','loses');
(1101, 'Bruce Wayne', '84612325V', 'BATMAN', 'Alfred', '1007 MOUNTAIN DRIVE, GOTHAM', 'Gotham', 46460, 1111111111, 222222222, 1, 'BruceWayne@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1102, 'Petter Parker', '87945234L', 'SPIDER MAN', 'Aunt May', '20 INGRAM STREET, QUEENS, USA', 'Gotham', 46460, 1111111111, 222222222, 1, 'PetterParker@mydomain.com', NULL, 0, 1234567890, 0, 2, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1103, 'Clark Kent', '06815934E', 'SUPER MAN', 'lois lane', '344 CLINTON STREET, APARTAMENT 3-D', 'Gotham', 46460, 1111111111, 222222222, 1, 'ClarkKent@mydomain.com', NULL, 0, 1234567890, 0, 3, 1, 0, 19, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1104, 'Tony Stark', '06089160W', 'IRON MAN', 'Pepper Potts', '10880 MALIBU POINT, 90265', 'Gotham', 46460, 1111111111, 222222222, 1, 'TonyStark@mydomain.com', NULL, 0, 1234567890, 0, 2, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 18, 0, 'florist','normal'),
(1105, 'Max Eisenhardt', '251628698', 'MAGNETO', 'Rogue', 'UNKNOWN WHEREABOUTS', 'Gotham', 46460, 1111111111, 222222222, 1, 'MaxEisenhardt@mydomain.com', NULL, 0, 1234567890, 0, 3, 1, 300, 8, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 1, NULL, 0, 0, 18, 0, 'florist','normal'),
(1106, 'DavidCharlesHaller', '53136686Q', 'LEGION', 'Charles Xavier', 'CITY OF NEW YORK, NEW YORK, USA', 'Gotham', 46460, 1111111111, 222222222, 1, 'DavidCharlesHaller@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 0, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, 19, 0, 'florist','normal'),
(1107, 'Hank Pym', '09854837G', 'ANT MAN', 'Hawk', 'ANTHILL, SAN FRANCISCO, CALIFORNIA', 'Gotham', 46460, 1111111111, 222222222, 1, 'HankPym@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 0, 0, NULL, 0, 0, 19, 0, 'florist','normal'),
(1108, 'Charles Xavier', '22641921P', 'PROFESSOR X', 'Beast', '3800 VICTORY PKWY, CINCINNATI, OH 45207, USA', 'Gotham', 46460, 1111111111, 222222222, 1, 'CharlesXavier@mydomain.com', NULL, 0, 1234567890, 0, 5, 1, 300, 13, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 1, NULL, 0, 0, 19, 0, 'florist','normal'),
(1109, 'Bruce Banner', '16104829E', 'HULK', 'Black widow', 'SOMEWHERE IN NEW YORK', 'Gotham', 46460, 1111111111, 222222222, 1, 'BruceBanner@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 0, 0, NULL, 0, 0, 9, 0, 'florist','normal'),
(1110, 'Jessica Jones', '58282869H', 'JESSICA JONES', 'Luke Cage', 'NYCC 2015 POSTER', 'Gotham', 46460, 1111111111, 222222222, 1, 'JessicaJones@mydomain.com', NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 1, 1, 0, NULL, 0, 0, NULL, 1, 'florist','normal'),
(1111, 'Missing', NULL, 'MISSING MAN', 'Anton', 'THE SPACE, UNIVERSE FAR AWAY', 'Gotham', 46460, 1111111111, 222222222, 1, NULL, NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 0, 1, 0, NULL, 1, 0, NULL, 0, 'others','loses'),
(1112, 'Trash', NULL, 'GARBAGE MAN', 'Unknown name', 'NEW YORK CITY, UNDERGROUND', 'Gotham', 46460, 1111111111, 222222222, 1, NULL, NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1, 5, 1, 1, 1, '0000-00-00', 0, 1, 0, NULL, 1, 0, NULL, 0, 'others','loses');
INSERT INTO `vn`.`client`(`id`, `name`, `fi`, `socialName`, `contact`, `street`, `city`, `postcode`, `isRelevant`, `email`, `iban`,`dueDay`,`accountingAccount`, `isEqualizated`, `provinceFk`, `hasToInvoice`, `credit`, `countryFk`, `isActive`, `gestdocFk`, `quality`, `payMethodFk`,`created`, `isTaxDataChecked`)
SELECT id, name, CONCAT(RPAD(CONCAT(id,9),8,id),'A'), UPPER(CONCAT(name, 'Social')), CONCAT(name, 'Contact'), UPPER(CONCAT(name, 'Street')), 'GOTHAM', 46460, 1, CONCAT(name,'@mydomain.com'), NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1,NULL, 10, 5, util.VN_CURDATE(), 1
INSERT INTO `vn`.`client`(`id`, `name`, `fi`, `socialName`, `contact`, `street`, `city`, `postcode`, `isRelevant`, `email`, `iban`,`dueDay`,`accountingAccount`, `isEqualizated`, `provinceFk`, `hasToInvoice`, `credit`, `countryFk`, `isActive`, `quality`, `payMethodFk`,`created`, `isTaxDataChecked`)
SELECT id, name, CONCAT(RPAD(CONCAT(id,9),8,id),'A'), UPPER(CONCAT(name, 'Social')), CONCAT(name, 'Contact'), UPPER(CONCAT(name, 'Street')), 'GOTHAM', 46460, 1, CONCAT(name,'@mydomain.com'), NULL, 0, 1234567890, 0, 1, 1, 300, 1, 1, 10, 5, util.VN_CURDATE(), 1
FROM `account`.`role` `r`
WHERE `r`.`hasLogin` = 1;
@ -545,7 +546,8 @@ INSERT INTO `vn`.`observationType`(`id`,`description`, `code`)
(6, 'Weight', 'weight'),
(7, 'InvoiceOut', 'invoiceOut'),
(8, 'DropOff', 'dropOff'),
(9, 'Sustitución', 'substitution');
(9, 'Sustitución', 'substitution'),
(10, 'Finance', 'finance');
INSERT INTO `vn`.`addressObservation`(`id`,`addressFk`,`observationTypeFk`,`description`)
VALUES
@ -630,14 +632,21 @@ INSERT INTO vn.invoiceOutConfig
SET id = 1,
parallelism = 8;
INSERT INTO `vn`.`invoiceOutSerial` (`code`, `description`, `isTaxed`, `taxAreaFk`, `isCEE`, `type`)
INSERT INTO `vn`.`invoiceOutSerial`
(`code`,`description`, `isTaxed`, `taxAreaFk`, `isCEE`, `type`)
VALUES
('A', 'Global nacional', 1, 'NATIONAL', 0, 'global'),
('T', 'Española rapida', 1, 'NATIONAL', 0, 'quick'),
('V', 'Intracomunitaria global', 0, 'CEE', 1, 'global'),
('M', 'Múltiple nacional', 1, 'NATIONAL', 0, 'multiple'),
('R', 'Rectificativa', 1, 'NATIONAL', 0, NULL),
('E', 'Exportación rápida', 0, 'WORLD', 0, 'quick');
('A', 'Global nacional', 1, 'NATIONAL', 0, 'global'),
('T', 'Española rapida', 1, 'NATIONAL', 0, 'quick'),
('V', 'Intracomunitaria global', 0, 'CEE', 1, 'global'),
('M', 'Múltiple nacional', 1, 'NATIONAL', 0, 'multiple'),
('R', 'Rectificativa', 1, 'NATIONAL', 0, NULL),
('E', 'Exportación rápida', 0, 'WORLD', 0, 'quick'),
('H', 'Intracomunitaria rápida', 0, 'CEE', 1, 'quick'),
('P', 'Factura simplificada', 1, 'NATIONAL', 0, NULL),
('PE', 'COOPERATIE FLORAHOLLAND UA', 0, 'CEE', 1, NULL),
('S', 'Simplificada', 1, 'NATIONAL', 0, NULL),
('X', 'Exportación global', 0, 'WORLD', 0, 'global'),
('N', 'Múltiple Intracomunitaria', 0, 'CEE', 1, 'multiple');
INSERT INTO `vn`.`invoiceOut`(`id`, `serial`, `amount`, `issued`,`clientFk`, `created`, `companyFk`, `dued`, `booked`, `bankFk`, `hasPdf`)
VALUES
@ -1497,16 +1506,17 @@ INSERT INTO `vn`.`awb` (id, code, package, weight, created, amount, transitoryFk
(10, '07546500856', 185, 2364, util.VN_CURDATE(), 5321, 442, 1);
INSERT INTO `vn`.`travel`(`id`,`shipped`, `landed`, `warehouseInFk`, `warehouseOutFk`, `agencyModeFk`, `m3`, `kg`,`ref`, `totalEntries`, `cargoSupplierFk`, `awbFK`)
VALUES
(1, DATE_ADD(util.VN_CURDATE(), INTERVAL -2 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -2 MONTH), 1, 2, 1, 100.00, 1000, 'first travel', 1, 1, 1),
(2, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 1, 2, 1, 150, 2000, 'second travel', 2, 2, 2),
(3, util.VN_CURDATE(), util.VN_CURDATE(), 1, 2, 1, 0.00, 0.00, 'third travel', 1, 1, 3),
(4, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 1, 3, 1, 50.00, 500, 'fourth travel', 0, 2, 4),
(5, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 3, 3, 1, 50.00, 500, 'fifth travel', 1, 1, 5),
(6, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 4, 4, 1, 50.00, 500, 'sixth travel', 1, 2, 6),
(7, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 5, 4, 1, 50.00, 500, 'seventh travel', 2, 1, 7),
(8, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 5, 1, 1, 50.00, 500, 'eight travel', 1, 2, 10),
(10, DATE_ADD(util.VN_CURDATE(), INTERVAL + 5 DAY), DATE_ADD(util.VN_CURDATE(), INTERVAL + 5 DAY), 5, 1, 1, 50.00, 500, 'nineth travel', 1, 2, 10);
VALUES (1, DATE_ADD(util.VN_CURDATE(), INTERVAL -2 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -2 MONTH), 1, 2, 1, 100.00, 1000, 'first travel', 1, 1, 1),
(2, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 1, 2, 1, 150.00, 2000, 'second travel', 2, 2, 2),
(3, util.VN_CURDATE(), util.VN_CURDATE(), 1, 2, 1, 0.00, 0.00, 'third travel', 1, 1, 3),
(4, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 1, 3, 1, 50.00, 500, 'fourth travel', 0, 2, 4),
(5, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 3, 3, 1, 50.00, 500, 'fifth travel', 1, 1, 5),
(6, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 4, 4, 1, 50.00, 500, 'sixth travel', 1, 2, 6),
(7, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 5, 4, 1, 50.00, 500, 'seventh travel', 2, 1, 7),
(8, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 5, 1, 1, 50.00, 500, 'eight travel', 1, 2, 10),
(10, DATE_ADD(util.VN_CURDATE(), INTERVAL +5 DAY), DATE_ADD(util.VN_CURDATE(), INTERVAL +5 DAY), 5, 1, 1, 50.00, 500, 'nineth travel', 1, 2, 10),
(11, util.VN_CURDATE() - INTERVAL 1 DAY , util.VN_CURDATE(), 6, 3, 0, 50.00, 500, 'eleventh travel', 1, 2, 4),
(12, util.VN_CURDATE() , util.VN_CURDATE() + INTERVAL 1 DAY, 6, 3, 0, 50.00, 500, 'eleventh travel', 1, 2, 4);
INSERT INTO `vn`.`entry`(`id`, `supplierFk`, `created`, `travelFk`, `isConfirmed`, `companyFk`, `invoiceNumber`, `reference`, `isExcludedFromAvailable`, `isRaid`, `evaNotes`)
VALUES
@ -1519,7 +1529,8 @@ INSERT INTO `vn`.`entry`(`id`, `supplierFk`, `created`, `travelFk`, `isConfirmed
(7, 2, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 7, 0, 442, 'IN2007', 'Movement 7', 0, 0, 'observation seven'),
(8, 2, DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 7, 0, 442, 'IN2008', 'Movement 8', 1, 1, ''),
(9, 2, DATE_ADD(util.VN_CURDATE(), INTERVAL +2 DAY), 10, 0, 442, 'IN2009', 'Movement 9', 1, 1, ''),
(10, 2, DATE_ADD(util.VN_CURDATE(), INTERVAL +2 DAY), 10, 0, 442, 'IN2009', 'Movement 9', 1, 1, '');
(10, 2, DATE_ADD(util.VN_CURDATE(), INTERVAL +2 DAY), 10, 0, 442, 'IN2009', 'Movement 10', 1, 1, ''),
(99, 69, '2000-12-01 00:00:00.000', 11, 0, 442, 'IN2009', 'Movement 99', 0, 0, '');
INSERT INTO `vn`.`entryConfig` (`defaultEntry`, `inventorySupplierFk`, `defaultSupplierFk`)
VALUES (2, 4, 1);
@ -1542,7 +1553,7 @@ INSERT INTO `bs`.`waste`(`buyerFk`, `year`, `week`, `itemFk`, `itemTypeFk`, `sal
('103', YEAR(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 WEEK)), WEEK(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 WEEK), 1), 6, 1, '186', '0', '51', '53.12', '56.20', '56.20', '56.20'),
('103', YEAR(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 WEEK)), WEEK(DATE_ADD(util.VN_CURDATE(), INTERVAL -1 WEEK), 1), 7, 1, '277', '0', '53.12', '56.20', '56.20', '56.20', '56.20');
INSERT INTO `vn`.`buy`(`id`,`entryFk`,`itemFk`,`buyingValue`,`quantity`,`packagingFk`,`stickers`,`freightValue`,`packageValue`,`comissionValue`,`packing`,`grouping`,`groupingMode`,`location`,`price1`,`price2`,`price3`, `printedStickers`,`isChecked`,`isIgnored`,`weight`, `created`)
INSERT INTO vn.buy(id,entryFk,itemFk,buyingValue,quantity,packagingFk,stickers,freightValue,packageValue,comissionValue,packing,grouping,groupingMode,location,price1,price2,price3,printedStickers,isChecked,isIgnored,weight,created)
VALUES
(1, 1, 1, 50, 5000, 4, 1, 1.500, 1.500, 0.000, 1, 1, 'packing', NULL, 0.00, 99.6, 99.4, 0, 1, 0, 1, util.VN_CURDATE() - INTERVAL 2 MONTH),
(2, 2, 1, 50, 100, 4, 1, 1.500, 1.500, 0.000, 1, 1, 'packing', NULL, 0.00, 99.6, 99.4, 0, 1, 0, 1, util.VN_CURDATE() - INTERVAL 1 MONTH),
@ -1558,7 +1569,8 @@ INSERT INTO `vn`.`buy`(`id`,`entryFk`,`itemFk`,`buyingValue`,`quantity`,`packagi
(12, 6, 4, 1.25, 0, 3, 1, 2.500, 2.500, 0.000, 10, 10, 'grouping', NULL, 0.00, 1.75, 1.67, 0, 1, 0, 4, util.VN_CURDATE()),
(13, 7, 1, 50, 0, 3, 1, 2.000, 2.000, 0.000, 1, 1, 'packing', NULL, 0.00, 99.6, 99.4, 0, 1, 0, 4, util.VN_CURDATE()),
(14, 7, 2, 5, 0, 3, 1, 2.000, 2.000, 0.000, 10, 10, 'grouping', NULL, 0.00, 7.30, 7.00, 0, 1, 0, 4, util.VN_CURDATE()),
(15, 7, 4, 1.25, 0, 3, 1, 2.000, 2.000, 0.000, 10, 10, 'grouping', NULL, 0.00, 1.75, 1.67, 0, 1, 0, 4, util.VN_CURDATE());
(15, 7, 4, 1.25, 0, 3, 1, 2.000, 2.000, 0.000, 10, 10, 'grouping', NULL, 0.00, 1.75, 1.67, 0, 1, 0, 4, util.VN_CURDATE()),
(16, 99,1,50.0000, 5000, 4, 1, 1.500, 1.500, 0.000, 1, 1, 'packing', NULL, 0.00, 99.60, 99.40, 0, 1, 0, 1.00, '2024-07-30 08:13:51.000');
INSERT INTO `hedera`.`order`(`id`, `date_send`, `customer_id`, `delivery_method_id`, `agency_id`, `address_id`, `company_id`, `note`, `source_app`, `confirmed`,`total`, `date_make`, `first_row_stamp`, `confirm_date`)
VALUES
@ -2439,30 +2451,32 @@ INSERT INTO `vn`.`workerTimeControl`(`userFk`, `timed`, `manual`, `direction`, `
(1107, CONCAT(util.VN_CURDATE(), ' 10:20'), TRUE, 'middle', 1),
(1107, CONCAT(util.VN_CURDATE(), ' 14:50'), TRUE, 'out', 1);
INSERT INTO `vn`.`dmsType`(`id`, `name`, `readRoleFk`, `writeRoleFk`, `code`)
INSERT INTO `vn`.`dmsType`
(`id`, `name`, `readRoleFk`, `writeRoleFk`, `code`)
VALUES
(1, 'Facturas Recibidas', NULL, NULL, 'invoiceIn'),
(2, 'Doc oficial', NULL, NULL, 'officialDoc'),
(3, 'Laboral', 37, 37, 'hhrrData'),
(4, 'Albaranes recibidos', NULL, NULL, 'deliveryNote'),
(5, 'Otros', 1, 1, 'miscellaneous'),
(6, 'Pruebas', NULL, NULL, 'tests'),
(7, 'IAE Clientes', 1, 1, 'economicActivitiesTax'),
(8, 'Fiscal', NULL, NULL, 'fiscal'),
(9, 'Vehiculos', NULL, NULL, 'vehicles'),
(10, 'Plantillas', NULL, NULL, 'templates'),
(11, 'Contratos', NULL, NULL, 'contracts'),
(12, 'ley de pagos', 1, 1, 'paymentsLaw'),
(13, 'Basura', 1, 1, 'trash'),
(14, 'Ticket', 1, 1, 'ticket'),
(15, 'Presupuestos', NULL, NULL, 'budgets'),
(16, 'Logistica', NULL, NULL, 'logistics'),
(17, 'cmr', 1, 1, 'cmr'),
(18, 'dua', NULL, NULL, 'dua'),
(19, 'inmovilizado', NULL, NULL, 'fixedAssets'),
(20, 'Reclamación', 1, 1, 'claim'),
(21, 'Entrada', 1, 1, 'entry'),
(22, 'Proveedor', 1, 1, 'supplier');
(1, 'Facturas Recibidas', NULL, NULL, 'invoiceIn'),
(2, 'Doc oficial', NULL, NULL, 'officialDoc'),
(3, 'Laboral', 37, 37, 'hhrrData'),
(4, 'Albaranes recibidos', NULL, NULL, 'deliveryNote'),
(5, 'Otros', 1, 1, 'miscellaneous'),
(6, 'Pruebas', NULL, NULL, 'tests'),
(7, 'IAE Clientes', 1, 1, 'economicActivitiesTax'),
(8, 'Fiscal', NULL, NULL, 'fiscal'),
(9, 'Vehiculos', NULL, NULL, 'vehicles'),
(10, 'Plantillas', NULL, NULL, 'templates'),
(11, 'Contratos', NULL, NULL, 'contracts'),
(12, 'ley de pagos', 1, 1, 'paymentsLaw'),
(13, 'Basura', 1, 1, 'trash'),
(14, 'Ticket', 1, 1, 'ticket'),
(15, 'Presupuestos', NULL, NULL, 'budgets'),
(16, 'Logistica', NULL, NULL, 'logistics'),
(17, 'cmr', 1, 1, 'cmr'),
(18, 'dua', NULL, NULL, 'dua'),
(19, 'inmovilizado', NULL, NULL, 'fixedAssets'),
(20, 'Reclamación', 1, 1, 'claim'),
(21, 'Entrada', 1, 1, 'entry'),
(22, 'Proveedor', 1, 1, 'supplier'),
(23, 'Termografos', 35, 35, 'thermograph');
INSERT INTO `vn`.`dms`(`id`, `dmsTypeFk`, `file`, `contentType`, `workerFk`, `warehouseFk`, `companyFk`, `hardCopyNumber`, `hasFile`, `reference`, `description`, `created`)
VALUES
@ -2470,7 +2484,7 @@ INSERT INTO `vn`.`dms`(`id`, `dmsTypeFk`, `file`, `contentType`, `workerFk`, `wa
(2, 5, '2.txt', 'text/plain', 5, 1, 442, 1, TRUE, 'Client:104', 'Client:104 dms for the client', util.VN_CURDATE()),
(3, 5, '3.txt', 'text/plain', 5, 1, 442, NULL, TRUE, 'Client: 104', 'Client:104 readme', util.VN_CURDATE()),
(4, 3, '4.txt', 'text/plain', 5, 1, 442, NULL, TRUE, 'Worker: 106', 'Worker:106 readme', util.VN_CURDATE()),
(5, 5, '5.txt', 'text/plain', 5, 1, 442, NULL, TRUE, 'travel: 1', 'dmsForThermograph', util.VN_CURDATE()),
(5, 23, '5.txt', 'text/plain', 5, 1, 442, NULL, TRUE, 'travel: 1', 'dmsForThermograph', util.VN_CURDATE()),
(6, 5, '6.txt', 'text/plain', 5, 1, 442, NULL, TRUE, 'NotExists', 'DoesNotExists', util.VN_CURDATE()),
(7, 20, '7.jpg', 'image/jpeg', 9, 1, 442, NULL, FALSE, '1', 'TICKET ID DEL CLIENTE BRUCE WAYNE ID 1101', util.VN_CURDATE()),
(8, 20, '8.mp4', 'video/mp4', 9, 1, 442, NULL, FALSE, '1', 'TICKET ID DEL CLIENTE BRUCE WAYNE ID 1101', util.VN_CURDATE()),
@ -2520,14 +2534,15 @@ INSERT INTO `vn`.`thermograph`(`id`, `model`)
('138350-0', 'DISPOSABLE');
INSERT INTO `vn`.`travelThermograph`(`thermographFk`, `created`, `warehouseFk`, `travelFk`, `temperatureFk`, `result`, `dmsFk`)
INSERT INTO `vn`.`travelThermograph`
(`thermographFk`, `created`, `warehouseFk`, `travelFk`, `temperatureFk`, `minTemperature`, `maxTemperature`, `result`, `dmsFk`)
VALUES
('TMM190901395', util.VN_CURDATE(), 1, 1, 'WARM', 'Ok', NULL),
('TL.BBA85422', DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 2, 2, 'COOL', 'Ok', NULL),
('TL.BBA85422', util.VN_CURDATE(), 2, 1, 'COOL', 'can not read the temperature', NULL),
('TZ1905012010', util.VN_CURDATE(), 1, 1, 'WARM', 'Temperature in range', 5),
('138350-0', DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 1, 1, 'WARM', NULL, 5),
('138350-0', util.VN_CURDATE(), 1, NULL, 'COOL', NULL, NULL);
('TMM190901395', util.VN_CURDATE(), 1, 1, 'WARM', NULL, NULL, 'Ok', NULL),
('TL.BBA85422', DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 2, 2, 'COOL', NULL, NULL, 'Ok', NULL),
('TL.BBA85422', util.VN_CURDATE(), 2, 1, 'COOL', NULL, NULL, 'can not read the temperature', NULL),
('TZ1905012010', util.VN_CURDATE(), 1, 1, 'WARM', NULL, NULL, 'Temperature in range', 5),
('138350-0', DATE_ADD(util.VN_CURDATE(), INTERVAL -1 MONTH), 1, 1, 'WARM', 2, 12, NULL, 5),
('138350-0', util.VN_CURDATE(), 1, NULL, 'COOL', NULL, NULL, NULL, NULL);
REPLACE INTO `vn`.`incoterms`(`code`, `name`)
VALUES
@ -2903,7 +2918,8 @@ INSERT INTO `util`.`notification` (`id`, `name`, `description`)
(6, 'book-entry-deleted', 'accounting entries deleted'),
(7, 'zone-included','An email to notify zoneCollisions'),
(8, 'backup-printer-selected','A backup printer has been selected'),
(9, 'mrw-deadline','The MRW deadline has passed');
(9, 'mrw-deadline','The MRW deadline has passed'),
(10,'invoice-ticket-closure','Tickets not invoiced during the nightly closure ticket process');
TRUNCATE `util`.`notificationAcl`;
INSERT INTO `util`.`notificationAcl` (`notificationFk`, `roleFk`)
@ -3935,6 +3951,11 @@ INSERT INTO vn.medicalReview
(id, workerFk, centerFk, `date`, `time`, isFit, amount, invoice, remark)
VALUES(3, 9, 2, '2000-01-01', '8:00', 1, 150.0, NULL, NULL);
INSERT INTO vn.stockBought (workerFk, bought, reserve, dated)
VALUES(35, 1.00, 1.00, '2001-01-01');
INSERT INTO vn.auctionConfig (id,conversionCoefficient,warehouseFk)
VALUES (1,0.6,6);
INSERT INTO vn.payrollComponent
(id, name, isSalaryAgreed, isVariable, isException)
VALUES
@ -3976,3 +3997,25 @@ VALUES
INSERT IGNORE INTO ormConfig
SET id =1,
selectLimit = 1000;
INSERT INTO pbx.queueMultiConfig
SET id = 'ring',
strategy = 20,
timeout = 2,
retry = 0,
weight = 0,
maxLen = 0,
ringInUse = 0;
INSERT INTO pbx.queue (description, name, config)
VALUES ('X-men', '1000', 1),
('Avengers', '2000', 1);
INSERT IGNORE INTO pbx.queueMember
SET queue = '1000',
extension = '1010';
UPDATE vn.department SET pbxQueue = '1000' WHERE name = "CAMARA";
UPDATE vn.department SET pbxQueue = '2000' WHERE name = "VENTAS";

View File

@ -6,25 +6,27 @@ BLOCK1: BEGIN
DECLARE vShipped DATE;
DECLARE vPreviousShipped DATE;
DECLARE vDone boolean;
DECLARE cur cursor for
SELECT clientFk, firstShipped
FROM bs.clientNewBorn;
DECLARE cur CURSOR FOR
SELECT clientFk, firstShipped
FROM bs.clientNewBorn;
DECLARE continue HANDLER FOR NOT FOUND SET vDone = TRUE;
SET vDone := FALSE;
DELETE FROM bs.clientNewBorn WHERE isModified = FALSE;
INSERT INTO clientNewBorn(clientFk, firstShipped, lastShipped)
SELECT c.id, MAX(t.shipped), MAX(t.shipped)
FROM vn.client c
JOIN vn.ticket t on t.clientFk = c.id
LEFT JOIN clientNewBorn cb on cb.clientFk = c.id
WHERE t.shipped BETWEEN TIMESTAMPADD(YEAR, -1, util.VN_CURDATE()) AND util.VN_CURDATE() AND cb.isModified is null
GROUP BY c.id;
INSERT INTO clientNewBorn(clientFk, firstShipped, lastShipped)
SELECT c.id, DATE(MAX(t.shipped)), DATE(MAX(t.shipped))
FROM vn.client c
JOIN vn.ticket t ON t.clientFk = c.id
LEFT JOIN clientNewBorn cb ON cb.clientFk = c.id
WHERE t.shipped BETWEEN util.VN_CURDATE() - INTERVAL 1 YEAR
AND util.VN_CURDATE()
AND cb.isModified IS NULL
GROUP BY c.id;
OPEN cur;
LOOP1: LOOP
SET vDone := FALSE;
FETCH cur INTO vClientFk, vShipped;

View File

@ -1,10 +1,10 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost`
CREATE OR REPLACE DEFINER=`vn`@`localhost`
PROCEDURE `hedera`.`orderRow_updateOverstocking`(vOrderFk INT)
BEGIN
/**
* Set amount = 0 to avoid overbooking sales
*
*
* @param vOrderFk hedera.order.id
*/
DECLARE vCalcFk INT;
@ -49,4 +49,4 @@ BEGIN
END LOOP;
CLOSE cWarehouses;
END$$
DELIMITER ;
DELIMITER ;

View File

@ -12,8 +12,8 @@ BEGIN
* @param vUser The user identifier
*/
DECLARE vHasRows BOOL;
DECLARE vDone BOOL;
DECLARE vHas0Amount BOOL;
DECLARE vDone BOOL;
DECLARE vWarehouseFk INT;
DECLARE vShipment DATE;
DECLARE vShipmentDayEnd DATETIME;
@ -108,7 +108,7 @@ BEGIN
IF vHas0Amount THEN
CALL util.throw('Hay líneas vacías. Por favor, elimínelas');
END IF;
END IF;
START TRANSACTION;

View File

@ -3,8 +3,8 @@ CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `hedera`.`orderRow_afterIns
AFTER INSERT ON `orderRow`
FOR EACH ROW
BEGIN
UPDATE `order`
SET rowUpdated = util.VN_NOW()
UPDATE `order`
SET rowUpdated = util.VN_NOW()
WHERE id = NEW.orderFk;
END$$
DELIMITER ;
DELIMITER ;

View File

@ -1,20 +0,0 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`buy_getVolumeByAgency`(vDated DATE, vAgencyFk INT)
BEGIN
DROP TEMPORARY TABLE IF EXISTS tmp.buy;
CREATE TEMPORARY TABLE tmp.buy (buyFk INT NOT NULL, PRIMARY KEY (buyFk)) ENGINE = MEMORY;
INSERT INTO tmp.buy
SELECT b.id
FROM buy b
JOIN entry e ON e.id = b.entryFk
JOIN travel t ON t.id = e.travelFk
WHERE t.landed = vDated
AND t.agencyModeFk IN (0, vAgencyFk);
CALL buy_getVolume();
DROP TEMPORARY TABLE tmp.buy;
END$$
DELIMITER ;

View File

@ -23,6 +23,13 @@ BEGIN
DELETE FROM messageInbox WHERE sendDate < v2Months;
DELETE FROM messageInbox WHERE sendDate < v2Months;
DELETE FROM workerTimeControl WHERE timed < v4Years;
DELETE FROM itemShelvingSale
WHERE itemShelvingFk IN (
SELECT id
FROM itemShelving
WHERE created < util.VN_CURDATE()
AND visible = 0
);
DELETE FROM itemShelving WHERE created < util.VN_CURDATE() AND visible = 0;
DELETE FROM ticketDown WHERE created < util.yesterday();
DELETE IGNORE FROM expedition WHERE created < v26Months;
@ -50,16 +57,10 @@ BEGIN
DELETE FROM claim WHERE ticketCreated < v4Years;
-- Robert ubicacion anterior de travelLog comentario para debug
DELETE FROM zoneEvent WHERE `type` = 'day' AND dated < v3Months;
DELETE bm
FROM buyMark bm
JOIN buy b ON b.id = bm.id
JOIN entry e ON e.id = b.entryFk
JOIN travel t ON t.id = e.travelFk
WHERE t.landed <= v2Months;
DELETE b FROM buy b
JOIN entryConfig e ON e.defaultEntry = b.entryFk
WHERE b.created < v2Months;
DELETE FROM stockBuyed WHERE creationDate < v2Months;
DELETE FROM stockBought WHERE dated < v2Months;
DELETE FROM printQueue WHERE statusCode = 'printed' AND created < v2Months;
-- Equipos duplicados
DELETE w.*

View File

@ -34,22 +34,19 @@ BEGIN
DECLARE vIsTaxDataChecked TINYINT(1);
DECLARE vHasCoreVnl BOOLEAN;
DECLARE vMandateTypeFk INT;
DECLARE vHasDailyInvoice BOOLEAN;
SELECT cc.defaultPayMethodFk,
cc.defaultDueDay,
cc.defaultCredit,
cc.defaultIsTaxDataChecked,
cc.defaultHasCoreVnl,
cc.defaultMandateTypeFk,
c.hasDailyInvoice
cc.defaultMandateTypeFk
INTO vPayMethodFk,
vDueDay,
vDefaultCredit,
vIsTaxDataChecked,
vHasCoreVnl,
vMandateTypeFk,
vHasDailyInvoice
vMandateTypeFk
FROM clientConfig cc
LEFT JOIN province p ON p.id = vProvinceFk
LEFT JOIN country c ON c.id = p.countryFk;
@ -70,8 +67,7 @@ BEGIN
credit = vDefaultCredit,
isTaxDataChecked = vIsTaxDataChecked,
hasCoreVnl = vHasCoreVnl,
isEqualizated = FALSE,
hasDailyInvoice = vHasDailyInvoice
isEqualizated = FALSE
ON duplicate KEY UPDATE
payMethodFk = vPayMethodFk,
dueDay = vDueDay,

View File

@ -1,5 +1,8 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`collection_new`(vUserFk INT, OUT vCollectionFk INT)
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`collection_new`(
vUserFk INT,
OUT vCollectionFk INT
)
BEGIN
/**
* Genera colecciones de tickets sin asignar trabajador.
@ -12,30 +15,29 @@ BEGIN
DECLARE vLinesLimit INT;
DECLARE vTicketLines INT;
DECLARE vVolumeLimit DECIMAL;
DECLARE vTicketVolume DECIMAL;
DECLARE vSizeLimit INT;
DECLARE vTicketVolume DECIMAL;
DECLARE vMaxTickets INT;
DECLARE vStateFk VARCHAR(45);
DECLARE vStateCode VARCHAR(45);
DECLARE vFirstTicketFk INT;
DECLARE vHour INT;
DECLARE vMinute INT;
DECLARE vWorkerCode VARCHAR(3);
DECLARE vWagonCounter INT DEFAULT 0;
DECLARE vWagonCounter INT DEFAULT 1;
DECLARE vTicketFk INT;
DECLARE vItemPackingTypeFk VARCHAR(1);
DECLARE vHasAssignedTickets BOOLEAN;
DECLARE vHasAssignedTickets BOOL;
DECLARE vHasUniqueCollectionTime BOOL;
DECLARE vDone INT DEFAULT FALSE;
DECLARE vLockName VARCHAR(215);
DECLARE vLockTime INT DEFAULT 30;
DECLARE vHeight INT;
DECLARE vVolume INT;
DECLARE vLiters INT;
DECLARE vLines INT;
DECLARE vTotalLines INT DEFAULT 0;
DECLARE vTotalVolume INT DEFAULT 0;
DECLARE vFreeWagonFk INT;
DECLARE vErrorNumber INT;
DECLARE vErrorMsg TEXT;
DECLARE vDone INT DEFAULT FALSE;
DECLARE c1 CURSOR FOR
DECLARE vTickets CURSOR FOR
SELECT ticketFk, `lines`, m3
FROM tmp.productionBuffer
WHERE ticketFk <> vFirstTicketFk
ORDER BY HH,
mm,
productionOrder DESC,
@ -48,26 +50,6 @@ BEGIN
DECLARE CONTINUE HANDLER FOR NOT FOUND SET vDone = TRUE;
DECLARE EXIT HANDLER FOR SQLEXCEPTION
BEGIN
GET DIAGNOSTICS CONDITION 1
vErrorNumber = MYSQL_ERRNO,
vErrorMsg = MESSAGE_TEXT;
CALL util.debugAdd('collection_new', JSON_OBJECT(
'errorNumber', vErrorNumber,
'errorMsg', vErrorMsg,
'lockName', vLockName,
'userFk', vUserFk,
'ticketFk', vTicketFk
)); -- Tmp
IF vLockName IS NOT NULL THEN
DO RELEASE_LOCK(vLockName);
END IF;
RESIGNAL;
END;
SELECT pc.ticketTrolleyMax * o.numberOfWagons,
pc.hasUniqueCollectionTime,
w.code,
@ -78,36 +60,26 @@ BEGIN
o.trainFk,
o.linesLimit,
o.volumeLimit,
o.sizeLimit,
pc.collection_new_lockname
o.sizeLimit
INTO vMaxTickets,
vHasUniqueCollectionTime,
vWorkerCode,
vWarehouseFk,
vItemPackingTypeFk,
vStateFk,
vWagons,
vTrainFk,
vLinesLimit,
vVolumeLimit,
vSizeLimit,
vLockName
FROM productionConfig pc
JOIN worker w ON w.id = vUserFk
vHasUniqueCollectionTime,
vWorkerCode,
vWarehouseFk,
vItemPackingTypeFk,
vStateCode,
vWagons,
vTrainFk,
vLinesLimit,
vVolumeLimit,
vSizeLimit
FROM worker w
JOIN operator o ON o.workerFk = w.id
JOIN state st ON st.`code` = 'ON_PREPARATION'
JOIN operator o ON o.workerFk = vUserFk;
SET vLockName = CONCAT_WS('/',
vLockName,
vWarehouseFk,
vItemPackingTypeFk
);
IF NOT GET_LOCK(vLockName, vLockTime) THEN
CALL util.throw(CONCAT('Cannot get lock: ', vLockName));
END IF;
JOIN productionConfig pc
WHERE w.id = vUserFk;
-- Se prepara el tren, con tantos vagones como sea necesario.
CREATE OR REPLACE TEMPORARY TABLE tTrain
(wagon INT,
shelve INT,
@ -118,63 +90,62 @@ BEGIN
PRIMARY KEY(wagon, shelve))
ENGINE = MEMORY;
WHILE vWagons > vWagonCounter DO
SET vWagonCounter = vWagonCounter + 1;
INSERT INTO tTrain(wagon, shelve, liters, `lines`, height)
SELECT vWagonCounter, cv.`level` , cv.liters , cv.`lines` , cv.height
FROM collectionVolumetry cv
WHERE cv.trainFk = vTrainFk
INSERT INTO tTrain (wagon, shelve, liters, `lines`, height)
WITH RECURSIVE wagonSequence AS (
SELECT vWagonCounter wagon
UNION ALL
SELECT wagon + 1 wagon
FROM wagonSequence
WHERE wagon < vWagonCounter + vWagons -1
)
SELECT ws.wagon, cv.`level`, cv.liters, cv.`lines`, cv.height
FROM wagonSequence ws
JOIN vn.collectionVolumetry cv ON cv.trainFk = vTrainFk
AND cv.itemPackingTypeFk = vItemPackingTypeFk;
END WHILE;
-- Esto desaparecerá cuando tengamos la table cache.ticket
CALL productionControl(vWarehouseFk, 0);
ALTER TABLE tmp.productionBuffer
ADD COLUMN liters INT,
ADD COLUMN height INT;
-- Se obtiene nº de colección.
INSERT INTO collection
SET itemPackingTypeFk = vItemPackingTypeFk,
trainFk = vTrainFk,
wagons = vWagons,
warehouseFk = vWarehouseFk;
SELECT LAST_INSERT_ID() INTO vCollectionFk;
-- Los tickets de recogida en Algemesí sólo se sacan si están asignados.
-- Los pedidos con riesgo no se sacan aunque se asignen.
DELETE pb.*
DELETE pb
FROM tmp.productionBuffer pb
JOIN state s ON s.id = pb.state
WHERE (pb.agency = 'REC_ALGEMESI'
AND s.code <> 'PICKER_DESIGNED')
OR pb.problem LIKE '%RIESGO%';
-- Comprobamos si hay tickets asignados. En ese caso, nos centramos
-- exclusivamente en esos tickets y los sacamos independientemente
-- de problemas o tamaños
SELECT COUNT(*) INTO vHasAssignedTickets
FROM tmp.productionBuffer pb
JOIN state s ON s.id = pb.state
WHERE s.code = 'PICKER_DESIGNED'
AND pb.workerCode = vWorkerCode;
-- Si hay tickets asignados, nos centramos exclusivamente en esos tickets
-- y los sacamos independientemente de problemas o tamaños
SELECT EXISTS (
SELECT TRUE
FROM tmp.productionBuffer pb
JOIN state s ON s.id = pb.state
WHERE (s.code = 'PICKER_DESIGNED'
AND pb.workerCode = vWorkerCode)
OR s.code = 'LAST_CALL'
) INTO vHasAssignedTickets;
-- Se dejan en la tabla tmp.productionBuffer sólo aquellos tickets adecuados
IF vHasAssignedTickets THEN
DELETE pb.*
DELETE pb
FROM tmp.productionBuffer pb
JOIN state s ON s.id = pb.state
WHERE s.code <> 'PICKER_DESIGNED'
OR pb.workerCode <> vWorkerCode;
WHERE (s.code <> 'PICKER_DESIGNED'
OR pb.workerCode <> vWorkerCode)
AND s.code <> 'LAST_CALL';
ELSE
DELETE pb.*
DELETE pb
FROM tmp.productionBuffer pb
JOIN state s ON s.id = pb.state
JOIN agencyMode am ON am.id = pb.agencyModeFk
JOIN agency a ON a.id = am.agencyFk
LEFT JOIN (
SELECT pb.ticketFk, MAX(i.`size`) maxSize
FROM tmp.productionBuffer pb
@ -185,7 +156,7 @@ BEGIN
) sub ON sub.ticketFk = pb.ticketFk
JOIN productionConfig pc
WHERE pb.shipped <> util.VN_CURDATE()
OR (pb.ubicacion IS NULL AND a.isOwn)
OR pb.ubicacion IS NULL
OR (NOT s.isPreparable AND NOT s.isPrintable)
OR pb.collectionH IS NOT NULL
OR pb.collectionV IS NOT NULL
@ -193,26 +164,25 @@ BEGIN
OR (NOT pb.H AND pb.V > 0 AND vItemPackingTypeFk = 'H')
OR (NOT pb.V AND vItemPackingTypeFk = 'V')
OR (pc.isPreviousPreparationRequired AND pb.previousWithoutParking)
OR LENGTH(pb.problem) > 0
OR LENGTH(pb.problem)
OR pb.lines > vLinesLimit
OR pb.m3 > vVolumeLimit
OR sub.maxSize > vSizeLimit
OR pb.hasPlantTray;
END IF;
-- Es importante que el primer ticket se coja en todos los casos
SELECT ticketFk,
HH,
mm,
`lines`,
m3
INTO vFirstTicketFk,
vHour,
vMinute,
vTicketLines,
vTicketVolume
-- Hay que excluir aquellos que no tengan la misma hora de preparacion, si procede
IF vHasUniqueCollectionTime THEN
DELETE pb
FROM tmp.productionBuffer pb
JOIN tmp.productionBuffer pb2 ON pb2.ticketFk = vFirstTicketFk
AND (pb.HH <> pb2.HH OR pb.mm <> pb2.mm);
END IF;
SELECT ticketFk INTO vFirstTicketFk
FROM tmp.productionBuffer
ORDER BY HH,
ORDER BY HH,
mm,
productionOrder DESC,
m3 DESC,
@ -222,44 +192,37 @@ BEGIN
ticketFk
LIMIT 1;
-- Hay que excluir aquellos que no tengan la misma hora de preparacion, si procede
IF vHasUniqueCollectionTime THEN
DELETE FROM tmp.productionBuffer
WHERE HH <> vHour
OR mm <> vMinute;
END IF;
SET vTicketFk = vFirstTicketFk;
SET @lines = 0;
SET @volume = 0;
OPEN c1;
read_loop: LOOP
OPEN vTickets;
l: LOOP
SET vDone = FALSE;
FETCH vTickets INTO vTicketFk, vTicketLines, vTicketVolume;
IF vDone THEN
LEAVE l;
END IF;
-- Buscamos un ticket que cumpla con los requisitos en el listado
IF ((vTicketLines + @lines) <= vLinesLimit OR vLinesLimit IS NULL)
AND ((vTicketVolume + @volume) <= vVolumeLimit OR vVolumeLimit IS NULL) THEN
IF (vLinesLimit IS NULL OR (vTotalLines + vTicketLines) <= vLinesLimit)
AND (vVolumeLimit IS NULL OR (vTotalVolume + vTicketVolume) <= vVolumeLimit) THEN
CALL ticket_splitItemPackingType(vTicketFk, vItemPackingTypeFk);
DROP TEMPORARY TABLE tmp.ticketIPT;
SELECT COUNT(*), SUM(litros), MAX(i.`size`), SUM(sv.volume)
INTO vLines, vLiters, vHeight, vVolume
FROM saleVolume sv
JOIN sale s ON s.id = sv.saleFk
JOIN item i ON i.id = s.itemFk
WHERE sv.ticketFk = vTicketFk;
SET vTotalVolume = vTotalVolume + vVolume,
vTotalLines = vTotalLines + vLines;
UPDATE tmp.productionBuffer pb
JOIN (
SELECT SUM(litros) liters,
@lines:= COUNT(*) + @lines,
COUNT(*) `lines`,
MAX(i.`size`) height,
@volume := SUM(sv.volume) + @volume,
SUM(sv.volume) volume
FROM saleVolume sv
JOIN sale s ON s.id = sv.saleFk
JOIN item i ON i.id = s.itemFk
WHERE sv.ticketFk = vTicketFk
) sub
SET pb.liters = sub.liters,
pb.`lines` = sub.`lines`,
pb.height = sub.height
SET pb.liters = vLiters,
pb.`lines` = vLines,
pb.height = vHeight
WHERE pb.ticketFk = vTicketFk;
UPDATE tTrain tt
@ -276,17 +239,13 @@ BEGIN
tt.height
LIMIT 1;
-- Si no le encuentra una balda adecuada, intentamos darle un carro entero si queda alguno libre
-- Si no le encuentra una balda, intentamos darle un carro entero libre
IF NOT (SELECT COUNT(*) FROM tTrain WHERE ticketFk) THEN
SELECT tt.wagon
INTO vFreeWagonFk
FROM tTrain tt
LEFT JOIN (
SELECT DISTINCT wagon
FROM tTrain
WHERE ticketFk IS NOT NULL
) nn ON nn.wagon = tt.wagon
WHERE nn.wagon IS NULL
SELECT wagon INTO vFreeWagonFk
FROM tTrain
GROUP BY wagon
HAVING COUNT(ticketFk) = 0
ORDER BY wagon
LIMIT 1;
@ -295,38 +254,35 @@ BEGIN
SET ticketFk = vFirstTicketFk
WHERE wagon = vFreeWagonFk;
-- Se anulan el resto de carros libres para que sólo uno lleve un pedido excesivo
DELETE tt.*
FROM tTrain tt
LEFT JOIN (
SELECT DISTINCT wagon
FROM tTrain
WHERE ticketFk IS NOT NULL
) nn ON nn.wagon = tt.wagon
WHERE nn.wagon IS NULL;
END IF;
END IF;
-- Se anulan el resto de carros libres,
-- máximo un carro con pedido excesivo
FETCH c1 INTO vTicketFk, vTicketLines, vTicketVolume;
IF vDone OR NOT (SELECT COUNT(*) FROM tTrain WHERE ticketFk IS NULL) THEN
LEAVE read_loop;
END IF;
ELSE
FETCH c1 INTO vTicketFk, vTicketLines, vTicketVolume;
IF vDone THEN
LEAVE read_loop;
END IF;
DELETE tt
FROM tTrain tt
JOIN (SELECT wagon
FROM tTrain
GROUP BY wagon
HAVING COUNT(ticketFk) = 0
) sub ON sub.wagon = tt.wagon;
END IF;
END IF;
END IF;
END LOOP;
CLOSE c1;
CLOSE vTickets;
IF (SELECT COUNT(*) FROM tTrain WHERE ticketFk) THEN
UPDATE collection c
JOIN state st ON st.code = 'ON_PREPARATION'
SET c.stateFk = st.id
WHERE c.id = vCollectionFk;
-- Se obtiene nº de colección
INSERT INTO collection
SET itemPackingTypeFk = vItemPackingTypeFk,
trainFk = vTrainFk,
wagons = vWagons,
warehouseFk = vWarehouseFk;
SELECT LAST_INSERT_ID() INTO vCollectionFk;
-- Asigna las bandejas
INSERT IGNORE INTO ticketCollection(ticketFk, collectionFk, `level`, wagon, liters)
SELECT tt.ticketFk, vCollectionFk, tt.shelve, tt.wagon, tt.liters
FROM tTrain tt
@ -334,39 +290,36 @@ BEGIN
ORDER BY tt.wagon, tt.shelve;
-- Actualiza el estado de los tickets
CALL collection_setState(vCollectionFk, vStateFk);
CALL collection_setState(vCollectionFk, vStateCode);
-- Aviso para la preparacion previa
INSERT INTO ticketDown(ticketFk, collectionFk)
SELECT tc.ticketFk, tc.collectionFk
FROM ticketCollection tc
WHERE tc.collectionFk = vCollectionFk;
CALL sales_mergeByCollection(vCollectionFk);
CALL collection_mergeSales(vCollectionFk);
UPDATE `collection` c
JOIN (
JOIN(
SELECT COUNT(*) saleTotalCount,
SUM(s.isPicked <> 0) salePickedCount
FROM ticketCollection tc
JOIN sale s ON s.ticketFk = tc.ticketFk
WHERE tc.collectionFk = vCollectionFk
AND s.quantity > 0
) sub
WHERE tc.collectionFk = vCollectionFk
AND s.quantity > 0
)sub
SET c.saleTotalCount = sub.saleTotalCount,
c.salePickedCount = sub.salePickedCount
WHERE c.id = vCollectionFk;
ELSE
DELETE FROM `collection`
WHERE id = vCollectionFk;
SET vCollectionFk = NULL;
SET vCollectionFk = NULL;
END IF;
DO RELEASE_LOCK(vLockName);
DROP TEMPORARY TABLE
tTrain,
tmp.productionBuffer;
END$$
DELIMITER ;
DELIMITER ;

View File

@ -0,0 +1,56 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`invoiceOut_newFromAddress`(
IN vAddressFk INT,
IN vSerial CHAR(2),
IN vMaxShipped DATE,
IN vCompanyFk INT,
IN vTaxArea VARCHAR(25),
IN vRef VARCHAR(25),
OUT vInvoiceId INT)
BEGIN
/**
* Factura los tickets de un consignatario hasta una fecha dada
* @param vAddressFk Id del consignatario a facturar
* @param vSerial Serie de factura
* @param vMaxShipped Fecha hasta la cual cogerá tickets para facturar
* @param vCompanyFk Id de la empresa desde la que se factura
* @param vTaxArea Tipo de iva en relacion a la empresa y al cliente, NULL por defecto
* @param vRef Referencia de la factura en caso que se quiera forzar, NULL por defecto
* @return vInvoiceId factura
*/
DECLARE vIsRefEditable BOOLEAN;
IF vRef IS NOT NULL AND vSerial IS NOT NULL THEN
SELECT isRefEditable INTO vIsRefEditable
FROM invoiceOutSerial
WHERE code = vSerial;
IF NOT vIsRefEditable THEN
CALL util.throw('serial non editable');
END IF;
END IF;
DROP TEMPORARY TABLE IF EXISTS `tmp`.`ticketToInvoice`;
CREATE TEMPORARY TABLE `tmp`.`ticketToInvoice`
(PRIMARY KEY (`id`))
ENGINE = MEMORY
SELECT id FROM ticket t
WHERE t.addressFk = vAddressFk
AND t.refFk IS NULL
AND t.companyFk = vCompanyFk
AND t.shipped BETWEEN
util.firstDayOfYear(vMaxShipped - INTERVAL 1 YEAR)
AND util.dayend(vMaxShipped);
CALL invoiceOut_new(vSerial, util.VN_CURDATE(), vTaxArea, vInvoiceId);
UPDATE invoiceOut
SET `ref` = vRef
WHERE id = vInvoiceId
AND vRef IS NOT NULL;
IF vSerial <> 'R' AND NOT ISNULL(vInvoiceId) AND vInvoiceId <> 0 THEN
CALL invoiceOutBooking(vInvoiceId);
END IF;
END$$
DELIMITER ;

View File

@ -1,16 +1,22 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`itemShelving_addList`(vShelvingFk VARCHAR(3), vList TEXT, vIsChecking BOOL, vWarehouseFk INT)
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`itemShelving_addList`(
vShelvingFk VARCHAR(3),
vList TEXT,
vIsChecking BOOL,
vWarehouseFk INT
)
BEGIN
/* Recorre cada elemento en la colección vList.
/**
* Recorre cada elemento en la colección vList.
* Si el parámetro isChecking = FALSE, llama a itemShelving_add.
*
* Cuando es TRUE sólo inserta los elementos de la colección que no están ya en
* ese shelving, actualizando los valores del campo vn.itemShelving.isChecked
* ese shelving, actualizando los valores del campo itemShelving.isChecked
*
* param vShelvingFk Identificador de vn.shelving
* param vList JSON array con esta estructura: '[value1, value2, ...]'
* param vIsChecking Define si hay que añadir o comprobar los items
* param vWarehouseFk Identificador de vn.warehouse
* @param vShelvingFk Identificador de shelving
* @param vList JSON array con esta estructura: '[value1, value2, ...]'
* @param vIsChecking Define si hay que añadir o comprobar los items
* @param vWarehouseFk Identificador de warehouse
*/
DECLARE vListLength INT DEFAULT JSON_LENGTH(vList);
DECLARE vCounter INT DEFAULT 0;
@ -20,26 +26,27 @@ BEGIN
DECLARE vIsChecked BOOL;
WHILE vCounter < vListLength DO
SET vPath = CONCAT('$[',vCounter,']');
SET vBarcode = JSON_EXTRACT(vList,vPath);
SET vPath = CONCAT('$[', vCounter, ']');
SET vBarcode = JSON_EXTRACT(vList, vPath);
SET vIsChecked = NULL;
IF vIsChecking THEN
SELECT barcodeToItem(vBarcode) INTO vItemFk;
SELECT COUNT(*) INTO vIsChecked
FROM vn.itemShelving
SELECT IF(COUNT(*), TRUE, FALSE) INTO vIsChecked
FROM itemShelving
WHERE shelvingFk COLLATE utf8_unicode_ci = vShelvingFk
AND itemFk = vItemFk;
END IF;
IF NOT (vIsChecking AND vIsChecked) THEN
CALL vn.itemShelving_add(vShelvingFk, vBarcode, 1, NULL, NULL, NULL, vWarehouseFk);
IF NOT vIsChecking OR NOT vIsChecked THEN
CALL itemShelving_add(vShelvingFk, vBarcode, 1, NULL, NULL, NULL, vWarehouseFk);
END IF;
UPDATE vn.itemShelving
UPDATE itemShelving
SET isChecked = vIsChecked
WHERE shelvingFk COLLATE utf8_unicode_ci = vShelvingFk
AND itemFk = vItemFk AND isChecked IS NULL;
AND itemFk = vItemFk
AND isChecked IS NULL;
SET vCounter = vCounter + 1;
END WHILE;

View File

@ -1,15 +1,13 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`stockTraslation`(
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`item_calculateStock`(
vDated DATE
)
BEGIN
/**
* Calcula el stock del almacén de subasta desde FechaInventario hasta vDated
* sin tener en cuenta las salidas del mismo dia vDated
* para ver el transporte a reservar
* Calculate the stock of the auction warehouse from the inventory date to vDated
*
* @param vDated Fecha hasta la cual calcula el stock
* @return tmp.item
* @param vDated Date to calculate the stock.
* @return tmp.item, tmp.buyUltimate
*/
DECLARE vAuctionWarehouseFk INT;

View File

@ -15,13 +15,11 @@ proc: BEGIN
DECLARE vEndingDate DATETIME;
DECLARE vIsTodayRelative BOOLEAN;
SELECT util.dayEnd(util.VN_CURDATE()) + INTERVAL LEAST(vScopeDays, maxProductionScopeDays) DAY
INTO vEndingDate
FROM productionConfig;
SELECT isTodayRelative INTO vIsTodayRelative
FROM worker
WHERE id = getUser(); -- Cambiar por account.myUser_getId(), falta dar permisos
SELECT w.isTodayRelative, util.dayEnd(util.VN_CURDATE()) + INTERVAL LEAST(vScopeDays, pc.maxProductionScopeDays) DAY
INTO vIsTodayRelative,vEndingDate
FROM worker w
JOIN productionConfig pc
WHERE w.id = account.myUser_getId();
CALL prepareTicketList(util.yesterday(), vEndingDate);
@ -268,15 +266,14 @@ proc: BEGIN
UPDATE tmp.productionBuffer pb
JOIN sale s ON s.ticketFk = pb.ticketFk
JOIN item i ON i.id = s.itemFk
JOIN cache.last_buy lb ON lb.warehouse_id = vWarehouseFk
JOIN cache.last_buy lb ON lb.warehouse_id = vWarehouseFk
AND lb.item_id = s.itemFk
JOIN buy b ON b.id = lb.buy_id
JOIN packaging p ON p.id = b.packagingFk
JOIN productionConfig pc
SET pb.hasPlantTray = TRUE
WHERE p.isPlantTray
AND s.quantity >= b.packing
AND pb.isOwn;
AND pb.isOwn;
DROP TEMPORARY TABLE
tmp.productionTicket,

View File

@ -0,0 +1,29 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`queueMember_updateQueue`(
vBusinessFk INT
)
BEGIN
/**
* Elimina la entrada de la cola anterior y luego inserta la nueva para un trabajador.
*
* @param vBusinessFk ID del negocio
*/
DECLARE vNewQueue VARCHAR(10);
DECLARE vExtension VARCHAR(10);
DECLARE exit handler FOR SQLEXCEPTION
SELECT d.pbxQueue, s.extension
INTO vNewQueue, vExtension
FROM business b
JOIN department d ON d.id = b.departmentFk
JOIN pbx.sip s ON s.user_id = b.workerFk
WHERE b.id = vBusinessFk;
DELETE FROM pbx.queueMember
WHERE extension = vExtension COLLATE utf8_general_ci;
INSERT IGNORE INTO pbx.queueMember (queue, extension)
VALUES (vNewQueue, vExtension);
END$$
DELIMITER ;

View File

@ -7,13 +7,13 @@ proc: BEGIN
* Calculate the stock of the auction warehouse from the inventory date to vDated
* without taking into account the outputs of the same day vDated
*
* @param vDated Date to calculate the stock.
* @param vDated Date to calculate the stock
*/
IF vDated < util.VN_CURDATE() THEN
LEAVE proc;
END IF;
CREATE OR REPLACE TEMPORARY TABLE tStockBought
CREATE OR REPLACE TEMPORARY TABLE tCurrentData
SELECT workerFk, reserve
FROM stockBought
WHERE dated = vDated
@ -21,15 +21,28 @@ proc: BEGIN
DELETE FROM stockBought WHERE dated = vDated;
CREATE OR REPLACE TEMPORARY TABLE tStockSold
SELECT it.workerFk,
SUM(ic.cm3 * ito.quantity / vc.palletM3 / 1000000) sold
FROM itemTicketOut ito
JOIN item i ON i.id = ito.itemFk
JOIN itemType it ON it.id = i.typeFk
JOIN ticket t ON t.id = ito.ticketFk
JOIN warehouse wh ON wh.id = t.warehouseFk
JOIN itemCost ic ON ic.itemFk = ito.itemFk
AND ic.warehouseFk = t.warehouseFk
JOIN volumeConfig vc
WHERE ito.shipped BETWEEN vDated AND util.dayEnd(vDated)
AND wh.code = 'VNH'
GROUP BY it.workerFk;
CALL item_calculateStock(vDated);
INSERT INTO stockBought(workerFk, bought, dated)
CREATE OR REPLACE TEMPORARY TABLE tStockBought
SELECT it.workerFk,
ROUND(SUM(
(ti.quantity / b.packing) *
buy_getVolume(b.id)
) / vc.palletM3 / 1000000, 1) bought,
vDated
SUM((ti.quantity / b.packing) *
buy_getVolume(b.id)
) / vc.palletM3 / 1000000 bought
FROM itemType it
JOIN item i ON i.typeFk = it.id
LEFT JOIN tmp.item ti ON ti.itemFk = i.id
@ -43,20 +56,33 @@ proc: BEGIN
GROUP BY it.workerFk
HAVING bought;
INSERT INTO stockBought(workerFk, bought, dated)
SELECT tb.workerFk,
ROUND(GREATEST(tb.bought - IFNULL(ts.sold, 0), 0), 1),
vDated
FROM tStockBought tb
LEFT JOIN tStockSold ts ON ts.workerFk = tb.workerFk;
UPDATE stockBought s
JOIN tStockBought ts ON ts.workerFk = s.workerFk
JOIN tCurrentData ts ON ts.workerFk = s.workerFk
SET s.reserve = ts.reserve
WHERE s.dated = vDated;
INSERT INTO stockBought (workerFk, reserve, dated)
SELECT ts.workerFk, ts.reserve, vDated
FROM tStockBought ts
FROM tCurrentData ts
WHERE ts.workerFk NOT IN (
SELECT workerFk
FROM stockBought
WHERE dated = vDated
);
DROP TEMPORARY TABLE tStockBought, tmp.item, tmp.buyUltimate;
UPDATE stockBought s
JOIN tStockSold ts ON ts.workerFk = s.workerFk
SET s.bought = IF(s.bought < ts.sold, ROUND(s.bought - ts.sold, 1), 0)
WHERE s.dated = vDated;
DROP TEMPORARY TABLE tCurrentData, tmp.item, tmp.buyUltimate, tStockSold;
END$$
DELIMITER ;

View File

@ -1,74 +0,0 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`stockBuyedByWorker`(
vDated DATE,
vWorker INT
)
BEGIN
/**
* Inserta el volumen de compra de un comprador
* en stockBuyed de acuerdo con la fecha.
*
* @param vDated Fecha de compra
* @param vWorker Id de trabajador
*/
CREATE OR REPLACE TEMPORARY TABLE tStockBuyed
(INDEX (userFk))
ENGINE = MEMORY
SELECT requested, reserved, userFk
FROM stockBuyed
WHERE dated = vDated
AND userFk = vWorker;
DELETE FROM stockBuyed
WHERE dated = vDated
AND userFk = vWorker;
CALL stockTraslation(vDated);
INSERT INTO stockBuyed(userFk, buyed, `dated`, reserved, requested, description)
SELECT it.workerFk,
SUM((ti.quantity / b.packing) * buy_getVolume(b.id)) / vc.palletM3 / 1000000,
vDated,
sb.reserved,
sb.requested,
u.name
FROM itemType it
JOIN item i ON i.typeFk = it.id
LEFT JOIN tmp.item ti ON ti.itemFk = i.id
JOIN itemCategory ic ON ic.id = it.categoryFk
JOIN warehouse wh ON wh.code = 'VNH'
JOIN tmp.buyUltimate bu ON bu.itemFk = i.id
AND bu.warehouseFk = wh.id
JOIN buy b ON b.id = bu.buyFk
JOIN volumeConfig vc
JOIN account.`user` u ON u.id = it.workerFk
LEFT JOIN tStockBuyed sb ON sb.userFk = it.workerFk
WHERE ic.display
AND it.workerFk = vWorker;
SELECT b.entryFk Id_Entrada,
i.id Id_Article,
i.name Article,
ti.quantity Cantidad,
(ac.conversionCoefficient * (ti.quantity / b.packing) * buy_getVolume(b.id))
/ (vc.trolleyM3 * 1000000) buyed,
b.packagingFk id_cubo,
b.packing
FROM tmp.item ti
JOIN item i ON i.id = ti.itemFk
JOIN itemType it ON i.typeFk = it.id
JOIN itemCategory ic ON ic.id = it.categoryFk
JOIN worker w ON w.id = it.workerFk
JOIN auctionConfig ac
JOIN tmp.buyUltimate bu ON bu.itemFk = i.id
AND bu.warehouseFk = ac.warehouseFk
JOIN buy b ON b.id = bu.buyFk
JOIN volumeConfig vc
WHERE ic.display
AND w.id = vWorker;
DROP TEMPORARY TABLE tmp.buyUltimate,
tmp.item,
tStockBuyed;
END$$
DELIMITER ;

View File

@ -1,70 +0,0 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`stockBuyed_add`(
vDated DATE
)
BEGIN
/**
* Inserta el volumen de compra por comprador
* en stockBuyed de acuerdo con la fecha.
*
* @param vDated Fecha de compra
*/
CREATE OR REPLACE TEMPORARY TABLE tStockBuyed
(INDEX (userFk))
ENGINE = MEMORY
SELECT requested, reserved, userFk
FROM stockBuyed
WHERE dated = vDated;
DELETE FROM stockBuyed WHERE dated = vDated;
CALL stockTraslation(vDated);
INSERT INTO stockBuyed(userFk, buyed, `dated`, description)
SELECT it.workerFk,
SUM((ti.quantity / b.packing) * buy_getVolume(b.id)) / vc.palletM3 / 1000000,
vDated,
u.name
FROM itemType it
JOIN item i ON i.typeFk = it.id
LEFT JOIN tmp.item ti ON ti.itemFk = i.id
JOIN itemCategory ic ON ic.id = it.categoryFk
JOIN warehouse wh ON wh.code = 'VNH'
JOIN tmp.buyUltimate bu ON bu.itemFk = i.id AND bu.warehouseFk = wh.id
JOIN buy b ON b.id = bu.buyFk
JOIN volumeConfig vc
JOIN account.`user` u ON u.id = it.workerFk
JOIN workerDepartment wd ON wd.workerFk = u.id
JOIN department d ON d.id = wd.departmentFk
WHERE ic.display
AND d.code IN ('shopping', 'logistic', 'franceTeam')
GROUP BY it.workerFk;
INSERT INTO stockBuyed(buyed, dated, description)
SELECT SUM(ic.cm3 * ito.quantity / vc.palletM3 / 1000000),
vDated,
IF(c.code = 'ES', p.name, c.name) destiny
FROM itemTicketOut ito
JOIN ticket t ON t.id = ito.ticketFk
JOIN `address` a ON a.id = t.addressFk
JOIN province p ON p.id = a.provinceFk
JOIN country c ON c.id = p.countryFk
JOIN warehouse wh ON wh.id = t.warehouseFk
JOIN itemCost ic ON ic.itemFk = ito.itemFk
AND ic.warehouseFk = t.warehouseFk
JOIN volumeConfig vc
WHERE ito.shipped BETWEEN vDated AND util.dayend(vDated)
AND wh.code = 'VNH'
GROUP BY destiny;
UPDATE stockBuyed s
JOIN tStockBuyed ts ON ts.userFk = s.userFk
SET s.requested = ts.requested,
s.reserved = ts.reserved
WHERE s.dated = vDated;
DROP TEMPORARY TABLE tmp.buyUltimate,
tmp.item,
tStockBuyed;
END$$
DELIMITER ;

View File

@ -0,0 +1,25 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`ticketRefund_upsert`(
vRefundTicketFk INT,
vOriginalTicketFk INT
)
READS SQL DATA
BEGIN
/**
* Common code for ticketRefund triggers
*
* @param vRefundTicketFk
* @param vOriginalTicketFk
*/
DECLARE vIsDeleted BOOL;
SELECT COUNT(*) INTO vIsDeleted
FROM ticket
WHERE id IN (vRefundTicketFk, vOriginalTicketFk)
AND isDeleted;
IF vIsDeleted THEN
CALL util.throw('The refund ticket cannot be deleted tickets');
END IF;
END$$
DELIMITER ;

View File

@ -43,7 +43,7 @@ BEGIN
c.isTaxDataChecked,
t.companyFk,
t.shipped,
IFNULL(a.hasDailyInvoice, co.hasDailyInvoice),
c.hasDailyInvoice,
w.isManaged,
c.hasToInvoice
INTO vClientFk,
@ -55,9 +55,6 @@ BEGIN
vHasToInvoice
FROM ticket t
JOIN `client` c ON c.id = t.clientFk
JOIN province p ON p.id = c.provinceFk
LEFT JOIN autonomy a ON a.id = p.autonomyFk
JOIN country co ON co.id = p.countryFk
JOIN warehouse w ON w.id = t.warehouseFk
WHERE t.id = vCurTicketFk;
@ -85,7 +82,7 @@ BEGIN
IF(vHasDailyInvoice) AND vHasToInvoice THEN
SELECT invoiceSerial(vClientFk, vCompanyFk, 'quick') INTO vSerial;
IF vSerial IS NULL THEN
IF vSerial IS NULL THEN
CALL util.throw('Cannot booking without a serial');
END IF;

View File

@ -1,5 +1,7 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`ticket_getTax`(IN vTaxArea VARCHAR(25))
CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`ticket_getTax`(
vTaxArea VARCHAR(25)
)
BEGIN
/**
* Calcula la base imponible, el IVA y el recargo de equivalencia para
@ -33,30 +35,39 @@ BEGIN
CREATE OR REPLACE TEMPORARY TABLE tmp.ticketTax
(PRIMARY KEY (ticketFk, code, rate))
ENGINE = MEMORY
SELECT * FROM (
SELECT tmpTicket.ticketFk,
bp.pgcFk,
SUM(s.quantity * s.price * (100 - s.discount) / 100 ) taxableBase,
pgc.rate,
tc.code,
bp.priority
FROM tmp.ticket tmpTicket
JOIN sale s ON s.ticketFk = tmpTicket.ticketFk
JOIN item i ON i.id = s.itemFk
JOIN ticket t ON t.id = tmpTicket.ticketFk
JOIN supplier su ON su.id = t.companyFk
WITH sales AS (
SELECT s.ticketFk,
s.itemFk,
s.quantity * s.price * (100 - s.discount) / 100 total,
t.companyFk,
t.addressFk,
su.countryFk,
ata.areaFk,
itc.taxClassFk
FROM vn.sale s
JOIN tmp.ticket tmp ON tmp.ticketFk = s.ticketFk
JOIN vn.ticket t ON t.id = s.ticketFk
JOIN vn.supplier su ON su.id = t.companyFk
JOIN tmp.addressTaxArea ata ON ata.addressFk = t.addressFk
AND ata.companyFk = t.companyFk
JOIN itemTaxCountry itc ON itc.itemFk = i.id
JOIN vn.itemTaxCountry itc ON itc.itemFk = s.itemFk
AND itc.countryFk = su.countryFk
JOIN bookingPlanner bp ON bp.countryFk = su.countryFk
AND bp.taxAreaFk = ata.areaFk
AND bp.taxClassFk = itc.taxClassFk
JOIN pgc ON pgc.code = bp.pgcFk
JOIN taxClass tc ON tc.id = bp.taxClassFk
GROUP BY tmpTicket.ticketFk, pgc.code, pgc.rate
HAVING taxableBase
) t3
HAVING total
)
SELECT s.ticketFk,
bp.pgcFk,
SUM(s.total) taxableBase,
pgc.rate,
tc.code,
bp.priority
FROM sales s
JOIN vn.bookingPlanner bp ON bp.countryFk = s.countryFk
AND bp.taxAreaFk = s.areaFk
AND bp.taxClassFk = s.taxClassFk
JOIN vn.pgc ON pgc.code = bp.pgcFk
JOIN vn.taxClass tc ON tc.id = bp.taxClassFk
GROUP BY s.ticketFk, pgc.code, pgc.rate
HAVING taxableBase
ORDER BY priority;
CREATE OR REPLACE TEMPORARY TABLE tmp.ticketServiceTax

View File

@ -3,12 +3,25 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`ticket_mergeSales`(
vSelf INT
)
BEGIN
/**
* Para un ticket se agrupa las diferentes líneas de venta de un mismo artículo en una sola
* siempre y cuando tengan el mismo precio y dto.
*
* @param vSelf Id de ticket
*/
DECLARE vHasSalesToMerge BOOL;
DECLARE EXIT HANDLER FOR SQLEXCEPTION
BEGIN
ROLLBACK;
RESIGNAL;
END;
START TRANSACTION;
SELECT id INTO vSelf
FROM ticket
WHERE id = vSelf FOR UPDATE;
CREATE OR REPLACE TEMPORARY TABLE tSalesToPreserve
(PRIMARY KEY (id))
ENGINE = MEMORY
@ -18,26 +31,24 @@ BEGIN
JOIN itemType it ON it.id = i.typeFk
WHERE s.ticketFk = vSelf
AND it.isMergeable
GROUP BY s.itemFk, s.price, s.discount;
GROUP BY s.itemFk, s.price, s.discount
HAVING COUNT(*) > 1;
START TRANSACTION;
SELECT COUNT(*) INTO vHasSalesToMerge FROM tSalesToPreserve;
UPDATE sale s
JOIN tSalesToPreserve stp ON stp.id = s.id
SET s.quantity = newQuantity
WHERE s.ticketFk = vSelf;
IF vHasSalesToMerge THEN
UPDATE sale s
JOIN tSalesToPreserve stp ON stp.id = s.id
SET s.quantity = newQuantity;
DELETE s.*
FROM sale s
LEFT JOIN tSalesToPreserve stp ON stp.id = s.id
JOIN item i ON i.id = s.itemFk
JOIN itemType it ON it.id = i.typeFk
WHERE s.ticketFk = vSelf
AND stp.id IS NULL
AND it.isMergeable;
DELETE s
FROM sale s
JOIN tSalesToPreserve stp ON stp.itemFk = s.itemFk
WHERE s.ticketFk = vSelf
AND s.id <> stp.id;
END IF;
COMMIT;
DROP TEMPORARY TABLE tSalesToPreserve;
END$$
DELIMITER ;

View File

@ -3,124 +3,87 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`ticket_splitItemPacki
vSelf INT,
vOriginalItemPackingTypeFk VARCHAR(1)
)
BEGIN
proc:BEGIN
/**
* Clona y reparte las ventas de un ticket en funcion del tipo de empaquetado.
* Respeta el id inicial para el tipo propuesto.
* Clona y reparte las líneas de ventas de un ticket en funcion del tipo de empaquetado.
* Respeta el id de ticket original para el tipo de empaquetado propuesto.
*
* @param vSelf Id ticket
* @param vOriginalItemPackingTypeFk Tipo para el que se reserva el número de ticket original
* @param vOriginalItemPackingTypeFk Tipo empaquetado que se mantiene el ticket original
* @return table tmp.ticketIPT(ticketFk, itemPackingTypeFk)
*/
DECLARE vItemPackingTypeFk VARCHAR(1) DEFAULT 'H';
DECLARE vNewTicketFk INT;
DECLARE vPackingTypesToSplit INT;
DECLARE vDone INT DEFAULT FALSE;
DECLARE vHasItemPackingType BOOL;
DECLARE vItemPackingTypeFk INT;
DECLARE vNewTicketFk INT;
DECLARE vSaleGroup CURSOR FOR
SELECT itemPackingTypeFk
FROM tSaleGroup
WHERE itemPackingTypeFk IS NOT NULL
ORDER BY (itemPackingTypeFk = vOriginalItemPackingTypeFk) DESC;
DECLARE vItemPackingTypes CURSOR FOR
SELECT DISTINCT itemPackingTypeFk
FROM tSalesToMove;
DECLARE CONTINUE HANDLER FOR NOT FOUND SET vDone = TRUE;
START TRANSACTION;
SELECT id
FROM sale
WHERE ticketFk = vSelf
AND NOT quantity
FOR UPDATE;
DELETE FROM sale
WHERE NOT quantity
AND ticketFk = vSelf;
CREATE OR REPLACE TEMPORARY TABLE tSale
(PRIMARY KEY (id))
ENGINE = MEMORY
SELECT s.id, i.itemPackingTypeFk, IFNULL(sv.litros, 0) litros
FROM sale s
JOIN item i ON i.id = s.itemFk
LEFT JOIN saleVolume sv ON sv.saleFk = s.id
WHERE s.ticketFk = vSelf;
CREATE OR REPLACE TEMPORARY TABLE tSaleGroup
ENGINE = MEMORY
SELECT itemPackingTypeFk, SUM(litros) totalLitros
FROM tSale
GROUP BY itemPackingTypeFk;
SELECT COUNT(*) INTO vPackingTypesToSplit
FROM tSaleGroup
WHERE itemPackingTypeFk IS NOT NULL;
SELECT COUNT(*) INTO vHasItemPackingType
FROM ticket t
JOIN sale s ON s.ticketFk = t.id
JOIN item i ON i.id = s.itemFk
WHERE t.id = vSelf
AND i.itemPackingTypeFk = vOriginalItemPackingTypeFk;
CREATE OR REPLACE TEMPORARY TABLE tmp.ticketIPT(
ticketFk INT,
itemPackingTypeFk VARCHAR(1)
) ENGINE = MEMORY;
) ENGINE=MEMORY
SELECT vSelf ticketFk, vOriginalItemPackingTypeFk itemPackingTypeFk;
CASE vPackingTypesToSplit
WHEN 0 THEN
INSERT INTO tmp.ticketIPT(ticketFk, itemPackingTypeFk)
VALUES(vSelf, vItemPackingTypeFk);
WHEN 1 THEN
INSERT INTO tmp.ticketIPT(ticketFk, itemPackingTypeFk)
SELECT vSelf, itemPackingTypeFk
FROM tSaleGroup
WHERE itemPackingTypeFk IS NOT NULL;
ELSE
OPEN vSaleGroup;
FETCH vSaleGroup INTO vItemPackingTypeFk;
IF NOT vHasItemPackingType THEN
LEAVE proc;
END IF;
INSERT INTO tmp.ticketIPT(ticketFk, itemPackingTypeFk)
VALUES(vSelf, vItemPackingTypeFk);
CREATE OR REPLACE TEMPORARY TABLE tSalesToMove (
ticketFk INT,
saleFk INT,
itemPackingTypeFk INT
) ENGINE=MEMORY;
l: LOOP
SET vDone = FALSE;
FETCH vSaleGroup INTO vItemPackingTypeFk;
INSERT INTO tSalesToMove (saleFk, itemPackingTypeFk)
SELECT s.id, i.itemPackingTypeFk
FROM ticket t
JOIN sale s ON s.ticketFk = t.id
JOIN item i ON i.id = s.itemFk
WHERE t.id = vSelf
AND i.itemPackingTypeFk <> vOriginalItemPackingTypeFk;
IF vDone THEN
LEAVE l;
END IF;
OPEN vItemPackingTypes;
CALL ticket_Clone(vSelf, vNewTicketFk);
l: LOOP
SET vDone = FALSE;
FETCH vItemPackingTypes INTO vItemPackingTypeFk;
INSERT INTO tmp.ticketIPT(ticketFk, itemPackingTypeFk)
VALUES(vNewTicketFk, vItemPackingTypeFk);
END LOOP;
IF vDone THEN
LEAVE l;
END IF;
CLOSE vSaleGroup;
CALL ticket_Clone(vSelf, vNewTicketFk);
SELECT s.id
FROM sale s
JOIN tSale ts ON ts.id = s.id
JOIN tmp.ticketIPT t ON t.itemPackingTypeFk = ts.itemPackingTypeFk
FOR UPDATE;
UPDATE tSalesToMove
SET ticketFk = vNewTicketFk
WHERE itemPackingTypeFk = vItemPackingTypeFk;
UPDATE sale s
JOIN tSale ts ON ts.id = s.id
JOIN tmp.ticketIPT t ON t.itemPackingTypeFk = ts.itemPackingTypeFk
SET s.ticketFk = t.ticketFk;
END LOOP;
SELECT itemPackingTypeFk INTO vItemPackingTypeFk
FROM tSaleGroup sg
WHERE sg.itemPackingTypeFk IS NOT NULL
ORDER BY sg.itemPackingTypeFk
LIMIT 1;
CLOSE vItemPackingTypes;
UPDATE sale s
JOIN tSale ts ON ts.id = s.id
JOIN tmp.ticketIPT t ON t.itemPackingTypeFk = vItemPackingTypeFk
SET s.ticketFk = t.ticketFk
WHERE ts.itemPackingTypeFk IS NULL;
END CASE;
UPDATE sale s
JOIN tSalesToMove stm ON stm.saleFk = s.id
SET s.ticketFk = stm.ticketFk
WHERE stm.ticketFk;
COMMIT;
INSERT INTO tmp.ticketIPT (ticketFk, itemPackingTypeFk)
SELECT ticketFk, itemPackingTypeFk
FROM tSalesToMove
GROUP BY ticketFk;
DROP TEMPORARY TABLE
tSale,
tSaleGroup;
DROP TEMPORARY TABLE tSalesToMove;
END$$
DELIMITER ;

View File

@ -21,6 +21,8 @@ BEGIN
SET businessFk = vNewBusinessFk
WHERE id = vSelf;
CALL queueMember_updateQueue(vNewBusinessFk);
IF vOldBusinessFk IS NULL THEN
CALL account.account_enable(vSelf);

View File

@ -3,10 +3,20 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`business_afterUpdate`
AFTER UPDATE ON `business`
FOR EACH ROW
BEGIN
DECLARE vIsActive BOOL;
DECLARE vExtension VARCHAR(10);
CALL worker_updateBusiness(NEW.workerFk);
IF NOT (OLD.workerFk <=> NEW.workerFk) THEN
CALL worker_updateBusiness(OLD.workerFk);
END IF;
IF NOT (OLD.departmentFk <=> NEW.departmentFk) THEN
SELECT COUNT(*) INTO vIsActive FROM worker WHERE businessFk = NEW.id;
IF vIsActive THEN
CALL queueMember_updateQueue(NEW.id);
END IF;
END IF;
END$$
DELIMITER ;

View File

@ -3,6 +3,8 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`ticketRefund_beforeInse
BEFORE INSERT ON `ticketRefund`
FOR EACH ROW
BEGIN
CALL ticketRefund_upsert(NEW.refundTicketFk, NEW.originalTicketFk);
SET NEW.editorFk = account.myUser_getId();
END$$
DELIMITER ;

View File

@ -3,6 +3,8 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`ticketRefund_beforeUpda
BEFORE UPDATE ON `ticketRefund`
FOR EACH ROW
BEGIN
CALL ticketRefund_upsert(NEW.refundTicketFk, NEW.originalTicketFk);
SET NEW.editorFk = account.myUser_getId();
END$$
DELIMITER ;

View File

@ -4,5 +4,14 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`travelThermograph_befor
FOR EACH ROW
BEGIN
SET NEW.editorFk = account.myUser_getId();
IF NEW.travelFk IS NULL AND
(SELECT COUNT(*) FROM travelThermograph
WHERE thermographFk = NEW.thermographFk
AND travelFk IS NULL
AND id <> NEW.id) > 0
THEN
CALL util.throw('Duplicate thermographFk without travelFk not allowed.');
END IF;
END$$
DELIMITER ;

View File

@ -4,5 +4,14 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`travelThermograph_befor
FOR EACH ROW
BEGIN
SET NEW.editorFk = account.myUser_getId();
IF NEW.travelFk IS NULL AND
(SELECT COUNT(*) FROM travelThermograph
WHERE thermographFk = NEW.thermographFk
AND travelFk IS NULL
AND id <> NEW.id) > 0
THEN
CALL util.throw('Duplicate thermographFk without travelFk not allowed.');
END IF;
END$$
DELIMITER ;

View File

@ -13,6 +13,5 @@ AS SELECT `am`.`id` AS `Id_Agencia`,
`am`.`reportMail` AS `send_mail`,
`am`.`isActive` AS `tpv`,
`am`.`code` AS `code`,
`am`.`showAgencyName` AS `show_AgencyName`,
`am`.`isRiskFree` AS `isRiskFree`
FROM `vn`.`agencyMode` `am`

View File

@ -22,7 +22,6 @@ AS SELECT `c`.`id` AS `id_cliente`,
`c`.`credit` AS `credito`,
`c`.`countryFk` AS `Id_Pais`,
`c`.`isActive` AS `activo`,
`c`.`gestdocFk` AS `gestdoc_id`,
`c`.`quality` AS `calidad`,
`c`.`payMethodFk` AS `pay_met_id`,
`c`.`created` AS `created`,

View File

@ -1,8 +0,0 @@
CREATE OR REPLACE DEFINER=`root`@`localhost`
SQL SECURITY DEFINER
VIEW `vn2008`.`Compres_mark`
AS SELECT `bm`.`id` AS `Id_Compra`,
`bm`.`comment` AS `comment`,
`bm`.`mark` AS `mark`,
`bm`.`odbcDate` AS `odbc_date`
FROM `vn`.`buyMark` `bm`

View File

@ -0,0 +1,7 @@
UPDATE vn.itemShelving
SET isChecked = TRUE
WHERE isChecked;
UPDATE vn.itemShelving
SET isChecked = FALSE
WHERE NOT isChecked;

View File

@ -0,0 +1,3 @@
ALTER TABLE vn.clientObservation DROP COLUMN IF EXISTS observationTypeFk;
ALTER TABLE vn.clientObservation ADD COLUMN IF NOT EXISTS observationTypeFk TINYINT(3) UNSIGNED NULL;
ALTER TABLE vn.clientObservation ADD CONSTRAINT clientObservationTypeFk FOREIGN KEY IF NOT EXISTS (observationTypeFk) REFERENCES vn.observationType(id);

View File

@ -0,0 +1,3 @@
INSERT IGNORE INTO vn.observationType
SET description = 'Finance',
code = 'finance';

View File

@ -0,0 +1,3 @@
DELETE FROM salix.ACL
WHERE model = 'WorkerLog'
AND property = '*';

View File

@ -0,0 +1,3 @@
UPDATE vn.sale
SET originalQuantity = quantity
WHERE originalQuantity IS NULL

View File

@ -0,0 +1 @@
-- ALTER TABLE vn.sale MODIFY COLUMN originalQuantity decimal(10,2) DEFAULT 0.00 NOT NULL COMMENT 'Se utiliza para notificar a través de rocket los cambios de quantity';

View File

@ -0,0 +1,3 @@
ALTER TABLE `vn`.`travelThermograph`
ADD COLUMN `maxTemperature` DECIMAL(5,2) NULL AFTER `temperatureFk`,
ADD COLUMN `minTemperature` DECIMAL(5,2) NULL AFTER `maxTemperature`;

View File

@ -0,0 +1,2 @@
ALTER TABLE `vn`.`travelThermograph` DROP FOREIGN KEY travelThermographDmsFgn;
ALTER TABLE `vn`.`travelThermograph` ADD CONSTRAINT travelThermographDmsFgn FOREIGN KEY (dmsFk) REFERENCES vn.dms(id) ON DELETE CASCADE ON UPDATE CASCADE;

View File

@ -0,0 +1,31 @@
-- vn.priceDelta definition
CREATE OR REPLACE TABLE vn.priceDelta (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`itemTypeFk` smallint(5) unsigned NOT NULL,
`minSize` int(10) unsigned DEFAULT NULL COMMENT 'Minimum item.size',
`maxSize` int(10) unsigned DEFAULT NULL COMMENT 'Maximum item.size',
`inkFk` varchar(3) DEFAULT NULL,
`originFk` tinyint(2) unsigned DEFAULT NULL,
`producerFk` mediumint(3) unsigned DEFAULT NULL,
`fromDated` date DEFAULT NULL,
`toDated` date DEFAULT NULL,
`absIncreasing` decimal(10,3) DEFAULT NULL COMMENT 'Absolute increasing of final price',
`ratIncreasing` int(11) DEFAULT NULL COMMENT 'Increasing ratio for the cost price',
`warehouseFk` smallint(6) unsigned NOT NULL,
`created` timestamp NOT NULL DEFAULT current_timestamp(),
`editorFk` int(10) unsigned DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `priceDelta_itemType_FK` (`itemTypeFk`),
KEY `priceDelta_ink_FK` (`inkFk`),
KEY `priceDelta_producer_FK` (`producerFk`),
KEY `priceDelta_warehouse_FK` (`warehouseFk`),
KEY `priceDelta_worker_FK` (`editorFk`),
CONSTRAINT `priceDelta_ink_FK` FOREIGN KEY (`inkFk`) REFERENCES `ink` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_itemType_FK` FOREIGN KEY (`itemTypeFk`) REFERENCES `itemType` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_producer_FK` FOREIGN KEY (`producerFk`) REFERENCES `producer` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_warehouse_FK` FOREIGN KEY (`warehouseFk`) REFERENCES `warehouse` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_worker_FK` FOREIGN KEY (`editorFk`) REFERENCES `worker` (`id`) ON DELETE SET NULL ON UPDATE CASCADE
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci COMMENT='Defines the increasing o decreasing for ranges of items';
GRANT INSERT, SELECT, UPDATE, DELETE ON TABLE vn.priceDelta TO buyer;

View File

@ -0,0 +1,32 @@
-- Place your SQL code here
-- vn.priceDelta definition
CREATE OR REPLACE TABLE vn.priceDelta (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`itemTypeFk` smallint(5) unsigned NOT NULL,
`minSize` int(10) unsigned DEFAULT NULL COMMENT 'Minimum item.size',
`maxSize` int(10) unsigned DEFAULT NULL COMMENT 'Maximum item.size',
`inkFk` varchar(3) DEFAULT NULL,
`originFk` tinyint(2) unsigned DEFAULT NULL,
`producerFk` mediumint(3) unsigned DEFAULT NULL,
`fromDated` date DEFAULT NULL,
`toDated` date DEFAULT NULL,
`absIncreasing` decimal(10,3) DEFAULT NULL COMMENT 'Absolute increasing of final price',
`ratIncreasing` int(11) DEFAULT NULL COMMENT 'Increasing ratio for the cost price',
`warehouseFk` smallint(6) unsigned NOT NULL,
`created` timestamp NOT NULL DEFAULT current_timestamp(),
`editorFk` int(10) unsigned DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `priceDelta_itemType_FK` (`itemTypeFk`),
KEY `priceDelta_ink_FK` (`inkFk`),
KEY `priceDelta_producer_FK` (`producerFk`),
KEY `priceDelta_warehouse_FK` (`warehouseFk`),
KEY `priceDelta_worker_FK` (`editorFk`),
CONSTRAINT `priceDelta_ink_FK` FOREIGN KEY (`inkFk`) REFERENCES `ink` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_itemType_FK` FOREIGN KEY (`itemTypeFk`) REFERENCES `itemType` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_producer_FK` FOREIGN KEY (`producerFk`) REFERENCES `producer` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_warehouse_FK` FOREIGN KEY (`warehouseFk`) REFERENCES `warehouse` (`id`) ON UPDATE CASCADE,
CONSTRAINT `priceDelta_worker_FK` FOREIGN KEY (`editorFk`) REFERENCES `worker` (`id`) ON DELETE SET NULL ON UPDATE CASCADE
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_unicode_ci COMMENT='Defines the increasing o decreasing for ranges of items';
GRANT INSERT, SELECT, UPDATE, DELETE ON TABLE vn.priceDelta TO buyer;

View File

@ -0,0 +1,2 @@
ALTER TABLE vn.agencyMode
CHANGE IF EXISTS showAgencyName showAgencyName__ tinyint(1) DEFAULT 1 COMMENT '@deprecated 2024-09-24';

View File

@ -0,0 +1 @@
ALTER TABLE dipole.expedition_PrintOut DROP COLUMN IF EXISTS isChecked;

View File

@ -0,0 +1,3 @@
-- Place your SQL code here
ALTER TABLE vn.priceDelta ADD IF NOT EXISTS zoneGeoFk int(11) NULL COMMENT 'Application area for the bonus component';
ALTER TABLE vn.priceDelta ADD CONSTRAINT priceDelta_zoneGeo_FK FOREIGN KEY IF NOT EXISTS (zoneGeoFk) REFERENCES vn.zoneGeo(id) ON DELETE RESTRICT ON UPDATE CASCADE;

View File

@ -0,0 +1,4 @@
-- Place your SQL code here
RENAME TABLE vn.stockBuyed TO vn.stockBuyed__;
ALTER TABLE vn.stockBuyed__
COMMENT='@deprecated 2024-10-01 rename and refactor to stockBought';

View File

@ -0,0 +1 @@
ALTER TABLE account.user MODIFY COLUMN emailVerified tinyint(1) DEFAULT FALSE NOT NULL;

View File

@ -0,0 +1 @@
ALTER TABLE bs.defaulter MODIFY COLUMN hasChanged tinyint(1) DEFAULT FALSE NOT NULL;

View File

@ -0,0 +1 @@
ALTER TABLE vn.address MODIFY COLUMN isEqualizated tinyint(1) DEFAULT FALSE NOT NULL;

View File

@ -0,0 +1 @@
ALTER TABLE vn.chat MODIFY COLUMN checkUserStatus tinyint(1) DEFAULT FALSE NOT NULL;

View File

@ -0,0 +1,3 @@
ALTER TABLE vn.warehouse
MODIFY COLUMN isOrigin tinyint(1) DEFAULT FALSE NOT NULL,
MODIFY COLUMN isDestiny tinyint(1) DEFAULT FALSE NOT NULL;

View File

@ -0,0 +1 @@
ALTER TABLE vn.zoneIncluded MODIFY COLUMN isIncluded tinyint(1) DEFAULT FALSE NOT NULL;

View File

@ -0,0 +1,3 @@
-- Place your SQL code here
ALTER TABLE hedera.`order` ADD IF NOT EXISTS rowUpdated DATETIME NULL
COMMENT 'Timestamp for last updated record in orderRow table';

View File

@ -0,0 +1 @@
DROP TABLE IF EXISTS vn.buyMark;

View File

@ -0,0 +1,3 @@
ALTER TABLE vn.itemShelving DROP FOREIGN KEY itemShelving_fk2;
ALTER TABLE vn.itemShelving ADD CONSTRAINT itemShelving_fk2
FOREIGN KEY (shelvingFk) REFERENCES vn.shelving(code) ON DELETE RESTRICT ON UPDATE CASCADE;

View File

@ -0,0 +1,2 @@
-- Place your SQL code here
ALTER TABLE vn.itemShelving ADD IF NOT EXISTS isMoving BOOL DEFAULT FALSE NOT NULL COMMENT 'Indica que se ha marcado este registro para transferirlo a otro sector';

View File

@ -0,0 +1,3 @@
-- Place your SQL code here
ALTER TABLE vn.itemShelving DROP COLUMN IF EXISTS isMoving;
ALTER TABLE vn.itemShelving ADD IF NOT EXISTS movingState ENUM('selected','printed') NULL;

View File

@ -0,0 +1,3 @@
-- Place your SQL code here
ALTER TABLE hedera.`order` ADD IF NOT EXISTS rowUpdated DATETIME NULL
COMMENT 'Timestamp for last updated record in orderRow table';

View File

@ -0,0 +1,6 @@
ALTER TABLE `vn`.`operator`
ADD COLUMN `machineFk` int(11) DEFAULT NULL,
ADD CONSTRAINT `operator_machine_FK` FOREIGN KEY (`machineFk`) REFERENCES `vn`.`machine` (`id`) ON DELETE SET NULL ON UPDATE CASCADE;
INSERT INTO salix.ACL (model,property,accessType,permission,principalType,principalId)
VALUES ('Machine','*','*','ALLOW','ROLE','productionBoss');

View File

@ -0,0 +1,3 @@
-- Place your SQL code here
ALTER TABLE vn.itemShelving DROP COLUMN IF EXISTS isMoving;
ALTER TABLE vn.itemShelving ADD IF NOT EXISTS movingState ENUM('selected','printed') NULL;

View File

@ -0,0 +1,3 @@
ALTER TABLE `vn`.`ticketConfig`
ADD COLUMN `closureDaysAgo` int(11) NOT NULL DEFAULT 2 COMMENT 'Number of days to look back for ticket closure',
ADD CONSTRAINT `closureDaysAgo_check` CHECK (`closureDaysAgo` > 0);

View File

@ -0,0 +1,13 @@
UPDATE `vn`.`client` c
JOIN `vn`.`country` co ON co.id=c.countryFk
SET c.hasDailyInvoice = co.hasDailyInvoice
WHERE co.hasDailyInvoice IS NOT NULL
AND c.hasDailyInvoice = FALSE;
UPDATE `vn`.`client` c
JOIN `vn`.`province` p ON p.id=c.provinceFk
JOIN `vn`.`autonomy` a ON a.id = p.autonomyFk
SET c.hasDailyInvoice = a.hasDailyInvoice
WHERE a.hasDailyInvoice IS NOT NULL
AND c.hasDailyInvoice = FALSE;

View File

@ -0,0 +1 @@
ALTER TABLE vn.client CHANGE gestdocFk gestdocFk__ int(11) DEFAULT NULL NULL COMMENT '@deprecated 2024-10-17';

View File

@ -1,68 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('SmartTable SearchBar integration', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('salesPerson', 'item');
await page.waitToClick(selectors.globalItems.searchButton);
});
afterAll(async() => {
await browser.close();
});
it('should search by type in searchBar, reload page and have same results', async() => {
await page.waitToClick(selectors.itemsIndex.openAdvancedSearchButton);
await page.autocompleteSearch(selectors.itemsIndex.advancedSearchItemType, 'Anthurium');
await page.waitToClick(selectors.itemsIndex.advancedSearchButton);
await page.waitForNumberOfElements(selectors.itemsIndex.searchResult, 4);
await page.reload({
waitUntil: 'networkidle2'
});
await page.waitForNumberOfElements(selectors.itemsIndex.searchResult, 4);
await page.write(selectors.itemsIndex.advancedSmartTableGrouping, '1');
await page.keyboard.press('Enter');
await page.waitForNumberOfElements(selectors.itemsIndex.searchResult, 2);
await page.reload({
waitUntil: 'networkidle2'
});
await page.waitForNumberOfElements(selectors.itemsIndex.searchResult, 1);
});
it('should filter in section without smart-table and search in searchBar go to zone section', async() => {
await page.loginAndModule('salesPerson', 'zone');
await page.waitToClick(selectors.globalItems.searchButton);
await page.doSearch('A');
const firstCount = await page.countElement(selectors.zoneIndex.searchResult);
await page.doSearch('A');
const secondCount = await page.countElement(selectors.zoneIndex.searchResult);
expect(firstCount).toEqual(7);
expect(secondCount).toEqual(7);
});
it('should order orders by first id and order by last id, reload page and have same order', async() => {
await page.loginAndModule('developer', 'item');
await page.accessToSection('item.fixedPrice');
await page.keyboard.press('Enter');
await page.waitForTextInField(selectors.itemFixedPrice.firstItemID, '1');
await page.waitToClick(selectors.itemFixedPrice.orderColumnId);
await page.reload({
waitUntil: 'networkidle2'
});
await page.waitForTextInField(selectors.itemFixedPrice.firstItemID, '3');
});
});

View File

@ -1,42 +0,0 @@
import selectors from '../../helpers/selectors';
import getBrowser from '../../helpers/puppeteer';
describe('Client Add notes path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('employee', 'client');
await page.accessToSearchResult('Bruce Banner');
await page.accessToSection('client.card.note.index');
});
afterAll(async() => {
await browser.close();
});
it(`should reach the notes index`, async() => {
await page.waitForState('client.card.note.index');
});
it(`should click on the add note button`, async() => {
await page.waitToClick(selectors.clientNotes.addNoteFloatButton);
await page.waitForState('client.card.note.create');
});
it(`should create a note`, async() => {
await page.waitForSelector(selectors.clientNotes.note);
await page.type(`${selectors.clientNotes.note} textarea`, 'Meeting with Black Widow 21st 9am');
await page.waitToClick(selectors.clientNotes.saveButton);
const message = await page.waitForSnackbar();
expect(message.text).toContain('Data saved!');
});
it('should confirm the note was created', async() => {
const result = await page.waitToGetProperty(selectors.clientNotes.firstNoteText, 'innerText');
expect(result).toEqual('Meeting with Black Widow 21st 9am');
});
});

View File

@ -28,12 +28,12 @@ describe('Client defaulter path', () => {
const salesPersonName =
await page.waitToGetProperty(selectors.clientDefaulter.firstSalesPersonName, 'innerText');
expect(clientName).toEqual('Bruce Banner');
expect(salesPersonName).toEqual('developer');
expect(clientName).toEqual('Ororo Munroe');
expect(salesPersonName).toEqual('salesperson');
});
it('should first observation not changed', async() => {
const expectedObservation = 'Meeting with Black Widow 21st 9am';
const expectedObservation = 'Madness, as you know, is like gravity, all it takes is a little push';
const result = await page.waitToGetProperty(selectors.clientDefaulter.firstObservation, 'value');
expect(result).toContain(expectedObservation);
@ -62,13 +62,4 @@ describe('Client defaulter path', () => {
await page.write(selectors.clientDefaulter.observation, 'My new observation');
await page.waitToClick(selectors.clientDefaulter.saveButton);
});
it('should first observation changed', async() => {
const message = await page.waitForSnackbar();
await page.waitForSelector(selectors.clientDefaulter.firstObservation);
const result = await page.waitToGetProperty(selectors.clientDefaulter.firstObservation, 'value');
expect(message.text).toContain('Observation saved!');
expect(result).toContain('My new observation');
});
});

View File

@ -1,46 +0,0 @@
import getBrowser from '../../helpers/puppeteer';
const $ = {
id: 'vn-order-summary vn-one:nth-child(1) > vn-label-value:nth-child(1) span',
alias: 'vn-order-summary vn-one:nth-child(1) > vn-label-value:nth-child(2) span',
consignee: 'vn-order-summary vn-one:nth-child(2) > vn-label-value:nth-child(6) span',
subtotal: 'vn-order-summary vn-one.taxes > p:nth-child(1)',
vat: 'vn-order-summary vn-one.taxes > p:nth-child(2)',
total: 'vn-order-summary vn-one.taxes > p:nth-child(3)',
sale: 'vn-order-summary vn-tbody > vn-tr',
};
describe('Order summary path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('employee', 'order');
await page.accessToSearchResult('16');
});
afterAll(async() => {
await browser.close();
});
it('should reach the order summary section and check data', async() => {
await page.waitForState('order.card.summary');
const id = await page.innerText($.id);
const alias = await page.innerText($.alias);
const consignee = await page.innerText($.consignee);
const subtotal = await page.innerText($.subtotal);
const vat = await page.innerText($.vat);
const total = await page.innerText($.total);
const sale = await page.countElement($.sale);
expect(id).toEqual('16');
expect(alias).toEqual('Many places');
expect(consignee).toEqual('address 26 - Gotham (Province one)');
expect(subtotal.length).toBeGreaterThan(1);
expect(vat.length).toBeGreaterThan(1);
expect(total.length).toBeGreaterThan(1);
expect(sale).toBeGreaterThan(0);
});
});

View File

@ -1,69 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
const $ = {
form: 'vn-order-basic-data form',
observation: 'vn-order-basic-data form [vn-name="note"]',
saveButton: `vn-order-basic-data form button[type=submit]`,
acceptButton: '.vn-confirm.shown button[response="accept"]'
};
describe('Order edit basic data path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('employee', 'order');
await page.accessToSearchResult('1');
await page.accessToSection('order.card.basicData');
});
afterAll(async() => {
await browser.close();
});
describe('when confirmed order', () => {
it('should not be able to change the client', async() => {
const message = await page.sendForm($.form, {
client: 'Tony Stark',
address: 'Tony Stark',
});
expect(message.text).toContain(`You can't make changes on the basic data`);
});
});
describe('when new order', () => {
it('should create an order and edit its basic data', async() => {
await page.waitToClick(selectors.globalItems.returnToModuleIndexButton);
await page.waitToClick($.acceptButton);
await page.waitForContentLoaded();
await page.waitToClick(selectors.ordersIndex.createOrderButton);
await page.waitForState('order.create');
await page.autocompleteSearch(selectors.createOrderView.client, 'Jessica Jones');
await page.pickDate(selectors.createOrderView.landedDatePicker);
await page.autocompleteSearch(selectors.createOrderView.agency, 'Other agency');
await page.waitToClick(selectors.createOrderView.createButton);
await page.waitForState('order.card.catalog');
await page.accessToSection('order.card.basicData');
const values = {
client: 'Tony Stark',
address: 'Tony Stark',
agencyMode: 'Other agency'
};
const message = await page.sendForm($.form, values);
await page.reloadSection('order.card.basicData');
const formValues = await page.fetchForm($.form, Object.keys(values));
expect(message.isSuccess).toBeTrue();
expect(formValues).toEqual(values);
});
});
});

View File

@ -1,48 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Order lines', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('employee', 'order');
await page.accessToSearchResult('8');
await page.accessToSection('order.card.line');
});
afterAll(async() => {
await browser.close();
});
it('should check the order subtotal', async() => {
const result = await page
.waitToGetProperty(selectors.orderLine.orderSubtotal, 'innerText');
expect(result).toContain('112.30');
});
it('should delete the first line in the order', async() => {
await page.waitToClick(selectors.orderLine.firstLineDeleteButton);
await page.waitToClick(selectors.orderLine.confirmButton);
const message = await page.waitForSnackbar();
expect(message.text).toContain('Data saved!');
});
it('should confirm the order subtotal has changed', async() => {
await page.waitForTextInElement(selectors.orderLine.orderSubtotal, '92.80');
const result = await page
.waitToGetProperty(selectors.orderLine.orderSubtotal, 'innerText');
expect(result).toContain('92.80');
});
it('should confirm the whole order and redirect to ticket index filtered by clientFk', async() => {
await page.waitToClick(selectors.orderLine.confirmOrder);
await page.expectURL('ticket/index');
await page.expectURL('clientFk');
});
});

View File

@ -1,97 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Order catalog', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('employee', 'order');
});
afterAll(async() => {
await browser.close();
});
it('should open the create new order form', async() => {
await page.waitToClick(selectors.ordersIndex.createOrderButton);
await page.waitForState('order.create');
});
it('should create a new order', async() => {
await page.autocompleteSearch(selectors.createOrderView.client, 'Tony Stark');
await page.pickDate(selectors.createOrderView.landedDatePicker);
await page.autocompleteSearch(selectors.createOrderView.agency, 'Other agency');
await page.waitToClick(selectors.createOrderView.createButton);
await page.waitForState('order.card.catalog');
});
it('should add the realm and type filters and obtain results', async() => {
await page.waitToClick(selectors.orderCatalog.plantRealmButton);
await page.autocompleteSearch(selectors.orderCatalog.type, 'Anthurium');
await page.waitForNumberOfElements('section.product', 4);
const result = await page.countElement('section.product');
expect(result).toEqual(4);
});
it('should perfom an "OR" search for the item tag colors silver and brown', async() => {
await page.waitToClick(selectors.orderCatalog.openTagSearch);
await page.autocompleteSearch(selectors.orderCatalog.tag, 'Color');
await page.autocompleteSearch(selectors.orderCatalog.firstTagAutocomplete, 'silver');
await page.waitToClick(selectors.orderCatalog.addTagButton);
await page.autocompleteSearch(selectors.orderCatalog.secondTagAutocomplete, 'brown');
await page.waitToClick(selectors.orderCatalog.searchTagButton);
await page.waitForNumberOfElements('section.product', 4);
});
it('should perfom an "OR" search for the item tag tallos 2 and 9', async() => {
await page.waitToClick(selectors.orderCatalog.openTagSearch);
await page.autocompleteSearch(selectors.orderCatalog.tag, 'Tallos');
await page.write(selectors.orderCatalog.firstTagValue, '2');
await page.waitToClick(selectors.orderCatalog.addTagButton);
await page.write(selectors.orderCatalog.secondTagValue, '9');
await page.waitToClick(selectors.orderCatalog.searchTagButton);
await page.waitForNumberOfElements('section.product', 2);
});
it('should perform a general search for category', async() => {
await page.write(selectors.orderCatalog.itemTagValue, 'concussion');
await page.keyboard.press('Enter');
await page.waitForNumberOfElements('section.product', 2);
});
it('should perfom an "AND" search for the item tag tallos 2', async() => {
await page.waitToClick(selectors.orderCatalog.openTagSearch);
await page.autocompleteSearch(selectors.orderCatalog.tag, 'Tallos');
await page.write(selectors.orderCatalog.firstTagValue, '2');
await page.waitToClick(selectors.orderCatalog.searchTagButton);
await page.waitForNumberOfElements('section.product', 1);
});
it('should remove the tag filters and have 4 results', async() => {
await page.waitForContentLoaded();
await page.waitToClick(selectors.orderCatalog.sixthFilterRemoveButton);
await page.waitForContentLoaded();
await page.waitToClick(selectors.orderCatalog.fifthFilterRemoveButton);
await page.waitForContentLoaded();
await page.waitToClick(selectors.orderCatalog.fourthFilterRemoveButton);
await page.waitForContentLoaded();
await page.waitToClick(selectors.orderCatalog.thirdFilterRemoveButton);
await page.waitForNumberOfElements('.product', 4);
const result = await page.countElement('section.product');
expect(result).toEqual(4);
});
it('should search for an item by id', async() => {
await page.accessToSearchResult('2');
await page.waitForNumberOfElements('section.product', 1);
const result = await page.countElement('section.product');
expect(result).toEqual(1);
});
});

View File

@ -1,34 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Order Index', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('employee', 'order');
});
afterAll(async() => {
await browser.close();
});
it(`should check the second search result doesn't contain a total of 0€`, async() => {
await page.waitToClick(selectors.globalItems.searchButton);
const result = await page.waitToGetProperty(selectors.ordersIndex.secondSearchResultTotal, 'innerText');
expect(result).not.toContain('0.00');
});
it('should search including empty orders', async() => {
await page.waitToClick(selectors.ordersIndex.openAdvancedSearch);
await page.waitToClick(selectors.ordersIndex.advancedSearchShowEmptyCheckbox);
await page.waitToClick(selectors.ordersIndex.advancedSearchButton);
await page.waitForTextInElement(selectors.ordersIndex.secondSearchResultTotal, '0.00');
const result = await page.waitToGetProperty(selectors.ordersIndex.secondSearchResultTotal, 'innerText');
expect(result).toContain('0.00');
});
});

View File

@ -1,42 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Travel create path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('buyer', 'travel');
});
afterAll(async() => {
await browser.close();
});
it('should create a new travel and check it was created with the correct data', async() => {
const date = Date.vnNew();
date.setDate(15);
date.setUTCHours(0, 0, 0, 0);
await page.waitToClick(selectors.travelIndex.newTravelButton);
await page.waitForState('travel.create');
const values = {
reference: 'Testing reference',
agencyMode: 'inhouse pickup',
shipped: date,
landed: date,
warehouseOut: 'Warehouse One',
warehouseIn: 'Warehouse Five'
};
const message = await page.sendForm('vn-travel-create form', values);
await page.waitForState('travel.card.basicData');
const formValues = await page.fetchForm('vn-travel-basic-data form', Object.keys(values));
expect(message.isSuccess).toBeTrue();
expect(formValues).toEqual(values);
});
});

View File

@ -1,97 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Travel basic data path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('buyer', 'travel');
await page.write(selectors.travelIndex.generalSearchFilter, '3');
await page.keyboard.press('Enter');
await page.accessToSection('travel.card.basicData');
});
afterAll(async() => {
await browser.close();
});
it('should reach the thermograph section', async() => {
await page.waitForState('travel.card.basicData');
});
it('should set a wrong delivery date then receive an error on submit', async() => {
await page.loginAndModule('buyer', 'travel');
await page.write(selectors.travelIndex.generalSearchFilter, '4');
await page.keyboard.press('Enter');
await page.accessToSection('travel.card.basicData');
await page.waitForState('travel.card.basicData');
const lastMonth = Date.vnNew();
lastMonth.setMonth(lastMonth.getMonth() - 2);
await page.pickDate(selectors.travelBasicData.deliveryDate, lastMonth);
await page.waitToClick(selectors.travelBasicData.save);
const message = await page.waitForSnackbar();
expect(message.text).toContain('Landing cannot be lesser than shipment');
});
it('should undo the changes', async() => {
await page.clearInput(selectors.travelBasicData.reference);
await page.write(selectors.travelBasicData.reference, 'totally pointless ref');
await page.waitToClick(selectors.travelBasicData.undoChanges);
const result = await page.waitToGetProperty(selectors.travelBasicData.reference, 'value');
expect(result).toEqual('fourth travel');
});
it('should now edit the whole form then save', async() => {
await page.clearInput(selectors.travelBasicData.reference);
await page.write(selectors.travelBasicData.reference, 'new reference!');
await page.autocompleteSearch(selectors.travelBasicData.agency, 'Entanglement');
await page.autocompleteSearch(selectors.travelBasicData.outputWarehouse, 'Warehouse Three');
await page.autocompleteSearch(selectors.travelBasicData.inputWarehouse, 'Warehouse Four');
await page.waitToClick(selectors.travelBasicData.delivered);
await page.waitToClick(selectors.travelBasicData.received);
await page.waitToClick(selectors.travelBasicData.save);
const message = await page.waitForSnackbar();
expect(message.text).toContain('Data saved!');
});
it('should reload the section and check the reference was saved', async() => {
await page.reloadSection('travel.card.basicData');
const result = await page.waitToGetProperty(selectors.travelBasicData.reference, 'value');
expect(result).toEqual('new reference!');
});
it('should check the agency was saved', async() => {
const result = await page.waitToGetProperty(selectors.travelBasicData.agency, 'value');
expect(result).toEqual('Entanglement');
});
it('should check the output warehouse date was saved', async() => {
const result = await page.waitToGetProperty(selectors.travelBasicData.outputWarehouse, 'value');
expect(result).toEqual('Warehouse Three');
});
it('should check the input warehouse date was saved', async() => {
const result = await page.waitToGetProperty(selectors.travelBasicData.inputWarehouse, 'value');
expect(result).toEqual('Warehouse Four');
});
it(`should check the delivered checkbox was saved even tho it doesn't make sense`, async() => {
await page.waitForClassPresent(selectors.travelBasicData.delivered, 'checked');
});
it(`should check the received checkbox was saved even tho it doesn't make sense`, async() => {
await page.waitForClassPresent(selectors.travelBasicData.received, 'checked');
});
});

View File

@ -1,36 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Travel descriptor path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('buyer', 'travel');
await page.write(selectors.travelIndex.generalSearchFilter, '3');
await page.keyboard.press('Enter');
await page.waitForState('travel.card.summary');
});
afterAll(async() => {
await browser.close();
});
it('should click the descriptor button to navigate to the travel index showing all travels with current agency', async() => {
await page.waitToClick(selectors.travelDescriptor.filterByAgencyButton);
await page.waitForState('travel.index');
const result = await page.countElement(selectors.travelIndex.anySearchResult);
expect(result).toBeGreaterThanOrEqual(1);
});
it('should navigate to the first search result', async() => {
await page.waitToClick(selectors.travelIndex.firstSearchResult);
await page.waitForState('travel.card.summary');
const state = await page.getState();
expect(state).toBe('travel.card.summary');
});
});

View File

@ -1,42 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Travel extra community path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('buyer', 'travel');
await page.accessToSection('travel.extraCommunity');
});
afterAll(async() => {
await browser.close();
});
it('should edit the travel reference and the locked kilograms', async() => {
await page.waitToClick(selectors.travelExtraCommunity.removeContinentFilter);
await page.waitForSpinnerLoad();
await page.writeOnEditableTD(selectors.travelExtraCommunity.firstTravelReference, 'edited reference');
await page.waitForSpinnerLoad();
await page.writeOnEditableTD(selectors.travelExtraCommunity.firstTravelLockedKg, '1500');
const message = await page.waitForSnackbar();
expect(message.text).toContain('Data saved!');
});
it('should reload the index and confirm the reference and locked kg were edited', async() => {
await page.accessToSection('travel.index');
await page.accessToSection('travel.extraCommunity');
await page.waitToClick(selectors.travelExtraCommunity.removeContinentFilter);
await page.waitForTextInElement(selectors.travelExtraCommunity.firstTravelReference, 'edited reference');
const reference = await page.getProperty(selectors.travelExtraCommunity.firstTravelReference, 'innerText');
const lockedKg = await page.getProperty(selectors.travelExtraCommunity.firstTravelLockedKg, 'innerText');
expect(reference).toContain('edited reference');
expect(lockedKg).toContain(1500);
});
});

View File

@ -1,64 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Travel thermograph path', () => {
const thermographName = '7H3-37H3RN4L-FL4M3';
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('buyer', 'travel');
await page.write(selectors.travelIndex.generalSearchFilter, '3');
await page.keyboard.press('Enter');
await page.accessToSection('travel.card.thermograph.index');
});
afterAll(async() => {
await browser.close();
});
it('should reach the thermograph section', async() => {
await page.waitForState('travel.card.thermograph.index');
});
it('should click the add thermograph floating button', async() => {
await page.waitToClick(selectors.travelThermograph.add);
await page.waitForState('travel.card.thermograph.create');
});
it('should click on the add thermograph icon of the thermograph autocomplete', async() => {
await page.waitToClick(selectors.travelThermograph.addThermographIcon);
await page.write(selectors.travelThermograph.newThermographId, thermographName);
await page.autocompleteSearch(selectors.travelThermograph.newThermographModel, 'TEMPMATE');
await page.autocompleteSearch(selectors.travelThermograph.newThermographWarehouse, 'Warehouse Two');
await page.autocompleteSearch(selectors.travelThermograph.newThermographTemperature, 'Warm');
await page.waitToClick(selectors.travelThermograph.createThermographButton);
});
it('should select the file to upload', async() => {
let currentDir = process.cwd();
let filePath = `${currentDir}/e2e/assets/thermograph.jpeg`;
const [fileChooser] = await Promise.all([
page.waitForFileChooser(),
page.waitToClick(selectors.travelThermograph.uploadIcon)
]);
await fileChooser.accept([filePath]);
await page.waitToClick(selectors.travelThermograph.upload);
const message = await page.waitForSnackbar();
const state = await page.getState();
expect(message.text).toContain('Data saved!');
expect(state).toBe('travel.card.thermograph.index');
});
it('should check everything was saved correctly', async() => {
const result = await page.waitToGetProperty(selectors.travelThermograph.createdThermograph, 'innerText');
expect(result).toContain(thermographName);
});
});

View File

@ -1,62 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Travel search panel path', () => {
let browser;
let page;
let httpRequest;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('buyer', 'travel');
page.on('request', req => {
if (req.url().includes(`Travels/filter`))
httpRequest = req.url();
});
});
afterAll(async() => {
await browser.close();
});
it('should filter using all the fields', async() => {
await page.click(selectors.travelIndex.chip);
await page.write(selectors.travelIndex.generalSearchFilter, 'travel');
await page.keyboard.press('Enter');
expect(httpRequest).toContain('search=travel');
await page.click(selectors.travelIndex.chip);
await page.autocompleteSearch(selectors.travelIndex.agencyFilter, 'Entanglement');
expect(httpRequest).toContain('agencyModeFk');
await page.click(selectors.travelIndex.chip);
await page.autocompleteSearch(selectors.travelIndex.warehouseOutFilter, 'Warehouse One');
expect(httpRequest).toContain('warehouseOutFk');
await page.click(selectors.travelIndex.chip);
await page.autocompleteSearch(selectors.travelIndex.warehouseInFilter, 'Warehouse Two');
expect(httpRequest).toContain('warehouseInFk');
await page.click(selectors.travelIndex.chip);
await page.overwrite(selectors.travelIndex.scopeDaysFilter, '15');
await page.keyboard.press('Enter');
expect(httpRequest).toContain('scopeDays=15');
await page.click(selectors.travelIndex.chip);
await page.autocompleteSearch(selectors.travelIndex.continentFilter, 'Asia');
expect(httpRequest).toContain('continent');
await page.click(selectors.travelIndex.chip);
await page.write(selectors.travelIndex.totalEntriesFilter, '1');
await page.keyboard.press('Enter');
expect(httpRequest).toContain('totalEntries=1');
});
});

View File

@ -1,104 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Zone basic data path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('deliveryAssistant',
'zone'); // turns up the zone module name and route aint the same lol
await page.accessToSearchResult('10');
await page.accessToSection('zone.card.basicData');
});
afterAll(async() => {
await browser.close();
});
it('should reach the basic data section', async() => {
await page.waitForState('zone.card.basicData');
});
it('should edit de form and then save', async() => {
await page.clearInput(selectors.zoneBasicData.name);
await page.write(selectors.zoneBasicData.name, 'Brimstone teleportation');
await page.autocompleteSearch(selectors.zoneBasicData.agency, 'Quantum break device');
await page.clearInput(selectors.zoneBasicData.maxVolume);
await page.write(selectors.zoneBasicData.maxVolume, '10');
await page.clearInput(selectors.zoneBasicData.travelingDays);
await page.write(selectors.zoneBasicData.travelingDays, '1');
await page.clearInput(selectors.zoneBasicData.closing);
await page.pickTime(selectors.zoneBasicData.closing, '21:00');
await page.clearInput(selectors.zoneBasicData.price);
await page.write(selectors.zoneBasicData.price, '999');
await page.clearInput(selectors.zoneBasicData.bonus);
await page.write(selectors.zoneBasicData.bonus, '100');
await page.clearInput(selectors.zoneBasicData.inflation);
await page.write(selectors.zoneBasicData.inflation, '200');
await page.waitToClick(selectors.zoneBasicData.volumetric);
await page.waitToClick(selectors.zoneBasicData.saveButton);
const message = await page.waitForSnackbar();
expect(message.text).toContain('Data saved!');
});
it('should now reload the section', async() => {
await page.reloadSection('zone.card.basicData');
});
it('should confirm the name was updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.name, 'value');
expect(result).toEqual('Brimstone teleportation');
});
it('should confirm the agency was updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.agency, 'value');
expect(result).toEqual('Quantum break device');
});
it('should confirm the max volume was updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.maxVolume, 'value');
expect(result).toEqual('10');
});
it('should confirm the traveling days were updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.travelingDays, 'value');
expect(result).toEqual('1');
});
it('should confirm the closing hour was updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.closing, 'value');
expect(result).toEqual('21:00');
});
it('should confirm the price was updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.price, 'value');
expect(result).toEqual('999');
});
it('should confirm the bonus was updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.bonus, 'value');
expect(result).toEqual('100');
});
it('should confirm the inflation was updated', async() => {
const result = await page.waitToGetProperty(selectors.zoneBasicData.inflation, 'value');
expect(result).toEqual('200');
});
it('should confirm the volumetric checkbox was checked', async() => {
await page.waitForClassPresent(selectors.zoneBasicData.volumetric, 'checked');
});
});

View File

@ -1,32 +0,0 @@
import selectors from '../../helpers/selectors.js';
import getBrowser from '../../helpers/puppeteer';
describe('Zone descriptor path', () => {
let browser;
let page;
beforeAll(async() => {
browser = await getBrowser();
page = browser.page;
await page.loginAndModule('deliveryAssistant', 'zone');
await page.accessToSearchResult('13');
});
afterAll(async() => {
await browser.close();
});
it('should eliminate the zone using the descriptor option', async() => {
await page.waitToClick(selectors.zoneDescriptor.menu);
await page.waitToClick(selectors.zoneDescriptor.deleteZone);
await page.respondToDialog('accept');
await page.waitForState('zone.index');
});
it('should search for the deleted zone to find no results', async() => {
await page.doSearch('13');
const count = await page.countElement(selectors.zoneIndex.searchResult);
expect(count).toEqual(0);
});
});

View File

@ -240,5 +240,6 @@
"There is already a tray with the same height": "There is already a tray with the same height",
"The height must be greater than 50cm": "The height must be greater than 50cm",
"The maximum height of the wagon is 200cm": "The maximum height of the wagon is 200cm",
"The quantity claimed cannot be greater than the quantity of the line": "The quantity claimed cannot be greater than the quantity of the line"
"The quantity claimed cannot be greater than the quantity of the line": "The quantity claimed cannot be greater than the quantity of the line",
"There are tickets for this area, delete them first": "There are tickets for this area, delete them first"
}

View File

@ -350,6 +350,7 @@
"Cmr file does not exist": "El archivo del cmr no existe",
"You are not allowed to modify the alias": "No estás autorizado a modificar el alias",
"The address of the customer must have information about Incoterms and Customs Agent": "El consignatario del cliente debe tener informado Incoterms y Agente de aduanas",
"No invoice series found for these parameters": "No se encontró una serie para estos parámetros",
"The line could not be marked": "La linea no puede ser marcada",
"Through this procedure, it is not possible to modify the password of users with verified email": "Mediante este procedimiento, no es posible modificar la contraseña de usuarios con correo verificado",
"They're not your subordinate": "No es tu subordinado/a.",
@ -378,5 +379,10 @@
"There is already a tray with the same height": "Ya existe una bandeja con la misma altura",
"The height must be greater than 50cm": "La altura debe ser superior a 50cm",
"The maximum height of the wagon is 200cm": "La altura máxima es 200cm",
"The quantity claimed cannot be greater than the quantity of the line": "La cantidad reclamada no puede ser mayor que la cantidad de la línea"
"The entry does not have stickers": "La entrada no tiene etiquetas",
"This buyer has already made a reservation for this date": "Este comprador ya ha hecho una reserva para esta fecha",
"No valid travel thermograph found": "No se encontró un termógrafo válido",
"The quantity claimed cannot be greater than the quantity of the line": "La cantidad reclamada no puede ser mayor que la cantidad de la línea",
"type cannot be blank": "Se debe rellenar el tipo",
"There are tickets for this area, delete them first": "Hay tickets para esta sección, borralos primero"
}

View File

@ -350,6 +350,7 @@
"Cmr file does not exist": "Le fichier cmr n'existe pas",
"You are not allowed to modify the alias": "Vous n'êtes pas autorisé à modifier l'alias",
"The address of the customer must have information about Incoterms and Customs Agent": "L'adresse du client doit contenir des informations sur les Incoterms et l'agent des douanes",
"No invoice series found for these parameters": "Aucune série de facture trouvée pour ces paramètres",
"The line could not be marked": "La ligne ne peut pas être marquée",
"This password can only be changed by the user themselves": "Ce mot de passe ne peut être modifié que par l'utilisateur lui-même",
"They're not your subordinate": "Ce n'est pas votre subordonné.",

View File

@ -350,6 +350,7 @@
"Cmr file does not exist": "O arquivo CMR não existe",
"You are not allowed to modify the alias": "Você não tem permissão para modificar o alias",
"The address of the customer must have information about Incoterms and Customs Agent": "O endereço do cliente deve ter informações sobre Incoterms e Agente Aduaneiro",
"No invoice series found for these parameters": "Nenhuma série de fatura encontrada para esses parâmetros",
"The line could not be marked": "A linha não pôde ser marcada",
"This password can only be changed by the user themselves": "Esta senha só pode ser alterada pelo próprio usuário",
"They're not your subordinate": "Eles não são seus subordinados.",

View File

@ -25,7 +25,12 @@
"type": "belongsTo",
"model": "VnUser",
"foreignKey": "user_id"
},
"queueMember": {
"type": "belongsTo",
"model": "QueueMember",
"foreignKey": "extension",
"primaryKey": "extension"
}
}
}
}

View File

@ -85,16 +85,11 @@ module.exports = Self => {
const updatedClaim = await claim.updateAttributes(args, myOptions);
const salesPerson = claim.client().salesPersonUser();
if (salesPerson) {
if (changedPickup && updatedClaim.pickup)
await notifyPickUp(ctx, salesPerson.id, claim);
if (args.claimStateFk) {
const newState = await models.ClaimState.findById(args.claimStateFk, null, myOptions);
await notifyStateChange(ctx, salesPerson.id, claim, newState.description);
if (newState.code == 'canceled')
await notifyStateChange(ctx, claim.workerFk, claim, newState.description);
}
if (salesPerson && args.claimStateFk) {
const newState = await models.ClaimState.findById(args.claimStateFk, null, myOptions);
await notifyStateChange(ctx, salesPerson.id, claim, newState.description);
if (newState.code == 'canceled')
await notifyStateChange(ctx, claim.workerFk, claim, newState.description);
}
if (tx) await tx.commit();
@ -119,18 +114,4 @@ module.exports = Self => {
});
await models.Chat.sendCheckingPresence(ctx, workerId, message);
}
async function notifyPickUp(ctx, workerId, claim) {
const models = Self.app.models;
const url = await models.Url.getUrl();
const $t = ctx.req.__; // $translate
const message = $t('Claim will be picked', {
claimId: claim.id,
clientName: claim.client().name,
claimUrl: `${url}claim/${claim.id}/summary`,
claimPickup: $t(claim.pickup)
});
await models.Chat.sendCheckingPresence(ctx, workerId, message);
}
};

View File

@ -43,6 +43,23 @@ module.exports = function(Self) {
};
try {
const province = await models.Province.findOne({
where: {id: data.provinceFk},
fields: ['autonomyFk']
});
const autonomy = province ? await models.Autonomy.findOne({
where: {id: province.autonomyFk},
fields: ['hasDailyInvoice']
}) : null;
const country = await models.Country.findOne({
where: {id: data.countryFk},
fields: ['hasDailyInvoice']
});
const hasDailyInvoice = (autonomy?.hasDailyInvoice ?? country?.hasDailyInvoice) || false;
const account = await models.VnUser.create(user, myOptions);
const client = await Self.create({
id: account.id,
@ -57,7 +74,8 @@ module.exports = function(Self) {
provinceFk: data.provinceFk,
countryFk: data.countryFk,
isEqualizated: data.isEqualizated,
businessTypeFk: data.businessTypeFk
businessTypeFk: data.businessTypeFk,
hasDailyInvoice: hasDailyInvoice
}, myOptions);
const address = await models.Address.create({

View File

@ -1,67 +1,78 @@
const models = require('vn-loopback/server/server').models;
describe('Client Create', () => {
const newAccount = {
userName: 'deadpool',
email: 'deadpool@marvel.com',
fi: '16195279J',
name: 'Wade',
socialName: 'DEADPOOL MARVEL',
street: 'WALL STREET',
city: 'New York',
businessTypeFk: 'florist',
provinceFk: 1
};
const newAccountWithoutEmail = JSON.parse(JSON.stringify(newAccount));
delete newAccountWithoutEmail.email;
let options;
let tx;
beforeAll.mockLoopBackContext();
it(`should not find deadpool as he's not created yet`, async() => {
const tx = await models.Client.beginTransaction({});
beforeEach(async() => {
tx = await models.Client.beginTransaction({});
options = {transaction: tx};
});
afterEach(async() => await tx.rollback());
it('should not find deadpool as he is not created yet', async() => {
try {
const options = {transaction: tx};
const account = await models.VnUser.findOne({where: {name: 'deadpool'}}, options);
const client = await models.Client.findOne({where: {name: 'Wade'}}, options);
const account = await models.VnUser.findOne({where: {name: newAccount.userName}}, options);
const client = await models.Client.findOne({where: {name: newAccount.name}}, options);
expect(account).toEqual(null);
expect(client).toEqual(null);
await tx.rollback();
expect(account).toBeNull();
expect(client).toBeNull();
} catch (e) {
await tx.rollback();
throw e;
}
});
it('should not create a new account', async() => {
const tx = await models.Client.beginTransaction({});
it('should throw an error when creating a new account without email', async() => {
let error;
const newAccountWithoutEmail = {
userName: 'deadpool',
fi: '16195279J',
name: 'Wade',
socialName: 'DEADPOOL MARVEL',
street: 'WALL STREET',
city: 'New York',
businessTypeFk: 'florist',
provinceFk: 1
};
try {
const options = {transaction: tx};
await models.Client.createWithUser(newAccountWithoutEmail, options);
await tx.rollback();
} catch (e) {
error = e.message;
await tx.rollback();
error = e;
}
expect(error).toEqual(`An email is necessary`);
expect(error.message).toEqual('An email is necessary');
});
it('should create a new account', async() => {
const tx = await models.Client.beginTransaction({});
it('should create a new account with dailyInvoice', async() => {
const newAccount = {
userName: 'deadpool',
email: 'deadpool@marvel.com',
fi: '16195279J',
name: 'Wade',
socialName: 'DEADPOOL MARVEL',
street: 'WALL STREET',
city: 'New York',
businessTypeFk: 'florist',
provinceFk: 1
};
try {
const options = {transaction: tx};
const province = await models.Province.findById(newAccount.provinceFk, {
fields: ['id', 'name', 'autonomyFk'],
include: {
relation: 'autonomy'
}
}, options);
const client = await models.Client.createWithUser(newAccount, options);
const account = await models.VnUser.findOne({where: {name: newAccount.userName}}, options);
expect(province.autonomy().hasDailyInvoice).toBeTruthy();
expect(account.name).toEqual(newAccount.userName);
expect(client.id).toEqual(account.id);
expect(client.name).toEqual(newAccount.name);
@ -69,8 +80,38 @@ describe('Client Create', () => {
expect(client.fi).toEqual(newAccount.fi);
expect(client.socialName).toEqual(newAccount.socialName);
expect(client.businessTypeFk).toEqual(newAccount.businessTypeFk);
expect(client.hasDailyInvoice).toBeTruthy();
} catch (e) {
await tx.rollback();
throw e;
}
});
it('should create a new account without dailyInvoice', async() => {
const newAccount = {
userName: 'deadpool',
email: 'deadpool@marvel.com',
fi: '16195279J',
name: 'Wade',
socialName: 'DEADPOOL MARVEL',
street: 'WALL STREET',
city: 'New York',
businessTypeFk: 'florist',
provinceFk: 3
};
try {
const province = await models.Province.findById(newAccount.provinceFk, {
fields: ['id', 'name', 'autonomyFk'],
include: {
relation: 'autonomy'
}
}, options);
const client = await models.Client.createWithUser(newAccount, options);
expect(province.autonomy.hasDailyInvoice).toBeFalsy();
expect(client.hasDailyInvoice).toBeFalsy();
} catch (e) {
await tx.rollback();
throw e;
@ -78,26 +119,25 @@ describe('Client Create', () => {
});
it('should not be able to create a user if exists', async() => {
const tx = await models.Client.beginTransaction({});
let error;
const newAccount = {
userName: 'deadpool',
email: 'deadpool@marvel.com',
fi: '16195279J',
name: 'Wade',
socialName: 'DEADPOOL MARVEL',
street: 'WALL STREET',
city: 'New York',
businessTypeFk: 'florist',
provinceFk: 1
};
try {
const options = {transaction: tx};
await models.Client.createWithUser(newAccount, options);
const client = await models.Client.createWithUser(newAccount, options);
expect(client).toBeNull();
await tx.rollback();
await models.Client.createWithUser(newAccount, options);
} catch (e) {
await tx.rollback();
error = e;
}
const errorName = error.details.codes.name[0];
expect(errorName).toEqual('uniqueness');
expect(error.message).toContain('already exists');
});
});

View File

@ -74,7 +74,8 @@ module.exports = Self => {
pm.name payMethod,
r.finished IS NULL hasRecovery,
dp.id departmentFk,
dp.name departmentName
dp.name departmentName,
dp.notificationEmail departmentEmail
FROM defaulter d
JOIN client c ON c.id = d.clientFk
JOIN country cn ON cn.id = c.countryFk

View File

@ -47,7 +47,7 @@ module.exports = Self => {
await models.Mail.create({
subject: $t('Comment added to client', {clientFk: defaulter.clientFk}),
body: body,
receiver: `${defaulter.salesPersonName}@verdnatura.es`,
receiver: `${defaulter.departmentEmail}`,
replyTo: `${user.name}@verdnatura.es`
}, myOptions);
}

View File

@ -1,8 +1,11 @@
module.exports = function(Self) {
Self.validate('text', isEnabled, {message: 'Description cannot be blank'});
function isEnabled(err) {
Self.validate('text', function(err) {
if (!this.text) err();
}
}, {message: 'Description cannot be blank'});
Self.validate('observationTypeFk', function(err) {
if (!this.observationTypeFk) err();
}, {message: 'type cannot be blank'});
Self.observe('before save', function(ctx, next) {
ctx.instance.created = Date();

View File

@ -1,10 +1,10 @@
{
"name": "ClientObservation",
"name": "ClientObservation",
"description": "Client notes",
"base": "VnModel",
"mixins": {
"Loggable": true
},
"mixins": {
"Loggable": true
},
"options": {
"mysql": {
"table": "clientObservation"
@ -26,6 +26,10 @@
"created": {
"type": "date",
"description": "Creation date and time"
},
"observationTypeFk": {
"type": "number",
"description": "Type of observation"
}
},
"relations": {
@ -44,14 +48,18 @@
"include": {
"relation": "worker",
"scope": {
"fields": ["id"],
"fields": [
"id"
],
"include": {
"relation": "user",
"scope": {
"fields": ["nickname"]
"fields": [
"nickname"
]
}
}
}
}
}
}
}

View File

@ -1,31 +0,0 @@
<vn-crud-model
vn-id="model"
url="clientObservations"
filter="$ctrl.filter"
link="{clientFk: $ctrl.$params.id}"
data="notes"
auto-load="true">
</vn-crud-model>
<vn-data-viewer
model="model"
class="vn-w-md">
<vn-card class="vn-pa-md">
<div
ng-repeat="note in notes"
class="note vn-pa-sm border-solid border-radius vn-mb-md">
<vn-horizontal class="vn-mb-sm" style="color: #666">
<vn-one>{{::note.worker.user.nickname}}</vn-one>
<vn-auto>{{::note.created | date:'dd/MM/yyyy HH:mm'}}</vn-auto>
</vn-horizontal>
<vn-horizontal class="text">
{{::note.text}}
</vn-horizontal>
</div>
</vn-card>
</vn-data-viewer>
<a vn-tooltip="New note"
ui-sref="client.card.note.create({id: $ctrl.$params.id})"
vn-bind="+"
fixed-bottom-right>
<vn-float-button icon="add"></vn-float-button>
</a>

View File

@ -5,9 +5,10 @@ import './style.scss';
export default class Controller extends Section {
constructor($element, $) {
super($element, $);
this.filter = {
order: 'created DESC',
};
}
async $onInit() {
this.$state.go('home');
window.location.href = await this.vnApp.getUrl(`customer/${this.$params.id}/notes`);
}
}

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