Răsfoiți Sursa

init:commit

未来全栈 4 luni în urmă
părinte
comite
9d0da551ab
100 a modificat fișierele cu 4387 adăugiri și 111 ștergeri
  1. 2 1
      angular.json
  2. 113 0
      package-lock.json
  3. 6 0
      package.json
  4. 1 1
      src/app/app.component.html
  5. 6 0
      src/app/app.component.scss
  6. 0 21
      src/app/app.component.spec.ts
  7. 59 2
      src/app/app.component.ts
  8. 64 5
      src/app/app.module.ts
  9. 0 4
      src/app/explore-container/explore-container.component.html
  10. 0 27
      src/app/explore-container/explore-container.component.scss
  11. 0 24
      src/app/explore-container/explore-container.component.spec.ts
  12. 0 12
      src/app/explore-container/explore-container.component.ts
  13. 0 14
      src/app/explore-container/explore-container.module.ts
  14. 28 0
      src/app/func/balancesummary/balancesummary.module.ts
  15. 32 0
      src/app/func/balancesummary/balancesummary.page.html
  16. 0 0
      src/app/func/balancesummary/balancesummary.page.scss
  17. 42 0
      src/app/func/balancesummary/balancesummary.page.ts
  18. 31 0
      src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.module.ts
  19. 47 0
      src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.page.html
  20. 0 0
      src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.page.scss
  21. 144 0
      src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.page.ts
  22. 28 0
      src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.module.ts
  23. 45 0
      src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.page.html
  24. 0 0
      src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.page.scss
  25. 144 0
      src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.page.ts
  26. 50 0
      src/app/func/balancesummary/rubber-balance-summary.service.ts
  27. 28 0
      src/app/func/chanliang/chanliang.module.ts
  28. 65 0
      src/app/func/chanliang/chanliang.page.html
  29. 0 0
      src/app/func/chanliang/chanliang.page.scss
  30. 146 0
      src/app/func/chanliang/chanliang.page.ts
  31. 31 0
      src/app/func/chanliang/rubber-product-chart/rubber-product-chart.module.ts
  32. 43 0
      src/app/func/chanliang/rubber-product-chart/rubber-product-chart.page.html
  33. 0 0
      src/app/func/chanliang/rubber-product-chart/rubber-product-chart.page.scss
  34. 127 0
      src/app/func/chanliang/rubber-product-chart/rubber-product-chart.page.ts
  35. 33 0
      src/app/func/chanliang/rubber-product-chart/rubber-product-chart.service.ts
  36. 28 0
      src/app/func/chanliang/rubber-product-result/rubber-product-result.module.ts
  37. 45 0
      src/app/func/chanliang/rubber-product-result/rubber-product-result.page.html
  38. 0 0
      src/app/func/chanliang/rubber-product-result/rubber-product-result.page.scss
  39. 159 0
      src/app/func/chanliang/rubber-product-result/rubber-product-result.page.ts
  40. 38 0
      src/app/func/chanliang/rubber-product-result/rubber-product-result.service.ts
  41. 28 0
      src/app/func/chaoqi/chaoqi.module.ts
  42. 42 0
      src/app/func/chaoqi/chaoqi.page.html
  43. 0 0
      src/app/func/chaoqi/chaoqi.page.scss
  44. 71 0
      src/app/func/chaoqi/chaoqi.page.ts
  45. 31 0
      src/app/func/chaoqi/out-valid-chart/out-valid-chart.module.ts
  46. 90 0
      src/app/func/chaoqi/out-valid-chart/out-valid-chart.page.html
  47. 0 0
      src/app/func/chaoqi/out-valid-chart/out-valid-chart.page.scss
  48. 161 0
      src/app/func/chaoqi/out-valid-chart/out-valid-chart.page.ts
  49. 28 0
      src/app/func/chaoqi/out-valid-result/out-valid-result.module.ts
  50. 48 0
      src/app/func/chaoqi/out-valid-result/out-valid-result.page.html
  51. 0 0
      src/app/func/chaoqi/out-valid-result/out-valid-result.page.scss
  52. 162 0
      src/app/func/chaoqi/out-valid-result/out-valid-result.page.ts
  53. 48 0
      src/app/func/chaoqi/out-valid.service.ts
  54. 28 0
      src/app/func/chuku/chuku.module.ts
  55. 29 0
      src/app/func/chuku/chuku.page.html
  56. 0 0
      src/app/func/chuku/chuku.page.scss
  57. 45 0
      src/app/func/chuku/chuku.page.ts
  58. 31 0
      src/app/func/chuku/out-stock-chart/out-stock-chart.module.ts
  59. 76 0
      src/app/func/chuku/out-stock-chart/out-stock-chart.page.html
  60. 0 0
      src/app/func/chuku/out-stock-chart/out-stock-chart.page.scss
  61. 163 0
      src/app/func/chuku/out-stock-chart/out-stock-chart.page.ts
  62. 28 0
      src/app/func/chuku/out-stock-result/out-stock-result.module.ts
  63. 41 0
      src/app/func/chuku/out-stock-result/out-stock-result.page.html
  64. 0 0
      src/app/func/chuku/out-stock-result/out-stock-result.page.scss
  65. 138 0
      src/app/func/chuku/out-stock-result/out-stock-result.page.ts
  66. 64 0
      src/app/func/chuku/out-stock.service.ts
  67. 19 0
      src/app/func/func.module.ts
  68. 83 0
      src/app/func/func.page.html
  69. 5 0
      src/app/func/func.page.scss
  70. 35 0
      src/app/func/func.page.ts
  71. 24 0
      src/app/func/func.service.ts
  72. 28 0
      src/app/func/hegefenxi/hegefenxi.module.ts
  73. 26 0
      src/app/func/hegefenxi/hegefenxi.page.html
  74. 0 0
      src/app/func/hegefenxi/hegefenxi.page.scss
  75. 29 0
      src/app/func/hegefenxi/hegefenxi.page.ts
  76. 26 0
      src/app/func/hegefenxi/hegefenxi.service.ts
  77. 26 0
      src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.module.ts
  78. 74 0
      src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.page.html
  79. 0 0
      src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.page.scss
  80. 112 0
      src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.page.ts
  81. 26 0
      src/app/func/jiance/fast-exam-chart/fast-exam-chart.module.ts
  82. 70 0
      src/app/func/jiance/fast-exam-chart/fast-exam-chart.page.html
  83. 0 0
      src/app/func/jiance/fast-exam-chart/fast-exam-chart.page.scss
  84. 156 0
      src/app/func/jiance/fast-exam-chart/fast-exam-chart.page.ts
  85. 25 0
      src/app/func/jiance/fast-exam-result/fast-exam-result.module.ts
  86. 62 0
      src/app/func/jiance/fast-exam-result/fast-exam-result.page.html
  87. 0 0
      src/app/func/jiance/fast-exam-result/fast-exam-result.page.scss
  88. 108 0
      src/app/func/jiance/fast-exam-result/fast-exam-result.page.ts
  89. 28 0
      src/app/func/jiance/jiance.module.ts
  90. 57 0
      src/app/func/jiance/jiance.page.html
  91. 0 0
      src/app/func/jiance/jiance.page.scss
  92. 158 0
      src/app/func/jiance/jiance.page.ts
  93. 50 0
      src/app/func/jiance/jiance.service.ts
  94. 28 0
      src/app/func/jihua/jihua.module.ts
  95. 33 0
      src/app/func/jihua/jihua.page.html
  96. 0 0
      src/app/func/jihua/jihua.page.scss
  97. 93 0
      src/app/func/jihua/jihua.page.ts
  98. 33 0
      src/app/func/jihua/jihua.service.ts
  99. 27 0
      src/app/func/jihua/plan-exec-monitor-chart/plan-exec-monitor-chart.module.ts
  100. 9 0
      src/app/func/jihua/plan-exec-monitor-chart/plan-exec-monitor-chart.page.html

+ 2 - 1
angular.json

@@ -136,7 +136,8 @@
   "cli": {
     "schematicCollections": [
       "@ionic/angular-toolkit"
-    ]
+    ],
+    "analytics": "b9c89391-c4e9-4ab9-a287-048afd48b937"
   },
   "schematics": {
     "@ionic/angular-toolkit:component": {

+ 113 - 0
package-lock.json

@@ -22,7 +22,13 @@
         "@capacitor/keyboard": "6.0.1",
         "@capacitor/status-bar": "6.0.0",
         "@ionic/angular": "^8.0.0",
+        "@ionic/storage": "^4.0.0",
+        "@ngx-translate/core": "^15.0.0",
+        "@ngx-translate/http-loader": "^8.0.0",
+        "dingtalk-jsapi": "^3.0.36",
+        "echarts": "^5.5.1",
         "ionicons": "^7.0.0",
+        "ngx-echarts": "^18.0.0",
         "rxjs": "~7.8.0",
         "tslib": "^2.3.0",
         "zone.js": "~0.14.2"
@@ -3712,6 +3718,14 @@
         "tslib": "^2.1.0"
       }
     },
+    "node_modules/@ionic/storage": {
+      "version": "4.0.0",
+      "resolved": "https://registry.npmmirror.com/@ionic/storage/-/storage-4.0.0.tgz",
+      "integrity": "sha512-3N21P19Xk6cICLnSXZ3ilRqbSXAGSFeIF3HNqz+1kARcm0UFT/vwmZreaXtFyq437vvEWOfJ2enlj3JHLKS0FA==",
+      "dependencies": {
+        "localforage": "^1.9.0"
+      }
+    },
     "node_modules/@ionic/utils-array": {
       "version": "2.1.5",
       "resolved": "https://registry.npmmirror.com/@ionic/utils-array/-/utils-array-2.1.5.tgz",
@@ -4549,6 +4563,33 @@
         "webpack": "^5.54.0"
       }
     },
+    "node_modules/@ngx-translate/core": {
+      "version": "15.0.0",
+      "resolved": "https://registry.npmmirror.com/@ngx-translate/core/-/core-15.0.0.tgz",
+      "integrity": "sha512-Am5uiuR0bOOxyoercDnAA3rJVizo4RRqJHo8N3RqJ+XfzVP/I845yEnMADykOHvM6HkVm4SZSnJBOiz0Anx5BA==",
+      "engines": {
+        "node": "^16.13.0 || >=18.10.0"
+      },
+      "peerDependencies": {
+        "@angular/common": ">=16.0.0",
+        "@angular/core": ">=16.0.0",
+        "rxjs": "^6.5.5 || ^7.4.0"
+      }
+    },
+    "node_modules/@ngx-translate/http-loader": {
+      "version": "8.0.0",
+      "resolved": "https://registry.npmmirror.com/@ngx-translate/http-loader/-/http-loader-8.0.0.tgz",
+      "integrity": "sha512-SFMsdUcmHF5OdZkL1CHEoSAwbP5EbAOPTLLboOCRRoOg21P4GJx+51jxGdJeGve6LSKLf4Pay7BkTwmE6vxYlg==",
+      "engines": {
+        "node": "^16.13.0 || >=18.10.0"
+      },
+      "peerDependencies": {
+        "@angular/common": ">=16.0.0",
+        "@angular/core": ">=16.0.0",
+        "@ngx-translate/core": ">=15.0.0",
+        "rxjs": "^6.5.5 || ^7.4.0"
+      }
+    },
     "node_modules/@nodelib/fs.scandir": {
       "version": "2.1.5",
       "resolved": "https://registry.npmmirror.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
@@ -8221,6 +8262,14 @@
         "node": "^14.15.0 || ^16.10.0 || >=18.0.0"
       }
     },
+    "node_modules/dingtalk-jsapi": {
+      "version": "3.0.36",
+      "resolved": "https://registry.npmmirror.com/dingtalk-jsapi/-/dingtalk-jsapi-3.0.36.tgz",
+      "integrity": "sha512-oGDNwqpOzRtMifY/POqPvsLRUYpt/csw7mBfczFzRaPHYyezj7JPGkBybCNW/PA/4DvVIAe+RJEkM3cdtVHFtA==",
+      "dependencies": {
+        "promise-polyfill": "^7.1.0"
+      }
+    },
     "node_modules/dir-glob": {
       "version": "3.0.1",
       "resolved": "https://registry.npmmirror.com/dir-glob/-/dir-glob-3.0.1.tgz",
@@ -8363,6 +8412,20 @@
       "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==",
       "dev": true
     },
+    "node_modules/echarts": {
+      "version": "5.5.1",
+      "resolved": "https://registry.npmmirror.com/echarts/-/echarts-5.5.1.tgz",
+      "integrity": "sha512-Fce8upazaAXUVUVsjgV6mBnGuqgO+JNDlcgF79Dksy4+wgGpQB2lmYoO4TSweFg/mZITdpGHomw/cNBJZj1icA==",
+      "dependencies": {
+        "tslib": "2.3.0",
+        "zrender": "5.6.0"
+      }
+    },
+    "node_modules/echarts/node_modules/tslib": {
+      "version": "2.3.0",
+      "resolved": "https://registry.npmmirror.com/tslib/-/tslib-2.3.0.tgz",
+      "integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg=="
+    },
     "node_modules/ee-first": {
       "version": "1.1.1",
       "resolved": "https://registry.npmmirror.com/ee-first/-/ee-first-1.1.1.tgz",
@@ -10530,6 +10593,11 @@
         "node": ">=0.10.0"
       }
     },
+    "node_modules/immediate": {
+      "version": "3.0.6",
+      "resolved": "https://registry.npmmirror.com/immediate/-/immediate-3.0.6.tgz",
+      "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ=="
+    },
     "node_modules/immutable": {
       "version": "4.3.6",
       "resolved": "https://registry.npmmirror.com/immutable/-/immutable-4.3.6.tgz",
@@ -12052,6 +12120,14 @@
         }
       }
     },
+    "node_modules/lie": {
+      "version": "3.1.1",
+      "resolved": "https://registry.npmmirror.com/lie/-/lie-3.1.1.tgz",
+      "integrity": "sha512-RiNhHysUjhrDQntfYSfY4MU24coXXdEOgw9WGcKHNeEwffDYbF//u87M1EWaMGzuFoSbqW0C9C6lEEhDOAswfw==",
+      "dependencies": {
+        "immediate": "~3.0.5"
+      }
+    },
     "node_modules/lines-and-columns": {
       "version": "2.0.4",
       "resolved": "https://registry.npmmirror.com/lines-and-columns/-/lines-and-columns-2.0.4.tgz",
@@ -12183,6 +12259,14 @@
         "node": ">= 12.13.0"
       }
     },
+    "node_modules/localforage": {
+      "version": "1.10.0",
+      "resolved": "https://registry.npmmirror.com/localforage/-/localforage-1.10.0.tgz",
+      "integrity": "sha512-14/H1aX7hzBBmmh7sGPd+AOMkkIrHM3Z1PAyGgZigA1H1p5O5ANnMyWzvpAETtG68/dC4pC0ncy3+PPGzXZHPg==",
+      "dependencies": {
+        "lie": "3.1.1"
+      }
+    },
     "node_modules/locate-path": {
       "version": "6.0.0",
       "resolved": "https://registry.npmmirror.com/locate-path/-/locate-path-6.0.0.tgz",
@@ -13000,6 +13084,17 @@
       "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==",
       "dev": true
     },
+    "node_modules/ngx-echarts": {
+      "version": "18.0.0",
+      "resolved": "https://registry.npmmirror.com/ngx-echarts/-/ngx-echarts-18.0.0.tgz",
+      "integrity": "sha512-1rJW7vhMTTQMZNO5AhbHfTDorhP7dcvwRsDH5jFk2SPb/gjIFWvXBY9VSNAOKumuSBnopm2+uSz6BRO5oWxovA==",
+      "dependencies": {
+        "tslib": "^2.3.0"
+      },
+      "peerDependencies": {
+        "echarts": ">=5.0.0"
+      }
+    },
     "node_modules/nice-napi": {
       "version": "1.0.2",
       "resolved": "https://registry.npmmirror.com/nice-napi/-/nice-napi-1.0.2.tgz",
@@ -14604,6 +14699,11 @@
       "integrity": "sha512-6zWPyEOFaQBJYcGMHBKTKJ3u6TBsnMFOIZSa6ce1e/ZrrsOlnHRHbabMjLiBYKp+n44X9eUI6VUPaukCXHuG4g==",
       "dev": true
     },
+    "node_modules/promise-polyfill": {
+      "version": "7.1.2",
+      "resolved": "https://registry.npmmirror.com/promise-polyfill/-/promise-polyfill-7.1.2.tgz",
+      "integrity": "sha512-FuEc12/eKqqoRYIGBrUptCBRhobL19PS2U31vMNTfyck1FxPyMfgsXyW4Mav85y/ZN1hop3hOwRlUDok23oYfQ=="
+    },
     "node_modules/promise-retry": {
       "version": "2.0.1",
       "resolved": "https://registry.npmmirror.com/promise-retry/-/promise-retry-2.0.1.tgz",
@@ -17816,6 +17916,19 @@
       "version": "0.14.7",
       "resolved": "https://registry.npmmirror.com/zone.js/-/zone.js-0.14.7.tgz",
       "integrity": "sha512-0w6DGkX2BPuiK/NLf+4A8FLE43QwBfuqz2dVgi/40Rj1WmqUskCqj329O/pwrqFJLG5X8wkeG2RhIAro441xtg=="
+    },
+    "node_modules/zrender": {
+      "version": "5.6.0",
+      "resolved": "https://registry.npmmirror.com/zrender/-/zrender-5.6.0.tgz",
+      "integrity": "sha512-uzgraf4njmmHAbEUxMJ8Oxg+P3fT04O+9p7gY+wJRVxo8Ge+KmYv0WJev945EH4wFuc4OY2NLXz46FZrWS9xJg==",
+      "dependencies": {
+        "tslib": "2.3.0"
+      }
+    },
+    "node_modules/zrender/node_modules/tslib": {
+      "version": "2.3.0",
+      "resolved": "https://registry.npmmirror.com/tslib/-/tslib-2.3.0.tgz",
+      "integrity": "sha512-N82ooyxVNm6h1riLCoyS9e3fuJ3AMG2zIZs2Gd1ATcSFjSA23Q0fzjjZeh0jbJvWVDZ0cJT8yaNNaaXHzueNjg=="
     }
   }
 }

+ 6 - 0
package.json

@@ -27,7 +27,13 @@
     "@capacitor/keyboard": "6.0.1",
     "@capacitor/status-bar": "6.0.0",
     "@ionic/angular": "^8.0.0",
+    "@ionic/storage": "^4.0.0",
+    "@ngx-translate/core": "^15.0.0",
+    "@ngx-translate/http-loader": "^8.0.0",
+    "dingtalk-jsapi": "^3.0.36",
+    "echarts": "^5.5.1",
     "ionicons": "^7.0.0",
+    "ngx-echarts": "^18.0.0",
     "rxjs": "~7.8.0",
     "tslib": "^2.3.0",
     "zone.js": "~0.14.2"

+ 1 - 1
src/app/app.component.html

@@ -1,3 +1,3 @@
-<ion-app>
+<ion-app [class]="selectedTheme">
   <ion-router-outlet></ion-router-outlet>
 </ion-app>

+ 6 - 0
src/app/app.component.scss

