seimin 3 gadi atpakaļ
vecāks
revīzija
c9a2891c61

+ 5 - 3
src/app/views/pharmacy/pharmacy.component.html

@@ -58,7 +58,8 @@
58 58
                 <span>{{item.drugsState?item.drugsState.name:''}}</span>
59 59
               </div>
60 60
               <div class="pharmacy-main__selectionItem">
61
-                <span>记账时间:{{item.creatTime|dateTransform}}</span>
61
+                <!-- <span>记账:{{item.bagTime|dateTransform}}</span> -->
62
+                <span><ng-container *ngIf="item.bagTime">记账时间:{{item.bagTime}}</ng-container></span>
62 63
                 <!-- <span>批次&emsp;<em>{{item.batchNo}}</em></span> -->
63 64
               </div>
64 65
             </div>
@@ -118,8 +119,9 @@
118 119
                 <span>{{item.drugsState?item.drugsState.name:''}}</span>
119 120
               </div>
120 121
               <div class="pharmacy-main__selectionItem">
121
-                <span>记账时间:{{item.creatTime|dateTransform}}</span>
122
+                <span><ng-container *ngIf="item.bagTime">记账时间:{{item.bagTime}}</ng-container></span>
122 123
                 <!-- <span>批次&emsp;<em>{{item.batchNo}}</em></span> -->
124
+                <span><ng-container *ngIf="item.startDispensingTime">开始配药时间:{{item.startDispensingTime}}</ng-container></span>
123 125
               </div>
124 126
             </div>
125 127
             <!-- <div class="pharmacy-main__selectionPrint">
@@ -178,7 +180,7 @@
178 180
                 <span>{{item.drugsState?item.drugsState.name:''}}</span>
179 181
               </div>
180 182
               <div class="pharmacy-main__selectionItem">
181
-                <span>配送人员:{{item.deliveryUser?item.deliveryUser.name:''}}({{item.deliveryUser?item.deliveryUser.phone:''}})</span>
183
+                <span *ngIf="item.deliveryUser">配送人员:{{item.deliveryUser.name}}({{item.deliveryUser.phone}})</span>
182 184
                 <span></span>
183 185
               </div>
184 186
             </div>

+ 24 - 9
src/app/views/pharmacy/pharmacy.component.ts

@@ -139,10 +139,14 @@ export class PharmacyComponent implements OnInit {
139 139
                 this.printPharmacyFlag = true;
140 140
               }
141 141
               // 列表数据合并
142
-              this.printPharmacyList = [
143
-                ...this.printPharmacyList,
144
-                ...result["list"],
145
-              ];
142
+              if(idx === 0){
143
+                this.printPharmacyList = result["list"];
144
+              }else{
145
+                this.printPharmacyList = [
146
+                  ...this.printPharmacyList,
147
+                  ...result["list"],
148
+                ];
149
+              }
146 150
               break;
147 151
             case 2:
148 152
               this.waitPharmacyLoad = false;
@@ -153,10 +157,14 @@ export class PharmacyComponent implements OnInit {
153 157
               } else {
154 158
                 this.waitPharmacyFlag = true;
155 159
               }
156
-              this.waitPharmacyList = [
157
-                ...this.waitPharmacyList,
158
-                ...result["list"],
159
-              ];
160
+              if(idx === 0){
161
+                this.waitPharmacyList = result["list"];
162
+              }else{
163
+                this.waitPharmacyList = [
164
+                  ...this.waitPharmacyList,
165
+                  ...result["list"],
166
+                ];
167
+              }
160 168
               break;
161 169
             case 3:
162 170
               this.pharmacyLoad = false;
@@ -167,7 +175,14 @@ export class PharmacyComponent implements OnInit {
167 175
               } else {
168 176
                 this.pharmacyFlag = true;
169 177
               }
170
-              this.pharmacyList = [...this.pharmacyList, ...result["list"]];
178
+              if(idx === 0){
179
+                this.pharmacyList = result["list"];
180
+              }else{
181
+                this.pharmacyList = [
182
+                  ...this.pharmacyList,
183
+                  ...result["list"],
184
+                ];
185
+              }
171 186
               break;
172 187
           }
173 188
         }