1(function () { 2 'use strict'; 3 4 var isOnGitHub = false, url = 'upload/'; 5 6 angular.module('fileuploader', [ 7 'blueimp.fileupload' 8 ]) 9 10 .controller('SupportFileUploadController', ['$scope', '$http', '$filter', '$window', 11 function ($scope, $http) { 12 this.s = $scope; 13 14 this.test = function(){ 15 alert('testing'); 16 alert(this.s.queue.length); 17 } 18 19 this.onFormSubmit = function(sender) 20 { 21 angular.forEach(sender.$parent.stc.submitForm.$error.required, function(field) { 22 field.$setDirty(); 23 }); 24 25 if(sender.$parent.stc.submitForm.$valid) { 26 sender.submit(); 27 } 28 } 29 30 $scope.options = { 31 url: url 32 }; 33 } 34 ]) 35 36 .controller('FileDestroyController', [ 37 '$scope', '$http', 38 function ($scope, $http) { 39 var file = $scope.file, 40 state; 41 if (file.url) { 42 file.$state = function () { 43 return state; 44 }; 45 file.$destroy = function () { 46 state = 'pending'; 47 return $http({ 48 url: file.deleteUrl, 49 method: file.deleteType 50 }).then( 51 function () { 52 state = 'resolved'; 53 $scope.clear(file); 54 }, 55 function () { 56 state = 'rejected'; 57 } 58 ); 59 }; 60 } else if (!file.$cancel && !file._index) { 61 file.$cancel = function () { 62 $scope.clear(file); 63 }; 64 } 65 } 66 ]); 67 68}());
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.