{"version":3,"sources":["webpack:///dist/build.js","webpack:///webpack/bootstrap 870c48a7b27eb5b671e4","webpack:///./src/app.js","webpack:///./src/upload.service.js","webpack:///./src/upload.js"],"names":["modules","__webpack_require__","moduleId","installedModules","exports","module","i","l","call","m","c","d","name","getter","o","Object","defineProperty","configurable","enumerable","get","n","__esModule","object","property","prototype","hasOwnProperty","p","s","_upload","_upload2","obj","default","UploadService","$inject","angular","service","_classCallCheck","instance","Constructor","TypeError","value","_createClass","defineProperties","target","props","length","descriptor","writable","key","protoProps","staticProps","$http","this","teste","Upload","onPreUpload","onProgress","onUploadSuccess","onUploadFail","nome","form","_this","formData","FormData","append","Function","method","url","headers","Content-Type","data","uploadEventHandlers","progress","e","lengthComputable","transformRequest","identity","then","catch"],"mappings":"CAAS,SAAUA,GCInB,QAAAC,GAAAC,GAGA,GAAAC,EAAAD,GACA,MAAAC,GAAAD,GAAAE,OAGA,IAAAC,GAAAF,EAAAD,IACAI,EAAAJ,EACAK,GAAA,EACAH,WAUA,OANAJ,GAAAE,GAAAM,KAAAH,EAAAD,QAAAC,IAAAD,QAAAH,GAGAI,EAAAE,GAAA,EAGAF,EAAAD,QAvBA,GAAAD,KA4BAF,GAAAQ,EAAAT,EAGAC,EAAAS,EAAAP,EAGAF,EAAAU,EAAA,SAAAP,EAAAQ,EAAAC,GACAZ,EAAAa,EAAAV,EAAAQ,IACAG,OAAAC,eAAAZ,EAAAQ,GACAK,cAAA,EACAC,YAAA,EACAC,IAAAN,KAMAZ,EAAAmB,EAAA,SAAAf,GACA,GAAAQ,GAAAR,KAAAgB,WACA,WAA2B,MAAAhB,GAAA,SAC3B,WAAiC,MAAAA,GAEjC,OADAJ,GAAAU,EAAAE,EAAA,IAAAA,GACAA,GAIAZ,EAAAa,EAAA,SAAAQ,EAAAC,GAAsD,MAAAR,QAAAS,UAAAC,eAAAjB,KAAAc,EAAAC,IAGtDtB,EAAAyB,EAAA,GAGAzB,IAAA0B,EAAA,KDMM,SAAUtB,EAAQD,E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\t// The module cache\n/******/ \tvar installedModules = {};\n/******/\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n/******/\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId]) {\n/******/ \t\t\treturn installedModules[moduleId].exports;\n/******/ \t\t}\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\ti: moduleId,\n/******/ \t\t\tl: false,\n/******/ \t\t\texports: {}\n/******/ \t\t};\n/******/\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n/******/\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.l = true;\n/******/\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n/******/\n/******/\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n/******/\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n/******/\n/******/ \t// define getter function for harmony exports\n/******/ \t__webpack_require__.d = function(exports, name, getter) {\n/******/ \t\tif(!__webpack_require__.o(exports, name)) {\n/******/ \t\t\tObject.defineProperty(exports, name, {\n/******/ \t\t\t\tconfigurable: false,\n/******/ \t\t\t\tenumerable: true,\n/******/ \t\t\t\tget: getter\n/******/ \t\t\t});\n/******/ \t\t}\n/******/ \t};\n/******/\n/******/ \t// getDefaultExport function for compatibility with non-harmony modules\n/******/ \t__webpack_require__.n = function(module) {\n/******/ \t\tvar getter = module && module.__esModule ?\n/******/ \t\t\tfunction getDefault() { return module['default']; } :\n/******/ \t\t\tfunction getModuleExports() { return module; };\n/******/ \t\t__webpack_require__.d(getter, 'a', getter);\n/******/ \t\treturn getter;\n/******/ \t};\n/******/\n/******/ \t// Object.prototype.hasOwnProperty.call\n/******/ \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n/******/\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n/******/\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(__webpack_require__.s = 0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nvar _upload = __webpack_require__(1);\n\nvar _upload2 = _interopRequireDefault(_upload);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n_upload2.default.$inject = ['$http'];\n\nangular.module('$uploadModule', []).service('$upload', _upload2.default);\n\n/***/ }),\n/* 1 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nvar _upload = __webpack_require__(2);\n\nvar _upload2 = _interopRequireDefault(_upload);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nvar UploadService = function () {\n function UploadService($http) {\n _classCallCheck(this, UploadService);\n\n this.teste = 'Hello World';\n this.$http = $http;\n }\n\n _createClass(UploadService, [{\n key: 'createUpload',\n value: function createUpload() {\n return new _upload2.default(this.$http);\n }\n }]);\n\n return UploadService;\n}();\n\nexports.default = UploadService;\n\n/***/ }),\n/* 2 */\n/***/ (function(module, exports, __webpack_require__) {\n\n\"use strict\";\n\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\nvar Upload = function () {\n function Upload($http) {\n _classCallCheck(this, Upload);\n\n this.onPreUpload = null;\n this.onProgress = null;\n this.onUploadSuccess = null;\n this.onUploadFail = null;\n this.$http = $http;\n }\n\n _createClass(Upload, [{\n key: 'upload',\n value: function upload(nome, form) {\n var _this = this;\n\n var formData = new FormData();\n\n formData.append('nome', nome);\n formData.append('file', form);\n\n if (this.onPreUpload instanceof Function) {\n this.onPreUpload();\n }\n this.$http({\n method: 'post',\n url: '../../UploadAsp/ToFileSystem.asp',\n headers: {\n 'Content-Type': 'multipart/form-data'\n },\n data: formData,\n uploadEventHandlers: {\n progress: function progress(e) {\n if (e.lengthComputable) {\n //console.log(e);\n if (_this.onProgress instanceof Function) {\n _this.onProgress(e);\n }\n }\n }\n },\n transformRequest: angular.identity\n }).then(function (data) {\n if (_this.onUploadSuccess instanceof Function) {\n _this.onUploadSuccess(data);\n }\n }).catch(function (data) {\n if (_this.onUploadFail instanceof Function) {\n _this.onUploadFail(data);\n }\n });\n }\n }]);\n\n return Upload;\n}();\n\nexports.default = Upload;\n\n/***/ })\n/******/ ]);\n\n\n// WEBPACK FOOTER //\n// dist/build.js"," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, {\n \t\t\t\tconfigurable: false,\n \t\t\t\tenumerable: true,\n \t\t\t\tget: getter\n \t\t\t});\n \t\t}\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 0);\n\n\n\n// WEBPACK FOOTER //\n// webpack/bootstrap 870c48a7b27eb5b671e4","import UploadService from './upload.service';\n\nUploadService.$inject = ['$http'];\n\nangular.module('$uploadModule', []).service('$upload', UploadService);\n\n\n\n// WEBPACK FOOTER //\n// ./src/app.js","import Upload from './upload';\n\nexport default class UploadService {\n constructor($http) {\n this.teste = 'Hello World';\n this.$http = $http;\n }\n\n createUpload() {\n return new Upload(this.$http);\n }\n}\n\n\n\n// WEBPACK FOOTER //\n// ./src/upload.service.js","export default class Upload {\n constructor($http) {\n this.onPreUpload = null;\n this.onProgress = null;\n this.onUploadSuccess = null;\n this.onUploadFail = null;\n this.$http = $http;\n }\n\n upload(nome, form) {\n const formData = new FormData();\n\n formData.append('nome', nome);\n formData.append('file', form);\n\n\n if (this.onPreUpload instanceof Function) {\n this.onPreUpload();\n }\n this.$http({\n method: 'post',\n url: '../../UploadAsp/ToFileSystem.asp',\n headers: {\n 'Content-Type': 'multipart/form-data',\n },\n data: formData,\n uploadEventHandlers: {\n progress: (e) => {\n if (e.lengthComputable) {\n //console.log(e);\n if (this.onProgress instanceof Function) {\n this.onProgress(e);\n }\n }\n },\n },\n transformRequest: angular.identity,\n }).then((data) => {\n if (this.onUploadSuccess instanceof Function) {\n this.onUploadSuccess(data);\n }\n }).catch((data) => {\n if (this.onUploadFail instanceof Function) {\n this.onUploadFail(data);\n }\n });\n }\n}\n\n\n\n// WEBPACK FOOTER //\n// ./src/upload.js"],"sourceRoot":""}