Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0039360
TypeCategorySeverityReproducibilityDate SubmittedLast Update
design defect[Retail Modules] Web POSmajorN/A2018-09-27 12:512019-06-18 12:34
Reportergorka_gilView Statuspublic 
Assigned Togorka_gil 
PrioritynormalResolutionfixedFixed in VersionRR19Q1
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tomarvintm
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0039360: Terminal Log : Improve log client with cashier actions and processes start/end info

DescriptionA) Log client saves info, warn, error messages generated by the pos.


B) There is a project to create a new log with cashier actions and other events but adding in the code all this log.


C) There is another project that add a log to each button or key pressed.


D) In this feature request, idea is to improve the idea behind C), so in a central place and generic, saves logs of each click and key pressed, and improve till reach a similar level than B), that has hardcoded in many places of the code the log messages. Also apart of cashier actions will save the processes start/end.


The purpose is to help understand better what has happen in case of a problem.

And second objective is to not have to add log in all the places of the code, but this is created in a central place and don't require edit the code, so automatically applies to all modules.


Special care will be taken to ensure that we cause no performance degradation in the client side, we don't generate too much data which needs to be synchronized with the backend, and we also don't cause performance problems in the backend because of the new data we need to save.
Steps To Reproduce-
TagsNo tags attached.
Attached Filesdiff file icon terminallog-q3-erp.diff [^] (4,640 bytes) 2018-12-11 11:25 [Show Content]
diff file icon terminallog-q3-mobilecore.diff [^] (116,206 bytes) 2018-12-11 11:25 [Show Content]
diff file icon terminallog-q3-posterminal.diff [^] (17,682 bytes) 2018-12-11 11:26 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0039699 closedcaristu Openbravo ERP SortingFilteringGridConfiguration is failing when it should be skipped 
related to defect 0039968 scheduledRetail Retail Modules Terminal log model appear in the pending models to be synchronized when offline 
related to defect 0041118 scheduledRetail Retail Modules Column "em_obpos_applications_id" of "c_import_entry" not filled by "OBMOBC_TerminalLog" or "OBCFR_TerminalMonitor" 
related to defect 0041184 newRetail Retail Modules Terminal Log: fix createdby of table terminal log 
causes defect 0039725 closedalostale Openbravo ERP ViewGeneration fails in retail CI 
causes defect 0040054 closedgorka_gil Retail Modules Clicking "x" button in a receipt paying process throws a JS error 

-  Notes
(0108147)
hgbot (developer)
2018-11-28 14:29

Repository: erp/devel/pi
Changeset: 9045f47e9ae714123a3bd79f58beeb72ff50be77
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Wed Nov 28 13:52:50 2018 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/9045f47e9ae714123a3bd79f58beeb72ff50be77 [^]

[TerminalLog] Related to issue 39360: Add Terminal Log project

Implement the ability in the import entry processor to skip the archiving per entry type

---
M src/org/openbravo/service/importprocess/ImportEntryArchiveManager.java
M src/org/openbravo/service/importprocess/ImportEntryProcessor.java
---
(0108148)
hgbot (developer)
2018-11-28 14:29

Repository: tools/automation/pi-mobile
Changeset: 390c13cdc1d050b7517114db795de239092cbea1
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Wed Nov 28 13:56:44 2018 +0100
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/390c13cdc1d050b7517114db795de239092cbea1 [^]

[TerminalLog] Related to issue 39360: Add Terminal Log project

Fix tests:
  - I30412_QuotationsAndPromotions.java
  - I33307_VerifyLoginUserWithTwoDistinctRoles.java

Disable some SharedPaymentMethods till issue 39691 is fixed.

---
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/discountsandpromotions/I30412_QuotationsAndPromotions.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/loginout/I33307_VerifyLoginUserWithTwoDistinctRoles.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/I31591_VerifySharePaymentsCashup.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/I35901_SPMVerifyErrorPopupInSlave.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/SPMMulticurrencyPayInEURUSD.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/SPMNeedToCloseMaster.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/SPMQuotationSharedPayments.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/SPMSaleAndReloadSharedPayments.java
---
(0108150)
hgbot (developer)
2018-11-28 14:32

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 1392001fae5266678b988e6d34f0550a9da81209
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Wed Nov 28 13:35:27 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/1392001fae5266678b988e6d34f0550a9da81209 [^]

