-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathreturn.component.html
More file actions
215 lines (169 loc) · 7 KB
/
Copy pathreturn.component.html
File metadata and controls
215 lines (169 loc) · 7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
<div style="padding-left: 10px;padding-top: 10px;padding-right: 10px;margin-bottom: 10px;
">
<div class="fixHeader" id="myHeader">
<mat-card style="background-color: #03a9f4; color:white; padding:7px;">
<mat-card-title style= "font-size:19px;font-weight:bold">RETURN MANAGEMENT
<!-- <button style="margin-left: 100vh;" class="btn btn-primary mat-ripple" md-ripple="reset" (click)="reset()">RESET</button>
<button class="btn btn-primary mat-ripple" md-ripple="submit" (click)="save(VendorForm.value)">save</button> -->
<button style="margin-right: 10px;
float: right;
background-color: white;
color: black !important;margin-top:-5px"
class="btn btn-primary mat-ripple" md-ripple="submit" (click)="open(basic)">Save</button>
<!-- <button style="margin-right: 10px;
float: right;
background-color: white;
color: black !important; "
class="btn btn-primary mat-ripple" class="btn btn-primary mat-ripple" md-ripple="submit" (click)="save();">save</button> -->
</mat-card-title>
</mat-card>
</div>
</div>
<div class="content">
<div style="padding-left:10px;padding-right:10px">
<mat-card style="max-height: 150px; padding-top: 5px">
<!--form class="form-horizontal" class="form-inline">-->
<div class="row">
<div class=" col-lg-3 col-md-4 col-sm-4">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="billDetail.billNo" maxlength="9" matInput (keydown.enter)="getBillDetails($event)" placeholder="Bill No#"
type="text">
</mat-form-field>
</div>
</div>
</div>
<div class=" col-lg-3 col-md-4 col-sm-4">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="billDetail.billDate" matInput readonly placeholder="BillDate" type="text">
</mat-form-field>
</div>
</div>
</div>
<div class=" col-lg-3 col-md-4 col-sm-4">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="billDetail.name" matInput readonly placeholder="Name" type="text">
</mat-form-field>
</div>
</div>
</div>
<div class=" col-lg-3 col-md-4 col-sm-4">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="billDetail.regId" maxlength="10" matInput readonly placeholder="Register No" type="text">
</mat-form-field>
</div>
</div>
</div>
<div class=" col-lg-3 col-md-4 col-sm-4">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="billDetail.mobile" matInput readonly placeholder="Mobile Number" type="text">
</mat-form-field>
</div>
</div>
</div>
<div class=" col-lg-3 col-md-4 col-sm-4">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="billDetail.location" matInput readonly placeholder="Location" type="text">
</mat-form-field>
</div>
</div>
</div>
</div>
<!--/form>-->
</mat-card>
</div>
<div style="padding-left:10px;padding-right:10px">
<table width="100%" class="table table-bordered" style="overflow-y: scroll;">
<tr style="background:#03a9f4;color:whitesmoke">
<th>Sno</th>
<th>Medicine Name</th>
<th>Purchased Quantity</th>
<th>Return Quantity</th>
<th>Discount%</th>
<th>Return Amount</th>
<th>GST</th>
</tr>
<!-- {{newReturn.refSalesReturns|json}} -->
<tr *ngFor="let sale of newReturn.refSalesReturns;let i= index">
<td> {{i + 1}}</td>
<td>
<input [(ngModel)]="sale.medicineName" placeholder="Medicine Name" matInput type="text" readonly>
</td>
<td>
<input [(ngModel)]="sale.org_quantity" readonly matInput type="number">
</td>
<td>
<input [(ngModel)]="sale.quantity" #quantity matInput type="number" (change)="calcAmount(sale)" placeholder="Quantity">
<div class="text text-danger" *ngIf="sale.quantity_error">Quantity should not exceed {{sale.org_quantity}}</div>
</td>
<td>
<input [(ngModel)]="sale.discount" readonly matInput placeholder="discount" type="number">
</td>
<td>
<input [value]="sale.amount || 0" matInput placeholder="Amount" type="text" readonly>
</td>
<td>
<input [(ngModel)]="sale.gst" matInput placeholder="GST" type="text" readonly>
</td>
</tr>
</table>
</div>
<ng-template #basic let-modal>
<div class="modal-header">
<h4 class="modal-title" id="modal-basic-title">PAYMENT PAGE</h4>
<button type="button" class="close" aria-label="Close" (click)="modal.dismiss('Cross click')">
<span aria-hidden="true">×</span>
</button>
</div>
<div class="modal-body">
<!-- <div class="col-lg-6 col-md-6 col-sm-12">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="billDetail.paymentType" matInput placeholder="SalesPayment type" type="text">
</mat-form-field>
</div>
</div>
</div> -->
<div class="col-lg-6 col-md-6 col-sm-12">
<div class="form-group ">
<div class="col-xl">
<label>Payment Type</label>
<select [(ngModel)]="this.newReturn.paymentType" style="width:200px">
<!-- *ngIf="billDetail.paymentType !='Due'"
<option *ngIf="billDetail.paymentType =='Due'" value="Advance">Advance</option> -->
<option value="Due">Due</option>
<option value="Cash">Cash</option>
<option value="Card">Card</option>
<option value="Cash+Card">Cash+Card</option>
</select>
</div>
</div>
</div>
<h1 style="padding-left:300px"> Total:{{total}}</h1>
<!-- <div class="col-lg-6 col-md-6 col-sm-12">
<div class="form-group ">
<div class="col-xl">
<mat-form-field>
<input [(ngModel)]="amount" matInput placeholder="SalesPayment type" type="text">
</mat-form-field>
</div>
</div>
</div> -->
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger mat-ripple" (click)="modal.close('Save click')">No</button>
<button class="btn btn-primary mat-ripple" md-ripple="submit" (click)="save()" [disabled]="saveInProgress">Save</button>
</div>
</ng-template>