@hitsoft/uretim-yonetimi 1.0.10 → 1.0.12
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/.eslintrc.json +44 -0
- package/README.md +24 -24
- package/config/ng-package.json +7 -0
- package/config/src/enums/route-names.ts +3 -0
- package/config/src/providers/create-barcode-route.provider.ts +21 -0
- package/config/src/providers/issues-for-production-route.provider.ts +21 -0
- package/config/src/providers/production-order-route.provider.ts +21 -0
- package/config/src/providers/receipt-from-production-route.provider.ts +21 -0
- package/config/src/providers/route.provider.ts +26 -0
- package/config/src/uretim-yonetimi-config.module.ts +22 -0
- package/karma.conf.js +44 -0
- package/ng-package.json +7 -0
- package/package.json +14 -42
- package/src/lib/components/hit-create-barcodes/hit-create-barcodes-component.css +10 -0
- package/src/lib/components/hit-create-barcodes/hit-create-barcodes-routing.module.ts +19 -0
- package/src/lib/components/hit-create-barcodes/hit-create-barcodes.component.html +80 -0
- package/src/lib/components/hit-create-barcodes/hit-create-barcodes.component.ts +219 -0
- package/src/lib/components/hit-create-barcodes/hit-create-barcodes.module.ts +39 -0
- package/src/lib/components/hit-issues-for-productions/hit-issues-for-productions-routing.module.ts +19 -0
- package/src/lib/components/hit-issues-for-productions/hit-issues-for-productions.componenet.css +7 -0
- package/src/lib/components/hit-issues-for-productions/hit-issues-for-productions.component.html +96 -0
- package/src/lib/components/hit-issues-for-productions/hit-issues-for-productions.component.ts +274 -0
- package/src/lib/components/hit-issues-for-productions/hit-issues-for-productions.module.ts +46 -0
- package/src/lib/components/hit-production-orders/hit-production-orders-routing.module.ts +19 -0
- package/src/lib/components/hit-production-orders/hit-production-orders.component.html +79 -0
- package/src/lib/components/hit-production-orders/hit-production-orders.component.ts +214 -0
- package/src/lib/components/hit-production-orders/hit-production-orders.module.ts +39 -0
- package/src/lib/components/hit-receipt-from-productions/hit-receipt-from-production-component.css +10 -0
- package/src/lib/components/hit-receipt-from-productions/hit-receipt-from-production-routing.module.ts +19 -0
- package/src/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.component.html +101 -0
- package/src/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.component.ts +258 -0
- package/src/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.module.ts +38 -0
- package/src/lib/components/uretim-yonetimi.component.ts +9 -0
- package/src/lib/hit-proxy/devexpress-query-builder/devexpress-load-options.model.ts +20 -0
- package/src/lib/hit-proxy/devexpress-query-builder/devexpress-query-builder.ts +51 -0
- package/src/lib/hit-proxy/hit-create-barcodes/hit-create-barcodes.service.ts +41 -0
- package/src/lib/hit-proxy/hit-create-barcodes/models.ts +6 -0
- package/src/lib/hit-proxy/hit-issues-for-productions/hit-issues-for-productions.service.ts +39 -0
- package/src/lib/hit-proxy/hit-issues-for-productions/models.ts +42 -0
- package/src/lib/hit-proxy/hit-production-orders/hit-production-orders.service.ts +60 -0
- package/src/lib/hit-proxy/hit-production-orders/models.ts +137 -0
- package/src/lib/hit-proxy/hit-receipt-from-productions/hit-receipt-from-productions.service.ts +32 -0
- package/src/lib/hit-proxy/hit-receipt-from-productions/models.ts +43 -0
- package/src/lib/hit-proxy/models.ts +105 -0
- package/src/lib/uretim-yonetimi-routing.module.ts +30 -0
- package/src/lib/uretim-yonetimi.component.spec.ts +24 -0
- package/src/lib/uretim-yonetimi.module.ts +52 -0
- package/src/lib/uretim-yonetimi.service.spec.ts +15 -0
- package/{public-api.d.ts → src/public-api.ts} +4 -0
- package/src/test.ts +29 -0
- package/tsconfig.lib.json +20 -0
- package/tsconfig.lib.prod.json +10 -0
- package/tsconfig.spec.json +17 -0
- package/config/enums/route-names.d.ts +0 -3
- package/config/index.d.ts +0 -5
- package/config/providers/create-barcode-route.provider.d.ts +0 -9
- package/config/providers/issues-for-production-route.provider.d.ts +0 -9
- package/config/providers/production-order-route.provider.d.ts +0 -9
- package/config/providers/receipt-from-production-route.provider.d.ts +0 -9
- package/config/providers/route.provider.d.ts +0 -8
- package/config/uretim-yonetimi-config.module.d.ts +0 -8
- package/esm2020/config/enums/index.mjs +0 -2
- package/esm2020/config/enums/route-names.mjs +0 -2
- package/esm2020/config/hitsoft-uretim-yonetimi-config.mjs +0 -5
- package/esm2020/config/providers/create-barcode-route.provider.mjs +0 -19
- package/esm2020/config/providers/index.mjs +0 -2
- package/esm2020/config/providers/issues-for-production-route.provider.mjs +0 -19
- package/esm2020/config/providers/production-order-route.provider.mjs +0 -19
- package/esm2020/config/providers/receipt-from-production-route.provider.mjs +0 -19
- package/esm2020/config/providers/route.provider.mjs +0 -24
- package/esm2020/config/public-api.mjs +0 -4
- package/esm2020/config/uretim-yonetimi-config.module.mjs +0 -28
- package/esm2020/hitsoft-uretim-yonetimi.mjs +0 -5
- package/esm2020/lib/components/hit-create-barcodes/hit-create-barcodes-routing.module.mjs +0 -26
- package/esm2020/lib/components/hit-create-barcodes/hit-create-barcodes.component.mjs +0 -186
- package/esm2020/lib/components/hit-create-barcodes/hit-create-barcodes.module.mjs +0 -65
- package/esm2020/lib/components/hit-issues-for-productions/hit-issues-for-productions-routing.module.mjs +0 -26
- package/esm2020/lib/components/hit-issues-for-productions/hit-issues-for-productions.component.mjs +0 -250
- package/esm2020/lib/components/hit-issues-for-productions/hit-issues-for-productions.module.mjs +0 -68
- package/esm2020/lib/components/hit-production-orders/hit-production-orders-routing.module.mjs +0 -26
- package/esm2020/lib/components/hit-production-orders/hit-production-orders.component.mjs +0 -152
- package/esm2020/lib/components/hit-production-orders/hit-production-orders.module.mjs +0 -65
- package/esm2020/lib/components/hit-receipt-from-productions/hit-receipt-from-production-routing.module.mjs +0 -26
- package/esm2020/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.component.mjs +0 -215
- package/esm2020/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.module.mjs +0 -62
- package/esm2020/lib/components/uretim-yonetimi.component.mjs +0 -11
- package/esm2020/lib/hit-proxy/devexpress-query-builder/devexpress-load-options.model.mjs +0 -2
- package/esm2020/lib/hit-proxy/devexpress-query-builder/devexpress-query-builder.mjs +0 -54
- package/esm2020/lib/hit-proxy/hit-create-barcodes/hit-create-barcodes.service.mjs +0 -35
- package/esm2020/lib/hit-proxy/hit-create-barcodes/models.mjs +0 -3
- package/esm2020/lib/hit-proxy/hit-issues-for-productions/hit-issues-for-productions.service.mjs +0 -35
- package/esm2020/lib/hit-proxy/hit-issues-for-productions/models.mjs +0 -24
- package/esm2020/lib/hit-proxy/hit-production-orders/hit-production-orders.service.mjs +0 -44
- package/esm2020/lib/hit-proxy/hit-production-orders/models.mjs +0 -65
- package/esm2020/lib/hit-proxy/hit-receipt-from-productions/hit-receipt-from-productions.service.mjs +0 -30
- package/esm2020/lib/hit-proxy/hit-receipt-from-productions/models.mjs +0 -20
- package/esm2020/lib/hit-proxy/models.mjs +0 -81
- package/esm2020/lib/services/uretim-yonetimi.service.mjs +0 -18
- package/esm2020/lib/uretim-yonetimi-routing.module.mjs +0 -33
- package/esm2020/lib/uretim-yonetimi.module.mjs +0 -55
- package/esm2020/public-api.mjs +0 -6
- package/fesm2015/hitsoft-uretim-yonetimi-config.mjs +0 -121
- package/fesm2015/hitsoft-uretim-yonetimi-config.mjs.map +0 -1
- package/fesm2015/hitsoft-uretim-yonetimi.mjs +0 -1539
- package/fesm2015/hitsoft-uretim-yonetimi.mjs.map +0 -1
- package/fesm2020/hitsoft-uretim-yonetimi-config.mjs +0 -121
- package/fesm2020/hitsoft-uretim-yonetimi-config.mjs.map +0 -1
- package/fesm2020/hitsoft-uretim-yonetimi.mjs +0 -1517
- package/fesm2020/hitsoft-uretim-yonetimi.mjs.map +0 -1
- package/index.d.ts +0 -5
- package/lib/components/hit-create-barcodes/hit-create-barcodes-routing.module.d.ts +0 -7
- package/lib/components/hit-create-barcodes/hit-create-barcodes.component.d.ts +0 -45
- package/lib/components/hit-create-barcodes/hit-create-barcodes.module.d.ts +0 -16
- package/lib/components/hit-issues-for-productions/hit-issues-for-productions-routing.module.d.ts +0 -7
- package/lib/components/hit-issues-for-productions/hit-issues-for-productions.component.d.ts +0 -48
- package/lib/components/hit-issues-for-productions/hit-issues-for-productions.module.d.ts +0 -16
- package/lib/components/hit-production-orders/hit-production-orders-routing.module.d.ts +0 -7
- package/lib/components/hit-production-orders/hit-production-orders.component.d.ts +0 -44
- package/lib/components/hit-production-orders/hit-production-orders.module.d.ts +0 -16
- package/lib/components/hit-receipt-from-productions/hit-receipt-from-production-routing.module.d.ts +0 -7
- package/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.component.d.ts +0 -57
- package/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.module.d.ts +0 -16
- package/lib/components/uretim-yonetimi.component.d.ts +0 -5
- package/lib/hit-proxy/devexpress-query-builder/devexpress-load-options.model.d.ts +0 -17
- package/lib/hit-proxy/devexpress-query-builder/devexpress-query-builder.d.ts +0 -18
- package/lib/hit-proxy/hit-create-barcodes/hit-create-barcodes.service.d.ts +0 -23
- package/lib/hit-proxy/hit-create-barcodes/models.d.ts +0 -6
- package/lib/hit-proxy/hit-issues-for-productions/hit-issues-for-productions.service.d.ts +0 -17
- package/lib/hit-proxy/hit-issues-for-productions/models.d.ts +0 -30
- package/lib/hit-proxy/hit-production-orders/hit-production-orders.service.d.ts +0 -19
- package/lib/hit-proxy/hit-production-orders/models.d.ts +0 -85
- package/lib/hit-proxy/hit-receipt-from-productions/hit-receipt-from-productions.service.d.ts +0 -16
- package/lib/hit-proxy/hit-receipt-from-productions/models.d.ts +0 -39
- package/lib/hit-proxy/models.d.ts +0 -21
- package/lib/services/uretim-yonetimi.service.d.ts +0 -9
- package/lib/uretim-yonetimi-routing.module.d.ts +0 -7
- package/lib/uretim-yonetimi.module.d.ts +0 -17
- /package/config/{enums/index.d.ts → src/enums/index.ts} +0 -0
- /package/config/{providers/index.d.ts → src/providers/index.ts} +0 -0
- /package/config/{public-api.d.ts → src/public-api.ts} +0 -0
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import {CoreModule} from '@abp/ng.core';
|
|
2
|
+
import {ThemeSharedModule} from '@abp/ng.theme.shared';
|
|
3
|
+
import {NgModule} from '@angular/core';
|
|
4
|
+
import {
|
|
5
|
+
NgbCollapseModule,
|
|
6
|
+
NgbDatepickerModule,
|
|
7
|
+
NgbDropdownModule,
|
|
8
|
+
} from '@ng-bootstrap/ng-bootstrap';
|
|
9
|
+
import {NgxValidateCoreModule} from '@ngx-validate/core';
|
|
10
|
+
import {CommercialUiModule} from '@volo/abp.commercial.ng.ui';
|
|
11
|
+
import {PageModule} from '@abp/ng.components/page';
|
|
12
|
+
import {HitIssuesForProductionsComponent} from "./hit-issues-for-productions.component";
|
|
13
|
+
import {HitIssuesForProductionsRoutingModule} from "./hit-issues-for-productions-routing.module";
|
|
14
|
+
import {
|
|
15
|
+
DevExtremeModule,
|
|
16
|
+
DxButtonModule,
|
|
17
|
+
DxDataGridModule,
|
|
18
|
+
DxLoadIndicatorModule,
|
|
19
|
+
DxTextBoxModule
|
|
20
|
+
} from "devextreme-angular";
|
|
21
|
+
|
|
22
|
+
@NgModule({
|
|
23
|
+
declarations: [HitIssuesForProductionsComponent],
|
|
24
|
+
imports: [
|
|
25
|
+
HitIssuesForProductionsRoutingModule,
|
|
26
|
+
CoreModule,
|
|
27
|
+
ThemeSharedModule,
|
|
28
|
+
CommercialUiModule,
|
|
29
|
+
NgxValidateCoreModule,
|
|
30
|
+
NgbCollapseModule,
|
|
31
|
+
NgbDatepickerModule,
|
|
32
|
+
NgbDropdownModule,
|
|
33
|
+
PageModule,
|
|
34
|
+
DxTextBoxModule,
|
|
35
|
+
DxButtonModule,
|
|
36
|
+
DxDataGridModule,
|
|
37
|
+
DxLoadIndicatorModule,
|
|
38
|
+
DevExtremeModule
|
|
39
|
+
],
|
|
40
|
+
})
|
|
41
|
+
export class HitIssuesForProductionModule {
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export function loadHitIssuesForProductionsAsChild() {
|
|
45
|
+
return Promise.resolve(HitIssuesForProductionModule);
|
|
46
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import {AuthGuard, PermissionGuard} from '@abp/ng.core';
|
|
2
|
+
import {NgModule} from '@angular/core';
|
|
3
|
+
import {RouterModule, Routes} from '@angular/router';
|
|
4
|
+
import {HitProductionOrdersComponent} from "./hit-production-orders.component";
|
|
5
|
+
|
|
6
|
+
const routes: Routes = [
|
|
7
|
+
{
|
|
8
|
+
path: '',
|
|
9
|
+
component: HitProductionOrdersComponent,
|
|
10
|
+
canActivate: [AuthGuard, PermissionGuard],
|
|
11
|
+
},
|
|
12
|
+
];
|
|
13
|
+
|
|
14
|
+
@NgModule({
|
|
15
|
+
imports: [RouterModule.forChild(routes)],
|
|
16
|
+
exports: [RouterModule],
|
|
17
|
+
})
|
|
18
|
+
export class HitProductionOrdersRoutingModule {
|
|
19
|
+
}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
<abp-page [breadcrumb]="false">
|
|
2
|
+
<abp-page-toolbar-container class="col">
|
|
3
|
+
<div class="row">
|
|
4
|
+
<h3 class="page-title">
|
|
5
|
+
{{ 'UretimYonetimi::ProductionOrders' | abpLocalization }}
|
|
6
|
+
</h3>
|
|
7
|
+
</div>
|
|
8
|
+
<div class="row text-lg-end pt-2">
|
|
9
|
+
<div class="col-8">
|
|
10
|
+
<button class="btn btn-success btn-sm" type="button" (click)="patchProductionOrder()"
|
|
11
|
+
[disabled]="!isEmriBarkoduGecerliMi">
|
|
12
|
+
<i class="fa fa-plus me-1"></i>
|
|
13
|
+
{{ 'UretimYonetimi::ProductionOrders.Create' | abpLocalization }}
|
|
14
|
+
</button>
|
|
15
|
+
</div>
|
|
16
|
+
<div class="col-4">
|
|
17
|
+
<button class="btn btn-warning btn-sm" type="button" (click)="clearAll()">
|
|
18
|
+
<i class="fa fa-broom me-1"></i>
|
|
19
|
+
{{ 'UretimYonetimi::ProductionOrders.Clean' | abpLocalization }}
|
|
20
|
+
</button>
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
</abp-page-toolbar-container>
|
|
24
|
+
<div class="card mt-2">
|
|
25
|
+
<div class="card-body">
|
|
26
|
+
<div style="display: flex; align-items: center;">
|
|
27
|
+
<dx-number-box #barkodNumarasiRef class="me-1" style="width:100%;"
|
|
28
|
+
[label]="'UretimYonetimi::ProductionOrders.WorkOrderNo' | abpLocalization"
|
|
29
|
+
[(value)]="isEmriBarkodu" (onEnterKey)="getProductionOrderDetails()"
|
|
30
|
+
[disabled]="searcheBasildiMi || isEmriBarkoduGecerliMi">
|
|
31
|
+
</dx-number-box>
|
|
32
|
+
<dx-button style="margin-top: 7.5px;" icon="search" type="default" (onClick)="getProductionOrderDetails()"
|
|
33
|
+
[disabled]="searcheBasildiMi || isEmriBarkoduGecerliMi">
|
|
34
|
+
</dx-button>
|
|
35
|
+
</div>
|
|
36
|
+
<div class="mt-3" *ngIf="isEmriBarkoduGecerliMi">
|
|
37
|
+
<dx-text-box style="width:100%;"
|
|
38
|
+
[label]="'UretimYonetimi::ProductionOrders.WorkOrderName' | abpLocalization"
|
|
39
|
+
[(value)]="productionOrder.productDescription"
|
|
40
|
+
[disabled]="true">
|
|
41
|
+
</dx-text-box>
|
|
42
|
+
<dx-number-box style="width:100%;"
|
|
43
|
+
[label]="'UretimYonetimi::ProductionOrders.PlannedQty' | abpLocalization"
|
|
44
|
+
format="#,##0.00"
|
|
45
|
+
[(value)]="productionOrder.plannedQuantity"
|
|
46
|
+
[disabled]="true">
|
|
47
|
+
</dx-number-box>
|
|
48
|
+
<div style="display: flex; align-items: center;">
|
|
49
|
+
<dx-text-box #hammaddeQRRef style="width:100%;" class="me-1"
|
|
50
|
+
[label]="'UretimYonetimi::ProductionOrders.QrBarcode' | abpLocalization"
|
|
51
|
+
[maxLength]="256"
|
|
52
|
+
[(value)]="hammaddeQR" (onEnterKey)="parseAndAddQR()"
|
|
53
|
+
[placeholder]="'UretimYonetimi::ProductionOrders.QrBarcode.Placeholder' | abpLocalization"
|
|
54
|
+
[disabled]="qrOkutulduMu">
|
|
55
|
+
</dx-text-box>
|
|
56
|
+
<dx-button style="margin-top: 7.5px;" icon="plus" type="default" (onClick)="parseAndAddQR()"
|
|
57
|
+
[disabled]="qrOkutulduMu">
|
|
58
|
+
</dx-button>
|
|
59
|
+
</div>
|
|
60
|
+
|
|
61
|
+
<div *ngIf="productionOrderList.ProductionOrderLines?.length" class="mt-3">
|
|
62
|
+
<dx-data-grid [dataSource]="productionOrderList.ProductionOrderLines" [showBorders]="true"
|
|
63
|
+
[columnAutoWidth]="true" (onRowRemoved)="qrOkutulduMu=false">
|
|
64
|
+
<dxo-editing mode="row" [allowUpdating]="true" [allowDeleting]="true" [useIcons]="true">
|
|
65
|
+
</dxo-editing>
|
|
66
|
+
<dxi-column dataField="ItemName" [caption]="'UretimYonetimi::ProductionOrders.ItemName' | abpLocalization" [allowEditing]="false"></dxi-column>
|
|
67
|
+
<dxi-column dataField="Quantity" [caption]="'UretimYonetimi::ProductionOrders.Quantity' | abpLocalization" dataType="number" [format]="'#0.00 kg'"></dxi-column>
|
|
68
|
+
<dxi-column dataField="WarehouseCode" [caption]="'UretimYonetimi::ProductionOrders.Warehouse' | abpLocalization" [width]="150" [allowSorting]="false">
|
|
69
|
+
<dxo-lookup [dataSource]="warehouses" displayExpr="whsName" valueExpr="whsCode">
|
|
70
|
+
</dxo-lookup>
|
|
71
|
+
</dxi-column>
|
|
72
|
+
<dxi-column dataField="ItemCode" [caption]="'UretimYonetimi::ProductionOrders.ItemCode' | abpLocalization" [allowEditing]="false"></dxi-column>
|
|
73
|
+
<dxi-column dataField="BatchNumber" [caption]="'UretimYonetimi::ProductionOrders.BatchNumber' | abpLocalization" [allowEditing]="false"></dxi-column>
|
|
74
|
+
</dx-data-grid>
|
|
75
|
+
</div>
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
78
|
+
</div>
|
|
79
|
+
</abp-page>
|
|
@@ -0,0 +1,214 @@
|
|
|
1
|
+
import {ABP, ListService, PagedResultDto, TrackByService} from '@abp/ng.core';
|
|
2
|
+
import {Confirmation, ConfirmationService} from '@abp/ng.theme.shared';
|
|
3
|
+
import {DateAdapter} from '@abp/ng.theme.shared/extensions';
|
|
4
|
+
import {
|
|
5
|
+
AfterViewInit,
|
|
6
|
+
ChangeDetectionStrategy,
|
|
7
|
+
Component,
|
|
8
|
+
NgZone,
|
|
9
|
+
OnInit,
|
|
10
|
+
ViewChild,
|
|
11
|
+
} from '@angular/core';
|
|
12
|
+
import {FormBuilder, FormControl, FormGroup, Validators} from '@angular/forms';
|
|
13
|
+
import {NgbDateAdapter} from '@ng-bootstrap/ng-bootstrap';
|
|
14
|
+
import {filter, finalize, switchMap, tap} from 'rxjs/operators';
|
|
15
|
+
import {HitProductionOrdersService} from '../../hit-proxy/hit-production-orders/hit-production-orders.service';
|
|
16
|
+
import {DevExtremeModule, DxNumberBoxComponent, DxTextBoxComponent} from 'devextreme-angular';
|
|
17
|
+
import {GetProductionOrderDto} from '../../hit-proxy/hit-receipt-from-productions/models';
|
|
18
|
+
import {
|
|
19
|
+
BatchNumber,
|
|
20
|
+
ProductionOrderLine,
|
|
21
|
+
ProductionOrderLineForListing,
|
|
22
|
+
ProductionOrderList,
|
|
23
|
+
ProductionOrderPatchDto,
|
|
24
|
+
TuketilenHammadde,
|
|
25
|
+
Warehouse,
|
|
26
|
+
} from '../../hit-proxy/hit-production-orders/models';
|
|
27
|
+
import {firstValueFrom} from 'rxjs';
|
|
28
|
+
import {HitHelper} from '../../hit-proxy/models';
|
|
29
|
+
|
|
30
|
+
@Component({
|
|
31
|
+
selector: 'lib-hit-production-orders',
|
|
32
|
+
changeDetection: ChangeDetectionStrategy.Default,
|
|
33
|
+
providers: [ListService, {provide: NgbDateAdapter, useClass: DateAdapter}],
|
|
34
|
+
templateUrl: './hit-production-orders.component.html',
|
|
35
|
+
styles: [],
|
|
36
|
+
})
|
|
37
|
+
export class HitProductionOrdersComponent implements AfterViewInit, OnInit {
|
|
38
|
+
protected readonly HitHelper = HitHelper;
|
|
39
|
+
@ViewChild('barkodNumarasiRef', {static: false}) nmbBoxBarkodNumarasi: DxTextBoxComponent;
|
|
40
|
+
@ViewChild('hammaddeQRRef', {static: false}) nmbBoxHammaddeQR: DxTextBoxComponent;
|
|
41
|
+
options: Partial<Confirmation.Options> = {
|
|
42
|
+
hideYesBtn: true,
|
|
43
|
+
cancelText: 'Kapat',
|
|
44
|
+
dismissible: false,
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
constructor(
|
|
48
|
+
private ngZone: NgZone,
|
|
49
|
+
public readonly list: ListService,
|
|
50
|
+
public readonly track: TrackByService,
|
|
51
|
+
public readonly service: HitProductionOrdersService,
|
|
52
|
+
private confirmation: ConfirmationService,
|
|
53
|
+
private fb: FormBuilder,
|
|
54
|
+
private productionOrdersService: HitProductionOrdersService
|
|
55
|
+
) {
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
ngOnInit(): void {
|
|
59
|
+
this.getWarehouses();
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
ngAfterViewInit() {
|
|
63
|
+
this.nmbBoxBarkodNumarasi.instance.focus();
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
isLoading: boolean = false;
|
|
67
|
+
isEmriBarkoduGecerliMi: boolean = false;
|
|
68
|
+
searcheBasildiMi: boolean = false;
|
|
69
|
+
isEmriBarkodu: number;
|
|
70
|
+
hammaddeQR: string = '';
|
|
71
|
+
productionOrder: GetProductionOrderDto;
|
|
72
|
+
productionOrderPatch: ProductionOrderPatchDto;
|
|
73
|
+
productionOrderList: ProductionOrderList;
|
|
74
|
+
qrOkutulduMu: boolean = false;
|
|
75
|
+
unitOfMeasure: string;
|
|
76
|
+
|
|
77
|
+
async getProductionOrderDetails() {
|
|
78
|
+
if (!this.isEmriBarkodu) {
|
|
79
|
+
return;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
try {
|
|
83
|
+
this.isLoading = true;
|
|
84
|
+
this.isEmriBarkoduGecerliMi = false;
|
|
85
|
+
this.searcheBasildiMi = true;
|
|
86
|
+
|
|
87
|
+
const response = await firstValueFrom(this.productionOrdersService.get(this.isEmriBarkodu));
|
|
88
|
+
const response2 = await this.productionOrdersService.get2(this.isEmriBarkodu).subscribe();
|
|
89
|
+
|
|
90
|
+
if (response?.items) {
|
|
91
|
+
this.unitOfMeasure = response.items.unitOfMeasurement;
|
|
92
|
+
this.productionOrder = response.items;
|
|
93
|
+
this.productionOrderList = new ProductionOrderList();
|
|
94
|
+
this.isEmriBarkoduGecerliMi = true;
|
|
95
|
+
this.ngZone.run(() => {
|
|
96
|
+
setTimeout(() => {
|
|
97
|
+
this.nmbBoxHammaddeQR.instance.focus();
|
|
98
|
+
}, 0);
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
} catch (error) {
|
|
102
|
+
this.isEmriBarkoduGecerliMi = false;
|
|
103
|
+
this.searcheBasildiMi = false;
|
|
104
|
+
} finally {
|
|
105
|
+
this.isLoading = false;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
async parseAndAddQR() {
|
|
110
|
+
if (!this.hammaddeQR) {
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
const parsed = HitHelper.parseQR(this.hammaddeQR);
|
|
115
|
+
|
|
116
|
+
if (!parsed) {
|
|
117
|
+
this.confirmation.error('', 'Geçersiz barkod!', this.options).subscribe({
|
|
118
|
+
next: () => {
|
|
119
|
+
this.hammaddeQR = '';
|
|
120
|
+
this.nmbBoxHammaddeQR.instance.focus();
|
|
121
|
+
},
|
|
122
|
+
});
|
|
123
|
+
return;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
const response = await firstValueFrom(
|
|
127
|
+
this.service.getWareHouseInfo(
|
|
128
|
+
parsed.chemicalCode,
|
|
129
|
+
this.productionOrder.absoluteEntry.toString()
|
|
130
|
+
)
|
|
131
|
+
);
|
|
132
|
+
|
|
133
|
+
const response2 = await firstValueFrom(this.service.getItemInfo(parsed.chemicalCode));
|
|
134
|
+
|
|
135
|
+
if (response?.items && response.isSuccessful) {
|
|
136
|
+
const productionOrderLineForListing = new ProductionOrderLineForListing(
|
|
137
|
+
parsed.chemicalCode,
|
|
138
|
+
response2.items.itemName,
|
|
139
|
+
response.items.selectedWarehouse,
|
|
140
|
+
parsed.weightKg,
|
|
141
|
+
parsed.weightKg,
|
|
142
|
+
parsed.lotNumber,
|
|
143
|
+
202,
|
|
144
|
+
this.productionOrder.absoluteEntry,
|
|
145
|
+
0
|
|
146
|
+
);
|
|
147
|
+
this.productionOrderList.ProductionOrderLines.push(productionOrderLineForListing);
|
|
148
|
+
|
|
149
|
+
this.qrOkutulduMu = true;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
this.hammaddeQR = '';
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
patchProductionOrder() {
|
|
156
|
+
this.isLoading = true;
|
|
157
|
+
|
|
158
|
+
const productionOrderLines: ProductionOrderLine[] =
|
|
159
|
+
this.productionOrderList.ProductionOrderLines.map(productionLine => {
|
|
160
|
+
return new ProductionOrderLine(
|
|
161
|
+
productionLine.ItemCode,
|
|
162
|
+
productionLine.WarehouseCode,
|
|
163
|
+
productionLine.Quantity,
|
|
164
|
+
productionLine.Quantity,
|
|
165
|
+
productionLine.Quantity,
|
|
166
|
+
'',
|
|
167
|
+
productionLine.BaseEntry,
|
|
168
|
+
0,
|
|
169
|
+
[new BatchNumber(productionLine.BatchNumber, productionLine.Quantity)]
|
|
170
|
+
);
|
|
171
|
+
});
|
|
172
|
+
this.productionOrderPatch = new ProductionOrderPatchDto(productionOrderLines);
|
|
173
|
+
|
|
174
|
+
this.service.patch(this.productionOrderPatch).subscribe({
|
|
175
|
+
next: result => {
|
|
176
|
+
if (result.isSuccessful) {
|
|
177
|
+
this.confirmation.success('', 'İşlem başarılı!', this.options).subscribe(() => {
|
|
178
|
+
this.clearAll();
|
|
179
|
+
});
|
|
180
|
+
}
|
|
181
|
+
},
|
|
182
|
+
});
|
|
183
|
+
|
|
184
|
+
this.isLoading = false;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
clearAll() {
|
|
188
|
+
this.isEmriBarkoduGecerliMi = false;
|
|
189
|
+
this.searcheBasildiMi = false;
|
|
190
|
+
this.qrOkutulduMu = false;
|
|
191
|
+
this.productionOrderPatch = null;
|
|
192
|
+
this.isEmriBarkodu = null;
|
|
193
|
+
this.hammaddeQR = '';
|
|
194
|
+
this.productionOrder = null;
|
|
195
|
+
this.unitOfMeasure = null;
|
|
196
|
+
this.ngZone.run(() => {
|
|
197
|
+
setTimeout(() => {
|
|
198
|
+
this.nmbBoxBarkodNumarasi.instance.focus();
|
|
199
|
+
}, 0);
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
warehouses: Warehouse[] = [];
|
|
204
|
+
|
|
205
|
+
getWarehouses() {
|
|
206
|
+
this.isLoading = true;
|
|
207
|
+
this.service.getWarehouses().subscribe(result => {
|
|
208
|
+
if (result.items) {
|
|
209
|
+
this.warehouses = result.items.slice();
|
|
210
|
+
}
|
|
211
|
+
});
|
|
212
|
+
this.isLoading = false;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import {CoreModule} from '@abp/ng.core';
|
|
2
|
+
import {ThemeSharedModule} from '@abp/ng.theme.shared';
|
|
3
|
+
import {NgModule} from '@angular/core';
|
|
4
|
+
import {
|
|
5
|
+
NgbCollapseModule,
|
|
6
|
+
NgbDatepickerModule,
|
|
7
|
+
NgbDropdownModule,
|
|
8
|
+
} from '@ng-bootstrap/ng-bootstrap';
|
|
9
|
+
import {NgxValidateCoreModule} from '@ngx-validate/core';
|
|
10
|
+
import {CommercialUiModule} from '@volo/abp.commercial.ng.ui';
|
|
11
|
+
import {PageModule} from '@abp/ng.components/page';
|
|
12
|
+
import {HitProductionOrdersComponent} from "./hit-production-orders.component";
|
|
13
|
+
import {HitProductionOrdersRoutingModule} from "./hit-production-orders-routing.module";
|
|
14
|
+
import {DxButtonModule, DxDataGridModule, DxNumberBoxModule, DxTextBoxModule} from "devextreme-angular";
|
|
15
|
+
|
|
16
|
+
@NgModule({
|
|
17
|
+
declarations: [HitProductionOrdersComponent],
|
|
18
|
+
imports: [
|
|
19
|
+
HitProductionOrdersRoutingModule,
|
|
20
|
+
CoreModule,
|
|
21
|
+
ThemeSharedModule,
|
|
22
|
+
CommercialUiModule,
|
|
23
|
+
NgxValidateCoreModule,
|
|
24
|
+
NgbCollapseModule,
|
|
25
|
+
NgbDatepickerModule,
|
|
26
|
+
NgbDropdownModule,
|
|
27
|
+
PageModule,
|
|
28
|
+
DxTextBoxModule,
|
|
29
|
+
DxButtonModule,
|
|
30
|
+
DxDataGridModule,
|
|
31
|
+
DxNumberBoxModule
|
|
32
|
+
],
|
|
33
|
+
})
|
|
34
|
+
export class HitProductionOrderModule {
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export function loadHitProductionOrdersAsChild() {
|
|
38
|
+
return Promise.resolve(HitProductionOrderModule);
|
|
39
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import {AuthGuard, PermissionGuard} from '@abp/ng.core';
|
|
2
|
+
import {NgModule} from '@angular/core';
|
|
3
|
+
import {RouterModule, Routes} from '@angular/router';
|
|
4
|
+
import {HitReceiptFromProductionsComponent} from "./hit-receipt-from-productions.component";
|
|
5
|
+
|
|
6
|
+
const routes: Routes = [
|
|
7
|
+
{
|
|
8
|
+
path: '',
|
|
9
|
+
component: HitReceiptFromProductionsComponent,
|
|
10
|
+
canActivate: [AuthGuard, PermissionGuard],
|
|
11
|
+
},
|
|
12
|
+
];
|
|
13
|
+
|
|
14
|
+
@NgModule({
|
|
15
|
+
imports: [RouterModule.forChild(routes)],
|
|
16
|
+
exports: [RouterModule],
|
|
17
|
+
})
|
|
18
|
+
export class HitReceiptFromProductionRoutingModule {
|
|
19
|
+
}
|
package/src/lib/components/hit-receipt-from-productions/hit-receipt-from-productions.component.html
ADDED
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
<abp-page [breadcrumb]="false" style="padding: 0;">
|
|
2
|
+
<abp-page-toolbar-container class="col">
|
|
3
|
+
<div class="row">
|
|
4
|
+
<h3 class="page-title">
|
|
5
|
+
{{ 'UretimYonetimi::ReceiptFromProductions.Title' | abpLocalization }}
|
|
6
|
+
</h3>
|
|
7
|
+
</div>
|
|
8
|
+
<div class="row text-lg-end pt-2">
|
|
9
|
+
<div class="col-8">
|
|
10
|
+
<button class="btn btn-success btn-sm" type="button"
|
|
11
|
+
(click)="postReceiptFromProductions()"
|
|
12
|
+
[disabled]="!isProductionOrderValid">
|
|
13
|
+
<i class="fa fa-plus me-1" aria-hidden="true"></i>
|
|
14
|
+
{{ 'UretimYonetimi::ReceiptFromProductions.Create' | abpLocalization }}
|
|
15
|
+
</button>
|
|
16
|
+
</div>
|
|
17
|
+
<div class="col-4">
|
|
18
|
+
<button class="btn btn-warning btn-sm" type="button" (click)="clearAll()">
|
|
19
|
+
<i class="fa fa-broom me-1" aria-hidden="true"></i>
|
|
20
|
+
{{ 'UretimYonetimi::ReceiptFromProductions.Clean' | abpLocalization }}
|
|
21
|
+
</button>
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
24
|
+
</abp-page-toolbar-container>
|
|
25
|
+
<div class="card">
|
|
26
|
+
<div class="card-body">
|
|
27
|
+
<div style="display: flex; align-items: center;">
|
|
28
|
+
<dx-number-box class="me-1 w-100"
|
|
29
|
+
#barkodNumarasiRef
|
|
30
|
+
[label]="'UretimYonetimi::ReceiptFromProductions.WorkOrderNo' | abpLocalization"
|
|
31
|
+
[(value)]="barkodNumarasi"
|
|
32
|
+
(onChange)="getProductionOrder()"
|
|
33
|
+
(onEnterKey)="getProductionOrder()"
|
|
34
|
+
[disabled]="searcheBasildiMi || isProductionOrderValid">
|
|
35
|
+
</dx-number-box>
|
|
36
|
+
<dx-button style="margin-top: 7.5px;" icon="search" type="default"
|
|
37
|
+
(onClick)="getProductionOrder()"
|
|
38
|
+
[disabled]="searcheBasildiMi || isProductionOrderValid">
|
|
39
|
+
</dx-button>
|
|
40
|
+
</div>
|
|
41
|
+
<div *ngIf="isProductionOrderValid">
|
|
42
|
+
<dx-text-box [label]="'UretimYonetimi::ReceiptFromProductions.StokCode' | abpLocalization"
|
|
43
|
+
[(value)]="productionOrder.itemNo"
|
|
44
|
+
[disabled]="true">
|
|
45
|
+
</dx-text-box>
|
|
46
|
+
|
|
47
|
+
<dx-text-box [label]="'UretimYonetimi::ReceiptFromProductions.StokDesc' | abpLocalization"
|
|
48
|
+
[(value)]="productionOrder.productDescription"
|
|
49
|
+
[maxLength]="128" [disabled]="true">
|
|
50
|
+
</dx-text-box>
|
|
51
|
+
|
|
52
|
+
<dx-text-box [label]="'UretimYonetimi::ReceiptFromProductions.ToWhs' | abpLocalization" [maxLength]="128"
|
|
53
|
+
[value]="getWarehouseName(receiptFromProductionsPostDtoDocumentLine.warehouseCode)"
|
|
54
|
+
[disabled]="true">
|
|
55
|
+
</dx-text-box>
|
|
56
|
+
|
|
57
|
+
<dx-text-box [label]="'UretimYonetimi::ReceiptFromProductions.BatchNumber' | abpLocalization"
|
|
58
|
+
[(value)]="receiptFromProductionsPostDtoBatchNumber.batchNumber"
|
|
59
|
+
[maxLength]="128" [disabled]="true">
|
|
60
|
+
</dx-text-box>
|
|
61
|
+
|
|
62
|
+
<dx-number-box [label]="'UretimYonetimi::ReceiptFromProductions.PlannedQty' | abpLocalization"
|
|
63
|
+
[(value)]="productionOrder.plannedQuantity"
|
|
64
|
+
[format]="HitHelper.getMeasurementFormatted(unitOfMeasure)"
|
|
65
|
+
[disabled]="true">
|
|
66
|
+
</dx-number-box>
|
|
67
|
+
|
|
68
|
+
<dx-number-box [label]="'UretimYonetimi::ReceiptFromProductions.CompletedQty' | abpLocalization"
|
|
69
|
+
[(value)]="productionOrder.completedQuantity"
|
|
70
|
+
[format]="HitHelper.getMeasurementFormatted(unitOfMeasure)"
|
|
71
|
+
[disabled]="true">
|
|
72
|
+
</dx-number-box>
|
|
73
|
+
|
|
74
|
+
<dx-number-box [label]="'UretimYonetimi::ReceiptFromProductions.Quantity' | abpLocalization"
|
|
75
|
+
[(value)]="receiptFromProductionsPostDtoBatchNumber.quantity"
|
|
76
|
+
(onValueChanged)="quantityChanged($event)"
|
|
77
|
+
[format]="HitHelper.getMeasurementFormatted(unitOfMeasure)"
|
|
78
|
+
[showSpinButtons]="true" [min]="0" #toplananMiktarRef>
|
|
79
|
+
</dx-number-box>
|
|
80
|
+
</div>
|
|
81
|
+
</div>
|
|
82
|
+
</div>
|
|
83
|
+
</abp-page>
|
|
84
|
+
|
|
85
|
+
<abp-modal [(visible)]="showModal" (appear)="generateReport()" (disappear)="clearAll()">
|
|
86
|
+
<ng-template #abpHeader>
|
|
87
|
+
<h3>{{ 'UretimYonetimi::CreateBarcodes.BarcodePreview' | abpLocalization }}</h3>
|
|
88
|
+
</ng-template>
|
|
89
|
+
<ng-template #abpBody>
|
|
90
|
+
<iframe *ngIf="pdfSrc" [src]="pdfSrc" width="100%" height="300"
|
|
91
|
+
webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>
|
|
92
|
+
</ng-template>
|
|
93
|
+
<ng-template #abpFooter>
|
|
94
|
+
<button (click)="downloadPdf(blobUrl)" type="button"
|
|
95
|
+
class="btn btn-secondary mobilde-gorunur" abpClose> İndir
|
|
96
|
+
</button>
|
|
97
|
+
<button type="button"
|
|
98
|
+
class="btn btn-secondary" abpClose> {{ 'UretimYonetimi::CreateBarcodes.Close' | abpLocalization }}
|
|
99
|
+
</button>
|
|
100
|
+
</ng-template>
|
|
101
|
+
</abp-modal>
|