gunsmith-common 2.3.13 → 2.3.14
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/esm2020/public_api.mjs +1 -2
- package/esm2020/shared/services/finish-date-helper.service.mjs +7 -9
- package/esm2020/shared/shared.module.mjs +1 -6
- package/fesm2015/gunsmith-common.mjs +24 -216
- package/fesm2015/gunsmith-common.mjs.map +1 -1
- package/fesm2020/gunsmith-common.mjs +15 -203
- package/fesm2020/gunsmith-common.mjs.map +1 -1
- package/gunsmith-common-2.3.14.tgz +0 -0
- package/package.json +1 -1
- package/public_api.d.ts +0 -1
- package/shared/services/finish-date-helper.service.d.ts +2 -1
- package/shared/shared.module.d.ts +6 -7
- package/esm2020/shared/controls/package-selector/package-selector.component.mjs +0 -190
- package/gunsmith-common-2.3.13.tgz +0 -0
- package/shared/controls/package-selector/package-selector.component.d.ts +0 -42
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, Inject, Pipe, Directive, Input, Component, EventEmitter, Output, NgModule } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common/http';
|
|
4
|
-
import { of, switchMap as switchMap$1,
|
|
4
|
+
import { of, switchMap as switchMap$1, EMPTY, forkJoin, Subject } from 'rxjs';
|
|
5
5
|
import { switchMap } from 'rxjs/operators';
|
|
6
6
|
import { DateTime } from 'luxon';
|
|
7
|
-
import * as
|
|
8
|
-
import {
|
|
9
|
-
import * as
|
|
10
|
-
import { DropDownsModule } from '@progress/kendo-angular-dropdowns';
|
|
11
|
-
import * as i2$1 from '@angular/common';
|
|
7
|
+
import * as i1$1 from '@angular/forms';
|
|
8
|
+
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
9
|
+
import * as i2 from '@angular/common';
|
|
12
10
|
import { CommonModule } from '@angular/common';
|
|
11
|
+
import { DropDownsModule } from '@progress/kendo-angular-dropdowns';
|
|
13
12
|
import { trigger, transition, style, animate } from '@angular/animations';
|
|
14
13
|
|
|
15
14
|
function touchControls(formGroup) {
|
|
@@ -1971,23 +1970,21 @@ class FinishDateHelperService {
|
|
|
1971
1970
|
}
|
|
1972
1971
|
return this.adjustHoliday(finishDate.toJSDate());
|
|
1973
1972
|
}
|
|
1974
|
-
|
|
1973
|
+
calculate(receivedDate, workOrderType) {
|
|
1975
1974
|
if (!receivedDate) {
|
|
1976
|
-
return
|
|
1975
|
+
return EMPTY;
|
|
1977
1976
|
}
|
|
1978
1977
|
if (!this.configs) {
|
|
1979
|
-
return
|
|
1978
|
+
return forkJoin([
|
|
1980
1979
|
this.configService.readConfigs(),
|
|
1981
1980
|
this.holidayService.readHolidays(),
|
|
1982
1981
|
]).pipe(switchMap$1(([configs, holidays]) => {
|
|
1983
1982
|
this.configs = configs;
|
|
1984
1983
|
this.holidays = holidays;
|
|
1985
1984
|
return of(this.calculateFinishDate(receivedDate, workOrderType));
|
|
1986
|
-
}))
|
|
1985
|
+
}));
|
|
1987
1986
|
}
|
|
1988
|
-
return
|
|
1989
|
-
resolve(this.calculateFinishDate(receivedDate, workOrderType));
|
|
1990
|
-
});
|
|
1987
|
+
return of(this.calculateFinishDate(receivedDate, workOrderType));
|
|
1991
1988
|
}
|
|
1992
1989
|
}
|
|
1993
1990
|
FinishDateHelperService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: FinishDateHelperService, deps: [{ token: ConfigurationService }, { token: WorkHolidayService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
@@ -2129,14 +2126,14 @@ class DisableControlDirective {
|
|
|
2129
2126
|
this.ngControl.control[action]();
|
|
2130
2127
|
}
|
|
2131
2128
|
}
|
|
2132
|
-
DisableControlDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: DisableControlDirective, deps: [{ token:
|
|
2129
|
+
DisableControlDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: DisableControlDirective, deps: [{ token: i1$1.NgControl }], target: i0.ɵɵFactoryTarget.Directive });
|
|
2133
2130
|
DisableControlDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.11", type: DisableControlDirective, selector: "[disableControl]", inputs: { disableControl: "disableControl" }, ngImport: i0 });
|
|
2134
2131
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: DisableControlDirective, decorators: [{
|
|
2135
2132
|
type: Directive,
|
|
2136
2133
|
args: [{
|
|
2137
2134
|
selector: '[disableControl]'
|
|
2138
2135
|
}]
|
|
2139
|
-
}], ctorParameters: function () { return [{ type:
|
|
2136
|
+
}], ctorParameters: function () { return [{ type: i1$1.NgControl }]; }, propDecorators: { disableControl: [{
|
|
2140
2137
|
type: Input
|
|
2141
2138
|
}] } });
|
|
2142
2139
|
|
|
@@ -2185,191 +2182,10 @@ function refinishDetailsValidator() {
|
|
|
2185
2182
|
};
|
|
2186
2183
|
}
|
|
2187
2184
|
|
|
2188
|
-
class PackageSelectorComponent {
|
|
2189
|
-
constructor(packageService, fb, inj) {
|
|
2190
|
-
this.packageService = packageService;
|
|
2191
|
-
this.fb = fb;
|
|
2192
|
-
this.inj = inj;
|
|
2193
|
-
this.gunsmithOnly = false;
|
|
2194
|
-
this.packages = [];
|
|
2195
|
-
this.packageVariations = [];
|
|
2196
|
-
this.packageOptionalItems = [];
|
|
2197
|
-
this.onChangeSubs = [];
|
|
2198
|
-
this.onTouched = () => { };
|
|
2199
|
-
this.touched = false;
|
|
2200
|
-
this.disabled = false;
|
|
2201
|
-
this.createForm();
|
|
2202
|
-
}
|
|
2203
|
-
ngOnChanges(changes) {
|
|
2204
|
-
if (this.canGetPackages(changes)) {
|
|
2205
|
-
this.getPackages();
|
|
2206
|
-
this.packageForm.reset();
|
|
2207
|
-
}
|
|
2208
|
-
else {
|
|
2209
|
-
this.packages = [];
|
|
2210
|
-
this.packageForm.reset();
|
|
2211
|
-
}
|
|
2212
|
-
}
|
|
2213
|
-
canGetPackages(changes) {
|
|
2214
|
-
return (changes.firearmId && changes.firearmId.currentValue && this.projectType === ProjectType.Firearm && (this.workOrderType == WorkOrderType.Standard || this.workOrderType == WorkOrderType.NewInBox)) ||
|
|
2215
|
-
(changes.projectType && changes.projectType.currentValue === ProjectType.Firearm && this.firearmId && (this.workOrderType == WorkOrderType.Standard || this.workOrderType == WorkOrderType.NewInBox)) ||
|
|
2216
|
-
(changes.workOrderType && (changes.workOrderType.currentValue === WorkOrderType.Standard || changes.workOrderType.currentValue === WorkOrderType.NewInBox) && this.firearmId && this.projectType === ProjectType.Firearm);
|
|
2217
|
-
}
|
|
2218
|
-
ngAfterViewInit() {
|
|
2219
|
-
const outerControl = this.inj.get(NgControl).control;
|
|
2220
|
-
const prevMarkAsTouched = outerControl.markAsTouched;
|
|
2221
|
-
outerControl.markAsTouched = (...args) => {
|
|
2222
|
-
this.packageForm.markAllAsTouched();
|
|
2223
|
-
prevMarkAsTouched.bind(outerControl)(...args);
|
|
2224
|
-
};
|
|
2225
|
-
}
|
|
2226
|
-
ngOnDestroy() {
|
|
2227
|
-
for (let sub of this.onChangeSubs) {
|
|
2228
|
-
sub.unsubscribe();
|
|
2229
|
-
}
|
|
2230
|
-
}
|
|
2231
|
-
getPackages() {
|
|
2232
|
-
this.packageService.readPackagesByFirearm(this.firearmId, this.gunsmithOnly)
|
|
2233
|
-
.subscribe(packages => {
|
|
2234
|
-
this.packages = packages;
|
|
2235
|
-
if (this.packageForm.controls.package.value) {
|
|
2236
|
-
let packagez = this.packages.find(p => p.id === this.packageForm.controls.package.value.id);
|
|
2237
|
-
this.setPackageOptions(packagez);
|
|
2238
|
-
}
|
|
2239
|
-
});
|
|
2240
|
-
}
|
|
2241
|
-
createForm() {
|
|
2242
|
-
this.packageForm = this.fb.group({
|
|
2243
|
-
package: null,
|
|
2244
|
-
optionalItems: this.fb.control([]),
|
|
2245
|
-
variations: this.fb.array([])
|
|
2246
|
-
});
|
|
2247
|
-
this.packageForm.controls.variations.valueChanges
|
|
2248
|
-
.subscribe(value => {
|
|
2249
|
-
if (value) {
|
|
2250
|
-
this.packageForm.controls.variations.setValue(value.map(v => v?.id ? v : null), { emitEvent: false });
|
|
2251
|
-
}
|
|
2252
|
-
});
|
|
2253
|
-
this.packageForm.controls.package.valueChanges
|
|
2254
|
-
.subscribe(value => {
|
|
2255
|
-
this.packageForm.controls.optionalItems.reset();
|
|
2256
|
-
this.packageOptionalItems = [];
|
|
2257
|
-
this.variations.clear({ emitEvent: false });
|
|
2258
|
-
this.packageVariations = [];
|
|
2259
|
-
if (value?.id) {
|
|
2260
|
-
this.setPackageOptions(value);
|
|
2261
|
-
}
|
|
2262
|
-
else {
|
|
2263
|
-
if (this.packageDetail) {
|
|
2264
|
-
this.packageDetail.variations = null;
|
|
2265
|
-
this.packageDetail.optionalItems = null;
|
|
2266
|
-
}
|
|
2267
|
-
}
|
|
2268
|
-
});
|
|
2269
|
-
}
|
|
2270
|
-
get variations() { return this.packageForm.controls.variations; }
|
|
2271
|
-
setPackageOptions(packagez) {
|
|
2272
|
-
this.packageOptionalItems = packagez.optionalItems;
|
|
2273
|
-
this.packageVariations = this.gunsmithOnly ? packagez.variations : packagez.variations.filter(v => !v.gunsmithOnly);
|
|
2274
|
-
this.variations.clear({ emitEvent: false });
|
|
2275
|
-
for (let v of this.packageVariations) {
|
|
2276
|
-
let selectedVariation = this.packageDetail?.variations?.find(pv => pv.packageVariationId === v.id);
|
|
2277
|
-
if (v.gunsmithOnly)
|
|
2278
|
-
this.variations.push(this.fb.control(selectedVariation), { emitEvent: false });
|
|
2279
|
-
else
|
|
2280
|
-
this.variations.push(this.fb.control(selectedVariation, Validators.required), { emitEvent: false });
|
|
2281
|
-
}
|
|
2282
|
-
}
|
|
2283
|
-
setValue(packageDetail) {
|
|
2284
|
-
this.packageForm.reset(packageDetail);
|
|
2285
|
-
}
|
|
2286
|
-
validate(control) {
|
|
2287
|
-
if (this.packageForm.valid) {
|
|
2288
|
-
return null;
|
|
2289
|
-
}
|
|
2290
|
-
let errors = {};
|
|
2291
|
-
for (let v of this.variations.controls) {
|
|
2292
|
-
if (v.invalid) {
|
|
2293
|
-
return v.errors;
|
|
2294
|
-
}
|
|
2295
|
-
}
|
|
2296
|
-
return errors;
|
|
2297
|
-
}
|
|
2298
|
-
addControlErrors(allErrors, controlName) {
|
|
2299
|
-
const errors = { ...allErrors };
|
|
2300
|
-
const controlErrors = this.packageForm.controls[controlName].errors;
|
|
2301
|
-
if (controlErrors) {
|
|
2302
|
-
errors[controlName] = controlErrors;
|
|
2303
|
-
}
|
|
2304
|
-
return errors;
|
|
2305
|
-
}
|
|
2306
|
-
writeValue(packageDetail) {
|
|
2307
|
-
if (packageDetail) {
|
|
2308
|
-
this.packageDetail = Object.assign({}, packageDetail);
|
|
2309
|
-
this.setValue(packageDetail);
|
|
2310
|
-
}
|
|
2311
|
-
else {
|
|
2312
|
-
this.packageForm.reset();
|
|
2313
|
-
}
|
|
2314
|
-
}
|
|
2315
|
-
registerOnChange(onChange) {
|
|
2316
|
-
const sub = this.packageForm.valueChanges.subscribe(onChange);
|
|
2317
|
-
this.onChangeSubs.push(sub);
|
|
2318
|
-
}
|
|
2319
|
-
registerOnTouched(onTouched) {
|
|
2320
|
-
this.onTouched = onTouched;
|
|
2321
|
-
}
|
|
2322
|
-
setDisabledState(isDisabled) {
|
|
2323
|
-
this.disabled = isDisabled;
|
|
2324
|
-
if (isDisabled) {
|
|
2325
|
-
this.packageForm.disable();
|
|
2326
|
-
}
|
|
2327
|
-
else {
|
|
2328
|
-
this.packageForm.enable();
|
|
2329
|
-
}
|
|
2330
|
-
}
|
|
2331
|
-
}
|
|
2332
|
-
PackageSelectorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: PackageSelectorComponent, deps: [{ token: PackageService }, { token: i2.FormBuilder }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
2333
|
-
PackageSelectorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: PackageSelectorComponent, selector: "cgw-package-selector", inputs: { firearmId: "firearmId", projectType: "projectType", workOrderType: "workOrderType", gunsmithOnly: "gunsmithOnly" }, providers: [
|
|
2334
|
-
{
|
|
2335
|
-
provide: NG_VALUE_ACCESSOR,
|
|
2336
|
-
multi: true,
|
|
2337
|
-
useExisting: PackageSelectorComponent
|
|
2338
|
-
},
|
|
2339
|
-
{
|
|
2340
|
-
provide: NG_VALIDATORS,
|
|
2341
|
-
multi: true,
|
|
2342
|
-
useExisting: PackageSelectorComponent
|
|
2343
|
-
}
|
|
2344
|
-
], usesOnChanges: true, ngImport: i0, template: "<div [formGroup]=\"packageForm\">\n <div class=\"row mb-2\">\n <div class=\"col\">\n <label for=\"waitlist-gun-package\">Package</label>\n <kendo-dropdownlist [data]=\"packages\"\n [defaultItem]=\"{name: 'No Package', id: null}\"\n id=\"waitlist-gun-package\"\n formControlName=\"package\"\n textField=\"name\"\n valueField=\"id\"\n size=\"small\"></kendo-dropdownlist>\n </div>\n </div>\n <div formArrayName=\"variations\" *ngFor=\"let variationControl of variations.controls; let i = index\">\n <div class=\"row mb-2\">\n <div class=\"col\">\n <label [for]=\"'waitlist-gun-package-variation-' + i\">{{packageVariations[i]?.name}}</label>\n <kendo-dropdownlist [data]=\"packageVariations[i]?.options\"\n [id]=\"'waitlist-gun-package-variation-' + i\"\n [defaultItem]=\"{optionName: '', id: null}\"\n textField=\"optionName\"\n [formControl]=\"variationControl\"\n valueField=\"id\"\n size=\"small\" *ngIf=\"packageVariations[i]?.gunsmithOnly\">\n <ng-template kendoDropDownListItemTemplate let-dataItem>\n <span class=\"fw-bold\">{{ dataItem?.sku }}</span> - {{ dataItem?.optionName }} <span *ngIf=\"dataItem?.serviceChargeItemPrice\">(add ${{dataItem.serviceChargeItemPrice.toFixed(2)}})</span>\n </ng-template>\n </kendo-dropdownlist>\n <kendo-dropdownlist [data]=\"packageVariations[i]?.options\"\n [id]=\"'waitlist-gun-package-variation-' + i\"\n textField=\"optionName\"\n [formControl]=\"variationControl\"\n valueField=\"id\"\n size=\"small\" *ngIf=\"!packageVariations[i]?.gunsmithOnly\">\n <ng-template kendoDropDownListItemTemplate let-dataItem>\n <span class=\"fw-bold\">{{ dataItem?.sku }}</span> - {{ dataItem?.optionName }} <span *ngIf=\"dataItem?.serviceChargeItemPrice\">(add ${{dataItem.serviceChargeItemPrice.toFixed(2)}})</span>\n </ng-template>\n </kendo-dropdownlist>\n </div>\n </div>\n <div *ngIf=\"variationControl.invalid && (variationControl.dirty || variationControl.touched)\" class=\"error-container text-danger\">\n <div *ngIf=\"variationControl.errors.required\">\n {{packageVariations[i]?.name}} is required.\n </div>\n </div>\n </div>\n <div class=\"row mb-2\" *ngIf=\"packageOptionalItems?.length\">\n <div class=\"col\">\n <label for=\"waitlist-gun-package-addons\">Add-ons (Additional charges will apply)</label>\n <kendo-multiselect id=\"waitlist-gun-package-addons\"\n [data]=\"packageOptionalItems\"\n formControlName=\"optionalItems\"\n textField=\"name\"\n valueField=\"id\"\n size=\"small\">\n <ng-template kendoMultiSelectItemTemplate let-dataItem>\n <span class=\"fw-bold\">{{ dataItem?.sku }}</span> - {{ dataItem?.name }}\n </ng-template>\n </kendo-multiselect>\n </div>\n </div>\n</div>\n", styles: [""], components: [{ type: i3.DropDownListComponent, selector: "kendo-dropdownlist", inputs: ["iconClass", "loading", "data", "value", "textField", "valueField", "popupSettings", "listHeight", "defaultItem", "disabled", "itemDisabled", "readonly", "filterable", "virtual", "ignoreCase", "delay", "valuePrimitive", "tabindex", "tabIndex", "size", "rounded", "fillMode", "id"], outputs: ["valueChange", "filterChange", "selectionChange", "open", "opened", "close", "closed", "focus", "blur"], exportAs: ["kendoDropDownList"] }, { type: i3.MultiSelectComponent, selector: "kendo-multiselect", inputs: ["focusableId", "autoClose", "loading", "data", "value", "valueField", "textField", "tabindex", "tabIndex", "size", "rounded", "fillMode", "placeholder", "disabled", "itemDisabled", "checkboxes", "readonly", "filterable", "virtual", "popupSettings", "listHeight", "valuePrimitive", "clearButton", "tagMapper", "allowCustom", "valueNormalizer"], outputs: ["filterChange", "valueChange", "open", "opened", "close", "closed", "focus", "blur", "removeTag"], exportAs: ["kendoMultiSelect"] }], directives: [{ type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { type: i2$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2.FormArrayName, selector: "[formArrayName]", inputs: ["formArrayName"] }, { type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i3.ItemTemplateDirective, selector: "[kendoDropDownListItemTemplate],[kendoComboBoxItemTemplate],[kendoAutoCompleteItemTemplate],[kendoMultiSelectItemTemplate]" }] });
|
|
2345
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: PackageSelectorComponent, decorators: [{
|
|
2346
|
-
type: Component,
|
|
2347
|
-
args: [{ selector: 'cgw-package-selector', providers: [
|
|
2348
|
-
{
|
|
2349
|
-
provide: NG_VALUE_ACCESSOR,
|
|
2350
|
-
multi: true,
|
|
2351
|
-
useExisting: PackageSelectorComponent
|
|
2352
|
-
},
|
|
2353
|
-
{
|
|
2354
|
-
provide: NG_VALIDATORS,
|
|
2355
|
-
multi: true,
|
|
2356
|
-
useExisting: PackageSelectorComponent
|
|
2357
|
-
}
|
|
2358
|
-
], template: "<div [formGroup]=\"packageForm\">\n <div class=\"row mb-2\">\n <div class=\"col\">\n <label for=\"waitlist-gun-package\">Package</label>\n <kendo-dropdownlist [data]=\"packages\"\n [defaultItem]=\"{name: 'No Package', id: null}\"\n id=\"waitlist-gun-package\"\n formControlName=\"package\"\n textField=\"name\"\n valueField=\"id\"\n size=\"small\"></kendo-dropdownlist>\n </div>\n </div>\n <div formArrayName=\"variations\" *ngFor=\"let variationControl of variations.controls; let i = index\">\n <div class=\"row mb-2\">\n <div class=\"col\">\n <label [for]=\"'waitlist-gun-package-variation-' + i\">{{packageVariations[i]?.name}}</label>\n <kendo-dropdownlist [data]=\"packageVariations[i]?.options\"\n [id]=\"'waitlist-gun-package-variation-' + i\"\n [defaultItem]=\"{optionName: '', id: null}\"\n textField=\"optionName\"\n [formControl]=\"variationControl\"\n valueField=\"id\"\n size=\"small\" *ngIf=\"packageVariations[i]?.gunsmithOnly\">\n <ng-template kendoDropDownListItemTemplate let-dataItem>\n <span class=\"fw-bold\">{{ dataItem?.sku }}</span> - {{ dataItem?.optionName }} <span *ngIf=\"dataItem?.serviceChargeItemPrice\">(add ${{dataItem.serviceChargeItemPrice.toFixed(2)}})</span>\n </ng-template>\n </kendo-dropdownlist>\n <kendo-dropdownlist [data]=\"packageVariations[i]?.options\"\n [id]=\"'waitlist-gun-package-variation-' + i\"\n textField=\"optionName\"\n [formControl]=\"variationControl\"\n valueField=\"id\"\n size=\"small\" *ngIf=\"!packageVariations[i]?.gunsmithOnly\">\n <ng-template kendoDropDownListItemTemplate let-dataItem>\n <span class=\"fw-bold\">{{ dataItem?.sku }}</span> - {{ dataItem?.optionName }} <span *ngIf=\"dataItem?.serviceChargeItemPrice\">(add ${{dataItem.serviceChargeItemPrice.toFixed(2)}})</span>\n </ng-template>\n </kendo-dropdownlist>\n </div>\n </div>\n <div *ngIf=\"variationControl.invalid && (variationControl.dirty || variationControl.touched)\" class=\"error-container text-danger\">\n <div *ngIf=\"variationControl.errors.required\">\n {{packageVariations[i]?.name}} is required.\n </div>\n </div>\n </div>\n <div class=\"row mb-2\" *ngIf=\"packageOptionalItems?.length\">\n <div class=\"col\">\n <label for=\"waitlist-gun-package-addons\">Add-ons (Additional charges will apply)</label>\n <kendo-multiselect id=\"waitlist-gun-package-addons\"\n [data]=\"packageOptionalItems\"\n formControlName=\"optionalItems\"\n textField=\"name\"\n valueField=\"id\"\n size=\"small\">\n <ng-template kendoMultiSelectItemTemplate let-dataItem>\n <span class=\"fw-bold\">{{ dataItem?.sku }}</span> - {{ dataItem?.name }}\n </ng-template>\n </kendo-multiselect>\n </div>\n </div>\n</div>\n", styles: [""] }]
|
|
2359
|
-
}], ctorParameters: function () { return [{ type: PackageService }, { type: i2.FormBuilder }, { type: i0.Injector }]; }, propDecorators: { firearmId: [{
|
|
2360
|
-
type: Input
|
|
2361
|
-
}], projectType: [{
|
|
2362
|
-
type: Input
|
|
2363
|
-
}], workOrderType: [{
|
|
2364
|
-
type: Input
|
|
2365
|
-
}], gunsmithOnly: [{
|
|
2366
|
-
type: Input
|
|
2367
|
-
}] } });
|
|
2368
|
-
|
|
2369
2185
|
class FormErrorMessageComponent {
|
|
2370
2186
|
}
|
|
2371
2187
|
FormErrorMessageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: FormErrorMessageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2372
|
-
FormErrorMessageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: FormErrorMessageComponent, selector: "cgw-error-message", inputs: { control: "control", controlName: "controlName" }, ngImport: i0, template: "<div *ngIf=\"control.invalid && (control.dirty || control.touched)\" class=\"error-container text-danger\">\n <div *ngIf=\"control.errors.required\">\n {{controlName}} is required.\n </div>\n</div>\n", styles: [""], directives: [{ type: i2
|
|
2188
|
+
FormErrorMessageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: FormErrorMessageComponent, selector: "cgw-error-message", inputs: { control: "control", controlName: "controlName" }, ngImport: i0, template: "<div *ngIf=\"control.invalid && (control.dirty || control.touched)\" class=\"error-container text-danger\">\n <div *ngIf=\"control.errors.required\">\n {{controlName}} is required.\n </div>\n</div>\n", styles: [""], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
2373
2189
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: FormErrorMessageComponent, decorators: [{
|
|
2374
2190
|
type: Component,
|
|
2375
2191
|
args: [{ selector: 'cgw-error-message', template: "<div *ngIf=\"control.invalid && (control.dirty || control.touched)\" class=\"error-container text-danger\">\n <div *ngIf=\"control.errors.required\">\n {{controlName}} is required.\n </div>\n</div>\n", styles: [""] }]
|
|
@@ -2410,7 +2226,6 @@ SharedModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "
|
|
|
2410
2226
|
DisableControlDirective,
|
|
2411
2227
|
NewLinePipe,
|
|
2412
2228
|
FrameMaterialPipe,
|
|
2413
|
-
PackageSelectorComponent,
|
|
2414
2229
|
FormErrorMessageComponent,
|
|
2415
2230
|
ModalHeaderComponent], imports: [CommonModule, DropDownsModule, FormsModule, ReactiveFormsModule], exports: [PhonePipe,
|
|
2416
2231
|
FileNamePipe,
|
|
@@ -2418,7 +2233,6 @@ SharedModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "
|
|
|
2418
2233
|
NewLinePipe,
|
|
2419
2234
|
DisableControlDirective,
|
|
2420
2235
|
FrameMaterialPipe,
|
|
2421
|
-
PackageSelectorComponent,
|
|
2422
2236
|
FormErrorMessageComponent,
|
|
2423
2237
|
ModalHeaderComponent] });
|
|
2424
2238
|
SharedModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: SharedModule, imports: [[CommonModule, DropDownsModule, FormsModule, ReactiveFormsModule]] });
|
|
@@ -2432,7 +2246,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
2432
2246
|
DisableControlDirective,
|
|
2433
2247
|
NewLinePipe,
|
|
2434
2248
|
FrameMaterialPipe,
|
|
2435
|
-
PackageSelectorComponent,
|
|
2436
2249
|
FormErrorMessageComponent,
|
|
2437
2250
|
ModalHeaderComponent
|
|
2438
2251
|
],
|
|
@@ -2444,7 +2257,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
2444
2257
|
NewLinePipe,
|
|
2445
2258
|
DisableControlDirective,
|
|
2446
2259
|
FrameMaterialPipe,
|
|
2447
|
-
PackageSelectorComponent,
|
|
2448
2260
|
FormErrorMessageComponent,
|
|
2449
2261
|
ModalHeaderComponent
|
|
2450
2262
|
],
|
|
@@ -2509,7 +2321,7 @@ class NotificationBarComponent {
|
|
|
2509
2321
|
}
|
|
2510
2322
|
}
|
|
2511
2323
|
NotificationBarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: NotificationBarComponent, deps: [{ token: NotificationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2512
|
-
NotificationBarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: NotificationBarComponent, selector: "app-notification-bar", ngImport: i0, template: "<div class=\"notification-bar\" *ngIf=\"messages.length\">\n <div *ngFor=\"let message of viewMessages\" class=\"notification-pill\" [class.error]=\"message.type == 1\" [@fadeOutAnimation]=\"shouldFade()\">\n <i class=\"fa\" [ngClass]=\"getIconClass(message)\"></i> <span class=\"ms-1\">{{message.message}}</span>\n </div>\n <div *ngIf=\"messages.length > 3\" class=\"notification-pill\">{{messages.length - 2}} more...</div>\n</div>\n", styles: [".notification-bar{position:fixed;top:0;left:0;right:0;z-index:1000001;pointer-events:none}.notification-bar .notification-pill{max-width:300px;margin:10px auto;border-radius:4px;color:#000;background:#181818;padding:8px;text-align:center;color:#fff}.notification-bar .error{color:#711e16!important;background:#f8d8d4!important}\n"], directives: [{ type: i2
|
|
2324
|
+
NotificationBarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.11", type: NotificationBarComponent, selector: "app-notification-bar", ngImport: i0, template: "<div class=\"notification-bar\" *ngIf=\"messages.length\">\n <div *ngFor=\"let message of viewMessages\" class=\"notification-pill\" [class.error]=\"message.type == 1\" [@fadeOutAnimation]=\"shouldFade()\">\n <i class=\"fa\" [ngClass]=\"getIconClass(message)\"></i> <span class=\"ms-1\">{{message.message}}</span>\n </div>\n <div *ngIf=\"messages.length > 3\" class=\"notification-pill\">{{messages.length - 2}} more...</div>\n</div>\n", styles: [".notification-bar{position:fixed;top:0;left:0;right:0;z-index:1000001;pointer-events:none}.notification-bar .notification-pill{max-width:300px;margin:10px auto;border-radius:4px;color:#000;background:#181818;padding:8px;text-align:center;color:#fff}.notification-bar .error{color:#711e16!important;background:#f8d8d4!important}\n"], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], animations: [fadeOutAnimation] });
|
|
2513
2325
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: NotificationBarComponent, decorators: [{
|
|
2514
2326
|
type: Component,
|
|
2515
2327
|
args: [{ selector: 'app-notification-bar', animations: [fadeOutAnimation], template: "<div class=\"notification-bar\" *ngIf=\"messages.length\">\n <div *ngFor=\"let message of viewMessages\" class=\"notification-pill\" [class.error]=\"message.type == 1\" [@fadeOutAnimation]=\"shouldFade()\">\n <i class=\"fa\" [ngClass]=\"getIconClass(message)\"></i> <span class=\"ms-1\">{{message.message}}</span>\n </div>\n <div *ngIf=\"messages.length > 3\" class=\"notification-pill\">{{messages.length - 2}} more...</div>\n</div>\n", styles: [".notification-bar{position:fixed;top:0;left:0;right:0;z-index:1000001;pointer-events:none}.notification-bar .notification-pill{max-width:300px;margin:10px auto;border-radius:4px;color:#000;background:#181818;padding:8px;text-align:center;color:#fff}.notification-bar .error{color:#711e16!important;background:#f8d8d4!important}\n"] }]
|
|
@@ -2551,5 +2363,5 @@ var NotificationType;
|
|
|
2551
2363
|
* Generated bundle index. Do not edit.
|
|
2552
2364
|
*/
|
|
2553
2365
|
|
|
2554
|
-
export { Address, BaseService, BillingInfo, BundleItem, ChangeOrderPackageDetail, ChangeOrderStatus, Coating, CoatingService, CoatingValue, CoatingValueService, Configuration, ConfigurationService, Customer, CustomerService, Dealer, DealerContact, DealerCoupon, DealerService, DisableControlDirective, EnumPipe, FileNamePipe, FileUploadService, FilterOptions, FinishDateHelperService, Firearm, FirearmMillingTypeService, FirearmOptic, FirearmOpticService, FirearmService, FirearmSightService, FormErrorMessageComponent, FrameMaterial, FrameMaterialPipe, GunCaliber, GunPart, GunPartOption, GunPartService, InventoryItem, InventoryService, JFile, Material, MaterialService, MillingDetail, MillingItem, MillingType, MillingTypeAddon, MillingTypeAddonOption, MillingTypeAddonService, MillingTypeService, ModalHeaderComponent, MountType, MountTypeService, NewLinePipe, NotificationBarComponent, NotificationModule, NotificationService, NotificationType, Optic, OpticService, OpticSight, OpticStatus, Package, PackageItem, PackageOptionalItem, PackageOptionalItemService,
|
|
2366
|
+
export { Address, BaseService, BillingInfo, BundleItem, ChangeOrderPackageDetail, ChangeOrderStatus, Coating, CoatingService, CoatingValue, CoatingValueService, Configuration, ConfigurationService, Customer, CustomerService, Dealer, DealerContact, DealerCoupon, DealerService, DisableControlDirective, EnumPipe, FileNamePipe, FileUploadService, FilterOptions, FinishDateHelperService, Firearm, FirearmMillingTypeService, FirearmOptic, FirearmOpticService, FirearmService, FirearmSightService, FormErrorMessageComponent, FrameMaterial, FrameMaterialPipe, GunCaliber, GunPart, GunPartOption, GunPartService, InventoryItem, InventoryService, JFile, Material, MaterialService, MillingDetail, MillingItem, MillingType, MillingTypeAddon, MillingTypeAddonOption, MillingTypeAddonService, MillingTypeService, ModalHeaderComponent, MountType, MountTypeService, NewLinePipe, NotificationBarComponent, NotificationModule, NotificationService, NotificationType, Optic, OpticService, OpticSight, OpticStatus, Package, PackageItem, PackageOptionalItem, PackageOptionalItemService, PackageService, PackageTotal, PackageVariation, PackageVariationOption, PackageVariationService, PhonePipe, Product, ProductService, ProjectType, PurchaseOrder, PurchaseOrderRefinishItem, PurchaseOrderService, PurchaseOrderStatus, QuickbooksService, RearSightPosition, RefinishCode, RefinishCodeService, RefinishDetail, ReportMillingItem, ReportRefinishItem, SharedModule, ShieldRMSOptions, Sight, SightMaterialService, SightMaterialType, SightService, SightType, SightTypeEnum, SightTypeService, SlideAddon, SlideAddonService, State, StateService, StatusHistoryService, Total, TotalItem, TotalsService, UserService, Vendor, VendorContact, VendorService, WaitlistAction, WaitlistCustomerService, WaitlistGun, WaitlistGunPackageDetail, WaitlistHistory, WaitlistItem, WaitlistProjectService, WaitlistService, WaitlistStatus, WorkChangeOrder, WorkHoliday, WorkHolidayService, WorkOrder, WorkOrderAction, WorkOrderBillingTransaction, WorkOrderDiscount, WorkOrderDiscountService, WorkOrderHistory, WorkOrderInventoryItem, WorkOrderListItem, WorkOrderNonInventoryItem, WorkOrderNonInventoryItemService, WorkOrderPackageDetail, WorkOrderRefinishItem, WorkOrderService, WorkOrderShippingItem, WorkOrderShippingItemService, WorkOrderStatus, WorkOrderTotal, WorkOrderType, coatingDescriptionValidator, coatingValueValidator, convertEnumToObjectArray, getCoatingValues, getCoatings, hasCoatingDescription, hasCoatingValues, refinishDetailsValidator, touchControls };
|
|
2555
2367
|
//# sourceMappingURL=gunsmith-common.mjs.map
|