|
|
|
|
@ -55,6 +55,12 @@ $(document).ready(function() { |
|
|
|
|
return $('#'+panel_id); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
doc_rows.click(function(e){ |
|
|
|
|
e.preventDefault(); |
|
|
|
|
var link = $($(this).find('a')[0]).attr('href'); |
|
|
|
|
console.log(link); |
|
|
|
|
location.replace(link); |
|
|
|
|
}) |
|
|
|
|
$('.toggle_doc_status').on('click', function(e){ |
|
|
|
|
e.preventDefault(); |
|
|
|
|
$this = $(this); |
|
|
|
|
@ -63,13 +69,7 @@ $(document).ready(function() { |
|
|
|
|
var doc_attr = $this.data("attr") |
|
|
|
|
$.post('/my/docs/ajax_toggle_doc_status/' + doc_type + '/' + doc_id + '/' + doc_attr + '/', function(data){
|
|
|
|
|
$this.text(data[0]); |
|
|
|
|
$this.removeClass('doc_status1'); |
|
|
|
|
$this.removeClass('doc_status2'); |
|
|
|
|
$this.removeClass('doc_status3'); |
|
|
|
|
$this.removeClass('doc_statustrue'); |
|
|
|
|
$this.removeClass('doc_statusTrue'); |
|
|
|
|
$this.removeClass('doc_statusFalse'); |
|
|
|
|
$this.removeClass('doc_statusfalse'); |
|
|
|
|
$this.removeClass('doc_status1 doc_status2 doc_status3 doc_statustrue doc_statusTrue doc_statusFalse doc_statusfalse'); |
|
|
|
|
$this.addClass('doc_status' + data[1]); |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|