Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0011555Openbravo ERPZ. Otherspublic2009-11-30 13:432010-04-16 00:00
psarobe 
adrianromero 
urgentmajoralways
closedfixed 
5
 
2.50MP15 
Core
No
0011555: Processed records should be rendered as read only
The idea of this feature is to have "read only logic" fields depending on the status of the document. This read only logic fields are already handle through Triggers object but the difference is that with this feature they will be in grey colour, remarking then that you cannot edit.

Right now they are as editable although you cannot thanks to the triggers
The field that you have to change is in the table AD_COLUMN and it is named as "readonlylogic". To do it through the UI you have to go to Application Dictionary || Tables and Columns || Table >> Column

These are the windows/tables that need to review. All of them transactional windows:

A. Windows Sales Invoice/Purchase invoice
==========================================
Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In these two windows exist several tabs. The ones we need to focus are:

A.1. Tab Header: Table C_INVOICE
--------------------------------
Here you need to define the "processed" column in Table C_INVOICE as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed can be found in trigger C_Invoice_trg
The fields that must be read only when the document is posted can be found in trigger C_Invoice_trg
Example: In the column documentno fill the field "Read only logic" with the value @Processed@='Y'

A.2 Tab lines: Table C_INVOICELINE
----------------------------------
The columns that must be read only when the document is processed can be found in trigger c_invline_chk_restrictions_trg
Example: In the column PriceActual fill the field "Read only logic" with the value @Processed@='Y'

A.3 Tab Tax: C_INVOICETAX
-------------------------
The columns that must be read only when the document is processed can be found in trigger C_invoicetax_trg

A.4 Tab Payment: C_DEBT_PAYMENT
--------------------------
Here the rule must be: When Isvalid='Y' the columns Amount, Ismanual and currency must be readonlylogic
Example: @Isvalid@='Y'

A.5 Tab Reverse invoice: C_INVOICE_REVERSE
------------------------------------------
Here all the columns must be readonlylogic when the invoice is processed

A.6 Tab Discount: C_INVOICE_DISCOUNT
------------------------------------
Here all the columns must be readonlylogic when the invoice is processed


B. Windows Sales Order/Purchase order
=====================================
Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In these two windows exist several tabs. The ones we need to focus are:

B.1. Tab Header: Table C_ORDER
--------------------------------
Here you need to define the "processed" column in Table C_ORDER as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger c_order_chk_restrinctions_trg. Don't take into account the OLD.Docaction<>'CL' parameter
The fields that must be read only when the document is posted can be found in trigger c_order_chk_restrinctions_trg
Example: In the column documentno fill the field "Read only logic" with the value @Processed@='Y'

B.2 Tab lines: Table C_ORDERLINE
----------------------------------
The columns that must be read only when the document is processed can be found in trigger c_ordline_chk_restrictions_trg. Don't take into account the OLD.Docaction<>'CL' parameter
Example: In the column PriceActual fill the field "Read only logic" with the value @Processed@='Y'

B.3 Tab Discount: C_ORDER_DISCOUNT
------------------------------------
Here all the columns must be readonlylogic when the invoice is processed

B.4 Tab Payment: C_DEBT_PAYMENT
--------------------------
Here the rule must be: When Isvalid='Y' the columns Amount, Ismanual and currency must be readonlylogic
Example: @Isvalid@='Y'

B.5 Tab Tax: C_INVOICETAX
-------------------------
The columns that must be read only when the document is processed can be found in trigger c_ordertax_trg. Don't take into account the OLD.Docaction<>'CL' parameter

C. Windows Goods receipt/Goods shipment
========================================

Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In these two windows exist several tabs. The ones we need to focus are:

C.1. Tab Header: Table M_INOUT
--------------------------------
Here you need to define the "processed" column in Table M_INOUT as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger m_inout_chk_restrictions_trg
The fields that must be read only when the document is posted can be found in trigger m_inout_chk_restrictions_trg
Example: In the column documentno fill the field "Read only logic" with the value @Processed@='Y'

C.2 Tab lines: Table M_INOUTLINE
----------------------------------
The columns that must be read only when the document is processed can be found in trigger m_ioline_chk_restrictions_trg
Example: In the column M_PRODUCT_ID fill the field "Read only logic" with the value @Processed@='Y'

D. Windows Movement products
============================

Here we only have to take into account one scenarios:

-Document completed (which means processed='Y')

The tabs we need to focus are:

D.1. Tab Header: Table M_MOVEMENT
---------------------------------
Here you need to define the "processed" column in Table M_MOVEMENT as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger m_movement_trg
Example: In the column documentno fill the field "Read only logic" with the value @Processed@='Y'

