@colijnit/transaction 254.1.26 → 254.1.28

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.
@@ -3,8 +3,8 @@ export class Version {
3
3
  constructor() {
4
4
  this.name = "@colijnit/transaction";
5
5
  this.description = "Colijn IT transaction package";
6
- this.symVer = "254.1.26";
7
- this.publishDate = "22-7-2024 09:15:36";
6
+ this.symVer = "254.1.28";
7
+ this.publishDate = "13-8-2024 17:13:15";
8
8
  }
9
9
  }
10
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHJhbnNhY3Rpb24tdmVyc2lvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL3RyYW5zYWN0aW9uL3NyYy9saWIvdHJhbnNhY3Rpb24tdmVyc2lvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSx1REFBdUQ7QUFDdkQsTUFBTSxPQUFPLE9BQU87SUFBcEI7UUFDUyxTQUFJLEdBQUcsdUJBQXVCLENBQUM7UUFDL0IsZ0JBQVcsR0FBRywrQkFBK0IsQ0FBQztRQUM5QyxXQUFNLEdBQUcsVUFBVSxDQUFDO1FBQ3BCLGdCQUFXLEdBQUcsb0JBQW9CLENBQUM7SUFDNUMsQ0FBQztDQUFBIiwic291cmNlc0NvbnRlbnQiOlsiLy8gdGhpcyBmaWxlIGlzIGR5bmFtaWNhbGx5IGNyZWF0ZWQsIGRvIG5vdCBjaGFuZ2UgdGhpc1xuZXhwb3J0IGNsYXNzIFZlcnNpb24ge1xuICBwdWJsaWMgbmFtZSA9IFwiQGNvbGlqbml0L3RyYW5zYWN0aW9uXCI7XG4gIHB1YmxpYyBkZXNjcmlwdGlvbiA9IFwiQ29saWpuIElUIHRyYW5zYWN0aW9uIHBhY2thZ2VcIjtcbiAgcHVibGljIHN5bVZlciA9IFwiMjU0LjEuMjZcIjtcbiAgcHVibGljIHB1Ymxpc2hEYXRlID0gXCIyMi03LTIwMjQgMDk6MTU6MzZcIjtcbn0iXX0=
10
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHJhbnNhY3Rpb24tdmVyc2lvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL3RyYW5zYWN0aW9uL3NyYy9saWIvdHJhbnNhY3Rpb24tdmVyc2lvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSx1REFBdUQ7QUFDdkQsTUFBTSxPQUFPLE9BQU87SUFBcEI7UUFDUyxTQUFJLEdBQUcsdUJBQXVCLENBQUM7UUFDL0IsZ0JBQVcsR0FBRywrQkFBK0IsQ0FBQztRQUM5QyxXQUFNLEdBQUcsVUFBVSxDQUFDO1FBQ3BCLGdCQUFXLEdBQUcsb0JBQW9CLENBQUM7SUFDNUMsQ0FBQztDQUFBIiwic291cmNlc0NvbnRlbnQiOlsiLy8gdGhpcyBmaWxlIGlzIGR5bmFtaWNhbGx5IGNyZWF0ZWQsIGRvIG5vdCBjaGFuZ2UgdGhpc1xuZXhwb3J0IGNsYXNzIFZlcnNpb24ge1xuICBwdWJsaWMgbmFtZSA9IFwiQGNvbGlqbml0L3RyYW5zYWN0aW9uXCI7XG4gIHB1YmxpYyBkZXNjcmlwdGlvbiA9IFwiQ29saWpuIElUIHRyYW5zYWN0aW9uIHBhY2thZ2VcIjtcbiAgcHVibGljIHN5bVZlciA9IFwiMjU0LjEuMjhcIjtcbiAgcHVibGljIHB1Ymxpc2hEYXRlID0gXCIxMy04LTIwMjQgMTc6MTM6MTVcIjtcbn0iXX0=
@@ -261,8 +261,8 @@ class Version {
261
261
  constructor() {
262
262
  this.name = "@colijnit/transaction";
263
263
  this.description = "Colijn IT transaction package";
264
- this.symVer = "254.1.26";
265
- this.publishDate = "22-7-2024 09:15:36";
264
+ this.symVer = "254.1.28";
265
+ this.publishDate = "13-8-2024 17:13:15";
266
266
  }
267
267
  }
268
268
 
@@ -1938,6 +1938,23 @@ class ArticleConnectorService {
1938
1938
  });
1939
1939
  });
1940
1940
  }
