How I can extend Core Entity with the Help use of Plugin.
My Requirement is that : add a new field "InvoiceNumber" in Order table through Plugin, and when Customer will place an order, I can set the InvoiceNumber value through Plugin.
Getting Problem : unable to extend the Order through Plugin.
You cannot extend a core entity from a plugin. Read this thread for more information. What you can do is storing your extra order information on another table, with the orderId.
I added a field OrderItemStatusId to the OrderItem table in the database. But on run I've got an exception the model and database are different.
I tried to remove database and have it created by Nop installation. During the installation I've got an exception "The specified table does not exist. [ Store ]".
I've checked created database and found out there are no tables at all. So that makes me think during database creation no tables were added at all due to some my code induced error, which was silently ignored.
Is there anyway to override a property that has .HasPrecision(18, 4)? I tried the method in this post and it doesn't seem to work.
We are trying to increase the number of decimal spots on Tier pricing from 4 to 6 decimals. I have created a Plugin that does this and all works except when using the admin console to add/update a TierPrice. When saved it only saves 4 decimals.
I created a custom folder in Nop.Data and created the below class to try to override the precision
My plugin changes the Precision in the Database and updates the precision in the EditorTemplates. If i remove the .HasPrecision(18, 4) from this.Property(tp => tp.Price) in \Nop.Data\Mapping\Catalog\TierPriceMap.cs. Everything seems to work. We would like to figure out a way to override properties that have HasPrecision set outside of modify the NopCore code.