erp.html
52.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
<!doctype html>
<html lang="zh-CN">
<head>
<meta charset="utf-8" />
<title>ERP - 企业业务能力平台</title>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<style>
:root {
--bg: #f3f4f6;
--panel: #ffffff;
--topbar: #1f1f23;
--topbar-text: #ffffff;
--primary: #2f7adf;
--primary-strong: #1f6ed4;
--link: #1e84e6;
--text: #333333;
--text-soft: #555;
--text-mute: #888;
--border: #e3e6eb;
--row-alt: #f7f8fa;
--header-bg: #f4f5f7;
--danger: #e34d4d;
--tab-active: #1e84e6;
--toolbar-bg: #2c2f36;
--toolbar-text: #ffffff;
--label: #f04848;
--field-bg: #eaf3fe;
--field-bg-readonly: #f1f3f5;
}
*{box-sizing:border-box}
html,body{margin:0;padding:0;background:var(--bg);color:var(--text);font-family:"Microsoft YaHei","PingFang SC","Helvetica Neue",Helvetica,Arial,"Segoe UI",sans-serif;font-size:13px;}
button{font-family:inherit;cursor:pointer}
a{color:inherit;text-decoration:none}
input,select,textarea{font-family:inherit;font-size:13px}
/* ======= TOP BAR ======= */
.topbar{display:flex;align-items:stretch;height:44px;background:var(--topbar);color:var(--topbar-text);position:relative;z-index:30;}
.topbar .logo{width:54px;display:flex;align-items:center;justify-content:center;}
.topbar .logo svg{width:30px;height:30px}
.topbar .nav-btn{display:flex;align-items:center;gap:6px;padding:0 18px;color:#fff;cursor:pointer;font-size:14px;border:none;background:transparent;height:100%;}
.topbar .nav-btn.active{background:var(--primary);}
.topbar .nav-btn:hover{background:#33363d}
.topbar .nav-btn.active:hover{background:var(--primary-strong)}
.topbar .tabs{display:flex;align-items:stretch;flex:1;}
.topbar .tab{display:flex;align-items:center;gap:8px;padding:0 18px;cursor:pointer;color:#cfd2d8;font-size:14px;height:100%;}
.topbar .tab .ic{opacity:.85}
.topbar .tab.active{color:var(--link)}
.topbar .tab .close{margin-left:6px;width:14px;height:14px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;font-size:11px;color:#9aa0a8}
.topbar .tab .close:hover{background:#3a3d44;color:#fff}
.topbar .right{display:flex;align-items:center;gap:18px;padding-right:14px;}
.topbar .right .ic{width:18px;height:18px;opacity:.9;cursor:pointer}
.topbar .user{display:flex;align-items:center;gap:6px;font-size:14px}
.topbar .more{font-size:18px;letter-spacing:2px;cursor:pointer;padding:0 4px}
/* ======= APP LAYOUT ======= */
.app{height:100vh;display:flex;flex-direction:column;overflow:hidden}
.stage{flex:1;position:relative;overflow:hidden;background:var(--bg)}
.screen{position:absolute;inset:0;display:none;overflow:auto}
.screen.active{display:block}
/* ======= MAIN / DASHBOARD ======= */
.main-wrap{display:grid;grid-template-columns:1fr 280px;gap:10px;padding:10px;min-height:100%;}
.panel{background:var(--panel);border:1px solid var(--border);border-radius:2px}
.kpi-head{padding:14px 18px;display:flex;align-items:center;gap:24px;flex-wrap:wrap;}
.kpi-head .title{font-size:15px;color:#222;font-weight:500;margin-right:6px}
.kpi-head .stat{color:var(--text-soft)}
.kpi-head .stat b{color:var(--danger);font-weight:500;margin-left:6px;font-size:14px}
.kpi-head .stat.blue b{color:var(--link)}
.kpi-head .sep{color:#cdd0d6}
.kpi-head .ai-btn{margin-left:auto;background:var(--primary);color:#fff;border:none;padding:7px 14px;border-radius:2px;display:inline-flex;align-items:center;gap:6px;font-size:13px;}
.kpi-head .ai-btn:hover{background:var(--primary-strong)}
.kpi-body{display:grid;grid-template-columns:200px 90px 1fr 1fr 90px 90px 130px;border-top:1px solid var(--border)}
.kpi-body > div{border-right:1px solid var(--border);border-bottom:1px solid var(--border);padding:10px 12px;font-size:13px;min-height:38px;display:flex;align-items:center}
.kpi-body > div:nth-last-child(-n+7){border-bottom:none}
.kpi-body > div:last-child{border-right:none}
.kpi-body .h{background:var(--header-bg);font-weight:500;color:#222;padding:9px 12px}
.kpi-body .row-alt{background:var(--row-alt)}
.kpi-body .link{color:var(--link);cursor:pointer}
.kpi-body .link:hover{text-decoration:underline}
.kpi-body .num-red{color:var(--danger);font-weight:600;justify-content:center}
.kpi-body .num-zero{color:var(--danger);font-weight:600;justify-content:center}
.kpi-body .num{justify-content:center}
.kpi-body .center{justify-content:center}
.nav-tree{padding:6px 0}
.nav-tree .group{padding:8px 14px;color:#444;font-size:13px;display:flex;align-items:center;gap:6px;cursor:pointer}
.nav-tree .group .arrow{display:inline-block;width:0;height:0;border-left:4px solid #888;border-top:4px solid transparent;border-bottom:4px solid transparent;transform:rotate(90deg);margin-right:2px}
.nav-tree .group .ico{color:#e0b96a}
.nav-tree .item{padding:6px 14px 6px 36px;display:flex;align-items:center;gap:8px;color:#3a3a3a;cursor:pointer;font-size:13px}
.nav-tree .item:hover{background:#eef3fb}
.nav-tree .item.active{background:#d8eaff;color:#1166cc}
.nav-tree .item .ico{color:#e0b96a}
.three-col{display:grid;grid-template-columns:280px 1fr;height:100%;}
.three-col .left-nav{background:var(--panel);border:1px solid var(--border);overflow:auto}
.three-col .center{display:flex;flex-direction:column;gap:10px;min-width:0}
.common-ops{padding:14px 18px}
.common-ops .h{font-size:14px;color:#222;margin-bottom:14px;font-weight:500}
.common-ops a{display:block;color:var(--link);padding:8px 0;font-size:13px;border-bottom:1px dashed transparent}
.common-ops a:hover{text-decoration:underline}
/* table sub-process column */
.subproc{writing-mode:vertical-rl;text-orientation:upright;color:#222;font-weight:500;justify-content:center;min-width:24px;}
.subproc.estimate{ background:transparent }
footer.foot{
background:#f3f4f6;border-top:1px solid var(--border);padding:10px 14px;text-align:center;color:#666;font-size:12px;
}
footer.foot .pipe{margin:0 8px;color:#bbb}
footer.foot .police{display:inline-flex;align-items:center;gap:4px;margin-left:6px}
footer.foot .police svg{width:14px;height:14px}
/* ======= NAV OVERLAY ======= */
#nav-overlay{position:absolute;inset:0;background:#2b3137;display:none;z-index:20;color:#cfd3da;}
#nav-overlay.show{display:flex}
#nav-overlay .side{width:200px;background:#2b3137;padding:8px 0;border-right:1px solid #1e2226}
#nav-overlay .side .si{display:flex;align-items:center;gap:10px;padding:11px 18px;font-size:14px;color:#d3d6db;cursor:pointer}
#nav-overlay .side .si:hover{background:#34393f}
#nav-overlay .side .si.active{color:var(--link);background:#34393f}
#nav-overlay .side .si svg{width:16px;height:16px;opacity:.85}
#nav-overlay .grid{flex:1;padding:30px 40px;display:grid;grid-template-columns:repeat(7,1fr);gap:30px 40px;align-content:start}
#nav-overlay .col h3{font-size:15px;color:#e8eaee;font-weight:500;margin:0 0 18px;border-bottom:1px solid #4a4f57;padding-bottom:10px}
#nav-overlay .col a{display:flex;align-items:center;gap:6px;padding:7px 0;color:#cfd3da;font-size:14px;cursor:pointer}
#nav-overlay .col a:hover{color:#fff}
#nav-overlay .col a .star{color:#f3b526}
/* ======= USER LIST ======= */
.toolbar{background:var(--toolbar-bg);color:#fff;display:flex;align-items:center;gap:6px;padding:0 8px;height:38px}
.toolbar .tb-btn{display:inline-flex;align-items:center;gap:6px;padding:6px 12px;color:#e6e7ea;cursor:pointer;font-size:13px;border-radius:2px}
.toolbar .tb-btn:hover{background:#3a3d44}
.toolbar .tb-btn .ic{opacity:.9}
.toolbar .spacer{flex:1}
.toolbar .gear{padding:6px 8px;cursor:pointer;color:#cfd2d8}
.filterbar{display:flex;align-items:center;gap:8px;padding:10px 12px;background:var(--panel);border-bottom:1px solid var(--border)}
.filterbar select, .filterbar input{height:30px;border:1px solid #d5d8de;border-radius:2px;padding:0 28px 0 10px;background:#fff;min-width:140px;appearance:none;
background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'><path d='M2 3l3 4 3-4z' fill='%23888'/></svg>");
background-repeat:no-repeat;background-position:right 8px center}
.filterbar input{background-image:none;padding-right:10px}
.filterbar .down{width:34px;height:30px;background:#dfe5ee;border:1px solid #d5d8de;display:flex;align-items:center;justify-content:center;border-radius:2px;cursor:pointer;color:#3776c8}
.filterbar .btn{height:30px;padding:0 14px;border-radius:2px;border:1px solid var(--primary);background:var(--primary);color:#fff;display:inline-flex;align-items:center;gap:5px;font-size:13px;cursor:pointer}
.filterbar .btn.ghost{background:#fff;color:#444;border-color:#cfd3da}
.filterbar .btn:hover{filter:brightness(1.05)}
.grid-table{width:100%;border-collapse:collapse;background:#fff;font-size:13px;}
.grid-table th, .grid-table td{border:1px solid var(--border);padding:7px 10px;text-align:left;white-space:nowrap}
.grid-table thead th{background:var(--header-bg);font-weight:500;color:#333;position:sticky;top:0;z-index:1}
.grid-table thead th .h-flex{display:flex;align-items:center;gap:6px;justify-content:space-between}
.grid-table thead th .h-flex .ic{display:flex;gap:2px;color:#aaa}
.grid-table tbody tr:nth-child(even){background:var(--row-alt)}
.grid-table tbody tr:hover{background:#eaf3fe}
.grid-table .radio-cell{width:32px;text-align:center}
.radio-dot{width:14px;height:14px;border:1px solid #b8bcc3;border-radius:50%;display:inline-block;vertical-align:middle;background:#fff}
.grid-table input.cb{margin:0}
.pager{display:flex;align-items:center;gap:8px;padding:10px 14px;background:#fff;border-top:1px solid var(--border);justify-content:flex-end;font-size:13px;color:#555}
.pager .pgbtn{width:28px;height:28px;border:1px solid #d5d8de;background:#fff;border-radius:2px;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;color:#666}
.pager .pgcur{width:28px;height:28px;border:1px solid var(--primary);color:var(--primary);display:inline-flex;align-items:center;justify-content:center;border-radius:2px}
.pager select{height:28px;border:1px solid #d5d8de;border-radius:2px;padding:0 8px;background:#fff}
/* ======= USER DETAIL ======= */
.form-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:0;background:#fff;padding:10px 14px;border-bottom:1px solid var(--border)}
.form-cell{display:flex;align-items:center;gap:6px;padding:8px 10px;}
.form-cell .lbl{min-width:88px;color:#333;font-size:13px;text-align:right}
.form-cell .lbl.req::before{content:"*";color:var(--label);margin-right:3px}
.form-cell .lbl.req{color:var(--label)}
.form-cell input[type=text], .form-cell .field{
flex:1;height:28px;border:1px solid #d5d8de;border-radius:2px;padding:0 24px 0 10px;background:var(--field-bg);
appearance:none; min-width:0;
}
.form-cell .field.readonly{background:var(--field-bg-readonly);color:#444;display:flex;align-items:center}
.form-cell .field.with-caret{background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'><path d='M2 3l3 4 3-4z' fill='%23888'/></svg>");background-repeat:no-repeat;background-position:right 8px center;background-color:var(--field-bg)}
.form-cell .field.with-cal{background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16' fill='none' stroke='%23888' stroke-width='1.4'><rect x='2' y='3' width='12' height='11' rx='1'/><path d='M2 6h12M5 1v3M11 1v3'/></svg>");background-repeat:no-repeat;background-position:right 8px center;background-color:var(--field-bg-readonly)}
.form-cell .cb{width:14px;height:14px;border:1px solid #b8bcc3;background:#fff;display:inline-block}
.tabs-row{display:flex;background:#fff;border-bottom:1px solid var(--border);padding:0 6px}
.tabs-row .tb{padding:11px 18px;font-size:14px;color:#444;cursor:pointer;border-bottom:2px solid transparent;margin-right:4px}
.tabs-row .tb.active{color:var(--tab-active);border-bottom-color:var(--tab-active)}
.perm-list{background:#fff}
.perm-row{display:flex;align-items:center;gap:14px;padding:10px 14px;border-bottom:1px solid var(--border);font-size:13px;color:#333}
.perm-row.head{background:var(--header-bg);font-weight:500;color:#222}
.perm-row .cb{width:14px;height:14px;border:1px solid #b8bcc3;background:#fff;display:inline-block;flex-shrink:0}
.perm-row.head .ic{margin-left:auto;color:#aaa}
/* ======= LOGIN ======= */
.login-wrap{position:absolute;inset:0;background:#eaedf2;display:flex;flex-direction:column}
.login-head{display:flex;align-items:center;gap:12px;padding:18px 36px;background:#eaedf2}
.login-head .lg{width:42px;height:42px;display:flex;align-items:center;justify-content:center}
.login-head .name{font-size:24px;font-weight:700;color:#e0a020;letter-spacing:2px}
.login-head .sub{color:#444;font-size:14px;margin-left:6px}
.login-hero{flex:1;position:relative;background:
radial-gradient(ellipse at center, #1a4ea0 0%, #0a1d44 60%, #050d20 100%);
overflow:hidden}
.login-hero::before{
content:"";position:absolute;inset:0;
background-image:
linear-gradient(rgba(80,160,255,.18) 1px, transparent 1px),
linear-gradient(90deg, rgba(80,160,255,.18) 1px, transparent 1px);
background-size:80px 80px;
transform:perspective(800px) rotateX(55deg) translateY(20%);
transform-origin:center;
opacity:.55;
}
.login-hero::after{
content:"";position:absolute;inset:0;
background:
radial-gradient(ellipse 800px 300px at 50% 50%, rgba(140,200,255,.35), transparent 60%),
radial-gradient(circle 200px at 30% 40%, rgba(255,255,255,.15), transparent 70%),
radial-gradient(circle 160px at 70% 60%, rgba(255,255,255,.12), transparent 70%);
}
.login-text{position:absolute;left:8%;top:35%;color:#fff;z-index:2}
.login-text .en{font-size:30px;font-weight:300;letter-spacing:1px;color:#cfe1ff;margin-bottom:6px}
.login-text .zh{font-size:54px;font-weight:700;color:#fff;letter-spacing:4px;margin-bottom:4px}
.login-text .erp{font-size:90px;font-weight:800;color:#fff;letter-spacing:8px;line-height:.9}
.login-card{position:absolute;right:8%;top:50%;transform:translateY(-50%);background:#fff;width:380px;padding:36px 32px;border-radius:2px;box-shadow:0 12px 40px rgba(0,0,0,.3);z-index:3}
.login-card h3{margin:0 0 22px;font-size:18px;color:#333;font-weight:500}
.login-card .lf{display:flex;align-items:center;border:1px solid #e1e4e8;border-radius:2px;height:42px;margin-bottom:14px;background:#fff;}
.login-card .lf .ic{width:42px;display:flex;align-items:center;justify-content:center;color:#888}
.login-card .lf .div{width:1px;height:20px;background:#e1e4e8}
.login-card .lf input{flex:1;border:none;outline:none;height:100%;padding:0 12px;background:transparent}
.login-card .lf select{flex:1;border:none;outline:none;height:100%;padding:0 12px;background:transparent;appearance:none}
.login-card .lf.dropdown{position:relative}
.login-card .lf.dropdown::after{content:"";position:absolute;right:14px;top:50%;width:0;height:0;border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid #888;transform:translateY(-50%)}
.login-card .lf.dropdown.open .opt{display:block}
.login-card .lf .opt{display:none;position:absolute;left:-1px;right:-1px;top:42px;background:#fff;border:1px solid #e1e4e8;border-top:none;z-index:5}
.login-card .lf .opt .o{padding:10px 14px;color:#333;cursor:pointer;background:#eef5ff}
.login-card .lf .opt .o:hover{background:#dde9fb}
.login-card .submit{width:100%;height:42px;background:var(--primary);color:#fff;border:none;border-radius:2px;font-size:15px;letter-spacing:8px;cursor:pointer;margin-top:6px}
.login-card .submit:hover{background:var(--primary-strong)}
.login-foot{background:#eaedf2;text-align:center;padding:14px 8px;color:#666;font-size:12px;border-top:1px solid #d8dce2}
/* misc */
.ic{display:inline-flex;align-items:center;justify-content:center}
.star{color:#f3b526}
.scrollable-y{overflow-y:auto}
.table-shell{background:#fff;flex:1;overflow:auto;border:1px solid var(--border);border-top:none}
/* Antler logo color */
.lg-antler{color:#0e1216}
</style>
</head>
<body>
<div class="app">
<!-- ======= TOP BAR ======= -->
<div class="topbar" id="topbar">
<div class="logo" data-go="main" title="主页">
<!-- antler/deer logo -->
<svg viewBox="0 0 64 64" fill="currentColor" class="lg-antler">
<path d="M14 10c2 4 1 8-1 11 3-1 7 0 10 3 1-4 4-7 8-7-3 3-4 7-3 11l4 1c-1 3 0 6 3 8-3 0-6 1-8 4-1-3-4-5-8-5 2-3 2-7 0-10-3 1-7 0-10-3 3 0 5-2 6-5l-1-8z"/>
<path d="M48 14c-2 3-2 6-1 9-2-2-5-2-8-1 1 3 1 6-1 9 3 0 5 2 6 5 1-3 4-5 7-5-2-3-2-6 0-9 2 1 5 1 7-1-2 0-4-1-5-3-1-2-3-4-5-4z"/>
<path d="M28 38c2 3 5 5 9 5 1 4 4 7 8 8-3 2-5 5-5 9-3-2-7-3-11-2 1-3 1-7-1-10-3 0-6-1-8-4 3-1 6-3 8-6z"/>
</svg>
</div>
<div class="tabs" id="tabs">
<button class="nav-btn" id="nav-toggle">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><line x1="4" y1="7" x2="20" y2="7"/><line x1="4" y1="12" x2="20" y2="12"/><line x1="4" y1="17" x2="20" y2="17"/></svg>
全部导航
</button>
<div class="tab" data-go="main">
<span class="ic"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M3 11l9-8 9 8"/><path d="M5 10v10h14V10"/></svg></span>
主页
</div>
<div class="tab" id="tab-userlist" data-go="userlist" style="display:none">
用户列表 <span class="close" data-close="userlist">✕</span>
</div>
<div class="tab" id="tab-userdetail" data-go="userdetail" style="display:none">
用户信息单据 <span class="close" data-close="userdetail">✕</span>
</div>
</div>
<div class="right">
<span class="ic" title="搜索">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="11" cy="11" r="7"/><line x1="21" y1="21" x2="16.5" y2="16.5"/></svg>
</span>
<span class="ic" title="通知">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M6 8a6 6 0 0 1 12 0v5l1.5 3h-15L6 13z"/><path d="M10 19a2 2 0 0 0 4 0"/></svg>
</span>
<div class="user">
<span class="ic"><svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="3" y="5" width="18" height="14" rx="1"/><path d="M3 9h18"/></svg></span>
朱子纯(超级管理员) <span style="font-size:10px">▾</span>
</div>
<span class="more">⋯</span>
</div>
</div>
<!-- ======= STAGE ======= -->
<div class="stage" id="stage">
<!-- NAV OVERLAY -->
<div id="nav-overlay">
<div class="side" id="nav-side"></div>
<div class="grid" id="nav-grid"></div>
</div>
<!-- ===== MAIN ===== -->
<section class="screen active" id="screen-main">
<div class="main-wrap">
<div style="display:flex;flex-direction:column;gap:10px;min-height:0">
<!-- KPI head bar -->
<div class="panel kpi-head">
<span class="title">KPI监控</span>
<span class="stat">今日未处理:<b>37428</b></span>
<span class="sep">|</span>
<span class="stat blue">未清总数:<b>56433</b></span>
<button class="ai-btn">
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M12 2l2 5 5 2-5 2-2 5-2-5-5-2 5-2z"/></svg>
小ai同学,请帮我安排今日工作
</button>
</div>
<!-- KPI body grid -->
<div class="three-col">
<!-- Left tree -->
<div class="left-nav nav-tree">
<div class="group"><span class="arrow"></span><span class="ico">📁</span>按角色</div>
<div class="item active"><span class="ico">📄</span>所有部门 (37428)</div>
<div class="item"><span class="ico">📄</span>核价人员 (17)</div>
<div class="item"><span class="ico">📄</span>销售人员 (0)</div>
<div class="item"><span class="ico">📄</span>印前 (11)</div>
<div class="item"><span class="ico">📄</span>客服部 (30127)</div>
<div class="item"><span class="ico">📄</span>技术研发部 (47)</div>
<div class="item"><span class="ico">📄</span>车间主管 (316)</div>
<div class="item"><span class="ico">📄</span>工艺部 (6)</div>
<div class="item"><span class="ico">📄</span>物控部 (728)</div>
<div class="item"><span class="ico">📄</span>生产计划部 (225)</div>
<div class="item"><span class="ico">📄</span>版房 (120)</div>
<div class="item"><span class="ico">📄</span>生产车间 (596)</div>
<div class="item"><span class="ico">📄</span>工艺技术部 (0)</div>
<div class="item"><span class="ico">📄</span>品质管理部 (589)</div>
<div class="item"><span class="ico">📄</span>储运部 (3496)</div>
<div class="item"><span class="ico">📄</span>通用 (0)</div>
<div class="item"><span class="ico">📄</span>外发组 (867)</div>
<div class="item"><span class="ico">📄</span>材料仓管 (0)</div>
<div class="item"><span class="ico">📄</span>机修组 (42)</div>
<div class="item"><span class="ico">📄</span>应收 (30)</div>
<div class="item"><span class="ico">📄</span>出纳 (211)</div>
<div class="item"><span class="ico">📄</span>应付 (0)</div>
<div class="item"><span class="ico">📄</span>客服 (0)</div>
<div class="group"><span class="arrow"></span><span class="ico">📁</span>按流程</div>
<div class="item"><span class="ico">📄</span>估价管理流程 (17)</div>
<div class="item"><span class="ico">📄</span>设计制作流程 (11)</div>
<div class="item"><span class="ico">📄</span>新品研发流程 (11)</div>
<div class="item"><span class="ico">📄</span>材料测试流程 (51)</div>
<div class="item"><span class="ico">📄</span>订单下达流程 (30118)</div>
</div>
<div class="center">
<div class="panel" style="overflow:auto">
<div class="kpi-body" id="kpi-body"></div>
</div>
</div>
</div>
</div>
<!-- right side common ops -->
<div class="panel common-ops" style="height:fit-content">
<div class="h">常用操作</div>
<a data-go="userlist">用户列表</a>
<a>系统功能模块设置</a>
</div>
</div>
<footer class="foot">
<span style="vertical-align:middle">🛠</span>
©Copyright Antler Software <span class="pipe">|</span> 印刷智慧工厂 <span class="pipe">|</span> 印刷MES <span class="pipe">|</span> 印刷ERP <span class="pipe">|</span> 印刷电商平台 <span class="pipe">|</span> 文件智能处理 <span class="pipe">|</span> 印前自动化 <span class="pipe">|</span> 400-880-6237
<span class="police">
<svg viewBox="0 0 24 24" fill="#3a6cb6"><path d="M12 2l9 4v6c0 5-4 9-9 10-5-1-9-5-9-10V6z"/></svg>
沪ICP备14034791号-1
</span>
</footer>
</section>
<!-- ===== USER LIST ===== -->
<section class="screen" id="screen-userlist">
<div class="toolbar">
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M21 12a9 9 0 1 1-3-6.7"/><path d="M21 4v5h-5"/></svg>刷新</span>
<span class="tb-btn" id="btn-add" data-add-user="1"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="12" r="9"/><path d="M12 8v8M8 12h8"/></svg>新增</span>
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M4 4h12l4 4v12H4z"/><path d="M16 4v4h4"/><path d="M8 12h8M8 16h8"/></svg>导出Excel</span>
<span class="spacer"></span>
<span class="gear">⚙</span>
</div>
<div class="filterbar">
<select><option>全部用户</option></select>
<select><option>用户名</option></select>
<select><option>包含</option></select>
<input type="text" />
<span class="down">▾</span>
<button class="btn"><svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="11" cy="11" r="7"/><line x1="21" y1="21" x2="16.5" y2="16.5"/></svg>搜索</button>
<button class="btn ghost">⊗ 清空</button>
</div>
<div class="table-shell">
<table class="grid-table" id="user-table">
<thead>
<tr>
<th style="width:36px"></th>
<th style="width:60px">序号</th>
<th>用户名 <span style="color:#aaa">⇅ ⌕</span></th>
<th>员工名 <span style="color:#aaa">⇅ ⌕</span></th>
<th>用户号 <span style="color:#aaa">⇅ ⌕</span></th>
<th>部门 <span style="color:#aaa">⇅ ⌕</span></th>
<th>用户类型 <span style="color:#aaa">⇅ ⌕</span></th>
<th>语言 <span style="color:#aaa">⇅ ⌕</span></th>
<th>作 <span style="color:#aaa">⇅ ⌕</span></th>
<th>登录日期</th>
<th>制单人 <span style="color:#aaa">⇅ ⌕</span></th>
<th>制单日期</th>
</tr>
</thead>
<tbody id="user-tbody"></tbody>
</table>
</div>
<div class="pager">
<span>当前显示 共37个单据 共37条记录</span>
<span class="pgbtn">‹</span>
<span class="pgcur">1</span>
<span class="pgbtn">›</span>
<select><option>10000 条/页</option></select>
</div>
</section>
<!-- ===== USER DETAIL ===== -->
<section class="screen" id="screen-userdetail">
<div class="toolbar">
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="12" r="9"/><path d="M12 8v8M8 12h8"/></svg>新增</span>
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M14 3l7 7-11 11H3v-7z"/></svg>修改</span>
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="12" r="9"/><path d="M8 8l8 8M16 8l-8 8"/></svg>删除</span>
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M5 4h11l3 3v13H5z"/><rect x="8" y="4" width="8" height="5"/></svg>保存</span>
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="12" r="9"/><path d="M9 9l6 6M15 9l-6 6"/></svg>取消</span>
<span class="tb-btn"><svg class="ic" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="3" y="3" width="7" height="7"/><rect x="14" y="3" width="7" height="7"/><rect x="3" y="14" width="7" height="7"/><rect x="14" y="14" width="7" height="7"/></svg>功能</span>
<span class="tb-btn">作废</span>
<span class="tb-btn">重置密码</span>
<span class="tb-btn">取消作废</span>
<span class="spacer"></span>
<span class="gear">⚙</span>
</div>
<div class="form-grid">
<div class="form-cell"><span class="lbl">创建时间:</span><div class="field with-cal readonly" id="f-ctime">2023-10-26 17:02:01</div></div>
<div class="form-cell"><span class="lbl">制单人:</span><div class="field readonly" id="f-creator">超级管理员</div></div>
<div class="form-cell"><span class="lbl req">员工名:</span><div class="field with-caret" id="f-empname">管广飞</div></div>
<div class="form-cell"><span class="lbl req">用户名:</span><input type="text" id="f-username" value="管广飞"/></div>
<div class="form-cell"><span class="lbl req">类型:</span><div class="field with-caret" id="f-type">超级管理员</div></div>
<div class="form-cell"><span class="lbl req">语言:</span><div class="field with-caret" id="f-lang">英文</div></div>
<div class="form-cell"><span class="lbl req">用户号:</span><input type="text" id="f-userno" value="ggf"/></div>
<div class="form-cell"></div>
<div class="form-cell"><span class="lbl">单据修改权限:</span><span class="cb"></span></div>
</div>
<div class="tabs-row">
<div class="tb active">权限组</div>
<div class="tb">客户查看权限</div>
<div class="tb">供应商查看权限</div>
<div class="tb">人员查看权限</div>
<div class="tb">工序查看权限</div>
<div class="tb">司机查看权限</div>
</div>
<div class="perm-list" id="perm-list">
<div class="perm-row head"><span class="cb"></span><span>权限分类</span><span class="ic" style="margin-left:auto;color:#aaa">⇅</span></div>
</div>
</section>
<!-- ===== LOGIN ===== -->
<section class="screen" id="screen-login">
<div class="login-wrap">
<div class="login-head">
<span class="lg">
<svg viewBox="0 0 64 64" width="42" height="42" fill="#0e1216">
<path d="M14 10c2 4 1 8-1 11 3-1 7 0 10 3 1-4 4-7 8-7-3 3-4 7-3 11l4 1c-1 3 0 6 3 8-3 0-6 1-8 4-1-3-4-5-8-5 2-3 2-7 0-10-3 1-7 0-10-3 3 0 5-2 6-5l-1-8z"/>
<path d="M48 14c-2 3-2 6-1 9-2-2-5-2-8-1 1 3 1 6-1 9 3 0 5 2 6 5 1-3 4-5 7-5-2-3-2-6 0-9 2 1 5 1 7-1-2 0-4-1-5-3-1-2-3-4-5-4z"/>
<path d="M28 38c2 3 5 5 9 5 1 4 4 7 8 8-3 2-5 5-5 9-3-2-7-3-11-2 1-3 1-7-1-10-3 0-6-1-8-4 3-1 6-3 8-6z"/>
</svg>
</span>
<span class="name">Antler ERP</span>
<span class="sub">欢迎登录EBC平台</span>
</div>
<div class="login-hero">
<div class="login-text">
<div class="en">Enterprise Business Capability</div>
<div class="zh">企业业务能力平台</div>
<div class="erp">ERP</div>
</div>
<div class="login-card">
<h3>用户登录</h3>
<div class="lf">
<span class="ic"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="8" r="4"/><path d="M4 21c0-4 4-7 8-7s8 3 8 7"/></svg></span>
<span class="div"></span>
<input type="text" placeholder="请输入你的用户名" />
</div>
<div class="lf">
<span class="ic"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="4" y="11" width="16" height="10" rx="1"/><path d="M8 11V7a4 4 0 0 1 8 0v4"/></svg></span>
<span class="div"></span>
<input type="password" placeholder="请输入你的密码" />
</div>
<div class="lf dropdown" id="ver-drop">
<input type="text" value="标准版" readonly style="cursor:pointer"/>
<div class="opt">
<div class="o">标准版</div>
</div>
<div class="opt">
<div class="o">标准版1</div>
</div>
</div>
<button class="submit" data-go="main">登 录</button>
</div>
</div>
<div class="login-foot">
🛠 ©Copyright Antler Software | 印刷智慧工厂 | 印刷MES | 印刷ERP | 印刷电商平台 | 文件智能处理 | 印前自动化 | 400-880-6237
<span style="display:inline-flex;align-items:center;gap:4px;margin-left:6px">
<svg width="14" height="14" viewBox="0 0 24 24" fill="#3a6cb6"><path d="M12 2l9 4v6c0 5-4 9-9 10-5-1-9-5-9-10V6z"/></svg>
沪ICP备14034791号-1
</span>
</div>
</div>
</section>
</div>
</div>
<script>
/* ============ KPI ROWS ============ */
const kpiHeader = ['导航类型','角色','KPI待处理事项(当前行双击进入)','KPI内容描述及处理结果(点击蓝色查看明细)','今日未处理','未清总数','子流程'];
const kpiRows = [
// [role, item, desc, today, total, sub, navType?, rowSpanRole?, rowSpanSub?]
// group 1: 估价管理流程 — 5 rows, role 核价人员 spans 4, 销售人员 1
{role:'核价人员', item:'01/04【新增】新报价单', desc:'报价单明细', today:'-', total:'-', sub:'估价管理流程', navTypeFirst:true, roleSpan:4, subSpan:5},
{role:null, item:'02/04 审核后报价单->客户确认价格', desc:'报价单明细', today:'16', total:'16', red:true},
{role:null, item:'03/04 客户不认可->二次确认', desc:'报价单明细', today:'-', total:'-'},
{role:null, item:'04/04 报价单->销售订单', desc:'销售订单明细', today:'1', total:'1', red:true},
{role:'销售人员', item:'04/04 报价单->销售订单(标签)', desc:'销售订单明细(标签)', today:'0', total:'0', red:true},
// group 2: 设计制作流程 — 印前 (2 rows), span 2
{role:'印前', item:'1/2 新增设计申请单', desc:'设计申请明细', today:'-', total:'-', sub:'设计制作流程', roleSpan:2, subSpan:2},
{role:null, item:'2/2 设计申请->设计制作', desc:'根据设计申请单进行设计制作,当日16:00前审核的为今日任务,16:00后(含)顺延至次日', today:'11', total:'11', red:true},
// group 3: 新品研发流程 — 客服部, 技术研发部, 客服部, 技术研发部
{role:'客服部', item:'1/1 研发申请->文件制作', desc:'根据研发申请单,制作电子文件,当日16:00前下达的为今日任务,16:00后(含)顺延至次日', today:'0', total:'12', red:true, sub:'新品研发流程', subSpan:5},
{role:'客服部', item:'1/5 新增研发申请单', desc:'研发申请明细', today:'-', total:'-'},
{role:'技术研发部', item:'2/5 研发申请>>研发工单', desc:'及时开立研发工单,当日16:00前审核的为今日任务,16:00后(含)顺延至次日', today:'4', total:'4', red:true, roleSpan:2},
{role:null, item:'3/5 研发工单>>完工处理', desc:'计划人员在交货日期前确认工单完工', today:'7', total:'7', red:true},
{role:'客服部', item:'4/5 研发工单->客户确认', desc:'工单完工后需在7天内和客户确认样品', today:'-', total:'2703'},
// 5/5 技术研发部
{role:'技术研发部', item:'5/5 客户确认->工艺卡', desc:'根据客户已经确认的研发工单,生成产品工艺卡。当日16:00前确认的为今日任务,16:00后(含)顺延至次日', today:'0', total:'1632', red:true, sub:'', subSpan:0},
// group 4: 材料测试流程 — 车间主管, 技术研发部, 技术研发部
{role:'车间主管', item:'1/3 工单(测试部门数)->车间反馈', desc:'车间主管在工单完工前对测试材料进行数据反馈', today:'10', total:'115', red:true, sub:'材料测试流程', subSpan:3},
{role:null, item:'2/3 车间反馈->车间补充(多部门)', desc:'补充新材料测试信息,车间反馈次日16:00前的为当日任务,16:00后(含)顺延一日', today:'8', total:'8', red:true, roleSpan:2},
{role:'技术研发部', item:'2/3 车间反馈->工程部反馈(单部门)', desc:'工程部对新材料的测试结果进行反馈,车间反馈次日16:00前的为当日任务,16:00后(含)顺延一日', today:'23', total:'23', red:true},
];
/* Render KPI grid via spans simulated with empty cells (CSS grid) */
(function renderKpi(){
const host = document.getElementById('kpi-body');
const heads = ['导航类型','角色','KPI待处理事项(当前行双击进入)','KPI内容描述及处理结果(点击蓝色查看明细)','今日未处理','未清总数','子流程'];
heads.forEach(h => { const d = document.createElement('div'); d.className='h'; d.textContent=h; host.appendChild(d); });
// We'll render 7 columns per row.
// Track active rowspans for col 0(navType), 1(role), 6(sub).
// We model by emitting blank cells for spanned positions (visually merge by removing borders).
// Simpler: emit single tall cells via grid-row span.
let r = 2; // CSS row index (1-based) but auto rows after header row = 1
// Use explicit grid placement
let line = 2;
// First, emit a single big "按角色" cell for col1 spanning all data rows? Original shows rows have nav type only at start.
// We'll emit "按角色" merged across all rows (24 rows in screenshot share 按角色). Use full span.
// Emit nav cell once
const total = kpiRows.length;
const navCell = document.createElement('div');
navCell.style.gridColumn = '1';
navCell.style.gridRow = `2 / span ${total}`;
navCell.className = 'center';
navCell.textContent = '按角色';
host.appendChild(navCell);
let curRow = 2;
let i = 0;
while (i < kpiRows.length) {
const row = kpiRows[i];
const altClass = (i%2===1)?'row-alt':'';
// role
if (row.role) {
const span = row.roleSpan || 1;
const c = document.createElement('div');
c.style.gridColumn = '2';
c.style.gridRow = `${curRow} / span ${span}`;
c.className = 'center ' + altClass;
c.textContent = row.role;
host.appendChild(c);
}
// item
const item = document.createElement('div');
item.style.gridColumn = '3';
item.style.gridRow = `${curRow}`;
item.className = 'link ' + altClass;
item.textContent = row.item;
host.appendChild(item);
// desc
const desc = document.createElement('div');
desc.style.gridColumn = '4';
desc.style.gridRow = `${curRow}`;
desc.className = 'link ' + altClass;
desc.textContent = row.desc;
host.appendChild(desc);
// today
const today = document.createElement('div');
today.style.gridColumn = '5';
today.style.gridRow = `${curRow}`;
today.className = 'num ' + (row.red?'num-red':'') + ' ' + altClass;
today.textContent = row.today;
host.appendChild(today);
// total
const tot = document.createElement('div');
tot.style.gridColumn = '6';
tot.style.gridRow = `${curRow}`;
tot.className = 'num ' + (row.red?'num-red':'') + ' ' + altClass;
tot.textContent = row.total;
host.appendChild(tot);
// sub
if (row.sub && row.subSpan) {
const c = document.createElement('div');
c.style.gridColumn = '7';
c.style.gridRow = `${curRow} / span ${row.subSpan}`;
c.className = 'subproc';
c.textContent = row.sub;
host.appendChild(c);
}
curRow++;
i++;
}
host.style.gridTemplateRows = `38px repeat(${total}, minmax(38px, auto))`;
})();
/* ============ USER TABLE ============ */
const users = [
['管广飞','管广飞','ggf','工艺技术','超级管理员','英文','','2026-02-27 17:48:11','超级管理员','2023-10-26 17:02:01'],
['李斌','李斌','lib','印前制作','超级管理员','中文','','2026-01-28 16:53:32','超级管理员','2023-10-26 17:02:58'],
['系统管理员','','admin','','超级管理员','中文','','2026-05-06 12:28:49','超级管理员','2023-10-26 17:05:58'],
['朱财喜','朱财喜','zhucx','印刷车间','超级管理员','中文','','2026-03-23 10:08:29','超级管理员','2023-11-20 10:29:09'],
['ljh','ljh','ljh','机修','超级管理员','中文','','2026-05-06 11:14:04','YFZ','2024-10-08 13:48:59'],
['wx','汪鑫','wx','工艺技术','超级管理员','中文','','2026-03-23 11:57:13','超级管理员','2023-11-22 13:22:35'],
['钱豹','钱豹','qianb','物控部','超级管理员','中文','','2026-04-28 16:49:04','超级管理员','2023-11-27 15:30:11'],
['zyf','张寅飞','zyf','印前制作','超级管理员','中文','','2025-09-11 11:42:12','LJH','2024-11-11 15:59:52'],
['孟威','孟威','mengw','工艺技术','超级管理员','中文','','2026-05-06 13:56:22','系统管理员','2025-06-03 21:26:07'],
['杭仁萍','杭仁萍','hangrp','跟单','超级管理员','中文','','2026-04-30 14:18:28','孟威','2025-06-05 11:11:56'],
['李丹','','李丹','','超级管理员','中文','','2026-04-27 13:47:58','杭仁萍','2025-06-11 10:34:29'],
['王宽明','王宽明','王宽明','印刷车间','超级管理员','中文','','2026-04-25 16:07:38','李丹','2025-06-11 10:40:22'],
['潘茹','潘茹','潘茹','工艺技术','超级管理员','中文','','2025-06-17 09:04:46','李丹','2025-06-11 10:41:07'],
['耿广东','耿广东','耿广东','工艺技术','超级管理员','中文','','2025-07-04 14:40:02','李丹','2025-06-11 10:41:37'],
['yut','余涛','yut','印刷车间','超级管理员','中文','','2026-04-03 18:39:34','杭仁萍','2025-06-17 14:32:49'],
['lzj','廖赵军','lzj','财务部','超级管理员','中文','','','杭仁萍','2025-06-26 10:57:28'],
['caojy','caojy','caojy','物控部','超级管理员','中文','','2026-02-02 13:58:14','李明青','2025-07-28 13:59:21'],
['陈淑贤','陈淑贤','csx','品质管理部','超级管理员','中文','','2026-04-24 15:05:52','csx','2025-07-29 13:26:58'],
['张红英','张红英','zhy','模烫车间','超级管理员','中文','','2025-12-24 16:24:52','系统管理员','2025-08-18 09:34:47'],
['lzy','吕政彦','吕政彦','总经理办公室','超级管理员','中文','','2026-04-16 08:54:24','杭仁萍','2025-08-21 11:16:12'],
['陈鑫涛','陈鑫涛','cxt','品质管理部','超级管理员','中文','','2026-03-23 10:12:47','陈淑贤','2025-09-01 11:22:00'],
['陆鑫','陆鑫','luxin','工艺技术','超级管理员','中文','','2026-05-05 17:56:03','张震','2025-09-04 11:48:44'],
['陆鑫-储运部…','陆鑫','ZY0006','工艺技术','普通用户','中文','','2025-11-19 09:11:27','陆鑫','2025-09-05 11:28:37'],
['朱咸兵','朱咸兵','zhuxb','工艺技术','超级管理员','中文','','2026-04-27 13:40:15','钱豹','2025-09-08 15:00:29'],
['孟臻晟','孟臻晟','mengzs','装订车间','超级管理员','中文','','2026-05-07 09:17:57','系统管理员','2025-09-12 16:24:07'],
['pengm','彭敏','pengm','计划管理','超级管理员','中文','','2026-05-06 11:28:33','彭敏','2025-10-16 13:30:32'],
['张伟','张伟','zhangw','印刷车间','超级管理员','中文','','2026-03-15 09:22:14','张伟','2025-10-22 10:12:00'],
['李娜','李娜','lin','质检部','普通用户','中文','','2026-04-02 14:50:33','李丹','2025-11-04 16:08:21'],
['王军','王军','wangj','装订车间','超级管理员','中文','','2026-04-15 17:10:55','系统管理员','2025-11-15 09:30:11'],
['赵敏','赵敏','zhaom','财务部','超级管理员','中文','','2026-05-01 08:45:00','赵敏','2025-12-01 11:00:00'],
['周强','周强','zhouq','物控部','普通用户','中文','','2026-04-20 10:30:21','钱豹','2025-12-08 14:22:33'],
['吴丽','吴丽','wul','人事部','超级管理员','中文','','2026-04-25 15:18:09','吴丽','2026-01-05 09:15:42'],
['郑涛','郑涛','zhengt','工艺技术','超级管理员','中文','','2026-05-02 11:40:58','郑涛','2026-01-18 13:55:27'],
['冯静','冯静','fengj','客服部','超级管理员','中文','','2026-05-04 16:25:17','冯静','2026-02-02 10:08:14'],
['孙磊','孙磊','sunl','装订车间','普通用户','中文','','2026-05-05 09:55:36','系统管理员','2026-02-20 15:32:48'],
['马超','马超','mac','机修','超级管理员','中文','','2026-05-06 14:12:25','LJH','2026-03-08 11:48:09'],
['朱子纯','朱子纯','zhuzc','总经理办公室','超级管理员','中文','','2026-05-07 13:00:00','超级管理员','2026-03-22 09:00:00'],
];
(function renderUsers(){
const tb = document.getElementById('user-tbody');
users.forEach((u,i)=>{
const tr = document.createElement('tr');
tr.innerHTML = `
<td class="radio-cell"><span class="radio-dot"></span></td>
<td>${i+1}</td>
<td>${u[0]}</td>
<td>${u[1]}</td>
<td>${u[2]}</td>
<td>${u[3]}</td>
<td>${u[4]}</td>
<td>${u[5]}</td>
<td><input class="cb" type="checkbox"></td>
<td>${u[7]}</td>
<td>${u[8]}</td>
<td>${u[9]}</td>
`;
tr.addEventListener('dblclick', ()=> goTo('userdetail'));
tb.appendChild(tr);
});
})();
/* ============ PERM LIST ============ */
const perms = ['默认显示(必选)','禁止查看价格','客服跟单','报价组员工','物控部员工','供应链PMC','允许查看订单价格','储运部员工','外部供应商','品质部员工','技术中心员工','机修组员工','生产部计划员工','外发组员工','模烫车间','装订车间','后加工车间','品质部管理','精品车间','人事组','统计组','机修主管','样品开发部员工','设计开发','总经办','审核组','结算组','打样车间','制版组','文控组','行政组','成本组','采购组','OA管理员','开发组','API对接','MES管理员','报表组'];
(function(){
const host = document.getElementById('perm-list');
perms.forEach(p=>{
const r = document.createElement('div');
r.className = 'perm-row';
r.innerHTML = `<span class="cb"></span><span>${p}</span>`;
host.appendChild(r);
});
})();
/* ============ NAV OVERLAY ============ */
const navSide = [
{ico:'sales', label:'销售管理'}, {ico:'dcs', label:'DCS系统'}, {ico:'prod', label:'产品管理'},
{ico:'ops', label:'生产运营'}, {ico:'exec', label:'生产执行'}, {ico:'mold', label:'模具管理'},
{ico:'cart', label:'采购管理'}, {ico:'mat', label:'材料库存'}, {ico:'fg', label:'成品库存'},
{ico:'out', label:'外协管理'}, {ico:'logi', label:'物流管理'}, {ico:'qa', label:'质量管理'},
{ico:'fin', label:'财务管理'}, {ico:'cost1', label:'成本管理(专)'}, {ico:'cost2', label:'成本管理'},
{ico:'eq', label:'设备管理'}, {ico:'hr', label:'人事行政'}, {ico:'oa', label:'OA系统'},
{ico:'base', label:'基础设置'}, {ico:'sys', label:'系统设置', active:true},
];
const sideIco = {
sales:'M3 7l3 10h12l3-10M5 7l1-3h12l1 3M9 21a1 1 0 1 0 0-2 1 1 0 0 0 0 2zm8 0a1 1 0 1 0 0-2 1 1 0 0 0 0 2z',
dcs:'M12 2l9 5-9 5-9-5z M3 12l9 5 9-5 M3 17l9 5 9-5',
prod:'M3 7l9-5 9 5v10l-9 5-9-5z',
ops:'M4 4h6v6H4zM14 4h6v6h-6zM4 14h6v6H4zM14 14h6v6h-6z',
exec:'M5 4h14v16H5z M5 9h14 M9 4v5',
mold:'M4 7h16v10H4z M8 7v10 M16 7v10',
cart:'M5 5h2l3 11h10l2-8H8 M9 20a1 1 0 1 0 0-2 1 1 0 0 0 0 2zm9 0a1 1 0 1 0 0-2 1 1 0 0 0 0 2z',
mat:'M4 21V8l8-5 8 5v13z M9 21v-7h6v7',
fg:'M3 21V9l9-6 9 6v12z',
out:'M12 12c2 0 4-1 4-4s-2-4-4-4-4 1-4 4 2 4 4 4z M4 21c0-4 4-7 8-7s8 3 8 7',
logi:'M3 7h11v9H3z M14 10h5l3 3v3h-8z M7 19a1 1 0 1 0 0-2 1 1 0 0 0 0 2zm10 0a1 1 0 1 0 0-2 1 1 0 0 0 0 2z',
qa:'M12 2l8 4v6c0 5-4 8-8 10-4-2-8-5-8-10V6z M9 12l2 2 4-4',
fin:'M12 2v20 M7 6h10 M7 10h10',
cost1:'M4 20V8 M9 20V4 M14 20v-8 M19 20v-6 M2 20h20',
cost2:'M4 20V8 M9 20V4 M14 20v-8 M19 20v-6 M2 20h20',
eq:'M12 8a4 4 0 1 1 0 8 4 4 0 0 1 0-8z M19 12a7 7 0 0 0-.5-2.5l1.5-1.5-2-2-1.5 1.5A7 7 0 0 0 14 7l-.5-2h-3l-.5 2A7 7 0 0 0 7.5 7.5L6 6 4 8l1.5 1.5A7 7 0 0 0 5 12',
hr:'M9 11a4 4 0 1 0 0-8 4 4 0 0 0 0 8z M2 21c0-4 3-7 7-7s7 3 7 7 M17 11a3 3 0 1 0 0-6 3 3 0 0 0 0 6z M22 21c0-3-2-5-5-5',
oa:'M3 7h18v12H3z M3 11h18 M8 7V4h8v3',
base:'M4 6h16 M4 12h16 M4 18h16 M8 6v12 M14 6v12',
sys:'M12 8a4 4 0 1 1 0 8 4 4 0 0 1 0-8z M19 12a7 7 0 0 0-.5-2.5l1.5-1.5-2-2-1.5 1.5A7 7 0 0 0 14 7l-.5-2h-3l-.5 2A7 7 0 0 0 7.5 7.5L6 6 4 8l1.5 1.5A7 7 0 0 0 5 12',
};
const navSideHost = document.getElementById('nav-side');
navSide.forEach(s=>{
const d = document.createElement('div');
d.className = 'si' + (s.active?' active':'');
d.innerHTML = `<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.6"><path d="${sideIco[s.ico]||''}"/></svg>${s.label}`;
navSideHost.appendChild(d);
});
const navCols = [
{title:'期初设置', items:['客户期初','供应商期初','材料期初','产品期初','数据导入','离线导出下载']},
{title:'用户管理', items:[{label:'用户列表',star:true,go:'userlist'},'系统权限','系统权限稽查表','权限组']},
{title:'系统参数', items:['系统参数','财务结账','系统常量配置']},
{title:'计算方案', items:['方案列表','计算参数']},
{title:'日志', items:['个性化模块','操作日志','异常清除KPI任务表','MYSQL监听器']},
{title:'开发平台', items:['自定义开发范例',{label:'系统功能模块设置',star:true},'EBC流程清单','功能模块界面设置','增删改存业务处理']},
{title:'API对接管理', items:['调用第三方接口(TOKEN配置)','调用第三方接口(接口定义)','被第三方调用(生成token)','数据同步','被第三方调用(API定义)']},
];
const navGridHost = document.getElementById('nav-grid');
navCols.forEach(c=>{
const col = document.createElement('div');
col.className = 'col';
let html = `<h3>${c.title}</h3>`;
c.items.forEach(it=>{
if (typeof it === 'string') html += `<a>${it}</a>`;
else html += `<a data-go="${it.go||''}">${it.label}${it.star?' <span class="star">★</span>':''}</a>`;
});
col.innerHTML = html;
navGridHost.appendChild(col);
});
/* ============ NAV / TABS ============ */
const screens = ['main','userlist','userdetail','login'];
function goTo(name){
screens.forEach(s=>document.getElementById('screen-'+s).classList.toggle('active', s===name));
// hide top bar on login
document.getElementById('topbar').style.display = (name==='login') ? 'none' : 'flex';
// tabs visibility
document.getElementById('tab-userlist').style.display = (['userlist','userdetail'].includes(name) || tabsOpen.userlist) ? 'flex' : 'none';
document.getElementById('tab-userdetail').style.display = (name==='userdetail' || tabsOpen.userdetail) ? 'flex' : 'none';
// tab active states
document.querySelectorAll('.topbar .tab').forEach(t=>t.classList.remove('active'));
if (name==='main') document.querySelectorAll('.topbar .tab')[0]?.classList.add('active');
if (name==='userlist') document.getElementById('tab-userlist').classList.add('active');
if (name==='userdetail') document.getElementById('tab-userdetail').classList.add('active');
// nav button active when on main with overlay; clear otherwise
document.getElementById('nav-overlay').classList.remove('show');
document.getElementById('nav-toggle').classList.remove('active');
// close login overlay if leaving
}
const tabsOpen = {userlist:false, userdetail:false};
function openTab(name){
if (name==='userlist'){ tabsOpen.userlist = true; }
if (name==='userdetail'){ tabsOpen.userlist = true; tabsOpen.userdetail = true; }
goTo(name);
}
document.body.addEventListener('click', (e)=>{
const go = e.target.closest('[data-go]');
if (go){
const name = go.dataset.go;
if (!name) return;
if (name==='userlist' || name==='userdetail') openTab(name);
else goTo(name);
return;
}
const close = e.target.closest('[data-close]');
if (close){
e.stopPropagation();
const which = close.dataset.close;
tabsOpen[which] = false;
if (which==='userdetail') goTo('userlist');
else goTo('main');
if (which==='userlist'){ tabsOpen.userdetail=false; }
return;
}
});
document.getElementById('nav-toggle').addEventListener('click', ()=>{
const ov = document.getElementById('nav-overlay');
ov.classList.toggle('show');
document.getElementById('nav-toggle').classList.toggle('active', ov.classList.contains('show'));
});
// new-user mode
function setUserDetailMode(mode){
const isNew = mode === 'new';
document.getElementById('f-ctime').textContent = isNew ? '' : '2023-10-26 17:02:01';
document.getElementById('f-creator').textContent = isNew ? '保存后自动生成' : '超级管理员';
document.getElementById('f-empname').textContent = isNew ? '' : '管广飞';
document.getElementById('f-type').textContent = isNew ? '' : '超级管理员';
document.getElementById('f-lang').textContent = isNew ? '' : '英文';
document.getElementById('f-username').value = isNew ? '' : '管广飞';
document.getElementById('f-userno').value = isNew ? '' : 'ggf';
document.querySelectorAll('#perm-list .perm-row:not(.head) .cb').forEach(cb=>{cb.classList.remove('checked')});
}
document.querySelector('[data-add-user]')?.addEventListener('click', ()=>{ setUserDetailMode('new'); openTab('userdetail'); });
// Default initial screen: login
goTo('login');
// version dropdown demo
document.getElementById('ver-drop').addEventListener('click', e=>{
e.currentTarget.classList.toggle('open');
});
</script>
</body>
</html>