| | |
| | | |
| | | //payloadJson.AWS_Data_Id__c = r.object[0].dataId; |
| | | payloadJson.AWS_Data_Id__c = '{!AWSDataId}'; |
| | | if (isNewMode) { |
| | | if (isNewMode || {!isCloneMode}) { |
| | | payloadJson.AWS_Data_Id__c = r.object[0].dataId; |
| | | } else { |
| | | payloadJson.AWS_Data_Id__c = '{!AWSDataId}'; |
| | |
| | | var VLookUpFields = {! VLookUpFieldsJson}; |
| | | function ProcessPI(sobjJson, payloadForNewPI) { |
| | | blockme(); |
| | | if ({!isNewMode}) { |
| | | if ({!isNewMode} || {!isCloneMode}) { |
| | | NewPIToAWS(sobjJson, payloadForNewPI) |
| | | }else { |
| | | UpdatePIToAWS(sobjJson, payloadForNewPI) |
| | |
| | | |
| | | function alertErrorMessage(errorMsg) { |
| | | let errorMsgNode = document.getElementById("page:form:block:msgContent"); |
| | | errorMsg = '错误:无效数据。' + '\n' + errorMsg; |
| | | errorMsgNode.innerText = errorMsg; |
| | | errorMsgNode.className = 'pbError'; |
| | | } |
| | |
| | | <div class="ptBody"> |
| | | <div class="content"> |
| | | <img src="/img/s.gif" alt="{! SobjectLabel}" class="pageTitleIcon" title="{! SobjectLabel}" /> |
| | | <h1 class="pageType">{! SobjectLabel}<apex:outputText rendered="{!isNewMode}">{!$Label.New}</apex:outputText><apex:outputText rendered="{!not(isNewMode)}">{!$Label.Edit}</apex:outputText> |
| | | <h1 class="pageType">{! SobjectLabel}<apex:outputText rendered="{!isNewMode || isCloneMode}">{!$Label.New}</apex:outputText><apex:outputText rendered="{!not(isNewMode || isCloneMode)}">{!$Label.Edit}</apex:outputText> |
| | | <span class="titleSeparatingColon">:</span> |
| | | </h1> |
| | | <h2 class="pageDescription"> <apex:outputText rendered="{!isNewMode}">{!$Label.New}</apex:outputText><apex:outputText rendered="{!not(isNewMode)}">{!$Label.Edit}</apex:outputText>{! SobjectLabel}</h2> |
| | | <h2 class="pageDescription"> <apex:outputText rendered="{!isNewMode || isCloneMode}">{!$Label.New}</apex:outputText><apex:outputText rendered="{!not(isNewMode || isCloneMode)}">{!$Label.Edit}</apex:outputText>{! SobjectLabel}</h2> |
| | | <div class="blank"> </div> |
| | | </div> |
| | | <div class="links"> |
| | |
| | | <tr> |
| | | <td class="pbTitle"> |
| | | <img src="/img/s.gif" alt="" class="minWidth" title="" width="1" height="1" /> |
| | | <h2 class="mainTitle">{! SobjectLabel}<apex:outputText rendered="{!isNewMode}">{!$Label.New}</apex:outputText><apex:outputText rendered="{!not(isNewMode)}">{!$Label.Edit}</apex:outputText></h2> |
| | | <h2 class="mainTitle">{! SobjectLabel}<apex:outputText rendered="{!isNewMode || isCloneMode}">{!$Label.New}</apex:outputText><apex:outputText rendered="{!not(isNewMode || isCloneMode)}">{!$Label.Edit}</apex:outputText></h2> |
| | | </td> |
| | | <td class="pbButton" id="topButtonRow"> |
| | | <input class="btn" type="Button" value="{!$Label.Save}" onclick="saveSobjectProcess()" /> |
| | |
| | | } |
| | | } |
| | | jQuery('a[data-id="OwnerId"]').remove(); |
| | | |
| | | /* |
| | | jQuery(".lookupInput").each(function(i,e){ |
| | | let je =jQuery(e).find('input'); |
| | | je.attr("readonly",""); |
| | | je.css("background","unset"); |
| | | |
| | | let dataid = je.attr('data-id'); |
| | | if(['Hospital_Name__c','Department_Class__c','OwnerId'].indexOf(dataid) > -1) return; |
| | | jQuery(e).children(":last-child").before('<img class="closeIcon" data-id="'+dataid+'" generate="" alt="Clear" src="/s.gif" style="display: inline-block;">'); |
| | | }) |
| | | |
| | | jQuery(".lookupInput").on("mouseenter","img[generate]",function(e){ |
| | | this.className = "closeIconOn"; |
| | | }); |
| | | |
| | | jQuery(".lookupInput").on("mouseleave","img[generate]",function(e){ |
| | | this.className = "closeIcon" |
| | | }); |
| | | |
| | | jQuery(".lookupInput").on("click","img[generate]",function(e){ |
| | | let id = jQuery("input[data-id='"+jQuery(this).attr("data-id")+ "']").attr("id"); |
| | | let input = document.getElementById(id); |
| | | if(input){ |
| | | input.value = ''; |
| | | let hidden = document.getElementById(id+'_lkid'); |
| | | if(hidden){ |
| | | hidden.value = ''; |
| | | } |
| | | } |
| | | });*/ |
| | | |
| | | var layoutSections = JSON.parse('{!layoutSectionsStr}'); |
| | | for (let m = 0; m < layoutSections.length; m++) { |