@colijnit/transaction 12.1.3 → 12.1.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/app/service/dictionary.service.d.ts +1 -0
- package/bundles/colijnit-transaction.umd.js +22 -12
- package/bundles/colijnit-transaction.umd.js.map +1 -1
- package/colijnit-transaction.metadata.json +1 -1
- package/esm2015/app/component/core/warehouse/warehouse.component.js +3 -2
- package/esm2015/app/component/service-order/ione-service-order-module.js +2 -2
- package/esm2015/app/service/dictionary.service.js +20 -9
- package/fesm2015/colijnit-transaction.js +21 -10
- package/fesm2015/colijnit-transaction.js.map +1 -1
- package/package.json +1 -1
|
@@ -3013,21 +3013,23 @@
|
|
|
3013
3013
|
// Loads the dictionary for given language in memory.
|
|
3014
3014
|
DictionaryService.prototype.setDictionary = function (language) {
|
|
3015
3015
|
return __awaiter(this, void 0, void 0, function () {
|
|
3016
|
-
var dictionary;
|
|
3017
3016
|
return __generator(this, function (_a) {
|
|
3018
3017
|
this._language = language || LanguageCode.Dutch;
|
|
3019
|
-
|
|
3020
|
-
dictionary = new Dictionary();
|
|
3021
|
-
// eslint-disable-next-line no-magic-numbers
|
|
3022
|
-
if (dictionary.strings[this._language.substr(0, 2).toLowerCase()] !== undefined) {
|
|
3023
|
-
// eslint-disable-next-line no-magic-numbers
|
|
3024
|
-
this._dictionaries.set(this._language, dictionary.strings[this._language.substr(0, 2).toLowerCase()]);
|
|
3025
|
-
}
|
|
3026
|
-
}
|
|
3018
|
+
this._loadDictionary();
|
|
3027
3019
|
return [2 /*return*/];
|
|
3028
3020
|
});
|
|
3029
3021
|
});
|
|
3030
3022
|
};
|
|
3023
|
+
DictionaryService.prototype._loadDictionary = function () {
|
|
3024
|
+
if (!this._dictionaries.has(this._language)) {
|
|
3025
|
+
var dictionary = new Dictionary();
|
|
3026
|
+
// eslint-disable-next-line no-magic-numbers
|
|
3027
|
+
if (dictionary.strings[this._language.substr(0, 2).toLowerCase()] !== undefined) {
|
|
3028
|
+
// eslint-disable-next-line no-magic-numbers
|
|
3029
|
+
this._dictionaries.set(this._language, dictionary.strings[this._language.substr(0, 2).toLowerCase()]);
|
|
3030
|
+
}
|
|
3031
|
+
}
|
|
3032
|
+
};
|
|
3031
3033
|
/**
|
|
3032
3034
|
* Returns the localized text for the given dictionary key.
|
|
3033
3035
|
* @param {string} key
|
|
@@ -3044,6 +3046,10 @@
|
|
|
3044
3046
|
if (!StringUtils.IsStringWithLength(key)) {
|
|
3045
3047
|
return key || "";
|
|
3046
3048
|
}
|
|
3049
|
+
if (this.language === undefined) {
|
|
3050
|
+
this._language = LanguageCode.Dutch;
|
|
3051
|
+
this._loadDictionary();
|
|
3052
|
+
}
|
|
3047
3053
|
var text = this._dictionaries.get(this.language)[key];
|
|
3048
3054
|
text = StringUtils.IsStringWithLength(text) ? text : key;
|
|
3049
3055
|
if (upperCaseFirst) {
|
|
@@ -3059,8 +3065,11 @@
|
|
|
3059
3065
|
};
|
|
3060
3066
|
return DictionaryService;
|
|
3061
3067
|
}());
|
|
3068
|
+
DictionaryService.ɵprov = i0__namespace.ɵɵdefineInjectable({ factory: function DictionaryService_Factory() { return new DictionaryService(); }, token: DictionaryService, providedIn: "root" });
|
|
3062
3069
|
DictionaryService.decorators = [
|
|
3063
|
-
{ type: i0.Injectable
|
|
3070
|
+
{ type: i0.Injectable, args: [{
|
|
3071
|
+
providedIn: "root"
|
|
3072
|
+
},] }
|
|
3064
3073
|
];
|
|
3065
3074
|
DictionaryService.ctorParameters = function () { return []; };
|
|
3066
3075
|
|
|
@@ -8136,7 +8145,6 @@
|
|
|
8136
8145
|
this.transactionArticleWarehouses = [];
|
|
8137
8146
|
this.columns = [];
|
|
8138
8147
|
this._okOrCancelClick = false;
|
|
8139
|
-
this.columns.push({ field: "warehouseNr", headerText: this._dictionaryService.get("WAREHOUSE"), allowFiltering: false }, { field: "warehouseDesc", headerText: this._dictionaryService.get("DESCRIPTION") }, { field: "stockAmount", headerText: this._dictionaryService.get("STOCK") });
|
|
8140
8148
|
}
|
|
8141
8149
|
WarehouseComponent.prototype.ngOnInit = function () {
|
|
8142
8150
|
return __awaiter(this, void 0, void 0, function () {
|
|
@@ -8148,6 +8156,7 @@
|
|
|
8148
8156
|
return [4 /*yield*/, this.service.getCommissionCodes("NL")];
|
|
8149
8157
|
case 1:
|
|
8150
8158
|
_a.commissionCodes = _b.sent();
|
|
8159
|
+
this.columns.push({ field: "warehouseNr", headerText: this._dictionaryService.get("WAREHOUSE"), allowFiltering: false }, { field: "warehouseDesc", headerText: this._dictionaryService.get("DESCRIPTION") }, { field: "stockAmount", headerText: this._dictionaryService.get("STOCK") });
|
|
8151
8160
|
return [2 /*return*/];
|
|
8152
8161
|
}
|
|
8153
8162
|
});
|
|
@@ -8237,6 +8246,7 @@
|
|
|
8237
8246
|
// eslint-disable-next-line @angular-eslint/component-selector
|
|
8238
8247
|
selector: "warehouse",
|
|
8239
8248
|
template: "\n <co-dialog #warehouseDialog\n (closeClick)=\"hide()\"\n (overlayClick)=\"onStockManagerCancelClick()\"\n >\n <ng-container header>{{ 'STOCK_NOTIFICATION' | localize }}</ng-container>\n\n <ng-container content>\n <co-form>\n <div class=\"form-content\">\n <span *ngIf=\"message\" class=\"message-field\" [textContent]=\"message | localize\"></span>\n <div class=\"commission-fields\" fxLayout=\"row\">\n <co-input-number-picker class=\"horizontal\" [(model)]=\"amount\" [min]=\"0\" decimals=\"3\"></co-input-number-picker>\n <co-input-combo-box [(model)]=\"commissionCode\"\n [source]=\"commissionCodes\"\n [fields]=\"commissionFields\"\n [placeholder]=\"'COMMISSION_CODE' | localize\"\n [required]=\"true\"\n ></co-input-combo-box>\n </div>\n <div>\n <co-grid #warehouseGrid\n [data]=\"transactionArticleWarehouses\"\n [columns]=\"columns\"\n [pagingEnabled]=\"'true'\"\n [maxNumberOfRows]=\"'10'\"\n (rowsSelected)=\"handleRowsSelected($event)\"\n ></co-grid>\n </div>\n </div>\n </co-form>\n </ng-container>\n\n <ng-container footer>\n <div class=\"flex-center\">\n <co-button [label]=\"'OK' | localize\" (click)=\"onStockManagerOkClick()\"></co-button>\n <co-button [label]=\"'CANCEL' | localize\" (click)=\"onStockManagerCancelClick()\"></co-button>\n </div>\n </ng-container>\n </co-dialog>\n ",
|
|
8249
|
+
providers: [DictionaryService],
|
|
8240
8250
|
styles: ["html,body{height:100%}body{margin:0;font-family:Roboto,\"Helvetica Neue\",sans-serif}.flex-center,.warehouse-line-container{display:flex}.flex-center,.warehouse-line-container{flex-direction:row}.flex-center{align-items:center!important;justify-content:center!important}::ng-deep #warehouseDialog ::ng-deep .form-content .message-field,.commission-fields{margin-left:11px}.triangle{border-radius:3px}.full-width{width:100%}.flex-center{margin:10px 0}::ng-deep #warehouseDialog{align-items:center;max-height:100%}::ng-deep #warehouseDialog ::ng-deep co-form{height:100%;width:500px}::ng-deep #warehouseDialog ::ng-deep .form-content{height:calc(100% - 80px);width:100%}::ng-deep #warehouseDialog ::ng-deep .form-content .message-field{height:20px;word-wrap:break-word;white-space:normal}co-button:not(:last-child){margin-right:10px}.commission-fields{justify-content:space-between;margin:10px 0}.warehouse-description-item{width:15rem}.warehouse-nr-item{width:5rem}co-input-number-picker co-button{max-width:20px}\n"]
|
|
8241
8251
|
},] }
|
|
8242
8252
|
];
|
|
@@ -8277,13 +8287,13 @@
|
|
|
8277
8287
|
corecomponents_v12.PopupModule.forRoot(),
|
|
8278
8288
|
corecomponents_v12.CoSidebarModule,
|
|
8279
8289
|
corecomponents_v12.CoGridModule,
|
|
8280
|
-
CoreModule,
|
|
8281
8290
|
ej2AngularButtons.ChipListModule,
|
|
8282
8291
|
ej2AngularSplitbuttons.DropDownButtonModule,
|
|
8283
8292
|
ej2AngularButtons.CheckBoxModule,
|
|
8284
8293
|
ej2AngularDropdowns.DropDownListModule,
|
|
8285
8294
|
IoneShoppingCartModule,
|
|
8286
8295
|
ej2AngularNavigations.TabModule,
|
|
8296
|
+
CoreModule,
|
|
8287
8297
|
common.CommonModule,
|
|
8288
8298
|
// RichTextEditorModule
|
|
8289
8299
|
],
|