Skip to content

Commit 18d41c3

Browse files
committed
refactor: 屏蔽 IsRequiredWhenAdd/IsRequiredWhenEdit 设置
1 parent 38f5241 commit 18d41c3

File tree

1 file changed

+3
-29
lines changed

1 file changed

+3
-29
lines changed

src/BootstrapBlazor/Attributes/AutoGenerateColumnAttribute.cs

Lines changed: 3 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -81,38 +81,12 @@ public class AutoGenerateColumnAttribute : AutoGenerateBaseAttribute, ITableColu
8181
set => IsVisibleWhenEdit = value ?? true;
8282
}
8383

84-
/// <summary>
85-
/// <inheritdoc/>
86-
/// </summary>
87-
public bool Required { get; set; }
84+
bool? IEditorItem.Required { get; set; }
8885

89-
bool? IEditorItem.Required
90-
{
91-
get => Required;
92-
set => Required = value ?? false;
93-
}
9486

95-
/// <summary>
96-
/// <inheritdoc/>
97-
/// </summary>
98-
public bool IsRequiredWhenAdd { get; set; }
87+
bool? ITableColumn.IsRequiredWhenAdd { get; set; }
9988

100-
bool? ITableColumn.IsRequiredWhenAdd
101-
{
102-
get => IsRequiredWhenAdd;
103-
set => IsRequiredWhenAdd = value ?? false;
104-
}
105-
106-
/// <summary>
107-
/// <inheritdoc/>
108-
/// </summary>
109-
public bool IsRequiredWhenEdit { get; set; }
110-
111-
bool? ITableColumn.IsRequiredWhenEdit
112-
{
113-
get => IsRequiredWhenEdit;
114-
set => IsRequiredWhenEdit = value ?? false;
115-
}
89+
bool? ITableColumn.IsRequiredWhenEdit { get; set; }
11690

11791
/// <summary>
11892
/// <inheritdoc/>

0 commit comments

Comments
 (0)