Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 2542 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hi Everyone,

I need help with portal show records. I have attached the example solution. There are four tables. Office, Staff, Asset and Assign (Asset assigned to staff).

On Asset layout i have portal based on Assign table i want the portal to show only staff members which are related to specific/related office not all staff.

Maybe its already answered or its simple to solve but i couldn't find any after searching/googling. If any answer is already in forum please give me link or modify

this solution i shall be very thankful.

Thanks in advance for help.

 

Assets.fmp12

Posted (edited)

Hi Ash

I've enclosed a revision of your sample file.

I added a global field in your 'Asset' table to act as the selector, to decide which 'Assignments' to view. Then I added a filter to your portal that only show the records that match the current selection.

You can't have it based on the 'idOffice' in Assets since that changes which office the asset is assigned to, which is wrong, hence needing the new global field. I also added a script trigger to my new selector field to refresh the window when the value changes, to force the portal to refresh which records it shows.

Also, I had to add an Auto-Enter 'Lookup' on the 'idOffice' field in 'Assignments' so that each assignment knows which office the asset it references is located in. This was required to do the portal filter.

Note that portal filters only change what is viewed, it doesn't actually change which values are found by the relationship which shows the portal. Therefore if you did any calculations such as Sum (Assignments::qty) in the Assets table, then it would add up all the related records, NOT just the ones shown in the portal. You'd have to change the relationship itself if that was a problem.

Hope that helps and good luck as you learn!

Assets.fmp12

Edited by rwoods
  • Like 1
Posted

Thank Rwoods for your reply.

Maybe i am not asking the right question or using FM lingo.

Let me try in simple words what i want. An office (A) has five Staff (A Staff1, A Staff2, ... ) same as Office B and C ... etc.

Each office buys Asset and Assign that asset to staff. In Asset Layout I have portal which is based on Assign Table. When inside that portal i want to assign an Asset i see all the Staff from all offices. What i want is to see only Staff for the office which bought the asset not all the staff.

Sorry if i didn't made clear what i need. 

 

Thanks again for the help.

Posted (edited)

Oh OK, right well I've updated again. Had to just create a new Value list that shows the correct staff. You can see it in the list of Value Lists.

I also renamed all the table occurrences in the graph using standard anchor-buoy naming conventions so they weren't all called Office 2, Staff 2 etc.

Assets.fmp12

Edited by rwoods
  • Like 1

This topic is 2542 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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