D.2 Tab lines: Table M_MOVEMENTLINE
----------------------------------
All the columns must be read only when the header is processed
Example: In the column M_PRODUCT_ID fill the field "Read only logic" with the value @Processed@='Y'

E. Windows Bank Statement
=========================

Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In this window exists two tabs:

E.1. Tab Header: Table C_BANKSTATEMENT
--------------------------------------
Here you need to define the "processed" and "posted" column in Table C_BANKSTATEMENT as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger c_bstmt_chk_restrictions_trg

For this window does not exist any extra field for the case Posted='Y' so you don0t have to do anything, just the rule processed='Y'
Example: In the column statementdate fill the field "Read only logic" with the value @Processed@='Y'

E.2 Tab lines: Table C_BANKSTATEMENTLINE
----------------------------------
Be carefully with this table. In this tab we have to distinguish between processed and posted in the same way we did with other windows. The difference here is that we distinguish in the tab line and not in the header.

The fields that must be read only when the document is processed='Y' can be found in trigger c_bstmtline_chk_restrict_trg
The fields that must be read only when the document is posted can be found in trigger c_bstmtline_chk_restrict_trg
Example: In the column stmtamt fill the field "Read only logic" with the value @Processed@='Y'

F. Windows Cash journal
=========================

Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In this window exists two tabs:

F.1. Tab Header: Table C_CASH
--------------------------------------
Here you need to define the "processed" column in Table C_CASH as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger c_cash_chk_restrictions_trg
The fields that must be read only when the document is posted='Y' can be found in trigger c_cash_chk_restrictions_trg

Example: In the column statementdate fill the field "Read only logic" with the value @Processed@='Y'

F.2 Tab lines: Table C_CASHLINE
-------------------------------
The fields that must be read only when the document is processed='Y' can be found in trigger c_cashline_chk_restrict_trg
Example: In the column amount fill the field "Read only logic" with the value @Processed@='Y'

G. Windows Physical inventory
============================

Here we only have to take into account one scenarios:

-Document completed (which means processed='Y')

The tabs we need to focus are:

G.1. Tab Header: Table M_INVENTORY
---------------------------------
Here you need to define the "processed" column in Table M_INVENTORY as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger m_inventory_trg
Example: In the column documentno fill the field "Read only logic" with the value @Processed@='Y'

G.2 Tab lines: Table M_INVENTORYLINE
----------------------------------
All the columns must be read only when the header is processed
Example: In the column M_PRODUCT_ID fill the field "Read only logic" with the value @Processed@='Y'

H. Windows Amortization
=========================

Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In this window exists two tabs:

H.1. Tab Header: Table A_AMORTIZATION
--------------------------------------
Here you need to define the "processed" column in Table A_AMORTIZATION as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' and Posted='Y' are the same and can be found in trigger a_amortization_trg

Example: In the column dateacct fill the field "Read only logic" with the value @Processed@='Y'

H.2 Tab lines: Table A_AMORTIZATIONLINE
---------------------------------------
The fields that must be read only when the document is processed='Y' can be found in trigger a_amortizationline_trg
Example: In the column amortization_percentage fill the field "Read only logic" with the value @Processed@='Y'

I. Windows GL Journal
=========================

Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In this window exists three tabs but we will only focus in two:

I.1. Tab Header: Table GL_JOURNAL
--------------------------------------
Here you need to define the "processed" column in Table GL_JOURNAL as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger gl_journal_chk_restrict_trg
The fields that must be read only when the document is Posted='Y' can be found in trigger gl_journal_chk_restrict_trg

Example: In the column dateacct fill the field "Read only logic" with the value @Processed@='Y'

I.2 Tab lines: Table GL_JOURNALLINE
---------------------------------------
All the fields must be read only when the document is processed='Y'

J. Windows Settlement/Manual settlement
========================================

Here we have to take into account two different scenarios:

1. Document completed (which means processed='Y')
2. Document posted (which means posted='Y')

For every of these two scenarios some fields will be read only and other won't be. The rule is that to be able to post a document first the document must be processed so if fields A, B and C are read only when the document is processed and field D only when is posted, it means that in the final status (document posted='Y') the document will have A,B,C and D as read only fields

In this window exists several tabs but we will only focus in:

J.1. Tab Header: Table C_SETTLEMENT
-----------------------------------
Here you need to define the "processed" column in Table C_SETTLEMENT as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger c_settlement_trg
The fields that must be read only when the document is Posted='Y' can be found in trigger c_settlement_trg

