SchemaBuilder.CreateTable("SkillPartRecord", table => table .ContentPartRecord() .Column<string>("SkillName", c => c.NotNull()) .Column<int>("Knowledgment", c => c.NotNull().WithDefault(0)));
I did a lot of debugging with a collegue of mine that help me with Orchard (he has a more extensive experience that I have with Orchard).
So we have found the problem; specify this option in a string column seems to has somes problem with the NHibernate persistence, so the data is not saved
I will do other checks to be sure!
Added: I forgot, I talking about Orchard 1.4.2 with NHibernate v2.0.50727
You saved my day. NotNull is not working for ContentPartRecords, but it works perfectly for custom Records.
ReplyDelete