1 2var socials = { 3 data: [], 4 types: [], 5 total: 0, 6 filter: { 7 search: "", 8 size: 500, 9 page: 1, 10 sort: "name", 11 sortType: "asc" 12 }, 13 get: function() { 14 service.call("socials", socials.filter, socials.returned); 15 }, 16 returned: function(e) { 17 $(".loader").removeClass("open"); 18 if (e.error) growler.error(e.error); 19 else { 20 socials.data = e.data; 21 socials.total = e.total; 22 context.set("socials", socials.data); 23 } 24 }, 25 save: function(url, id) { 26 $(".loader").addClass("open"); 27 var params = socials.filter; 28 params.id = id; 29 params.url = url; 30 service.call("social", params, socials.returned); 31 }, 32 delete: function(ids) { 33 var params = category.filter; 34 params.ids = ids; 35 service.call("social", params, socials.returned, "DELETE"); 36 }, 37 details: function(id) { 38 for (var i=0; i<socials.data.length; i++) { 39 if (id==socials.data[i].socialId) return socials.data[i]; 40 } 41 return null; 42 }, 43 getTypes: function() { 44 service.call("socialTypes", {}, socials.typesLoaded); 45 }, 46 typesLoaded: function(e) { 47 socials.types = e.data; 48 context.set("socialTypes", e.data); 49 } 50}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.