Example: In the column dateacct fill the field "Read only logic" with the value @Processed@='Y'

J.2 Tab Balance Payment: C_DEBT_PAYMENT_BALANCING
-------------------------------------------------
All the fields must be read only logic when the document is processed

K. Window Remittance
====================

Here you only have to take into account one scenario:

1. Document completed (which means processed='Y')

In this window exists two tabs:

K.1. Tab Header: Table C_REMITTANCE
-----------------------------------
Here you need to define the "processed" column in Table C_REMITTANCE as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger c_remittance_trg. Just take into account if it processed

Example: In the column name fill the field "Read only logic" with the value @Processed@='Y'

K.2 Tab Lines: C_REMITTANCELINES
--------------------------------
All the fields must be read only logic when the document is processed

L. Window Payment management status
===================================

Here you only have to take into account one scenario:

1. Document completed (which means processed='Y')

In this window exists two tabs:

L.1. Tab Header: Table C_DP_MANAGEMENT
--------------------------------------
Here you need to define the "processed" column in Table C_DP_MANAGEMENT as "Stored in session" so when you are in children tabs (i.e: the tab lines) you can get that value (because it will be in the session) and use it
The fields that must be read only when the document is processed='Y' can be found in trigger c_dp_management_chk_restr_trg. Just take into account if it processed

Example: In the column name fill the field "Read only logic" with the value @Processed@='Y'

L.2 Tab Lines: C_DP_MANAGEMENTLINE
----------------------------------
All the fields must be read only logic when the document is processed
No tags attached.
related to defect 0011719 closed alostale "Read only logic" does not work for selectors like Products or Business Partners 
related to defect 00142432.50MP23 closed sivaraman Requisition form is not following the logic of read only for completed status 
related to defect 0014505 closed alostale Read-only logic does not get properly columns stored in session 
Issue History
2009-11-30 13:43psarobeNew Issue
2009-11-30 13:43psarobeAssigned To => adrianromero
2009-11-30 13:45psarobeSteps to Reproduce Updated
2009-11-30 18:20psarobeSteps to Reproduce Updated
2009-11-30 18:21psarobeSteps to Reproduce Updated
2009-11-30 19:52psarobeSteps to Reproduce Updated
2009-11-30 20:45psarobeSteps to Reproduce Updated
2009-11-30 20:53psarobeStatusnew => scheduled
2009-12-01 17:20psarobeSteps to Reproduce Updated
2009-12-02 17:33adrianromeroSteps to Reproduce Updated
2009-12-02 18:40adrianromeroSteps to Reproduce Updated
2009-12-04 12:09adrianromeroSteps to Reproduce Updated
2009-12-04 13:18adrianromeroSteps to Reproduce Updated
2009-12-10 10:27adrianromeroRelationship addedrelated to 0011719
2009-12-14 12:45hgbotCheckin
2009-12-14 12:45hgbotNote Added: 0022749
2009-12-14 12:45hgbotStatusscheduled => resolved
2009-12-14 12:45hgbotResolutionopen => fixed
2009-12-14 12:45hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/4102b19a8c40456103339b003c65e55cbf1fe478 [^]
2009-12-15 08:58hudsonbotCheckin
2009-12-15 08:58hudsonbotNote Added: 0022800
2010-04-15 14:24sureshbabuNote Added: 0026263
2010-04-15 14:24sureshbabuStatusresolved => closed
2010-04-15 14:24sureshbabuFixed in Version => 2.50MP15
2010-04-16 00:00anonymoussf_bug_id0 => 2987948
2010-08-26 11:51adrianromeroRelationship addedrelated to 0014243
2010-10-18 09:28rafarodaRelationship addedrelated to 0014505

Notes
(0022749)
hgbot   
2009-12-14 12:45   
Repository: erp/devel/pi
Changeset: 4102b19a8c40456103339b003c65e55cbf1fe478
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Thu Dec 10 10:09:56 2009 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/4102b19a8c40456103339b003c65e55cbf1fe478 [^]

Fixes issue 0011555: Processed records should be rendered as read only

---
M src-db/database/sourcedata/AD_AUXILIARINPUT.xml
M src-db/database/sourcedata/AD_COLUMN.xml
---
(0022800)
hudsonbot   
2009-12-15 08:58   
---
A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/d8660a4ab9a7 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/obx/core/OpenbravoERP-2.50CI.15731.obx [^]
---
(0026263)
sureshbabu   
2010-04-15 14:24   
Tested working fine