@@ -0,0 +1,6 @@
+// App Styles
+// ----------------------------------------------------------------------------
+// Put style rules here that you want to apply to the entire application. These 
+// styles are for the entire app and not just one component. Additionally, this 
+// file can hold Sass mixins, functions, and placeholder classes to be imported 
+// and used throughout the application.

+ 0 - 21
src/app/app.component.spec.ts

@@ -1,21 +0,0 @@
-import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
-import { TestBed } from '@angular/core/testing';
-
-import { AppComponent } from './app.component';
-
-describe('AppComponent', () => {
-
-  beforeEach(async () => {
-    await TestBed.configureTestingModule({
-      declarations: [AppComponent],
-      schemas: [CUSTOM_ELEMENTS_SCHEMA],
-    }).compileComponents();
-  });
-
-  it('should create the app', () => {
-    const fixture = TestBed.createComponent(AppComponent);
-    const app = fixture.componentInstance;
-    expect(app).toBeTruthy();
-  });
-
-});

+ 59 - 2
src/app/app.component.ts

@@ -1,10 +1,67 @@
 import { Component } from '@angular/core';
+import * as dd from 'dingtalk-jsapi';
+import { Platform } from '@ionic/angular';
+import { SplashScreen } from '@ionic-native/splash-screen/ngx';
+import { StatusBar } from '@ionic-native/status-bar/ngx';
+import { Storage } from '@ionic/storage';
+import { SettingsService } from './wongoing/settings.service';
+import { EnvService } from './wongoing/env.service';
 
 @Component({
   selector: 'app-root',
   templateUrl: 'app.component.html',
-  styleUrls: ['app.component.scss'],
+  styleUrls: ['app.component.scss']
 })
 export class AppComponent {
-  constructor() {}
+  selectedTheme: string;  // 保存当前主题样式名称
+  constructor(
+    private platform: Platform,
+    private splashScreen: SplashScreen,
+    private statusBar: StatusBar,
+    private settings: SettingsService,
+    private env: EnvService,
+    public storage: Storage
+  ) {
+    this.initializeApp();
+    /** 设置customerId的默认值 */
+    this.storage.set('customerId', '1').then(()=>{
+      console.log('storage item');
+    }).catch(error=>{
+      console.error('storage error', error);
+    });
+  }
+
+  /**
+   * 初始化应用方法
+   */
+  initializeApp() {
+    if (dd.env.platform == 'notInDingTalk') {
+      // 如果没在钉钉容器中运行,则显示头部导航条
+      this.env.IsShowHeader = true;
+    } else {
+      // 如果在钉钉容器中运行则隐藏头部导航条
+      this.env.IsShowHeader = false;
+    }
+    this.platform.ready().then(() => {
+      this.statusBar.styleDefault();
+      this.splashScreen.hide();
+      // 订阅可观察者对象
+      this.settings.getActiveTheme().subscribe(val => {
+        console.log('theme = ' + val);
+        const plats: any = this.platform.platforms();
+        if (plats.length > 0) {
+          console.log('platform = ' + plats[0]);
+          // 判断当前平台是android平台核实ios平台
+          if (plats[0] === 'android') {
+            this.selectedTheme = val + ' md ion-page hydrated';
+          } else {
+            this.selectedTheme = val + ' ios ion-page hydrated';
+          }
+        } else {
+          this.selectedTheme = val;
+        }
+        console.log('theme = ' + this.selectedTheme);
+      });
+    });
+  }
 }

+ 64 - 5
src/app/app.module.ts

@@ -2,15 +2,74 @@ import { NgModule } from '@angular/core';
 import { BrowserModule } from '@angular/platform-browser';
 import { RouteReuseStrategy } from '@angular/router';
 
-import { IonicModule, IonicRouteStrategy } from '@ionic/angular';
+import { LocationStrategy, HashLocationStrategy } from '@angular/common';
+
+import { IonicModule, IonicRouteStrategy, Platform } from '@ionic/angular';
+import { SplashScreen } from '@ionic-native/splash-screen/ngx';
+import { StatusBar } from '@ionic-native/status-bar/ngx';
+import { IonicStorageModule } from '@ionic/storage';
 
 import { AppRoutingModule } from './app-routing.module';
 import { AppComponent } from './app.component';
 
+import { HttpClient, HttpClientModule } from '@angular/common/http';
+import { TranslateLoader, TranslateModule, TranslateService } from '@ngx-translate/core';
+import { TranslateHttpLoader } from '@ngx-translate/http-loader';
+
+import { WongoingModule } from './wongoing/wongoing.module';
+
+/**
+ * 导出加载函数
+ * @param http HttpClient对象
+ */
+export function HttpLoaderFactory(http: HttpClient) {
+  return new TranslateHttpLoader(http, './assets/i18n/', '.json');
+}
+
 @NgModule({
   declarations: [AppComponent],
-  imports: [BrowserModule, IonicModule.forRoot(), AppRoutingModule],
-  providers: [{ provide: RouteReuseStrategy, useClass: IonicRouteStrategy }],
-  bootstrap: [AppComponent],
+  entryComponents: [],
+  imports: [BrowserModule, IonicModule.forRoot(), IonicStorageModule.forRoot(), AppRoutingModule, HttpClientModule,
+    TranslateModule.forRoot({
+      loader: {
+        provide: TranslateLoader,
+        useFactory: HttpLoaderFactory,
+        deps: [HttpClient]
+      }
+    }),
+    WongoingModule],
+  exports: [
+    TranslateModule
+  ],
+  providers: [
+    StatusBar,
+    SplashScreen,
+    TranslateService,
+    { provide: RouteReuseStrategy, useClass: IonicRouteStrategy },
+    { provide: LocationStrategy, useClass: HashLocationStrategy }
+  ],
+  bootstrap: [AppComponent]
 })
-export class AppModule {}
+export class AppModule {
+  // 默认语言
+  private lang: any = 'zh';
+
+  constructor(private platform: Platform, public translate: TranslateService) {
+    platform.ready().then(async () => {
+      this.initTranslateConfig();
+    });
+    console.log('App start...');
+  }
+
+  public initTranslateConfig() {
+    console.log('initTranslateConfig...');
+    // 添加要支持的语言
+    this.translate.addLangs(['zh', 'en']);
+    // 设置默认语言
+    this.translate.setDefaultLang(this.lang);
+    // 语言切换处理
+    this.translate.use(this.lang).subscribe(() => {
+      console.log('语言切换=' + this.lang);
+    });
+  }
+}

+ 0 - 4
src/app/explore-container/explore-container.component.html

@@ -1,4 +0,0 @@
-<div id="container">
-  <strong>{{ name }}</strong>
-  <p>Explore <a target="_blank" rel="noopener noreferrer" href="https://ionicframework.com/docs/components">UI Components</a></p>
-</div>

+ 0 - 27
src/app/explore-container/explore-container.component.scss

@@ -1,27 +0,0 @@
-#container {
-  text-align: center;
-
-  position: absolute;
-  left: 0;
-  right: 0;
-  top: 50%;
-  transform: translateY(-50%);
-}
-
-#container strong {
-  font-size: 20px;
-  line-height: 26px;
-}
-
-#container p {
-  font-size: 16px;
-  line-height: 22px;
-
-  color: #8c8c8c;
-
-  margin: 0;
-}
-
-#container a {
-  text-decoration: none;
-}

+ 0 - 24
src/app/explore-container/explore-container.component.spec.ts

@@ -1,24 +0,0 @@
-import { ComponentFixture, TestBed } from '@angular/core/testing';
-import { IonicModule } from '@ionic/angular';
-
-import { ExploreContainerComponent } from './explore-container.component';
-
-describe('ExploreContainerComponent', () => {
-  let component: ExploreContainerComponent;
-  let fixture: ComponentFixture<ExploreContainerComponent>;
-
-  beforeEach(async () => {
-    await TestBed.configureTestingModule({
-      declarations: [ExploreContainerComponent],
-      imports: [IonicModule.forRoot()]
-    }).compileComponents();
-
-    fixture = TestBed.createComponent(ExploreContainerComponent);
-    component = fixture.componentInstance;
-    fixture.detectChanges();
-  });
-
-  it('should create', () => {
-    expect(component).toBeTruthy();
-  });
-});

+ 0 - 12
src/app/explore-container/explore-container.component.ts

@@ -1,12 +0,0 @@
-import { Component, Input } from '@angular/core';
-
-@Component({
-  selector: 'app-explore-container',
-  templateUrl: './explore-container.component.html',
-  styleUrls: ['./explore-container.component.scss'],
-})
-export class ExploreContainerComponent {
-
-  @Input() name?: string;
-
-}

+ 0 - 14
src/app/explore-container/explore-container.module.ts

@@ -1,14 +0,0 @@
-import { NgModule } from '@angular/core';
-import { CommonModule } from '@angular/common';
-import { FormsModule } from '@angular/forms';
-
-import { IonicModule } from '@ionic/angular';
-
-import { ExploreContainerComponent } from './explore-container.component';
-
-@NgModule({
-  imports: [ CommonModule, FormsModule, IonicModule],
-  declarations: [ExploreContainerComponent],
-  exports: [ExploreContainerComponent]
-})
-export class ExploreContainerComponentModule {}

+ 28 - 0
src/app/func/balancesummary/balancesummary.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { BalancesummaryPage } from './balancesummary.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: BalancesummaryPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [BalancesummaryPage]
+})
+export class BalancesummaryPageModule {}

+ 32 - 0
src/app/func/balancesummary/balancesummary.page.html

@@ -0,0 +1,32 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_stock_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-list>
+    <!-- 开始时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_startTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.startDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 结束时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_endTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.endDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 物料名称 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/material-primary.svg"></ion-icon>
+      <ion-label>{{'generic_materName' | translate}}</ion-label>
+      <ion-input [(ngModel)]="input.materName" placeholder="{{'generic_placeholder_materName' | translate}}"></ion-input>
+    </ion-item>
+  </ion-list>
+  <ion-button expand="full" (click)='doSearch()'>{{ 'generic_query' | translate }}</ion-button>
+</ion-content>

+ 0 - 0
src/app/tab1/tab1.page.scss → src/app/func/balancesummary/balancesummary.page.scss


+ 42 - 0
src/app/func/balancesummary/balancesummary.page.ts

@@ -0,0 +1,42 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { TranslateService } from '@ngx-translate/core';
+import { Router } from '@angular/router';
+import { BaseService } from 'src/app/wongoing/base.service';
+
+@Component({
+  selector: 'app-balancesummary',
+  templateUrl: './balancesummary.page.html',
+  styleUrls: ['./balancesummary.page.scss'],
+})
+export class BalancesummaryPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+
+    /** 输入属性-双向绑定 */
+    input = {
+      startDate: '2016/08/20',
+      endDate: '2016/08/31',
+      materName: 'ATA'
+    };
+
+  constructor(private env: EnvService, public translate: TranslateService, private baseService: BaseService, private router : Router) { }
+
+  ngOnInit() {
+  }
+
+  public doSearch() {
+    // console.log('------------------------------------------');
+    console.log('startDate =' + this.input.startDate);
+    console.log('endDate =' + this.input.endDate);
+
+    this.input.startDate = this.input.startDate.substring(0, 10);
+    this.input.startDate.replace(new RegExp(/(-)/g), '/');
+    
+    this.input.endDate = this.input.endDate.substring(0, 10);
+    this.input.endDate.replace(new RegExp(/(-)/g), '/');
+
+
+    this.router.navigate(['/tabs/func/balanceSummary/rubberBalanceSummarytResult'], { queryParams : this.input });
+  }
+
+}

+ 31 - 0
src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.module.ts

@@ -0,0 +1,31 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { NgxEchartsModule } from 'ngx-echarts';
+
+import { RubberBalanceSummaryChartPage } from './rubber-balance-summary-chart.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: RubberBalanceSummaryChartPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule,
+    NgxEchartsModule
+  ],
+  declarations: [RubberBalanceSummaryChartPage]
+})
+export class RubberBalanceSummaryChartPageModule {}

+ 47 - 0
src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.page.html

@@ -0,0 +1,47 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_stock_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-card>
+    <ion-card-content>
+      <ion-list lines="none">
+        <ion-item>
+          <ion-icon name="calendar" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'rubberStockChart_date' | translate }}: </ion-label>
+          <ion-label>{{date}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="book" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_materName' | translate }}</ion-label>
+          <ion-label>{{materName}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="barcode" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_stock_weigh' | translate }}: </ion-label>
+          <ion-label>{{weigh}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="cube" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_stock_number' | translate }}: </ion-label>
+          <ion-label>{{number}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <ion-card>
+    <ion-card-header>
+      <ion-card-subtitle>
+        <ion-label>{{ 'rubberStockChart_title_chart' | translate }} </ion-label>
+      </ion-card-subtitle>
+    </ion-card-header>
+    <ion-card-content>
+      <div echarts [options]="options" class="echarts" style="height:320px;"></div>
+    </ion-card-content>
+  </ion-card>
+</ion-content>

+ 0 - 0
src/app/tab2/tab2.page.scss → src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.page.scss


+ 144 - 0
src/app/func/balancesummary/rubber-balance-summary-chart/rubber-balance-summary-chart.page.ts

@@ -0,0 +1,144 @@
+import { Component, OnInit } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { EnvService } from '../../../wongoing/env.service';
+import { EchartService } from '../../../wongoing/echart.service';
+import { RubberBalanceSummaryService } from '../rubber-balance-summary.service';
+
+@Component({
+  selector: 'app-rubber-summary-chart',
+  templateUrl: './rubber-balance-summary-chart.page.html',
+  styleUrls: ['./rubber-balance-summary-chart.page.scss'],
+})
+export class RubberBalanceSummaryChartPage implements OnInit {
+
+  isShowHeader = this.env.IsShowHeader;
+  options: any = {};   //echart图表选项
+  //保存横坐标
+  xaxis:any = {};
+  //保存重量
+  weight:any = {};
+  //保存数量
+  num:any = {};
+
+  /** 保存查询参数 */
+  startDate: any = '2016/03/15';
+  endDate: any = '2016/03/30';
+  materCode: any = '';
+  offset :any = 0;
+  limit :any = 5;
+  date :any ='';
+  materName :any ='';
+  weigh :any ='';
+  number :any ='';
+  constructor(private router: Router, private activatedRoute: ActivatedRoute,private env: EnvService, private echartservice: EchartService, private service: RubberBalanceSummaryService) { }
+
+  ngOnInit() {
+    this.loadData();
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // console.log('----------------------------------------');
+    // 获取路由参数
+    this.activatedRoute.queryParams.subscribe(param => {
+      this.startDate = param['startDate'];
+      this.endDate = param['endDate'];
+      this.materCode = param['materCode'];
+      this.offset = param['offset'];
+      this.limit = param['limit'];
+      this.date = param['date'];
+      this.materName = param['materName'];
+      this.weigh = param['weigh'];
+      this.number = param['number'];
+       
+      //debugger;
+      this.startDate = this.startDate.substring(0, 10);
+      this.startDate.replace(new RegExp(/(-)/g), '/');
+    
+      this.endDate = this.endDate.substring(0, 10);
+      this.endDate.replace(new RegExp(/(-)/g), '/');
+
+     
+      this.service.getBusStockChart(this.startDate,
+                                          this.endDate,
+                                          this.materCode,
+                                          this.offset,
+                                          this.limit).then((res: any) => {
+        if (res && res.state && res.state === '0') {
+          console.log(res);
+          //debugger;
+          if (res.result && res.result.length > 0) {
+            this.options = this.echartservice.getLineOptionsTemplate(this.echartservice.SuccessColor,
+                                                                    this.echartservice.InfoColor,
+                                                                    this.echartservice.TextColor,
+                                                                    this.echartservice.AxisLineColor,
+                                                                    this.echartservice.SplitLineColor);
+            
+            // 设置标题文本
+            this.options.title.subtext = '';
+            //debugger;
+            // 设置图例
+            this.options.legend.data = new Array(1);
+            this.options.legend.data[0] = {
+              name: res.result[0][1],//物料名作为图例名
+              icon: 'rect',
+              // textStyle: { color: this.echartservice.Colors[i] }
+            };
+            
+            for(let i = 0; i < res.result.length; i++) {
+              //debugger;
+              //获取所有时间作为横坐标
+              this.xaxis[i] = res.result[i][0];
+              this.weight[i] = res.result[i][3];
+              this.num[i] = res.result[i][4];              
+            }
+
+            //将横坐标转换为数组Array对象
+            let xaxisArray: number[] = new Array(res.result.length);
+            let numArray: number[] = new Array(res.result.length);
+            for(let i = 0; i < xaxisArray.length; i++) 
+            {
+              xaxisArray[i] = this.xaxis[i];
+              numArray[i] = this.num[i];
+            }
+
+            // 设置X轴的数据的点
+            this.options.xAxis.data = xaxisArray;
+
+            // 设置曲线个数
+            this.options.series = new Array(1); 
+
+            // 设置曲线名称及数据 
+            this.options.series[0] = {
+              //曲线名与图例名相对应才会显示
+              name: res.result[0][1],
+              type:'line',
+              smooth : true,
+              stack: '',
+              data: numArray,
+              markLine: { },
+              // lineStyle: {
+              //   color: this.echartservice.Colors[i]
+              // }
+            };
+           
+            // 设置Y轴最小值
+            let tempmin = Math.min.apply(null, numArray);
+            this.options.yAxis.min = Math.min(tempmin, this.options.yAxis.min);
+            
+            // 设置Y轴最大值
+            let tempmax = Math.max.apply(null,numArray);
+            this.options.yAxis.max = Math.max(tempmax, this.options.yAxis.max);
+ 
+          }
+        } else {
+          console.warn('请求后台接口[getBusStockChart]异常!');
+        }
+      }).catch(err => {
+        console.error(err);
+      });
+    });
+  }
+}

+ 28 - 0
src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { RubberBalanceSummaryResultPage } from './rubber-balance-summary-result.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: RubberBalanceSummaryResultPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [RubberBalanceSummaryResultPage]
+})
+export class RubberBalanceSummaryResultPageModule {}

+ 45 - 0
src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.page.html

@@ -0,0 +1,45 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_stock_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 下拉刷新 -->
+  <ion-refresher slot="fixed" (ionRefresh)="doDownRefresh($event)">
+    <ion-refresher-content></ion-refresher-content>
+  </ion-refresher>
+  <ion-card *ngFor="let result of resultList; let k = index">
+    <ion-card-content>
+      <ion-list>
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+          <ion-label>{{'generic_date'|translate}}:{{result[0]}}</ion-label>
+        </ion-item>
+        <ion-item (click)="goChartPage(k)">
+          <ion-icon name="book" slot="start" color="primary"></ion-icon>
+          <ion-label style="color:blue">{{'generic_title_materName'|translate}}:{{result[1]}}</ion-label>
+          <ion-icon name="pulse" slot="end" color="primary"></ion-icon>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="barcode" slot="start" color="primary"></ion-icon>
+          <ion-label>{{'generic_stock_weigh'|translate}}:{{result[3]}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="cube" slot="start" color="primary"></ion-icon>
+          <ion-label>{{'generic_stock_number'|translate}}:{{result[4]}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <!-- 上拉分页 -->
+  <ion-infinite-scroll threshold="100px" (ionInfinite)="doUpRefresh($event)">
+    <ion-infinite-scroll-content
+      loadingSpinner="bubbles"
+      loadingText="正在加载更多数据...">
+    </ion-infinite-scroll-content>
+  </ion-infinite-scroll>
+</ion-content>

+ 0 - 0
src/app/tab3/tab3.page.scss → src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.page.scss


+ 144 - 0
src/app/func/balancesummary/rubber-balance-summary-result/rubber-balance-summary-result.page.ts

@@ -0,0 +1,144 @@
+import { Component, OnInit, ViewChild } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { Storage } from '@ionic/storage';
+import { IonInfiniteScroll } from '@ionic/angular';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { RubberBalanceSummaryService } from '../rubber-balance-summary.service';
+
+@Component({
+  selector: 'app-rubber-summary-result',
+  templateUrl: './rubber-balance-summary-result.page.html',
+  styleUrls: ['./rubber-balance-summary-result.page.scss'],
+})
+export class RubberBalanceSummaryResultPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  infiniteScroll: IonInfiniteScroll;
+  pageIndex = 1;    // 当前页的索引
+  maxPageCount = 5; // 允许显示的最大页数
+  pageSize = 5;     // 每页大小
+  resultList: any;   // 保存结果数据的数组
+
+  /** 保存查询参数 */
+  startDate: any = '2016/03/15';
+  endDate: any = '2016/03/30';
+  materName: any = '';
+  materCode: any = '';
+
+  constructor(private env: EnvService,
+    private router: Router,
+    private activatedRoute: ActivatedRoute,
+    private storage: Storage,
+    private service: RubberBalanceSummaryService) { }
+
+  ngOnInit() {
+    this.resultList = [];
+    this.loadData();
+  }
+
+  /**
+   * 下拉刷新事件处理
+   * @param event 事件
+   */
+  public doDownRefresh(event) {
+    console.log('Begin async operation');
+    this.pageIndex = 1;   // 重新从第1页开始显示
+    this.resultList.splice(0, this.resultList.length);   // 清空原缓存的数据
+    this.loadData();
+    setTimeout(() => {
+      console.log('Async operation has ended');
+      event.target.complete();
+    }, 1000);
+  }
+
+  /**
+   * 上拉刷新加载分页数据
+   * @param event 事件
+   */
+  public doUpRefresh(event) {
+    this.pageIndex++; // 增加一页
+    this.loadData();
+    setTimeout(() => {
+      console.log('Done');
+      event.target.complete();
+
+      // // App logic to determine if all data is loaded
+      // // and disable the infinite scroll
+      if (this.pageIndex >= this.maxPageCount) {
+        event.target.disabled = true;
+      }
+    }, 1000);
+  }
+
+  toggleInfiniteScroll() {
+    this.infiniteScroll.disabled = !this.infiniteScroll.disabled;
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // 从Storage获取customerId
+    this.storage.get('customerId').then((customerId) => {
+
+      // 获取路由参数
+      this.activatedRoute.queryParams.subscribe(param => {
+
+        this.startDate = param['startDate'];
+        this.endDate = param['endDate'];
+        this.materName = param['materName'];
+        //debugger;
+        const offset: number = (this.pageIndex - 1) * this.pageSize;
+
+        this.service.getBusStockResult(
+          param['startDate'],
+          param['endDate'],
+          param['materName'],
+          offset,
+          this.pageSize).then((res: any) => {
+            if (res && res.state && res.state === '0') {
+              console.log(res);
+              //debugger;
+              // 把结果数据压入结果数组列表中。
+              res.result.forEach((element: never) => {
+                this.resultList.push(element);
+              });
+            } else {
+              console.warn('请求后台接口[getBusStockResult]异常!');
+            }
+          }).catch(err => {
+            console.error(err);
+          });
+      });
+    }).catch(error => {
+      console.error('从Storage中获取customerId失败!', error);
+    });
+  }
+
+  /**
+   * 跳转到图表展示页面
+   */
+  public goChartPage(resultIndex: any) {
+    console.log('resultIndex = ' + resultIndex);
+    if (this.resultList && this.resultList.length > resultIndex) {
+      //获取物料编码
+      this.materCode = this.resultList[resultIndex][2];
+      this.materName = this.resultList[resultIndex][1];
+      const params = {
+        dsType: 'demoDs',
+        startDate: this.startDate,
+        endDate: this.endDate,
+        materCode: this.materCode,
+        offset :(this.pageIndex - 1) * this.pageSize,
+        limit :this.pageSize,
+        date :this.resultList[resultIndex][0],
+        materName :this.resultList[resultIndex][1],
+        weigh :this.resultList[resultIndex][3],
+        number :this.resultList[resultIndex][4]
+      }
+      this.router.navigate(['/tabs/func/balanceSummary/rubberBalanceSummarytChart'], { queryParams: params });
+    } else {
+      console.warn('要查看的数据索引超过了缓存数据列表的长度!');
+    }
+  }
+
+}

+ 50 - 0
src/app/func/balancesummary/rubber-balance-summary.service.ts

@@ -0,0 +1,50 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+
+import { EnvService } from '../../wongoing/env.service';
+import { UtilsService } from '../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class RubberBalanceSummaryService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+
+  /**
+   * 获取胶料结存结果列表
+   * @param startDate 开始日期
+   * @param endDate 截止日期
+   * @param materName  物料名
+   * @param offset  偏移量
+   * @param limit 限制
+   */
+  public getBusStockResult(startDate: string, endDate:string, materName: string,offset: any, limit: any) {
+    const url = this.env.getBusStockResult;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType,'startDate': startDate, 'endDate': endDate, 'materName': materName,'offset': offset, 'limit': limit } };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+    /**
+   * 获取胶料结存趋势图表
+   * @param startDate 
+   * @param endDate 
+   * @param materCode 
+   */
+  public getBusStockChart(startDate: string, endDate:string, materCode: string,offset :any,limit:any) {
+    const url = this.env.getBusStockChart;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'startDate': startDate, 'endDate': endDate,'materCode': materCode ,'offset':offset,'limit':limit} };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+  
+}

