Sorry for the stupid question - Creating Simple DB/CRUD app. Data Read-only?

(RE: https://jesse-brin.outsystemscloud.com/TestDataCRUD/)

I'm really sorry to have to ask this question. Hope this is the correct forum. Total newbie just dipping my toe in the water evaluating OutS (Personal Environment) for my dev shop. Looks extremely promising but stumbling over what I had assumed would be a simple 'Hello World' ask. (I know, never assume). I can't seem to add records to a new database I created on Data tab. Really simple DB. Just three entities, each with a few basic columns, related to each other. After creating it I want to populate it with some test data. It appears that you can't do that directly in service studio in the data tab (right-click, View Data). Another forum post from someone asking about the same thing suggested making DB public and creating a companion web app using the List-Detail scaffolding. Seems like that's more work than it should be, but I did it anyway (that's the link). But this also appears to be read-only. No 'Add new' button, etc, to be found. Thought I had it with the Expose Read-Only property, but setting that to 'No' and re-publishing did not change anything. No joy in docs or searching forums. I'm sure it's covered in a video I have not gotten through yet. This *has* to be something really simple. What am I doing wrong? Thanks In Advance.

Hello,

The best way to learn OutSystems (by yourself) is through the Online Classes https://www.outsystems.com/learn/courses/114/developing-web-apps-outsystems-11/?LearningPathId=2

In any case, If you have an entity and want to create a pair of LIST / DETAIL pages, be sure to have the entities Expose READ ONLY property set to NO (if they are in different modules). If the page is in the same module, this does not apply (inside the a module the entities created there are always read/write).

Try to have at least a single text field in the entities you want to do the scaffolding.

Than, just drag and drop the same entity twice to the Main Flow. The scaffolding will create both pages and the List Page will have a NEW action at the top of the page for you to create items.

It is not possible to edit data in database through the Service Studio.

Hope this helps.

Cheers.

Eduardo Jauch wrote:

Hello,

The best way to learn OutSystems (by yourself) is through the Online Classes https://www.outsystems.com/learn/courses/114/developing-web-apps-outsystems-11/?LearningPathId=2

In any case, If you have an entity and want to create a pair of LIST / DETAIL pages, be sure to have the entities Expose READ ONLY property set to NO (if they are in different modules). If the page is in the same module, this does not apply (inside the a module the entities created there are always read/write).

Try to have at least a single text field in the entities you want to do the scaffolding.

Than, just drag and drop the same entity twice to the Main Flow. The scaffolding will create both pages and the List Page will have a NEW action at the top of the page for you to create items.

It is not possible to edit data in database through the Service Studio.

Hope this helps.

Cheers.

Screenshot attached.

Man, thanks so much for your answer. I do plan to do just that with the tutorials. We're evaluating a number of low-code, no-code options. One of the first things I try before I get too far in with any of these is to build something simple that we use every day around here - a simple CRUD browser grid-form pair - just to get a feel for how 'simple' it really is. That's where I am right now. Was delighted to discover scaffolding. It was going swimmingly until I hit this road block.

I had already done what you suggested regarding the scaffolding based on another post I found up here. And the entity does have a Text type field.  I had already set the "Expose READ ONLY" property to 'no'. Refreshed the Dependencies to synch everything up since I initially designed the data model in the Mobile flavor of the test. But the browser app it generated still shows 0 records with the only buttons being Search and Reset. There's nothing that looks like "Add New...".

Thanks again!

Another screenshot attached of the Data tab in Service Studio

WhipMeister wrote:

Thought I had it with the Expose Read-Only property, but setting that to 'No' and re-publishing did not change anything. 

Hi,

Re-publishing it will not "re-run" scaffolding (the automatic creation of List Detail screens).

So, after you put Expose Read Only as No, you need to delete all the screens you created previously and Drag and Drop the Entities again on the UI Flow. 

This time scaffolding will create the buttons you are searching for.

NOTE: Before doing that, don't forget to update the references inside the module that are using this entities (the module that will have the Screens) and publish it. 


Solution

Alberto Ferreira wrote:

WhipMeister wrote:

Thought I had it with the Expose Read-Only property, but setting that to 'No' and re-publishing did not change anything. 

Hi,

Re-publishing it will not "re-run" scaffolding (the automatic creation of List Detail screens).

So, after you put Expose Read Only as No, you need to delete all the screens you created previously and Drag and Drop the Entities again on the UI Flow. 

This time scaffolding will create the buttons you are searching for.

NOTE: Before doing that, don't forget to update the references inside the module that are using this entities (the module that will have the Screens) and publish it. 


Thank you so much. Deleting and re D&D back into the Entry screen did not change the behavior. *BUT*, deleting the entire web app and recreating it from scratch *DID* finally make the 'Create new ' link appear and all is well. Obviously I would like to avoid having to resort to such a radical fix. One thing I did not do was delete the references and re-link them. That me be the secret sauce. I'll try that on another dataset.

Thanks again for your help!


Solution

Hello,

You don't need a so radical solution. :)

When you make a reference, your consumer module is using a certain version of the producer module.

If you change the producer, than you need to refresh the references in the consumer module, so that it becomes aware of the changes.

Than redoing the scaffolding would work.

Cheers.