Again: Setting up Multiple resources with M$ SQL |
Post Reply |
Author | |
flauzer
Senior Member Joined: 30 December 2003 Location: Italy Status: Offline Points: 108 |
Post Options
Thanks(0)
Posted: 18 August 2006 at 6:32am |
Sorry but (for me) the whole architecture of Multiple-Resource is source of confusion.
Suppose that the user A is enabled to see the events of resource R1 and R2....in the code we map "name" R1 e R2 with 2 long ScheduleIDs, with some Hash function....
In SQL event table we add ScheduleID field.
pRes0.Name = "Resource1" pRes0.ScheduleIDs.Add HashforR1 arResources.Add pRes0 pRes1.Name = "Resource2" pRes1.ScheduleIDs.Add hashForR2 arResources.Add pRes1
2) BUT my problem is with providerSQLServer and SQLDataHelper:
I Must modify also code in property (MakeRetrieveDayEventsSQL, and so on) to manage SQL SELECT in accord with the scheduleID ??
Thanks
|
|
sserge
Moderator Group Joined: 01 December 2004 Status: Offline Points: 1297 |
Post Options
Thanks(0)
|
Yes, you must...
Note: Calendar expects that ScheduleID values (which you set to resources and events) should present in DataProvider.Schedules collection. (you have to fill it as well) When you add a new Schedule to DataProvider.Schedules collection, the element's index is assigned as ID by default, but you can easily change ID to your value (other hash or something). ps: attached see updated files from VB sample: uploads/20060821_154751_f4827.zip -- WBR, Serge |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |