completed an orchard tutorial on displaying a calendar but nothing displays? - orchardcms

I was trying to display some sort of booking system in orchard and I found a set of tutorials that allow you to set queries to display on different dates...
So ive went through all the 18 tutorials for orchard CMS 1.6 displaying a calendar on screen
http://www.youtube.com/watch?v=Iv7rA-viyTw
and my calendar doesnt appear on screen? ive tried changing the widget of it (which selects dates on the calendar) and nothing appears, im logged in as authentic user, (as it is set to show-when creating the widget)
The only thing I can think of (which shouldnt be a problem but worth mentioning - in tutorial 13 where you edit template. when I tried to select a query none where appearing from the drop down list, I created a query as in the tutorials but still none appeared on the content page.) - this threw an error when trying to create a 'calendar widget' so I commented the code causing this in calendarWidgetDriver.cshtml.
//if (part.QueryId <= 0)
//{
// updater.AddModelError("QueryId", T("You must select a query."));
//}
But this only matters when you want to display a query on a date. surely it shouldnt matter for displaying the entire calendar. I realise this is a bit of a jump for a large Q. but im hoping on the off chance someone has encountered the same problem.
If so I would be glad to know.
thank you all
I have tried contacting the owner but as of yet no word so thought I would try here....
EDIT 1...
Logs
2013-08-21 10:06:37,658 [32] Orchard.Environment.Extensions.ExtensionManager - No suitable loader found for extension "FoodPodBootstrapTheme"
2013-08-21 10:07:06,130 [32] Orchard.ContentManagement.Drivers.Coordinators.ContentPartDriverCoordinator - ArgumentException thrown from IContentPartDriver by UMACS.FoodPod.Drivers.CalendarWidgetDriver
System.ArgumentException: queryId
at Orchard.Projections.Services.ProjectionManager.GetContentItems(Int32 queryId, Int32 skip, Int32 count)
at UMACS.FoodPod.Services.CalendarService.GetCalendarEvents(CalendarWidgetPart part)
at UMACS.FoodPod.Drivers.CalendarWidgetDriver.<>c__DisplayClass3.<Display>b__2()
at Orchard.ContentManagement.Drivers.ContentPartDriver`1.<>c__DisplayClassf.<ContentShape>b__e(BuildShapeContext ctx) in C:\WORK\Orchard1.6.1\Orchard.Source\src\Orchard\ContentManagement\Drivers\ContentPartDriver.cs:line 130
at Orchard.ContentManagement.Drivers.ContentPartDriver`1.<>c__DisplayClass15.<ContentShapeImplementation>b__14(BuildShapeContext ctx) in C:\WORK\ Orchard1.6.1\Orchard.Source\src\Orchard\ContentManagement\Drivers\ContentPartDriver.cs:line 139
at Orchard.ContentManagement.Drivers.ContentShapeResult.ApplyImplementation(BuildShapeContext context, String displayType) in C:\WORK\ Orchard1.6.1\Orchard.Source\src\Orchard\ContentManagement\Drivers\ContentShapeResult.cs:line 39
at Orchard.ContentManagement.Drivers.ContentShapeResult.Apply(BuildDisplayContext context) in C:\WORK\ Orchard1.6.1\Orchard.Source\src\Orchard\ContentManagement\Drivers\ContentShapeResult.cs:line 21
at Orchard.ContentManagement.Drivers.Coordinators.ContentPartDriverCoordinator.<>c__DisplayClassa.<BuildDisplay>b__9(IContentPartDriver driver) in C:\WORK \Orchard1.6.1\Orchard.Source\src\Orchard\ContentManagement\Drivers\Coordinators\ContentPartDriverCoordinator.cs:line 49
at Orchard.InvokeExtensions.Invoke[TEvents](IEnumerable`1 events, Action`1 dispatch, ILogger logger) in C:\WORK\Orchard1.6.1\Orchard.Source\src\Orchard\InvokeExtensions.cs:line 17
EDIT 2
following the advice Ron gives at 7.40 of this video:
http://www.youtube.com/watch?v=jOSxGj2gOpY using 'Sources' from F12, he is able to view calendarWidget from inside localhost, i do not have this view able for me. What could i be missing?

The loader error means that Orchard cannot find the FoodPodBootstrapTheme.dll.
When i read ...
No suitable loader found for extension "FoodPodBootstrapTheme"
... i assume it is a project located in ...
src\Orchard.Web\Themes\FoodPodBootstrapTheme
You have most likely added this project to your src\Orchard.sln file in Visual Studio manually and therefore the project is not configured for building correctly.
I had the same error multiple times and this is what helped me to get rid of the error:
Fix theme build dependencies
Open src\Orchard.sln in Visual Studio
Right click on the FoodPodBootstrapTheme node and select Build Dependencies > Project Dependencies
now make sure Depends on contains a tick in checkbox Themes (Themes\Themes)
Fix Orchard.Web build dependencies
Open src\Orchard.sln in Visual Studio
Right click on the Orchard.Web node and select Build Dependencies > Project Dependencies
now make sure Depends on contains a tick in checkbox FoodPodBootstrapTheme

Related

Strapi debug: Error on attribute departure in model

today when I try to run my Strapi with some exercises, there was an error showing that inversedBy attribute flight not found target api::airport.airport. However, the command shows Admin UI was built successfully. but I cannot access the Admin panel and do anything with it. It seems that the error is belonging to one of the content, but the entire API is not working. What should I do? Does anyone know how to fix this bug?
enter image description here
Thank you.
Firstly, I tried to run the start command(npm run develop) for several time, it keep reporting same error.
Secondly, I tried to access the administration panel directly, it is apparently that I failed.
Hopes someone can help me to figure out, how can I solve this bug/error.
I had a similar error.
The issue for me related to a problem where the 'key'(i.e. attribute key in JSON) didn't match that was referenced by the model in the mappedBy & inversedBy.
e.g. mappedBy:"f_light" should point to
"f_light":{type:"relation",...) --
At least that was the problem for me
Strapi Docs on how the schema is supposed to look
My issue: Error on attribute a_token in model a-request(api::a-request.a-request): inversedBy attribute a-requests not found target api::a-token.a-token
This occurred because I inversedBy:'a-token' when the attribute key was 'a_token'. Changing them so they matched solved my issue ('a-token' -> 'a_token').
The naming conventions of mappedBy, inversedBy, and the attribute keys MUST use '_' instead of '-' for spaces, otherwise it will fail the naming convention tests.

WinUI PasswordBox Text Resources

