@seniorsistemas/angular-components 14.13.3 → 14.13.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/seniorsistemas-angular-components.umd.js +0 -41
- package/bundles/seniorsistemas-angular-components.umd.js.map +1 -1
- package/bundles/seniorsistemas-angular-components.umd.min.js +2 -2
- package/bundles/seniorsistemas-angular-components.umd.min.js.map +1 -1
- package/components/dynamic-form/components/lookup/lookup.component.d.ts +0 -2
- package/esm2015/components/dynamic-form/components/lookup/lookup.component.js +1 -43
- package/esm5/components/dynamic-form/components/lookup/lookup.component.js +1 -43
- package/fesm2015/seniorsistemas-angular-components.js +0 -41
- package/fesm2015/seniorsistemas-angular-components.js.map +1 -1
- package/fesm5/seniorsistemas-angular-components.js +0 -41
- package/fesm5/seniorsistemas-angular-components.js.map +1 -1
- package/package.json +1 -1
- package/seniorsistemas-angular-components.metadata.json +1 -1
|
@@ -2137,17 +2137,6 @@
|
|
|
2137
2137
|
this.searchFields = this.searchFields.map(function (value) { return new FormField(__assign(__assign({}, value), { size: { sm: 12, md: 12, lg: 12, xl: 12 } })); });
|
|
2138
2138
|
this.searchGridFields = (this.searchGridFields || this.searchFields).map(function (gridField) {
|
|
2139
2139
|
gridField["width"] = _this.getColWidth(gridField.label);
|
|
2140
|
-
var calendarOptions = gridField.calendarLocaleOptions;
|
|
2141
|
-
if (calendarOptions === null || calendarOptions === void 0 ? void 0 : calendarOptions.dateFormat) {
|
|
2142
|
-
switch (gridField.type) {
|
|
2143
|
-
case exports.FieldType.Date:
|
|
2144
|
-
calendarOptions.dateFormat = _this._convertToMomentDateFormat(calendarOptions.dateFormat);
|
|
2145
|
-
break;
|
|
2146
|
-
case exports.FieldType.Time:
|
|
2147
|
-
calendarOptions.dateFormat = _this._convertToMomentHourFormat(calendarOptions.hourFormat, calendarOptions.dateFormat);
|
|
2148
|
-
break;
|
|
2149
|
-
}
|
|
2150
|
-
}
|
|
2151
2140
|
return gridField;
|
|
2152
2141
|
});
|
|
2153
2142
|
var formGroup = this.searchFields.reduce(function (result, field) {
|
|
@@ -2173,36 +2162,6 @@
|
|
|
2173
2162
|
_this.onChange(newValue);
|
|
2174
2163
|
});
|
|
2175
2164
|
};
|
|
2176
|
-
LookupComponent.prototype._convertToMomentHourFormat = function (hourFormat, format) {
|
|
2177
|
-
if (format === "dd/mm/yy") { // valor padrão para o format.
|
|
2178
|
-
return "LTS";
|
|
2179
|
-
}
|
|
2180
|
-
if (hourFormat === "12") {
|
|
2181
|
-
return format
|
|
2182
|
-
.replace(/\bH\b/, "h") // hour (12 hour time) (no leading zero)
|
|
2183
|
-
.replace(/\bHH\b/, "hh"); // hour (12 hour time)
|
|
2184
|
-
}
|
|
2185
|
-
if (hourFormat === "24") {
|
|
2186
|
-
return format
|
|
2187
|
-
.replace(/\bh\b/, "H") // hour (24 hour time) (no leading zero)
|
|
2188
|
-
.replace(/\bhh\b/, "HH"); // hour (24 hour time)
|
|
2189
|
-
}
|
|
2190
|
-
return format;
|
|
2191
|
-
};
|
|
2192
|
-
LookupComponent.prototype._convertToMomentDateFormat = function (format) {
|
|
2193
|
-
// A ordem dos replaces é importante.
|
|
2194
|
-
return format
|
|
2195
|
-
.replace(/\bd\b/, "D") // day of month (no leading zero)
|
|
2196
|
-
.replace(/\bdd\b/, "DD") // day of month
|
|
2197
|
-
.replace(/\bo\b/, "DDD") // day of the year (no leading zero)
|
|
2198
|
-
.replace(/\boo\b/, "DDDD") // day of the year
|
|
2199
|
-
.replace(/\bM\b/, "MMM") // month name short
|
|
2200
|
-
.replace(/\bMM\b/, "MMMM") // month name long
|
|
2201
|
-
.replace(/\bm\b/, "M") // month of year (no leading)
|
|
2202
|
-
.replace(/\bmm\b/, "MM") // month of year
|
|
2203
|
-
.replace(/\by\b/, "YY") // year (two digits)
|
|
2204
|
-
.replace(/\byy\b/, "YYYY"); // year (four digits)
|
|
2205
|
-
};
|
|
2206
2165
|
LookupComponent.prototype.ngAfterViewInit = function () {
|
|
2207
2166
|
this.autocomplete.onOverlayAnimationDone = function (event) { };
|
|
2208
2167
|
};
|