{"version":3,"sources":["webpack:///./src/router/views/pages/devices/searchGroups.vue?6ad8","webpack:///src/router/views/pages/devices/searchGroups.vue","webpack:///./src/router/views/pages/devices/searchGroups.vue?59e7","webpack:///./src/router/views/pages/devices/searchGroups.vue","webpack:///./src/router/apiFiles/deviceApi.js","webpack:///./src/router/apiFiles/customerApi.js"],"names":["render","_vm","this","_h","$createElement","_c","_self","attrs","title","items","staticClass","_v","pageOptions","model","value","callback","$$v","perPage","expression","filter","currentUser","role","directives","name","rawName","staticStyle","on","$event","$$selectedVal","Array","prototype","call","target","options","o","selected","map","val","_value","customerId","multiple","_l","customer","key","id","domProps","_s","_e","fetchData","tableData","fields","currentPage","isBusy","scopedSlots","_u","fn","proxy","data","item","customerName","totalRows","staticRenderFns","page","meta","content","components","Layout","PageHeader","text","href","active","label","sortable","computed","rows","mounted","console","methods","customerApi","search","then","self","deviceApi","watch","handler","component","searchDevices","axios","get","response","getDevicesReport","responseType","fileURL","window","URL","createObjectURL","Blob","fileLink","document","createElement","setAttribute","body","appendChild","click","getDevice","getDeviceComplete","updateDevice","chassis","note","groupId","put","createDevice","modemId","modelId","post","createDeviceBulk","ids","updateDeviceBulk","installDeviceBulk","devices","searchDeviceModels","searchTelemetry","deviceId","start","end","getPlanActivationStatus","activateDevicePlan","searchDeviceGroups","createDeviceGroup","description","endpoint","endpointToken","updateDeviceGroup","getDeviceGroup","countMessages","modemIdentifier","searchCustomers","createCustomer","corporateName","tradeName","alertEmail","techEmail","techManager","techPhone","updateCustomer","getCustomer"],"mappings":"yHAAA,IAAIA,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,SAAS,CAACA,EAAG,aAAa,CAACE,MAAM,CAAC,MAAQN,EAAIO,MAAM,MAAQP,EAAIQ,SAASJ,EAAG,MAAM,CAACK,YAAY,OAAO,CAACL,EAAG,MAAM,CAACK,YAAY,UAAU,CAACL,EAAG,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C,IACFC,IAAI,gBAAkB5C,GACtBoC,KAAMS,GACIA,EAAShC","file":"js/chunk-855e3cae.8af6e7f2.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('Layout',[_c('PageHeader',{attrs:{\"title\":_vm.title,\"items\":_vm.items}}),_c('div',{staticClass:\"row\"},[_c('div',{staticClass:\"col-12\"},[_c('div',{staticClass:\"card\"},[_c('div',{staticClass:\"card-body\"},[_c('p',{staticClass:\"text-muted font-13 mb-4\"}),_c('div',{staticClass:\"row mb-md-2\"},[_c('div',{staticClass:\"col-sm-12\"},[_c('div',{staticClass:\"dataTables_length text-md-right float-right\",attrs:{\"id\":\"tickets-table_length\"}},[_c('label',{staticClass:\"d-inline-flex align-items-center\"},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\\t\\t\\tShow \\n\\t\\t\\t\\t\\t\\t\\t\\t\\t\"),_c('b-form-select',{attrs:{\"size\":\"sm\",\"options\":_vm.pageOptions},model:{value:(_vm.perPage),callback:function ($$v) {_vm.perPage=$$v},expression:\"perPage\"}}),_vm._v(\" entries\\n\\t\\t\\t\\t\\t\\t\\t\\t\")],1)])])]),_c('div',{staticClass:\"row mb-md-2\"},[_c('div',{staticClass:\"col-sm-5 col-md-4\"},[_c('div',[_c('label',{},[_vm._v(\"\\n\\t\\t\\t\\t\\t\\t\\t\\t\\tSearch:\\n\\t\\t\\t\\t\\t\\t\\t\\t\")]),_c('b-input-group',[_c('b-form-input',{staticClass:\"form-control form-control-sm\",attrs:{\"type\":\"search\",\"placeholder\":\"name...\"},model:{value:(_vm.filter),callback:function ($$v) {_vm.filter=$$v},expression:\"filter\"}})],1)],1)]),(_vm.currentUser && _vm.currentUser.role == '1')?_c('div',{staticClass:\"col-sm-5 col-md-4\"},[_c('div',{staticClass:\"form-group\"},[_c('label',[_vm._v(\"Customer\")]),_c('div',[_c('select',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.customerId),expression:\"customerId\"}],staticClass:\"form-control form-control-sm\",staticStyle:{\"max-width\":\"100%\"},on:{\"change\":function($event){var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = \"_value\" in o ? o._value : o.value;return val}); _vm.customerId=$event.target.multiple ? $$selectedVal : $$selectedVal[0]}}},[_c('option',{attrs:{\"value\":\"\"}}),_vm._l((_vm.customers),function(customer){return _c('option',{key:customer.id,domProps:{\"value\":customer.id}},[_vm._v(_vm._s(customer.name))])})],2)])])]):_vm._e(),_c('div',{staticClass:\"col-sm-2 col-md-1\"},[_c('div',[_c('div',{staticClass:\"form-group form-group-sm\"},[_c('label',[_vm._v(\"Find\")]),_c('div',[_c('button',{staticClass:\"btn btn-sm btn-info\",on:{\"click\":_vm.fetchData}},[_c('i',{staticClass:\"uil uil-search\"})])])])])])]),_c('div',{staticClass:\"table-responsive mb-0\"},[_c('b-table',{attrs:{\"items\":_vm.tableData,\"fields\":_vm.fields,\"responsive\":\"sm\",\"per-page\":0,\"current-page\":_vm.currentPage,\"busy\":_vm.isBusy},scopedSlots:_vm._u([{key:\"table-busy\",fn:function(){return [_c('div',{staticClass:\"text-center text-danger my-2\"},[_c('b-spinner',{staticClass:\"align-middle\"})],1)]},proxy:true},{key:\"cell(link)\",fn:function(data){return [_c('router-link',{attrs:{\"tag\":\"a\",\"to\":(\"/group/\" + (data.item.id))}},[_c('b',[_vm._v(_vm._s(data.item.name))])])]}},{key:\"cell(customerName)\",fn:function(data){return [_c('div',[_vm._v(_vm._s(data.item.customerName))])]}}])})],1),_c('div',{staticClass:\"row\"},[_c('div',{staticClass:\"col\"},[_c('div',{staticClass:\"dataTables_paginate paging_simple_numbers float-right\"},[_c('ul',{staticClass:\"pagination pagination-rounded mb-0\"},[_c('b-pagination',{attrs:{\"total-rows\":_vm.totalRows,\"per-page\":_vm.perPage},model:{value:(_vm.currentPage),callback:function ($$v) {_vm.currentPage=$$v},expression:\"currentPage\"}})],1)])])])])])])])],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\r\n\r\n","import mod from \"-!../../../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./searchGroups.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./searchGroups.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./searchGroups.vue?vue&type=template&id=57840c38&\"\nimport script from \"./searchGroups.vue?vue&type=script&lang=js&\"\nexport * from \"./searchGroups.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","import axios from 'axios'\r\n\r\nexport const deviceApi = {\r\n\r\n searchDevices({ search, page, perPage, customerId } = {}) {\r\n return axios\r\n .get('/device/search?search=' + search + '&customerId='+ customerId +'&page=' + page + '&perPage=' + perPage)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n getDevicesReport() {\r\n return axios\r\n .get('/device/exportdevicesexcel', {\r\n responseType: 'blob'\r\n })\r\n .then((response) => {\r\n var fileURL = window.URL.createObjectURL(new Blob([response.data]));\r\n var fileLink = document.createElement('a');\r\n\r\n fileLink.href = fileURL;\r\n fileLink.setAttribute('download', 'Devices report.xlsx');\r\n document.body.appendChild(fileLink);\r\n\r\n fileLink.click();\r\n\r\n return true;\r\n })\r\n },\r\n\r\n getDevice({ id } = {}) {\r\n return axios\r\n .get('/device/get?id=' + id)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n getDeviceComplete({ id } = {}) {\r\n return axios\r\n .get('/device/GetWithLastMessages?id=' + id)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n updateDevice({ id, chassis, note, groupId } = {}) {\r\n return axios\r\n .put('/device/update', { id, chassis, note, groupId }, {})\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n createDevice({ modemId, modelId, customerId } = {}) {\r\n return axios\r\n .post('/device/createdevice', { id: modemId, modelId, customerId }, {})\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n createDeviceBulk({ ids, modelId, customerId } = {}) {\r\n return axios\r\n .post('/device/createdevicebulk', { ids, modelId, customerId }, {})\r\n .then((response) => {\r\n return true;\r\n })\r\n },\r\n\r\n updateDeviceBulk({ ids, customerId } = {}) {\r\n return axios\r\n .put('/device/updatedevicebulk', { ids, customerId }, {})\r\n .then((response) => {\r\n return true;\r\n })\r\n },\r\n\r\n installDeviceBulk({ devices } = {}) {\r\n return axios\r\n .put('/device/installdevicebulk', { devices }, {})\r\n .then((response) => {\r\n return true;\r\n })\r\n },\r\n\r\n searchDeviceModels({ search, page, perPage } = {}) {\r\n return axios\r\n .get('/device/searchdevicemodels?search=' + search + '&page=' + page + '&perPage=' + perPage)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n searchTelemetry({ deviceId, page, perPage, start, end } = {}) {\r\n return axios\r\n .get('/device/searchtelemetry?deviceId=' + deviceId + '&page=' + page + '&perPage=' + perPage + '&start=' + start + '&end=' + end)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n getPlanActivationStatus({ deviceId } = {}) {\r\n return axios\r\n .get('/plan/getactivation?deviceId=' + deviceId)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n activateDevicePlan({ deviceId } = {}) {\r\n return axios\r\n .post('/plan/activateplan', { deviceId }, {})\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n searchDeviceGroups({ search, customerId, page, perPage }) {\r\n return axios\r\n .get(`/device/searchdevicegroups?search=${search}&customerId=${customerId}&page=${page}&perPage=${perPage}`)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n createDeviceGroup({ name, description, endpoint, endpointToken, customerId } = {}) {\r\n customerId = customerId == '' ? null : customerId\r\n return axios\r\n .post('/device/creategroup', { name, description, endpoint, endpointToken, customerId }, {})\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n updateDeviceGroup({ id, name, description, endpoint, endpointToken } = {}) {\r\n return axios\r\n .put('/device/updategroup', { id, name, description, endpoint, endpointToken }, {})\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\r\n getDeviceGroup({ id } = {}) {\r\n return axios\r\n .get('/device/GetDeviceGroup?id=' + id)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\t\r\n countMessages({ modemIdentifier, page, perPage, start, end } = {}) {\r\n return axios\r\n .get('/device/countmessages?modemIdentifier=' + modemIdentifier + '&page=' + page + '&perPage=' + perPage + '&start=' + start + '&end=' + end)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\t\r\n\r\n}\r\n","import axios from 'axios'\r\n\r\nexport const customerApi = {\r\n\r\n searchCustomers({ search, page, perPage } = {}) {\r\n return axios\r\n .get('/customer/search?search=' + search + '&page=' + page + '&perPage=' + perPage)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\t\r\n createCustomer({ name, document, corporateName, tradeName, note, alertEmail, techEmail, techManager, techPhone } = {}) {\r\n return axios\r\n .post('/customer/createcustomer', { name, document, corporateName, tradeName, note, alertEmail, techEmail, techManager, techPhone }, {})\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\r\n\t\r\n updateCustomer({ id, name, document, corporateName, tradeName, note, alertEmail, techEmail, techManager, techPhone } = {}) {\r\n return axios\r\n .put('/customer/update', { id, name, document, corporateName, tradeName, note, alertEmail, techEmail, techManager, techPhone }, {})\r\n .then((response) => {\r\n return response.data\r\n })\r\n }, \t\t\r\n\t\r\n getCustomer({ id } = {}) {\r\n return axios\r\n .get('/customer?id=' + id)\r\n .then((response) => {\r\n return response.data\r\n })\r\n },\t\r\n}\r\n"],"sourceRoot":""}