@hitsoft/smart-warehouse 1.0.2 → 1.0.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.
@@ -0,0 +1,40 @@
1
+ import { ToasterService } from '@abp/ng.theme.shared';
2
+ import { EventEmitter } from '@angular/core';
3
+ import DataSource from 'devextreme/data/data_source';
4
+ import { BinLocationDto, WarehouseService } from '../../hit-proxy/warehouse/warehouse.service';
5
+ import * as i0 from "@angular/core";
6
+ /**
7
+ * Dummy Kasa (depo yeri) seçim modalı.
8
+ *
9
+ * Depo yeri sayısı bir selectbox'a sığmayacak kadar çok olabildiği için grid ile çalışır ve
10
+ * sayfalama SUNUCU tarafındadır: grid her sayfa değişiminde yalnızca o sayfayı ister. Bu sayede
11
+ * "kaynak depo seçilince tüm depo yerlerini combobox'a doldur" davranışının yarattığı donma
12
+ * ortadan kalkar — veriler yalnızca modal açıldığında ve sayfa sayfa yüklenir.
13
+ */
14
+ export declare class BinLocationPickerComponent {
15
+ private readonly warehouseService;
16
+ private readonly toaster;
17
+ /** Seçim yapılacak kaynak depo kodu; sahibi bileşen ngModel ile geçirir. */
18
+ warehouseCode: string;
19
+ /** İki yönlü bağlanır; sahibi bileşen modalı bunu true yaparak açar. */
20
+ visible: boolean;
21
+ visibleChange: EventEmitter<boolean>;
22
+ selected: EventEmitter<BinLocationDto>;
23
+ readonly pageSize = 50;
24
+ readonly allowedPageSizes: number[];
25
+ searchTerm: string;
26
+ isSearching: boolean;
27
+ readonly dataSource: DataSource;
28
+ /** Her tuş vuruşunda sunucuya gitmemek için arama debounce edilir. */
29
+ private readonly searchInput;
30
+ constructor(warehouseService: WarehouseService, toaster: ToasterService);
31
+ /** Sahibi bileşen modalı açmadan hemen önce çağırır. */
32
+ open(): void;
33
+ onSearchTermChange(term: string): void;
34
+ onRowDoubleClick(event: any): void;
35
+ select(bin: BinLocationDto): void;
36
+ close(): void;
37
+ private loadPage;
38
+ static ɵfac: i0.ɵɵFactoryDeclaration<BinLocationPickerComponent, never>;
39
+ static ɵcmp: i0.ɵɵComponentDeclaration<BinLocationPickerComponent, "lib-bin-location-picker", never, { "warehouseCode": "warehouseCode"; "visible": "visible"; }, { "visibleChange": "visibleChange"; "selected": "selected"; }, never, never, false>;
40
+ }
@@ -4,6 +4,7 @@ import { ToasterService } from '@abp/ng.theme.shared';
4
4
  import { ConnectorParamsService, SaveConnectorParamsDto } from '../../hit-proxy/connector-params/connector-params.service';
5
5
  import { ConnectorParamsGuard } from '../../guards/connector-params.guard';
6
6
  import { WarehouseService, WarehouseDto, BinLocationDto } from '../../hit-proxy/warehouse/warehouse.service';
7
+ import { BinLocationPickerComponent } from '../bin-location-picker/bin-location-picker.component';
7
8
  import * as i0 from "@angular/core";