+ 28 - 0
src/app/func/chanliang/chanliang.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { ChanliangPage } from './chanliang.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: ChanliangPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [ChanliangPage]
+})
+export class ChanliangPageModule {}

+ 65 - 0
src/app/func/chanliang/chanliang.page.html

@@ -0,0 +1,65 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{'generic_production_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-list>
+    <!-- 开始时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_startTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.startDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 结束时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_endTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.endDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 生产机台 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/monitor-primary.svg"></ion-icon>
+      <ion-label>{{'generic_equip' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.equipMultiple" multiple="true" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}" placeholder="{{'generic_placeholder_equip' | translate}}">
+        <ion-select-option *ngFor="let equip of equipList" value="{{equip.equipCode}}">{{equip.equipName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+    <!-- 生产班组 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/classgroup-primary.svg"></ion-icon>
+      <ion-label>{{'generic_shiftClass' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.shiftClassId" [value]="1" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}">
+        <ion-select-option *ngFor="let shiftClass of shiftClassList" value="{{shiftClass.shiftClassId}}">{{shiftClass.shiftClassName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+    <!-- 胶料类型 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/rubtype-primary.svg"></ion-icon>
+      <ion-label>{{'generic_RubberType' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.rubTypeCode" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}">
+        <ion-select-option *ngFor="let rubType of rubTypeList" value="{{rubType.rubTypeCode}}">{{rubType.rubTypeName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+    <!-- 胶料大类 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/rubmkind-primary.svg"></ion-icon>
+      <ion-label>{{'rubberProductSearch_rubberBigType' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.mKindCode" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}">
+        <ion-select-option *ngFor="let mkind of mkindList" value="{{mkind.mkindCode}}">{{mkind.mkindName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+    <!-- 物料名称 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/material-primary.svg"></ion-icon>
+      <ion-label>{{'generic_materName' | translate}}</ion-label>
+      <ion-input [(ngModel)]="input.materName" placeholder="{{'generic_placeholder_materName' | translate}}"></ion-input>
+    </ion-item>
+  </ion-list>
+
+  <ion-button expand="full" (click)='doSearch()'>{{ 'generic_query' | translate }}</ion-button>
+</ion-content>

+ 0 - 0
src/app/func/chanliang/chanliang.page.scss


+ 146 - 0
src/app/func/chanliang/chanliang.page.ts

@@ -0,0 +1,146 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from '../../wongoing/env.service';
+import { TranslateService } from '@ngx-translate/core';
+import { Router } from '@angular/router';
+import { BaseService } from 'src/app/wongoing/base.service';
+
+@Component({
+  selector: 'app-chanliang',
+  templateUrl: './chanliang.page.html',
+  styleUrls: ['./chanliang.page.scss'],
+})
+export class ChanliangPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  /** 输入属性-双向绑定 */
+  input = {
+    startDate: '2016/03/15',
+    endDate: '2016/03/30',
+    equipCode: '',
+    shiftClassId: '全部',
+    shiftClassName: '全部',
+    rubTypeCode: '全部',
+    rubTypeName: '全部',
+    mKindCode: '全部',
+    mKindName: '全部',
+    materName: '',
+    equipMultiple: '01001,01003,01005,01006,01008',
+    pmtEquipList: []
+  };
+
+  /** 数据初始化属性-单向显示 */
+  shiftClassList: any[];
+  equipList: any[];
+  rubTypeList: any[];
+  mkindList: any[];
+  constructor(private env: EnvService, public translate: TranslateService, private baseService: BaseService, private router : Router) { }
+
+  /** ng初始化 */
+  ngOnInit() {
+    this.initShiftClass();
+    this.initEquip();
+    this.initRubType();
+    this.initMKind();
+  }
+
+  ionViewWillEnter() {
+    // this.translate.get(["generic_en_language"]).subscribe(res => {
+    //   console.log("ngOnInit get the translate generic_en_language");
+    //   console.log(res);
+    // });
+  }
+
+  /**
+   * 初始化生产班组
+   */
+  private async initShiftClass() {
+    let res: any = await this.baseService.getShiftClassList();
+    if (res && res.state && res.state == '0') {
+      this.shiftClassList = res.result;
+    } else {
+      console.warn('请求后台接口[getShiftClassList]异常!');
+    }
+  }
+
+  /**
+   * 初始化生产机台
+   */
+  private initEquip() {
+    this.baseService.getEquipList().then((res: any) => {
+      console.log('getEquipList调用完毕...');
+      console.log(res);
+      if (res && res.state && res.state === '0') {
+        this.equipList = res.result;
+      } else {
+        console.warn('请求后台接口[getEquipList]异常!');
+      }
+    }).catch(err => {
+      console.error(err);
+    });
+  }
+
+  /**
+   * 初始化胶料类别
+   */
+  private initRubType() {
+    this.baseService.getRubTypeList().then((res: any) => {
+      console.log('getRubTypeList调用完毕...');
+      console.log(res);
+      if (res && res.state && res.state === '0') {
+        this.rubTypeList = res.result;
+     } else {
+       console.warn('请求后台接口[getRubTypeList]异常!');
+     }
+    }).catch(err => {
+      console.error(err);
+    });
+  }
+
+  /**
+   * 初始化胶料大类
+   */
+  private initMKind() {
+    this.baseService.getMKindList().then((res: any) => {
+      console.log('getMKindList调用完毕...');
+      console.log(res);
+      if (res && res.state && res.state === '0') {
+        this.mkindList = res.result;
+      } else {
+        console.warn('请求后台接口[getMKindList]异常!');
+      }
+    }).catch(err => {
+      console.error(err);
+    });
+  }
+
+  public doSearch() {
+    // console.log('------------------------------------------');
+    console.log('startDate =' + this.input.startDate);
+    console.log('endDate =' + this.input.endDate);
+    // console.log('equipCode =' + this.input.equipCode);
+    // console.log('shiftClassId =' + this.input.shiftClassId);
+    // console.log('shiftClassName =' + this.input.shiftClassName);
+    // console.log('rubTypeCode =' + this.input.rubTypeCode);
+    // console.log('rubTypeName =' + this.input.rubTypeName);
+    // console.log('mKindCode =' + this.input.mKindCode);
+    // console.log('mKindName =' + this.input.mKindName);
+    // console.log('materName =' + this.input.materName);
+    // console.log('equipMultiple =' + this.input.equipMultiple);
+    // console.log('pmtEquipList =' + this.input.pmtEquipList);
+    // console.log('------------------------------------------');
+
+    this.input.startDate = this.input.startDate.substring(0, 10);
+    this.input.startDate.replace(new RegExp(/(-)/g), '/');
+    
+    this.input.endDate = this.input.endDate.substring(0, 10);
+    this.input.endDate.replace(new RegExp(/(-)/g), '/');
+
+    this.input.pmtEquipList.splice(0, this.input.pmtEquipList.length);
+    this.equipList.forEach(equip => {
+      if (this.input.equipMultiple.indexOf(equip.equipCode) >= 0) {
+        this.input.pmtEquipList.push(equip.equipName);
+      }
+    });
+
+    this.router.navigate(['/tabs/func/chanliang/rubberproductresult'], { queryParams : this.input });
+  }
+}

+ 31 - 0
src/app/func/chanliang/rubber-product-chart/rubber-product-chart.module.ts

@@ -0,0 +1,31 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { NgxEchartsModule } from 'ngx-echarts';
+
+import { RubberProductChartPage } from './rubber-product-chart.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: RubberProductChartPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule,
+    NgxEchartsModule
+  ],
+  declarations: [RubberProductChartPage]
+})
+export class RubberProductChartPageModule {}

+ 43 - 0
src/app/func/chanliang/rubber-product-chart/rubber-product-chart.page.html

@@ -0,0 +1,43 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_production_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-card>
+    <ion-card-content>
+      <ion-list lines="none">
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+          <ion-label>{{ 'generic_startTime' | translate }}{{startDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+          <ion-label>{{ 'generic_endTime' | translate }}{{endDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/classgroup-primary.svg"></ion-icon>
+          <ion-label>{{ 'generic_shiftClass' | translate }}{{shiftClassId}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/material-primary.svg"></ion-icon>
+          <ion-label>{{ 'generic_materName' | translate }}{{materName}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <ion-card>
+    <ion-card-header>
+      <ion-card-subtitle>
+        <ion-label>{{ 'rubberProductChart_title_chart' | translate }}</ion-label>
+      </ion-card-subtitle>
+    </ion-card-header>
+    <ion-card-content>
+      <div echarts [options]="options" class="echarts" style="height:320px;"></div>
+    </ion-card-content>
+  </ion-card>
+</ion-content>

+ 0 - 0
src/app/func/chanliang/rubber-product-chart/rubber-product-chart.page.scss


+ 127 - 0
src/app/func/chanliang/rubber-product-chart/rubber-product-chart.page.ts

@@ -0,0 +1,127 @@
+import { Component, OnInit } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { EnvService } from '../../../wongoing/env.service';
+import { EchartService } from '../../../wongoing/echart.service';
+import { RubberProductChartService } from './rubber-product-chart.service';
+
+@Component({
+  selector: 'app-rubber-product-chart',
+  templateUrl: './rubber-product-chart.page.html',
+  styleUrls: ['./rubber-product-chart.page.scss'],
+})
+export class RubberProductChartPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  options: any = {};   // echart图表选项
+
+  /** 保存查询参数 */
+  startDate: any = '2016/03/15';
+  endDate: any = '2016/03/30';
+  equipCode: any = '';
+  shiftClassId: any = '全部';
+  rubTypeName: any = '全部';
+  mKindName: any = '全部';
+  materCode: any = '';
+  materName: any = '';
+  constructor(private router: Router, private activatedRoute: ActivatedRoute,private env: EnvService, private echartService: EchartService, private service: RubberProductChartService) { }
+
+  ngOnInit() {
+    this.loadData();
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // console.log('----------------------------------------');
+    // 获取路由参数
+    this.activatedRoute.queryParams.subscribe(param => {
+      this.startDate = param['startDate'];
+      this.endDate = param['endDate'];
+      this.equipCode = param['equipCode'];
+      this.shiftClassId = param['shiftClassId'];
+      this.rubTypeName = param['rubTypeName'];
+      this.mKindName = param['mKindName'];
+      this.materCode = param['materCode'];
+      this.materName = param['materName'];
+
+      this.startDate = this.startDate.substring(0, 10);
+      this.startDate.replace(new RegExp(/(-)/g), '/');
+    
+      this.endDate = this.endDate.substring(0, 10);
+      this.endDate.replace(new RegExp(/(-)/g), '/');
+
+      console.log('startDate = ' + this.startDate);
+      console.log('endDate = ' + this.endDate);
+      console.log('equipCode =' + this.equipCode);
+      console.log('shiftClassId = ' + this.shiftClassId);
+      console.log('rubTypeName = ' + this.rubTypeName);
+      console.log('mKindName = ' + this.rubTypeName);
+      console.log('materCode = ' + this.materCode);
+      console.log('materName = ' + this.materName);
+      // console.log('----------------------------------------');
+      // console.log(this.equipList);
+      this.service.getBusProductionChart(this.startDate,
+                                          this.endDate,
+                                          this.equipCode,
+                                          this.shiftClassId,
+                                          this.rubTypeName,
+                                          this.mKindName,
+                                          this.materCode).then((res: any) => {
+        if (res && res.state && res.state === '0') {
+          console.log(res);
+          if (res.result && res.result.length > 0) {
+            this.options = this.echartService.getLineOptionsTemplate(this.echartService.SuccessColor,
+                                                                    this.echartService.InfoColor,
+                                                                    this.echartService.TextColor,
+                                                                    this.echartService.AxisLineColor,
+                                                                    this.echartService.SplitLineColor);
+            
+            // 设置标题文本
+            this.options.title.subtext = '';
+            this.options.grid.top = 30;
+            this.options.grid.bottom = 5;
+            this.options.grid.left = 0;
+            this.options.grid.right = '4%';
+            // 设置图例
+            this.options.legend.data = new Array(res.result[0].equipList.length);
+            for(let i = 0; i < res.result[0].equipList.length; i++) {
+              this.options.legend.data[i] = {
+                name: res.result[0].equipList[i],
+                icon: 'rect',
+                // textStyle: { color: this.echartservice.Colors[i] }
+              };
+            }
+            this.options.xAxis.data = res.result[0].dateList;               // 设置X轴的数据的点
+            this.options.series = new Array(res.result[0].equipDataList.length);    // 设置曲线个数
+
+            for(let i = 0; i < res.result[0].equipDataList.length; i++) {
+              // 设置曲线名称及数据 
+              this.options.series[i] = {
+                name: res.result[0].equipList[i],
+                type:'line',
+                smooth : true,
+                stack: '',
+                data: res.result[0].equipDataList[i],
+                markLine: { },
+                // lineStyle: {
+                //   color: this.echartservice.Colors[i]
+                // }
+              };
+              // 设置Y轴最小值
+              let tempmin = Math.min.apply(null, res.result[0].equipDataList[i]);
+              this.options.yAxis.min = Math.min(tempmin, this.options.yAxis.min);
+
+              // 设置Y轴最大值
+              let tempmax = Math.max.apply(null, res.result[0].equipDataList[i]);
+              this.options.yAxis.max = Math.max(tempmax, this.options.yAxis.max);
+            }
+          }
+        } else {
+          console.warn('请求后台接口[getBusProductionResult]异常!');
+        }
+      }).catch(err => {
+        console.error(err);
+      });
+    });
+  }
+}

+ 33 - 0
src/app/func/chanliang/rubber-product-chart/rubber-product-chart.service.ts

@@ -0,0 +1,33 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+
+import { EnvService } from '../../../wongoing/env.service';
+import { UtilsService } from '../../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class RubberProductChartService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取胶料产量分析趋势图表
+   * @param startDate 开始日期
+   * @param endDate 结束日期
+   * @param equipCode 机台编号列表,以分号分割
+   * @param shiftClassId 班组Id
+   * @param rubTypeName 胶料类型
+   * @param mKindName 胶料大类
+   * @param materCode 物料编码
+   */
+  public getBusProductionChart(startDate: string, endDate:string, equipCode: string, shiftClassId: string, rubTypeName: string, mKindName: string, materCode: string) {
+    const url = this.env.getBusProductionChart;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'startDate': startDate, 'endDate': endDate, 'equipCode': equipCode, 'shiftClassId': shiftClassId, 'rubTypeName': rubTypeName, 'mKindName': mKindName, 'materCode': materCode } };
+    return this.http.request(method, url, options).toPromise();
+  }
+}

+ 28 - 0
src/app/func/chanliang/rubber-product-result/rubber-product-result.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { RubberProductResultPage } from './rubber-product-result.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: RubberProductResultPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [RubberProductResultPage]
+})
+export class RubberProductResultPageModule {}

+ 45 - 0
src/app/func/chanliang/rubber-product-result/rubber-product-result.page.html

@@ -0,0 +1,45 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_production_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 下拉刷新 -->
+  <ion-refresher slot="fixed" (ionRefresh)="doDownRefresh($event)">
+    <ion-refresher-content></ion-refresher-content>
+  </ion-refresher>
+  <ion-card *ngFor="let result of resultList; let k = index">
+    <ion-card-content>
+      <ion-list>
+        <ion-item>
+          <ion-icon name="barcode" slot="start" color="primary"></ion-icon>
+          <ion-label>物料编码:{{result[0]}}</ion-label>
+        </ion-item>
+        <ion-item (click)="goChartPage(k)" button detail="false">
+          <ion-icon name="cube" slot="start" color="primary"></ion-icon>
+          <ion-label style="color:blue">物料名称:{{result[1]}}</ion-label>
+          <ion-icon name="pulse" slot="end" color="primary"></ion-icon>
+        </ion-item>
+        <ion-item *ngFor="let equip of equipList; let i = index" >
+          <ion-icon name="aperture" slot="start" color="primary"></ion-icon>
+          <ion-label>{{equip}}:{{result[i + 2]}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="gift" slot="start" color="primary"></ion-icon>
+          <ion-label>产量总计:<span style="color:red">{{result[result.length - 1]}}</span></ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <!-- 上拉分页 -->
+  <ion-infinite-scroll threshold="100px" (ionInfinite)="doUpRefresh($event)">
+    <ion-infinite-scroll-content
+      loadingSpinner="bubbles"
+      loadingText="正在加载更多数据...">
+    </ion-infinite-scroll-content>
+  </ion-infinite-scroll>
+</ion-content>

+ 0 - 0
src/app/func/chanliang/rubber-product-result/rubber-product-result.page.scss


+ 159 - 0
src/app/func/chanliang/rubber-product-result/rubber-product-result.page.ts

@@ -0,0 +1,159 @@
+import { Component, OnInit, ViewChild } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { Storage } from '@ionic/storage';
+import { IonInfiniteScroll } from '@ionic/angular';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { RubberProductResultService } from './rubber-product-result.service';
+
+@Component({
+  selector: 'app-rubber-product-result',
+  templateUrl: './rubber-product-result.page.html',
+  styleUrls: ['./rubber-product-result.page.scss'],
+})
+export class RubberProductResultPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  infiniteScroll: IonInfiniteScroll;
+  pageIndex = 1;    // 当前页的索引
+  maxPageCount = 5; // 允许显示的最大页数
+  pageSize = 5;     // 每页大小
+  equipList: [];    // 保存选择的机台名称列表
+  resultList: any;   // 保存结果数据的数组
+
+  /** 保存查询参数 */
+  startDate: any = '2016/03/15';
+  endDate: any = '2016/03/30';
+  equipCode: any = '';
+  shiftClassId: any = '全部';
+  rubTypeName: any = '全部';
+  mKindName: any = '全部';
+  materCode: any = '';
+  materName: any = '';
+
+  constructor(private env: EnvService,
+              private router: Router,
+              private activatedRoute: ActivatedRoute,
+              private storage: Storage,
+              private service: RubberProductResultService) { }
+
+  ngOnInit() {
+    this.resultList = [];
+    this.loadData();
+  }
+
+  /**
+   * 下拉刷新事件处理
+   * @param event 事件
+   */
+  public doDownRefresh(event) {
+    console.log('Begin async operation');
+    this.pageIndex = 1;   // 重新从第1页开始显示
+    this.resultList.splice(0, this.resultList.length);   // 清空原缓存的数据
+    this.loadData();
+    setTimeout(() => {
+      console.log('Async operation has ended');
+      event.target.complete();
+    }, 1000);
+  }
+
+  /**
+   * 上拉刷新加载分页数据
+   * @param event 事件
+   */
+  public doUpRefresh(event) {
+    this.pageIndex++; // 增加一页
+    this.loadData();
+    setTimeout(() => {
+      console.log('Done');
+      event.target.complete();
+
+      // // App logic to determine if all data is loaded
+      // // and disable the infinite scroll
+      if (this.pageIndex >= this.maxPageCount) {
+        event.target.disabled = true;
+      }
+    }, 1000);
+  }
+
+  toggleInfiniteScroll() {
+    this.infiniteScroll.disabled = !this.infiniteScroll.disabled;
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // 从Storage获取customerId
+    this.storage.get('customerId').then((customerId) => {
+      // console.log('----------------------------------------');
+      // console.log('customerId = ' + customerId);
+      // 获取路由参数
+      this.activatedRoute.queryParams.subscribe(param => {
+        this.startDate = param['startDate'];
+        this.endDate = param['endDate'];
+        this.shiftClassId = param['shiftClassId'];
+        this.rubTypeName = param['rubTypeName'];
+        this.mKindName = param['mKindName'];
+        // console.log('materName = ' + param['materName']);
+        this.equipCode = new String(param['equipMultiple']).replace(new RegExp(/(,)/g), ';');  // 把对象装转为字符串并且把字符串中所有的,替换为;
+        console.log('equipCode = ' + this.equipCode);
+        // console.log('----------------------------------------');
+        
+
+        this.equipList = param['pmtEquipList'];   // 机台名称列表
+        // console.log(this.equipList);
+        const offset: number = (this.pageIndex - 1) * this.pageSize;
+        this.service.getBusProductionResult(customerId, 
+                                            param['startDate'],
+                                            param['endDate'],
+                                            this.equipCode,
+                                            param['shiftClassId'],
+                                            param['rubTypeName'],
+                                            param['mKindName'],
+                                            param['materName'],
+                                            offset,
+                                            this.pageSize).then((res: any) => {
+          if (res && res.state && res.state === '0') {
+            console.log(res);
+            // 把结果数据压入结果数组列表中。
+            res.result.forEach((element: never) => {
+              this.resultList.push(element);
+            });
+          } else {
+            console.warn('请求后台接口[getBusProductionResult]异常!');
+          }
+        }).catch(err => {
+          console.error(err);
+        });
+      });
+    }).catch(error => {
+      console.error('从Storage中获取customerId失败!', error);
+    });
+  }
+
+  /**
+   * 跳转到图表展示页面
+   * @param resultIndex 缓存数据的索引 
+   */
+  public goChartPage(resultIndex: any) {
+    console.log('resultIndex = ' + resultIndex);
+    if (this.resultList && this.resultList.length > resultIndex) {
+      this.materCode = this.resultList[resultIndex][0];
+      this.materName = this.resultList[resultIndex][1];
+      const params = { 
+        dsType: 'demoDs', 
+        startDate: this.startDate, 
+        endDate: this.endDate, 
+        equipCode: this.equipCode, 
+        shiftClassId: this.shiftClassId, 
+        rubTypeName: this.rubTypeName,  
+        mKindName: this.mKindName,
+        materCode: this.materCode,
+        materName: this.materName
+      }
+      this.router.navigate(['/tabs/func/chanliang/rubberproductchart'], { queryParams: params });
+    } else {
+      console.warn('要查看的数据索引超过了缓存数据列表的长度!');
+    }
+  }
+
+}

+ 38 - 0
src/app/func/chanliang/rubber-product-result/rubber-product-result.service.ts

@@ -0,0 +1,38 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+
+import { EnvService } from '../../../wongoing/env.service';
+import { UtilsService } from '../../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class RubberProductResultService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取胶料产量分析结果列表
+   * @param customerId 客户Id
+   * @param startDate 开始日期yyyy-MM-dd,默认值2016-03-15
+   * @param endDate 结束日期yyyy-MM-dd,默认值2016-03-30
+   * @param equipCode 机台编号列表,以;分割
+   * @param shiftClassId 班组Id,默认值“全部”
+   * @param rubTypeName 胶料类型名称,默认值“全部”
+   * @param mKindName 胶料大类名称,默认值“全部”
+   * @param materName  物料名称,默认值""
+   * @param offset 记录偏移量
+   * @param limit 记录结果限定数
+   */
+  public getBusProductionResult(customerId: any, startDate: string, endDate:string, equipCode: string, shiftClassId: string, rubTypeName: string, mKindName: string, materName: string, offset: any, limit: any) {
+    const url = this.env.getBusProductionResult;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'customerId': customerId, 'startDate': startDate, 'endDate': endDate, 'equipCode': equipCode, 'shiftClassId': shiftClassId, 'rubTypeName': rubTypeName, 'mKindName': mKindName, 'materName': materName, 'offset': offset, 'limit': limit } };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+
+}

+ 28 - 0
src/app/func/chaoqi/chaoqi.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { ChaoqiPage } from './chaoqi.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: ChaoqiPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [ChaoqiPage]
+})
+export class ChaoqiPageModule {}

+ 42 - 0
src/app/func/chaoqi/chaoqi.page.html

@@ -0,0 +1,42 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_outValid_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-list>
+    <!-- 开始时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_startTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.startDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 结束时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_endTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.endDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 超时时间-小时数 -->
+    <ion-item>
+    <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+    <!-- <ion-label>{{'outValidSearch_outValidTime' | translate}}</ion-label> -->
+    <ion-label>超时时间(小时):</ion-label>
+    <ion-input inputmode="numeric" [(ngModel)]="input.validHours" onkeyup="value=value.replace(/[^\d]/g,'')"></ion-input>
+  </ion-item>
+  <!-- 归属仓库 -->
+  <ion-item>
+    <ion-icon slot="start" src="/assets/svg/rubtype-primary.svg"></ion-icon>
+    <ion-label>{{'generic_outValid_storehouse' | translate}}</ion-label>
+    <ion-select [(ngModel)]="input.stockNo " okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}">
+      <ion-select-option *ngFor="let stock of stockList" value="{{stock.codeValue}}">{{stock.codeName}}</ion-select-option>
+    </ion-select>
+  </ion-item>
+  </ion-list>
+
+  <ion-button expand="full" (click)='doSearch()'>{{ 'generic_query' | translate }}</ion-button>
+</ion-content>

+ 0 - 0
src/app/func/chaoqi/chaoqi.page.scss


+ 71 - 0
src/app/func/chaoqi/chaoqi.page.ts

@@ -0,0 +1,71 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { TranslateService } from '@ngx-translate/core';
+import { Router } from '@angular/router';
+import { BaseService } from 'src/app/wongoing/base.service';
+
+@Component({
+  selector: 'app-chaoqi',
+  templateUrl: './chaoqi.page.html',
+  styleUrls: ['./chaoqi.page.scss'],
+})
+export class ChaoqiPage implements OnInit {
+
+  isShowHeader = this.env.IsShowHeader;
+
+   /** 输入属性-双向绑定 */
+   input = {
+    startDate: '2016/03/15',
+    endDate: '2016/03/30',
+    validHours :0,
+    stockNo: '全部'
+  };
+
+  /** 数据初始化属性-单向显示 */
+  stockList: any[];
+
+  constructor(private env: EnvService, public translate: TranslateService, private baseService: BaseService, private router : Router) { }
+  
+  /** ng初始化 */
+  ngOnInit() {
+    this.initStockList();
+  }
+
+
+
+  public doSearch() {
+
+    console.log('startDate =' + this.input.startDate);
+    console.log('endDate =' + this.input.endDate);
+
+
+    this.input.startDate = this.input.startDate.substring(0, 10);
+    this.input.startDate.replace(new RegExp(/(-)/g), '/');
+    
+    this.input.endDate = this.input.endDate.substring(0, 10);
+    this.input.endDate.replace(new RegExp(/(-)/g), '/');
+
+
+    this.router.navigate(['/tabs/func/chaoqi/outValidResult'], { queryParams : this.input });
+  }
+
+
+   /**
+   * 初始化仓库列表
+   */
+  private initStockList() {
+    this.baseService.getStockList().then((res: any) => {
+      //debugger;
+      console.log('getStockList调用完毕...');
+      console.log(res);
+      if (res && res.state && res.state === '0') {
+        this.stockList = res.result;
+     } else {
+       console.warn('请求后台接口[getStockList]异常!');
+     }
+    }).catch(err => {
+      console.error(err);
+    });
+  }
+
+}

+ 31 - 0
src/app/func/chaoqi/out-valid-chart/out-valid-chart.module.ts

@@ -0,0 +1,31 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { NgxEchartsModule } from 'ngx-echarts';
+
+import { OutValidChartPage } from './out-valid-chart.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: OutValidChartPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule,
+    NgxEchartsModule
+  ],
+  declarations: [OutValidChartPage]
+})
+export class OutValidChartPageModule {}

+ 90 - 0
src/app/func/chaoqi/out-valid-chart/out-valid-chart.page.html

@@ -0,0 +1,90 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_outValid_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-card>
+    <ion-card-content>
+      <ion-list lines="none">
+        <ion-item>
+          <ion-icon name="barbell" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_barcode' | translate }} :{{barcode}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="calendar" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_outValidDate' | translate }} :{{outValidDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="home" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_outValid_storehouse' | translate }}{{storehouse}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="book" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_materName' | translate }}{{materName}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="keypad" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_RubberType' | translate }}{{rubberType}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="barcode" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_stockWeight' | translate }} :{{stockWeight}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="cube" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_convertStdNum' | translate }} :{{convertStdNum}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="flag" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_equip' | translate }}{{equip}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="hammer" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_shift' | translate }}{{shift}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="people" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_shiftClass' | translate }}{{shiftClass}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="toggle" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_usedState' | translate }} :{{usedState}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="link" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_dealMeasure' | translate }} :{{dealMeasure}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="toggle" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_quaState' | translate }} :{{quaState}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="flag" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_quaFlag' | translate }} :{{quaFlag}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="toggle" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_quaFinish' | translate }} :{{quaFinish}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="calendar" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_validDate' | translate }} :{{validDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="reader" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'outValidChart_unQuaReason' | translate }} :{{unQuaReason}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <ion-card>
+    <ion-card-content>
+      <div echarts [options]="options" class="echarts" style="height:320px;"></div>
+    </ion-card-content>
+  </ion-card>
+</ion-content>

+ 0 - 0
src/app/func/chaoqi/out-valid-chart/out-valid-chart.page.scss


+ 161 - 0
src/app/func/chaoqi/out-valid-chart/out-valid-chart.page.ts

@@ -0,0 +1,161 @@
+import { Component, OnInit } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { EnvService } from '../../../wongoing/env.service';
+import { EchartService } from '../../../wongoing/echart.service';
+import { OutValidService } from '../out-valid.service';
+
+@Component({
+  selector: 'app-rubber-product-chart',
+  templateUrl: './out-valid-chart.page.html',
+  styleUrls: ['./out-valid-chart.page.scss'],
+})
+export class OutValidChartPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  options: any = {};   //echart图表选项
+  //保存横坐标
+  xaxis:any = {};
+  //保存重量
+  weightArray:any = {};
+  //保存数量
+  num:any = {};
+  //图例名
+  legend :string ='数量';
+  /** 保存查询参数 */
+
+  materName: any = '';
+  outValidDate  : any ='';
+  offset: any ='';
+  limit: any ='';
+
+  //传递页面显示的参数
+  barcode :any ='';
+  storehouse :any ='';
+  rubberType :any ='';
+  stockWeight :any ='';
+  convertStdNum :any ='';
+  equip :any ='';
+  shift :any ='';
+  shiftClass :any ='';
+  usedState :any ='';
+  dealMeasure :any ='';
+  quaState :any ='';
+  quaFlag  :any ='';
+  quaFinish :any ='';
+  validDate :any ='';
+  unQuaReason :any ='';
+
+  constructor(private router: Router, private activatedRoute: ActivatedRoute,private env: EnvService, private echartservice: EchartService, private service: OutValidService) { }
+
+  ngOnInit() {
+    this.loadData();
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // console.log('----------------------------------------');
+    // 获取路由参数
+    this.activatedRoute.queryParams.subscribe(param => {
+      //debugger;
+      this.materName = param['materName'];
+      this.outValidDate = param['outValidDate'];
+      this.offset = param['offset'];
+      this.limit = param['limit'];
+      //传递参数
+      this.barcode = param['barcode'];
+      this.storehouse  = param['storehouse'];
+      this.rubberType  = param['rubberType'];
+      this.stockWeight  = param['stockWeight'];
+      this.convertStdNum  = param['convertStdNum'];
+      this.equip  = param['equip'];
+      this.shift  = param['shift'];
+      this.shiftClass  = param['shiftClass'];
+      this.usedState  = param['usedState'];
+      this.dealMeasure  = param['dealMeasure'];
+      this.quaState  = param['quaState'];
+      this.quaFlag   = param['quaFlag'];
+      this.quaFinish  = param['quaFinish'];
+      this.validDate  = param['validDate'];
+      this.unQuaReason  = param['unQuaReason'];
+
+      this.service.getBusOutValidChart(this.materName,this.outValidDate,this.offset,this.limit).then((res: any) => {
+        if (res && res.state && res.state === '0') {
+          console.log(res);
+         
+          if (res.result && res.result.length > 0) {
+            this.options = this.echartservice.getLineOptionsTemplate(this.echartservice.SuccessColor,
+                                                                    this.echartservice.InfoColor,
+                                                                    this.echartservice.TextColor,
+                                                                    this.echartservice.AxisLineColor,
+                                                                    this.echartservice.SplitLineColor);
+            
+             // 设置标题文本
+             this.options.title.subtext = '超期胶料趋势图';
+
+             // 设置图例
+             this.options.legend.data = new Array(1);
+             this.options.legend.data[0] = {
+               name: this.legend,
+               icon: 'rect',
+               // textStyle: { color: this.echartservice.Colors[i] }
+             };
+ 
+              for(let i = 0; i < res.result.length; i++) {
+               //debugger;
+               //获取所有时间作为横坐标
+               this.xaxis[i] = res.result[i][0];
+               this.weightArray[i] = res.result[i][2];
+               this.num[i] = res.result[i][1];              
+             }
+ 
+             //将横坐标转换为数组Array对象
+             let xaxisArray: number[] = new Array(res.result.length);
+             let numArray: number[] = new Array(res.result.length);
+             let weightArrayArray: number[] = new Array(res.result.length);
+
+             for(let i = 0; i < xaxisArray.length; i++) 
+             {
+               xaxisArray[i] = this.xaxis[i];
+               numArray[i] = this.num[i];
+               weightArrayArray = this.weightArray[i];
+             }
+ 
+             // 设置X轴的数据的点
+             this.options.xAxis.data = xaxisArray;
+ 
+             // 设置曲线个数
+             this.options.series = new Array(1); 
+ 
+             // 设置曲线名称及数据 
+             this.options.series[0] = {
+               //曲线名与图例名相对应才会显示
+               name: this.legend,
+               type:'line',
+               smooth : true,
+               stack: '',
+               data: numArray,
+               markLine: { },
+               // lineStyle: {
+               //   color: this.echartservice.Colors[i]
+               // }
+             };
+            
+             // 设置Y轴最小值
+             let tempmin = Math.min.apply(null, numArray);
+             this.options.yAxis.min = Math.min(tempmin, this.options.yAxis.min);
+             
+             // 设置Y轴最大值
+             let tempmax = Math.max.apply(null,numArray);
+             this.options.yAxis.max = Math.max(tempmax, this.options.yAxis.max);
+            
+          }
+        } else {
+          console.warn('请求后台接口[getBusOutValidChart]异常!');
+        }
+      }).catch(err => {
+        console.error(err);
+      });
+    });
+  }
+}

