On the fly duplicate checking

Posted by ByronB on 27-Jan-2015 06:49

Hi guys, was wondering if I could get some direction here. Basically what I would like to do is the following:

1. On Account Quick Create, only display the Account and Website fields with a Search button
2. User either puts in the Account or Website address, I then query the Account object based on either inputted field
3. Display a list of potential matches (table?)
4. If the Account is duplicate then they just click the Account and the Account will be populated in the New Contact form
5. If there are no results or the result from the search is a different account then show the rest of the quick create fields for population.

What's the easiest was to show the results? If the Account already exists and they click the link how do I populate the New Contact form with the clicked Account (existing Account)???

Regards,

Byron

All Replies

Posted by Godfrey Sorita on 27-Jan-2015 09:50

Hi Byron,

I wouldn't recommend this approach as it would consume a lot of time and effort to implement this. It might be easier to modify the process to achieve the same goal.

Below are my comments to your requirements:

1. On Account Quick Create, only display the Account and Website fields with a Search button

Quick create pages does not have search component. Creating one would require a lot of JavaScript and client-side APIs which is not good for performance. 

Perhaps you can either use either the lookup's autocomplete feaure or selector page component in searching account records.

3. Display a list of potential matches (table?)

The selector page component can have a search component which can be configured to filter records.

4. If the Account is duplicate then they just click the Account and the Account will be populated in the New Contact form

When records on the selector page are clicked, they are automatically populated in the parent form. 

5. If there are no results or the result from the search is a different account then show the rest of the quick create fields for population

If you weren't able to find anything on the selector page, just close it and then click the "quick create" button. 

Regards,

Godfrey

Posted by ByronB on 28-Jan-2015 10:27

Thanks Godfrey

Your suggestion is good and can definitely work, however I have a few questions please.

I want to create a clones selector with a detailed search in it, if there are no results can I create a way to Quick Create if no results are found? Would provide the best solution going forward.

Also, I have tried to set the cloned selector with rbf_setViewSelector('contactAccount', 58963); OnLoad of the New page but the default selector keeps coming up. Inspecting the element it is setting the following:

<input style="display: none;" size="20" tabindex="18" id="txtcontactAccount" name="txtcontactAccount" selectorviewid="58963" viewpageid="10867" class="requiredInput" onfocus="new AutoSuggestControl(this, 10845, 10930);" matchfield="name" matchrule="ST" suggtype="rObj" ismultiple="false" autocomplete="off" type="text">

Not sure why my selector is not being used?

Posted by ByronB on 28-Jan-2015 13:05

Hi you can close this we are going with a different direction.

This thread is closed