1941
+ getArticleListWithBarcodeArticleNrEanCode(search) {
1942
+ return __awaiter(this, void 0, void 0, function* () {
1943
+ return new Promise((resolve, reject) => {
1944
+ return this.connector.getArticleListWithBarcodeArticleNrEanCode(search).then((response) => {
1945
+ if (response && response.validationResult && response.validationResult.success) {
1946
+ // return this._boFactory.makeWithRawBackendData(ArticleExtended, response.resultObject) as ArticleLight;
1947
+ const collection = this._boFactory.makeBOArrayFromRawBackendDataArray(ArticleLight, response.resultObject);
1948
+ resolve(collection);
1949
+ }
1950
+ else {
1951
+ this._handleExceptionFromResponse(response);
1952
+ reject(null);
1953
+ }
1954
+ });
1955
+ });
1956
+ });
1957
+ }
1941
1958
  getMainArticles() {
1942
1959
  return __awaiter(this, void 0, void 0, function* () {
1943
1960
  return new Promise((resolve, reject) => {
@@ -10593,6 +10610,9 @@ class TransactionService extends PendingReasonService {
10593
10610
  getArticles(request) {
10594
10611
  return this.articleConnector.searchArticles(request);
10595
10612
  }
10613
+ getArticleListWithBarcodeArticleNrEanCode(search) {
10614
+ return this.articleConnector.getArticleListWithBarcodeArticleNrEanCode(search);
10615
+ }
10596
10616
  getMainArticles() {
10597
10617
  return this.articleConnector.getMainArticles();
10598
10618
  }
@@ -43257,6 +43277,7 @@ class TransactionPurchaseOrderFilterContentLogisticsComponent extends Transactio
43257
43277
  this.deliveryMethodFields = { text: "description", value: "code" };
43258
43278
  this.warehouseFields = { text: "description", value: "warehouseNo" };
43259
43279
  this.sourceWarehouseFields = { text: "description", value: "warehouseNo" };
43280
+ this.partDeliveryFields = { text: "description", value: "code" };
43260
43281
  }
43261
43282
  showClass() {
43262
43283
  return true;
@@ -43268,6 +43289,7 @@ class TransactionPurchaseOrderFilterContentLogisticsComponent extends Transactio
43268
43289
  this._setDeliveryMethods();
43269
43290
  this._setWarehouses();
43270
43291
  this._setSourceWarehouses();
43292
+ this._setPartDelivery();
43271
43293
  }
43272
43294
  //Delivery Methods
43273
43295
  _setDeliveryMethods() {
@@ -43287,6 +43309,11 @@ class TransactionPurchaseOrderFilterContentLogisticsComponent extends Transactio
43287
43309
  this.sourceWarehouses = new FilterViewmodel(warehouses, this.sourceWarehouseFields).filterItems;
43288
43310
  });
43289
43311
  }
43312
+ _setPartDelivery() {
43313
+ this.transactionService.getYesNo("NL").then((partDelivery) => {
43314
+ this.partDelivery = new FilterViewmodel(partDelivery, this.partDeliveryFields).filterItems;
43315
+ });
43316
+ }
43290
43317
  }
43291
43318
  TransactionPurchaseOrderFilterContentLogisticsComponent.decorators = [
43292
43319
  { type: Component, args: [{
@@ -43320,15 +43347,6 @@ TransactionPurchaseOrderFilterContentLogisticsComponent.decorators = [
43320
43347
  </co-transaction-filter-item>
43321
43348
  </div>
43322
43349
 
43323
- <!--Geleverd-->
43324
- <div class="filter-item-wrapper">
43325
- <co-transaction-filter-historic-state [label]="'DELIVERED'"
43326
- [(model)]="searchService.searchRequest.quantityDelivered"
43327
- [mode]="modes.SelectListWithStringCollectionOutput">
43328
- >
43329
- </co-transaction-filter-historic-state>
43330
- </div>
43331
-
43332
43350
  <!--Gefactureerd-->
43333
43351
  <div class="filter-item-wrapper">
43334
43352
  <co-transaction-filter-historic-state [label]="'INVOICED'"
@@ -43393,11 +43411,12 @@ TransactionPurchaseOrderFilterContentLogisticsComponent.decorators = [
43393
43411
 
43394
43412
  <!--Deellevering-->
43395
43413
  <div class="filter-item-wrapper">
43396
- <co-transaction-filter-historic-state [label]="'PART_DELIVERY'"
43397
- [(model)]="searchService.searchRequest.partialDelivery"
43398
- [mode]="modes.CheckboxToText">
43414
+ <co-transaction-filter-item [placeholder]="'PART_DELIVERY'"
43415
+ [collection]="partDelivery"
43416
+ [(model)]="searchService.searchRequest.partialDelivery"
43417
+ [mode]="modes.Filterlist">
43399
43418
  >
43400
- </co-transaction-filter-historic-state>
43419
+ </co-transaction-filter-item>
43401
43420
  </div>
43402
43421
 
43403
43422
  <!--Magazijn-->
@@ -48437,13 +48456,24 @@ class AddProductComponent {
48437
48456
  this.searchText = undefined;
48438
48457
  this._changeDetector.detectChanges();
48439
48458
  // first check if there's a single article found
48440
- const foundArticles = yield this.transactionService.getArticles(this.catalogParameters);
48441
- if (foundArticles && foundArticles.length === 1) {
48442
- const article = yield this.transactionService.getArticleExtended(foundArticles[0].articleNumber);
48459
+ // This is a two check step:
48460
+ // Check if there is an exact match on barcode, ean or articlenumber
48461
+ // if not: check with search like
48462
+ // else open catalogus
48463
+ const fullMatchSearch = yield this.transactionService.getArticleListWithBarcodeArticleNrEanCode(text);
48464
+ if (fullMatchSearch && fullMatchSearch.length === 1) {
48465
+ const article = yield this.transactionService.getArticleExtended(fullMatchSearch[0].articleNr);
48443
48466
  yield this.handleAddArticle(article);
48444
48467
  }
48445
- else { // else open the catalog
48446
- this.showCatalogDialog();
48468
+ else {
48469
+ const foundArticles = yield this.transactionService.getArticles(this.catalogParameters);
48470
+ if (foundArticles && foundArticles.length === 1) {
48471
+ const article = yield this.transactionService.getArticleExtended(foundArticles[0].articleNumber);
48472
+ yield this.handleAddArticle(article);
48473
+ }
48474
+ else {
48475
+ this.showCatalogDialog();
48476
+ }
48447
48477
  }
48448
48478
  });
48449
48479
  }