KKbes
2023-08-07 890eafcf31f5f8d519bb9e6f9c15303be5328e2d
force-app/main/default/lwc/lexCommitNeedApproval/lexCommitNeedApproval.js
@@ -59,6 +59,7 @@
    async commitNeedApproval(){
       var changeFlg=0;
       var NowStatus = this.MeetingDelayApply.status__c;
      if(NowStatus == "草案中" || NowStatus == "驳回"){
         var campaignId = this.MeetingDelayApply.campaign__c; //学会id
@@ -83,7 +84,6 @@
            message: '一旦提交此记录以待批准,根据您的设置您可能不再能够编辑此记录或将他从批准过程中调回。是否继续?',
            variant: 'headerless',
            label: 'this is the aria-label value',
            // setting theme would have no effect
        });
        if(!result){
           return;
@@ -92,16 +92,20 @@
      if(NowStatus == "草案中" || NowStatus == "驳回"){
         await newUpdateMeetingDelayApply({Id : this.recordId })
         .then(result=>{
         }).catch(error=>{
            if(result!='success'){
            const event2 = new ShowToastEvent({
                    message:
                  error.message,
                        result,
                  variant : 'error'
           });
                 changeFlg+=1;
           this.dispatchEvent(event2);
            }
      });
      }
      if(changeFlg!=0){
         return;
      }
      //4. 进程生成器