-- CRM-13037 fix for Navigating among tabs produces wrong popups

----------------------------------------
* CRM-13037:
  http://issues.civicrm.org/jira/browse/CRM-13037

The wrong popup was getting generated because all the tabs had "Add new record" button with class as "action-item" and there was a condition in js as follows:
   cj('.action-item').each(function () {
          cj(this).attr('jshref', cj(this).attr('href'));
          cj(this).attr('href', '#browseValues');
      });
So,  when we navigate from 1 tab to other, suppose from career tab to visa tab, career tab will have both href and jshref as #browseValues as the above condition will be called for all the elements with class "action-item". I restricted it by putting an if condition to check if jshref is already set for the element. If not then run the above condition. Then after fixing this, there was another bug. The lastly loaded ajax form of a tab was getting displayed in dialog box of all the tabs. This was because the profile form with a particular Id is not generated in a dialog until we pass reset=1 in its url path. So, I added that and assigned & added onPopupClose(as onPopupClose value is lost after reset=1 is passed) functionality in its url for proper redirection to the tab.