I am trying to define a setting page that includes a PasswordBox element. When I Rebuild the app, the defined Text resources do not show properly. However, if I remove the:
x:Uid="/resources/db_pwd"
definition (see below) then it Rebuilds the view OK. If I try to initialize the view with the resource link defined then I get the error below. It appears as if a Text property for the PasswordBox ... but it does not have this property. Very confused!
Resources
|Name | Value |
|-----------------------|---------------------------|
|db_pwd.Header |Password (default password)|
|db_pwd.PlaceholderText |Enter your password |
|db_pwd.Text |Password (default pwd) |
Password Box
<PasswordBox x:Name="dbpwd" Width="300" x:Uid="/resources/db_pwd"
Header="Database Password"
PlaceholderText="Enter password"
PasswordChanged="PasswordBox_PasswordChanged"
HorizontalAlignment="Left" Margin="40,5,0,0" />
Error Initializing View
Windows.UI.Xaml.Markup.XamlParseException
HResult=0x802B000A
Message=The text associated with this error code could not be found.
Unable to resolve property 'Text' while processing properties for Uid '/sql/db_pwd'. [Line: 38 Position: 68]
Source=Windows
StackTrace:
at Windows.UI.Xaml.Application.LoadComponent(Object component, Uri resourceLocator, ComponentResourceLocation componentResourceLocation)
at WeeWX.Views.SettingsPage.InitializeComponent() in D:\Dave\Documents\Visual Studio\WeeWX\obj\x86\Debug\Views\SettingsPage.g.i.cs:line 49
at WeeWX.Views.SettingsPage..ctor() in D:\Dave\Documents\Visual Studio\WeeWX\Views\SettingsPage.xaml.cs:line 49
at WeeWX.Views.MainPage.SetSettings(Object sender, TappedRoutedEventArgs e) in D:\Dave\Documents\Visual Studio\WeeWX\Views\MainPage.xaml.cs:line 350
This exception was originally thrown at this call stack:
[External Code]
WeeWX.Views.SettingsPage.SettingsPage() in SettingsPage.xaml.cs
WeeWX.Views.MainPage.SetSettings(object, Windows.UI.Xaml.Input.TappedRoutedEventArgs) in MainPage.xaml.cs
Questions
Why is it looking for a Text property, Password Box does not have this property!?
It fails even if I add a Text entry in the resources file as shown. Why?
What is the root cause of this error, and the fix?
To answer your questions:
1.Why is it looking for a Text property, Password Box does not have this property!?
2.It fails even if I add a Text entry in the resources file as shown. Why?
The PasswordBox control doesn't have a Text property. It has a Password property.
3.What is the root cause of this error, and the fix?
To fix this error you need to change your resource:
db_pwd.Text -> db_pwd.Password
Finally fixed this issue, but the scenario is important:
The original definition was a TextBox, which I then changed to PasswordBox
This is when Visual Studio (VS) was still looking to resolve a Text property (of the TextBox I assume vs the PasswordBox.Content property), therefore I thought there must be some caching going on.
I tried to do the Build/Clean Solution thing, with no success
I then did #3 again, restarted VS, still no success
I then did #3 again, changed the name of the db_pwd resources and reference to db_pswd, deleted db_pwd.Text, rebuilt the solution and ... success!
Not sure exactly what steps are required to fix this sort of issue, but the bottom line is that VS has some really dumb (overly optimistic) caching going on! Comments or advice?
PS: Now have a similar issue after changing a TextBox to HyperlinkButton. Fixed through a similar process (step #5)!

Is there a way to resolve this error: "CloudKit integration requires does not support ordered relationships."

I'm trying to use Apple's CoreDataCloudkitDemo app. I've only changed the app settings per their README document. On running the demo, I'm getting the error: "CloudKit integration requires does not support ordered relationships."
(The weird grammar in the title is included in the app)
The console log shows:
Fatal error: ###persistentContainer: Failed to load persistent stores:Error Domain=NSCocoaErrorDomain Code=134060 "A Core Data error occurred." UserInfo={NSLocalizedFailureReason=CloudKit integration requires does not support ordered relationships. The following relationships are marked ordered:
Post: attachments
There is the same error for the "Tags" entity.
I'm using Xcode 11.0 beta 4 (11M374r).
I've only changed the bundle identifier, and set my Team Id.
I removed the original entitlements file - no errors in resulting build.
I've not changed any code from the original.
Does anyone have a workaround, or preferably, a fix? Or did I do something wrong?
Thanks
Firstly, select CoreDataCloudKitDemo.xcdatamodeld -> Post -> RelationShips, select attachments relationship, on the Inspect panel, deselect Ordered, then do the same thing on the tags relationship.
Secondly, there will be some errors in the code now, because we unchecked the Ordered option, the property of attachments and tags in the generated NSManagedObject may changed from NSOrderedSet? to NSSet?. So we could change these error lines of code like below:
Origin:
guard let tag = post?.tags?.object(at: indexPath.row) as? Tag else { return cell }
Changed:
guard let tag = post?.tags?.allObjects[indexPath.row] as? Tag else { return cell }
Finally, you can run the code now. ;-)
Further more, on WWDC19 Session 202, the demo shows they set both attachments and tags relationships as Unordered, so I think there's something wrong in the given demo project.

SharePoint Workflow variable is not recognized in O365 site

I've created a Site Workflow of SharePoint 2013 Workflow type in O365 subsite of a site collection.
I use Call HTTP web service in workflow: screenshot of my workflow
http://www.image-share.com/ijpg-2992-17.html
To parse JSON results I need to use Variable:Index (Integer).
I've tried d/results/([%Variable: Index%])/Title as it is recommended in numerous blog posts (example).
But Workflow gets Suspened with the following error:
RequestorId: 8c3e172b-5da7-75d9-0000-000000000000. Details: An unhandled exception occurred during the execution of the workflow instance. Exception details: System.FormatException: The DynamicValue property 'd/results/([%Variable: Index%])/Title' was incorrectly formatted. at Microsoft.Activities.Dynamic.DynamicValueBuilder.PathSegmentFactory.Parse(String segmentText, String fullPathName) at Microsoft.Activities.Dynamic.DynamicValueBuilder.PathSegmentFactory.Create(String segment, PathSegment next, String path) at Microsoft.Activities.Dynamic.DynamicValueBuilder.PathSegmentFactory.Create(String path) at Microsoft.Activities.GetDynamicValueProperty1.Execute(CodeActivityContext context) at System.Activities.CodeActivity1.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager) at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation) Exception from activity GetDynamicValueProperty Stage 2 Sequence Flowchart Sequence Email30Days.WorkflowXaml_3f207548_d246_4058_82b3_34acf1933b6f
If I use the same but with number (not variable) d/results/(0)/Title it works.
Please, let me know What I'm missing.
It seems there was a glitch in SharePoint Designer. When I opened SPD the next time, it started to resolve [%Variable: Index%] just fine.
I've also tried to add slash in the end of string "d/results/(<index>)/" (like in the following article) before I noticed the first time Index began to resolve, however I never added slash at the ending furthemore.
Just FYI to whoever has similar issue, I noticed that in SPD - likely due to some quirk in copying text into string builder window from the web - if I type text manually or paste it, it doesn't seem to recognize it (same error occurs during workflow execution). But if you type into the window:
d/results(
then click Add or Change Lookups button and reference your variable, then finish typing the text:
)/YourPropertyName
then it all works well.

