Sha256: 579826ecc141a5fdd23c942e9230b75e60ecf00be4c2e7163bed833bb9ba572a
Contents?: true
Size: 682 Bytes
Versions: 48
Compression:
Stored size: 682 Bytes
Contents
module Rgviz module JsRenderer def self.render(table, tqx) response_handler = tqx['responseHandler'] req_id = tqx['reqId'] version = tqx['version'] "#{response_handler}({reqId:'#{req_id}',status:'ok',version:'#{version}',table:#{table.to_json}});" end def self.render_error(reason, message, tqx) reason = reason.gsub("'", "\\'") message = message.gsub("'", "\\'") response_handler = tqx['responseHandler'] req_id = tqx['reqId'] version = tqx['version'] "#{response_handler}({reqId:'#{req_id}',status:'error',version:'#{version}',errors:[{reason:'#{reason}', message:'#{message}'}]});" end end end
Version data entries
48 entries across 48 versions & 1 rubygems