I want to use CustionJS callback to trigger a data fetching from cloud database with blaze.
something like:
data fetching function:
def data_fetch():
do something
“on_change” on textInput
callback = CustomJS(args=dict(source=source), code=“”"
var f = cb_obj.get(‘value’)
window.alert(data_fetch(f))
source.trigger(‘change’);
“”")
textInput = TextInput(title=“query_parameters”, name=‘id’, value=‘id’, callback=callback)
I have read this article about How to call python function from javascript: http://stackoverflow.com/questions/13175510/call-python-function-from-javascript-code
I am using dev version 0.11
how can I store the python script on tornado server and call the function through URL in javascript ?
or is there better way to call a complex python function from javascript ?

