anchor.diff:  		var encounterRoleId = document.getElementById("encounterRole").value;
   		var providerId = document.getElementById("providerId_id").value;
   		
  +		<c:if test="${encounter.encounterId != null}">
   		DWREncounterService.addProviderToEncounter(${encounter.encounterId}, encounterRoleId, providerId, function(providerObj) {
   			if(providerObj){
   				addProviderRow(providerObj);
   			}else
   				alert('<spring:message code="Encounter.provider.failedToAddProvider"/>');
   		});
  +		</c:if>
   	}
   	
   	function addProviderRow(providerObj){
  
positive.code: 	<input type="button" value='<spring:message code="general.cancel"/>' onclick="history.go(-1); return; document.location='index.htm?autoJump=false&phrase=<request:parameter name="phrase"/>'">
  	</form>
  </div>
  
  	<br/>
  	<div class="boxHeader">
  		<b><spring:message code="Provider.header"/></b>
  
negative.code: 	function enableSaveButton(formFieldId, id) {
  		if (formFieldId == "patientId")
  			patientBoxFilledIn = true;
  		
  		//TODO: keep track of count of provider rows as they get added/removed to replace the commented lines below
  		//if (formFieldId == "providerId")
  		//	providerBoxFilledIn = true;
  
  		// only enable if both the patient and provider boxes have been entered
  		if (patientBoxFilledIn)
  			document.getElementById("saveEncounterButton").disabled = false;
  	}
  	
  