|
|
@@ -2,7 +2,7 @@
|
|
2
|
2
|
* @Author: dayan_hjm
|
|
3
|
3
|
* @Date: 2023-10-25 10:32:44
|
|
4
|
4
|
* @Last Modified by: dayan_hjm
|
|
5
|
|
- * @Last Modified time: 2023-12-19 15:47:39
|
|
|
5
|
+ * @Last Modified time: 2024-01-02 10:42:01
|
|
6
|
6
|
*/
|
|
7
|
7
|
/*
|
|
8
|
8
|
* @Author: dayan_hjm
|
|
|
@@ -30,7 +30,7 @@ import {
|
|
30
|
30
|
checkToken,
|
|
31
|
31
|
updateTimeService
|
|
32
|
32
|
} from "./api";
|
|
33
|
|
-import { getThousandNum,deleteCacheAndChangeUrl } from "@utils/util";
|
|
|
33
|
+import { getThousandNum, deleteCacheAndChangeUrl } from "@utils/util";
|
|
34
|
34
|
import {
|
|
35
|
35
|
fullscreen,
|
|
36
|
36
|
} from "@ant-design/icons";
|
|
|
@@ -213,23 +213,26 @@ class Home extends Component {
|
|
213
|
213
|
//产量计划完成率
|
|
214
|
214
|
var p1 = document.getElementById('plannedCompletionBox');
|
|
215
|
215
|
const datas_ = plannedCompletionData[plannedCompletionNum - 1];
|
|
216
|
|
- var res;
|
|
217
|
|
- if (type) {
|
|
218
|
|
- res = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number">' + getThousandNum(datas_?.value.toFixed(2)) + '</span><span class="topMsg_number_2" style={{fontSize: "0.75em",color: "#fff"}}>%</span><p class="topMsg_number_p">' + datas_.name + '</p></div>';
|
|
219
|
|
- } else {
|
|
220
|
|
- res = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number shu1">' + datas_?.value.toFixed(2) + '</span><span class="topMsg_number_2" style={{fontSize: "0.75em",color: "#fff"}}>%</span><p class="topMsg_number_p">' + datas_.name + '</p></div>';
|
|
|
216
|
+ var res = "";
|
|
|
217
|
+ if (datas_) {
|
|
|
218
|
+ if (type) {
|
|
|
219
|
+ res = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number">' + getThousandNum(datas_?.value.toFixed(2)) + '</span><span class="topMsg_number_2" style={{fontSize: "0.75em",color: "#fff"}}>%</span><p class="topMsg_number_p">' + datas_?.name + '</p></div>';
|
|
|
220
|
+ } else {
|
|
|
221
|
+ res = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number shu1">' + datas_?.value.toFixed(2) + '</span><span class="topMsg_number_2" style={{fontSize: "0.75em",color: "#fff"}}>%</span><p class="topMsg_number_p">' + datas_?.name + '</p></div>';
|
|
|
222
|
+ }
|
|
221
|
223
|
}
|
|
222
|
224
|
p1.innerHTML = res;
|
|
223
|
225
|
|
|
224
|
226
|
//百万工时损工率
|
|
225
|
227
|
var p2 = document.getElementById('manHourBox');
|
|
226
|
228
|
const datas_2 = manHourData[manHourNum - 1];
|
|
227
|
|
- var res2;
|
|
228
|
|
-
|
|
229
|
|
- if (type) {
|
|
230
|
|
- res2 = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number">' + getThousandNum(datas_2?.value.toFixed(2)) + '</span><p class="topMsg_number_p">' + datas_2.name + '</p></div>';//<span class="topMsg_number_2">%</span>
|
|
231
|
|
- } else {
|
|
232
|
|
- res2 = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number shu1">' + datas_2?.value.toFixed(2) + '</span><p class="topMsg_number_p">' + datas_2.name + '</p></div>';
|
|
|
229
|
+ var res2 = "";
|
|
|
230
|
+ if (datas_2) {
|
|
|
231
|
+ if (type) {
|
|
|
232
|
+ res2 = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number">' + getThousandNum(datas_2?.value.toFixed(2)) + '</span><p class="topMsg_number_p">' + datas_2?.name + '</p></div>';//<span class="topMsg_number_2">%</span>
|
|
|
233
|
+ } else {
|
|
|
234
|
+ res2 = '<div class="topMsg_box animate__animated animate__zoomIn"><span class="topMsg_number shu1">' + datas_2?.value.toFixed(2) + '</span><p class="topMsg_number_p">' + datas_2?.name + '</p></div>';
|
|
|
235
|
+ }
|
|
233
|
236
|
}
|
|
234
|
237
|
p2.innerHTML = res2;
|
|
235
|
238
|
|
|
|
@@ -248,14 +251,14 @@ class Home extends Component {
|
|
248
|
251
|
{/* 右键切换大屏 */}
|
|
249
|
252
|
<Tooltip placement="bottom" title={"产供销价值链"}>
|
|
250
|
253
|
<img src={require("@assets/imgs/iconJpg/rightJ.png").default} alt="" className={"rightJ_png"} onClick={() => {
|
|
251
|
|
- deleteCacheAndChangeUrl("/home/gvc",(url)=>{
|
|
|
254
|
+ deleteCacheAndChangeUrl("/home/gvc", (url) => {
|
|
252
|
255
|
this.props.history.replace(url);
|
|
253
|
256
|
})
|
|
254
|
257
|
}} />
|
|
255
|
258
|
</Tooltip>
|
|
256
|
259
|
<Tooltip placement="bottom" title={"产供销价值链"}>
|
|
257
|
260
|
<img src={require("@assets/imgs/iconJpg/rightJL.png").default} alt="" className={"rightJ_png rightJ_png_L"} onClick={() => {
|
|
258
|
|
- deleteCacheAndChangeUrl("/home/gvc",(url)=>{
|
|
|
261
|
+ deleteCacheAndChangeUrl("/home/gvc", (url) => {
|
|
259
|
262
|
this.props.history.replace(url);
|
|
260
|
263
|
})
|
|
261
|
264
|
}} />
|