8
9
  interface ErpOption {
9
10
  value: string;
@@ -17,9 +18,9 @@ export declare class ConnectorParamsComponent implements OnInit {
17
18
  private route;
18
19
  private warehouseService;
19
20
  erpOptions: ErpOption[];
21
+ dummyBoxPicker: BinLocationPickerComponent;
20
22
  warehouses: WarehouseDto[];
21
- binLocations: BinLocationDto[];
22
- isLoadingBinLocations: boolean;
23
+ isDummyBoxPickerOpen: boolean;
23
24
  form: SaveConnectorParamsDto;
24
25
  passwordSet: boolean;
25
26
  beeCellPasswordSet: boolean;
@@ -30,13 +31,15 @@ export declare class ConnectorParamsComponent implements OnInit {
30
31
  loadData(): void;
31
32
  get isCurrentFromWhsInList(): boolean;
32
33
  get isCurrentWhsInList(): boolean;
33
- get isCurrentDummyBoxInList(): boolean;
34
34
  /**
35
- * Kaynak Depo seçimi değiştiğinde çalışır: Dummy Kasa combobox'ını seçilen deponun
36
- * depo yerleriyle doldurur. Depo değiştiği için önceki depoya ait seçim artık geçerli değil.
35
+ * Kaynak Depo seçimi değiştiğinde çalışır. Depo değiştiği için önceki depoya ait Dummy Kasa
36
+ * seçimi artık geçerli değil temizlenir. Depo yerleri artık burada YÜKLENMEZ; kullanıcı
37
+ * "Seç" ile modalı açtığında sunucudan sayfa sayfa gelir (çok fazla veri combobox'ı kilitliyordu).
37
38
  */
38
39
  onFromWarehouseChange(whsCode: string): void;
39
- private loadBinLocations;
40
+ /** Dummy Kasa seçim modalını açar. Kaynak depo seçilmeden açılamaz. */
41
+ openDummyBoxPicker(): void;
42
+ onDummyBoxSelected(bin: BinLocationDto): void;
40
43
  save(): void;
41
44
  static ɵfac: i0.ɵɵFactoryDeclaration<ConnectorParamsComponent, never>;
42
45
  static ɵcmp: i0.ɵɵComponentDeclaration<ConnectorParamsComponent, "lib-connector-params", never, {}, {}, never, never, false>;
@@ -1,13 +1,15 @@
1
1
  import * as i0 from "@angular/core";
2
2
  import * as i1 from "./connector-params.component";
3
- import * as i2 from "@abp/ng.core";
4
- import * as i3 from "@abp/ng.theme.shared";
5
- import * as i4 from "@angular/forms";
6
- import * as i5 from "@abp/ng.components/page";
7
- import * as i6 from "@angular/router";
3
+ import * as i2 from "../bin-location-picker/bin-location-picker.component";
4
+ import * as i3 from "@abp/ng.core";
5
+ import * as i4 from "@abp/ng.theme.shared";
6
+ import * as i5 from "@angular/forms";
7
+ import * as i6 from "@abp/ng.components/page";
8
+ import * as i7 from "devextreme-angular";
9
+ import * as i8 from "@angular/router";
8
10
  export declare class ConnectorParamsModule {
9
11
  static ɵfac: i0.ɵɵFactoryDeclaration<ConnectorParamsModule, never>;
10
- static ɵmod: i0.ɵɵNgModuleDeclaration<ConnectorParamsModule, [typeof i1.ConnectorParamsComponent], [typeof i2.CoreModule, typeof i3.ThemeSharedModule, typeof i4.FormsModule, typeof i5.PageModule, typeof i6.RouterModule], never>;
12
+ static ɵmod: i0.ɵɵNgModuleDeclaration<ConnectorParamsModule, [typeof i1.ConnectorParamsComponent, typeof i2.BinLocationPickerComponent], [typeof i3.CoreModule, typeof i4.ThemeSharedModule, typeof i5.FormsModule, typeof i6.PageModule, typeof i7.DxDataGridModule, typeof i8.RouterModule], never>;
11
13
  static ɵinj: i0.ɵɵInjectorDeclaration<ConnectorParamsModule>;
12
14
  }
13
15
  export declare function loadConnectorParamsModuleAsChild(): Promise<typeof ConnectorParamsModule>;
@@ -22,6 +22,10 @@ export interface ItemInfoDto {
22
22
  ItemCode: string;
23
23
  ItemName: string;
24
24
  }
25
+ export interface BinLocationLookupResultDto {
26
+ Items: BinLocationDto[];
27
+ TotalCount: number;
28
+ }
25
29
  export declare class WarehouseService {
26
30
  private restService;
27
31
  apiName: string;
@@ -33,6 +37,11 @@ export declare class WarehouseService {
33
37
  * Seçilen depoya ait depo yerlerini (bin locations) getirir
34
38
  */
35
39
  getBinLocationsByWarehouse: (whsCode: string) => Observable<BinLocationDto[]>;
40
+ /**
41
+ * Depo yeri seçim modalı için sayfalı depo yeri araması.
42
+ * search boş bırakılabilir — o zaman deponun tüm depo yerleri sayfa sayfa gezilir.
43
+ */
44
+ searchBinLocationsByWarehouse: (warehouseCode: string, search: string, skip: number, take: number) => Observable<BinLocationLookupResultDto>;
36
45
  /**
37
46
  * Tüm akıllı depolardaki depo yerlerini getirir
38
47
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hitsoft/smart-warehouse",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "description": "Erkul Smart Warehouse",
5
5
  "peerDependencies": {
6
6
  "@angular/common": ">=9",