No Component
forceworks opened this issue · comments
Hi Rick, trying out the calendar control. Installed managed solution, but no control visible :(
Hi Steve,
If you are trying to add the control in a canvas app:
-
After installing the solution file, make sure that code components is enabled for the org you are using,
-
Open the canvas app, navigate to components > Import > Code > Calendar
-
To add it to the screen, you need to click the "+ Insert" button on the left nav bar
-
Navigate and expand "Code components" and select Calendar
(Note: Code components, for me, are not shown under the usual top menu bar "Custom" where I would expect them to be. Could be by design or a bug.)
Overall I have found this is a really great calendar control for Canvas apps.
I haven't worked with using the control in a model app yet. So I can't help you there.
Hope this helps,
-Art
I do know that in a model app, you have to create an entity view, and add the control to the view and indicate the fields used for event name, start date, end date.
The control is view specific and can't be added at the entity level as a control that applies to all views as you can do with the Dynamics calendar control.
-Art
PS. I have a long list of issues I would be happy to add to your list on needed AppSource fixes :)
@rwilson504
Hi Rick
Can I ask your advice on using the Calendar PCF control in a canvas app?
I've successfully imported the Calendar PCF using the managed solution from Github, and am able to insert it into my canvas app. However, I'm not sure what I'm doing wrong to get the calendar to show events.
My scenario:
- I have a CDS entity called "myevents" created with fields "myevent", "start" & "end"
- The unique identifier for this entity is "hc_myeventsid", and the primary field is "myevent"
- Data from this entity is loaded into a collection (colAppt) in the canvas app, as recommended in the readme. I am using AppStart to load the collection (and yes, AppStart has been run :) )
- in the PCF control, I have put "hc_myeventsid" (with the double quotes) in the eventid field.
- In the field calendarDataSet_Items, I have put the collection as the source.
- No fields have been selected under Properties for the control.
But the calendar is not showing the events. I have saved, exited, and restarted the app as well.
Putting just hc_myeventsid (without the double quotes) throws an error
What am I missing?
Also I just uploaded a sample managed solution you can install.
This sample does not include the Calendar component in it so that you can easily install/remove this managed solution without accidentally removing the Calendar component from your system.
There is a model app included with the solution so you can easily add/modify data and it also includes a Canvas app where i have provided different ways you can utilize the calendar.
Let me know what you think.
Thanks,
Rick
Thanks Rick - much appreciated
The import of the managed solution fails, as it requires a custom control which I don't have (screenshot below)
But I just configured the React Calendar again from scratch with a custom entity which had the relevant fields, and it works.
When I changed to using the standard Appointments entity in CDS, the control doesn't seem to work if connected directly to the entity in CDS. I suspect this is because Appointments uses activityid as it's GUID, which is really just a pointer.
But if you load the Appointments entity to a collection, it seems to work.
Have you experienced something similar?
Yes i have found that attaching directly to a CDS entity usually doesn't work. I would always suggest using a collection.
Also here is an updated Sample that does not include the Scheduler component.