anchor.diff:              var ret = true;
               if ($("#name").val() === "") {
                   $("#nameerror").html('Please enter a name for concept.');
  +                hideFormProcessing();
                   ret = false;
               } else {
                   $("#nameerror").html('');
               }
               if ($("#pos").val() === "") {
                   $("#poserror").html('Please select a pos.');
  +                hideFormProcessing();
                   ret = false;
               } else {
                   $("#poserror").html('');
               }
               if ($("#selectedList").val() === "") {
                   $("#listerror").html('Please select a concept list.');
  +                hideFormProcessing();
                   ret = false;
               } else {
                   $("#listerror").html('');
               }
               if ($("#selectedTypes").val() === "") {
                   $("#typeerror").html('Please select a concept type.');
  +                hideFormProcessing();
                   ret = false;
               } else {
                   $("#typeerror").html('');
  
positive.code:                                         class="form-control"></td>
                                      <td><input type="button"
                                          id="serviceSearch"
                                          value="search" class="button"
                                          class="btn btn-primary" /> <img
                                          alt="" id="loadingDiv"
                                          width="16px" height="16px"
                                          src="${pageContext.servletContext.contextPath}/resources/img/ajax_process_16x16.gif"
                                          class="none"></td>
                                  </tr>
                              </table>
                          </td>
  
negative.code:     //service 
      $(function() {
          $("#serviceSearch").click(function() {
              getTermDetails();
          });
      });
      
      function getTermDetails() {
  
          var serviceterm = $("#serviceterm").val();
          // Added validation for search term
          if(!serviceterm.trim()) {
              $("#serviceTermError").html('Term cannot be empty.');
              return false;
          } else {
              $("#serviceTermError").html('');
          }
          var serviceid = $("#selectedServiceNameIdMap").val();
          $.ajax({
              type : "GET",
              url : "${pageContext.servletContext.contextPath}/serviceSearch",
              data : {
                  serviceterm : serviceterm,
                  serviceid : serviceid
              },
              success : function(response) {
                  if (response.length > 0 && response != "[]") {
                      var data = jQuery.parseJSON(response);
                      $('#serviceResultTable').dataTable().fnClearTable();
                      $('#serviceResultTable').dataTable().fnAddData(data);
                      $('#showServiceResult').show();
                  } else {
                      $('#serviceResultTable').dataTable().fnClearTable();
                      $('#serviceResultTable').parents('div.dataTables_wrapper').first().hide();
                      $('#showServiceResult').hide();
                      $("#serviceTermError").html('No results found.');
                  }
              },
              error : function(response) {
                  $('#serviceResultTable').dataTable().fnClearTable();
                  $('#serviceResultTable').parents('div.dataTables_wrapper').first().hide();
                  $('#showServiceResult').hide();
                  $("#serviceTermError").html('An error occurred. Please try again later.');
              }
          });
      }
      
      $(function() {
          $("#showServiceResult").click(function() {
              $('#serviceResult').toggle();
  