DIsplay the content in the input box even after the page is reloaded

DIsplay the content in the input box even after the page is reloaded

  

Hi,

I have a list of passengers and with each name one link is associated. After clicking the link there is a webscreen in which there is comment section. So when I write comment and save that page and after going back,  the previous comment should remain there for that particular passenger.

Please help asap.

Thanks,

Ankita

Hi Ankita,

Can you describe better your problem? You add a comment and than when you come back is not there? On save did you include a passengerid on the comment entity and than you use an aggregate to get all the comments from a sepcific passenger?

Regards,

Marcelo

Marcelo Ferreira wrote:

Hi Ankita,

Can you describe better your problem? You add a comment and than when you come back is not there? On save did you include a passengerid on the comment entity and than you use an aggregate to get all the comments from a sepcific passenger?

Regards,

Marcelo


hi Marcelo Ferreira,

the comment is being saved in the aggregate but what I want is that if I again open the webscreen for that particular person for whom I have already wrote the comment in the input box that text should be present there in the input box and moreover the comment can be changed.

I am sharing the screenshots for better understanding in below comment.

CLICKED ONE NAME OF THE EDIT:

ADDED THE COMMENT AFTER CLICKING AND SAVED THE COMMENT :

IT WENT BACK TO THE PREVIOUS PAGE AND THEN AGAIN I CLICKED THE SAME PERSON (I.E. anki):

AFTER CLICKING THE COMMENT WHICH I WROTE PREVIOUSLY WAS PRESENT THERE WHICH I CAN EDIT :


How can I do this in my platform?

Please help


Thanks

Hi Ankita,

When you open the details for the passenger, are you getting the passenger's information from the database to present on the form?... if so, it's just a matter of reading the comment as well (I assume it's being stored in a different entity?). Depending on how it is implemented, you can add the comment entity with a Join to the existing Aggregate, or you may need to add a new Aggregate to read the comment entity record for that particular passenger.

Can you explain a bit better how your Passenger details page and your data model work?


Hi Ankita,

For those 2 fields you defined variables to be linked to them. On the preparation you need to fill those variables with the values that you get from the database. If this isn't enough maybe you can share with us what you already have.

Regards,

Marcelo

Hi Ankita,

I'll go in the same line of Jorge's comment, but I will try to explain in a different way.

You have an entity, that you are using to show a list of passengers in your LIST page.
When you click in an item of the list, you want to go to a DETAIL page, that shows the details of that specific passenger.

The "how to do" this is explained in the Online Training: https://www.outsystems.com/learn/
If you didn't take it yet, I recommend you to take it, as this will speed up your OutSystems development skills.
If you already did, I recommend you to revisit it.

In any case, if you created your entity with the comment field (only ONE comment per passenger is allowed), you can simple use the Scaffolding to create both pages.

1. Drag the entity that has the passenger information and drop it into the Main Flow of your application. This will create the LIST page.
2. Repeat the first item (1). This will create the DETAIL page and will make the links between both screens.

----

If you have the comment in a separated entity (can have MANY comments), after making 2, you do the following:
3. Drag and drop the Comment entity into the DETAIL page below the buttons, to create a master detail page.

Hope this helps.

Cheers.