seimin 3 年之前
父節點
當前提交
07080cf662
共有 1 個文件被更改,包括 8 次插入6 次删除
  1. 8 6
      src/app/views/inspect-active/inspect-active.component.ts

+ 8 - 6
src/app/views/inspect-active/inspect-active.component.ts

@@ -104,15 +104,17 @@ export class InspectActiveComponent implements OnInit {
104
   // 导出
104
   // 导出
105
   loading2 = false;
105
   loading2 = false;
106
   export() {
106
   export() {
107
-    let that = this;
107
+    let postData: any = {
108
-    let postData = {
108
+      type: "total",
109
-      hosId: that.hospital,
109
+      hosId: this.hospital,
110
       startTime: this.startDate + " " + "00:00:00",
110
       startTime: this.startDate + " " + "00:00:00",
111
       endTime: this.endDate + " " + "23:59:59",
111
       endTime: this.endDate + " " + "23:59:59",
112
-      groupId: that.dept || "",
113
     };
112
     };
113
+    if (this.dept !== 0) {
114
+      postData.deptId = this.dept;
115
+    }
114
     this.loading2 = true;
116
     this.loading2 = true;
115
-    that.mainService.exportReport("user", postData).subscribe(
117
+    this.mainService.exportReport("deptInspect", postData).subscribe(
116
       (data) => {
118
       (data) => {
117
         this.loading2 = false;
119
         this.loading2 = false;
118
         this.showPromptModal("导出", true, "");
120
         this.showPromptModal("导出", true, "");
@@ -124,7 +126,7 @@ export class InspectActiveComponent implements OnInit {
124
         var a = document.createElement("a");
126
         var a = document.createElement("a");
125
         a.href = fileURL;
127
         a.href = fileURL;
126
         a.target = "_blank";
128
         a.target = "_blank";
127
-        a.download = "支助人员统计.xls";
129
+        a.download = "人员检查主动服务统计.xls";
128
         document.body.appendChild(a);
130
         document.body.appendChild(a);
129
         a.click();
131
         a.click();
130
       },
132
       },