def _post_data(options=None, xml=None):
 params = {'token': options['token'].strip(), 'cmd': 'submitcheck', 'XMLDATA': xml}
 res = salt.utils.http.query(url=options['url'], method='POST', params=params, data='', decode=True, status=True, header_dict={}, opts=__opts__)
 if (res.get('status', None) == salt.ext.six.moves.http_client.OK):
  if (res.get('dict', None) and isinstance(res['dict'], list)):
   _content = res['dict'][0]
   if _content.get('status', None):
    return True
   else:
    return False
  else:
   log.error('No content returned from Nagios NRDP.')
   return False
 else:
  log.error('Error returned from Nagios NRDP.  Status code: {0}.'.format(res.status_code))
  return False

def _post_data ( options = None , xml = None ) : params = { 'token' : options [ 'token' ] . strip ( ) , 'cmd' : 'submitcheck' , 'XMLDATA' : xml } res = salt . utils . http . query ( url = options [ 'url' ] , method = 'POST' , params = params , data = '' , decode = True , status = True , header_dict = { } , opts = __opts__ ) if ( res . get ( 'status' , None ) == salt . ext . six . moves . http_client . OK ) : if ( res . get ( 'dict' , None ) and isinstance ( res [ 'dict' ] , list ) ) : _content = res [ 'dict' ] [ 0 ] if _content . get ( 'status' , None ) : return True else : return False else : log . error ( 'No content returned from Nagios NRDP.' ) return False else : log . error ( 'Error returned from Nagios NRDP.  Status code: {0}.' . format ( res . status_code ) ) return False
post data to nagios nrdp .