Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Manipulating Data Within Portal Without Affecting Displayed Record

Featured Replies

  • Newbies

Hello!

 

*Please see attached file*

 

I'm trying to create a field inspection sheet. Here's what I'm trying to achieve:

-I want to create a portal that displays different elements to be inspected based on the project type.

-I want the user to be able to comment on the inspected element.

-The comments mentioned above should be different for each project

 

The problem I'm facing is:

-I am not sure how to create the comment field (yellow in the database) that would be related to the main record, not the one displayed in the portal.

 

 

Is there a way to do this? I am also aware that I'm probably going to need a completely different approach.

The reason I tried doing this with a portal is because I'm going to have a lot of elements to inspect and I'm going to program the portal to display filtered values based on another field.

The attached file is to show you what I wan't to achieve.

 

Thank you very much for your help!

 

-FileJazz

Portal_Comment.zip

If you look in your graph, you will notice that you have a fork on each end of the line.  This indicates that you have a many-to-many relationship.  You need to use a join between the two to resolve the issue.  I've changed your graph to show how this is handled.

 

Also note that every table should have a unique ID.  You started to enter _pk... but you didn't make them auto-enter serial or UUID.  I changed them to proper relational setup as well.

 

Join tables are used similarly in the following configurations:

 

Invoices -< InvoiceLines >- Products

Surveys -< Answers >- Questions

 

Note also that I changed your portal to this new join table, but the Element fields remain the same - only the comment belongs to the ProjectElements join table.

Portal_CommentMOD.fmp12.zip

  • Author
  • Newbies

Thank you for the reply!

 

It did help me with the formatting! 

I guess what I'm looking for is that  Survey -< Answers >- Questions

Where the Survey would be the Project Type,

The Questions would be the Elements to Inspect

And the Answers would be the Inspectors Comments/Notes.

 

I will search for templates/examples of surveys!

 

Thank you very much for your help!

But what I gave you is exactly that.  :-)

  • Author
  • Newbies

Oh!

Well in that case, how would I make it so that the "questions" shown in the portal are the same for each new inspection (survey)?

 

Here's an example of what I would like to see in the portal for every new project (The ID and Question fields would be filled, but Comments would be blank when creating a new record)

 

ID      "Question"               Comment (Answer)

1       Height of building       2.0m

2       Length of building      Too long

3       Floor area                  OK

4       Beam size                  ...

5       ...

6

7

8

 

The questions would never change and would be shown in the portal, however the Comment will be a field that is filled in by the user every time.

Is this possible within a portal? 

 

The reason I want to use a portal is so that I can filter the questions within the portal afterwards.

 

Thank you!

 

FJ

Ah yes.  The first structure is what displays the questions asked (Elements) and the answers given (ProjectElements) for the Project.  New file shows how to display ALL Elements for the Project where you can answer all questions for that Project.  Layout is called Project Survey.

 

Note that there is a script trigger on that layout OnRecordLoad.  Its purpose is to set a global field in Elements with the Project ID as you move through Project records so the relationship to Answers uses both the ProjectID and the ElementID in the newly created ProjectElements (Answers) table occurrence.

 

You can do away with the first relationship if you always wish to display all Elements for the Project.  You can use portal filter to limit the Elements.


Notice also that I have turned on 'Allow Creation of Related' to the Answers portal so typing an answer into the Comment field creates the new ProjectElements records.  

Portal_CommentMOD2.fmp12.zip

  • Author
  • Newbies

Wow this is exactly what I've been searching for! I'm going to be able to handle it from here!

 

Thank you very much LaRetta!

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.