-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTableConfiguration.txt
More file actions
273 lines (174 loc) · 10.6 KB
/
TableConfiguration.txt
File metadata and controls
273 lines (174 loc) · 10.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
namespace Services.DPM.Project.Models.MethodologyTemplate.Calculations;
public class CalculationInputTableConfigModel
{
[JsonProperty("columns")] public List<Column> Columns { get; set; } = new();
[JsonProperty("disableAddNewRow")] public bool DisableAddNewRow { get; set; }
[JsonProperty("showFileUpload")] public bool ShowFileUpload { get; set; }
[JsonProperty("maxColumnCountInRow")] public int? MaxColumnCountInRow { get; set; }
[JsonProperty("disableExistingRowRemoval")]
public bool DisableExistingRowRemoval { get; set; }
[JsonProperty("hideHeader")] public bool HideHeader { get; set; }
[JsonProperty("addIdColumn")] public bool AddIdColumn { get; set; }
[JsonProperty("addTotalRow")] public bool AddTotalRow { get; set; }
[JsonProperty("allowCopyRow")] public bool AllowCopyRow { get; set; }
[JsonProperty("hideTableIfNoRowsFound")]
public bool HideTableIfNoRowsFound { get; set; }
[JsonProperty("addColumnDescription")] public bool AddColumnDescription { get; set; }
[JsonProperty("numberOfTotalRows")] public int NumberOfTotalRows { get; set; }
[JsonProperty("isCreditingPeriodTrigger")]
public bool IsCreditingPeriodTrigger { get; set; }
[JsonProperty("hasSubColumnsForAnyColumn")]
public bool HasSubColumnsForAnyColumn { get => Columns.Any(x => x.HasSubColumns); }
[JsonProperty("disablePasteAllOnColumnCopy")] public bool DisablePasteAllOnColumnCopy { get => Columns.Any(x => x.DisablePasteOnColumnCopy); }
[JsonProperty("conditionalRules")] public ConditionalRuleOption? ConditionalRules { get; set; }
[JsonProperty("disableScroll")] public bool DisableScroll { get; set; }
[JsonProperty("allowStickyHeader")] public bool AllowStickyHeader { get; set; }
}
public class Column
{
[JsonProperty("name")] public string Name { get; set; } = string.Empty;
[JsonProperty("columnHeading")] public string ColumnHeading { get; set; } = string.Empty;
[JsonProperty("columnDescription")] public string ColumnDescription { get; set; } = string.Empty;
[JsonProperty("placeholder")] public string Placeholder { get; set; } = string.Empty;
[JsonProperty("type")] public string Type { get; set; } = string.Empty;
[JsonProperty("controlType")] public string ControlType { get; set; } = string.Empty;
[JsonProperty("selectionOptions")] public List<SelectionOptionModel>? SelectionOptions { get; set; }
[JsonProperty("selectionOptionType")] public string? SelectionOptionType { get; set; }
[JsonProperty("nullable")] public bool Nullable { get; set; }
[JsonProperty("autoIncrement")] public bool AutoIncrement { get; set; }
[JsonProperty("disabled")] public bool Disabled { get; set; }
[JsonProperty("hideColumn")] public bool HideColumn { get; set; }
[JsonProperty("setDefaultAsNull")] public bool SetDefaultAsNull { get; set; }
[JsonProperty("addTotalColumn")] public bool AddTotalColumn { get; set; }
[JsonProperty("defaultValue")] public string DefaultValue { get; set; } = string.Empty;
[JsonProperty("configurations")] public CalculationInputColumnConfig? Configurations { get; set; }
[JsonProperty("helpText")] public string HelpText { get; set; } = string.Empty;
[JsonProperty("validationConfig")] public JsonSchemaValidation ValidationConfig { get; set; } = new();
[JsonProperty("isAfoluSpecific")] public bool IsAfoluSpecific { get; set; }
[JsonProperty("isNonAfoluSpecific")] public bool IsNonAfoluSpecific { get; set; }
[JsonProperty("allowCopyColumn")] public bool AllowCopyColumn { get; set; }
[JsonProperty("disablePasteOnColumnCopy")] public bool DisablePasteOnColumnCopy { get; set; }
[JsonProperty("disablePasteOnRowCopy")] public bool DisablePasteOnRowCopy { get; set; }
[JsonProperty("HasSubColumns")] public bool HasSubColumns { get => SubColumns != null && SubColumns.Any(); }
[JsonProperty("headerColSpan")] public int HeaderColSpan { get => SubColumns != null && SubColumns.Any() ? SubColumns.Count : 1; }
[JsonProperty("width")] public string Width { get; set; } = string.Empty;
[JsonProperty("subColumns")] public List<Column>? SubColumns { get; set; }
[JsonProperty("generateSubColumnsFromPath")] public string GenerateSubColumnsFromPath { get; set; } = string.Empty;
[JsonProperty("conditionalRules")] public ConditionalRuleOption? ConditionalRules { get; set; }
[JsonProperty("style")] public string Style { get; set; } = string.Empty;
[JsonProperty("rowSpan")] public int rowSpan { get; set; } = 1;
[JsonProperty("colSpan")] public int ColSpan { get; set; } = 1;
[JsonProperty("stickColumnWhenSplittingByRow")] public bool StickColumnWhenSplittingByRow { get; set; }
[JsonProperty("configuration")] public IDictionary<string, dynamic>? Configuration { get; set; }
[JsonProperty("requiredMessage")] public string RequiredMessage { get; set; } = string.Empty;
[JsonProperty("hideErrorMessage")] public bool HideErrorMessage { get; set; }
}
public class CalculationInputColumnConfig
{
[JsonProperty("columnHeadingForMonitoring")]
public string ColumnHeadingForMonitoring { get; set; } = string.Empty;
[JsonProperty("hideInProject")] public bool hideInProject { get; set; }
[JsonProperty("hideInMonitoringReport")]
public bool HideInMonitoringReport { get; set; }
[JsonProperty("hideInMethodologies")] public List<string>? HideInMethodologies { get; set; }
[JsonProperty("showInMethodologies")] public List<string>? ShowInMethodologies { get; set; }
[JsonProperty("hideInTemplateTypes")] public List<string>? HideInTemplateTypes { get; set; }
[JsonProperty("showOnlyInTemplateTypes")]
public List<string>? ShowOnlyInTemplateTypes { get; set; }
[JsonProperty("autofillFromColumnFromProject")] public string AutofillFromColumnFromProject { get; set; } = string.Empty;
[JsonProperty("minLength")] public int MinLength { get; set; }
[JsonProperty("maxLength")] public int MaxLength { get; set; }
[JsonProperty("noOfColSpanRowsFromLast")]
public int NoOfColSpanRowsFromLast { get; set; }
[JsonProperty("colSpan")] public int ColSpan { get; set; }
[JsonProperty("addColSpanToEndColumn")]
public bool AddColSpanToEndColumn { get; set; }
}
public class Equations
{
[JsonProperty("equation")]
public string Equation { get; set; } = string.Empty;
[JsonProperty("equationClause")]
public List<EquationClause>? EquationClauses { get; set; }
}
public class EquationClause
{
[JsonProperty("equationParam")]
public string EquationParam { get; set; } = string.Empty;
[JsonProperty("description")]
public string Description { get; set; } = string.Empty;
}
public class FileUploadModel
{
[JsonProperty("id")]
public int? Id { get; set; }
[JsonProperty("referenceId")]
public string? ReferenceId { get; set; }
[JsonProperty("name")]
public string? name { get; set; }
[JsonProperty("size")]
public long? size { get; set; }
[JsonProperty("extension")]
public string? Extension { get; set; }
}
<div class="col-md-6">
<label for="nullableSelect" class="form-label">Nullable</label>
<select id="nullableSelect" class="form-select" formControlName="Nullable">
<option [ngValue]="true">True</option>
<option [ngValue]="false">False</option>
</select>
</div>
<div class="col-12">
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="autoIncrement" />
<label class="form-check-label">Auto Increment</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="disabled" />
<label class="form-check-label">Disabled</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="hideColumn" />
<label class="form-check-label">Hide Column</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="setDefaultAsNull" />
<label class="form-check-label">Set Default as Null</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="addTotalColumn" />
<label class="form-check-label">Add Total Column</label>
</div>
<!-- <div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="validationConfig" />
<label class="form-check-label">Validation Config (Is Required)</label>
</div> -->
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="isAfoluSpecific" />
<label class="form-check-label">Is AFOLU Specific</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="isNonAfoluSpecific" />
<label class="form-check-label">Is Non-AFOLU Specific</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="allowCopyColumn" />
<label class="form-check-label">Allow Copy Column</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="disablePasteOnColumnCopy" />
<label class="form-check-label">Disable Paste on Column Copy</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="disablePasteOnRowCopy" />
<label class="form-check-label">Disable Paste on Row Copy</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="stickColumnWhenSplittingByRow" />
<label class="form-check-label">Stick Column When Splitting By Row</label>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" formControlName="hideErrorMessage" />
<label class="form-check-label">Hide Error Message</label>
</div>
</div>