What to do when get "The model used to open the store is incompatible with the one used to create the store"?

I had a core data EntityDescription and I created data in it. Then, I changed the EntityDescription, added new one, deleted the old one using the editor for xcdatamodeld file.
Now any of my code for core data causes this error "The model used to open the store is incompatible with the one used to create the store}". The detail is below. What should I do? I prefer to remove everything in the data model and restart new one.
Thanks for any suggestion!
reason=The model used to open the store is incompatible with the one used to create the store}, {
metadata = {
NSPersistenceFrameworkVersion = 320;
NSStoreModelVersionHashes = {
Promotion = <472663da d6da8cb6 ed22de03 eca7d7f4 9f692d88 a0f273b7 8db38989 0d34ba35>;
};
NSStoreModelVersionHashesVersion = 3;
NSStoreModelVersionIdentifiers = (
);
NSStoreType = SQLite;
NSStoreUUID = "9D6F4C7E-53E2-476A-9829-5024691CED03";
"_NSAutoVacuumLevel" = 2;
};
Or if you're in dev mode, you can also just delete the app and run it again.
Deleting the app is sometimes not the case! Suggest, your app has already been published! You can't just add new entity to the data base and go ahead - you need to perform migration!
For those who doesn't want to dig into documentation and is searching for a quick fix:
Open your .xcdatamodeld file
click on Editor
select Add model version...
Add a new version of your model (the new group of datamodels added)
select the main file, open file inspector (right-hand panel) and under Versioned core data model select your new version of data model for current data model
THAT'S NOT ALL ) You should perform so called "light migration".
Go to your AppDelegate and find where the persistentStoreCoordinator is being created
Find this line if (![_persistentStoreCoordinator addPersistentStoreWithType:NSSQLiteStoreType configuration:nil URL:storeURL options:nil error:&error])
Replace nil options with #{NSMigratePersistentStoresAutomaticallyOption:#YES, NSInferMappingModelAutomaticallyOption:#YES} (actually provided in the commented code in that method)
Here you go, have fun!
P.S. This only applies for lightweight migration. For your migration to qualify as a lightweight migration, your changes must be confined to this narrow band:
Add or remove a property (attribute or relationship).
Make a nonoptional property optional.
Make an optional attribute nonoptional, as long as you provide a default value.
Add or remove an entity.
Rename a property.
Rename an entity.
Answer borrowed from Stas
If this is a non-production app, just delete your local database (appname.sqlite) and restart the app.
I find I'm always doing this, and so provide the following additional detail:
Under XCode 4 (4.3.2) you should find your datastore here:
/Users/~/Library/Application Support/iPhone Simulator/simulatorVersion/Applications/yourAppIdentifier/Documents
Or you can use Spotlight, if you first enable searching for System Files; I've found it fastest to save such a search to the menu bar.
If this is a non-production app, just delete your local database (appname.sqlite) and restart the app.
Delete your app on simulator and restart:
On simulator, go to Hardware -> Home:
Click and hold mouse button on your application icon:
Click on "X" in app icon to delete:
Go back to Xcode and restart your application(Command+R):
or:
PS.:
If the error appears again, review your code because the problem should be in the syntax or discrepancy between what you want to list with the data model that you have.
Reset your simulator and run again. If you were to run with a different device in the simulator, it would work. If you are running with an iphone 6s simulator and you try to run 6s plus, it would still work without resetting.
If running on a phone, make sure to delete the app and rerun it
I have faced the same issue using Xcode 7 beta 1 and the following action has resolved the issue.
Menu==>> click on Window>Projects>select project on the left hand side and click on delete button which is located on the right side.
If still doesn't work,
=> reset the simulator and run the app

Resources