+ 28 - 0
src/app/func/chaoqi/out-valid-result/out-valid-result.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { OutValidResultPage } from './out-valid-result.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: OutValidResultPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [OutValidResultPage]
+})
+export class OutValidResultPageModule {}

+ 48 - 0
src/app/func/chaoqi/out-valid-result/out-valid-result.page.html

@@ -0,0 +1,48 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_outValid_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 下拉刷新 -->
+  <ion-refresher slot="fixed" (ionRefresh)="doDownRefresh($event)">
+    <ion-refresher-content></ion-refresher-content>
+  </ion-refresher>
+  <ion-card *ngFor="let result of resultList; let k = index">
+    <ion-card-content>
+      <ion-list>
+        
+        <ion-item>
+          <ion-icon name="barbell" slot="start" color="primary"></ion-icon>
+          <ion-label>{{'outValidResult_barcoder' | translate}} : {{result[0]}}</ion-label>
+        </ion-item>
+       
+        <ion-item>
+          <ion-icon name="calendar" slot="start" color="primary"></ion-icon>
+          <ion-label>{{'outValidResult_time' | translate}} : {{result[1]}}</ion-label>
+        </ion-item>
+        
+        <ion-item (click)="goChartPage(k)">
+          <ion-icon name="cube" slot="start" color="primary"></ion-icon>
+          <ion-label style="color:rgb(59, 59, 59)">{{'generic_title_materName' | translate}} : {{result[3]}}</ion-label>
+          <ion-icon name="pulse" slot="end" color="primary"></ion-icon>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="barcode" slot="start" color="primary"></ion-icon>
+          <ion-label>{{'outValidResult_weight' | translate}}(KG) : {{result[5]}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <!-- 上拉分页 -->
+  <ion-infinite-scroll threshold="100px" (ionInfinite)="doUpRefresh($event)">
+    <ion-infinite-scroll-content
+      loadingSpinner="bubbles"
+      loadingText="正在加载更多数据...">
+    </ion-infinite-scroll-content>
+  </ion-infinite-scroll>
+</ion-content>

+ 0 - 0
src/app/func/chaoqi/out-valid-result/out-valid-result.page.scss


+ 162 - 0
src/app/func/chaoqi/out-valid-result/out-valid-result.page.ts

@@ -0,0 +1,162 @@
+import { Component, OnInit, ViewChild } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { Storage } from '@ionic/storage';
+import { IonInfiniteScroll } from '@ionic/angular';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { OutValidService } from '../out-valid.service';
+
+@Component({
+  selector: 'app-rubber-product-result',
+  templateUrl: './out-valid-result.page.html',
+  styleUrls: ['./out-valid-result.page.scss'],
+})
+export class OutValidResultPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  infiniteScroll: IonInfiniteScroll;
+  pageIndex = 1;    // 当前页的索引
+  maxPageCount = 5; // 允许显示的最大页数
+  pageSize = 5;     // 每页大小
+  equipList: [];    // 保存选择的机台名称列表
+  resultList: any;   // 保存结果数据的数组
+
+  /** 保存查询参数 */
+  startDate: any = '2016/03/15';
+  endDate: any = '2018/03/30';
+  validHours: any =0;
+  stockNo : any = '';
+  materName  : any ='';
+  outValidDate : any ='';
+
+  constructor(private env: EnvService,
+              private router: Router,
+              private activatedRoute: ActivatedRoute,
+              private storage: Storage,
+              private service: OutValidService) { }
+
+  ngOnInit() {
+    this.resultList = [];
+    this.loadData();
+  }
+
+  /**
+   * 下拉刷新事件处理
+   * @param event 事件
+   */
+  public doDownRefresh(event) {
+    console.log('Begin async operation');
+    this.pageIndex = 1;   // 重新从第1页开始显示
+    this.resultList.splice(0, this.resultList.length);   // 清空原缓存的数据
+    this.loadData();
+    setTimeout(() => {
+      console.log('Async operation has ended');
+      event.target.complete();
+    }, 1000);
+  }
+
+  /**
+   * 上拉刷新加载分页数据
+   * @param event 事件
+   */
+  public doUpRefresh(event) {
+    this.pageIndex++; // 增加一页
+    this.loadData();
+    setTimeout(() => {
+      console.log('Done');
+      event.target.complete();
+
+      // // App logic to determine if all data is loaded
+      // // and disable the infinite scroll
+      if (this.pageIndex >= this.maxPageCount) {
+        event.target.disabled = true;
+      }
+    }, 1000);
+  }
+
+  toggleInfiniteScroll() {
+    this.infiniteScroll.disabled = !this.infiniteScroll.disabled;
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // 从Storage获取customerId
+    this.storage.get('customerId').then((customerId) => {
+      // console.log('----------------------------------------');
+      // console.log('customerId = ' + customerId);
+      // 获取路由参数
+      this.activatedRoute.queryParams.subscribe(param => {
+        //debugger;
+        this.startDate = param['startDate'];
+        this.endDate = param['endDate'];
+        this.validHours = param['validHours'];
+        this.stockNo  = param['stockNo'];
+        const offset: number = (this.pageIndex - 1) * this.pageSize;
+        this.service.getBusOutValidResult(
+                                            param['startDate'],
+                                            param['endDate'],
+                                            param['validHours'],
+                                            param['stockNo'],
+                                            offset,
+                                            this.pageSize).then((res: any) => {
+          if (res && res.state && res.state === '0') {
+            console.log(res);
+            // 把结果数据压入结果数组列表中。
+            //debugger;
+            res.result.forEach((element: never) => {
+              this.resultList.push(element);
+            });
+          } else {
+            console.warn('请求后台接口[getBusOutValidResult]异常!');
+          }
+        }).catch(err => {
+          console.error(err);
+        });
+      });
+    }).catch(error => {
+      console.error('从Storage中获取customerId失败!', error);
+    });
+  }
+
+  /**
+   * 跳转到图表展示页面
+   */
+  public goChartPage(resultIndex: any) {
+    console.log('resultIndex = ' + resultIndex);
+    if (this.resultList && this.resultList.length > resultIndex)
+    {
+      //获取物料名
+      this.materName = this.resultList[resultIndex][3];
+      this.outValidDate = this.resultList[resultIndex][1];
+      const params = { 
+        dsType: 'demoDs', 
+        startDate: this.startDate, 
+        endDate: this.endDate, 
+        materName:this.materName,
+        outValidDate : this.outValidDate,
+        offset :(this.pageIndex - 1) * this.pageSize,
+        limit :this.pageSize,
+        //传递页面显示的参数
+        barcode :this.resultList[resultIndex][0],
+        storehouse :this.resultList[resultIndex][2],
+        rubberType :this.resultList[resultIndex][4],
+        stockWeight :this.resultList[resultIndex][6],
+        convertStdNum :this.resultList[resultIndex][5],
+        equip :this.resultList[resultIndex][7],
+        shift :this.resultList[resultIndex][8],
+        shiftClass :this.resultList[resultIndex][9],
+        usedState :this.resultList[resultIndex][15],
+        dealMeasure :this.resultList[resultIndex][14],
+        quaState :this.resultList[resultIndex][10],
+        quaFlag  :this.resultList[resultIndex][11],
+        quaFinish :this.resultList[resultIndex][12],
+        validDate :this.resultList[resultIndex][16],
+        unQuaReason :this.resultList[resultIndex][13]
+      }
+      this.router.navigate(['/tabs/func/chaoqi/outValidChart'], { queryParams: params });
+    } else {
+      console.warn('要查看的数据索引超过了缓存数据列表的长度!');
+    }
+  }
+
+}

