NathanAshton Posted March 4, 2009 Posted March 4, 2009 Hi All, I am in the process of developing a db solution with an aviation focus. I am a novice-intermediate with Filemaker and have had a lot of help from more experienced people in putting this together so far. The basic functionality that exists, is: 1. Create a Flight 2. Create sectors for a particular flight 3. Assign crew to particular sectors of a flight The above functionality currently works. What I would like to do now is add the ability to add crew to a flight as a particular category (ie as a Pilot, Crew or Passenger). I envisage doing this the following way. 1. Select the sector. 2. A portal is shown listing all crew and 3 x Checkboxes next to each name. 3. Check the category they belong to I require this extra functionality for when it comes to doing up the reports. I'm sure if someone could look at my attached database they might be able to help me out. Cheers Gen_Decs_Updated.zip
Søren Dyhr Posted March 4, 2009 Posted March 4, 2009 A pretty easy way to accomplish assigning in categories is to have a tabbed layout where different valuelists are fitted to the same field as done with the template attached... However if passengers are to be included as well, might checkboxes in this way not be a convient way of doing it, so a carthesian portal might be a better choise using the Jeff Almquist, way of making the checkboxes show. http://www.fmforums.com/forum/showpost.php?post/226868/ --sd
NathanAshton Posted March 4, 2009 Author Posted March 4, 2009 Thanks for the reply. There won't be any passengers as such. More like Crew travelling as a passenger. All the assigning to a category will be from the list of crew which will be around 50 people in the end. Your method sounds interesting. I'm certainly open to different techniques of achieving my aim, I just thought of my portal method from a user interface point of view. Cheers
comment Posted March 4, 2009 Posted March 4, 2009 Try something along the lines of the attached, perhaps. Gen_Decs_Updated2.fp7.zip
NathanAshton Posted March 4, 2009 Author Posted March 4, 2009 Wow, that's brilliant! Blows my mind how you guys can wrap your head around relationships etc so easily. Must come with practice? Im going to give it a good test run later, only issue might be how the Popup Menu reacts when there is a large number of records showing
comment Posted March 4, 2009 Posted March 4, 2009 There are other selection methods available. I only looked at the relationships, not the user interface.
NathanAshton Posted March 4, 2009 Author Posted March 4, 2009 One more thing before I forget. I've added a button in the portal where you add / select a sector. The purpose of the button is to open a report which displays the sectors, the crew for that sector along with their details etc. Because there are so many tables now, which table should this report be showing records from?
comment Posted March 4, 2009 Posted March 4, 2009 I am a bit confused: adding a (new) sector to a flight is one thing; reporting on an (existing and populated with crew) sector is another. In any case, a report is best produced from the Assignments table. BTW, the Roles table may not be necessary, and could be replaced by a custom value list.
Søren Dyhr Posted March 4, 2009 Posted March 4, 2009 I've just discovered that the modification I suggested weren't attached at all... --sd Gen_Decs_SD.zip
NathanAshton Posted March 5, 2009 Author Posted March 5, 2009 Thanks to your help I am now 95% finished. I managed to get my report up and running except for one part which I believe is a relationship issue. If you look at the attached, when crew are assigned to a sector, they are assigned in either the capacity or OP, DHC, or TMA. The buttons at the bottom are to print the reports. The PRINT OPERATING button currently prints all crew for that sector regardless of their capacity. Id like it to only print those marked OP, same for the remaining buttons (ie PRINT DHC, only prints those marked DHC) Thanks again for your help. Really appreciate it. General_Declarations.zip
NathanAshton Posted March 5, 2009 Author Posted March 5, 2009 Yeh pretty much mandatory. I tried doing a find for "DHC" then sending those results off to the Report but it cant find anything. Same for the other categories. I thought that would have been the easiest way
comment Posted March 5, 2009 Posted March 5, 2009 That WOULD have been the easiest way - if your report was a list of the Assignments table. But you are using a portal instead, so a find is irrelevant. You must define another relationship between Sectors and Assignments, and filter it by Role. You can use a global field in Sectors to do the filtering, and have your script set this field accordingly to the type of report.
NathanAshton Posted March 5, 2009 Author Posted March 5, 2009 I don't suppose you could spell it out in detail for me? I'm not the best with relationships :
comment Posted March 5, 2009 Posted March 5, 2009 You can see an example of filtering a relationship by type here: http://fmforums.com/forum/showpost.php?post/317020/
NathanAshton Posted March 6, 2009 Author Posted March 6, 2009 Sorry but for the life of me I just can't work it out.The rest of the functionality is finished just this last hurdle and I'm done. You can see per my updated example, that the crew are allocated as either capacity OP, DHC or TMA. The buttons at the bottom print the General Declaration report for that sector. "Operating" crew should print OP, Print DHC should print DHC and so on. Also, I tried changing the Value List for the crew selection to a drop down box, but all I get is the CrewID showing. Once again, I'm stuck on that also. Anyone able to make the changes for me, so I can see how it's done, and move on with the project? Cheers General_Declarations.zip
comment Posted March 6, 2009 Posted March 6, 2009 Well, I can do it, but you'll never learn that way. General_Declarations.fp7.zip
NathanAshton Posted March 7, 2009 Author Posted March 7, 2009 (edited) I think one of my relationships may have "broke", Out of the blue, the General Declaration form is showing empty, even when crew are assigned. I have checked the Assignments table, and all the ID's seem to be allocating correctly. I have deleted the General Declaration form and recreated in case the error was there, but no change. The Form 3 Inwards & Outwards work ok, but they rely on a different relationship. I made some changes to the layout earlier (fonts, colours etc) and it hasn't worked correctly since then. Does Filemaker ever "break" the relationship? Bug maybe? or just novice user :B General_Declarations_-_Not_Working.zip Edited March 7, 2009 by Guest
comment Posted March 7, 2009 Posted March 7, 2009 Do you understand what the script parameter does in my script, and where is it coming from?
NathanAshton Posted March 7, 2009 Author Posted March 7, 2009 I can see that it's creating a gRole global field for every sector. The SelectorsSelected:gRole is related to the Roles field in the Assignments 3 table which is where I am allocating roles on the sector. So when I am allocating a role, I am setting the gRole GlobalID? When I print the report it is using this gRole to Get(ScriptParameter) which determines which roles to print?
comment Posted March 7, 2009 Posted March 7, 2009 Not creating - populating. And the second part of the question? BTW, these are rhetorical questions. You really need to figure this out for yourself.
NathanAshton Posted March 8, 2009 Author Posted March 8, 2009 *******, I just figured it out. Was staring me right in the face....Button "Optional Script Parameter" Cheers
Recommended Posts
This topic is 5799 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 accountSign in
Already have an account? Sign in here.
Sign In Now