Oracle Apex 4.2.4 Display only fields not saved to database

白昼怎懂夜的黑 提交于 2019-12-10 21:24:53

问题


I am using a dynamic action to auto fill data into fields based on the ID of a person that is being pulled from another table (which pulls the person's dept, employee#, etc). This works fine if I leave the auto populated fields editable, but I want these fields to be 'display only' so that the person entering the data cannot edit it. That's the whole reason for using dynamic action. When I set the fields to 'display only', the data never gets saved to the table so the fields are blank when I run a report on the record. Is there a way to get these fields to populate the database and still not be editable. Do I need to run another process 'behind the scenes' to get them populated, like with an 'on submit' process?


回答1:


Use Text field and then set the "HTML Form Element Attributes" with readonly="readonly";.




回答2:


Create an additional hidden item and save it instead of the read only item. Assign your dynamic actions to alter the values on both items, the read only and the hidden ones.




回答3:


You can achieve an update-able display/read only item by setting the item Display as property to Text Field and setting the Read Only Condition Type of the item to Always.



来源:https://stackoverflow.com/questions/27273509/oracle-apex-4-2-4-display-only-fields-not-saved-to-database

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!