[TerminalLog] Related to issue 39360: Added Terminal log project

- From this commit, it will be logged:
   - User actions: all click and key pressed
   - start and finish of web pos processes
- The way that works is:
   - All events are saved in ram
   - There is a backup process that take a backup to local storage each sec (by default)
      - When closing the window or pressing F5 it should take a local backup
   - There is another process each 30 secs that creates an entry in the models to
     be synchronized by runsyncprocess
   - The next runsyncprocess will sync the terminal log.
      - The model of terminal log is the last to be synchronized in a runsyncprocess
   - Note: the old log client is still synchronized in each own way.
- logclient table
   - loglevel column: make it reference list
      - as consecuence it goes from a string of 255 char to 60 char
      - values:
         - Functional - User action
         - Technical - Process
         - Technical - Info
         - Technical - Warn
         - Technical - Error
   - Added columns:
      - context : contains the context in which has been created the log line,
        like pos window or documentno
      - tstamp : contains the timestamp with miliseconds, usefull for sorting
        since created column don't have miliseconds and can not be added
   - Added many indexes
   - Rename "log client" window in erp to "terminal log" (db table remains logclient)
   - Added grid configuration to terminal log window, to only allow actions that are indexed
   - The inserts in the table are done with xsql instead of dal, becasue dal don't allow
     to modify the created column and for avoid to do an inserte and update per line.
   - Modify the log client to also fill the context and tstamp columns.
- Preferences:
   - Disable user actions log : OBMOBC_EnableTerminalLogUserActions
   - Disable processes log : OBMOBC_EnableTerminalLogProcess
   - Interval to create package to be synchronized by runsynprocess (by default 30 secs):
     OBMOBC_TerminalLogSyncInterval
   - Interval to create backups inside web pos in case of F5 or similar (by default 1 sec):
     OBMOBC_TerminalLogBackupInterval
- Mobile processes:
   - Add new column to indicate if this process should be logged or not
- Deleted human log, since this project replaces it

---
M src-db/database/model/tables/OBMOBC_LOGCLIENT.xml
M src-db/database/model/tables/OBMOBC_PROCESS_DEFINITION.xml
M src-db/database/sourcedata/AD_COLUMN.xml
M src-db/database/sourcedata/AD_DATASET.xml
M src-db/database/sourcedata/AD_DATASET_TABLE.xml
M src-db/database/sourcedata/AD_ELEMENT.xml
M src-db/database/sourcedata/AD_FIELD.xml
M src-db/database/sourcedata/AD_MENU.xml
M src-db/database/sourcedata/AD_PREFERENCE.xml
M src-db/database/sourcedata/AD_REFERENCE.xml
M src-db/database/sourcedata/AD_REF_LIST.xml
M src-db/database/sourcedata/AD_TAB.xml
M src-db/database/sourcedata/AD_WINDOW.xml
M src-db/database/sourcedata/OBMOBC_PROCESS_DEFINITION.xml
M src-db/database/sourcedata/OBMOBC_SERVICES.xml
M src/org/openbravo/mobile/core/MobileCoreComponentProvider.java
M src/org/openbravo/mobile/core/login/MobileCoreLoginUtilsServlet.java
M src/org/openbravo/mobile/core/utils/LogClientLoader.java
M web/org.openbravo.mobile.core/source/component/ob-commonbuttons.js
M web/org.openbravo.mobile.core/source/model/logclient.js
M web/org.openbravo.mobile.core/source/model/ob-terminal-model.js
M web/org.openbravo.mobile.core/source/retail/component/ob-retail-searchproductcharacteristic.js
M web/org.openbravo.mobile.core/source/utils/ob-dom-extension.js
M web/org.openbravo.mobile.core/source/utils/ob-processcontroller.js
M web/org.openbravo.mobile.core/source/utils/ob-utilities.js
M web/org.openbravo.mobile.core/source/utils/ob-utilitiesui.js
A referencedata/standard/Obmobc_logclient_grid_config.xml
A src/org/openbravo/mobile/core/TerminalLogLoader.java
A src/org/openbravo/mobile/core/UserEventLoaderQueries_data.xsql
A src/org/openbravo/mobile/core/importprocess/TerminalLogImportEntryProcessor.java
A web/org.openbravo.mobile.core/source/model/terminal-log.js
A web/org.openbravo.mobile.core/source/utils/ob-terminal-log.js
A web/org.openbravo.mobile.core/source/utils/terminal-log-sync-utils.js
R web/org.openbravo.mobile.core/source/utils/ob-loghumanaction.js
---
(0108151)
hgbot (developer)
2018-11-28 14:33

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 3d551a331438b15bf9150a24711d9352127356b6
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Wed Nov 28 13:44:12 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/3d551a331438b15bf9150a24711d9352127356b6 [^]

