<cite>JCompagnon: </cite> Hello @csbeginner,
Have you marked the .cshtml files as embedded resources in your assembly?
Hello. Yes I did. For all files
Some issue, Is there any update?
Configuration.EmbeddedResources.Sources.Add(
new EmbeddedResourceSet(
"/Areas/",
Assembly.GetExecutingAssembly(),
"ProjectTest.BlogService.Web.Areas"
)
);
ASPNET Zero 5.3
My project is MVC Core.
<a class="postlink" href="http://localhost:62114/App/BlogCategories">http://localhost:62114/App/BlogCategories</a> response this message:
An unhandled exception occurred while processing the request.
InvalidOperationException: The view 'Index' was not found. The following locations were searched:
/Areas/App/Views/BlogCategories/Index.cshtml
/Areas/App/Views/Shared/Index.cshtml
/Views/Shared/Index.cshtml
Microsoft.AspNetCore.Mvc.ViewEngines.ViewEngineResult.EnsureSuccessful(IEnumerable<string> originalLocations)
Hi, How you can mapping your entities from different assemblies? I have a entity in a class library named ShopModule with a entity named Customer. I want make OTO relation between Customers and AbpUser. A user can be a Customer that not required for all users. But a customer must be a User. I am a beginner and my attempt to create this relationship is confused cycle reference driving between assemblies.
If your rows is +1000 and you still want keep that, the best way for keeping that columns is changing "int" to "varchar" and use TypeConverter for new entries . You can create a excitation for that.
Hi I think you can create a Db backup and edit your query file then attach that again. Or use VS SQL Object Explorer right click on target table then click "View Code". Then change that column type. If your data is +1000 rows I'm not sure for this solution.
Hi.
<cite>alper: </cite> Is it Angular or MVC?
It's MVC. Navigation source place's is my wrong? I created this using ABP documents. I asked a question
<cite>csbeginner: </cite> Can I add a menu without permission required in the main menu? If yes what's my wrong?
but after waiting for 7 hours and refreshing topic page's I resolved a link not YES or NO.
[https://www.learnentityframeworkcore.com/configuration/fluent-api])
In version 2.0 onwards, this is accomplished by creating classes that implement IEntityTypeConfiguration<TEntity> and adding the fluent configuration code to a Configure method
<cite>alper: </cite> hi
maybe you should check this tutorial: <a class="postlink" href="https://www.tutorialspoint.com/entity_framework/entity_framework_fluent_api.htm">https://www.tutorialspoint.com/entity_f ... nt_api.htm</a>
and official Microsoft doc: <a class="postlink" href="https://msdn.microsoft.com/en-us/library/jj591617(v=vs.113">https://msdn.microsoft.com/en-us/librar ... 7(v=vs.113</a>).aspx
MSDN link is broken and first link tutorial is not covered by EF Core 2 because EF core 2 not generate join table. [https://github.com/aspnet/EntityFrameworkCore/issues/1368]) We need create that manually. Is can be hard for a project like eShop. Using fluent api in DbContext class's makes a ugly code if we have +10 tables. So what the best way?
Can I add a menu without permission required in the main menu? If yes whats my wrong?
CustomModuleNavigationProvider
public class CommerceServiceNavigationProvider : NavigationProvider
{
public override void SetNavigation(INavigationProviderContext context)
{
context.Manager.MainMenu
.AddItem(
new MenuItemDefinition(
PageNames.Commerce,
L("HomePage"),
url: "App/Commerce",
icon: "fa fa-home"
)
).AddItem(
new MenuItemDefinition(
PageNames.About,
L("About"),
url: "App/About",
icon: "fa fa-info"
)
);
}
private static ILocalizableString L(string name)
{
return new LocalizableString(name, CommerceServiceConsts.LocalizationSourceName);
}
}
CustomModuleWebModule
public class CommerceServiceWebModule : AbpModule
{
public override void PreInitialize()
{
Configuration.Navigation.Providers.Add<CommerceServiceNavigationProvider>();
Configuration.EmbeddedResources.Sources.Add(
new EmbeddedResourceSet(
"/Views/",
Assembly.GetExecutingAssembly(),
"CommerceService.Web.Views"
)
);
Configuration.Modules.AbpAspNetCore()
.CreateControllersForAppServices(
Assembly.GetExecutingAssembly()
);
}
public override void Initialize()
{
IocManager.RegisterAssemblyByConvention(typeof(CommerceServiceWebModule).GetAssembly());
}
}
Then I used [DependsOn(typeof(CommerceServiceWebModule)] attribute at MyAppWebCoreModule But nothing to show
[quote="alper"][list] Thank you for helpful links Is there any suggestion about fluent models builder? I think the Fluent API provider and interface's can be a good feature for ABP Framework. I don't know! Maybe I'm wrong