My application has a table where each record has 50 dates that I need to show on the calendar.
The way the calendar is integrated each record in the SampleEvent table can have one date or a range of dates.
How can integrate the calendar with my application so that I can show 50 different dates for each record in my table.
Please let me know how I can do this? Thanks.
Help needed in designing with the Calendar
6 posts
• Page 1 of 1
Posts: 5
Joined: Fri Jul 01, 2011 12:47 am |
|
Hi,
Do you have 50 date fields in the table? Ideally in a relational database we would to store that information in a separate table and have it relate back to the main record. I'm guessing that each of these dates represents a certain status/milestone of the main record. So when you create a new primary record, yo could have a script create the 50 related event records (in a portal?) and assign them the appropriate status. You could then fill in the date values in the portal of events, and those are what will sjow on the calendar. For example, in SeedCode Complete we have projects, but the schedule is defined in a portal of related events, and they are what you see on the calendar. Since they're all related back to the main project, it's easy to have project information show up for each event when in the calendar. Let me know if that helps, Jason |
|
Posts: 5
Joined: Fri Jul 01, 2011 12:47 am |
Thanks for responding. The use of the calendar in my application is very simple.
I have a table of patients (1000's of patients). Each patient has 50 visit dates and I want to bring up the calendar for a certain patient showing all the visit dates. Are you suggesting that I create a portal for each patient (there are thousands of patients), where there are 50 event records in the portal. Then can I bring up the calendar to show the 50 dates on a certain patient portal corresponding to a patient? Are you suggesting I do this? The way I was thinking of implementing this was. I can create a new table with the dates for all the patients and relate it back to the patient table with patient id. Then the calendar will have to filter out the patient with a certain patient id from the table. That's why in my other other post I wanted to know if the calendar can pre-filter dynamically from a script where the patient id is known. Thanks again for looking into this. Please let me know how you think I may be able to solve my problem. |
Hi Sohala,
I think we're actually saying the same thing. You'll create a separate table with the events/dates related back to the patients by their id, these would be the records in the portal and would be what the calendar uses as events. That way you can enter the dates in the portal from the patient layout. If you set this up as a creation relationship, then the patient id will automatically be pushed to the records in the portal as you enter the dates. Since all the events would then have a patient ID, you could then add a filter for patient ID to just see the events/dates for that patient. Let me know if that helps and/or makes sense, Jason |
|
Posts: 5
Joined: Fri Jul 01, 2011 12:47 am |
That makes sense but there are other issues that can a problem.
My application has a patient layout, where I placed a button. When clicked I run a script that brings up the calendar showing the 50 dates for the current patient. I will know the id of the current patient in the script and would need to pre-filter the calendar based on the id. I will have to dynamically set the pre-filter to filter on the specific id. Can I do this kind of dynamic pre-filtering? If possible then can you briefly explain how? Thank You, Sohan |
Hi Sohala,
There's several ways to do this, but this is probably the easiest. When you press the button / run the script from the patient layout, set the patient ID to a global variable, something like: $$Patient_ID Then, near the end of the script "Find Events By Date Range," before the script "Apply Filters to Found Set:" add a script step that constrains the found set by the patient id. I've attached a few screen shots to point you in the right direction: Let me know if that helps, Jason |
|
6 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 3 guests