{"version":3,"sources":["webpack:///./src/components/Pagination/index.vue?1bed","webpack:///scroll-to.ts","webpack:///./src/components/Pagination/index.vue?e699","webpack:///./src/components/Pagination/index.vue?1308","webpack:///./src/components/Pagination/index.vue","webpack:///cohorts.ts","webpack:///./src/components/Pagination/index.vue?bfef","webpack:///./src/views/labs/cohortLabs/index.vue?2842","webpack:///cohort.ts","webpack:///./node_modules/agentkeepalive/browser.js","webpack:///request.ts","webpack:///./src/views/labs/cohortLabs/index.vue?c8c7","webpack:///cohortLabs.ts","webpack:///./src/views/labs/cohortLabs/index.vue?c50c","webpack:///./src/views/labs/cohortLabs/index.vue?1289","webpack:///./src/views/labs/cohortLabs/index.vue"],"names":["render","_vm","this","_h","$createElement","_c","_self","staticClass","class","hidden","_b","attrs","background","currentPage","pageSize","layout","pageSizes","total","on","$event","handleSizeChange","handleCurrentChange","$attrs","staticRenderFns","easeInOutQuad","t","window","document","page","value","$emit","limit","autoScroll","scrollTo","required","default","name","component","noop","module","exports","HttpsAgent","staticStyle","handleCohortSelection","model","callback","$$v","cohortId","expression","_l","cohort","key","id","directives","rawName","reloadCohortLabs","_v","_s","$t","tableKey","paginatedCohortLabs","prop","order","scopedSlots","_u","fn","ref","row","handleUpdate","lab","displayName","version","filteredCohortLabs","length","perPage","paginationChange","cohortLabs","selectedCohortLabs","listLoading","searchTerm","cloneDialogVisible","getCohorts","getCohortLabs","$on","filterBySearch","$off","cohorts","then","response","data","SetCohorts","filterBySearchTerm","paginateData","start","end","slice","targetString","filter","cl","toLowerCase","includes","error","console","log","components","Pagination"],"mappings":"wIAAA,IAAIA,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,uBAAuBC,MAAM,CAAC,OAAUP,EAAIQ,SAAS,CAACJ,EAAG,gBAAgBJ,EAAIS,GAAG,CAACC,MAAM,CAAC,WAAaV,EAAIW,WAAW,eA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,QAClC,OAAOE,EAAWmB,MAAMF,EAAOC,KA7CnC,gCAgDU,SAAmBlB,GAAwB,WAC7CoB,EAAuB,GAC3B,MAAuB,IAAnB9F,KAAK6E,WACAH,EAAWqB,QAAO,SAACC,GACxB,QAAIA,EAAGhD,OAAOd,OACZ4D,EAAe,GAAH,OAAME,EAAGhD,OAAOd,MAAhB,OAAuB8D,EAAG7B,IAAIC,aACnC0B,EAAaG,cAAcC,SAAS,EAAKrB,WAAWoB,mBAK1DvB,IA3DX,oFA8DU,gHACN1E,KAAK4E,aAAc,EADb,SAEA,EAAc,IAAIS,MACtB,SAACC,GACC,IAAIC,EAAOD,EAASC,KACpB,EAAKb,WAAaa,EAClB,EAAKxE,MAAQwE,EAAKhB,OAClB,EAAKW,eAAe,CAACvD,MAAO,KAC5B,EAAKiD,aAAc,KAErB,SAACuB,GACCC,QAAQC,IAAIF,GACZ,EAAKvB,aAAc,KAZjB,gDA9DV,uFA+EU,WACN5E,KAAKgF,kBAhFT,mCAmFU,SAAsBO,GAC5BvF,KAAKgF,kBApFT,6BAuFU,WACNhF,KAAK8E,oBAAqB,IAxF9B,0BA2FU,SAAab,MA3FvB,8BA+FU,SAAiBsB,GACvBvF,KAAKW,YAAc4E,EAAK7D,KACpB1B,KAAKwE,UAAYe,EAAK1D,QACxB7B,KAAKW,YAAc,EACnBX,KAAKwE,QAAUe,EAAK1D,OAEtB7B,KAAKkF,eAAe,CAACvD,MAAO3B,KAAK6E,iBArGrC,GAA6B,QAA7B,kBAJC,eAAU,CACT3C,KAAM,aACNoE,WAAY,CAACC,aAAA,SAyGd,G,QCpMma,I,wBCQhapE,EAAY,eACd,EACArC,EACAuB,GACA,EACA,KACA,WACA,MAIa,aAAAc,E","file":"js/cohort-labs.8d98ce95.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"pagination-container\",class:{'hidden': _vm.hidden}},[_c('el-pagination',_vm._b({attrs:{\"background\":_vm.background,\"current-page\":_vm.currentPage,\"page-size\":_vm.pageSize,\"layout\":_vm.layout,\"page-sizes\":_vm.pageSizes,\"total\":_vm.total},on:{\"update:currentPage\":function($event){_vm.currentPage=$event},\"update:current-page\":function($event){_vm.currentPage=$event},\"update:pageSize\":function($event){_vm.pageSize=$event},\"update:page-size\":function($event){_vm.pageSize=$event},\"size-change\":_vm.handleSizeChange,\"current-change\":_vm.handleCurrentChange}},'el-pagination',_vm.$attrs,false))],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","const easeInOutQuad = (t, b, c, d) => {\n t /= d / 2;\n if (t < 1) {\n return (c / 2) * t * t + b;\n }\n t--;\n return (-c / 2) * (t * (t - 2) - 1) + b;\n};\n// requestAnimationFrame for Smart Animating http://goo.gl/sx5sts\nconst requestAnimFrame = (function() {\n return (\n window.requestAnimationFrame ||\n window.webkitRequestAnimationFrame ||\n window.mozRequestAnimationFrame ||\n function(callback) {\n window.setTimeout(callback, 1000 / 60);\n }\n );\n})();\n// Because it's so fucking difficult to detect the scrolling element, just move them all\nconst move = amount => {\n document.documentElement.scrollTop = amount;\n document.body.parentNode.scrollTop = amount;\n document.body.scrollTop = amount;\n};\nconst position = () => {\n return (\n document.documentElement.scrollTop ||\n document.body.parentNode.scrollTop ||\n document.body.scrollTop\n );\n};\nexport const scrollTo = (to, duration, callback) => {\n const start = position();\n const change = to - start;\n const increment = 20;\n let currentTime = 0;\n duration = typeof duration === \"undefined\" ? 500 : duration;\n const animateScroll = function() {\n // increment the time\n currentTime += increment;\n // find the value with the quadratic in-out easing function\n const val = easeInOutQuad(currentTime, start, change, duration);\n // move the document.body\n move(val);\n // do the animation unless its over\n if (currentTime < duration) {\n requestAnimFrame(animateScroll);\n } else {\n if (callback && typeof callback === \"function\") {\n // the animation is done so lets callback\n callback();\n }\n }\n };\n animateScroll();\n};\n//# sourceMappingURL=scroll-to.js.map\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, Prop, Vue } from 'vue-property-decorator'\nimport { scrollTo } from '@/utils/scroll-to'\n\n@Component({\n name: 'Pagination'\n})\nexport default class extends Vue {\n @Prop({ required: true }) private total!: number\n @Prop({ default: 1 }) private page!: number\n @Prop({ default: 20 }) private limit!: number\n @Prop({ default: () => [10, 20, 30, 50] }) private pageSizes!: number[]\n @Prop({ default: 'total, sizes, prev, pager, next, jumper' }) private layout!: string\n @Prop({ default: true }) private background!: boolean\n @Prop({ default: true }) private autoScroll!: boolean\n @Prop({ default: false }) private hidden!: boolean\n\n get currentPage() {\n return this.page\n }\n\n set currentPage(value) {\n this.$emit('update:page', value)\n }\n\n get pageSize() {\n return this.limit\n }\n\n set pageSize(value) {\n this.$emit('update:limit', value)\n }\n\n handleSizeChange(value: number) {\n this.$emit('pagination', { page: this.currentPage, limit: value })\n if (this.autoScroll) {\n scrollTo(0, 800)\n }\n }\n\n handleCurrentChange(value: number) {\n this.$emit('pagination', { page: value, limit: this.pageSize })\n if (this.autoScroll) {\n scrollTo(0, 800)\n }\n }\n}\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--13-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--13-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./index.vue?vue&type=template&id=2f4afb68&scoped=true&\"\nimport script from \"./index.vue?vue&type=script&lang=ts&\"\nexport * from \"./index.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./index.vue?vue&type=style&index=0&id=2f4afb68&lang=scss&scoped=true&\"\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 \"2f4afb68\",\n null\n \n)\n\nexport default component.exports","import request from '@/utils/request';\nexport const defaultCohort = {\n id: \"00000\",\n name: \"Pro Bootcamp\"\n};\nexport const getCohorts = (params) => request({\n url: '/cohorts',\n method: 'get',\n params\n});\nexport const getCohort = (id, params) => request({\n url: `/cohorts/${id}`,\n method: 'get',\n params\n});\n//# sourceMappingURL=cohorts.js.map","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/index.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/style-resources-loader/lib/index.js??ref--8-oneOf-1-4!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=style&index=0&id=2f4afb68&lang=scss&scoped=true&\"","export * from \"-!../../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../../node_modules/css-loader/index.js??ref--8-oneOf-1-1!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../../node_modules/style-resources-loader/lib/index.js??ref--8-oneOf-1-4!../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=style&index=0&id=3821c390&lang=scss&scoped=true&\"","import { __decorate } from \"tslib\";\nimport { VuexModule, Module, Action, Mutation, getModule } from 'vuex-module-decorators';\nimport store from '@/store';\nlet Cohort = class Cohort extends VuexModule {\n constructor() {\n super(...arguments);\n this.cohorts = [];\n }\n SET_COHORTS(cohorts) {\n this.cohorts = cohorts;\n }\n SetCohorts(cohorts) {\n return cohorts;\n }\n};\n__decorate([\n Mutation\n], Cohort.prototype, \"SET_COHORTS\", null);\n__decorate([\n Action({ commit: 'SET_COHORTS' })\n], Cohort.prototype, \"SetCohorts\", null);\nCohort = __decorate([\n Module({ dynamic: true, store, name: 'cohort' })\n], Cohort);\nexport const CohortModule = getModule(Cohort);\n//# sourceMappingURL=cohort.js.map","module.exports = noop;\nmodule.exports.HttpsAgent = noop;\n\n// Noop function for browser since native api's don't use agents.\nfunction noop () {}\n","import axios from \"axios\";\nimport { baseUrlApi } from \"@/config\";\nimport { Message } from \"element-ui\";\nimport { getToken } from \"@/utils/cookies\";\nconst Agent = require(\"agentkeepalive\");\n// const Qs = require('qs');\nconst keepAliveAgent = new Agent({\n maxSockets: 100,\n maxFreeSockets: 10,\n timeout: 60000,\n freeSocketTimeout: 30000 // free socket keepalive for 30 seconds\n});\nconst service = axios.create({\n baseURL: baseUrlApi + \"api/\",\n timeout: 60000,\n httpsAgent: keepAliveAgent,\n headers: {}\n // transformRequest: [\n // function(data, headers) {\n // // Do whatever you want to transform the data\n // return data;\n // }\n // ]\n // transformResponse: [function(data) {\n // // Do whatever you want to transform the data\n // return data;\n // }],\n // `paramsSerializer` is an optional function in charge of serializing `params`\n // paramsSerializer: function(params) {\n // return Qs.stringify(params, {arrayFormat: 'brackets'})\n // },\n // withCredentials: true // send cookies when cross-domain requests\n});\n// Request interceptors\nservice.interceptors.request.use(\n config => {\n // Add X-Access-Token header to every request, you can add other custom headers here\n if (getToken()) {\n config.headers[\"Authorization\"] = \"Bearer \" + getToken();\n }\n return config;\n },\n error => {\n Promise.reject(error);\n }\n);\n// Response interceptors\nservice.interceptors.response.use(\n response => {\n // console.log(\"Response:\", response)\n return response;\n },\n error => {\n if (!!error.isAxiosError && !error.response) {\n // window.location.href = `${baseUrl}session/signin`;\n } else {\n let response = error.response;\n if (response.status == 401) {\n Message({\n message: \"Unauthorization Error\",\n type: \"error\",\n duration: 5000\n });\n // window.location.href = `${baseUrl}session/signin`;\n } else {\n Message({\n message: response.data.Message,\n type: \"error\",\n duration: 5000\n });\n }\n }\n return Promise.reject(error);\n }\n);\nexport default service;\n//# sourceMappingURL=request.js.map\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"cohort-lab app-container\"},[_c('div',{staticClass:\"filter-container\"},[_c('el-select',{staticClass:\"filter-item\",staticStyle:{\"width\":\"220px\"},attrs:{\"autocomplete\":\"\",\"filterable\":\"\",\"placeholder\":\"Cohort\",\"clearable\":\"\"},on:{\"change\":_vm.handleCohortSelection},model:{value:(_vm.cohortId),callback:function ($$v) {_vm.cohortId=$$v},expression:\"cohortId\"}},_vm._l((_vm.cohorts),function(cohort){return _c('el-option',{key:cohort.id,attrs:{\"label\":cohort.name,\"value\":cohort.id}})}),1),_c('el-button',{directives:[{name:\"waves\",rawName:\"v-waves\"}],staticClass:\"filter-item has-margin-left btn-width-12\",attrs:{\"type\":\"primary\",\"icon\":\"el-icon-refresh\"},on:{\"click\":_vm.reloadCohortLabs}},[_vm._v(\"\\n \"+_vm._s(_vm.$t(\"table.refresh\"))+\"\\n \")])],1),_c('el-table',{directives:[{name:\"loading\",rawName:\"v-loading\",value:(_vm.listLoading),expression:\"listLoading\"}],key:_vm.tableKey,staticStyle:{\"width\":\"100%\"},attrs:{\"data\":_vm.paginatedCohortLabs,\"default-sort\":{prop: 'cohort.name', order: 'ascending'},\"max-height\":\"950\",\"border\":\"\",\"fit\":\"\",\"stripe\":\"\",\"highlight-current-row\":\"\"}},[_c('el-table-column',{attrs:{\"type\":\"selection\",\"width\":\"40\"}}),_c('el-table-column',{attrs:{\"label\":\"Cohort\",\"prop\":\"cohort.name\",\"sortable\":\"\",\"min-width\":\"150px\"},scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\nvar row = ref.row;\nreturn [_c('span',{staticClass:\"link-type\",on:{\"click\":function($event){return _vm.handleUpdate(row)}}},[_vm._v(_vm._s(row.cohort.name))])]}}])}),_c('el-table-column',{attrs:{\"label\":\"Lab\",\"prop\":\"lab.displayName\",\"sortable\":\"\",\"min-width\":\"150px\"},scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\nvar row = ref.row;\nreturn [_c('span',{staticClass:\"link-type\",on:{\"click\":function($event){return _vm.handleUpdate(row)}}},[_vm._v(_vm._s(row.lab.displayName))])]}}])}),_c('el-table-column',{attrs:{\"label\":\"Version\",\"min-width\":\"150px\"},scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\nvar row = ref.row;\nreturn [_c('span',{staticClass:\"link-type\",on:{\"click\":function($event){return _vm.handleUpdate(row)}}},[_vm._v(_vm._s(row.lab.version))])]}}])})],1),_c('pagination',{directives:[{name:\"show\",rawName:\"v-show\",value:(_vm.filteredCohortLabs.length > 0),expression:\"filteredCohortLabs.length > 0\"}],attrs:{\"total\":_vm.filteredCohortLabs.length,\"page\":_vm.currentPage,\"limit\":_vm.perPage},on:{\"pagination\":_vm.paginationChange}})],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import request from \"@/utils/request\";\nexport const getCohortLabs = (params) => request({\n url: \"/cohort-labs\",\n method: \"get\",\n params\n});\n//# sourceMappingURL=cohortLabs.js.map","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, Vue } from 'vue-property-decorator'\nimport { CohortModule } from \"@/store/modules/cohort\";\nimport { getCohorts } from \"@/api/cohorts\";\nimport {\n ICohortLab\n} from \"@/api/types\";\nimport { getCohortLabs } from \"@/api/cohortLabs\";\nimport { EventBus } from \"@/utils/eventBus\";\nimport * as moment from 'moment';\nimport Pagination from \"@/components/Pagination/index.vue\";\n\n@Component({\n name: 'CohortLabs',\n components: {Pagination}\n})\nexport default class extends Vue {\n private tableKey = 0;\n private cohortLabs: ICohortLab[] = [];\n private selectedCohortLabs: ICohortLab[] = [];\n private filteredCohortLabs: ICohortLab[] = [];\n private paginatedCohortLabs: ICohortLab[] = [];\n private listLoading = true;\n private total = 0;\n private searchTerm: string = '';\n private cloneDialogVisible: boolean = false;\n private currentPage: number = 1;\n private perPage: number = 20;\n private cohortId: string = '';\n\n created() {\n this.getCohorts();\n this.getCohortLabs()\n EventBus.$on(\"cohort-labs-search\", this.filterBySearch);\n }\n\n destroyed() {\n EventBus.$off(\"cohort-labs-search\", this.filterBySearch);\n }\n\n get cohorts() {\n return CohortModule.cohorts;\n }\n\n private async getCohorts() {\n this.listLoading = true;\n await getCohorts({}).then((response: any) => {\n let data = response.data;\n CohortModule.SetCohorts(data);\n });\n }\n\n private filterBySearch(data: any) {\n this.searchTerm = data.value;\n this.filteredCohortLabs = this.filterBySearchTerm(this.cohortLabs);\n this.paginatedCohortLabs = this.paginateData(this.filteredCohortLabs);\n }\n\n private paginateData(cohortLabs: ICohortLab[]) {\n let start = (this.currentPage - 1) * this.perPage;\n let end = this.currentPage * this.perPage;\n return cohortLabs.slice(start, end);\n }\n\n private filterBySearchTerm(cohortLabs: ICohortLab[]) {\n let targetString: string = \"\";\n if (this.searchTerm != \"\") {\n return cohortLabs.filter((cl: ICohortLab) => {\n if (cl.cohort.name) {\n targetString = `${cl.cohort.name}${cl.lab.displayName}`\n return targetString.toLowerCase().includes(this.searchTerm.toLowerCase())\n }\n return false;\n });\n }\n return cohortLabs;\n }\n\n private async getCohortLabs() {\n this.listLoading = true;\n await getCohortLabs({}).then(\n (response: any) => {\n let data = response.data;\n this.cohortLabs = data;\n this.total = data.length;\n this.filterBySearch({value: ''});\n this.listLoading = false;\n },\n (error: any) => {\n console.log(error);\n this.listLoading = false;\n }\n );\n }\n\n private reloadCohortLabs() {\n this.getCohortLabs()\n }\n\n private handleCohortSelection(data: any) {\n this.getCohortLabs();\n }\n\n private openCloneDialog() {\n this.cloneDialogVisible = true;\n }\n\n private handleUpdate(row: any) {\n\n }\n\n private paginationChange(data: any) {\n this.currentPage = data.page;\n if (this.perPage !== data.limit) {\n this.currentPage = 1;\n this.perPage = data.limit;\n }\n this.filterBySearch({value: this.searchTerm});\n }\n}\n","import mod from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--13-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--13-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./index.vue?vue&type=template&id=3821c390&scoped=true&\"\nimport script from \"./index.vue?vue&type=script&lang=ts&\"\nexport * from \"./index.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./index.vue?vue&type=style&index=0&id=3821c390&lang=scss&scoped=true&\"\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 \"3821c390\",\n null\n \n)\n\nexport default component.exports"],"sourceRoot":""}