高章伟
2022-03-18 4bfe21c4b5ddc089ae5a95f4b10f6cff148b690d
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
<apex:page action="{!init}" extensions="PAEDecisionRecordController" id="allPage" showheader="false" sidebar="false" standardcontroller="PAE_DecisionRecord__c" title="PAE判定记录">
    <apex:stylesheet value="{!URLFOR($Resource.blockUIcss)}">
    </apex:stylesheet>
    <apex:includescript value="{!URLFOR($Resource.jquery183minjs)}">
    </apex:includescript>
    <apex:includescript value="{!URLFOR($Resource.PleaseWaitDialog)}">
    </apex:includescript>
    <apex:includescript value="{!URLFOR($Resource.CommonUtilJs)}">
    </apex:includescript>
    <style type="text/css">
        .bPageBlock .pbTitle {
            width: 100%;
            text-align: center;
        }
    </style>
    <script>
        // function myDisabled(){
        //     // alert({!!isOSH})
        //     if("{!!isOSH}" == 'true'){
        //         document.getElementById('allPage:allForm:allBlock:unEditable:repairDetermineResult').disabled = "{!!isOSH}";
        //     }
        //     var productCount = "{!paedRecordDetailViewCount}";
        //     //  PAEDManagementCode PAEDReappearResult
        //     for (var i = 0; i < productCount; i++) {
        //         var id = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:';
        //         if(j$(escapeVfId(id + i +':variableinfo:isReadOnly')).attr('checked') == 'checked'){
        //             j$(escapeVfId(id + i +':PAEDManagementCode')).attr('disabled',true)
        //             j$(escapeVfId(id + i +':PAEDReappearResult')).attr('disabled',true)
        //         }
        //     }   
        // }
        // window.onload = myDisabled;
 
        function sendToSAPJS(onlySave) {
            if ('{!repa.FSE_ApplyForRepair_time__c}' == '' || '{!repa.Status__c}' != '0.申请完毕') {
                alert('不是申请完毕的不能受理');
                return;
            }
            if ('{!repa.SAP_Transfer_time__c}' != '') {
                alert('已经发送过SAP,不再受理了');
                return;
            }
 
            if ('{!today() - Datevalue(repa.CreatedDate)}' > 30) {
                alert("创建后超过30天,不能发送SAP了");
                return;
            }
            var repairAllowed = j$(escapeVfId('allPage:allForm:allBlock:unEditable:repairDetermineResult')).value();
 
            if (repairAllowed == '不可维修') {
                alert('是否可进行修理的判定是“不可维修”时,不允许SAP申请。');
                return;
            }
 
            if ('{!repa.ifDeadHurt__c}' == '有') {
                if (!confirm("是否确认AE要提交?")) {
                    return;
                }
            }
 
            if (confirm('确定后不能修改Intake Universal Code,是否要确定?')) {
                blockme();
                sendToSAP();
            }
        }
 
        //插入行
        function InsertRows() {
            //解除不可写状态
            blockme();
            InsertRow();
            
        }
        // 保存并关闭
        function SaveAndCloses(onlySave) {
            //  精琢科技   zxk   2021-11-17    start
            var productCount = "{!paedRecordDetailView}";
            //新值
            var PAEJudgeIdStr = '';
            //旧值
            var strJudgejsIdStr = '';
            var falsg = 0;
            //  + ':PAEJudge'
            for (var i = 0; i < productCount.length; i++) {
                var PAEJudgeId = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':PAEJudge';
                var strJudgejsId = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':strJudgejs';
                PAEJudgeIdStr = j$(escapeVfId(PAEJudgeId)).value();
                strJudgejsIdStr = j$(escapeVfId(strJudgejsId)).value();
                if (PAEJudgeIdStr != '' && PAEJudgeIdStr != strJudgejsIdStr) {
                    falsg = 1;
                    break;
                }
            }
            if (falsg == 1) {
                if (confirm('存在未知或者修改过PAE判定的code  确认保存?')) {
                    blockme();
                    SaveAndClose(onlySave);
                }
            } else {
                blockme();
                SaveAndClose(onlySave);
            }
            //  精琢科技   zxk   2021-11-17    end
        }
        //20200107 
        function toIntake() {
            blockme();
            toIntake();
        }
        //20191209 ljh
        function InsertMoreRowsJs(productIdx) {
            blockme();
            InsertMoreRows(productIdx);
 
        }
        // 2021-12-08  zxk   精琢科技  手动赋值逻辑  start
        function checkBoxTf() {
            // alert(lineNumberStr);
            var productCountStr = "{!paedRecordDetailView}";
            var PAEJudgeIdStr = '';
            var strJudgejsIdStr = '';
            var PaeIsSaveIdStr = '';
            var  MonitorPAE = '';
            var falsg = 0; 
            for (var i = 0; i < productCountStr.length; i++) {
                var PAEJudgeId = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':PAEJudge';
                var strJudgejsId = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':strJudgejs'; 
                var PaeIsSaveId = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':PaeIsSave';
                var MonitorPAEId = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':MonitorPAE';
                PAEJudgeIdStr = j$(escapeVfId(PAEJudgeId)).value();
                strJudgejsIdStr = j$(escapeVfId(strJudgejsId)).value();
                PaeIsSaveIdStr = j$(escapeVfId(PaeIsSaveId)).value();
                MonitorPAE = j$(escapeVfId(MonitorPAEId)).value();
                 if(PaeIsSaveIdStr != '1'){
                        if (strJudgejsIdStr != PAEJudgeIdStr || (strJudgejsIdStr == '' || strJudgejsIdStr == null)) {
                           j$(escapeVfId('allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':MonitorPAE')).attr('checked',true);
                        }else{
                           j$(escapeVfId('allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':MonitorPAE')).attr('checked',false);
 
                        }
                }
            }
        }
        // 2021-12-08  zxk   精琢科技  手动赋值逻辑  end
        
        function checkAll() {
            selectedSize = 0;
            // var productCount = j$(escapeVfId('allPage:allForm:allBlock:ConsumableorderdetailsSection:ConsumableorderdetailsCount')).value();
            var productCount = "{!paedRecordDetailViewCount}";
            // alert('paedRecordDetailViewCount' + productCount);
            // allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:2:variableinfo:consumablesCountproRowCheckbox
            if (j$(escapeVfId('checker')).attr('checked') == 'checked') {
                for (var i = 0; i < productCount; i++) {
                    var checkId = 'allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':variableinfo' + ':consumablesCountproRowCheckbox';
                    if (!j$(escapeVfId(checkId)).attr('disabled')) {
                        j$(escapeVfId(checkId)).attr('checked', true);
                        selectedSize++;
                    }
                }
            } else {
                for (var i = 0; i < productCount; i++) {
                    j$(escapeVfId('allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:' + i + ':variableinfo' + ':consumablesCountproRowCheckbox')).attr('checked', false);
                }
                // allPage:allForm:allBlock:unEditable:ConsumableorderdetailsTable:7:variableinfo:consumablesCountproRowCheckbox
            }
        }
    </script>
    <style>
        .dateFormat {
            display: none;
        }
 
        td.columuslowercolour {
            background-color: red;
            text-align: right;
        }
 
        td.columuscuperolour {
            background-color: yellow;
            text-align: right;
        }
    </style>
    <apex:form id="allForm">
        <apex:actionfunction action="{!InsertRow}" name="InsertRow" oncomplete="unblockUI();" rerender="unEditable">
        </apex:actionfunction>
        <!--         <apex:actionFunction name="InsertMoreRows" action="{!InsertMoreRows}" rerender="unEditable" onComplete="unblockUI();myDisabled();" >
        </apex:actionFunction> -->
        <apex:actionfunction action="{!InsertMoreRows}" name="InsertMoreRows" oncomplete="unblockUI();" rerender="unEditable,message">
        <!-- // 2021-12-08  zxk   精琢科技  手动赋值逻辑  start -->
 
            <apex:param assignto="{!productIdx}" name="productIdx" value="">
            </apex:param>
        <!-- // 2021-12-08  zxk   精琢科技  手动赋值逻辑  end -->
 
        </apex:actionfunction>
        <apex:actionfunction action="{!SaveAndClose}" name="SaveAndClose" oncomplete="unblockUI();" rerender="unEditable,message">
            <apex:param assignto="{!CancelineFlag}" name="firstParam" value="">
            </apex:param>
        </apex:actionfunction>
        <!-- tqz 2020/06/19 start -->
        <apex:actionfunction action="{!sendToSAP}" name="sendToSAP" oncomplete="unblockUI();" rerender="unEditable,message">
            <apex:param assignto="{!CancelineFlag}" name="firstParam" value="">
            </apex:param>
        </apex:actionfunction>
        <!-- tqz 2020/06/19 end -->
        <apex:actionfunction action="{!toIntake}" name="toIntake" oncomplete="unblockUI();" rerender="unEditable">
        </apex:actionfunction>
        <apex:actionfunction action="{!ReturnRepairInterface}" name="ReturnRepairInterface" oncomplete="unblockUI();" rerender="unEditable">
        </apex:actionfunction>
        <apex:outputpanel id="allPanel">
            <apex:pageblock id="allBlock">
                <apex:pageblock id="unEditable" rendered="{!editAble}" title="{!IF(RecordTypeName = 'ASRCDecision' , 'Intake universal code 编辑画面', 'Final universal code 编辑画面')}">
                    <table cellspacing="10">
                        <colgroup>
                            <col width="7%">
                            </col>
                            <col width="10%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <col width="7%">
                            </col>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' , true, false)}">
                                <col width="15%">
                                </col>
                                <col width="10%">
                                </col>
                            </apex:outputpanel>
                        </colgroup>
                        <tr>
                            <td align="left">
                                <apex:outputtext id="OrderCode_out" value="{!$Label.PAE}">
                                </apex:outputtext>
                            </td>
                            <!-- <td/> -->
                            <!-- <td align="left" ><apex:outputField id="OrderStatus_out" value="{!rdRecord.PAE_DetermineResults__c}"/></td> -->
                            <!-- 2020/07/28 taoqz start -->
                            <!-- PAE判定结果 由选项列表改为经过工作流更新后的文本 -->
                            <td align="left">
                                <apex:inputfield id="OrderStatus_out" value="{!rdRecord.PAEDetail_DetermineResults__c}">
                                </apex:inputfield>
                            </td>
                            <!-- 2020/07/28 taoqz end -->
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                <!-- <th>AS-RC</th> -->
                                <td align="right">
                                    {!$ObjectType.Repair__c.fields.Repair_ConfirmationDate__c.label}:
                                </td>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' , true, false)}">
                                <td align="right">
                                    {!$ObjectType.Repair__c.fields.OCSM_RC_CordingDate__c.label}:
                                </td>
                            </apex:outputpanel>
                            <td align="left">
                                <apex:outputfield value="{!rdRecord.PAE_ConfirmationDate__c}">
                                </apex:outputfield>
                            </td>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                <!-- <th>AS-RC</th> -->
                                <td align="right">
                                    {!$ObjectType.Repair__c.fields.Repair_Authenticator__c.label}:
                                </td>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' , true, false)}">
                                <!-- <th>AS-AC</th> -->
                                <td align="right">
                                    {!$ObjectType.Repair__c.fields.OCSM_RC_CordingUser__c.label}:
                                </td>
                            </apex:outputpanel>
                            <td align="left">
                                <apex:outputfield value="{!rdRecord.PAE_Authenticator__c}">
                                </apex:outputfield>
                            </td>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa != null, true, false)}">
                                <!-- <th>AS-RC</th> -->
                                <td align="right">
                                    {!$ObjectType.Repair__c.fields.SAP_Transfer_time__c.label}:
                                </td>
                                <td align="left">
                                    <apex:outputfield value="{!repa.SAP_Transfer_time__c}">
                                    </apex:outputfield>
                                </td>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' , true, false)}">
                                <td align="right">
                                    再现结果确认:
                                </td>
                                <td align="left" style="{!IF(rdRecord.PAE_reappear_confirm__c = '未确认' , 'color: red;font-weight: 800;', '')}">
                                    <apex:outputfield value="{!rdRecord.PAE_reappear_confirm__c}">
                                    </apex:outputfield>
                                </td>
                                <input class="btn" onclick="toIntake();return false;" style="margin-left:30px;float:right;{!IF(rdRecord.PAE_reappear_confirm__c = '未确认','color: red;','')}" type="button" value="Intake universal code 编辑
"/>
                            </apex:outputpanel>
                        </tr>
                        <tr>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa != null , true, false)}">
                                <!-- <th>AS-RC</th> -->
                                <td align="left">
                                    {!$ObjectType.Repair__c.fields.Repair_Determine__c.label}:
                                </td>
                                <!-- If 要, change to Red color -->
                                <td align="left" style="{!IF(repa.Repair_Determine__c = '要' ,'color: red', '')}">
                                    <apex:outputfield value="{!repa.Repair_Determine__c}">
                                    </apex:outputfield>
                                </td>
                            </apex:outputpanel>
                            <!-- <apex:outputPanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                <td align="right" > 进行修理的判定结果:</td>
                                <td align="left" >  
                                    <apex:InputField value="{!repa.Repair_Determine_result__c}"/>
                                </td>
                            </apex:outputPanel> -->
                            <!-- update by rentongxiao 2020-09-21 start -->
                            <!-- <apex:outputPanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision', true, false)}">
                                <td align="right" > {!$ObjectType.Repair__c.fields.if_Repair_Allowed__c.label}:</td>
                                <td align="left" >  
                                    <apex:InputField id="repairDetermineResult"  value="{!repa.if_Repair_Allowed__c}" rendered="{!isOSH}"/>
                                    <apex:outputField id="repairDetermineResultout"  value="{!repa.if_Repair_Allowed__c}" rendered="{!!isOSH}"/>
                                </td>
                                
                            </apex:outputPanel>
 
                            <apex:outputPanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision', true, false)}">
                                <td align="right" > {!$ObjectType.Repair__c.fields.NotAllowedReason__c.label}:</td>
                                <td align="left" colspan="3">  
                                    <apex:InputField id="NotAllowedReason"  value="{!repa.NotAllowedReason__c}" rendered="{!isOSH}"/>
                                    <apex:outputField id="NotAllowedReasontout"  value="{!repa.NotAllowedReason__c}" rendered="{!!isOSH}"/>
                                </td>
                                
                            </apex:outputPanel> -->
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa != null, true, false)}">
                                <td align="right">
                                    {!$ObjectType.Repair__c.fields.if_Repair_Allowed__c.label}:
                                </td>
                                <td align="left">
                                    <apex:inputfield id="repairDetermineResult" rendered="{!isOSH}" value="{!repa.if_Repair_Allowed__c}">
                                    </apex:inputfield>
                                    <apex:outputfield id="repairDetermineResultout" rendered="{!!isOSH}" value="{!repa.if_Repair_Allowed__c}">
                                    </apex:outputfield>
                                </td>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa != null, true, false)}">
                                <td align="right">
                                    {!$ObjectType.Repair__c.fields.NotAllowedReason__c.label}:
                                </td>
                                <td align="left" colspan="3">
                                    <apex:inputfield id="NotAllowedReason" rendered="{!isOSH}" value="{!repa.NotAllowedReason__c}">
                                    </apex:inputfield>
                                    <apex:outputfield id="NotAllowedReasontout" rendered="{!!isOSH}" value="{!repa.NotAllowedReason__c}">
                                    </apex:outputfield>
                                </td>
                            </apex:outputpanel>
                            <!-- update by rentongxiao 2020-09-21 end                           -->
                        </tr>
                        <tr>
                            <td colspan="4">
                            </td>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa != null , true, false)}">
                                <!-- <th>AS-RC</th> -->
                                <td align="left">
                                    {!$ObjectType.Repair__c.fields.OSHRAConfirmUser__c.label}:
                                </td>
                                <td align="left">
                                    <apex:outputfield value="{!repa.OSHRAConfirmUser__c}">
                                    </apex:outputfield>
                                </td>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa != null , true, false)}">
                                <!-- <th>AS-RC</th> -->
                                <td align="left">
                                    {!$ObjectType.Repair__c.fields.OSHRAConfirmDate__c.label}:
                                </td>
                                <td align="left">
                                    <apex:outputfield value="{!repa.OSHRAConfirmDate__c}">
                                    </apex:outputfield>
                                </td>
                            </apex:outputpanel>
                        </tr>
                    </table>
                    <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision'&& rdRecord.PAE_reappear_confirm__c = '未确认',false , true)}">
                        <table style="width:100%; {!IF(RecordTypeName = 'ASACDecision'&& rdRecord.PAE_reappear_confirm__c = '未确认', 'display: none;', '')}">
                            <tr>
                                <td>
                                    <!-- <apex:commandButton onclick="SaveAndCloses(false);"   value="1保存并关闭" style="margin-left:30px;width:80px;float:right" rerender="unEditable,message" oncomplete="unblockUI();"/>  -->
                                    <apex:commandbutton onclick="ReturnRepairInterface();return false;" oncomplete="unblockUI();" rerender="unEditable,message" style="margin-left:30px;width:80px;float:right" value="关闭">
                                    </apex:commandbutton>
                                    <apex:commandbutton disabled="{!IF(((repa.ETQ_UPLOAD_ERROR_GROUP__c != 'Intake') || editFlag) && savebuton == false && !(RecordTypeName='ASRCDecision'&&OCSM_QARA='1'),true,false)}" onclick="SaveAndCloses(1);return false;" oncomplete="unblockUI();" rerender="unEditable,message" style="margin-left:30px;width:80px;float:right" value="保存">
                                    </apex:commandbutton>
                                    <!-- <apex:commandButton value="保存并关闭" disabled="{!editFlag}"  rendered="{!IF((!isOSH && OCSM_QARA != '1' && RecordTypeName = 'ASRCDecision' && repa != null) || (RecordTypeName = 'ASACDecision') || (RecordTypeName = 'ASACDecision' && QISReportId != null),true,false)}" style="margin-left:30px;width:80px;float:right"  onclick="SaveAndCloses(2);return false;"  rerender="unEditable,message" oncomplete="unblockUI();" /> -->
                                    <!-- 20200810 Gzw 修改保存并关闭按钮,Final时显示
                                <apex:commandButton value="保存并关闭" disabled="{!editFlag}"  rendered="{!IF(((repa != null && !((repa.Repair_Determine__c = '要' && isOSH)||repa.Repair_Determine__c != '要')) || (RecordTypeName = 'ASACDecision')),true,false)}" style="margin-left:30px;width:80px;float:right"  onclick="SaveAndCloses(2);return false;"  rerender="unEditable,message" oncomplete="unblockUI();" /> -->
                                    <apex:commandbutton disabled="{!editFlag}" onclick="SaveAndCloses(2);return false;" oncomplete="unblockUI();" rendered="{!IF(repa != null && RecordTypeName = 'ASACDecision',true,false)}" rerender="unEditable,message" style="margin-left:30px;width:80px;float:right" value="保存并关闭">
                                    </apex:commandbutton>
                                    <!-- When 要不要进行修理的判定=要 -->
                                    <!-- OSH screen:[确定并SAP申请]  -->
                                    <!-- OCSM QARA screen  [确定并关闭] -->
                                    <!-- update by rentx 2020-10-26 start -->
                                    <!-- <apex:commandButton rendered="{!IF(((repa.Repair_Determine__c = '要' && isOSH)||repa.Repair_Determine__c != '要') && repa != null && RecordTypeName='ASRCDecision',true,false)}" value="确定并SAP申请"  style="margin-left:30px;width:100px;float:right"  onclick="sendToSAPJS(2);return false;"  rerender="unEditable,message" oncomplete="unblockUI();" disabled="{!IF(repa.SAP_Transfer_time__c != null || editFlag,true,false)}" /> -->
                                    <apex:commandbutton disabled="{!IF(repa.SAP_Transfer_time__c != null || editFlag,true,false)}" onclick="sendToSAPJS(2);return false;" oncomplete="unblockUI();" rendered="{!IF(((repa.Repair_Determine__c = '要' && isOSH)||repa.Repair_Determine__c != '要') && repa != null && RecordTypeName='ASRCDecision',true,false)}" rerender="unEditable,message" style="margin-left:30px;width:100px;float:right" value="确定并SAP申请">
                                    </apex:commandbutton>
                                    <apex:commandbutton disabled="{!editFlag}" onclick="SaveAndCloses(2);return false;" oncomplete="unblockUI();" rendered="{!IF((repa.Repair_Determine__c = '要' && OCSM_QARA == '1' && RecordTypeName = 'ASRCDecision' && repa != null) || (RecordTypeName = 'ASRCDecision' && QISReportId != null),true,false)}" rerender="unEditable,message" style="margin-left:30px;width:100px;float:right" value="确定并关闭">
                                    </apex:commandbutton>
                                    <!-- OCSM_QARA : {!OCSM_QARA}
                            OSH : {!isOSH} -->
                                    <!-- update by rentx 2020-10-26 start -->
                                    <!-- <apex:commandButton value="插入行" disabled="{!IF((RecordTypeName='ASRCDecision'&&OCSM_QARA='0')||(RecordTypeName='ASACDecision'&&OCSM_Cording='0')||(editFlag) || (RecordTypeName='ASRCDecision' && repa.SAP_Transfer_time__c != null),true,false)}" style="margin-left:30px;width:60px;float:right" onclick="InsertRows();return false;" rerender="unEditable,message" oncomplete="unblockUI();"/>
                            <apex:commandButton value="取消行" disabled="{!IF((RecordTypeName='ASRCDecision'&&OCSM_QARA='0')||(RecordTypeName='ASACDecision'&&OCSM_Cording='0')||(editFlag) || (RecordTypeName='ASRCDecision' && repa.SAP_Transfer_time__c != null),true,false)}" style="margin-left:30px;width:60px;float:right" onclick="SaveAndCloses(3);return false;"  rerender="unEditable,message" oncomplete="unblockUI();"/> -->
                                    <apex:commandbutton disabled="{!IF((RecordTypeName = 'ASRCDecision' && OCSM_QARA = '0') && ((RecordTypeName='ASACDecision'&&OCSM_Cording='0')||(editFlag) && (repa.ETQ_UPLOAD_ERROR_GROUP__c != 'Intake')),true,false)}" onclick="InsertRows();return false;" oncomplete="unblockUI();" rerender="unEditable,message" style="margin-left:30px;width:60px;float:right" value="插入行">
                                    </apex:commandbutton>
                                    <apex:commandbutton disabled="{!IF((RecordTypeName = 'ASRCDecision' && OCSM_QARA = '0') && ((RecordTypeName='ASACDecision'&&OCSM_Cording='0')||(editFlag) && (repa.ETQ_UPLOAD_ERROR_GROUP__c != 'Intake')),true,false)}" onclick="SaveAndCloses(3);return false;" oncomplete="unblockUI();" rerender="unEditable,message" style="margin-left:30px;width:60px;float:right" value="取消行">
                                    </apex:commandbutton>
                                    <!-- update by rentx 2020-10-26 end -->
                                </td>
                            </tr>
                        </table>
                    </apex:outputpanel>
                    <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision'&& rdRecord.PAE_reappear_confirm__c = '未确认',true , false)}">
                        <p style="text-align: right;padding-bottom: 10px;width:100%;font-weight: 800;">
                            再现结果未确认,请点击Intake universal code 编辑 按钮前去确认
                        </p>
                    </apex:outputpanel>
                    <!-- <tr> -->
                    <apex:outputpanel id="message">
                        <apex:pagemessages >
                        </apex:pagemessages>
                    </apex:outputpanel>
                    <!-- </tr> -->
                    <table border="0" cellpadding="0" cellspacing="0" class="list">
                        <tr class="headerRow">
                            <apex:variable rendered="{!editAble}" value="" var="v">
                                <th>
                                    <input id="checker" onclick="checkAll()" type="checkbox"/>
                                    选择
                                </th>
                            </apex:variable>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' , true, false)}">
                                <th>
                                    Location Group
                                </th>
                                <th>
                                    Location
                                </th>
                                <th>
                                    Final universal description / Phenomenon
                                </th>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                <th>
                                    Intake universal description
                                </th>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                <th>
                                    Intake universal code
                                </th>
                            </apex:outputpanel>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' , true, false)}">
                                <th>
                                    Final universal code
                                </th>
                            </apex:outputpanel>
                            <!-- <th>AS-RC</th> -->
                            <!-- <th width="7%">PAE判定</th> -->
                            <th width="7%">
                                {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAE_Judge__c.label}
                            </th>
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                <!-- <th width="7%">再现結果</th> -->
                                <th width="7%">
                                    {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_Reappear_Result__c.label}
                                </th>
                                <!-- <th width="15%">intake 页面 Final universal Code</th> -->
                                <th width="15%">
                                    {!$ObjectType.PAE_DecisionRecordDetail__c.fields.Final_universal_code__c.label}
                                </th>
                            </apex:outputpanel>
                            <!-- <th width="7%">状态</th> -->
                            <th width="7%">
                                {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_Status__c.label}
                            </th>
                            <!-- <th width="7%">确认日</th> -->
                            <th width="7%">
                                {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_ConfirmationDate__c.label}
                            </th>
                            <!-- <th width="7%">确认者</th> -->
                            <th width="7%">
                                {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_Affirmant__c.label}
                            </th>
                            <!-- <th width="7%">取消日</th> -->
                            <th width="7%">
                                {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_CancellationDate__c.label}
                            </th>
                            <!-- <th width="7%">取消者</th> -->
                            <th width="7%">
                                {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_Nullifier__c.label}
                            </th>
                             <!-- <th width="7%">手动修改</th> -->
                           
                            <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                <!-- <th width="7%">不再現結果確認日</th> -->
                                <th width="7%">
                                    {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_ResultConfirmationDate__c.label}
                                </th>
                                <!-- <th width="7%">不再現結果確認者</th> -->
                                <th width="7%">
                                    {!$ObjectType.PAE_DecisionRecordDetail__c.fields.PAED_ResultAffirmant__c.label}
                                </th>
                               
                            </apex:outputpanel>
                             <th width="7%">
                                {!$ObjectType.PAE_DecisionRecordDetail__c.fields.Monitor_PAE__c.label}
                            </th>
                        </tr>
                        <apex:repeat id="ConsumableorderdetailsTable" value="{!paedRecordDetailView}" var="paedRdV">
                            <tr class="dataRow">
                                <!-- //复选框 -->
                                <apex:variable id="variableinfo" rendered="{!editAble}" value="" var="v">
                                    <td>
                                        <apex:inputcheckbox disabled="{!paedRdV.canSelect}" id="consumablesCountproRowCheckbox" onclick="CheckSize(this);" value="{!paedRdV.check}">
                                        </apex:inputcheckbox>
                                        <apex:inputcheckbox id="proRowOldCheckbox" style="display:none" value="{!paedRdV.oldCheck}">
                                        </apex:inputcheckbox>
                                        <apex:inputcheckbox id="isReadOnly" style="display:none" value="{!paedRdV.canSelect}">
                                        </apex:inputcheckbox>
                                    </td>
                                </apex:variable>
                                <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa != null , true, false)}">
                                    <td class="dataCell">
                                        <apex:outputfield value="{!paedRdV.paedrdd.IntakeUniversalDesc__c}">
                                        </apex:outputfield>
                                    </td>
                                </apex:outputpanel>
                                <!-- QIS read only; always blank-->
                                <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' && repa = null , true, false)}">
                                    <td class="dataCell">
                                    </td>
                                </apex:outputpanel>
                                <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' && repa != null , true, false)}">
                                    <td class="dataCell">
                                        <apex:outputfield value="{!paedRdV.paedrdd.LocationGroup__c}">
                                        </apex:outputfield>
                                    </td>
                                    <td class="dataCell">
                                        <apex:outputfield value="{!paedRdV.paedrdd.Location__c}">
                                        </apex:outputfield>
                                    </td>
                                    <td class="dataCell">
                                        <apex:outputfield value="{!paedRdV.paedrdd.FinalUniversalDesc__c}">
                                        </apex:outputfield>
                                        <br/>
                                        <apex:outputfield value="{!paedRdV.paedrdd.PhenomenonDesc__c}">
                                        </apex:outputfield>
                                    </td>
                                </apex:outputpanel>
                                <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASACDecision' && repa = null, true, false)}">
                                    <td class="dataCell">
                                    </td>
                                    <td class="dataCell">
                                    </td>
                                    <td class="dataCell">
                                    </td>
                                </apex:outputpanel>
                                <td class="dataCell">
                                    <!-- {!paedRdV.paedrdd.PAE_is_save__c}
                                    {!paedRdV.paedrdd.isInterfaceCreate__c} -->
                                    <!-- update by rentx 2020-11-04 如果接口来的数据的Code是空白的话,Coding担当在FinalUniversalCode编辑画面,直接编辑FinalUniversalCode start -->
                                    <!-- <apex:outputPanel layout="none" rendered="{!IF(paedRdV.paedrdd.PAE_is_save__c ='1',false, true)}">
                                        <apex:outputPanel layout="none" rendered="{!IF((RecordTypeName = 'ASACDecision'&& rdRecord.PAE_reappear_confirm__c = '未确认')||(OCSM_QARA='0' &&RecordTypeName = 'ASRCDecision'), false, true)}">
                                        <apex:InputField id="PAEDManagementCode" value="{!paedRdV.paedrdd.PAED_ManagementCode__c}" onblur="InsertMoreRows()"/>
                                        </apex:outputPanel>
                                    </apex:outputPanel>
                                    <apex:outputPanel layout="none" rendered="{!IF(paedRdV.paedrdd.PAE_is_save__c ='1',true , false)}">
                                        <apex:outputField value="{!paedRdV.paedrdd.PAED_ManagementCode__c}" />
                                    </apex:outputPanel> -->
                                    <!-- <apex:outputPanel layout="none" rendered="{!IF(paedRdV.paedrdd.PAE_is_save__c !='1' || (paedRdV.paedrdd.isInterfaceCreate__c= true && paedRdV.paedrdd.PAED_ManagementCode__c = ''), true,false)}">
                                        <apex:outputPanel layout="none" rendered="{!IF((RecordTypeName = 'ASACDecision'&& rdRecord.PAE_reappear_confirm__c = '未确认')||(OCSM_QARA='0' &&RecordTypeName = 'ASRCDecision'), false, true)}">
                                        <apex:InputField id="PAEDManagementCode" value="{!paedRdV.paedrdd.PAED_ManagementCode__c}" onblur="InsertMoreRows()"/>
                                        </apex:outputPanel>
                                    </apex:outputPanel>
                                    <apex:outputPanel layout="none" rendered="{!IF(paedRdV.paedrdd.PAE_is_save__c ='1' || (paedRdV.paedrdd.isInterfaceCreate__c= true && paedRdV.paedrdd.PAED_ManagementCode__c != ''),true , false)}">
                                        <apex:outputField value="{!paedRdV.paedrdd.PAED_ManagementCode__c}" />
                                    </apex:outputPanel> -->
                                    <apex:outputpanel layout="none" rendered="{!IF(paedRdV.paedrdd.PAE_is_save__c !='1' || paedRdV.paedrdd.isedit__c = true, true,false)}">
                                        <!-- <apex:InputField id="PAEDManagementCodetest" value="{!paedRdV.paedrdd.PAED_ManagementCode__c}" onblur="InsertMoreRows()"/> -->
                                        <apex:outputpanel layout="none" rendered="{!IF((RecordTypeName = 'ASACDecision'&& rdRecord.PAE_reappear_confirm__c = '未确认')||(OCSM_QARA='0' &&RecordTypeName = 'ASRCDecision'), false, true)}">
                                            <apex:inputfield id="PAEDManagementCode" onblur="InsertMoreRowsJs(this.value);return false;" value="{!paedRdV.paedrdd.PAED_ManagementCode__c}">
                                            </apex:inputfield>
                                        </apex:outputpanel>
                                    </apex:outputpanel>
                                    <apex:outputpanel layout="none" rendered="{!IF(!(paedRdV.paedrdd.PAE_is_save__c !='1' || paedRdV.paedrdd.isedit__c = true),true , false)}">
                                        <apex:outputfield value="{!paedRdV.paedrdd.PAED_ManagementCode__c}">
                                        </apex:outputfield>
                                    </apex:outputpanel>
                                    <!-- update by rentx 2020-11-04 如果接口来的数据的Code是空白的话,Coding担当在FinalUniversalCode编辑画面,直接编辑FinalUniversalCode end -->
                                </td>
                                <td class="dataCell">
                                    <apex:outputpanel layout="none" rendered="{!IF(paedRdV.paedrdd.PAE_is_save__c ='1',false, true)}">
                                        <apex:outputpanel layout="none" rendered="{!IF((RecordTypeName = 'ASACDecision'&& rdRecord.PAE_reappear_confirm__c = '未确认')||(OCSM_QARA='0'&&RecordTypeName = 'ASRCDecision'), false, true)}">
                                            <!-- '{!paedRdV.strJudgeNum}' -->
                                            <apex:inputfield id="PAEJudge" onchange="checkBoxTf();" value="{!paedRdV.paedrdd.PAE_Judge__c}">
                                            </apex:inputfield>
                                        </apex:outputpanel>
                                    </apex:outputpanel>
                                    <apex:outputpanel layout="none" rendered="{!IF(paedRdV.paedrdd.PAE_is_save__c ='1',true , false)}">
                                        <apex:outputfield id="PAEJudge1" value="{!paedRdV.paedrdd.PAE_Judge__c}">
                                        </apex:outputfield>
                                    </apex:outputpanel>
                                    <!-- // 2021-12-08  zxk   精琢科技  手动赋值逻辑  start -->
 
                                    <apex:inputhidden id="strJudgejs" value="{!paedRdV.strJudge}">
                                    </apex:inputhidden>
                                    <apex:inputhidden id="Monitor_PAE__c" value="{!paedRdV.paedrdd.Monitor_PAE__c}">
                                    </apex:inputhidden>
                                    <apex:inputhidden id="PaeIsSave" value="{!paedRdV.paedrdd.PAE_is_save__c }">
                                    </apex:inputhidden>
                                    <!-- // 2021-12-08  zxk   精琢科技  手动赋值逻辑  end -->
                                </td>
                                <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                    <td class="dataCell">
                                        <!--只能简档OCSM Cording可以编辑-->
                                        <!-- {!paedRdV.paedrdd.PAE_is_save__c} -->
                                        <!-- {!OCSM_Cording} -->
                                        <!-- update by rentx 2020-11-04 start -->
                                        <!-- <apex:outputPanel layout="none" rendered="{!IF(OCSM_Cording != '1' || paedRdV.paedrdd.isInterfaceCreate__c = true, true, false)}">
                                    <apex:outputField value="{!paedRdV.paedrdd.PAED_Reappear_Result__c}"/>
                                    </apex:outputPanel>
                                    <apex:outputPanel layout="none" rendered="{!IF(OCSM_Cording='1' && paedRdV.paedrdd.isInterfaceCreate__c = false, true, false)}">
                                    <apex:InputField value="{!paedRdV.paedrdd.PAED_Reappear_Result__c}"/>
                                    </apex:outputPanel> -->
                                        <apex:outputpanel layout="none" rendered="{!IF(OCSM_Cording != '1', true, false)}">
                                            <apex:outputfield value="{!paedRdV.paedrdd.PAED_Reappear_Result__c}">
                                            </apex:outputfield>
                                        </apex:outputpanel>
                                        <apex:outputpanel layout="none" rendered="{!IF(OCSM_Cording='1', true, false)}">
                                            <apex:inputfield value="{!paedRdV.paedrdd.PAED_Reappear_Result__c}">
                                            </apex:inputfield>
                                        </apex:outputpanel>
                                        <!-- update by rentx 2020-11-04 end -->
                                    </td>
                                    <td class="dataCell">
                                        <apex:outputfield value="{!paedRdV.paedrdd.Final_universal_code__c}">
                                        </apex:outputfield>
                                    </td>
                                </apex:outputpanel>
                                <td class="dataCell">
                                    <apex:outputfield value="{!paedRdV.paedrdd.PAED_Status__c}">
                                    </apex:outputfield>
                                </td>
                                <td class="dataCell">
                                    <!-- Gzw 20200826 修改 Final 信息没有时,显示修理上内容 -->
                                    <apex:outputfield value="{!paedRdV.paedrdd.PAED_ConfirmationDate_F__c}">
                                    </apex:outputfield>
                                    <!-- Final确认日 -->
                                    <!-- <apex:outputPanel layout="none" rendered="{!IF(repa != null && paedRdV.paedrdd.PAED_ConfirmationDate__c = null, true, false)}">
                                        <apex:OutputField value="{!repa.IISE_confirmed_day__c}"/>
                                    </apex:outputPanel> -->
                                </td>
                                <td class="dataCell">
                                    <apex:outputfield value="{!paedRdV.paedrdd.PAED_Affirmant_F__c}">
                                    </apex:outputfield>
                                    <!-- Final确认者 -->
                                    <!--  <apex:outputPanel layout="none" rendered="{!IF(repa != null && paedRdV.paedrdd.PAED_Affirmant__r.NaMe = null, true, false)}">
                                        <apex:OutputField value="{!repa.IISE_confirmed_person__c}"/>
                                    </apex:outputPanel> -->
                                </td>
                                <td class="dataCell">
                                    <apex:outputfield rendered="{!IF(paedRdV.paedrdd.PAED_CancellationDate__c != null, true, false)}" value="{!paedRdV.paedrdd.PAED_CancellationDate__c}">
                                    </apex:outputfield>
                                    <!-- 取消日 -->
                                    <!-- <apex:outputPanel layout="none" rendered="{!IF(repa != null && paedRdV.paedrdd.PAED_Status__c = '取消' && paedRdV.paedrdd.isInterfaceCreate__c = true, true, false)}">
                                        <apex:OutputField value="{!repa.IISE_confirmed_day__c}"/>
                                    </apex:outputPanel> -->
                                </td>
                                <td class="dataCell">
                                    <apex:outputfield value="{!paedRdV.paedrdd.PAED_Nullifier__r.Name}">
                                    </apex:outputfield>
                                </td>
                                <apex:outputpanel layout="none" rendered="{!IF(RecordTypeName = 'ASRCDecision' , true, false)}">
                                    <td class="dataCell">
                                        <apex:outputfield value="{!paedRdV.paedrdd.PAED_ResultConfirmationDate__c}">
                                        </apex:outputfield>
                                    </td>
                                    <!-- update by rentongxiao 2020-10-10 start -->
                                    <!-- <td class="dataCell">
                                    <apex:OutputField value="{!paedRdV.paedrdd.PAED_ResultAffirmant__r.NaMe}"/>
                                    </td> -->
                                    <td class="dataCell">
                                        <apex:outputfield value="{!paedRdV.paedrdd.PAED_ResultAffirmant_new__c}">
                                        </apex:outputfield>
                                    </td>
                                    <!-- update by rentongxiao 2020-10-10  -->
                                </apex:outputpanel>
                                 <!-- // 2021-12-08  zxk   精琢科技  手动赋值逻辑  start -->
                                <td class="dataCell">
                                    <apex:inputcheckbox id="MonitorPAE" value="{!paedRdV.monitorPAE}" disabled="true">
                                    </apex:inputcheckbox>
                                    <apex:inputhidden id="MonitorPAEhidden" value="{!paedRdV.monitorPAE}">
                                    </apex:inputhidden>
                                </td>
                                <!-- // 2021-12-08  zxk   精琢科技  手动赋值逻辑  end -->
                            </tr>
                        </apex:repeat>
                    </table>
                </apex:pageblock>
            </apex:pageblock>
        </apex:outputpanel>
    </apex:form>
</apex:page>