mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-08-24 21:24:42 +08:00
Id columns should not include WithLength() on Data Migration scaffoldin
--HG-- branch : dev
This commit is contained in:
parent
cfbea89449
commit
0cf950bc83
@ -22,7 +22,7 @@ namespace Orchard.DevTools.Services {
|
|||||||
var options = new List<string>();
|
var options = new List<string>();
|
||||||
|
|
||||||
if ( createColumn.IsPrimaryKey ) {
|
if ( createColumn.IsPrimaryKey ) {
|
||||||
options.Add(string.Format("WithLength({0})", createColumn.Length));
|
options.Add("PrimaryKey()");
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( createColumn.IsUnique ) {
|
if ( createColumn.IsUnique ) {
|
||||||
@ -33,10 +33,6 @@ namespace Orchard.DevTools.Services {
|
|||||||
options.Add("NotNull()");
|
options.Add("NotNull()");
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( createColumn.IsPrimaryKey ) {
|
|
||||||
options.Add("PrimaryKey()");
|
|
||||||
}
|
|
||||||
|
|
||||||
if ( createColumn.Length.HasValue ) {
|
if ( createColumn.Length.HasValue ) {
|
||||||
options.Add(string.Format("WithLength({0})", createColumn.Length ));
|
options.Add(string.Format("WithLength({0})", createColumn.Length ));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user