[TerminalLog] Related to issue 39360: Add terminal log project

- Created mobile processes:
  - addPayment
  - searchProduct
  - searchCustomer
  - searchCustomerAddress
- Reorder models to sync: move the terminal log model to end since has the less priority
- When load an order set the context to the order documentno

---
M src-db/database/sourcedata/OBMOBC_PROCESS_DEFINITION.xml
M web/org.openbravo.retail.posterminal/js/components/bplocation.js
M web/org.openbravo.retail.posterminal/js/components/bplocationship.js
M web/org.openbravo.retail.posterminal/js/components/businesspartner_selector.js
M web/org.openbravo.retail.posterminal/js/login/model/login-model.js
M web/org.openbravo.retail.posterminal/js/model/order.js
---
(0108190)
hgbot (developer)
2018-11-30 13:22

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: a0d858f8db7814789897aefd7a2f4fe96a348739
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Fri Nov 30 13:21:53 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/a0d858f8db7814789897aefd7a2f4fe96a348739 [^]

[TerminalLog] Related to issue 39360: Change terminal log import entry to don't use posterminal classes

---
M src/org/openbravo/mobile/core/TerminalLogLoader.java
M src/org/openbravo/mobile/core/importprocess/TerminalLogImportEntryProcessor.java
---
(0108192)
hgbot (developer)
2018-11-30 14:58

Repository: tools/automation/pi-mobile
Changeset: 7ba0ebd347f3303ef0650d6bc52f279795008db4
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Fri Nov 30 14:58:18 2018 +0100
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/7ba0ebd347f3303ef0650d6bc52f279795008db4 [^]

[TerminalLog] Related to issue 39360: Disable some SharedPaymentMethods tests till issue 39691 is fixed

---
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/I31822_SPMQuotationSharedPayments.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/SPMDiscountsWithPriceIncludeTaxes.java
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/sharedpaymentmethods/SPMDiscountsWithoutPriceIncludeTaxes.java
---
(0108194)
hgbot (developer)
2018-11-30 15:07

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 01d5bef9c9516b7aa1228e861ff7fa41b637e4f6
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Fri Nov 30 15:07:12 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/01d5bef9c9516b7aa1228e861ff7fa41b637e4f6 [^]

[TerminalLog] Related to issue 39360: Fix license

---
M src/org/openbravo/mobile/core/UserEventLoaderQueries_data.xsql
---
(0108207)
hgbot (developer)
2018-12-01 20:51

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 8ef9cd2bbbeeecf5cfa420e1162f449e4c674f2c
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Sat Dec 01 20:51:37 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/8ef9cd2bbbeeecf5cfa420e1162f449e4c674f2c [^]

Related to issue 39360. Message related to non-defined form in class should not be warn but debug, similar to the same message related to the security preference

---
M src/org/openbravo/mobile/core/process/SecuredJSONProcess.java
---
(0108383)
gorka_gil (administrator)
2018-12-11 11:27

Attached patches for 18q3:
- terminallog-q3-erp.diff
- terminallog-q3-mobilecore.diff
- terminallog-q3-posterminal.diff
(0108504)
hudsonbot (developer)
2018-12-11 20:22

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/470e3cd384c5 [^]
Maturity status: Test
(0108558)
hgbot (developer)
2018-12-12 16:55

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 4bd4a7bada88d897f3a5bedf21e95042fcd7d361
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Mon Dec 10 18:02:53 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/4bd4a7bada88d897f3a5bedf21e95042fcd7d361 [^]