+ 48 - 0
src/app/func/chaoqi/out-valid.service.ts

@@ -0,0 +1,48 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+
+import { EnvService } from '../../wongoing/env.service';
+import { UtilsService } from '../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class OutValidService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取超期胶料结果列表
+   * @param startDate 开始日期yyyy-MM-dd,默认值2016-03-15
+   * @param endDate 结束日期yyyy-MM-dd,默认值2016-03-30
+   * @param validHours 超时小时数
+   * @param stockNo 归属仓库号
+   * @param offset 记录偏移量
+   * @param limit 记录结果限定数
+   */
+  public getBusOutValidResult(startDate: string, endDate:string, validHours: any,stockNo :string,offset: any, limit: any) {
+    const url = this.env.getBusOutValidResult;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'startDate': startDate, 'endDate': endDate,'validHours':validHours,'stockNo':stockNo,'offset': offset, 'limit': limit } };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+  /**
+   * 获取胶料出库趋势图表
+   * @param startDate 开始日期
+   * @param endDate 结束日期
+   * @param materCode 物料编号
+   */
+  public getBusOutValidChart(materName: string, outValidDate : string ,offset:string,limit:string) {
+    const url = this.env.getBusOutValidChart;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'materName': materName, 'outValidDate': outValidDate,'offset':offset,'limit':limit } };
+    return this.http.request(method, url, options).toPromise();
+  }
+}

+ 28 - 0
src/app/func/chuku/chuku.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { ChukuPage } from './chuku.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: ChukuPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [ChukuPage]
+})
+export class ChukuPageModule {}

+ 29 - 0
src/app/func/chuku/chuku.page.html

@@ -0,0 +1,29 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_outStock_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+
+  <ion-list>
+    <!-- 开始时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_startTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.startDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 结束时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_endTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.endDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+   
+  </ion-list>
+
+  <ion-button expand="full" (click)='doSearch()'>{{ 'generic_query' | translate }}</ion-button>
+</ion-content>

+ 0 - 0
src/app/func/chuku/chuku.page.scss


+ 45 - 0
src/app/func/chuku/chuku.page.ts

@@ -0,0 +1,45 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { TranslateService } from '@ngx-translate/core';
+import { Router } from '@angular/router';
+import { BaseService } from 'src/app/wongoing/base.service';
+
+@Component({
+  selector: 'app-chuku',
+  templateUrl: './chuku.page.html',
+  styleUrls: ['./chuku.page.scss'],
+})
+export class ChukuPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+   /** 输入属性-双向绑定 */
+   input = {
+    startDate: '2016-03-15',
+    endDate: '2016-04-30'
+  };
+
+  constructor(private env: EnvService, public translate: TranslateService, private baseService: BaseService, private router : Router) { }
+  
+  /** ng初始化 */
+  ngOnInit() {
+
+  }
+
+
+
+  public doSearch() {
+    // console.log('------------------------------------------');
+    console.log('startDate =' + this.input.startDate);
+    console.log('endDate =' + this.input.endDate);
+
+
+    this.input.startDate = this.input.startDate.substring(0, 10);
+    this.input.startDate.replace(new RegExp(/(-)/g), '/');
+    
+    this.input.endDate = this.input.endDate.substring(0, 10);
+    this.input.endDate.replace(new RegExp(/(-)/g), '/');
+
+
+    this.router.navigate(['/tabs/func/chuku/outStockResult'], { queryParams : this.input });
+  }
+
+}

+ 31 - 0
src/app/func/chuku/out-stock-chart/out-stock-chart.module.ts

@@ -0,0 +1,31 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { NgxEchartsModule } from 'ngx-echarts';
+
+import { OutStockChartPage } from './out-stock-chart.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: OutStockChartPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule,
+    NgxEchartsModule
+  ],
+  declarations: [OutStockChartPage]
+})
+export class OutStockChartPageModule {}

+ 76 - 0
src/app/func/chuku/out-stock-chart/out-stock-chart.page.html

@@ -0,0 +1,76 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_outStock_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-card>
+    <ion-card-content>
+      <ion-list lines="none">
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+          <ion-label>{{ 'generic_startTime' | translate }}</ion-label>
+          <ion-label>{{startDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+          <ion-label>{{ 'generic_endTime' | translate }}</ion-label>
+          <ion-label>{{endDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="book" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_title_materName' | translate }}:</ion-label>
+          <ion-label>{{materName}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="barcode" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_outStock_weight' | translate }}:</ion-label>
+          <ion-label>{{weight}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="cube" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_convertStdNum' | translate }}:</ion-label>
+          <ion-label>{{convertStdNum}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+
+  <ion-card>
+    <ion-card-content>
+      <div echarts [options]="options" class="echarts" style="height:320px;"></div>
+    </ion-card-content>
+  </ion-card>
+
+  <ion-card *ngFor="let result of resultList">
+    <ion-card-content>
+      <ion-list lines="none">
+        <ion-item>
+          <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+          <ion-label>{{ 'generic_date' | translate }}:</ion-label>
+          <ion-label>{{result[0]}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="home" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_outboundStorehouse' | translate }}:</ion-label>
+          <ion-label>{{result[1]}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="home" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_inboundStorehouse' | translate }}:</ion-label>
+          <ion-label>{{result[2]}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="car" slot="start" color="primary"></ion-icon>
+          <ion-label>{{ 'generic_serial' | translate }}:</ion-label>
+          <ion-label>{{result[3]}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+
+</ion-content>

+ 0 - 0
src/app/func/chuku/out-stock-chart/out-stock-chart.page.scss


+ 163 - 0
src/app/func/chuku/out-stock-chart/out-stock-chart.page.ts

@@ -0,0 +1,163 @@
+import { Component, OnInit } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { EnvService } from '../../../wongoing/env.service';
+import { EchartService } from '../../../wongoing/echart.service';
+import { OutStockService } from '../out-stock.service';
+
+@Component({
+  selector: 'app-rubber-product-chart',
+  templateUrl: './out-stock-chart.page.html',
+  styleUrls: ['./out-stock-chart.page.scss'],
+})
+export class OutStockChartPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  resultList: any;   // 保存结果数据的数组
+  options: any = {};   //echart图表选项
+  //保存横坐标
+  xaxis:any = {};
+  //保存重量
+  weightArray:any = {};
+  //保存数量
+  num:any = {};
+  /** 保存查询参数 */
+  startDate: any = '2016/03/15';
+  endDate: any = '2016/03/30';
+  materCode: any = '';
+  materName: any = '';
+  offset :any = '';
+  limit : any = '';
+  weight :any = '';
+  convertStdNum :any = '';
+  constructor(private router: Router, private activatedRoute: ActivatedRoute,private env: EnvService, private echartservice: EchartService, private service: OutStockService) { }
+
+  ngOnInit() {
+    this.resultList = [];
+    this.loadData();
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // console.log('----------------------------------------');
+    // 获取路由参数
+    this.activatedRoute.queryParams.subscribe(param => {
+      this.startDate = param['startDate'];
+      this.endDate = param['endDate'];
+      this.materCode = param['materCode'];
+      this.materName = param['materName'];
+      this.offset = param['offset'];
+      this.limit = param['limit'];
+      this.weight = param['weight'];
+      this.convertStdNum = param['convertStdNum'];
+
+      //debugger;
+      this.startDate = this.startDate.substring(0, 10);
+      this.startDate.replace(new RegExp(/(-)/g), '/');
+    
+      this.endDate = this.endDate.substring(0, 10);
+      this.endDate.replace(new RegExp(/(-)/g), '/');
+      
+      //渲染图表
+      this.service.getBusOutStockChart(this.startDate,
+                                          this.endDate,
+                                          this.materCode,
+                                          this.offset,
+                                          this.limit).then((res: any) => {
+        if (res && res.state && res.state === '0') {
+          console.log(res);
+          //debugger;
+          if (res.result && res.result.length > 0) {
+            this.options = this.echartservice.getLineOptionsTemplate(this.echartservice.SuccessColor,
+                                                                    this.echartservice.InfoColor,
+                                                                    this.echartservice.TextColor,
+                                                                    this.echartservice.AxisLineColor,
+                                                                    this.echartservice.SplitLineColor);
+            
+            // 设置标题文本
+            this.options.title.subtext = '胶料出库趋势图';
+
+            // 设置图例
+            this.options.legend.data = new Array(1);
+            this.options.legend.data[0] = {
+              name: res.result[0][1],//物料名作为图例名
+              icon: 'rect',
+              // textStyle: { color: this.echartservice.Colors[i] }
+            };
+
+             for(let i = 0; i < res.result.length; i++) {
+              //debugger;
+              //获取所有时间作为横坐标
+              this.xaxis[i] = res.result[i][0];
+              this.weightArray[i] = res.result[i][3];
+              this.num[i] = res.result[i][4];              
+            }
+
+            //将横坐标转换为数组Array对象
+            let xaxisArray: number[] = new Array(res.result.length);
+            let numArray: number[] = new Array(res.result.length);
+            for(let i = 0; i < xaxisArray.length; i++) 
+            {
+              xaxisArray[i] = this.xaxis[i];
+              numArray[i] = this.num[i];
+            }
+
+            // 设置X轴的数据的点
+            this.options.xAxis.data = xaxisArray;
+
+            // 设置曲线个数
+            this.options.series = new Array(1); 
+
+            // 设置曲线名称及数据 
+            this.options.series[0] = {
+              //曲线名与图例名相对应才会显示
+              name: res.result[0][1],
+              type:'line',
+              smooth : true,
+              stack: '',
+              data: numArray,
+              markLine: { },
+              // lineStyle: {
+              //   color: this.echartservice.Colors[i]
+              // }
+            };
+           
+            // 设置Y轴最小值
+            let tempmin = Math.min.apply(null, numArray);
+            this.options.yAxis.min = Math.min(tempmin, this.options.yAxis.min);
+            
+            // 设置Y轴最大值
+            let tempmax = Math.max.apply(null,numArray);
+            this.options.yAxis.max = Math.max(tempmax, this.options.yAxis.max);
+            
+          }
+        } else {
+          console.warn('请求后台接口[getBusOutStockChart]异常!');
+        }
+      }).catch(err => {
+        console.error(err);
+      });
+
+      //加载列表数据
+      this.service.getBusOutStockChartList(
+                        param['startDate'],
+                        param['endDate'],
+                        param['materCode']
+                      ).then((res: any) => {
+        if (res && res.state && res.state === '0') {
+        console.log(res);
+        //debugger;
+        // 把结果数据压入结果数组列表中。
+        res.result.forEach((element: never) => {
+        this.resultList.push(element);
+        });
+        } else {
+        console.warn('请求后台接口[getBusOutStockChartList]异常!');
+        }
+        }).catch(err => {
+        console.error(err);
+        });
+
+    });
+  }
+}

+ 28 - 0
src/app/func/chuku/out-stock-result/out-stock-result.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { OutStockResultPage } from './out-stock-result.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: OutStockResultPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [OutStockResultPage]
+})
+export class OutStockResultPageModule {}

+ 41 - 0
src/app/func/chuku/out-stock-result/out-stock-result.page.html

@@ -0,0 +1,41 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_outStock_title' | translate}}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 下拉刷新 -->
+  <ion-refresher slot="fixed" (ionRefresh)="doDownRefresh($event)">
+    <ion-refresher-content></ion-refresher-content>
+  </ion-refresher>
+  <ion-card *ngFor="let result of resultList; let k = index">
+    <ion-card-content>
+      <ion-list>
+        <ion-item>
+          <ion-icon name="book" slot="start" color="primary"></ion-icon>
+          <ion-label>{{'generic_title_materName'|translate}}:<span style="color:red">{{result[0]}}</span></ion-label>
+        </ion-item>
+        <ion-item (click)="goChartPage(k)">
+          <ion-icon name="barcode" slot="start" color="primary"></ion-icon>
+          <ion-label style="color:blue">{{'generic_outStock_weight'|translate}}:{{result[2]}}</ion-label>
+          <ion-icon name="pulse" slot="end" color="primary"></ion-icon>
+        </ion-item>
+        <ion-item>
+          <ion-icon name="cube" slot="start" color="primary"></ion-icon>
+          <ion-label>{{'generic_convertStdNum'|translate}}:{{result[3]}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <!-- 上拉分页 -->
+  <ion-infinite-scroll threshold="100px" (ionInfinite)="doUpRefresh($event)">
+    <ion-infinite-scroll-content
+      loadingSpinner="bubbles"
+      loadingText="正在加载更多数据...">
+    </ion-infinite-scroll-content>
+  </ion-infinite-scroll>
+</ion-content>

+ 0 - 0
src/app/func/chuku/out-stock-result/out-stock-result.page.scss


+ 138 - 0
src/app/func/chuku/out-stock-result/out-stock-result.page.ts

@@ -0,0 +1,138 @@
+import { Component, OnInit, ViewChild } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { Storage } from '@ionic/storage';
+import { IonInfiniteScroll } from '@ionic/angular';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { OutStockService } from '../out-stock.service';
+
+@Component({
+  selector: 'app-out-stock-result',
+  templateUrl: './out-stock-result.page.html',
+  styleUrls: ['./out-stock-result.page.scss'],
+})
+export class OutStockResultPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  infiniteScroll: IonInfiniteScroll;
+  pageIndex = 1;    // 当前页的索引
+  maxPageCount = 5; // 允许显示的最大页数
+  pageSize = 5;     // 每页大小
+  resultList: any;   // 保存结果数据的数组
+
+  /** 保存查询参数 */
+  startDate: any = '2016/03/15';
+  endDate: any = '2018/03/30';
+  materCode: any = '';
+  constructor(private env: EnvService,
+              private router: Router,
+              private activatedRoute: ActivatedRoute,
+              private storage: Storage,
+              private service: OutStockService) { }
+
+  ngOnInit() {
+    this.resultList = [];
+    this.loadData();
+  }
+
+  /**
+   * 下拉刷新事件处理
+   * @param event 事件
+   */
+  public doDownRefresh(event) {
+    console.log('Begin async operation');
+    this.pageIndex = 1;   // 重新从第1页开始显示
+    this.resultList.splice(0, this.resultList.length);   // 清空原缓存的数据
+    this.loadData();
+    setTimeout(() => {
+      console.log('Async operation has ended');
+      event.target.complete();
+    }, 1000);
+  }
+
+  /**
+   * 上拉刷新加载分页数据
+   * @param event 事件
+   */
+  public doUpRefresh(event) {
+    this.pageIndex++; // 增加一页
+    this.loadData();
+    setTimeout(() => {
+      console.log('Done');
+      event.target.complete();
+
+      // // App logic to determine if all data is loaded
+      // // and disable the infinite scroll
+      if (this.pageIndex >= this.maxPageCount) {
+        event.target.disabled = true;
+      }
+    }, 1000);
+  }
+
+  toggleInfiniteScroll() {
+    this.infiniteScroll.disabled = !this.infiniteScroll.disabled;
+  }
+
+  /**
+   * 数据加载
+   */
+  public loadData() {
+    // 从Storage获取customerId
+    this.storage.get('customerId').then((customerId) => {
+      // console.log('----------------------------------------');
+      // console.log('customerId = ' + customerId);
+      // 获取路由参数
+      this.activatedRoute.queryParams.subscribe(param => {
+        this.startDate = param['startDate'];
+        this.endDate = param['endDate'];
+        const offset: number = (this.pageIndex - 1) * this.pageSize;
+        this.service.getBusOutStockResult(
+                                            param['startDate'],
+                                            param['endDate'],
+                                            offset,
+                                            this.pageSize).then((res: any) => {
+          if (res && res.state && res.state === '0') {
+            console.log(res);
+            //debugger;
+            // 把结果数据压入结果数组列表中。
+            res.result.forEach((element: never) => {
+              this.resultList.push(element);
+            });
+          } else {
+            console.warn('请求后台接口[getBusOutStockResult]异常!');
+          }
+        }).catch(err => {
+          console.error(err);
+        });
+      });
+    }).catch(error => {
+      console.error('从Storage中获取customerId失败!', error);
+    });
+  }
+
+  /**
+   * 跳转到图表展示页面
+   */
+  public goChartPage(resultIndex: any) {
+    console.log('resultIndex = ' + resultIndex);
+    if (this.resultList && this.resultList.length > resultIndex)
+    {
+      //获取物料编码
+      this.materCode = this.resultList[resultIndex][1];
+
+      const params = { 
+        dsType: 'demoDs', 
+        startDate: this.startDate, 
+        endDate: this.endDate, 
+        materCode :this.materCode,
+        offset :(this.pageIndex - 1) * this.pageSize,
+        limit : this.pageSize,
+        materName :this.resultList[resultIndex][0],
+        weight :this.resultList[resultIndex][2],
+        convertStdNum :this.resultList[resultIndex][3]
+      }
+      this.router.navigate(['/tabs/func/chuku/outStockChart'], { queryParams: params });
+    } else {
+      console.warn('要查看的数据索引超过了缓存数据列表的长度!');
+    }
+  }
+
+}

+ 64 - 0
src/app/func/chuku/out-stock.service.ts

@@ -0,0 +1,64 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+
+import { EnvService } from '../../wongoing/env.service';
+import { UtilsService } from '../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class OutStockService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取胶料出库结果列表
+   * @param startDate 开始日期yyyy-MM-dd,默认值2016-03-15
+   * @param endDate 结束日期yyyy-MM-dd,默认值2016-03-30
+   * @param offset 记录偏移量
+   * @param limit 记录结果限定数
+   */
+  public getBusOutStockResult(startDate: string, endDate:string, offset: any, limit: any) {
+    const url = this.env.getBusOutStockResult;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'startDate': startDate, 'endDate': endDate,'offset': offset, 'limit': limit } };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+    
+  /**
+   * 获取胶料出库趋势图表
+   * @param startDate 开始日期
+   * @param endDate 结束日期
+   * @param materCode 物料编号
+   */
+  public getBusOutStockChart(startDate: string, endDate:string, materCode: string,offset :string,limit:string) {
+    const url = this.env.getBusOutStockChart;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'startDate': startDate, 'endDate': endDate,'materCode': materCode ,'offset':offset,'limit':limit} };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+  /**
+   * 获取胶料出库趋势图表列表
+   * @param startDate 开始日期
+   * @param endDate 结束日期
+   * @param materCode 物料编码
+   */
+  public getBusOutStockChartList(startDate: string, endDate:string, materCode: string) {
+    const url = this.env.getBusOutStockChartList;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const data  = null;
+    const options = { params: { 'dsType': dsType, 'startDate': startDate, 'endDate': endDate,'materCode': materCode } };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+}

+ 19 - 0
src/app/func/func.module.ts

@@ -0,0 +1,19 @@
+import { IonicModule } from '@ionic/angular';
+import { RouterModule } from '@angular/router';
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { TranslateModule } from '@ngx-translate/core';
+import { FuncPage } from './func.page';
+
+@NgModule({
+  imports: [
+    IonicModule,
+    CommonModule,
+    FormsModule,
+    RouterModule.forChild([{ path: '', component: FuncPage }]),
+    TranslateModule
+  ],
+  declarations: [FuncPage]
+})
+export class FuncPageModule { }

+ 83 - 0
src/app/func/func.page.html

@@ -0,0 +1,83 @@
+<ion-header *ngIf="isShowHeader">
+    <ion-toolbar>
+        <ion-title>{{ 'funcMain_title' | translate }}</ion-title>
+    </ion-toolbar>
+</ion-header>
+<ion-content forceOverscroll="false">
+    <div *ngIf="isGetDataSuccess">
+        <ion-list lines="none" *ngFor="let module of modules">
+            <ion-list-header>
+                <ion-label class="tt">{{module.moduleName}}</ion-label>
+            </ion-list-header>
+            <ion-item *ngFor="let func of module.data" [routerLink]="[func.type]" detail>
+                <ion-icon slot="start" src="/assets/svg/{{func.type}}-primary.svg"></ion-icon>
+                <ion-label>{{func.functionName}}</ion-label>
+            </ion-item>
+        </ion-list>
+    </div>
+    <div *ngIf="! isGetDataSuccess">
+        <ion-list lines="none">
+            <ion-list-header>
+                <ion-label class="tt">生产功能</ion-label>
+            </ion-list-header>
+            <ion-item [routerLink]="['/tabs/func/chanliang']" detail>
+                <ion-icon slot="start" src="/assets/svg/chanliang-primary.svg"></ion-icon>
+                <ion-label>胶料产量分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/xiaohao']" detail>
+                <ion-icon slot="start" src="/assets/svg/xiaohao-primary.svg"></ion-icon>
+                <ion-label>原料消耗分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/touruchanchu']" detail>
+                <ion-icon slot="start" src="/assets/svg/touruchanchu-primary.svg"></ion-icon>
+                <ion-label>投入产出分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/jihua']" detail>
+                <ion-icon slot="start" src="/assets/svg/jihua-primary.svg"></ion-icon>
+                <ion-label>计划执行监控</ion-label>
+            </ion-item>
+        </ion-list>
+        <ion-list lines="none">
+            <ion-list-header>
+                <ion-label class="tt">库存功能</ion-label>
+            </ion-list-header>
+            <ion-item [routerLink]="['/tabs/func/balanceSummary']" detail>
+                <ion-icon slot="start" src="/assets/svg/balanceSummary-primary.svg"></ion-icon>
+                <ion-label>胶料结存分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/chuku']" detail>
+                <ion-icon slot="start" src="/assets/svg/chuku-primary.svg"></ion-icon>
+                <ion-label>出库汇总分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/ruku']" detail>
+                <ion-icon slot="start" src="/assets/svg/ruku-primary.svg"></ion-icon>
+                <ion-label>入库汇总分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/chaoqi']" detail>
+                <ion-icon slot="start" src="/assets/svg/chaoqi-primary.svg"></ion-icon>
+                <ion-label>超期胶料分析</ion-label>
+            </ion-item>
+        </ion-list>
+        <ion-list lines="none">
+            <ion-list-header>
+                <ion-label class="tt">质量功能</ion-label>
+            </ion-list-header>
+            <ion-item [routerLink]="['/tabs/func/jiance']" detail>
+                <ion-icon slot="start" src="/assets/svg/jiance-primary.svg"></ion-icon>
+                <ion-label>胶料快检趋势分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/hegefenxi']" detail>
+                <ion-icon slot="start" src="/assets/svg/hegefenxi-primary.svg"></ion-icon>
+                <ion-label>胶料总体合格率分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/spc']" detail>
+                <ion-icon slot="start" src="/assets/svg/spc-primary.svg"></ion-icon>
+                <ion-label>胶料质量SPC分析</ion-label>
+            </ion-item>
+            <ion-item [routerLink]="['/tabs/func/kuhegefenxi']" detail>
+                <ion-icon slot="start" src="/assets/svg/kuhegefenxi-primary.svg"></ion-icon>
+                <ion-label>胶料分类合格率分析</ion-label>
+            </ion-item>
+        </ion-list>
+    </div>
+</ion-content>

+ 5 - 0
src/app/func/func.page.scss

@@ -0,0 +1,5 @@
+.tt {
+    margin-left:10px;
+    font-size:16px;
+    font-weight: normal;
+}

+ 35 - 0
src/app/func/func.page.ts

@@ -0,0 +1,35 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from '../wongoing/env.service';
+import { FuncService } from './func.service';
+
+@Component({
+  selector: 'app-func',
+  templateUrl: 'func.page.html',
+  styleUrls: ['func.page.scss']
+})
+export class FuncPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  isGetDataSuccess = true;                        //是否获取网络数据成功
+  /** 功能模块数据 */
+  modules: any[];
+
+  constructor(private env: EnvService, private service: FuncService) {  }
+
+  ngOnInit() {
+    console.log('isShowHeader is ' + this.isShowHeader);
+    this.service.getData(1).then((res: any) => {
+      console.log('getSysFunctionList调用完毕...');
+      console.log(res);
+      if (res && res.state && res.state === '0') {
+         this.modules = res.result;
+      } else {
+        this.isGetDataSuccess = false;
+        console.warn('请求后台接口[getSysFunctionList]异常!');
+      }
+    }).catch(err => {
+      this.isGetDataSuccess = false;
+      console.log('http请求异常!');
+      console.error(err);
+    });
+  }
+}

+ 24 - 0
src/app/func/func.service.ts

@@ -0,0 +1,24 @@
+import { Injectable } from '@angular/core';
+import { HttpClient, HttpParams } from '@angular/common/http';
+
+import { EnvService } from '../wongoing/env.service';
+import { UtilsService } from '../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class FuncService {
+  /** 注入依赖 */
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取远程接口数据
+   */
+  public getData(customerId) {
+    const url = this.env.getSysFunctionList;
+    const method = 'GET';
+    const data  = null;
+    const options = { params: { 'customerId': customerId } };
+    return this.http.request(method, url, options).toPromise();
+  }
+}

+ 28 - 0
src/app/func/hegefenxi/hegefenxi.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { HegefenxiPage } from './hegefenxi.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: HegefenxiPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [HegefenxiPage]
+})
+export class HegefenxiPageModule {}

+ 26 - 0
src/app/func/hegefenxi/hegefenxi.page.html

@@ -0,0 +1,26 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_totalQuaRate_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-list>
+    <!-- 开始时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_startTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.startDate" display-format="YYYY-MM-DD" picker-format="YYYY-MM-DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 结束时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_endTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.endDate" display-format="YYYY-MM-DD" picker-format="YYYY-MM-DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+  </ion-list>
+  <ion-button expand="full" (click)="doSearch()">{{ 'generic_query' | translate }}</ion-button>
+</ion-content>

+ 0 - 0
src/app/func/hegefenxi/hegefenxi.page.scss


+ 29 - 0
src/app/func/hegefenxi/hegefenxi.page.ts

@@ -0,0 +1,29 @@
+import { Component, OnInit } from '@angular/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { EnvService } from 'src/app/wongoing/env.service';
+
+@Component({
+  selector: 'app-hegefenxi',
+  templateUrl: './hegefenxi.page.html',
+  styleUrls: ['./hegefenxi.page.scss'],
+})
+export class HegefenxiPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  /** 输入属性-双向绑定 */
+  input = {
+    startDate: '2016-01-08',
+    endDate: '2016-01-20'
+  };
+
+  constructor(private env: EnvService, private router: Router) { }
+
+  ngOnInit() {
+  }
+
+  /**
+   * 执行查询跳转到图表页
+   */
+  public doSearch() {
+    this.router.navigate(['/tabs/func/hegefenxi/rubberpassratechart'], { queryParams: this.input });
+  }
+}

+ 26 - 0
src/app/func/hegefenxi/hegefenxi.service.ts

@@ -0,0 +1,26 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+import { EnvService } from '../../wongoing/env.service';
+import { UtilsService } from '../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class HegefenxiService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取总体合格率
+   * @param startTime 开始日期,格式[yyyy-MM-dd]
+   * @param endTime 结束日期,格式[yyyy-MM-dd]
+   */
+  public getRubberPassRate(startTime, endTime) {
+    const url = this.env.getRubberPassRate;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const options = { params: { 'startTime': startTime, 'endTime': endTime } };
+    return this.http.request(method, url, options).toPromise();
+  }
+}

+ 26 - 0
src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.module.ts

@@ -0,0 +1,26 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+import { NgxEchartsModule } from 'ngx-echarts';
+import { RubberPassRateChartPage } from './rubber-pass-rate-chart.page';
+const routes: Routes = [
+  {
+    path: '',
+    component: RubberPassRateChartPage
+  }
+];
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule,
+    NgxEchartsModule
+  ],
+  declarations: [RubberPassRateChartPage]
+})
+export class RubberPassRateChartPageModule {}

+ 74 - 0
src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.page.html

@@ -0,0 +1,74 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_totalQuaRate_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-card>
+    <ion-card-header>
+      <ion-card-subtitle>{{ 'rubberPassRateChart_title_chart' | translate }}</ion-card-subtitle>
+    </ion-card-header>
+    <ion-card-content>
+      <div echarts [options]="options" class="echarts" style="height:320px;"></div>
+    </ion-card-content>
+  </ion-card>
+  <ion-card>
+    <ion-card-content>
+      <ion-list>
+        <ion-item>
+          <ion-label>DATE:<br>{{ 'rubberPassRateChart_checkDate' | translate }}</ion-label>
+          <ion-label>DO:<br>{{ 'rubberPassRateChart_dayOutput' | translate }}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>DQN:<br>{{ 'rubberPassRateChart_dayQuaNum' | translate }}</ion-label>
+          <ion-label>DQR:<br>{{ 'rubberPassRateChart_dayQuaRate' | translate }}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>CO:<br>{{ 'rubberPassRateChart_cumulatedOutput' | translate }}</ion-label>
+          <ion-label>CQN:<br>{{ 'rubberPassRateChart_cumulatedQuaNum' | translate }}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>CQR:<br>{{ 'rubberPassRateChart_cumulatedQuaRate' | translate }}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+  <ion-card *ngFor="let item of resultList">
+    <ion-card-content>
+      <ion-list>
+        <ion-item>
+          <ion-label>DATE</ion-label>
+          <ion-label>{{item.checkDateSimple}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>DO</ion-label>
+          <ion-label>{{item.dayTotal}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>DQN</ion-label>
+          <ion-label>{{item.dayQuaNum}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>DQR</ion-label>
+          <ion-label>{{item.dayPassRate}}%</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>CO</ion-label>
+          <ion-label>{{item.cumProd}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>CQN</ion-label>
+          <ion-label>{{item.cumQuaNum}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>CQR</ion-label>
+          <ion-label>{{item.cumPassRate}}%</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+</ion-content>

+ 0 - 0
src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.page.scss


+ 112 - 0
src/app/func/hegefenxi/rubber-pass-rate-chart/rubber-pass-rate-chart.page.ts

@@ -0,0 +1,112 @@
+import { Component, OnInit } from '@angular/core';
+import { TranslateService } from '@ngx-translate/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { EchartService } from 'src/app/wongoing/echart.service';
+import { HegefenxiService } from '../hegefenxi.service';
+@Component({
+  selector: 'app-rubber-pass-rate-chart',
+  templateUrl: './rubber-pass-rate-chart.page.html',
+  styleUrls: ['./rubber-pass-rate-chart.page.scss'],
+})
+export class RubberPassRateChartPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  options: any = {};    // echart图标选项
+  // 保存查询参数
+  input: any = {};
+  resultList: any;
+  constructor(private env: EnvService, private translate: TranslateService, private router: Router, private activateRoute: ActivatedRoute, private echartService: EchartService, private hegefenxiService: HegefenxiService) { }
+
+  ngOnInit() {
+    this.getQueryParams();
+    this.initData();
+  }
+
+  /**
+   * 获取查询参数
+   */
+  public async getQueryParams() {
+    this.input = this.activateRoute.snapshot.queryParams;
+  }
+
+  /**
+   * 初始化数据
+   */
+  public async initData() {
+    const res: any = await this.hegefenxiService.getRubberPassRate(this.input.startDate, this.input.endDate);
+    console.log(res);
+    if (res && res.state && res.state == '0') {
+      this.resultList = res.result;
+      this.initChartOption(this.resultList);
+    } else {
+      console.warn('请求远程接口[getRubberPassRate]异常!');
+    }
+  }
+
+  /**
+   * 初始化图标选项
+   * @param data 图标数据
+   */
+  public async initChartOption(data) {
+    this.options = this.echartService.getLineOptionsTemplate(this.echartService.SuccessColor,
+      this.echartService.InfoColor,
+      this.echartService.TextColor,
+      this.echartService.AxisLineColor,
+      this.echartService.SplitLineColor);
+    
+    // 设置标题文本
+    this.options.title.subtext = '';
+    this.options.grid.top = 30;
+    this.options.grid.bottom = 5;
+    this.options.grid.left = 0;
+    this.options.grid.right = '4%';
+    // 设置图例
+    this.options.legend.data = new Array(2);
+    let names = [2];
+    names[0] = await this.translate.get('rubberPassRateChart_dayQuaRate').toPromise();
+    names[1] = await this.translate.get('rubberPassRateChart_cumulatedQuaRate').toPromise();
+    this.options.legend.data[0] = { name: names[0], icon: 'rect' };
+    this.options.legend.data[1] = { name: names[1], icon: 'rect' };
+    
+    // X轴的数据
+    let xAxisValues = [];
+    let yAxisValues1 = [];
+    let yAxisValues2 = [];
+    for(let i = 0; i < data.length; i++) {
+      xAxisValues.push(data[i].checkDateSimple);
+      yAxisValues1.push(data[i].dayPassRate);
+      yAxisValues2.push(data[i].cumPassRate);
+    }
+    this.options.xAxis.data = xAxisValues;
+
+    // 曲线数据
+    this.options.series = new Array(2);
+    this.options.series[0] = {
+      name: names[0],
+      type: 'line',
+      smooth: true,
+      stack: '',
+      data: yAxisValues1,
+      markLine: {},
+    };
+    this.options.series[1] = {
+      name: names[1],
+      type: 'line',
+      smooth: true,
+      stack: '',
+      data: yAxisValues2,
+      markLine: {},
+    };
+
+    const min1 = Math.min.apply(null, yAxisValues1);
+    const min2 = Math.min.apply(null, yAxisValues2);
+    const min = Math.min(min1, min2);
+
+    const max1 = Math.max.apply(null, yAxisValues1);
+    const max2 = Math.max.apply(null, yAxisValues2);
+    const max = Math.max(max1, max2);
+
+    this.options.yAxis.min = min;
+    this.options.yAxis.max = max;
+  }
+}

+ 26 - 0
src/app/func/jiance/fast-exam-chart/fast-exam-chart.module.ts

@@ -0,0 +1,26 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+import { NgxEchartsModule } from 'ngx-echarts';
+import { FastExamChartPage } from './fast-exam-chart.page';
+const routes: Routes = [
+  {
+    path: '',
+    component: FastExamChartPage
+  }
+];
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule,
+    NgxEchartsModule
+  ],
+  declarations: [FastExamChartPage]
+})
+export class FastExamChartPageModule {}

+ 70 - 0
src/app/func/jiance/fast-exam-chart/fast-exam-chart.page.html

@@ -0,0 +1,70 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_fastExam_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-card>
+    <ion-card-header>
+      <ion-card-subtitle>
+        ({{queryParam.itemName}}){{ 'fastExamChart_meanControlChart' | translate }}(%)
+      </ion-card-subtitle>
+    </ion-card-header>
+    <ion-card-content>
+      <div echarts [options]="optionsAvg" class="echarts" style="height:240px;"></div>
+    </ion-card-content>
+  </ion-card>
+  <ion-card>
+    <ion-card-header>
+      <ion-card-subtitle>
+        ({{queryParam.itemName}}){{ 'fastExamChart_rangeControlChart' | translate }}
+      </ion-card-subtitle>
+    </ion-card-header>
+    <ion-card-content>
+      <div echarts [options]="optionsRange" class="echarts" style="height:240px;"></div>
+    </ion-card-content>
+  </ion-card>
+
+  <ion-card>
+    <ion-card-content>
+      <ion-list>
+        <ion-item>
+          <ion-label>{{ 'generic_startTime' | translate }}</ion-label>
+          <ion-label>{{queryParam.startDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_endTime' | translate }}</ion-label>
+          <ion-label>{{queryParam.endDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_materName' | translate}}</ion-label>
+          <ion-label>{{queryParam.materName}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'fastExamSearch_checkItem' | translate }}</ion-label>
+          <ion-label>{{queryParam.itemName}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_equip' | translate }}</ion-label>
+          <ion-label>{{queryParam.equipName}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_shift' | translate }}</ion-label>
+          <ion-label>{{queryParam.shiftClassName}}</ion-label>
+        </ion-item>
+        <!-- <ion-item>
+          <ion-label>{{ 'fastExamChart_perMax' | translate }}</ion-label>
+          <ion-label>{{queryParam.perMax}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'fastExamChart_perMin' | translate }}</ion-label>
+          <ion-label>{{queryParam.perMin}}</ion-label>
+        </ion-item> -->
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+</ion-content>

+ 0 - 0
src/app/func/jiance/fast-exam-chart/fast-exam-chart.page.scss


+ 156 - 0
src/app/func/jiance/fast-exam-chart/fast-exam-chart.page.ts

@@ -0,0 +1,156 @@
+import { Component, OnInit } from '@angular/core';
+import { TranslateService } from '@ngx-translate/core';
+import { ActivatedRoute } from '@angular/router';
+import { Storage } from '@ionic/storage';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { EchartService } from 'src/app/wongoing/echart.service';
+import { JianceService } from '../jiance.service';
+
+@Component({
+  selector: 'app-fast-exam-chart',
+  templateUrl: './fast-exam-chart.page.html',
+  styleUrls: ['./fast-exam-chart.page.scss'],
+})
+export class FastExamChartPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  // 保存请求参数
+  queryParam: any = {};
+  item: any = {};
+
+  // echart图表选项
+  optionsAvg: any = {};     // 均值控制图图表选项
+  optionsRange: any = {};   // 极差控制图图表选项
+  constructor(private env: EnvService, private translate: TranslateService, private activatedRoute: ActivatedRoute, private storage: Storage, private echartService: EchartService, private jianceService: JianceService) { }
+
+  ngOnInit() {
+    this.getQueryParams();
+    this.initData();
+  }
+
+  /**
+   * 获取查询参数
+   */
+  public getQueryParams() {
+    this.queryParam = this.activatedRoute.snapshot.queryParams;
+  }
+
+  /**
+   * 从缓存中获取数据
+   */
+  public async initData() {
+    const res: any = await this.jianceService.getFastExaminationItemList(this.queryParam.startDate, this.queryParam.endDate, this.queryParam.itemCode, this.queryParam.itemName, this.queryParam.equipCode, this.queryParam.shiftClassId, this.queryParam.materCode);
+    console.log(res);
+    if (res && res.state && res.state == '0') {
+      const chartData = res.result;
+      if (chartData && chartData.length > 0) {
+        this.item = chartData[0];
+        this.initAvgData(this.item);
+        this.initRangeData(this.item);
+      }
+    } else {
+      console.warn('调用远程接口[getFastExaminationItemList]异常!');
+    }
+  }
+
+  /**
+   * 初始化均值控制图
+   * @param xbarData 均值控制图数据
+   */
+  public async initAvgData(xbarData) {
+    let opXbarCtrLine = this.echartService.getMarkLineTemplate();
+    /* mean value ucl,cl,lcl data setting */
+    opXbarCtrLine.data[0][0].label.normal.formatter = 'UCL=' + xbarData.xbarUcl;
+    opXbarCtrLine.data[0][0].tooltip.formatter = 'UCL=' + xbarData.xbarUcl;
+    opXbarCtrLine.data[0][0].coord = [0, xbarData.xbarUcl];
+    opXbarCtrLine.data[0][1].coord = [xbarData.xbarGroupAveArr.length - 1, xbarData.xbarUcl];
+    opXbarCtrLine.data[1][0].label.normal.formatter = 'CL=' + xbarData.xbarAve;
+    opXbarCtrLine.data[1][0].tooltip.formatter = 'CL=' + xbarData.xbarAve;
+    opXbarCtrLine.data[1][0].coord = [0, xbarData.xbarAve];
+    opXbarCtrLine.data[1][1].coord = [xbarData.xbarGroupAveArr.length - 1, xbarData.xbarAve];
+    opXbarCtrLine.data[2][0].label.normal.formatter = 'LCL=' + xbarData.xbarLcl;
+    opXbarCtrLine.data[2][0].tooltip.formatter = 'LCL=' + xbarData.xbarLcl;
+    opXbarCtrLine.data[2][0].coord = [0, xbarData.xbarLcl];
+    opXbarCtrLine.data[2][1].coord = [xbarData.xbarGroupAveArr.length - 1, xbarData.xbarLcl];
+
+    this.optionsAvg = this.echartService.getLineOptionsTemplate(this.echartService.SuccessColor,
+      this.echartService.InfoColor,
+      this.echartService.TextColor,
+      this.echartService.AxisLineColor,
+      this.echartService.SplitLineColor);
+    
+    this.optionsAvg.title.subtext = '';
+    // this.optionsAvg.legend = null;
+    this.optionsAvg.grid.top = 10;
+    this.optionsAvg.grid.bottom = 5;
+    this.optionsAvg.left = 0;
+    this.optionsAvg.right = '4%';
+
+    let xAxisValues = [];
+    if (xbarData.xbarGroupAveArr && xbarData.xbarGroupAveArr.length > 0) {
+      for(let i = 0; i < xbarData.xbarGroupAveArr.length; i++) {
+        xAxisValues.push(i);
+      }
+    }
+    this.optionsAvg.xAxis.data = xAxisValues;
+
+    const max = Math.max(Math.max.apply(null, xbarData.xbarGroupAveArr), xbarData.xbarUcl);
+    const min = Math.min(Math.min.apply(null, xbarData.xbarGroupAveArr), xbarData.xbarLcl);
+
+    this.optionsAvg.yAxis.min = this.echartService.getChartAxisMin(max, min);
+    this.optionsAvg.yAxis.max = this.echartService.getChartAxisMax(max, min);
+
+    this.optionsAvg.series[0].data = xbarData.xbarGroupAveArr;
+    this.optionsAvg.series[0].markLine = opXbarCtrLine;   // 设置标线
+  }
+
+  /**
+   * 初始化极差控制图
+   * @param rangeData 极差控制图数据
+   */
+  public initRangeData(rangeData) {
+    let opRangeCtrLine = this.echartService.getMarkLineTemplate();
+    /* mean value ucl, cl, lcl data setting */
+    opRangeCtrLine.data[0][0].label.normal.formatter = 'UCL=' + rangeData.rangeUcl;
+    opRangeCtrLine.data[0][0].tooltip.formatter = 'UCL=' + rangeData.rangeUcl;
+    opRangeCtrLine.data[0][0].coord = [0, rangeData.rangeUcl];
+    opRangeCtrLine.data[0][1].coord = [rangeData.groupRangeArr.length - 1, rangeData.rangeUcl];
+    opRangeCtrLine.data[1][0].label.normal.formatter = 'CL=' + rangeData.rangeAve;
+    opRangeCtrLine.data[1][0].tooltip.formatter = 'CL=' + rangeData.rangeAve;
+    opRangeCtrLine.data[1][0].coord = [0, rangeData.rangeAve];
+    opRangeCtrLine.data[1][1].coord = [rangeData.groupRangeArr.length - 1, rangeData.rangeAve];
+    opRangeCtrLine.data[2][0].label.normal.formatter = 'LCL=' + rangeData.rangeLcl;
+    opRangeCtrLine.data[2][0].tooltip.formatter = 'LCL=' + rangeData.rangeLcl;
+    opRangeCtrLine.data[2][0].coord = [0, rangeData.rangeLcl];
+    opRangeCtrLine.data[2][1].coord = [rangeData.groupRangeArr.length - 1, rangeData.rangeLcl];
+
+    this.optionsRange = this.echartService.getLineOptionsTemplate(this.echartService.SuccessColor,
+      this.echartService.InfoColor,
+      this.echartService.TextColor,
+      this.echartService.AxisLineColor,
+      this.echartService.SplitLineColor);
+
+    this.optionsRange.title.subtext = '';
+    // this.optionsAvg.legend = null;
+    this.optionsRange.grid.top = 10;
+    this.optionsRange.grid.bottom = 5;
+    this.optionsRange.grid.left = 0;
+    this.optionsRange.grid.right = '4%';
+
+    let xAxisValues = [];
+    if (rangeData.groupRangeArr && rangeData.groupRangeArr.length > 0) {
+      for(let i = 0; i < rangeData.groupRangeArr.length; i++) {
+        xAxisValues.push(i);
+      }
+    }
+    this.optionsRange.xAxis.data = xAxisValues;
+
+    const max = Math.max(Math.max.apply(null, rangeData.groupRangeArr), rangeData.rangeUcl);
+    const min = Math.min(Math.min.apply(null, rangeData.groupRangeArr), rangeData.rangeLcl);
+
+    this.optionsRange.yAxis.min = this.echartService.getChartAxisMin(max, min);
+    this.optionsRange.yAxis.max = this.echartService.getChartAxisMax(max, min);
+
+    this.optionsRange.series[0].data = rangeData.groupRangeArr;
+    this.optionsRange.series[0].markLine = opRangeCtrLine;    // 设置标线
+  }
+}

+ 25 - 0
src/app/func/jiance/fast-exam-result/fast-exam-result.module.ts

@@ -0,0 +1,25 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+import { FastExamResultPage } from './fast-exam-result.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: FastExamResultPage
+  }
+];
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [FastExamResultPage]
+})
+export class FastExamResultPageModule {}

+ 62 - 0
src/app/func/jiance/fast-exam-result/fast-exam-result.page.html

@@ -0,0 +1,62 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_fastExam_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 下拉刷新 -->
+  <ion-refresher slot="fixed" (ionRefresh)="doDownRefresh($event)">
+    <ion-refresher-content></ion-refresher-content>
+  </ion-refresher>
+
+  <ion-card>
+    <ion-card-content>
+      <ion-list lines="none">
+        <ion-item>
+          <ion-label>{{titleDate}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{titleDetail}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+
+  <ion-card *ngIf="noSearchData">
+    <ion-card-content>
+      {{ 'generic_searchNoData' | translate }}
+    </ion-card-content>
+  </ion-card>
+
+  <ion-card *ngFor="let item of resultList; let k = index">
+    <ion-card-content>
+      <ion-list>
+        <ion-item button (click)="goChartPage(k)">
+          <ion-label>{{ 'generic_title_materName' | translate }}</ion-label>
+          <ion-label>{{item.materName}}</ion-label>
+          <ion-icon name="pulse" slot="end" color="primary"></ion-icon>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_fastExamResult_output' | translate }} (KG)</ion-label>
+          <ion-label>{{item.realWeight}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_fastExamResult_quaNum' | translate }}</ion-label>
+          <ion-label>{{item.qualityNum}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_fastExamResult_unQuaRate' | translate }}(%)</ion-label>
+          <ion-label>{{item.unqualityNum}}</ion-label>
+        </ion-item>
+        <ion-item>
+          <ion-label>{{ 'generic_fastExamResult_quaRate' | translate }}(%)</ion-label>
+          <ion-label>{{item.qualityRate}}</ion-label>
+        </ion-item>
+      </ion-list>
+    </ion-card-content>
+  </ion-card>
+</ion-content>

+ 0 - 0
src/app/func/jiance/fast-exam-result/fast-exam-result.page.scss


+ 108 - 0
src/app/func/jiance/fast-exam-result/fast-exam-result.page.ts

@@ -0,0 +1,108 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { TranslateService } from '@ngx-translate/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { IonInfiniteScroll, PopoverController } from '@ionic/angular';
+import { Storage } from '@ionic/storage';
+import { JianceService } from '../jiance.service';
+
+@Component({
+  selector: 'app-fast-exam-result',
+  templateUrl: './fast-exam-result.page.html',
+  styleUrls: ['./fast-exam-result.page.scss'],
+})
+export class FastExamResultPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+
+  titleDate: any = '';
+  titleDetail: any = '';
+  noSearchData = false;     // 未找到数据标志
+
+  /** 输入属性-双向绑定 */
+  input: any = {};
+  resultList: any;
+  constructor(private env: EnvService, private translate: TranslateService, private router: Router, private activatedRoute: ActivatedRoute, private popoverController: PopoverController, private storage: Storage, private jianceService: JianceService) { }
+
+  ngOnInit() {
+    this.getQueryParams();
+    this.initTitle();
+    this.initData();
+  }
+
+  /**
+   * 获取查询参数
+   */
+  public getQueryParams() {
+    this.input = this.activatedRoute.snapshot.queryParams;
+    console.log('-----------------------');
+    console.log('startDate = ' + this.input.startDate);
+    console.log('endDate = ' + this.input.endDate);
+    console.log('itemCode = ' + this.input.itemCode);
+    console.log('itemName = ' + this.input.itemName);
+    console.log('equipCode = ' + this.input.equipCode);
+    console.log('shiftClassId = ' + this.input.shiftClassId);
+    console.log('materCode = ' + this.input.materCode);
+    console.log('-----------------------');
+  }
+
+  /**
+   * 初始化标题信息
+   */
+  public async initTitle() {
+    this.titleDate = this.input.startDate + '~' + this.input.endDate;
+    this.titleDetail = await this.translate.get('fastExamResult_title_string').toPromise();
+    this.titleDetail = this.titleDetail.replace(/selectedOptionEquip/g, this.input.equipName).replace(/selectedOptionShift/g, this.input.shiftClassName).replace(/selectedOptionExamType/g, this.input.itemName);
+  }
+  /**
+   * 初始化数据
+   */
+  public async initData() {
+    const res: any = await this.jianceService.getFastExaminationList(this.input.startDate, this.input.endDate, this.input.itemCode, this.input.itemName, this.input.equipCode, this.input.shiftClassId, this.input.materCode);
+    console.log(res);
+    if (res && res.state && res.state == '0') {
+      this.resultList = res.result;
+      if (res.result.length == 0) {
+        this.noSearchData = true;
+      } else {
+        this.noSearchData = false;
+      }
+    } else {
+      console.warn('调用远程接口[getFastExaminationList]异常!');
+    }
+  }
+
+  /**
+   * 下拉刷新事件处理
+   * @param event 
+   */
+  public doDownRefresh(event) {
+    console.log('Begin async operation');
+    this.initData();
+    setTimeout(() => {
+      event.target.complete();
+    }, 1000);
+  }
+
+  /**
+   * 跳转到图表页
+   * @param index 
+   */
+  public goChartPage(index) {
+    console.log('index = ' + index);
+    const params = {
+      startDate: this.input.startDate,
+      endDate: this.input.endDate,
+      itemCode: this.input.itemCode,
+      itemName: this.input.itemName,
+      equipCode: this.input.equipCode,
+      equipName: this.input.equipName,
+      shiftClassId: this.input.shiftClassId,
+      shiftClassName: this.input.shiftClassName,
+      materCode: this.input.materCode,
+      materName: this.input.materName,
+      perMax: this.resultList[index].perMax,
+      perMin: this.resultList[index].perMin
+    };
+    this.router.navigate(['/tabs/func/jiance/fastexamchart'], { queryParams: params });
+  }
+}

+ 28 - 0
src/app/func/jiance/jiance.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { JiancePage } from './jiance.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: JiancePage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [JiancePage]
+})
+export class JiancePageModule {}

+ 57 - 0
src/app/func/jiance/jiance.page.html

@@ -0,0 +1,57 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_fastExam_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-list>
+    <!-- 开始时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_startTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.startDate" display-format="YYYY-MM-DD" picker-format="YYYY-MM-DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 结束时间 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{'generic_endTime' | translate}}</ion-label>
+      <ion-datetime [(ngModel)]="input.endDate" display-format="YYYY-MM-DD" picker-format="YYYY-MM-DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <!-- 物料名称 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/material-primary.svg"></ion-icon>
+      <ion-label>{{'generic_materName' | translate}}</ion-label>
+      <ion-input [(ngModel)]="input.materName" placeholder="{{'generic_placeholder_materName' | translate}}" readonly [routerLink]="['/tabs/func/spc/rubberquamater']" routerLinkActive="router-link-active"></ion-input>
+      <ion-icon slot="end" color="primary" name="arrow-redo-outline" [routerLink]="['/tabs/func/spc/rubberquamater']" [queryParams]="{ from : 'jiance'}" routerLinkActive="router-link-active" ></ion-icon>
+    </ion-item>
+    <!-- 检验项目 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/checkItem-primary.svg"></ion-icon>
+      <ion-label>{{'generic_inspectionItems' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.itemCode" (ionChange)="handleCheckItemChange($event)" multiple="false" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}" required>
+        <ion-select-option *ngFor="let item of checkItemList" value="{{item.itemCd}}">{{item.itemName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+    <!-- 生产机台 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/monitor-primary.svg"></ion-icon>
+      <ion-label>{{'generic_equip' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.equipCode" (ionChange)="handleEquipChange($event)" multiple="false" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}" placeholder="{{'generic_placeholder_equip' | translate}}">
+        <ion-select-option *ngFor="let equip of equipList" value="{{equip.equipCode}}">{{equip.equipName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+    <!-- 生产班组 -->
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/classgroup-primary.svg"></ion-icon>
+      <ion-label>{{'generic_shiftClass' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.shiftClassId" (ionChange)="handleShiftClassChange($event)" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}">
+        <ion-select-option *ngFor="let shiftClass of shiftClassList" value="{{shiftClass.shiftClassId}}">{{shiftClass.shiftClassName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+  </ion-list>
+  <ion-button expand="full" (click)="doSearch()">{{ 'generic_query' | translate }}</ion-button>
+</ion-content>

+ 0 - 0
src/app/func/jiance/jiance.page.scss


+ 158 - 0
src/app/func/jiance/jiance.page.ts

@@ -0,0 +1,158 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from 'src/app/wongoing/env.service';
+import { TranslateService } from '@ngx-translate/core';
+import { Router, ActivatedRoute } from '@angular/router';
+import { Storage } from '@ionic/storage';
+import { BaseService } from 'src/app/wongoing/base.service';
+
+@Component({
+  selector: 'app-jiance',
+  templateUrl: './jiance.page.html',
+  styleUrls: ['./jiance.page.scss'],
+})
+export class JiancePage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+  /** 输入属性-双向绑定 */
+  input = {
+    startDate: '2016-01-08',
+    endDate: '2017-01-08',
+    equipCode: '全部',
+    equipName: '全部',
+    shiftClassId: '全部',
+    shiftClassName: '全部',
+    materCode: '5080000000027',
+    materName: 'BOG101-试B',
+    itemCode: '302',
+    itemName: 'MH'
+  };
+
+  /** 数据初始化属性-单向显示 */
+  checkItemList: any[];
+  shiftClassList: any[];
+  equipList: any[];
+  constructor(private env: EnvService, private translate: TranslateService, private router: Router, private activateRoute: ActivatedRoute, private storage: Storage, private baseService: BaseService) { }
+
+  ngOnInit() {
+    this.processQueryParam();
+    this.initShiftClass();
+    this.initEquip();
+    this.initCheckItem();
+  }
+
+  /**
+   * 处理请求参数,(处理选择物料后返回的值)
+   */
+  public processQueryParam() {
+    this.activateRoute.queryParams.subscribe(param => {
+      console.log('processQueryParam...begin');
+      console.log('materCode = ' + param['materCode']);
+      console.log('materName = ' + param['materName']);
+      console.log('processQueryParam...end');
+      if (param['materCode']) {
+        this.input.materCode = param['materCode'];
+      }
+      if (param['materName']) {
+        this.input.materName = param['materName'];
+      }
+    });
+  }
+
+  /**
+   * 初始化生产班组
+   */
+  public async initShiftClass() {
+    let res: any = await this.baseService.getShiftClassList();
+    console.log(res);
+    if (res && res.state && res.state == '0') {
+      this.shiftClassList = res.result;
+    } else {
+      console.warn('请求后台接口[getShiftClassList]异常!');
+    }
+  }
+
+  /**
+   * 初始化生产机台
+   */
+  public async initEquip() {
+    let res: any = await this.baseService.getEquipList();
+    console.log(res);
+    if (res && res.state && res.state === '0') {
+      this.equipList = res.result;
+    } else {
+      console.warn('请求后台接口[getEquipList]异常!');
+    }
+  }
+
+  /**
+   * 初始化胶料检测项
+   */
+  public async initCheckItem() {
+    let res: any = await this.baseService.getCheckItem();
+    console.log(res);
+    if (res && res.state && res.state == '0') {
+      this.checkItemList = res.result;
+    } else {
+      console.warn('请求后台接口[getCheckItem]异常!');
+    }
+  }
+
+  /**
+   * 处理检测项的选择,用于保存检测项名称
+   * @param event 事件对象
+   */
+  public handleCheckItemChange(event) {
+    console.log('CheckItem change');
+    this.checkItemList.forEach(element => {
+      if (element.itemCd == this.input.itemCode) {
+        this.input.itemName = element.itemName;
+      }
+    });
+  }
+
+  /**
+   * 处理机台的选择,用于保存选择的机台名称
+   * @param event 事件对象
+   */
+  public handleEquipChange(event) {
+    console.log('Equip change');
+    this.equipList.forEach(element => {
+      if (element.equipCode == this.input.equipCode) {
+        this.input.equipName = element.equipName;
+      }
+    });
+  }
+
+  /**
+   * 处理班组的选择,用于保存选择的班组名称
+   * @param event 事件对象
+   */
+  public handleShiftClassChange(event) {
+    console.log('shift class change');
+    this.shiftClassList.forEach(element => {
+      if (element.shiftClassId == this.input.shiftClassId) {
+        this.input.shiftClassName = element.shiftClassName;
+      }
+    });
+  }
+
+  /**
+   * 执行查询
+   */
+  public doSearch() {
+    console.log('执行查询');
+    this.input.startDate = this.input.startDate.substring(0, 10);
+    this.input.endDate = this.input.endDate.substring(0, 10);
+    console.log('startDate = ' + this.input.startDate);
+    console.log('endDate = ' + this.input.endDate);
+    console.log('materCode = ' + this.input.materCode);
+    console.log('materName = ' + this.input.materName);
+    console.log('itemCode = ' + this.input.itemCode);
+    console.log('equipCode = ' + this.input.equipCode);
+    console.log('shiftClassId = ' + this.input.shiftClassId);
+    
+    this.storage.set('inputQueryParams', this.input).then().catch(err => {
+      console.error('spc页面缓存查询条件异常!', err);
+    }); //缓存查询条件
+    this.router.navigate(['/tabs/func/jiance/fastexamresult'], { queryParams: this.input });
+  }
+}

+ 50 - 0
src/app/func/jiance/jiance.service.ts

@@ -0,0 +1,50 @@
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+import { EnvService } from '../../wongoing/env.service';
+import { UtilsService } from '../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class JianceService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取胶料快检列表
+   * @param startTime 开始日期,格式[yyyy-MM-dd]
+   * @param endTime 结束日期,格式[yyyy-MM-dd]
+   * @param itemCode 检验项代码
+   * @param itemName 检验项名称
+   * @param equipCode 机台编码
+   * @param shift 班组ID
+   * @param materialCode 物料编码 
+   */
+  public getFastExaminationList(startTime, endTime, itemCode, itemName, equipCode, shift, materialCode) {
+    const url = this.env.getFastExaminationList;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const options = { params: { 'dsType': dsType, 'usedLanguage': usedLanguage, 'startTime': startTime, 'endTime': endTime, 'itemCode': itemCode, 'itemName': itemName, 'equipCode': equipCode, 'shift': shift, 'materialCode': materialCode } };
+    return this.http.request(method, url, options).toPromise();
+  }
+
+  /**
+   * 获取胶料快检列表某项详情
+   * @param startTime 开始日期,格式[yyyy-MM-dd]
+   * @param endTime 结束日期,格式[yyyy-MM-dd]
+   * @param itemCode 检验项代码
+   * @param itemName 检验项名称
+   * @param equipCode 机台编码
+   * @param shift 班组ID
+   * @param materialCode 物料编码 
+   */
+  public getFastExaminationItemList(startTime, endTime, itemCode, itemName, equipCode, shift, materialCode) {
+    const url = this.env.getFastExaminationItemList;
+    const method = 'GET';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    const options = { params: { 'dsType': dsType, 'usedLanguage': usedLanguage, 'startTime': startTime, 'endTime': endTime, 'itemCode': itemCode, 'itemName': itemName, 'equipCode': equipCode, 'shift': shift, 'materialCode': materialCode } };
+    return this.http.request(method, url, options).toPromise();
+  }
+}

+ 28 - 0
src/app/func/jihua/jihua.module.ts

@@ -0,0 +1,28 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { JihuaPage } from './jihua.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: JihuaPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [JihuaPage]
+})
+export class JihuaPageModule {}

+ 33 - 0
src/app/func/jihua/jihua.page.html

@@ -0,0 +1,33 @@
+<ion-header *ngIf="isShowHeader">
+  <ion-toolbar>
+    <ion-buttons slot="start">
+      <ion-back-button text="{{ 'generic_goback' | translate }}"></ion-back-button>
+    </ion-buttons>
+    <ion-title>{{ 'generic_planExecMonitor_title' | translate }}</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <ion-list>
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/calendar-primary.svg"></ion-icon>
+      <ion-label>{{ 'generic_planDate' | translate }}</ion-label>
+      <ion-datetime [(ngModel)]="input.planDate" display-format="YYYY/MM/DD" picker-format="YYYY/MM/DD" doneText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}"></ion-datetime>
+    </ion-item>
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/classgroup-primary.svg"></ion-icon>
+      <ion-label>{{ 'planExecMonitorSearch_productionArea' | translate}}</ion-label>
+      <ion-select [(ngModel)]="input.equipGroupId" (ionChange)="handleEquipGroupChange($event)" multiple="false" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}" placeholder="{{'planExecMonitorSearch_placeholder_productionArea' | translate}}">
+        <ion-select-option *ngFor="let equipGroup of input.equipGroupList" value="{{equipGroup.codeValue}}">{{equipGroup.codeName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+    <ion-item>
+      <ion-icon slot="start" src="/assets/svg/monitor-primary.svg"></ion-icon>
+      <ion-label>{{ 'generic_equip' | translate }}</ion-label>
+      <ion-select [(ngModel)]="input.equipMultiple" multiple="true" okText="{{'generic_confirm' | translate}}" cancelText="{{'generic_cancel' | translate}}" placeholder="{{'generic_placeholder_equip' | translate}}">
+        <ion-select-option *ngFor="let equip of input.equipList" value="{{equip.equipCode}}">{{equip.equipName}}</ion-select-option>
+      </ion-select>
+    </ion-item>
+  </ion-list>
+  <ion-button expand="full" (click)='doSearch()'>{{ 'generic_query' | translate }}</ion-button>
+</ion-content>

+ 0 - 0
src/app/func/jihua/jihua.page.scss


+ 93 - 0
src/app/func/jihua/jihua.page.ts

@@ -0,0 +1,93 @@
+import { Component, OnInit } from '@angular/core';
+import { EnvService } from '../../wongoing/env.service';
+import { TranslateService } from '@ngx-translate/core';
+import { Router } from '@angular/router';
+import { BaseService } from 'src/app/wongoing/base.service';
+
+@Component({
+  selector: 'app-jihua',
+  templateUrl: './jihua.page.html',
+  styleUrls: ['./jihua.page.scss'],
+})
+export class JihuaPage implements OnInit {
+  isShowHeader = this.env.IsShowHeader;
+
+  /** 输入属性-双向绑定 */
+  input = {
+    planDate : '2016/03/16',
+    // 机子ID
+    equipGroupId : '1#',
+    // 页面显示所需机台文字
+    equipMultiple : '01003,01004,01005,01006,01008',
+    // 页面展示所需机台列表
+    equipList : [],
+    // 机组对象列表
+    equipGroupList : [],
+    // 请求所需机台列表数据
+    equipJson : [],
+    // 请求所需机台列表字符串
+    equipJsonString: ''
+  };
+
+  /** 数据初始化属性-单向显示 */
+  shiftList: any[];
+  equipList: any[];
+  constructor(private env: EnvService, public translate: TranslateService, private baseService: BaseService, private router: Router) { }
+
+  ngOnInit() {
+    this.initEquipGroup();
+    this.initEquip();
+  }
+
+  /**
+   * 初始化生产区域列表
+   */
+  public async initEquipGroup() {
+    const res: any = await this.baseService.getEquipGroup();
+    console.log(res);
+    if (res && res.state && res.state == '0') {
+      this.input.equipGroupList = res.result;
+    } else {
+      console.warn('请求后台接口[getSysCodeList]异常!');
+    }
+  }
+
+  /**
+   * 初始化机台列表
+   */
+  public async initEquip() {
+    const res: any = await this.baseService.getProductEquipByEquipGroup(this.input.equipGroupId);
+    console.log(res);
+    if (res && res.state && res.state === '0') {
+      this.input.equipList = res.result;
+    } else {
+      console.warn('请求后台接口[getEquipList]异常!');
+    }
+  }
+
+  /**
+   * 选择生产区域事件处理,获取对应生产区域的机台信息
+   * @param event 事件对象
+   */
+  public async handleEquipGroupChange(event) {
+    this.initEquip();
+  }
+
+  /**
+   * 执行查询
+   */
+  public doSearch() {
+    // console.log('planDate = ' + this.input.planDate);
+    // console.log('equipGroupId = ' + this.input.equipGroupId);
+    // console.log('equipMultiple = ' + this.input.equipMultiple);
+    if (this.input.equipList && this.input.equipList.length > 0) {
+      this.input.equipList.forEach(equip => {
+        if (this.input.equipMultiple.indexOf(equip.equipCode) > 0) {
+          this.input.equipJson.push({ equipCode: equip.equipCode, equipName: equip.equipName });
+        }
+      });
+    }
+    this.input.equipJsonString = JSON.stringify(this.input.equipJson);
+    this.router.navigate(['/tabs/func/jihua/planexecmonitorresult'], { queryParams: this.input });
+  }
+}

+ 33 - 0
src/app/func/jihua/jihua.service.ts

@@ -0,0 +1,33 @@
+import { Injectable } from '@angular/core';
+import { HttpClient, HttpHeaders, HttpParams } from '@angular/common/http';
+import { EnvService } from '../../wongoing/env.service';
+import { UtilsService } from '../../wongoing/utils.service';
+
+@Injectable({
+  providedIn: 'root'
+})
+export class JihuaService {
+
+  constructor(private http: HttpClient, private env: EnvService, private utilsService: UtilsService) { }
+
+  /**
+   * 获取计划执行监控总体数据列表
+   * @param planDate 计划日期
+   * @param equipGroupId 生产区域ID
+   * @param equipJson 机台列表json串[{equipCode:'', equipName:''}, {equipCode:'', equipName:''}]
+   */
+  public getPlanExecMonitorTotalData(planDate, equipGroupId, equipJson) {
+    const url = this.env.getPlanExecMonitorTotalData;
+    const method = 'POST';
+    const dsType = this.utilsService.getDataSourceType();
+    const usedLanguage = this.utilsService.getUsedLanguage();
+    let body = new HttpParams();
+    body = body.append('dsType', dsType);
+    body = body.append('planDate', planDate);
+    body = body.append('equipGroupId', equipGroupId);
+    body = body.append('equipJson', equipJson);
+    const options = { headers: new HttpHeaders().set('Content-Type', 'application/x-www-form-urlencoded') };
+    // const options = { headers: { 'Content-Type': 'application/x-www-form-urlencoded' } };      // 效果等同上一句
+    return this.http.post(url, body.toString(), options).toPromise();
+  }
+}

+ 27 - 0
src/app/func/jihua/plan-exec-monitor-chart/plan-exec-monitor-chart.module.ts

@@ -0,0 +1,27 @@
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
+import { Routes, RouterModule } from '@angular/router';
+import { IonicModule } from '@ionic/angular';
+import { TranslateModule } from '@ngx-translate/core';
+
+import { PlanExecMonitorChartPage } from './plan-exec-monitor-chart.page';
+
+const routes: Routes = [
+  {
+    path: '',
+    component: PlanExecMonitorChartPage
+  }
+];
+
+@NgModule({
+  imports: [
+    CommonModule,
+    FormsModule,
+    IonicModule,
+    RouterModule.forChild(routes),
+    TranslateModule
+  ],
+  declarations: [PlanExecMonitorChartPage]
+})
+export class PlanExecMonitorChartPageModule {}

+ 9 - 0
src/app/func/jihua/plan-exec-monitor-chart/plan-exec-monitor-chart.page.html

@@ -0,0 +1,9 @@
+<ion-header>
+  <ion-toolbar>
+    <ion-title>planExecMonitorChart</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+
+</ion-content>

Unele fișiere nu au fost afișate deoarece prea multe fișiere au fost modificate în acest diff