Openbravo Issue Tracking System - Retail Modules
View Issue Details
0055079Retail ModulesWeb POSpublic2024-04-02 17:162024-04-02 17:35
adrianromero 
Triage Platform Conn 
normalmajoralways
closedfixed 
5
 
RR24Q1.2RR24Q1.2 
adrianromero
No
0055079: You can't use Reprintable Documents in POS with an user with a Manual Role
When using a Manual Role we cant use Reprintable documents.

Most relevant stack line is:

at org.openbravo.mobile.core.report.ReprintableDocumentService.exec(ReprintableDocumentService.java:69) [classes/:?]

Line´s GitLab:
 https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/blob/master/src/org/openbravo/mobile/core/report/ReprintableDocumentService.java?ref_type=heads#L69 [^]

 
That process does not have a setAdminMode, so everything it executes, it does with the user's real permissions. That process ends up calling another core process, which does an explicit check of the user permissions:

modules/org.openbravo.client.application/src/org/openbravo/client/application/attachment/ReprintableDocumentManager.java · master · openbravo / product / openbravo · GitLab

As the particular user does not have read permissions for the Order entity, the process fails to retrieve the report.
In window Organization select 'Reprintable Documents' = ENABLED and log in on a POS using the Vall Blanca Manual role.
Do a sale on the POS
Try Reprinting the Document --> An error appears
No tags attached.
depends on defect 0054527 closed caristu You can't use Reprintable Documents in POS with an user with a Manual Role 
Issue History
2024-04-02 17:16adrianromeroNew Issue
2024-04-02 17:16adrianromeroAssigned To => Triage Platform Conn
2024-04-02 17:16adrianromeroTriggers an Emergency Pack => No
2024-04-02 17:16adrianromeroIssue generated from0054527
2024-04-02 17:16adrianromeroRelationship addeddepends on 0054527
2024-04-02 17:35hgbotResolutionopen => fixed
2024-04-02 17:35hgbotStatusnew => resolved
2024-04-02 17:35hgbotFixed in Version => RR24Q1.2
2024-04-02 17:35hgbotNote Added: 0162784
2024-04-02 17:35adrianromeroReview Assigned To => adrianromero
2024-04-02 17:35adrianromeroStatusresolved => closed

Notes
(0162784)
hgbot   
2024-04-02 17:35   
Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core [^]
Changeset: 67465e8a7f227e16f9c2cb9b56d6b4574f6b6ec4
Author: Adrián Romero <adrian.romero@openbravo.com>
Date: 02-04-2024 17:33:53
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/commit/67465e8a7f227e16f9c2cb9b56d6b4574f6b6ec4 [^]

Fixes ISSUE-55079: You can't use Reprintable Documents in POS with an user with a Manual Role
* Wraps ReprintableDocumentService with Admin Mode. The securization of reprintable documents must go to the User Action that invokes the service

---
M src/org/openbravo/mobile/core/report/ReprintableDocumentService.java
---