Related to issue 39360: Code review

- Do not change the physical order of column loglevel in OBMOBC_LOGCLIENT table
- Add check Y/N to new column TERMINALLOG of table OBMOBC_PROCESS_DEFINITION
- Use the new log4j2 in TerminalLogLoader

---
M src-db/database/model/tables/OBMOBC_LOGCLIENT.xml
M src-db/database/model/tables/OBMOBC_PROCESS_DEFINITION.xml
M src/org/openbravo/mobile/core/TerminalLogLoader.java
---
(0108585)
hgbot (developer)
2018-12-13 14:03

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 2ce7a00d14aef4378e42ec31a098315a3ba62fb9
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Thu Dec 13 13:37:24 2018 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/2ce7a00d14aef4378e42ec31a098315a3ba62fb9 [^]

[TerminalLog] Related to issue 39360: Initialize terminal log model

It was failing when changing terminal, for example test: I36010_PayCertificateTicketOtherTerminal

---
M web/org.openbravo.mobile.core/source/utils/ob-terminal-log.js
---

- Issue History
Date Modified Username Field Change
2018-09-27 12:51 gorka_gil New Issue
2018-09-27 12:51 gorka_gil Assigned To => Retail
2018-09-27 12:51 gorka_gil Triggers an Emergency Pack => No
2018-09-27 12:51 gorka_gil Assigned To Retail => gorka_gil
2018-09-27 12:51 gorka_gil Status new => scheduled
2018-11-27 10:47 caristu Relationship added related to 0039699
2018-11-28 14:29 hgbot Checkin
2018-11-28 14:29 hgbot Note Added: 0108147
2018-11-28 14:29 hgbot Checkin
2018-11-28 14:29 hgbot Note Added: 0108148
2018-11-28 14:32 hgbot Checkin
2018-11-28 14:32 hgbot Note Added: 0108150
2018-11-28 14:33 hgbot Checkin
2018-11-28 14:33 hgbot Note Added: 0108151
2018-11-28 17:40 gorka_gil Status scheduled => resolved
2018-11-28 17:40 gorka_gil Resolution open => fixed
2018-11-30 13:22 hgbot Checkin
2018-11-30 13:22 hgbot Note Added: 0108190
2018-11-30 14:58 hgbot Checkin
2018-11-30 14:58 hgbot Note Added: 0108192
2018-11-30 15:06 alostale Relationship added causes 0039725
2018-11-30 15:07 hgbot Checkin
2018-11-30 15:07 hgbot Note Added: 0108194
2018-12-01 20:51 hgbot Checkin
2018-12-01 20:51 hgbot Note Added: 0108207
2018-12-11 11:25 gorka_gil File Added: terminallog-q3-erp.diff
2018-12-11 11:25 gorka_gil File Added: terminallog-q3-mobilecore.diff
2018-12-11 11:26 gorka_gil File Added: terminallog-q3-posterminal.diff
2018-12-11 11:27 gorka_gil Note Added: 0108383
2018-12-11 20:22 hudsonbot Checkin
2018-12-11 20:22 hudsonbot Note Added: 0108504
2018-12-12 16:55 hgbot Checkin
2018-12-12 16:55 hgbot Note Added: 0108558
2018-12-13 10:21 marvintm Review Assigned To => marvintm
2018-12-13 10:21 marvintm Status resolved => closed
2018-12-13 10:21 marvintm Fixed in Version => RR19Q1
2018-12-13 14:03 hgbot Checkin
2018-12-13 14:03 hgbot Note Added: 0108585
2019-01-16 18:42 gorka_gil Relationship added related to 0039968
2019-01-29 18:55 gorka_gil Relationship added causes 0040054
2019-06-18 12:31 gorka_gil Relationship added related to 0041118
2019-06-18 12:31 gorka_gil Summary Improve log client with cashier actions and processes start/end info => Terminal Log: Improve log client with cashier actions and processes start/end info
2019-06-18 12:34 gorka_gil Summary Terminal Log: Improve log client with cashier actions and processes start/end info => Terminal Log : Improve log client with cashier actions and processes start/end info
2019-06-26 16:07 gorka_gil Relationship added related to 0041184


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker