leekelleher / umbraco-contentment

Contentment for Umbraco - a state of happiness and satisfaction
https://marketplace.umbraco.com/package/umbraco.community.contentment
Mozilla Public License 2.0
154 stars 70 forks source link

[Umbraco 12.0.1] Can't choose the datasource #340

Closed hoanganh9610 closed 1 year ago

hoanganh9610 commented 1 year ago

Which Contentment version are you using?

4.4.5

Which Umbraco version are you using? For example: 8.14.1 - don't just write v8

12.0.1

Bug summary

The datasource dont show anything in config. image

Steps to reproduce

Go to /umbraco and select any data type of this library

Expected result / actual result

No response

Do you have Umbraco ModelsBuilder enabled?

What browsers are you seeing the problem on?

Chrome

leekelleher commented 1 year ago

@hoanganh9610 Thank you for reporting this.

Do you get any errors in the browser's dev tools console panel? e.g. F12

If it has JavaScript errors about missing AngularJS controllers, then my educated guess would be that the "/App_Plugins/Contentment" files are missing from your website.

hoanganh9610 commented 1 year ago

image This is the error from browser. In my source I have the "/App_Plugins/Contentment" folder image

hoanganh9610 commented 1 year ago

@leekelleher

leekelleher commented 1 year ago

@hoanganh9610 Thanks. That looks like the error I was expecting to see, but strange that Contentment's JavaScript file is there, but not being loaded in. 🤔 I'm seeing the "umbraco-backoffice-js.js" file, which means that Umbraco is being ran in production mode... so maybe somehow the JavaScript isn't being loaded in there. But again, I'm not sure why not. Could try in development/debug mode, see if that works for now? 🤔

hoanganh9610 commented 1 year ago

I run this source in local and Runtime:Mode :"Development"

This is the error log ```json {"@t":"2023-09-05T11:16:42.5630221Z","@mt":"An unhandled exception has occurred while executing the request.","@l":"Error","@x":"System.IO.FileNotFoundException: No such file exists C:\\Users\\Dainn\\Projects\\ATM\\mpe\\src\\mpe\\Smidge\\Cache\\DESKTOP-L77LK1L\\2ad155b8b937cbc2afec5af55ab26fefabe1b0c4\\umbraco-backoffice-extensions-js.s.map (mapped from 2ad155b8b937cbc2afec5af55ab26fefabe1b0c4/umbraco-backoffice-extensions-js.s.map)\r\nFile name: 'C:\\Users\\Dainn\\Projects\\ATM\\mpe\\src\\mpe\\Smidge\\Cache\\DESKTOP-L77LK1L\\2ad155b8b937cbc2afec5af55ab26fefabe1b0c4\\umbraco-backoffice-extensions-js.s.map'\r\n at Smidge.Cache.PhysicalFileCacheFileSystem.GetRequiredFileInfo(String filePath)\r\n at Smidge.InMemory.ConfiguredCacheFileSystem.GetRequiredFileInfo(String filePath)\r\n at Smidge.Nuglify.NuglifySourceMapController.SourceMap(BundleRequestModel bundle)\r\n at lambda_method541(Closure, Object, Object[])\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.SyncActionResultExecutor.Execute(ActionContext actionContext, IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeActionMethodAsync()\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeNextActionFilterAsync()\r\n--- End of stack trace from previous location ---\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeInnerFilterAsync()\r\n--- End of stack trace from previous location ---\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeFilterPipelineAsync()\r\n--- End of stack trace from previous location ---\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)\r\n at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)\r\n at Microsoft.AspNetCore.Routing.EndpointMiddleware.g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger)\r\n at Umbraco.Cms.Web.Common.Middleware.BasicAuthenticationMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)\r\n at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass6_1.<b__1>d.MoveNext()\r\n--- End of stack trace from previous location ---\r\n at Umbraco.Cms.Web.BackOffice.Middleware.BackOfficeExternalLoginProviderErrorMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)\r\n at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass6_1.<b__1>d.MoveNext()\r\n--- End of stack trace from previous location ---\r\n at Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.Invoke(HttpContext httpContext)\r\n at Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider)\r\n at Microsoft.AspNetCore.Session.SessionMiddleware.Invoke(HttpContext context)\r\n at Microsoft.AspNetCore.Session.SessionMiddleware.Invoke(HttpContext context)\r\n at Microsoft.AspNetCore.Localization.RequestLocalizationMiddleware.Invoke(HttpContext context)\r\n at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)\r\n at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)\r\n at StackExchange.Profiling.MiniProfilerMiddleware.Invoke(HttpContext context) in C:\\projects\\dotnet\\src\\MiniProfiler.AspNetCore\\MiniProfilerMiddleware.cs:line 112\r\n at Umbraco.Cms.Web.Common.Middleware.UmbracoRequestMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)\r\n at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass6_1.<b__1>d.MoveNext()\r\n--- End of stack trace from previous location ---\r\n at Umbraco.Cms.Web.Common.Middleware.PreviewAuthenticationMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)\r\n at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass6_1.<b__1>d.MoveNext()\r\n--- End of stack trace from previous location ---\r\n at Umbraco.Cms.Web.Common.Middleware.UmbracoRequestLoggingMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)\r\n at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass6_1.<b__1>d.MoveNext()\r\n--- End of stack trace from previous location ---\r\n at SixLabors.ImageSharp.Web.Middleware.ImageSharpMiddleware.Invoke(HttpContext httpContext, Boolean retry)\r\n at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context)","EventId":{"Id":1,"Name":"UnhandledException"},"SourceContext":"Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddleware","RequestId":"40000028-0003-fc00-b63f-84710c7967bb","RequestPath":"/sb/nmap/umbraco-backoffice-extensions-js.js.v2ad155b8b937cbc2afec5af55ab26fefabe1b0c4","ProcessId":37940,"ProcessName":"iisexpress","ThreadId":39,"ApplicationId":"238a5a74592914da44b37cedb32e49e4652c4b8b","MachineName":"DESKTOP-L77LK1L","Log4NetLevel":"ERROR"} {"@t":"2023-09-05T11:17:17.1709567Z","@mt":"Could not find a value for configuration field '{ConfigField}'","@l":"Warning","ConfigField":"dataSource","SourceContext":"Umbraco.Cms.Core.Models.Mapping.DataTypeMapDefinition","ActionId":"713d8c18-2791-4612-913c-3a322c63e99d","ActionName":"Umbraco.Cms.Web.BackOffice.Controllers.DataTypeController.GetPreValues (Umbraco.Web.BackOffice)","RequestId":"4000003f-0000-fb00-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/umbracoapi/datatype/GetPreValues","ProcessId":37940,"ProcessName":"iisexpress","ThreadId":39,"ApplicationId":"238a5a74592914da44b37cedb32e49e4652c4b8b","MachineName":"DESKTOP-L77LK1L","Log4NetLevel":"WARN ","HttpRequestId":"ff9dc8f3-5c25-473f-beb0-6d98cfcd2738","HttpRequestNumber":2,"HttpSessionId":"c0bc0b64-7860-6d12-898a-d9edc18dfac6"} {"@t":"2023-09-05T11:17:17.1718653Z","@mt":"Could not find a value for configuration field '{ConfigField}'","@l":"Warning","ConfigField":"labelStyle","SourceContext":"Umbraco.Cms.Core.Models.Mapping.DataTypeMapDefinition","ActionId":"713d8c18-2791-4612-913c-3a322c63e99d","ActionName":"Umbraco.Cms.Web.BackOffice.Controllers.DataTypeController.GetPreValues (Umbraco.Web.BackOffice)","RequestId":"4000003f-0000-fb00-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/umbracoapi/datatype/GetPreValues","ProcessId":37940,"ProcessName":"iisexpress","ThreadId":39,"ApplicationId":"238a5a74592914da44b37cedb32e49e4652c4b8b","MachineName":"DESKTOP-L77LK1L","Log4NetLevel":"WARN ","HttpRequestId":"ff9dc8f3-5c25-473f-beb0-6d98cfcd2738","HttpRequestNumber":2,"HttpSessionId":"c0bc0b64-7860-6d12-898a-d9edc18dfac6"} {"@t":"2023-09-05T11:17:17.1719694Z","@mt":"Could not find a value for configuration field '{ConfigField}'","@l":"Warning","ConfigField":"enableDevMode","SourceContext":"Umbraco.Cms.Core.Models.Mapping.DataTypeMapDefinition","ActionId":"713d8c18-2791-4612-913c-3a322c63e99d","ActionName":"Umbraco.Cms.Web.BackOffice.Controllers.DataTypeController.GetPreValues (Umbraco.Web.BackOffice)","RequestId":"4000003f-0000-fb00-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/umbracoapi/datatype/GetPreValues","ProcessId":37940,"ProcessName":"iisexpress","ThreadId":39,"ApplicationId":"238a5a74592914da44b37cedb32e49e4652c4b8b","MachineName":"DESKTOP-L77LK1L","Log4NetLevel":"WARN ","HttpRequestId":"ff9dc8f3-5c25-473f-beb0-6d98cfcd2738","HttpRequestNumber":2,"HttpSessionId":"c0bc0b64-7860-6d12-898a-d9edc18dfac6"} {"@t":"2023-09-05T11:17:17.1719797Z","@mt":"Could not find a value for configuration field '{ConfigField}'","@l":"Warning","ConfigField":"preview","SourceContext":"Umbraco.Cms.Core.Models.Mapping.DataTypeMapDefinition","ActionId":"713d8c18-2791-4612-913c-3a322c63e99d","ActionName":"Umbraco.Cms.Web.BackOffice.Controllers.DataTypeController.GetPreValues (Umbraco.Web.BackOffice)","RequestId":"4000003f-0000-fb00-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/umbracoapi/datatype/GetPreValues","ProcessId":37940,"ProcessName":"iisexpress","ThreadId":39,"ApplicationId":"238a5a74592914da44b37cedb32e49e4652c4b8b","MachineName":"DESKTOP-L77LK1L","Log4NetLevel":"WARN ","HttpRequestId":"ff9dc8f3-5c25-473f-beb0-6d98cfcd2738","HttpRequestNumber":2,"HttpSessionId":"c0bc0b64-7860-6d12-898a-d9edc18dfac6"} {"@t":"2023-09-05T11:17:30.5018810Z","@mt":"The Delivery API is not enabled, no indexing will performed for the Delivery API content index.","SourceContext":"Umbraco.Cms.Infrastructure.Examine.DeliveryApiContentIndexPopulator","ProcessId":37940,"ProcessName":"iisexpress","ThreadId":6,"ApplicationId":"238a5a74592914da44b37cedb32e49e4652c4b8b","MachineName":"DESKTOP-L77LK1L","Log4NetLevel":"INFO "} ```
leekelleher commented 1 year ago

😕 I don't see anything related to Contentment specifically in the error messages, sorry.

I haven't experienced this error with the "umbraco-backoffice-extensions-js.s.map" file before, but did a quick google search and found this topic on the forum which may help? https://our.umbraco.com/forum/umbraco-9/106992-umbraco-9-usync-dashboard-not-loading-after-publish-to-server

leekelleher commented 1 year ago

@hoanganh9610 I'll close this off, as I don't think it's directly related to Contentment itself, e.g. it's not something I can bug fix and release a patch for. Hopefully, the forum post helped to resolve your issue?

If you do feel this is specific issue for Contentment itself, then please do feel free to re-open this ticket.