From 1b8c8764c39fc546ca1b85ff1810ae51be74331c Mon Sep 17 00:00:00 2001
From: Li Jun <buli@deloitte.com.cn>
Date: 星期四, 31 三月 2022 18:39:23 +0800
Subject: [PATCH] PIPL0331V2Deploy
---
force-app/main/default/pages/NewAndEditAgencyContact.page | 40 ++++++++++++++++++++++++++++++----------
1 files changed, 30 insertions(+), 10 deletions(-)
diff --git a/force-app/main/default/pages/NewAndEditAgencyContact.page b/force-app/main/default/pages/NewAndEditAgencyContact.page
index 2007b25..346569a 100644
--- a/force-app/main/default/pages/NewAndEditAgencyContact.page
+++ b/force-app/main/default/pages/NewAndEditAgencyContact.page
@@ -305,14 +305,15 @@
//1. Get Sobject Information from Form
let sobjJson = getSobjectInformation();
//2. Validate the Sobject field value formate, for example the email formate or phone formate
-
- let validationResultMessage = validateFieldValueFormate();
- console.log(validationResultMessage);
- if (validationResultMessage) {
- //Popup error message. - To Do After POC
- alertErrorMessage(validationResultMessage);
- return
- }
+ //updated by Lijun0325 Start
+ //let validationResultMessage = validateFieldValueFormate();
+ //console.log(validationResultMessage);
+ // if (validationResultMessage) {
+ // //Popup error message. - To Do After POC
+ // alertErrorMessage(validationResultMessage);
+ // return
+ // }
+ //updated by Lijun0325 End
// Check Required Field
let checkRequiredFieldMsgResult = checkRequiredFieldMsg(sobjJson);
if (checkRequiredFieldMsgResult) {
@@ -361,7 +362,8 @@
console.log(accountValue);
if(true || accountValue !='000000000000000'){
let baseUrl = "/apex/SearchContactPage";
- let suffixUrl = "?contactId="+contactNodeId+"&accountId="+accountValue;
+ let searchContactKeyWord = document.querySelector("[data-id='Contact__c']").value;
+ let suffixUrl = "?contactId="+contactNodeId+"&accountId="+accountValue+"&searchContactKeyWord=" + searchContactKeyWord;
let newSearchContactParam = 'height=600,width=800,left=100,top=100,dialogHide=true,resizable=no,scrollbars=yes,toolbar=no,status=no';
newSearchContactWindow = window.open(baseUrl+suffixUrl, 'Popup', newSearchContactParam);
if (window.focus) {
@@ -502,6 +504,7 @@
}
jQuery('a[data-id="OwnerId"]').remove();
+ /*
jQuery(".lookupInput").each(function(i,e){
let je =jQuery(e).find('input');
je.attr("readonly","");
@@ -530,7 +533,24 @@
hidden.value = '';
}
}
- });
+ });*/
+ let previous_value = {};
+ jQuery(".lookupInput input").each(function(i,e){
+ let je =jQuery(e);
+
+ let dataid = je.attr('data-id');
+ if(['Contact__c'].indexOf(dataid) < 0) return;
+
+ jQuery(e).focus(function(){
+ previous_value[this.id] = this.value;
+ })
+
+ jQuery(e).change(function(){
+ if (previous_value[this.id] != jQuery(this).val()) {
+ document.getElementById(this.id+'_lkid').value = '';
+ }
+ })
+ })
var layoutSections = JSON.parse('{!layoutSectionsStr}');
for (let m = 0; m < layoutSections.length; m++) {
--
Gitblit v1.9.1