forked from External/greenlight
		
	destroy recordings table before caching page
This commit is contained in:
		| @@ -102,6 +102,9 @@ class @Recordings | |||||||
|     }; |     }; | ||||||
|     $('#recordings').tooltip(options) |     $('#recordings').tooltip(options) | ||||||
|  |  | ||||||
|  |     $(document).on "turbolinks:before-cache", => | ||||||
|  |       @getTable().api().clear().draw().destroy() | ||||||
|  |  | ||||||
|     # enable popovers |     # enable popovers | ||||||
|     options = { |     options = { | ||||||
|       selector: '.has-popover', |       selector: '.has-popover', | ||||||
| @@ -150,7 +153,7 @@ class @Recordings | |||||||
|   # setup click handlers for the action buttons |   # setup click handlers for the action buttons | ||||||
|   setupActionHandlers: -> |   setupActionHandlers: -> | ||||||
|     table_api = this.table.api() |     table_api = this.table.api() | ||||||
|     this.table.on 'click', '.recording-update', (event) -> |     @getTable().on 'click', '.recording-update', (event) -> | ||||||
|       btn = $(this) |       btn = $(this) | ||||||
|       row = table_api.row($(this).closest('tr')).data() |       row = table_api.row($(this).closest('tr')).data() | ||||||
|       url = $('.meeting-url').val() |       url = $('.meeting-url').val() | ||||||
| @@ -182,6 +185,9 @@ class @Recordings | |||||||
|         btn.prop('disabled', false) |         btn.prop('disabled', false) | ||||||
|       ) |       ) | ||||||
|  |  | ||||||
|  |   getTable: -> | ||||||
|  |     @table | ||||||
|  |  | ||||||
|   isOwner: -> |   isOwner: -> | ||||||
|     @owner |     @owner | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user