id
stringlengths
34
124
type
stringclasses
4 values
prompt
stringlengths
0
4.95k
response
stringlengths
21
4.89k
source_lang
stringclasses
3 values
target_lang
stringclasses
2 values
repo
stringclasses
75 values
path
stringlengths
10
88
license
stringclasses
1 value
commit
stringlengths
40
40
stars
int64
431
18.7k
source_url
stringlengths
86
176
line_start
int64
1
214
line_end
int64
3
253
gterrono/houston:client/collection_view.coffee:3:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var resubscribe; resubscribe = function() { var subscription_name; // Stop the old subscription and resubscribe with the new filter/sort subscription_name = `_houston_${Houston._session('collection_name')}`; Houston._paginated_subscription.stop(); return...
resubscribe = -> # Stop the old subscription and resubscribe with the new filter/sort subscription_name = "_houston_#{Houston._session('collection_name')}" Houston._paginated_subscription.stop() Houston._paginated_subscription = Meteor.subscribeWithPagination subscription_name, get_sort_by(), get_filt...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
23
30
gterrono/houston:client/collection_view.coffee:3:completion
completion
resubscribe = -> # Stop the old subscription and resubscribe with the new filter/sort subscription_name = "_houston_#{Houston._session('collection_name')}" Houston._paginated_subscription.stop()
Houston._paginated_subscription = Meteor.subscribeWithPagination subscription_name, get_sort_by(), get_filter_query(), Houston._page_length
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
23
30
gterrono/houston:client/collection_view.coffee:5:raw_corpus
raw_corpus
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers custom_selector_error_class: -> if Houston._session("custom_selector_error") then "error" else "" custom_selector_error: -> Houston._session("custom_selector_error") field_filter_disabled: -> if Houston._session("custom_sele...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
34
63
gterrono/houston:client/collection_view.coffee:5:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript collection_count = -> collection_info()?.count Template._houston_collection_view.helpers custom_selector_error_class: -> if Houston._session("custom_selector_error") then "error" else "" custom_selector_error: -> Houston._session("custom_selector_error") f...
var collection_count; collection_count = function() { var ref; return (ref = collection_info()) != null ? ref.count : void 0; }; Template._houston_collection_view.helpers({ custom_selector_error_class: function() { if (Houston._session("custom_selector_error")) { return "error"; } else { ret...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
34
63
gterrono/houston:client/collection_view.coffee:5:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var collection_count; collection_count = function() { var ref; return (ref = collection_info()) != null ? ref.count : void 0; }; Template._houston_collection_view.helpers({ custom_selector_error_class: function() { if (Houston._session("custom_selector_...
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers custom_selector_error_class: -> if Houston._session("custom_selector_error") then "error" else "" custom_selector_error: -> Houston._session("custom_selector_error") field_filter_disabled: -> if Houston._session("custom_sele...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
34
63
gterrono/houston:client/collection_view.coffee:5:completion
completion
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers custom_selector_error_class: -> if Houston._session("custom_selector_error") then "error" else "" custom_selector_error: -> Houston._session("custom_selector_error") field_filter_disabled: -> if Houston._session("custom_sele...
documents = get_current_collection()?.find(get_filter_query(), {sort: get_sort_by()}).fetch() _.map documents, (d) -> d.collection = collection d._id = d._id._str or d._id return d values_in_order: -> fields_in_order = get_collection_view_fields() names_in_order = _.clone fields_in_order...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
34
63
gterrono/houston:client/collection_view.coffee:6:raw_corpus
raw_corpus
Template._houston_collection_view.rendered = -> $win = $(window) $win.scroll -> if $win.scrollTop() + 300 > $(document).height() - $win.height() and Houston._paginated_subscription.limit() < collection_count() Houston._paginated_subscription.loadNextPage()
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
65
70
gterrono/houston:client/collection_view.coffee:6:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript Template._houston_collection_view.rendered = -> $win = $(window) $win.scroll -> if $win.scrollTop() + 300 > $(document).height() - $win.height() and Houston._paginated_subscription.limit() < collection_count() Houston._paginated_subscription...
Template._houston_collection_view.rendered = function() { var $win; $win = $(window); return $win.scroll(function() { if ($win.scrollTop() + 300 > $(document).height() - $win.height() && Houston._paginated_subscription.limit() < collection_count()) { return Houston._paginated_subscription.loadNextPage()...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
65
70
gterrono/houston:client/collection_view.coffee:6:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript Template._houston_collection_view.rendered = function() { var $win; $win = $(window); return $win.scroll(function() { if ($win.scrollTop() + 300 > $(document).height() - $win.height() && Houston._paginated_subscription.limit() < collection_count()) { ...
Template._houston_collection_view.rendered = -> $win = $(window) $win.scroll -> if $win.scrollTop() + 300 > $(document).height() - $win.height() and Houston._paginated_subscription.limit() < collection_count() Houston._paginated_subscription.loadNextPage()
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
65
70
gterrono/houston:client/collection_view.coffee:6:completion
completion
Template._houston_collection_view.rendered = -> $win = $(window) $win.scroll ->
if $win.scrollTop() + 300 > $(document).height() - $win.height() and Houston._paginated_subscription.limit() < collection_count() Houston._paginated_subscription.loadNextPage()
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
65
70
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._ses...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; e.preventDefault(); sort_key = this.name; i...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; ...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
get_current_collection()) update_dict = {} update_dict[field_name] = updated_val Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
if selector_text == "" Houston._session 'custom_selector', null else selector_json = JSON.parse(selector_text) Houston._session 'custom_selector', selector_json Houston._session 'custom_selector_error', null # successful, update, so lose focus on text event.currentTarget....
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
123
168
gterrono/houston:client/collection_view.coffee:9:completion
completion
if selector_text == "" Houston._session 'custom_selector', null else selector_json = JSON.parse(selector_text) Houston._session 'custom_selector', selector_json Houston._session 'custom_selector_error', null # successful, update, so lose focus on text event.currentTarget....
'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() valu...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
a29cf62a9b1ac18439d32ab4f549cf231b09e6d4
802
https://github.com/gterrono/houston/blob/a29cf62a9b1ac18439d32ab4f549cf231b09e6d4/client/collection_view.coffee
123
168
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433
802
https://github.com/gterrono/houston/blob/9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._ses...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; e.preventDefault(); sort_key = this.name; i...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433
802
https://github.com/gterrono/houston/blob/9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; ...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433
802
https://github.com/gterrono/houston/blob/9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
get_current_collection()) update_dict = {} update_dict[field_name] = updated_val Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433
802
https://github.com/gterrono/houston/blob/9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433/client/collection_view.coffee
73
122
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
selector_json = JSON.parse(selector_text) Houston._session 'custom_selector', selector_json Houston._session 'custom_selector_error', null event.currentTarget.blur() catch e Houston._session 'custom_selector_error', e.toString() Houston._session 'custom_selector', null resubscrib...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433
802
https://github.com/gterrono/houston/blob/9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433/client/collection_view.coffee
123
164
gterrono/houston:client/collection_view.coffee:9:completion
completion
selector_json = JSON.parse(selector_text) Houston._session 'custom_selector', selector_json Houston._session 'custom_selector_error', null event.currentTarget.blur() catch e Houston._session 'custom_selector_error', e.toString() Houston._session 'custom_selector', null resubscrib...
$create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() value = Houston._convert_to_correct_type(field.name, field.value, ...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433
802
https://github.com/gterrono/houston/blob/9a8b88f2ba0a400826ec739b6f5ba5cbd2fac433/client/collection_view.coffee
123
164
gterrono/houston:client/collection_view.coffee:2:raw_corpus
raw_corpus
get_filter_query = -> # Make find query using the filter stored in the session. The regexes are # escaped, but $regex is used so it can match anywhere in the string. query = {} fill_query_with_regex = (session_key) -> return unless Houston._session(session_key)? for key, val of Houston._session(session_...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
6
16
gterrono/houston:client/collection_view.coffee:2:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_filter_query = -> # Make find query using the filter stored in the session. The regexes are # escaped, but $regex is used so it can match anywhere in the string. query = {} fill_query_with_regex = (session_key) -> return unless Houston._session(se...
var get_filter_query; get_filter_query = function() { var fill_query_with_regex, query; // Make find query using the filter stored in the session. The regexes are // escaped, but $regex is used so it can match anywhere in the string. query = {}; fill_query_with_regex = function(session_key) { var key, re...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
6
16
gterrono/houston:client/collection_view.coffee:2:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_filter_query; get_filter_query = function() { var fill_query_with_regex, query; // Make find query using the filter stored in the session. The regexes are // escaped, but $regex is used so it can match anywhere in the string. query = {}; fill_que...
get_filter_query = -> # Make find query using the filter stored in the session. The regexes are # escaped, but $regex is used so it can match anywhere in the string. query = {} fill_query_with_regex = (session_key) -> return unless Houston._session(session_key)? for key, val of Houston._session(session_...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
6
16
gterrono/houston:client/collection_view.coffee:2:completion
completion
get_filter_query = -> # Make find query using the filter stored in the session. The regexes are # escaped, but $regex is used so it can match anywhere in the string. query = {} fill_query_with_regex = (session_key) ->
return unless Houston._session(session_key)? for key, val of Houston._session(session_key) # From http://stackoverflow.com/questions/3115150/how-to-escape-regular-expression-special-characters-using-javascript#answer-9310752 query[key] = $regex: val.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&") fill_que...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
6
16
gterrono/houston:client/collection_view.coffee:5:raw_corpus
raw_corpus
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] col_name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" ...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] col_name: -> Houston._session('collection_name') document_id: -> @_id + ...
var collection_count; collection_count = function() { var ref; return (ref = collection_info()) != null ? ref.count : void 0; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_view_fields().s...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var collection_count; collection_count = function() { var ref; return (ref = collection_info()) != null ? ref.count : void 0; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers:...
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] col_name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" ...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:completion
completion
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] col_name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" ...
_.map documents, (d) -> d.collection = collection d._id = d._id._str or d._id return d values_in_order: -> fields_in_order = get_collection_view_fields() names_in_order = _.clone fields_in_order values = (Houston._nested_field_lookup(@, field.name) for field in fields_in_order[1..]) # s...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._ses...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; e.preventDefault(); sort_key = this.name; i...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; ...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
get_current_collection()) update_dict = {} update_dict[field_name] = updated_val Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="tex...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
115
140
gterrono/houston:client/collection_view.coffee:9:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_do...
if (confirm(`Are you sure you want to delete the document with _id ${id}?`)) { Houston._call(`${Houston._session('collection_name')}_delete`, id); } ({ 'click .houston-create-doc': function(e) { var $create_row, doc_iter, field, final_key, i, j, key, keys, len, len1, new_doc, ref, value; e.preventDefault()...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
115
140
gterrono/houston:client/collection_view.coffee:9:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript if (confirm(`Are you sure you want to delete the document with _id ${id}?`)) { Houston._call(`${Houston._session('collection_name')}_delete`, id); } ({ 'click .houston-create-doc': function(e) { var $create_row, doc_iter, field, final_key, i, j, key, keys,...
if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="tex...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
115
140
gterrono/houston:client/collection_view.coffee:9:completion
completion
if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="tex...
get_current_collection()) doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key] doc_iter[final_key] = value field.value = '' Houston._call("#{Houston._session('collection_name')}_insert", new_doc) 'submit form.houston-filter-...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
6bc2f26cf31dfe80de6c30326b92565d56b01aee
802
https://github.com/gterrono/houston/blob/6bc2f26cf31dfe80de6c30326b92565d56b01aee/client/collection_view.coffee
115
140
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
91d8fb0d012edf4f987be454abbca03630d8e5b1
802
https://github.com/gterrono/houston/blob/91d8fb0d012edf4f987be454abbca03630d8e5b1/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._ses...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; e.preventDefault(); sort_key = this.name; i...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
91d8fb0d012edf4f987be454abbca03630d8e5b1
802
https://github.com/gterrono/houston/blob/91d8fb0d012edf4f987be454abbca03630d8e5b1/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { var sort_key; ...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
91d8fb0d012edf4f987be454abbca03630d8e5b1
802
https://github.com/gterrono/houston/blob/91d8fb0d012edf4f987be454abbca03630d8e5b1/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() sort_key = this.name if (Houston._session('sort_key') == sort_key) Houston._session('sort_order', Houston._session('sort_order') * - 1) ...
get_current_collection()) update_dict = {} update_dict[field_name] = updated_val Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
91d8fb0d012edf4f987be454abbca03630d8e5b1
802
https://github.com/gterrono/houston/blob/91d8fb0d012edf4f987be454abbca03630d8e5b1/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() value = Houston._convert_to_correct_type(fie...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
91d8fb0d012edf4f987be454abbca03630d8e5b1
802
https://github.com/gterrono/houston/blob/91d8fb0d012edf4f987be454abbca03630d8e5b1/client/collection_view.coffee
115
136
gterrono/houston:client/collection_view.coffee:9:completion
completion
e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() value = Houston._convert_to_correct_type(fie...
for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key] doc_iter[final_key] = value field.value = '' Houston._call("#{Houston._session('collection_name')}_insert", new_doc) 'submit form.houston-filter-form': (e) -> e.preventDefault()
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
91d8fb0d012edf4f987be454abbca03630d8e5b1
802
https://github.com/gterrono/houston/blob/91d8fb0d012edf4f987be454abbca03630d8e5b1/client/collection_view.coffee
115
136
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
cbbf311aeeb7dbec68c3b47ae058c641936bce63
802
https://github.com/gterrono/houston/blob/cbbf311aeeb7dbec68c3b47ae058c641936bce63/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
updated_val = if typeof old_val == 'object' new constructor(updated_val) else constructor(updated_val) update_dict = {} update_dict[field_name] = updated_val Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-col...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
cbbf311aeeb7dbec68c3b47ae058c641936bce63
802
https://github.com/gterrono/houston/blob/cbbf311aeeb7dbec68c3b47ae058c641936bce63/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) ...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
cbbf311aeeb7dbec68c3b47ae058c641936bce63
802
https://github.com/gterrono/houston/blob/cbbf311aeeb7dbec68c3b47ae058c641936bce63/client/collection_view.coffee
115
137
gterrono/houston:client/collection_view.coffee:9:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten ...
Houston._call(`${Houston._session('collection_name')}_delete`, id)({ 'click .houston-create-doc': function(e) { var $create_row, doc_iter, field, final_key, i, j, key, keys, len, len1, new_doc, ref; e.preventDefault(); $create_row = $('#houston-create-row'); new_doc = {}; ref = $create_row.find('i...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
cbbf311aeeb7dbec68c3b47ae058c641936bce63
802
https://github.com/gterrono/houston/blob/cbbf311aeeb7dbec68c3b47ae058c641936bce63/client/collection_view.coffee
115
137
gterrono/houston:client/collection_view.coffee:9:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript Houston._call(`${Houston._session('collection_name')}_delete`, id)({ 'click .houston-create-doc': function(e) { var $create_row, doc_iter, field, final_key, i, j, key, keys, len, len1, new_doc, ref; e.preventDefault(); $create_row = $('#houston-create...
Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) ...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
cbbf311aeeb7dbec68c3b47ae058c641936bce63
802
https://github.com/gterrono/houston/blob/cbbf311aeeb7dbec68c3b47ae058c641936bce63/client/collection_view.coffee
115
137
gterrono/houston:client/collection_view.coffee:9:completion
completion
Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) ...
doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key] doc_iter[final_key] = field.value field.value = '' Houston._call("#{Houston._session('collection_name')}_insert", new_doc) 'submit form.houston-filter-form': (e) -> e.preven...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
cbbf311aeeb7dbec68c3b47ae058c641936bce63
802
https://github.com/gterrono/houston/blob/cbbf311aeeb7dbec68c3b47ae058c641936bce63/client/collection_view.coffee
115
137
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', H...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefault(); if (Houston._session('sort_key') === this.toS...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefau...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
field_properties = _.find(get_collection_view_fields(), (f) -> f.name == field_name) updated_val = if typeof old_val == 'object' new constructor(updated_val) else constructor(updated_val) update_dict = {} update_dict[field_name] = updated_val Houston._call("#{Houston....
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="tex...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
115
138
gterrono/houston:client/collection_view.coffee:9:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_do...
if (confirm(`Are you sure you want to delete the document with _id ${id}?`)) { Houston._call(`${Houston._session('collection_name')}_delete`, id); } ({ 'click .houston-create-doc': function(e) { var $create_row, doc_iter, field, final_key, i, j, key, keys, len, len1, new_doc, ref; e.preventDefault(); $...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
115
138
gterrono/houston:client/collection_view.coffee:9:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript if (confirm(`Are you sure you want to delete the document with _id ${id}?`)) { Houston._call(`${Houston._session('collection_name')}_delete`, id); } ({ 'click .houston-create-doc': function(e) { var $create_row, doc_iter, field, final_key, i, j, key, keys,...
if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="tex...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
115
138
gterrono/houston:client/collection_view.coffee:9:completion
completion
if confirm("Are you sure you want to delete the document with _id #{id}?") Houston._call("#{Houston._session('collection_name')}_delete", id) 'click .houston-create-doc': (e) -> e.preventDefault() $create_row = $('#houston-create-row') new_doc = {} for field in $create_row.find('input[type="tex...
doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key] doc_iter[final_key] = field.value field.value = '' Houston._call("#{Houston._session('collection_name')}_insert", new_doc) 'submit form.houston-filter-form': (e) -> e.preven...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
610792505b6af1a34d4e0a3f846df923f114d531
802
https://github.com/gterrono/houston/blob/610792505b6af1a34d4e0a3f846df923f114d531/client/collection_view.coffee
115
138
gterrono/houston:client/collection_view.coffee:5:raw_corpus
raw_corpus
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plur...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" ...
var collection_count; collection_count = function() { var ref; return (ref = collection_info()) != null ? ref.count : void 0; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_view_fields().s...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var collection_count; collection_count = function() { var ref; return (ref = collection_info()) != null ? ref.count : void 0; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers:...
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plur...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:completion
completion
collection_count = -> collection_info()?.count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plur...
_.map documents, (d) -> d.collection = collection d._id = d._id._str or d._id return d values_in_order: -> fields_in_order = get_collection_view_fields() names_in_order = _.clone fields_in_order values = (Houston._nested_field_lookup(@, field_name) for field_name in fields_in_order[1..])...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', H...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefault(); if (Houston._session('sort_key') === this.toS...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefau...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if item.value field_selectors[item.name] = item.value Houston._session 'field_selectors',...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key] ...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
115
131
gterrono/houston:client/collection_view.coffee:9:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() doc_iter = new_doc for key in keys doc_iter[key] = {} un...
var doc_iter, field, final_key, i, j, key, keys, len, len1, ref; ref = $create_row.find('input[type="text"]'); for (i = 0, len = ref.length; i < len; i++) { field = ref[i]; // Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.'); final_key = keys.pop(); doc_iter = new_do...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
115
131
gterrono/houston:client/collection_view.coffee:9:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var doc_iter, field, final_key, i, j, key, keys, len, len1, ref; ref = $create_row.find('input[type="text"]'); for (i = 0, len = ref.length; i < len; i++) { field = ref[i]; // Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.sp...
for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key] ...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
115
131
gterrono/houston:client/collection_view.coffee:9:completion
completion
for field in $create_row.find('input[type="text"]') # Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key]
doc_iter = doc_iter[key] doc_iter[final_key] = field.value field.value = '' Houston._call("#{Houston._session('collection_name')}_insert", new_doc) 'submit form.houston-filter-form': (e) -> e.preventDefault()
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc
802
https://github.com/gterrono/houston/blob/d3b7ccf5dbd13b2ef5c84220727d4eb62439d2fc/client/collection_view.coffee
115
131
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed
802
https://github.com/gterrono/houston/blob/66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', H...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefault(); if (Houston._session('sort_key') === this.toS...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed
802
https://github.com/gterrono/houston/blob/66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefau...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed
802
https://github.com/gterrono/houston/blob/66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if item.value field_selectors[item.name] = item.value Houston._session 'field_selectors',...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed
802
https://github.com/gterrono/houston/blob/66f4cd87f19211f41a82dd0dfc5c99778f4ef0ed/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
5eb765d65b771728b7a4f70f9a4430388545c983
802
https://github.com/gterrono/houston/blob/5eb765d65b771728b7a4f70f9a4430388545c983/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if item.value field_selectors[item.name] = item.value Houston._session 'field_selectors',...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
5eb765d65b771728b7a4f70f9a4430388545c983
802
https://github.com/gterrono/houston/blob/5eb765d65b771728b7a4f70f9a4430388545c983/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:9:raw_corpus
raw_corpus
# Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key] doc_iter[final_key] = field.value field.value = '...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
5eb765d65b771728b7a4f70f9a4430388545c983
802
https://github.com/gterrono/houston/blob/5eb765d65b771728b7a4f70f9a4430388545c983/client/collection_view.coffee
115
130
gterrono/houston:client/collection_view.coffee:9:completion
completion
# Unflatten the field names (e.g. foods.app -> {foods: {app:}}) keys = field.name.split('.') final_key = keys.pop() doc_iter = new_doc for key in keys doc_iter[key] = {} unless doc_iter[key] doc_iter = doc_iter[key]
doc_iter[final_key] = field.value field.value = '' Houston._call("#{Houston._session('collection_name')}_insert", new_doc) 'submit form.houston-filter-form': (e) -> e.preventDefault()
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
5eb765d65b771728b7a4f70f9a4430388545c983
802
https://github.com/gterrono/houston/blob/5eb765d65b771728b7a4f70f9a4430388545c983/client/collection_view.coffee
115
130
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
5649bd2bb384ceee4fba0c1817575a0fd8e3cef8
802
https://github.com/gterrono/houston/blob/5649bd2bb384ceee4fba0c1817575a0fd8e3cef8/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', H...
var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefault(); if (Houston._session('sort_key') === this.toS...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
5649bd2bb384ceee4fba0c1817575a0fd8e3cef8
802
https://github.com/gterrono/houston/blob/5649bd2bb384ceee4fba0c1817575a0fd8e3cef8/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { var ref; return ((ref = collection_info()) != null ? ref.fields : void 0) || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefau...
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
5649bd2bb384ceee4fba0c1817575a0fd8e3cef8
802
https://github.com/gterrono/houston/blob/5649bd2bb384ceee4fba0c1817575a0fd8e3cef8/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info()?.fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else H...
Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if item.value field_selectors[item.name] = item.value Houston._session 'field_selectors',...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
5649bd2bb384ceee4fba0c1817575a0fd8e3cef8
802
https://github.com/gterrono/houston/blob/5649bd2bb384ceee4fba0c1817575a0fd8e3cef8/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:5:raw_corpus
raw_corpus
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plura...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" ...
var collection_count; collection_count = function() { return collection_info().count; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_view_fields().slice(1); }, name: function() { ret...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var collection_count; collection_count = function() { return collection_info().count; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_vi...
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plura...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:completion
completion
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plura...
_.map documents, (d) -> d.collection = collection d._id = d._id._str or d._id return d values_in_order: -> fields_in_order = get_collection_view_fields() names_in_order = _.clone fields_in_order values = (Houston._nested_field_lookup(@, field_name) for field_name in fields_in_order[1..])...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info().fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else Ho...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info().fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Ho...
var get_collection_view_fields; get_collection_view_fields = function() { return collection_info().fields || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefault(); if (Houston._session('sort_key') === this.toString()) { Houston._session('sort_orde...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var get_collection_view_fields; get_collection_view_fields = function() { return collection_info().fields || []; }; Template._houston_collection_view.events({ "click a.houston-sort": function(e) { e.preventDefault(); if (Houston._session('sort_key') =...
get_collection_view_fields = -> collection_info().fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else Ho...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:8:completion
completion
get_collection_view_fields = -> collection_info().fields or [] Template._houston_collection_view.events "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Houston._session('sort_order') * - 1) else Ho...
Houston._call("#{Houston._session('collection_name')}_update", id, $set: update_dict) 'keyup .houston-column-filter': (e) -> field_selectors = {} $('.houston-column-filter').each (idx, item) -> if item.value field_selectors[item.name] = item.value Houston._session 'field_selectors',...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
379c076c2d987af237e161067be5729b1a43b4ab
802
https://github.com/gterrono/houston/blob/379c076c2d987af237e161067be5729b1a43b4ab/client/collection_view.coffee
65
114
gterrono/houston:client/collection_view.coffee:5:raw_corpus
raw_corpus
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plura...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
c64d37df458f49f3aec190bdf793fa665473895a
802
https://github.com/gterrono/houston/blob/c64d37df458f49f3aec190bdf793fa665473895a/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" ...
var collection_count; collection_count = function() { return collection_info().count; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_view_fields().slice(1); }, name: function() { ret...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
c64d37df458f49f3aec190bdf793fa665473895a
802
https://github.com/gterrono/houston/blob/c64d37df458f49f3aec190bdf793fa665473895a/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var collection_count; collection_count = function() { return collection_info().count; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_vi...
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plura...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
c64d37df458f49f3aec190bdf793fa665473895a
802
https://github.com/gterrono/houston/blob/c64d37df458f49f3aec190bdf793fa665473895a/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:completion
completion
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> Houston._session('collection_name') document_id: -> @_id + "" num_of_records: -> collection_count() or "no" plura...
_.map documents, (d) -> d.collection = collection d._id = d._id._str or d._id return d values_in_order: -> fields_in_order = get_collection_view_fields() names_in_order = _.clone fields_in_order values = (Houston._nested_field_lookup(@, field_name) for field_name in fields_in_order[1..])...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
c64d37df458f49f3aec190bdf793fa665473895a
802
https://github.com/gterrono/houston/blob/c64d37df458f49f3aec190bdf793fa665473895a/client/collection_view.coffee
29
55
gterrono/houston:client/collection_view.coffee:5:raw_corpus
raw_corpus
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> "#{Houston._session('collection_name')}" document_url: -> "/houston/#{Houston._session('collection_name')}/#{@_id}" doc...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
446fa960c31d33c521b881308100a6ac27b904d0
802
https://github.com/gterrono/houston/blob/446fa960c31d33c521b881308100a6ac27b904d0/client/collection_view.coffee
29
56
gterrono/houston:client/collection_view.coffee:5:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> "#{Houston._session('collection_name')}" document_url: -> "/hous...
var collection_count; collection_count = function() { return collection_info().count; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_view_fields().slice(1); }, name: function() { ret...
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
446fa960c31d33c521b881308100a6ac27b904d0
802
https://github.com/gterrono/houston/blob/446fa960c31d33c521b881308100a6ac27b904d0/client/collection_view.coffee
29
56
gterrono/houston:client/collection_view.coffee:5:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var collection_count; collection_count = function() { return collection_info().count; }; Template._houston_collection_view.helpers({ headers: function() { return get_collection_view_fields(); }, nonid_headers: function() { return get_collection_vi...
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> "#{Houston._session('collection_name')}" document_url: -> "/houston/#{Houston._session('collection_name')}/#{@_id}" doc...
JavaScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
446fa960c31d33c521b881308100a6ac27b904d0
802
https://github.com/gterrono/houston/blob/446fa960c31d33c521b881308100a6ac27b904d0/client/collection_view.coffee
29
56
gterrono/houston:client/collection_view.coffee:5:completion
completion
collection_count = -> collection_info().count Template._houston_collection_view.helpers headers: -> get_collection_view_fields() nonid_headers: -> get_collection_view_fields()[1..] name: -> "#{Houston._session('collection_name')}" document_url: -> "/houston/#{Houston._session('collection_name')}/#{@_id}" doc...
_.map documents, (d) -> d.collection = collection d._id = d._id._str or d._id return d values_in_order: -> fields_in_order = get_collection_view_fields() names_in_order = _.clone fields_in_order values = (Houston._nested_field_lookup(@, field_name) for field_name in fields_in_order[1..])...
CoffeeScript
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
446fa960c31d33c521b881308100a6ac27b904d0
802
https://github.com/gterrono/houston/blob/446fa960c31d33c521b881308100a6ac27b904d0/client/collection_view.coffee
29
56
gterrono/houston:client/collection_view.coffee:8:raw_corpus
raw_corpus
get_collection_view_fields = -> collection_info().fields or [] Template._houston_collection_view.events "click a.houston-home": (e) -> Houston._go 'home' "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == this.toString()) Houston._session('sort_order', Ho...
CoffeeScript
gterrono/houston
client/collection_view.coffee
MIT
446fa960c31d33c521b881308100a6ac27b904d0
802
https://github.com/gterrono/houston/blob/446fa960c31d33c521b881308100a6ac27b904d0/client/collection_view.coffee
66
115
gterrono/houston:client/collection_view.coffee:8:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript get_collection_view_fields = -> collection_info().fields or [] Template._houston_collection_view.events "click a.houston-home": (e) -> Houston._go 'home' "click a.houston-sort": (e) -> e.preventDefault() if (Houston._session('sort_key') == t...
var get_collection_view_fields; get_collection_view_fields = function() { return collection_info().fields || []; }; Template._houston_collection_view.events({ "click a.houston-home": function(e) { return Houston._go('home'); }, "click a.houston-sort": function(e) { e.preventDefault(); if (Houston....
CoffeeScript
JavaScript
gterrono/houston
client/collection_view.coffee
MIT
446fa960c31d33c521b881308100a6ac27b904d0
802
https://github.com/gterrono/houston/blob/446fa960c31d33c521b881308100a6ac27b904d0/client/collection_view.coffee
66
115