黄千龙
2023-07-18 428f42fab44b654c69fbc461513203830743d7de
hql20230718更新lightning按钮
18个文件已修改
601 ■■■■ 已修改文件
force-app/main/default/classes/QISReportController.cls 97 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexCreateRepair/lexCreateRepair.js 133 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexOCMSubmit/lexOCMSubmit.js 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexOCSMNoToReportLighting/lexOCSMNoToReportLighting.js 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexOCSMToReportLighting/lexOCSMToReportLighting.js 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexOSHInspect/lexOSHInspect.js 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexOSHRecieved/lexOSHRecieved.js 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexOSHSubmit/lexOSHSubmit.js 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexPDFQISrequest/lexPDFQISrequest.js 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexQISAgree/lexQISAgree.js 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexQISIntakeuniversalcode/lexQISIntakeuniversalcode.js 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexQISSC/lexQISSC.js 55 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexQisUniversalFailureCode/lexQisUniversalFailureCode.js 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexRCCDScomplete/lexRCCDScomplete.js 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexRCRecieved/lexRCRecieved.js 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexRCSubmit/lexRCSubmit.js 33 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexRCinspectioncompletedate/lexRCinspectioncompletedate.js 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/lwc/lexSendQIS/lexSendQIS.js 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/classes/QISReportController.cls
@@ -19,8 +19,8 @@
        
        String recordTypeId = LightingButtonConstant.DEVELOPER_NAME_ASAC_DECISION;
        try{
            PAE_DecisionRecord__c rCPAEDIdList = [SELECT LastModifiedDate, Id, Name, LastModifiedById,RecordType.DeveloperName FROM PAE_DecisionRecord__c where PAE_QIS__c = :qisReportId  And RecordType.DeveloperName =  :recordTypeId limit 1];
            res.pAEid = rCPAEDIdList.id;
            PAE_DecisionRecord__c RCPAEDIdList = [SELECT LastModifiedDate, Id, Name, LastModifiedById,RecordType.DeveloperName FROM PAE_DecisionRecord__c where PAE_QIS__c = :qisReportId  And RecordType.DeveloperName =  :recordTypeId limit 1];
            res.pAEid = RCPAEDIdList.id;
            System.debug(LoggingLevel.INFO, '*** res: ' + res);
        }catch(Exception e){
            System.debug(LoggingLevel.INFO, '*** e: ' + e);
@@ -48,8 +48,8 @@
        
        String recordTypeId = LightingButtonConstant.DEVELOPER_NAME_ASRC_DECISION;
        try{
            PAE_DecisionRecord__c aSRCDIdList = [SELECT LastModifiedDate, Id, Name, LastModifiedById,RecordType.DeveloperName FROM PAE_DecisionRecord__c where PAE_QIS__c = :qisReportId  And RecordType.DeveloperName =  :recordTypeId Limit 1];
            res.pAEid = aSRCDIdList.id;
            PAE_DecisionRecord__c ASRCDIdList = [SELECT LastModifiedDate, Id, Name, LastModifiedById,RecordType.DeveloperName FROM PAE_DecisionRecord__c where PAE_QIS__c = :qisReportId  And RecordType.DeveloperName =  :recordTypeId Limit 1];
            res.pAEid = ASRCDIdList.id;
            System.debug(LoggingLevel.INFO, '*** res: ' + res);
        }catch(Exception e){
            System.debug(LoggingLevel.INFO, '*** e: ' + e);
@@ -528,6 +528,10 @@
    public static InitData initForlexCreateRepairButton (String recordId){
        InitData res = new initData();
        ID myUserID = UserInfo.getUserId();
        List<RecordType> RecordTypeList = [select id,name from RecordType where name = '2.OCSM' or name = '1.FSE' or name = '戦略科室分類 消化科'
                                            or name = '戦略科室分類 消化科' or name = '戦略科室分類 呼吸科' or name = '戦略科室分類ET'
                                            or name = '戦略科室分類 普外科' or name = '戦略科室分類 泌尿科' or name = '戦略科室分類 耳鼻喉科'
                                            or name = '戦略科室分類 婦人科' or name = '戦略科室分類 その他'];
        User userinfo = [SELECT id,RepairSalesPoint_Province_China__c FROM User WHERE Id = :myUserID LIMIT 1];
        QIS_Report__c report = [SELECT  id,Owner.name,FailureQInHospital__c,InformationFrom__c,Delay15Min__c,
                                AfterFailureInformation__c,Set_usage_product__c,BreakORFallOff__c,Opera_Name__c,
@@ -541,7 +545,39 @@
                        Parent.Parent.FSE_GI_Main_Leader__r.Work_Location__c,
                        Parent.Parent.FSE_SP_Main_Leader__r.Work_Location__c FROM Account WHERE id = :report.Hospital_Department__c limit 1];
        try{
            for (RecordType rec :RecordTypeList) {
                if (rec.name == '1.FSE') {
                    res.oneFSE = rec.id.to15();
                }
                if (rec.name == '2.OCSM') {
                    res.twoOCSM = rec.id.to15();
                }
                if (rec.name == '戦略科室分類 消化科') {
                    res.xiaohua = rec.id.to15();
                }
                if (rec.name == '戦略科室分類 呼吸科') {
                    res.huxi = rec.id.to15();
                }
                if (rec.name == '戦略科室分類ET') {
                    res.eT = rec.id.to15();
                }
                if (rec.name == '戦略科室分類 普外科') {
                    res.puwai = rec.id.to15();
                }
                if (rec.name == '戦略科室分類 泌尿科') {
                    res.miniao = rec.id.to15();
                }
                if (rec.name == '戦略科室分類 耳鼻喉科') {
                    res.erbihou = rec.id.to15();
                }
                if (rec.name == '戦略科室分類 婦人科') {
                    res.fuke = rec.id.to15();
                }
                if (rec.name == '戦略科室分類 その他') {
                    res.qita = rec.id.to15();
                }
            
            }
            res.Id = report.Id;
            res.qisRecordTypeId = report.RecordType_ID__c;
            res.oCMjudgement = report.OCM_judgement__c;
@@ -739,9 +775,30 @@
        }
         return re;
    }
     // 新建QIS
    @AuraEnabled
    public static InitData initForlexCreateQISFromAssetButton (String recordId){
        InitData res = new initData();
        ID myUserID = UserInfo.getUserId();
        Asset ass = [SELECT id,AssetMark__c FROM Asset WHERE Id = :recordId LIMIT 1];
        try{
            Date fomatToday = Date.today().addDays(-10);
            QIS_Report__c report = [SELECT id,QIS_Submit_day__c FROM QIS_Report__c WHERE nonyushohin__c=:recordId and QIS_Submit_day__c != null and QIS_Submit_day__c >= :fomatToday];
            Repair__c rep = [SELECT id,Name FROM Repair__c WHERE Delivered_Product__c = :recordId and Status2__c!='00.删除' and Status2__c!='00.取消' and FSE_ApplyForRepair_Day__c >= :fomatToday  order by FSE_ApplyForRepair_Day__c desc limit 1];
            res.Id = report.id;
            res.repId = rep.id;
            System.debug(LoggingLevel.INFO, '*** res: ' + res);
        }catch(Exception e){
            System.debug(LoggingLevel.INFO, '*** e: ' + e);
        }
        return res;
    }
    public class InitData{
        @AuraEnabled
        public String Id;
        @AuraEnabled
        public String repId;
        @AuraEnabled
        public String qISSCReport;
        @AuraEnabled
@@ -769,23 +826,23 @@
        @AuraEnabled
        public String failuerSituation;
        @AuraEnabled
        public String sourceOnCall;
        public ID sourceOnCall;
        @AuraEnabled
        public String sourceOnCallname;
        @AuraEnabled
        public String hospitalId;
        public ID hospitalId;
        @AuraEnabled
        public String hospitalname;
        @AuraEnabled
        public String departmentClassId;
        public ID departmentClassId;
        @AuraEnabled
        public String departmentClassname;
        @AuraEnabled
        public String hospitalDepartment;
        public ID hospitalDepartment;
        @AuraEnabled
        public String hospitalDepartmentname;
        @AuraEnabled
        public String nonyushohinId;
        public ID nonyushohinId;
        @AuraEnabled
        public String nonyushohinIdname;
        @AuraEnabled
@@ -815,7 +872,7 @@
        @AuraEnabled
        public String failureQInHospital;
        @AuraEnabled
        public String ownerId;
        public ID ownerId;
        @AuraEnabled
        public String ownername;
        @AuraEnabled
@@ -853,6 +910,26 @@
        @AuraEnabled
        public String contractnumber;
        @AuraEnabled
        public String oneFSE;
        @AuraEnabled
        public String twoOCSM;
        @AuraEnabled
        public String huxi;
        @AuraEnabled
        public String xiaohua;
        @AuraEnabled
        public String eT;
        @AuraEnabled
        public String puwai;
        @AuraEnabled
        public String miniao;
        @AuraEnabled
        public String erbihou;
        @AuraEnabled
        public String fuke;
        @AuraEnabled
        public String qita;
        @AuraEnabled
        public Date rCinspectionDate;
        @AuraEnabled
        public Date qISReplyDay;
force-app/main/default/lwc/lexCreateRepair/lexCreateRepair.js
@@ -2,9 +2,18 @@
import { CurrentPageReference } from "lightning/navigation";
import { CloseActionScreenEvent } from 'lightning/actions';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import { NavigationMixin } from 'lightning/navigation';
import { encodeDefaultFieldValues } from 'lightning/pageReferenceUtils';
import init  from '@salesforce/apex/QISReportController.initForlexCreateRepairButton';
export default class lexCreateRepair extends LightningElement {
/*
 * @Description: 新建修理
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexCreateRepair extends NavigationMixin(LightningElement) {
    @api recordId;
    IsLoading = true;
    typeflag = false;
@@ -29,11 +38,11 @@
    UseFailProductFinish='';
    failuerSituation='';
    sourceOnCall='';
    hospitalId='';
    departmentClassId='';
    hospitalId1;
    departmentClassId;
    hospitalDepartment='';
    nonyushohinId='';
    ownerId='';
    nonyushohinId;
    ownerId;
    faliourdate='';
    sourceforrepair='';
    repairSalesPointProvinceChina='';
@@ -55,6 +64,16 @@
    hospitalDepartmentname = '';
    nonyushohinIdname = '';
    sourceOnCallname = '';
    oneFSE = '';
    twoOCSM = '';
    huxi = '';
    xiaohua = '';
    eT = '';
    puwai = '';
    miniao = '';
    fuke = '';
    erbihou = '';
    qita = '';
    @wire(CurrentPageReference)
     getStateParameters(currentPageReference) {
@@ -76,8 +95,19 @@
        init({
            recordId: this.recordId
        }).then(result => {
            console.log('init方法返回');
            this.IsLoading = false;
            this.oneFSE = result.oneFSE;
            this.twoOCSM = result.twoOCSM;
            this.qisReportId = result.Id;
            this.huxi = result.huxi;
            this.xiaohua = result.xiaohua;
            this.eT = result.eT;
            this.puwai = result.puwai;
            this.erbihou = result.erbihou;
            this.miniao = result.miniao;
            this.fuke = result.fuke;
            this.qita = result.qita;
            this.oCMjudgement = result.oCMjudgement;
            this.nextaction = result.nextaction;
            this.ownername = result.ownername;
@@ -90,7 +120,7 @@
                this.sourceOnCallname = result.sourceOnCallname;
            }
            this.name = result.name;
            this.hospitalId = result.hospitalId;
            this.hospitalId1 = result.hospitalId;
            this.hospitalname = result.hospitalname;
            this.departmentClassname = result.departmentClassname;
            this.departmentClassId = result.departmentClassId;
@@ -119,17 +149,17 @@
            this.accParentParentFSEGIMainLeaderWorkLocation = result.accParentParentFSEGIMainLeaderWorkLocation;
            this.accParentParentFSESPMainLeader = result.accParentParentFSESPMainLeader;
            this.accParentParentFSESPMainLeaderWorkLocation = result.accParentParentFSESPMainLeaderWorkLocation;
             if (this.qisRecordTypeId != '01210000000RLWc' && this.qisRecordTypeId != '01210000000RLWh') {
            if (this.qisRecordTypeId != this.oneFSE && this.qisRecordTypeId != this.twoOCSM) {
                 this.typeflag = true;
             }
             if (this.accParentId != null) {
                 if (this.accParentRecordTypeId != null) {
                     this.accrecordId = this.accParentRecordTypeId.substring(0,15);
                     if (this.accrecordId == '01210000000QemL' || this.accrecordId == '01210000000QezZ' || this.accrecordId == '01210000000QemQ') {
                    if (this.accrecordId == this.huxi || this.accrecordId == this.xiaohua || this.accrecordId == this.eT) {
                         if (this.accParentParentFSEGIMainLeader != null) {
                             this.WorkLocation = this.accParentParentFSEGIMainLeaderWorkLocation;
                         }
                     }else if(this.accrecordId == '01210000000Qeze' || this.accrecordId == '01210000000Qezj' || this.accrecordId == '01210000000Qezt'|| this.accrecordId == '01210000000Qezo'|| this.accrecordId == '01210000000Qezy'){
                    }else if(this.accrecordId == this.erbihou || this.accrecordId == this.qita || this.accrecordId == this.fuke|| this.accrecordId == this.puwai || this.accrecordId == this.miniao){
                         if (this.accParentParentFSESPMainLeader != null) {
                             this.WorkLocation = this.accParentParentFSESPMainLeaderWorkLocation;
                         }
@@ -162,48 +192,51 @@
                 if ('使用前准备' == this.failuerSituation) {
                     this.failuerSituation = '使用前准备-患者未麻醉';
                 }
                 var url = '';
                     url = "/a0J/e?" +
                        "CF00N10000002FIJU_lkid="+this.sourceOnCall+"&" +
                        "CF00N10000002FIJU="+this.sourceOnCallname+"&" +
                        "CF00N10000002FIJZ_lkid="+this.qisReportId+"&" +
                        "CF00N10000002FIJZ="+this.name+"&" +
                        "CF00N10000002Dx66_lkid="+this.hospitalId+"&" +
                        "CF00N10000002Dx66="+this.hospitalname+"&" +
                        "CF00N10000002Dx5t_lkid="+this.departmentClassId+"&" +
                        "CF00N10000002Dx5t="+this.departmentClassname+"&" +
                        "CF00N10000002Dx5n_lkid="+this.hospitalDepartment+"&" +
                        "CF00N10000002Dx5n="+this.hospitalDepartmentname+"&" +
                        "CF00N10000002Dx1X_lkid="+this.nonyushohinId+"&" +
                        "CF00N10000002Dx1X="+this.nonyushohinIdname+"&" +
                        "CF00N10000002EMHw_lkid="+this.ownerId+"&" +
                        "CF00N10000002EMHw="+this.ownername+"&" +
                        "00N10000002Dx5y="+this.faliourdate+"&" +
                        "00N10000002Dx6I="+this.comment+"&" +
                        "00N10000002FH86="+this.sourceforrepair+"&" +
                        "00N10000006P6Rn="+this.repairSalesPointProvinceChina+"&" +
                        "00N10000008rsVQ="+this.trableoccurdaYcollect+"&" +
                        "00N10000008rsW7="+this.damageForDocOrPat+"&"+
                        "00N10000008rsVw="+this.relationWithTheProblem+"&"+
                        "00N10000008rsW2="+this.reportForGoz+"&"+
                        "00N10000008rsW6="+this.whichProject+"&"+
                        "00N10000008rsVk="+this.operaName+"&" +
                        "00N10000008rsVN="+this.breakORFallOff+"&"+
                        "00N10000008rsW4="+this.setusageproduct+"&" +
                        "00N10000008rsVL="+this.afterFailureInformation+"&" +
                        "00N10000008rsVR="+this.delay15Min+"&"+
                        "00N10000008rsVZ="+this.informationFrom+"&"+
                        "00N10000008rsVT="+this.failureQInHospital+"&" +
                        "00N10000008rsVv="+this.failuerSituation+"&"+
                        "00N10000008rsW5="+this.UseFailProductFinish+ "&" +
                        "00N10000006P6SM="+this.WorkLocation+ "&" +
                        "retURL=%2F"+this.qisReportId;
                        window.open(url, "_blank");
                const defaultFieldValues =encodeDefaultFieldValues({
                                  On_Call_ID__c: this.sourceOnCall,
                                  QIS_ID__c: this.qisReportId,
                                  Hospital__c: this.hospitalId1,
                                  Department_Class__c: this.departmentClassId,
                                  Account__c:this.hospitalDepartment,
                                  Delivered_Product__c:this.nonyushohinId,
                                  Incharge_Staff__c:this.ownerId,
                                  Failure_Occurrence_Date__c:this.faliourdate,
                                  Repair_Detail__c:this.comment,
                                  Repair_Source__c:this.sourceforrepair,
                                  DateReceiptQuestions__c:this.trableoccurdaYcollect,
                                  ifDeadHurt__c:this.damageForDocOrPat,
                                  ProductFailureRelated__c:this.relationWithTheProblem,
                                  ReportAdverseEvents__c:this.reportForGoz,
                                  WhatProject__c:this.whichProject,
                                  OperationOrExaminationName__c:this.operaName,
                                  BreakORFallOff__c:this.breakORFallOff,
                                  SupportingProducts__c:this.setusageproduct,
                                  Delay15Min__c:this.delay15Min,
                                  AfterFailureInformation__c:this.afterFailureInformation,
                                  InformationFrom__c:this.informationFrom,
                                  FailureQInHospital__c:this.failureQInHospital,
                                  ProblemOccurred__c:this.failuerSituation,
                                  UseFailProductFinish__c:this.UseFailProductFinish,
                                  SalesOfficeCode_selection__c:this.WorkLocation
                                });
                        this[NavigationMixin.Navigate]({
                          type: 'standard__objectPage',
                          attributes: {
                            objectApiName: 'Repair__c',
                            actionName: 'new'
                          },
                          state: {
                            nooverride: '1',
                            defaultFieldValues: defaultFieldValues
                          }
                        });
                        this.dispatchEvent(new CloseActionScreenEvent());
             }else{
                 const evt = new ShowToastEvent({
                        title : '该QIS不能新建修理',
                        message: '',
                        title : '',
                        message: '该QIS不能新建修理',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -213,8 +246,8 @@
        }).catch(error => {
            
            const evt = new ShowToastEvent({
                        title : '发生错误',
                        message: '',
                        title : '',
                        message: '发生错误',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
force-app/main/default/lwc/lexOCMSubmit/lexOCMSubmit.js
@@ -5,7 +5,14 @@
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForOCMSubmitButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisWithOCM';
import { updateRecord } from 'lightning/uiRecordApi';
/*
 * @Description: 提交
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexOCMSubmit extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -43,8 +50,8 @@
            this.isaohuiproduct = result.isaohuiproduct;
             if (this.qisStatus!='草案中' && this.qisStatus!='取消') {
                 const evt = new ShowToastEvent({
                        title : '已经提交',
                        message: '',
                        title : '',
                        message: '已经提交',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -53,8 +60,8 @@
             }else{
                 if (this.qisStatus == '取消') {
                     const evt = new ShowToastEvent({
                        title : '取消后的QIS不允许再提交,如果需要提交请点击\"复制\"按钮重新生成一个QIS',
                        message: '',
                        title : '',
                        message: '取消后的QIS不允许再提交,如果需要提交请点击\"复制\"按钮重新生成一个QIS',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -65,8 +72,8 @@
             
             if (this.QISInstallDate == null) {
                 const evt = new ShowToastEvent({
                        title : '【购买日期/安装日期】为空时不能提交申请',
                        message: '',
                        title : '',
                        message: '【购买日期/安装日期】为空时不能提交申请',
                        variant: 'error'
                    });
                 this.dispatchEvent(evt);
@@ -76,8 +83,8 @@
             if (this.contractnumber == null) {
                 const evt = new ShowToastEvent({
                        title : '【销售合同上订单号码】为空时不能提交申请',
                        message: '',
                        title : '',
                        message: '【销售合同上订单号码】为空时不能提交申请',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -113,13 +120,15 @@
                    if (result!='成功') {
                        this.err = result;
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
                        console.log('error='+error);
                }).finally(() => {
force-app/main/default/lwc/lexOCSMNoToReportLighting/lexOCSMNoToReportLighting.js
@@ -3,9 +3,17 @@
import { CloseActionScreenEvent } from 'lightning/actions';
import LightningConfirm from 'lightning/confirm';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import { updateRecord } from 'lightning/uiRecordApi';
import init  from '@salesforce/apex/QISReportController.initForlexOCSMNoToReportLightingButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisForlexOCSMNoToReportLighting';
/*
 * @Description: OCSM不要报告
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexOCSMNoToReportLighting extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -48,8 +56,8 @@
                    if(res) {
                        if (this.OCSMAdministrativeReportDate != null || this.OCSMAdministrativeReportNumber != null) {
                            const evt = new ShowToastEvent({
                                    title : '已经报告的QIS,不可以点击OCSM不要报告',
                                    message: '',
                                    title : '',
                                    message: '已经报告的QIS,不可以点击OCSM不要报告',
                                    variant: 'error'
                                });
                                this.dispatchEvent(evt);
@@ -60,8 +68,8 @@
                            this.updateQisSubmit();
                        }else{
                            const evt = new ShowToastEvent({
                                    title : '没有AwareDate或已经OCSM行政报告,请确认',
                                    message: '',
                                    title : '',
                                    message: '没有AwareDate或已经OCSM行政报告,请确认',
                                    variant: 'error'
                                });
                                this.dispatchEvent(evt);
@@ -88,13 +96,15 @@
                     this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
            console.log('error='+error);
        }).finally(() => {
force-app/main/default/lwc/lexOCSMToReportLighting/lexOCSMToReportLighting.js
@@ -2,10 +2,17 @@
import { CurrentPageReference } from "lightning/navigation";
import { CloseActionScreenEvent } from 'lightning/actions';
import LightningConfirm from 'lightning/confirm';
import { updateRecord } from 'lightning/uiRecordApi';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForlexOCSMToReportLightingButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisForlexOCSMToReportLighting';
/*
 * @Description: OCSM要报告
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexOCSMToReportLighting extends LightningElement {
    @api recordId;
    str;
@@ -46,8 +53,8 @@
                            this.updateQisSubmit();
                        }else{
                            const evt = new ShowToastEvent({
                                    title : '没有AwareDate或已经OCSM行政报告,请确认',
                                    message: '',
                                    title : '',
                                    message: '没有AwareDate或已经OCSM行政报告,请确认',
                                    variant: 'error'
                                });
                                this.dispatchEvent(evt);
@@ -74,13 +81,15 @@
                     this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
            console.log('error='+error);
        }).finally(() => {
force-app/main/default/lwc/lexOSHInspect/lexOSHInspect.js
@@ -3,8 +3,16 @@
import { CloseActionScreenEvent } from 'lightning/actions';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForlexOSHInspectButton';
import { updateRecord } from 'lightning/uiRecordApi';
import updateQis  from '@salesforce/apex/QISReportController.updateQisForlexOSHInspect';
/*
 * @Description: OSH检查受理
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexOSHInspect extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -39,8 +47,8 @@
            this.oSHInspectionDate = result.oSHInspectionDate;
             if (this.qisStatus!='OSH检测中') {
                 const evt = new ShowToastEvent({
                            title : '需要先点击[OSH现品收到]',
                            message: '',
                            title : '',
                            message: '需要先点击[OSH现品收到]',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -48,8 +56,8 @@
                        return;
             }else if(this.oSHInspectionDate != null){
                 const evt = new ShowToastEvent({
                            title : 'OSH检测已经受理',
                            message: '',
                            title : '',
                            message: 'OSH检测已经受理',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -75,13 +83,15 @@
                    if (result!='成功') {
                        this.err = result;
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
            console.log('error='+error);
        }).finally(() => {
force-app/main/default/lwc/lexOSHRecieved/lexOSHRecieved.js
@@ -4,7 +4,14 @@
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForOSHRecievedButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQis';
import { updateRecord } from 'lightning/uiRecordApi';
/*
 * @Description: OSH现品收到
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexOSHRecieved extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -36,8 +43,8 @@
            console.log('this.qisStatus='+this.qisStatus);
             if (this.qisStatus!='OSH检测申请' && this.qisStatus!='完毕') {
                const evt = new ShowToastEvent({
                        title : 'OSH已经收到实物',
                        message: '',
                        title : '',
                        message: 'OSH已经收到实物',
                        variant: 'error'
                    });
                this.dispatchEvent(evt);
@@ -60,13 +67,15 @@
                    console.log('result'+result);
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: result,
                            title : '',
                            message: '更新失败'+result,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
            console.log('error='+error);
        }).finally(() => {
force-app/main/default/lwc/lexOSHSubmit/lexOSHSubmit.js
@@ -5,6 +5,14 @@
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForOSHSubmitButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQis1';
import { updateRecord } from 'lightning/uiRecordApi';
/*
 * @Description: 提交待审批1
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexOSHSubmit extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -44,8 +52,8 @@
            console.log('this.OSHstaffEmail='+this.OSHstaffEmail);
             if (this.qisStatus=='OSH检测申请' || this.qisStatus=='完毕') {
                const evt = new ShowToastEvent({
                            title : '需要先点击[OSH检查受理]',
                            message: '',
                            title : '',
                            message: '需要先点击[OSH检查受理]',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -54,8 +62,8 @@
             }
             if (this.qisStatus!='OSH检测中') {
                const evt = new ShowToastEvent({
                            title : '已经提交审批',
                            message: '',
                            title : '',
                            message: '已经提交审批',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -71,8 +79,8 @@
                if(res) {
                    if (this.OSHstaff==null||this.OSHstaffEmail==null) {
                        const evt = new ShowToastEvent({
                                    title : 'OSH担当必须填写',
                                    message: '',
                                    title : '',
                                    message: 'OSH担当必须填写',
                                    variant: 'error'
                                });
                                this.dispatchEvent(evt);
@@ -84,8 +92,8 @@
                        }catch(err){
                            if(err.faultstring !=undefined && err.faultstring.indexOf('INVALID_SESSION_ID') != -1) {
                                const evt = new ShowToastEvent({
                                        title : '当前网页已登出,请您重新登录后刷新该网页!',
                                        message: '',
                                        title : '',
                                        message: '当前网页已登出,请您重新登录后刷新该网页!',
                                        variant: 'error'
                                    });
                                    this.dispatchEvent(evt);
@@ -124,13 +132,16 @@
                    if (result!='成功') {
                        this.err = result;
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                 updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
            console.log('error='+error);
        }).finally(() => {
force-app/main/default/lwc/lexPDFQISrequest/lexPDFQISrequest.js
@@ -3,6 +3,13 @@
import { CloseActionScreenEvent } from 'lightning/actions';
import init  from '@salesforce/apex/QISReportController.initForlexPDFQISrequestButton';
/*
 * @Description: PDF(QIS申请书)
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexPDFQISrequest extends LightningElement {
    @api recordId;
    IsLoading = true;
force-app/main/default/lwc/lexQISAgree/lexQISAgree.js
@@ -5,7 +5,14 @@
import init  from '@salesforce/apex/QISReportController.initForQisAgreeButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisForQisAgree';
import USER_ID from '@salesforce/user/Id';
import { updateRecord } from 'lightning/uiRecordApi';
/*
 * @Description: QIS结果跟进完毕
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexQISAgree extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -39,8 +46,8 @@
            this.OwnerId = result.ownerId;
            if (this.OwnerId != this.userId) {
                const evt = new ShowToastEvent({
                            title : '只有所有者可以按QIS结果跟进完毕的按钮',
                            message: '',
                            title : '',
                            message: '只有所有者可以按QIS结果跟进完毕的按钮',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -63,13 +70,15 @@
                     this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
            console.log('error='+error);
        }).finally(() => {
force-app/main/default/lwc/lexQISIntakeuniversalcode/lexQISIntakeuniversalcode.js
@@ -2,7 +2,13 @@
import { CurrentPageReference } from "lightning/navigation";
import init  from '@salesforce/apex/QISReportController.initForlexQISIntakeuniversalcodeButton';
import sqlForPAE  from '@salesforce/apex/QISReportController.sqlForPAE1';
/*
 * @Description: Intake universal code编辑
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexQISIntakeuniversalcode extends LightningElement {
    @api recordId;
    IsLoading = true;
force-app/main/default/lwc/lexQISSC/lexQISSC.js
@@ -2,13 +2,22 @@
import { CurrentPageReference } from "lightning/navigation";
import { CloseActionScreenEvent } from 'lightning/actions';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import { NavigationMixin } from 'lightning/navigation';
import { encodeDefaultFieldValues } from 'lightning/pageReferenceUtils';
import init  from '@salesforce/apex/QISReportController.initForlexQISSCButton';
export default class lexQISSC extends LightningElement {
/*
 * @Description: QIS市场部意见
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexQISSC  extends NavigationMixin(LightningElement) {
    @api recordId;
    IsLoading = true;
    qisReportId;
    name;
    name1;
    profileName;
    qISSCId;
    qISSCReport;
@@ -38,21 +47,18 @@
        }).then(result => {
            this.IsLoading = false;
            this.qisReportId = result.Id;
            this.name = result.name;
            this.name1 = result.name;
            this.qISSCId = result.qISSCId;
            this.qISSCReport = result.qISSCReport;
            this.nextaction = result.nextaction;
            this.qISMarketCategory = result.qISMarketCategory;
            this.profileName = result.profileName;
            console.log('profileName='+this.profileName);
            console.log('qISSCReport='+this.qISSCReport);
            console.log('nextaction='+this.nextaction);
            console.log('qISMarketCategory='+this.qISMarketCategory);
            console.log('qISSCId='+this.qISSCId);
            console.log('name1='+this.name1);
           console.log('result.name='+result.name);
            if (this.profileName == '2F4_技术推进部' || this.profileName == '2F4_技术推进部_OSH 非单点') {
                const evt = new ShowToastEvent({
                            title : '您没有新建QIS市场部权限。',
                            message: '',
                            title : '',
                            message: '您没有新建QIS市场部权限。',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -66,19 +72,34 @@
                return;
            }else{
                if (this.nextaction == '送回' && (this.qISMarketCategory == 'ET' || this.qISMarketCategory == 'ENG' || this.qISMarketCategory == 'EndoRapid')) {
                    var urlStr ='/a3w/e?CF00N100000095xFJ='+this.name+
                            '&CF00N100000095xFJ_lkid='+this.qisReportId+
                            '&retURL='+this.qisReportId+
                            '&Name='+this.name;
                        window.open(urlStr);
                    // var urlStr ='/a3w/e?CF00N100000095xFJ='+this.name+
                    //         '&CF00N100000095xFJ_lkid='+this.qisReportId+
                    //         '&retURL='+this.qisReportId+
                    //         '&Name='+this.name;
                    //     window.open(urlStr);
                        const defaultFieldValues =encodeDefaultFieldValues({
                                  Name:this.name1,
                                  QIS_Report__c:this.qisReportId
                                });
                        
                        this[NavigationMixin.Navigate]({
                          type: 'standard__objectPage',
                          attributes: {
                            objectApiName: 'QIS_SC_Report__c',
                            actionName: 'new'
                          },
                          state: {
                            nooverride: '1',
                            defaultFieldValues: defaultFieldValues
                          }
                        });
                        this.dispatchEvent(new CloseActionScreenEvent());
                        return;
                }else{
                    console.log('触发');
                    const evt = new ShowToastEvent({
                            title : '对应方法为返回且对应主机/消耗品为ET 或 ENG 或 EndoRapid 时,才可以新建。',
                            message: '',
                            title : '',
                            message: '对应方法为返回且对应主机/消耗品为ET 或 ENG 或 EndoRapid 时,才可以新建。',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
force-app/main/default/lwc/lexQisUniversalFailureCode/lexQisUniversalFailureCode.js
@@ -2,7 +2,13 @@
import { CurrentPageReference } from 'lightning/navigation';
import init  from '@salesforce/apex/QISReportController.initForQisUniversalFailureCodeButton';
import sqlForPAE  from '@salesforce/apex/QISReportController.sqlForPAE';
/*
 * @Description: Final universal code编辑
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexQisUniversalFailureCode extends LightningElement {
    @api recordId;
    IsLoading = true;
force-app/main/default/lwc/lexRCCDScomplete/lexRCCDScomplete.js
@@ -4,7 +4,15 @@
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForRCCDScompleteButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisForRCCDScomplete';
import { updateRecord } from 'lightning/uiRecordApi';
/*
 * @Description: OCSM服务本部CDS完毕
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexRCCDScomplete extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -39,8 +47,8 @@
            this.QIStatus = result.qIStatus;
            if (this.QIStatus == 'RC检测申请') {
                const evt = new ShowToastEvent({
                            title : '需要先点击[OCM服务本部收到实物]',
                            message: '',
                            title : '',
                            message: '需要先点击[OCM服务本部收到实物]',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -49,8 +57,8 @@
            }
            if (this.cdsdate != null) {
                const evt = new ShowToastEvent({
                            title : 'OCM服务本部CDS已经完毕',
                            message: '',
                            title : '',
                            message: 'OCM服务本部CDS已经完毕',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -72,13 +80,15 @@
                     this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
            console.log('error='+error);
        }).finally(() => {
force-app/main/default/lwc/lexRCRecieved/lexRCRecieved.js
@@ -2,9 +2,16 @@
import { CurrentPageReference } from "lightning/navigation";
import { CloseActionScreenEvent } from 'lightning/actions';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import { updateRecord } from 'lightning/uiRecordApi';
import init  from '@salesforce/apex/QISReportController.initForlexRCRecievedButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisForRCRecieved';
/*
 * @Description: OCSM服务本部收到实物
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexRCRecieved extends LightningElement {
    @api recordId;
    err;
@@ -43,18 +50,18 @@
            console.log('this.qisStatus='+this.qisStatus);   
             if (this.qisStatus!='RC检测申请') {
                const evt = new ShowToastEvent({
                        title : 'OCM服务本部已经收到实物',
                        message: '',
                        title : '',
                        message: 'OCM服务本部已经收到实物',
                        variant: 'error'
                    });
                this.dispatchEvent(evt);
                this.dispatchEvent(new CloseActionScreenEvent());
                return;
             }else{
                 if (this.isAEProfile == null || this.isPAEProfile == null || this.isCNBuy != 'true') {
                if (this.isAEProfile == null ||(this.isPAEProfile == null && this.isCNBuy != 'true')) {
                     const evt = new ShowToastEvent({
                        title : '安全信息未判定,请联系质量法规部',
                        message: '',
                        title : '',
                        message: '安全信息未判定,请联系质量法规部',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -79,13 +86,15 @@
                    this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                this.dispatchEvent(new CloseActionScreenEvent());
                updateRecord({fields: { Id: this.recordId }});
                }).catch(error => {
                            console.log('error='+error);
                }).finally(() => {
force-app/main/default/lwc/lexRCSubmit/lexRCSubmit.js
@@ -5,7 +5,14 @@
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForRCSubmitButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisWithRC';
import { updateRecord } from 'lightning/uiRecordApi';
/*
 * @Description: 提交待审批
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexRCSubmit extends LightningElement {
    @api recordId;
    IsLoading = true;
@@ -61,11 +68,11 @@
                 return;
             }
            console.log('this.RCproblemnotfound='+(this.QISReplyDay!=null  && this.RCproblemnotfound));
             if (this.CancelQISReason!=null) {
            if (this.CancelQISReason==null) {
                 if (this.qisStatus == 'RC检测申请') {
                    const evt = new ShowToastEvent({
                        title : '需要先点击[OCM服务本部收到实物]',
                        message: '',
                        title : '',
                        message: '需要先点击[OCM服务本部收到实物]',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -74,8 +81,8 @@
                 }
                 if (this.Rcid ==null) {
                    const evt = new ShowToastEvent({
                        title : '判定担当必须填写',
                        message: '',
                        title : '',
                        message: '判定担当必须填写',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -84,8 +91,8 @@
                 }
                 if (this.RCinspectionDate == null) {
                    const evt = new ShowToastEvent({
                        title : 'OCM服务本部还没有检测完毕',
                        message: '',
                        title : '',
                        message: 'OCM服务本部还没有检测完毕',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -95,8 +102,8 @@
                 if (this.QISReplyDay!=null  && this.RCproblemnotfound) {
                    const evt = new ShowToastEvent({
                        title : '最终判定时,请取消[故障未发现留下继续观察]并选择[对应方法]',
                        message: '',
                        title : '',
                        message: '最终判定时,请取消[故障未发现留下继续观察]并选择[对应方法]',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -154,12 +161,14 @@
                     this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                    updateRecord({fields: { Id: this.recordId }});
                this.dispatchEvent(new CloseActionScreenEvent());
                }).catch(error => {
            console.log('error='+error);
force-app/main/default/lwc/lexRCinspectioncompletedate/lexRCinspectioncompletedate.js
@@ -2,9 +2,17 @@
import { CurrentPageReference } from "lightning/navigation";
import { CloseActionScreenEvent } from 'lightning/actions';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import { updateRecord } from 'lightning/uiRecordApi';
import init  from '@salesforce/apex/QISReportController.initForlexRCinspectioncompletedateButton';
import updateQis  from '@salesforce/apex/QISReportController.updateQisForRCinspectioncompletedate';
/*
 * @Description: OCSM服务本部检测完毕
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexRCinspectioncompletedate extends LightningElement {
    @api recordId;
    err;
@@ -40,8 +48,8 @@
             if (this.qisStatus =='RC检测申请') {
                const evt = new ShowToastEvent({
                        title : '需要先点击[OCM服务本部收到实物]',
                        message: '',
                        title : '',
                        message: '需要先点击[OCM服务本部收到实物]',
                        variant: 'error'
                    });
                this.dispatchEvent(evt);
@@ -49,8 +57,8 @@
                return;
             }else if(this.rCinspectionDate != null){
                     const evt = new ShowToastEvent({
                        title : 'OCM服务本部检测已经完毕',
                        message: '',
                        title : '',
                        message: 'OCM服务本部检测已经完毕',
                        variant: 'error'
                    });
                    this.dispatchEvent(evt);
@@ -74,12 +82,14 @@
                    this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
                        updateRecord({fields: { Id: this.recordId }});
                    }
                updateRecord({fields: { Id: this.recordId }});
                this.dispatchEvent(new CloseActionScreenEvent());
                }).catch(error => {
                            console.log('error='+error);
force-app/main/default/lwc/lexSendQIS/lexSendQIS.js
@@ -4,7 +4,13 @@
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
import init  from '@salesforce/apex/QISReportController.initForlexSendQISButton';
import sendSPO  from '@salesforce/apex/QISReportController.updateQisForSendQIS';
/*
 * @Description: 发送QIS到SPO
 * @Author: hql
 * @Date: 2023-07-12 09:45:19
 * @LastEditTime: 2023-07-12 15:44:33
 * @LastEditors:
 */
export default class lexSendQIS extends LightningElement {
    @api recordId;
    str;
@@ -40,8 +46,8 @@
                this.IsSendQIS = result.isSendQIS;
                if (this.qisRecordName == '2.OCSM') {
                    const evt = new ShowToastEvent({
                            title : '不能提交到SPO',
                            message: '记录类型为'+this.qisRecordName,
                            title : '',
                            message: '不能提交到SPO记录类型为'+this.qisRecordName,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -51,8 +57,8 @@
                if (!(this.ProfileName == '系统管理员' || this.ProfileName == '2F4_技术推进部' || this.ProfileName == '2F1_服务窗口')) {
                    const evt = new ShowToastEvent({
                            title : '没有权限提交,请联系系统管理员',
                            message: '',
                            title : '',
                            message: '没有权限提交,请联系系统管理员',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -62,8 +68,8 @@
                if (this.IsSendQIS) {
                    const evt = new ShowToastEvent({
                            title : '已提交到SPO,请不要重复提交',
                            message: '',
                            title : '',
                            message: '已提交到SPO,请不要重复提交',
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -85,8 +91,8 @@
                     this.err = result;
                    if (result!='成功') {
                        const evt = new ShowToastEvent({
                            title : '更新失败',
                            message: this.err,
                            title : '',
                            message: '更新失败'+this.err,
                            variant: 'error'
                        });
                        this.dispatchEvent(evt);
@@ -94,8 +100,8 @@
                        return;
                    }else{
                        const evt = new ShowToastEvent({
                            title : '提交成功!请在SPO系统中完成退换货申请',
                            message: '',
                            title : '',
                            message: '提交成功!请在SPO系统中完成退换货申请',
                            variant: 'success'
                        });
                        this.dispatchEvent(evt);