Revision 1281:e9bfba17e791 plugins/redmine_bibliography/assets

View differences:

plugins/redmine_bibliography/assets/javascripts/authors.js
14 14
  $(link).closest(".fields").hide();
15 15
}
16 16

  
17
$(".author_search").live('keyup.autocomplete', function(){
18
    $this = $(this);
19

  
20
    $.ajax({
21
        type: "POST",
22
        url: "/publications/autocomplete_for_author",
23
        dataType: "json",
24
        data: {
25
            q: $this.val()
26
        },
27

  
28
        success: function(data, type) {
29
            console.log("OK: " + data);
30
            items = data;
31
            response(items);
32
        },
33

  
34
        error: function(data, type){
35
            console.log("ERROR: " + type);
36
        }
37
    });
38
});
39

  
40

  
17 41
function identify_author_status(status, object_id) {
18 42
    $('publication_authorships_attributes_' + object_id + '_edit_author_info').select('input').each(function(s) {
19 43
	if(status == "no"){

Also available in: Unified diff