jamesooooo Posted September 13, 2003 Posted September 13, 2003 OK, I am working on a scheduler for my company and hit a stumbling block. i have a general idea on what i think may work but need advice from some of you FM wizards. . OK, i have a db that is called jobs. it has all the information for a given job i enter in when a customer calls. Then i have a db called schedule that has a portal to jobs and lists the jobs that are scheduled and draws a line across the screen to show visually the time slot it is in say 8am-10am ( scheduled window for my arrival time at my customers home ) that works great. now what i want to do is have another portal ( i think thats the way to do it ) that will list mt techs ( only me atm and show what they have been doing and or are doing that day. like i click a job in the first portal and it takes the job from the first portal and puts it in the portal on the row with my name and draws the line starting at the time i was dispatched. then repeat that over and over all day as i get dispatched to new jobs. so i would have all my jobs on one row. and the other techs would have the same. i have been thinking about this for days and its a real brain teaser for me. I was thinking of doing the following maybe someone can tell me if they think i am going in the right direction. Ok, i add another line items type db that has a portal to jobs and it has using the date and tech name to know wich files records to bring into the portal. then schedule looks to line items and the portal in it for the list of current jobs assigned to me for the day. i know this doesn't cover all the things i need to do but does this sound like i am heading in the correct direction? also how do i make it so the first portal in schedule only list records in the portal if a given fields value is "Unassigned" ? any help would be great. my brain has been cooking for days on this one.
jamesooooo Posted September 14, 2003 Author Posted September 14, 2003 Hmm, Can I get data from a portal in line item and display it in another portal in another db? meaning can one portal look into and get data from another portal?
Ch. Posted September 14, 2003 Posted September 14, 2003 This is where you're losing me... " what i want to do is have another portal ( i think thats the way to do it ) that will list mt techs ( only me atm and show what they have been doing and or are doing that day. like i click a job in the first portal and it takes the job from the first portal and puts it in the portal on the row with my name and draws the line starting at the time i was dispatched. then repeat that over and over all day as i get dispatched to new jobs." But it sounds like you want a record for each Tech including yourself listing jobs for each. So, set up a Tech's file. In the Schedules file, on the Jobs portal, you could add a field to enter the tech's id. You could then set up a relationship from the Techs file using the techs id as the match field, with the Jobs file. Then add a portal to the Tech's file using this relationship (sorting by date, descending) and voila! Portals are not designed to get information from other portals - but there's nothing to stop you from getting data from one file into one or more files. "so i would have all my jobs on one row. and the other techs would have the same" - you can't have more than one record on a portal row. "also how do i make it so the first portal in schedule only list records in the portal if a given fields value is "Unassigned" ?" Create a second portal with a relationship that includes "unassigned": In Jobs, I presume you have a value list with "unassigned" as an option. If not, you would need to create one eg. Field name: assigned_unassigned value list: assigned unassigned In the Schedules file, define a field whose only value is "unassigned". Set up the relationship in the Schedules file, matching the field containing the word "unassigned" in the Schedules file with the field containing the value list in the Jobs file. This will now show only unassigned jobs. Hope this helps. Paula
jamesooooo Posted September 14, 2003 Author Posted September 14, 2003 OK, i have another idea. I can use count(relationship::field) and find how many matching records in my line items db. is there a way i can use a calculation field to check a given field in each of those records ?
jamesooooo Posted September 14, 2003 Author Posted September 14, 2003 Sorry, i posted after you. I was in the middle of my post when a friend came over. hmm. i will try that, but i am still going to try and find a work around to get the values from different jobs into the same portal line. the reason for what i want is to make it draw a line something like this: 1pm 2pm 3pm 4pm 5pm 6pm 7pm 8pm joe tech ------------- ---------- ------- Each line represents a job he has done today or say a lunch break or a trip to the shope etc. i have done this with the jobs list and it works great. but i only had to draw 1 line per portal row. as each row was a job with only one time frame. but the techs portal will have multiple time frames per row as his shift goes on. i have been go nuts trying to figure this one out. i use a container field that has a bitmap i made of a line in windows paint and a bunch of calculation fields in a row that will equal that conrtainer with the bitmap if the field is in the time slot of that job. works really nice. just this one that has to look at into from multiple records to draw more that one line if tough.
Ch. Posted September 14, 2003 Posted September 14, 2003 You're forgiven. What do you mean by "just this one that has to look at into from multiple records to draw more that one line if tough"?
jamesooooo Posted September 14, 2003 Author Posted September 14, 2003 Opps, is tough.. I got the filter to work doing what use suggested. Ok, I will try to explain my project clearer " not easy for me. hehehe ) Ok, i have 2 portals in my layout in the DB schedule. the first one does the following : 1PM 2PM 3PM 4PM 5PM 6PM 7PM etc, customer -------------- Ok, what its doing is looking in the DB named jobs and in jobs there are a bunch of calculation fields 96 to be exact. named like this : pm1 pm115 pm130 pm145 pm2 etc. and each has a calculation that if that field lands in the time window that the job in that record ( in jobs ) it will equel a global field wich is a container that holds a bitmap of a line. so what ends up happening is if you make a record in jobs and give it a schedule time of say 2pm till 4pm then the calculation fields pm2 thru pm4 will have a bitmap in them with a line and the portal in schedule will diplay them as one long line from 2pm to 4pm. and it will have the job number and customers name as well. so when i look at the portal i will see all the jobs scheduled for the day with a graphical line to help with seeing the schedule mapped out for the day so i don't schedule too many for any given time frame. ok. hehe now. i want to have the second portal do kinda the same thing. but, instead of having it displaid by job numer and customer name i want it to display by the tech, so it will look something like this: 1pm 2pm 3pm 4pm 5pm 6pm 7pm joe tech --------- -------- -------- bob tech ------- -------- -------- ------ were each of the lines you see on a techs line in the portal represents a job he did. kinda tricky as i bet you can see. I think i need a line items type of db wich will hold the techs name and the date and the time frames he has been working on jobs then display them in the portal in scedule. i think thats what i need to do. what do you think?
Ch. Posted September 14, 2003 Posted September 14, 2003 What you want to do can't be done through a portal on the Schedules file, but it can be done! In the Schedules file, define fields for the number of techs you expect and call them something like Tech1, Tech2, Tech3 etc. The fields could be formatted as pop-up so that you can select the tech's name from a list in the Tech's file, or they could be entered automatically through scripting. Also, in the Schedules file define the same number of calculation fields, eg. c_tech1_date, c_tech2_date, c_tech3_date, and the calculation should be as follows: tech1 & DateToText(date) In the Jobs file, create a field to calculate the same value tech_name & DateToText(date) Then go to the the Schedules file and define a relationship using the two fields you just specified: c_tech1_date::c_techname_date You will have to create a relationship for each tech c_tech2_date::c_techname_date c_tech3_date::c_techname_date Still in the Schedules file, drag the correct bitmap calculation field (ie.12-2pm, 2-4pm etc.) beside the fields Tech1, Tech2 and Tech3, using the correct relationship for each tech. A tad complicated, but do-able :0) Paula
Ugo DI LUCA Posted September 14, 2003 Posted September 14, 2003 Hi, You seem to be looking for a simulated 'Horizontal Portal' You'd be able to display say 10 slots, and move "horizontally" to the 96th using a script. Surely a GetField() could be used here. This would, as far as I understood, involve 10 relationships using a concanation of the time slot calc (each of your 96 current calcs) with the Date field. Check CobaltSky Web Site for an example of a simulated Horizontal Portal, where multiple records can be viewed on the same line.
Ch. Posted September 14, 2003 Posted September 14, 2003 Correction to my earlier post - I meant to say What you want to do can't be done through a portal on the Schedules file, easily. You could of course design a button to create the line items for a particular schedule...but that's another storey :0) Paula
jamesooooo Posted September 15, 2003 Author Posted September 15, 2003 Thanks for the ideas, I will see what i can do
Recommended Posts
This topic is 7742 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