openc3-cosmos-tool-cmdtlmserver 5.6.0 → 5.6.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d123e63cd0ccce5b7cb5469bf832bfd6ef5cf23a2f309f1b979fd461d77f47dd
4
- data.tar.gz: 16f21c7feddfbdede75fac83f983d2cddf499c7123852afa10d58ee16a9b55b7
3
+ metadata.gz: f21358bff6da17887d0a4fae2ccd2f69547014727513e561dc1ab8133ee25330
4
+ data.tar.gz: ae65262019834f83a800a4d1a2b1df942b71827f44a523a15cc368b446b49549
5
5
  SHA512:
6
- metadata.gz: 5361f1b3714feff64ade5254eb7d4d54dd303e0685d2091bc0b8c3ad902cb515d8929a4ced2111a71fe5ba21cad3da97ae620c19b42fb9c559fac6f66dfdf9ae
7
- data.tar.gz: 2571dc31726cd2db5281c846fdaeac0ee1e1bafcd7a9c8ea89a0f9ae63a75aaf1d7e466d0b49b81b2fe6ee256e58f4a2044503a5a03d1b62c8ad26d643651ec8
6
+ metadata.gz: 255180ffcd0fd8d7013780cb28944e0a73e02aca39bd8945204d269dbf65f1190199ad4a2897c1806857a367a124316e1367e9fe43bb9896380df45c9fe59f26
7
+ data.tar.gz: 0e3e48b3833ae4d66f3131d6ddd08819087c06c793082b93c9b5800411e5ed2ce3d284fcfa251751e17ae52b0e6ab033112785ee0582a78f7ad5204173923c67
@@ -1,2 +1,2 @@
1
- (self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]=self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]||[]).push([[916],{3916:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return p}});t(7950),t(4908);function a(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",n="6ab0d73706fa7c0dc987925b5fe31277b476ce6e",t=new Function("return this")(),l="__coverage__",s={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",statementMap:{0:{start:{line:1,column:13},end:{line:5,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:4,column:84}},4:{start:{line:1,column:330},end:{line:1,column:344}},5:{start:{line:6,column:22},end:{line:6,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:5,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:314},end:{line:1,column:315}},loc:{start:{line:1,column:329},end:{line:1,column:345}},line:1}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0},f:{0:0,1:0},b:{},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"6ab0d73706fa7c0dc987925b5fe31277b476ce6e"},r=t[l]||(t[l]={});r[e]&&r[e].hash===n||(r[e]=s);var o=r[e];return a=function(){return o},o}a(),a().s[0]++;var l=function(){a().f[0]++;var e=(a().s[1]++,this),n=(a().s[2]++,e._self._c);return a().s[3]++,n("div",[n("v-card",[n("v-card-title",[e._v(" "+e._s(e.data.length)+" Metrics "),n("v-spacer"),n("v-text-field",{attrs:{"append-icon":"mdi-magnify",label:"Search","single-line":"","hide-details":""},model:{value:e.search,callback:function(n){a().f[1]++,a().s[4]++,e.search=n},expression:"search"}})],1),n("v-data-table",{attrs:{headers:e.headers,items:e.data,search:e.search,"items-per-page":10,"footer-props":{itemsPerPageOptions:[10,20,50,100,1e3],showFirstLastPage:!0},"calculate-widths":"","multi-sort":"","data-test":"metrics-table"}})],1)],1)},s=(a().s[5]++,[]),r=t(7302),o=(t(1245),t(5883),t(6728),t(4872)),i=t(8123);function c(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",n="c538a4d97bd8f6141e1539fa3abd7ca8ae091605",t=new Function("return this")(),a="__coverage__",l={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",statementMap:{0:{start:{line:12,column:4},end:{line:35,column:5}},1:{start:{line:39,column:6},end:{line:43,column:7}},2:{start:{line:40,column:8},end:{line:40,column:44}},3:{start:{line:41,column:13},end:{line:43,column:7}},4:{start:{line:42,column:8},end:{line:42,column:43}},5:{start:{line:46,column:6},end:{line:46,column:43}},6:{start:{line:46,column:37},end:{line:46,column:43}},7:{start:{line:47,column:6},end:{line:52,column:8}},8:{start:{line:48,column:8},end:{line:48,column:22}},9:{start:{line:49,column:8},end:{line:51,column:9}},10:{start:{line:50,column:10},end:{line:50,column:60}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:11,column:2},end:{line:11,column:3}},loc:{start:{line:11,column:9},end:{line:36,column:3}},line:11},1:{name:"(anonymous_1)",decl:{start:{line:38,column:4},end:{line:38,column:5}},loc:{start:{line:38,column:29},end:{line:44,column:5}},line:38},2:{name:"(anonymous_2)",decl:{start:{line:45,column:4},end:{line:45,column:5}},loc:{start:{line:45,column:13},end:{line:53,column:5}},line:45},3:{name:"(anonymous_3)",decl:{start:{line:47,column:34},end:{line:47,column:35}},loc:{start:{line:47,column:47},end:{line:52,column:7}},line:47}},branchMap:{0:{loc:{start:{line:39,column:6},end:{line:43,column:7}},type:"if",locations:[{start:{line:39,column:6},end:{line:43,column:7}},{start:{line:41,column:13},end:{line:43,column:7}}],line:39},1:{loc:{start:{line:41,column:13},end:{line:43,column:7}},type:"if",locations:[{start:{line:41,column:13},end:{line:43,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:41},2:{loc:{start:{line:46,column:6},end:{line:46,column:43}},type:"if",locations:[{start:{line:46,column:6},end:{line:46,column:43}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:46}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0},f:{0:0,1:0,2:0,3:0},b:{0:[0,0],1:[0,0],2:[0,0]},inputSourceMap:{version:3,sources:["StatusTab.vue"],names:[],mappings:";AAwDA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"StatusTab.vue",sourceRoot:"src/tools/CmdTlmServer",sourcesContent:["\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <div>\n \x3c!-- Use a container here so we can do cols=\"auto\" to resize v-select --\x3e\n <v-card>\n <v-card-title>\n {{ data.length }} Metrics\n <v-spacer />\n <v-text-field\n v-model=\"search\"\n append-icon=\"mdi-magnify\"\n label=\"Search\"\n single-line\n hide-details\n />\n </v-card-title>\n <v-data-table\n :headers=\"headers\"\n :items=\"data\"\n :search=\"search\"\n :items-per-page=\"10\"\n :footer-props=\"{\n itemsPerPageOptions: [10, 20, 50, 100, 1000],\n showFirstLastPage: true,\n }\"\n calculate-widths\n multi-sort\n data-test=\"metrics-table\"\n >\n </v-data-table>\n </v-card>\n </div>\n</template>\n\n<script>\nimport Updater from './Updater'\nimport { OpenC3Api } from '@openc3/tool-common/src/services/openc3-api'\n\nexport default {\n mixins: [Updater],\n props: {\n tabId: Number,\n curTab: Number,\n },\n data() {\n return {\n api: new OpenC3Api(),\n apiStatus: [],\n apiHeaders: [\n { text: 'Port', value: 'port' },\n { text: 'Clients', value: 'clients' },\n { text: 'Requests', value: 'requests' },\n { text: 'Avg Request Time', value: 'avgTime' },\n { text: 'Server Threads', value: 'threads' },\n ],\n backgroundTasks: [],\n backgroundHeaders: [\n { text: 'Name', value: 'name' },\n { text: 'State', value: 'state' },\n { text: 'Status', value: 'status' },\n { text: 'Control', value: 'control' },\n ],\n search: '',\n data: [],\n headers: [\n { text: 'Metric', value: 'metric_name' },\n { text: 'Value', value: 'value' },\n ],\n }\n },\n methods: {\n taskControl(name, state) {\n if (state == 'Start') {\n this.api.start_background_task(name)\n } else if (state == 'Stop') {\n this.api.stop_background_task(name)\n }\n },\n update() {\n if (this.tabId != this.curTab) return\n this.api.get_metrics().then((metrics) => {\n this.data = []\n for (const [key, value] of Object.entries(metrics)) {\n this.data.push({ metric_name: key, value: value })\n }\n })\n },\n },\n}\n<\/script>\n\n<style scoped>\n.container,\n.theme--dark.v-card,\n.theme--dark.v-sheet {\n background-color: var(--v-tertiary-darken2);\n}\n</style>\n"]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"c538a4d97bd8f6141e1539fa3abd7ca8ae091605"},s=t[a]||(t[a]={});s[e]&&s[e].hash===n||(s[e]=l);var r=s[e];return c=function(){return r},r}c();var u={mixins:[o.Z],props:{tabId:Number,curTab:Number},data:function(){return c().f[0]++,c().s[0]++,{api:new i.k,apiStatus:[],apiHeaders:[{text:"Port",value:"port"},{text:"Clients",value:"clients"},{text:"Requests",value:"requests"},{text:"Avg Request Time",value:"avgTime"},{text:"Server Threads",value:"threads"}],backgroundTasks:[],backgroundHeaders:[{text:"Name",value:"name"},{text:"State",value:"state"},{text:"Status",value:"status"},{text:"Control",value:"control"}],search:"",data:[],headers:[{text:"Metric",value:"metric_name"},{text:"Value",value:"value"}]}},methods:{taskControl:function(e,n){c().f[1]++,c().s[1]++,"Start"==n?(c().b[0][0]++,c().s[2]++,this.api.start_background_task(e)):(c().b[0][1]++,c().s[3]++,"Stop"==n?(c().b[1][0]++,c().s[4]++,this.api.stop_background_task(e)):c().b[1][1]++)},update:function(){var e=this;if(c().f[2]++,c().s[5]++,this.tabId!=this.curTab)return c().b[2][0]++,void c().s[6]++;c().b[2][1]++,c().s[7]++,this.api.get_metrics().then((function(n){c().f[3]++,c().s[8]++,e.data=[],c().s[9]++;for(var t=0,a=Object.entries(n);t<a.length;t++){var l=(0,r.Z)(a[t],2),s=l[0],o=l[1];c().s[10]++,e.data.push({metric_name:s,value:o})}}))}}},d=u,m=(t(460),t(3483)),A=(0,m.Z)(d,l,s,!1,null,"44b09238",null),p=A.exports},5883:function(e,n,t){var a=t(3103),l=t(7664).entries;a({target:"Object",stat:!0},{entries:function(e){return l(e)}})},825:function(e,n,t){"use strict";t.r(n);var a=t(9601),l=t.n(a),s=t(2609),r=t.n(s),o=r()(l());o.push([e.id,".container[data-v-44b09238],.theme--dark.v-card[data-v-44b09238],.theme--dark.v-sheet[data-v-44b09238]{background-color:var(--v-tertiary-darken2)}",""]),n["default"]=o},460:function(e,n,t){var a=t(825);a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals);var l=t(3514).Z;l("5f1a43b8",a,!0,{sourceMap:!1,shadowMode:!1})}}]);
2
- //# sourceMappingURL=916.js.map
1
+ (self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]=self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]||[]).push([[279],{2279:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return p}});t(7950),t(4908);function a(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",n="6ab0d73706fa7c0dc987925b5fe31277b476ce6e",t=new Function("return this")(),l="__coverage__",s={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",statementMap:{0:{start:{line:1,column:13},end:{line:5,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:4,column:84}},4:{start:{line:1,column:330},end:{line:1,column:344}},5:{start:{line:6,column:22},end:{line:6,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:5,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:314},end:{line:1,column:315}},loc:{start:{line:1,column:329},end:{line:1,column:345}},line:1}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0},f:{0:0,1:0},b:{},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"6ab0d73706fa7c0dc987925b5fe31277b476ce6e"},r=t[l]||(t[l]={});r[e]&&r[e].hash===n||(r[e]=s);var o=r[e];return a=function(){return o},o}a(),a().s[0]++;var l=function(){a().f[0]++;var e=(a().s[1]++,this),n=(a().s[2]++,e._self._c);return a().s[3]++,n("div",[n("v-card",[n("v-card-title",[e._v(" "+e._s(e.data.length)+" Metrics "),n("v-spacer"),n("v-text-field",{attrs:{"append-icon":"mdi-magnify",label:"Search","single-line":"","hide-details":""},model:{value:e.search,callback:function(n){a().f[1]++,a().s[4]++,e.search=n},expression:"search"}})],1),n("v-data-table",{attrs:{headers:e.headers,items:e.data,search:e.search,"items-per-page":10,"footer-props":{itemsPerPageOptions:[10,20,50,100,1e3],showFirstLastPage:!0},"calculate-widths":"","multi-sort":"","data-test":"metrics-table"}})],1)],1)},s=(a().s[5]++,[]),r=t(7302),o=(t(1245),t(5883),t(6728),t(4872)),i=t(8123);function c(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",n="c538a4d97bd8f6141e1539fa3abd7ca8ae091605",t=new Function("return this")(),a="__coverage__",l={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue",statementMap:{0:{start:{line:12,column:4},end:{line:35,column:5}},1:{start:{line:39,column:6},end:{line:43,column:7}},2:{start:{line:40,column:8},end:{line:40,column:44}},3:{start:{line:41,column:13},end:{line:43,column:7}},4:{start:{line:42,column:8},end:{line:42,column:43}},5:{start:{line:46,column:6},end:{line:46,column:43}},6:{start:{line:46,column:37},end:{line:46,column:43}},7:{start:{line:47,column:6},end:{line:52,column:8}},8:{start:{line:48,column:8},end:{line:48,column:22}},9:{start:{line:49,column:8},end:{line:51,column:9}},10:{start:{line:50,column:10},end:{line:50,column:60}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:11,column:2},end:{line:11,column:3}},loc:{start:{line:11,column:9},end:{line:36,column:3}},line:11},1:{name:"(anonymous_1)",decl:{start:{line:38,column:4},end:{line:38,column:5}},loc:{start:{line:38,column:29},end:{line:44,column:5}},line:38},2:{name:"(anonymous_2)",decl:{start:{line:45,column:4},end:{line:45,column:5}},loc:{start:{line:45,column:13},end:{line:53,column:5}},line:45},3:{name:"(anonymous_3)",decl:{start:{line:47,column:34},end:{line:47,column:35}},loc:{start:{line:47,column:47},end:{line:52,column:7}},line:47}},branchMap:{0:{loc:{start:{line:39,column:6},end:{line:43,column:7}},type:"if",locations:[{start:{line:39,column:6},end:{line:43,column:7}},{start:{line:41,column:13},end:{line:43,column:7}}],line:39},1:{loc:{start:{line:41,column:13},end:{line:43,column:7}},type:"if",locations:[{start:{line:41,column:13},end:{line:43,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:41},2:{loc:{start:{line:46,column:6},end:{line:46,column:43}},type:"if",locations:[{start:{line:46,column:6},end:{line:46,column:43}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:46}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0},f:{0:0,1:0,2:0,3:0},b:{0:[0,0],1:[0,0],2:[0,0]},inputSourceMap:{version:3,sources:["StatusTab.vue"],names:[],mappings:";AAwDA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"StatusTab.vue",sourceRoot:"src/tools/CmdTlmServer",sourcesContent:["\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <div>\n \x3c!-- Use a container here so we can do cols=\"auto\" to resize v-select --\x3e\n <v-card>\n <v-card-title>\n {{ data.length }} Metrics\n <v-spacer />\n <v-text-field\n v-model=\"search\"\n append-icon=\"mdi-magnify\"\n label=\"Search\"\n single-line\n hide-details\n />\n </v-card-title>\n <v-data-table\n :headers=\"headers\"\n :items=\"data\"\n :search=\"search\"\n :items-per-page=\"10\"\n :footer-props=\"{\n itemsPerPageOptions: [10, 20, 50, 100, 1000],\n showFirstLastPage: true,\n }\"\n calculate-widths\n multi-sort\n data-test=\"metrics-table\"\n >\n </v-data-table>\n </v-card>\n </div>\n</template>\n\n<script>\nimport Updater from './Updater'\nimport { OpenC3Api } from '@openc3/tool-common/src/services/openc3-api'\n\nexport default {\n mixins: [Updater],\n props: {\n tabId: Number,\n curTab: Number,\n },\n data() {\n return {\n api: new OpenC3Api(),\n apiStatus: [],\n apiHeaders: [\n { text: 'Port', value: 'port' },\n { text: 'Clients', value: 'clients' },\n { text: 'Requests', value: 'requests' },\n { text: 'Avg Request Time', value: 'avgTime' },\n { text: 'Server Threads', value: 'threads' },\n ],\n backgroundTasks: [],\n backgroundHeaders: [\n { text: 'Name', value: 'name' },\n { text: 'State', value: 'state' },\n { text: 'Status', value: 'status' },\n { text: 'Control', value: 'control' },\n ],\n search: '',\n data: [],\n headers: [\n { text: 'Metric', value: 'metric_name' },\n { text: 'Value', value: 'value' },\n ],\n }\n },\n methods: {\n taskControl(name, state) {\n if (state == 'Start') {\n this.api.start_background_task(name)\n } else if (state == 'Stop') {\n this.api.stop_background_task(name)\n }\n },\n update() {\n if (this.tabId != this.curTab) return\n this.api.get_metrics().then((metrics) => {\n this.data = []\n for (const [key, value] of Object.entries(metrics)) {\n this.data.push({ metric_name: key, value: value })\n }\n })\n },\n },\n}\n<\/script>\n\n<style scoped>\n.container,\n.theme--dark.v-card,\n.theme--dark.v-sheet {\n background-color: var(--v-tertiary-darken2);\n}\n</style>\n"]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"c538a4d97bd8f6141e1539fa3abd7ca8ae091605"},s=t[a]||(t[a]={});s[e]&&s[e].hash===n||(s[e]=l);var r=s[e];return c=function(){return r},r}c();var u={mixins:[o.Z],props:{tabId:Number,curTab:Number},data:function(){return c().f[0]++,c().s[0]++,{api:new i.k,apiStatus:[],apiHeaders:[{text:"Port",value:"port"},{text:"Clients",value:"clients"},{text:"Requests",value:"requests"},{text:"Avg Request Time",value:"avgTime"},{text:"Server Threads",value:"threads"}],backgroundTasks:[],backgroundHeaders:[{text:"Name",value:"name"},{text:"State",value:"state"},{text:"Status",value:"status"},{text:"Control",value:"control"}],search:"",data:[],headers:[{text:"Metric",value:"metric_name"},{text:"Value",value:"value"}]}},methods:{taskControl:function(e,n){c().f[1]++,c().s[1]++,"Start"==n?(c().b[0][0]++,c().s[2]++,this.api.start_background_task(e)):(c().b[0][1]++,c().s[3]++,"Stop"==n?(c().b[1][0]++,c().s[4]++,this.api.stop_background_task(e)):c().b[1][1]++)},update:function(){var e=this;if(c().f[2]++,c().s[5]++,this.tabId!=this.curTab)return c().b[2][0]++,void c().s[6]++;c().b[2][1]++,c().s[7]++,this.api.get_metrics().then((function(n){c().f[3]++,c().s[8]++,e.data=[],c().s[9]++;for(var t=0,a=Object.entries(n);t<a.length;t++){var l=(0,r.Z)(a[t],2),s=l[0],o=l[1];c().s[10]++,e.data.push({metric_name:s,value:o})}}))}}},d=u,m=(t(8090),t(3287)),A=(0,m.Z)(d,l,s,!1,null,"44b09238",null),p=A.exports},9522:function(e,n,t){"use strict";t.r(n);var a=t(3467),l=t.n(a),s=t(8715),r=t.n(s),o=r()(l());o.push([e.id,".container[data-v-44b09238],.theme--dark.v-card[data-v-44b09238],.theme--dark.v-sheet[data-v-44b09238]{background-color:var(--v-tertiary-darken2)}",""]),n["default"]=o},5883:function(e,n,t){var a=t(3103),l=t(7664).entries;a({target:"Object",stat:!0},{entries:function(e){return l(e)}})},8090:function(e,n,t){var a=t(9522);a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals);var l=t(3514).Z;l("073b130d",a,!0,{sourceMap:!1,shadowMode:!1})}}]);
2
+ //# sourceMappingURL=279.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"js/916.js","mappings":"41CAeY,OAAAA,EAAA,kBAAAC,CAAA,EAAAA,CAAA,CAAAD,IAAAA,IAAAE,EAAA,KAfZ,IAAIC,EAAS,WAAiBH,IAAAI,EAAA,KAAC,IAAIC,GAAGL,IAAAE,EAAA,KAACI,MAAKC,GAAEP,IAAAE,EAAA,KAACG,EAAIG,MAAMD,IAAG,OAAAP,IAAAE,EAAA,KAAOK,EAAG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AA0B,IAA4B,KAE1DA,EAAwBR,KAAK,CAACS,EAAOC,GAAI,qJAAsJ,KAE/L,c,sBCJA,IAAIC,EAAU,EAAQ,KACnBA,EAAQC,aAAYD,EAAUA,EAAQE,SACnB,kBAAZF,IAAsBA,EAAU,CAAC,CAACF,EAAOC,GAAIC,EAAS,MAC7DA,EAAQG,SAAQL,EAAOM,QAAUJ,EAAQG,QAE5C,IAAIE,EAAM,UACGA,EAAI,WAAYL,GAAS,EAAM,CAAC,WAAY,EAAM,YAAa,G","sources":["webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?0c8b","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?7de2","webpack://@openc3/cosmos-tool-cmdtlmserver/../../node_modules/core-js/modules/es.object.entries.js","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?82df","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?b814"],"sourcesContent":["var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',[_c('v-card',[_c('v-card-title',[_vm._v(\" \"+_vm._s(_vm.data.length)+\" Metrics \"),_c('v-spacer'),_c('v-text-field',{attrs:{\"append-icon\":\"mdi-magnify\",\"label\":\"Search\",\"single-line\":\"\",\"hide-details\":\"\"},model:{value:(_vm.search),callback:function ($$v) {_vm.search=$$v},expression:\"search\"}})],1),_c('v-data-table',{attrs:{\"headers\":_vm.headers,\"items\":_vm.data,\"search\":_vm.search,\"items-per-page\":10,\"footer-props\":{\n itemsPerPageOptions: [10, 20, 50, 100, 1000],\n showFirstLastPage: true,\n },\"calculate-widths\":\"\",\"multi-sort\":\"\",\"data-test\":\"metrics-table\"}})],1)],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n-->\n\n<template>\n <div>\n <!-- Use a container here so we can do cols=\"auto\" to resize v-select -->\n <v-card>\n <v-card-title>\n {{ data.length }} Metrics\n <v-spacer />\n <v-text-field\n v-model=\"search\"\n append-icon=\"mdi-magnify\"\n label=\"Search\"\n single-line\n hide-details\n />\n </v-card-title>\n <v-data-table\n :headers=\"headers\"\n :items=\"data\"\n :search=\"search\"\n :items-per-page=\"10\"\n :footer-props=\"{\n itemsPerPageOptions: [10, 20, 50, 100, 1000],\n showFirstLastPage: true,\n }\"\n calculate-widths\n multi-sort\n data-test=\"metrics-table\"\n >\n </v-data-table>\n </v-card>\n </div>\n</template>\n\n<script>\nimport Updater from './Updater'\nimport { OpenC3Api } from '@openc3/tool-common/src/services/openc3-api'\n\nexport default {\n mixins: [Updater],\n props: {\n tabId: Number,\n curTab: Number,\n },\n data() {\n return {\n api: new OpenC3Api(),\n apiStatus: [],\n apiHeaders: [\n { text: 'Port', value: 'port' },\n { text: 'Clients', value: 'clients' },\n { text: 'Requests', value: 'requests' },\n { text: 'Avg Request Time', value: 'avgTime' },\n { text: 'Server Threads', value: 'threads' },\n ],\n backgroundTasks: [],\n backgroundHeaders: [\n { text: 'Name', value: 'name' },\n { text: 'State', value: 'state' },\n { text: 'Status', value: 'status' },\n { text: 'Control', value: 'control' },\n ],\n search: '',\n data: [],\n headers: [\n { text: 'Metric', value: 'metric_name' },\n { text: 'Value', value: 'value' },\n ],\n }\n },\n methods: {\n taskControl(name, state) {\n if (state == 'Start') {\n this.api.start_background_task(name)\n } else if (state == 'Stop') {\n this.api.stop_background_task(name)\n }\n },\n update() {\n if (this.tabId != this.curTab) return\n this.api.get_metrics().then((metrics) => {\n this.data = []\n for (const [key, value] of Object.entries(metrics)) {\n this.data.push({ metric_name: key, value: value })\n }\n })\n },\n },\n}\n</script>\n\n<style scoped>\n.container,\n.theme--dark.v-card,\n.theme--dark.v-sheet {\n background-color: var(--v-tertiary-darken2);\n}\n</style>\n","import mod from \"-!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./StatusTab.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./StatusTab.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./StatusTab.vue?vue&type=template&id=44b09238&scoped=true&\"\nimport script from \"./StatusTab.vue?vue&type=script&lang=js&\"\nexport * from \"./StatusTab.vue?vue&type=script&lang=js&\"\nimport style0 from \"./StatusTab.vue?vue&type=style&index=0&id=44b09238&prod&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../node_modules/@vue/vue-loader-v15/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"44b09238\",\n null\n \n)\n\nexport default component.exports","var $ = require('../internals/export');\nvar $entries = require('../internals/object-to-array').entries;\n\n// `Object.entries` method\n// https://tc39.es/ecma262/#sec-object.entries\n$({ target: 'Object', stat: true }, {\n entries: function entries(O) {\n return $entries(O);\n }\n});\n","// Imports\nimport ___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___ from \"../../../../../node_modules/css-loader/dist/runtime/noSourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".container[data-v-44b09238],.theme--dark.v-card[data-v-44b09238],.theme--dark.v-sheet[data-v-44b09238]{background-color:var(--v-tertiary-darken2)}\", \"\"]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!../../../../../node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!../../../../../node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[3]!../../../../../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./StatusTab.vue?vue&type=style&index=0&id=44b09238&prod&scoped=true&lang=css&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"5f1a43b8\", content, true, {\"sourceMap\":false,\"shadowMode\":false});"],"names":["cov_2ntlonrahl","actualCoverage","s","render","f","_vm","this","_c","_self","_v","_s","data","length","attrs","model","value","search","callback","$$v","expression","headers","itemsPerPageOptions","showFirstLastPage","staticRenderFns","mixins","Updater","props","tabId","Number","curTab","api","OpenC3Api","apiStatus","apiHeaders","text","backgroundTasks","backgroundHeaders","methods","taskControl","name","state","b","start_background_task","stop_background_task","update","_this","get_metrics","then","metrics","_i","_Object$entries","Object","entries","_Object$entries$_i","_slicedToArray","key","push","metric_name","component","$","$entries","target","stat","O","___CSS_LOADER_EXPORT___","module","id","content","__esModule","default","locals","exports","add"],"sourceRoot":""}
1
+ {"version":3,"file":"js/279.js","mappings":"41CAeY,OAAAA,EAAA,kBAAAC,CAAA,EAAAA,CAAA,CAAAD,IAAAA,IAAAE,EAAA,KAfZ,IAAIC,EAAS,WAAiBH,IAAAI,EAAA,KAAC,IAAIC,GAAGL,IAAAE,EAAA,KAACI,MAAKC,GAAEP,IAAAE,EAAA,KAACG,EAAIG,MAAMD,IAAG,OAAAP,IAAAE,EAAA,KAAOK,EAAG,MAAM,CAACA,EAAG,SAAS,CAACA,EAAG,eAAe,CAACF,EAAII,GAAG,IAAIJ,EAAIK,GAAGL,EAAIM,KAAKC,QAAQ,aAAaL,EAAG,YAAYA,EAAG,eAAe,CAACM,MAAM,CAAC,cAAc,cAAc,MAAQ,SAAS,cAAc,GAAG,eAAe,IAAIC,MAAM,CAACC,MAAOV,EAAIW,OAAQC,SAAS,SAAUC,GAAKlB,IAAAI,EAAA,KAAAJ,IAAAE,EAAA,KAACG,EAAIW,OAAOE,CAAG,EAAEC,WAAW,aAAa,GAAGZ,EAAG,eAAe,CAACM,MAAM,CAAC,QAAUR,EAAIe,QAAQ,MAAQf,EAAIM,KAAK,OAASN,EAAIW,OAAO,iBAAiB,GAAG,eAAe,CACreK,oBAAqB,CAAC,GAAI,GAAI,GAAI,IAAK,KACvCC,mBAAmB,GACnB,mBAAmB,GAAG,aAAa,GAAG,YAAY,oBAAoB,IAAI,EAClF,EACIC,GAAevB,IAAAE,EAAA,KAAG,I,mgMCiEtB,OAAAF,EAAA,kBAAAC,CAAA,EAAAA,CAAA,CAAAD,IAXA,OACAwB,OAAA,CAAAC,EAAAA,GACAC,MAAA,CACAC,MAAAC,OACAC,OAAAD,QAEAjB,KAAA,WACA,OADAX,IAAAI,E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AAAtC,OAAAqC,IAAA,KAAAI,GAAAC,EAAAA,EAAAA,GAAAJ,EAAAD,GAAA,GAAAM,EAAAF,EAAA,GAAAtC,EAAAsC,EAAA,GAAArD,IAAAE,EAAA,MACA2C,EAAAlC,KAAA6C,KAAA,CAAAC,YAAAF,EAAAxC,MAAAA,GACA,CACA,GACA,IC3GwX,I,oBCQpX2C,GAAY,OACd,EACAvD,EACAoB,GACA,EACA,KACA,WACA,MAIF,EAAemC,EAAiB,O,qFChB5BC,EAA0B,IAA4B,KAE1DA,EAAwBH,KAAK,CAACI,EAAOC,GAAI,qJAAsJ,KAE/L,c,uBCPA,IAAIC,EAAI,EAAQ,MACZC,EAAW,gBAIfD,EAAE,CAAEE,OAAQ,SAAUC,MAAM,GAAQ,CAClCb,QAAS,SAAiBc,GACxB,OAAOH,EAASG,EAClB,G,uBCLF,IAAIC,EAAU,EAAQ,MACnBA,EAAQC,aAAYD,EAAUA,EAAQE,SACnB,kBAAZF,IAAsBA,EAAU,CAAC,CAACP,EAAOC,GAAIM,EAAS,MAC7DA,EAAQG,SAAQV,EAAOW,QAAUJ,EAAQG,QAE5C,IAAIE,EAAM,UACGA,EAAI,WAAYL,GAAS,EAAM,CAAC,WAAY,EAAM,YAAa,G","sources":["webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/StatusTab.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?6aa1","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?8ed3","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?1790","webpack://@openc3/cosmos-tool-cmdtlmserver/../../node_modules/core-js/modules/es.object.entries.js","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/StatusTab.vue?ca72"],"sourcesContent":["var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',[_c('v-card',[_c('v-card-title',[_vm._v(\" \"+_vm._s(_vm.data.length)+\" Metrics \"),_c('v-spacer'),_c('v-text-field',{attrs:{\"append-icon\":\"mdi-magnify\",\"label\":\"Search\",\"single-line\":\"\",\"hide-details\":\"\"},model:{value:(_vm.search),callback:function ($$v) {_vm.search=$$v},expression:\"search\"}})],1),_c('v-data-table',{attrs:{\"headers\":_vm.headers,\"items\":_vm.data,\"search\":_vm.search,\"items-per-page\":10,\"footer-props\":{\n itemsPerPageOptions: [10, 20, 50, 100, 1000],\n showFirstLastPage: true,\n },\"calculate-widths\":\"\",\"multi-sort\":\"\",\"data-test\":\"metrics-table\"}})],1)],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n-->\n\n<template>\n <div>\n <!-- Use a container here so we can do cols=\"auto\" to resize v-select -->\n <v-card>\n <v-card-title>\n {{ data.length }} Metrics\n <v-spacer />\n <v-text-field\n v-model=\"search\"\n append-icon=\"mdi-magnify\"\n label=\"Search\"\n single-line\n hide-details\n />\n </v-card-title>\n <v-data-table\n :headers=\"headers\"\n :items=\"data\"\n :search=\"search\"\n :items-per-page=\"10\"\n :footer-props=\"{\n itemsPerPageOptions: [10, 20, 50, 100, 1000],\n showFirstLastPage: true,\n }\"\n calculate-widths\n multi-sort\n data-test=\"metrics-table\"\n >\n </v-data-table>\n </v-card>\n </div>\n</template>\n\n<script>\nimport Updater from './Updater'\nimport { OpenC3Api } from '@openc3/tool-common/src/services/openc3-api'\n\nexport default {\n mixins: [Updater],\n props: {\n tabId: Number,\n curTab: Number,\n },\n data() {\n return {\n api: new OpenC3Api(),\n apiStatus: [],\n apiHeaders: [\n { text: 'Port', value: 'port' },\n { text: 'Clients', value: 'clients' },\n { text: 'Requests', value: 'requests' },\n { text: 'Avg Request Time', value: 'avgTime' },\n { text: 'Server Threads', value: 'threads' },\n ],\n backgroundTasks: [],\n backgroundHeaders: [\n { text: 'Name', value: 'name' },\n { text: 'State', value: 'state' },\n { text: 'Status', value: 'status' },\n { text: 'Control', value: 'control' },\n ],\n search: '',\n data: [],\n headers: [\n { text: 'Metric', value: 'metric_name' },\n { text: 'Value', value: 'value' },\n ],\n }\n },\n methods: {\n taskControl(name, state) {\n if (state == 'Start') {\n this.api.start_background_task(name)\n } else if (state == 'Stop') {\n this.api.stop_background_task(name)\n }\n },\n update() {\n if (this.tabId != this.curTab) return\n this.api.get_metrics().then((metrics) => {\n this.data = []\n for (const [key, value] of Object.entries(metrics)) {\n this.data.push({ metric_name: key, value: value })\n }\n })\n },\n },\n}\n</script>\n\n<style scoped>\n.container,\n.theme--dark.v-card,\n.theme--dark.v-sheet {\n background-color: var(--v-tertiary-darken2);\n}\n</style>\n","import mod from \"-!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./StatusTab.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./StatusTab.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./StatusTab.vue?vue&type=template&id=44b09238&scoped=true&\"\nimport script from \"./StatusTab.vue?vue&type=script&lang=js&\"\nexport * from \"./StatusTab.vue?vue&type=script&lang=js&\"\nimport style0 from \"./StatusTab.vue?vue&type=style&index=0&id=44b09238&prod&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"44b09238\",\n null\n \n)\n\nexport default component.exports","// Imports\nimport ___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___ from \"../../../../../node_modules/@vue/cli-service/node_modules/css-loader/dist/runtime/noSourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../../node_modules/@vue/cli-service/node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".container[data-v-44b09238],.theme--dark.v-card[data-v-44b09238],.theme--dark.v-sheet[data-v-44b09238]{background-color:var(--v-tertiary-darken2)}\", \"\"]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","var $ = require('../internals/export');\nvar $entries = require('../internals/object-to-array').entries;\n\n// `Object.entries` method\n// https://tc39.es/ecma262/#sec-object.entries\n$({ target: 'Object', stat: true }, {\n entries: function entries(O) {\n return $entries(O);\n }\n});\n","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../node_modules/@vue/cli-service/node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!../../../../../node_modules/@vue/cli-service/node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!../../../../../node_modules/@vue/cli-service/node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[3]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./StatusTab.vue?vue&type=style&index=0&id=44b09238&prod&scoped=true&lang=css&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"073b130d\", content, true, {\"sourceMap\":false,\"shadowMode\":false});"],"names":["cov_2ntlonrahl","actualCoverage","s","render","f","_vm","this","_c","_self","_v","_s","data","length","attrs","model","value","search","callback","$$v","expression","headers","itemsPerPageOptions","showFirstLastPage","staticRenderFns","mixins","Updater","props","tabId","Number","curTab","api","OpenC3Api","apiStatus","apiHeaders","text","backgroundTasks","backgroundHeaders","methods","taskControl","name","state","b","start_background_task","stop_background_task","update","_this","get_metrics","then","metrics","_i","_Object$entries","Object","entries","_Object$entries$_i","_slicedToArray","key","push","metric_name","component","___CSS_LOADER_EXPORT___","module","id","$","$entries","target","stat","O","content","__esModule","default","locals","exports","add"],"sourceRoot":""}
@@ -1,2 +1,2 @@
1
- (self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]=self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]||[]).push([[320],{1320:function(n,e,t){"use strict";t.d(e,{Z:function(){return A}});t(4083);function l(){var n="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",e="853a91e0ae78f53288b053e75c6209d163e3e6d4",t=new Function("return this")(),i="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",statementMap:{0:{start:{line:1,column:13},end:{line:2,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:1,column:2136}},4:{start:{line:1,column:137},end:{line:1,column:241}},5:{start:{line:1,column:229},end:{line:1,column:241}},6:{start:{line:1,column:241},end:{line:1,column:262}},7:{start:{line:1,column:319},end:{line:1,column:336}},8:{start:{line:1,column:493},end:{line:1,column:662}},9:{start:{line:1,column:874},end:{line:1,column:1042}},10:{start:{line:1,column:1268},end:{line:1,column:1463}},11:{start:{line:1,column:2084},end:{line:1,column:2099}},12:{start:{line:3,column:22},end:{line:3,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:2,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:120},end:{line:1,column:121}},loc:{start:{line:1,column:136},end:{line:1,column:263}},line:1},2:{name:"(anonymous_2)",decl:{start:{line:1,column:303},end:{line:1,column:304}},loc:{start:{line:1,column:318},end:{line:1,column:337}},line:1},3:{name:"(anonymous_3)",decl:{start:{line:1,column:469},end:{line:1,column:470}},loc:{start:{line:1,column:492},end:{line:1,column:663}},line:1},4:{name:"(anonymous_4)",decl:{start:{line:1,column:850},end:{line:1,column:851}},loc:{start:{line:1,column:873},end:{line:1,column:1043}},line:1},5:{name:"(anonymous_5)",decl:{start:{line:1,column:1244},end:{line:1,column:1245}},loc:{start:{line:1,column:1267},end:{line:1,column:1464}},line:1},6:{name:"(anonymous_6)",decl:{start:{line:1,column:2068},end:{line:1,column:2069}},loc:{start:{line:1,column:2083},end:{line:1,column:2100}},line:1}},branchMap:{0:{loc:{start:{line:1,column:137},end:{line:1,column:241}},type:"if",locations:[{start:{line:1,column:137},end:{line:1,column:241}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:1},1:{loc:{start:{line:1,column:140},end:{line:1,column:228}},type:"binary-expr",locations:[{start:{line:1,column:140},end:{line:1,column:167}},{start:{line:1,column:169},end:{line:1,column:228}}],line:1}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},b:{0:[0,0],1:[0,0]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"853a91e0ae78f53288b053e75c6209d163e3e6d4"},a=t[i]||(t[i]={});a[n]&&a[n].hash===e||(a[n]=o);var c=a[n];return l=function(){return c},c}l(),l().s[0]++;var i=function(){l().f[0]++;var n=(l().s[1]++,this),e=(l().s[2]++,n._self._c);return l().s[3]++,e("v-dialog",{attrs:{width:"790px"},on:{keydown:function(e){if(l().f[1]++,l().s[4]++,l().b[1][0]++,!e.type.indexOf("key")&&(l().b[1][1]++,n._k(e.keyCode,"esc",27,e.key,["Esc","Escape"])))return l().b[0][0]++,l().s[5]++,null;l().b[0][1]++,l().s[6]++,n.isVisible=!1}},model:{value:n.isVisible,callback:function(e){l().f[2]++,l().s[7]++,n.isVisible=e},expression:"isVisible"}},[e("v-card",[e("v-system-bar",[e("v-tooltip",{attrs:{top:""},scopedSlots:n._u([{key:"activator",fn:function(t){var i=t.on,o=t.attrs;return l().f[3]++,l().s[8]++,[e("div",n._g(n._b({},"div",o,!1),i),[e("v-icon",{attrs:{"data-test":"copy-icon"},on:{click:n.copyRawData}},[n._v(" mdi-content-copy ")])],1)]}}])},[e("span",[n._v(" Copy ")])]),e("v-spacer"),e("span",[n._v(" "+n._s(n.type)+" ")]),e("v-spacer"),e("v-tooltip",{attrs:{top:""},scopedSlots:n._u([{key:"activator",fn:function(t){var i=t.on,o=t.attrs;return l().f[4]++,l().s[9]++,[e("div",n._g(n._b({},"div",o,!1),i),[e("v-icon",{attrs:{"data-test":"download"},on:{click:n.downloadRawData}},[n._v(" mdi-download ")])],1)]}}])},[e("span",[n._v(" Download ")])])],1),e("v-card-title",[e("span",[n._v(" "+n._s(n.header)+" ")]),e("v-spacer"),e("v-tooltip",{attrs:{top:""},scopedSlots:n._u([{key:"activator",fn:function(t){var i=t.on,o=t.attrs;return l().f[5]++,l().s[10]++,[e("div",n._g(n._b({},"div",o,!1),i),[e("v-btn",{attrs:{icon:"","data-test":"pause"},on:{click:n.pause}},[e("v-icon",[n._v(" "+n._s(n.buttonIcon)+" ")])],1)],1)]}}])},[e("span",[n._v(" "+n._s(n.buttonLabel)+" ")])])],1),e("v-card-text",[e("v-row",{attrs:{dense:""}},[e("v-col",{attrs:{cols:"4"}},[e("span",[n._v(" Received Time: ")])]),e("v-col",{staticClass:"text-right"},[e("span",[n._v(" "+n._s(n.receivedTime)+" ")])])],1),e("v-row",{attrs:{dense:""}},[e("v-col",{attrs:{cols:"4"}},[e("span",[n._v(" Count: ")])]),e("v-col",{staticClass:"text-right"},[e("span",[n._v(" "+n._s(n.receivedCount)+" ")])])],1),e("v-textarea",{staticClass:"pa-0 ma-0",attrs:{"auto-grow":"",readonly:""},model:{value:n.rawData,callback:function(e){l().f[6]++,l().s[11]++,n.rawData=e},expression:"rawData"}})],1)],1)],1)},o=(l().s[12]++,[]),a=(t(8178),t(8188),t(8673),t(6886),t(4121),t(523),t(1939),t(7789),t(8233),t(9413)),c=t(4872);function s(){var n="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",e="5089fec28d4524bf316ed8efca2d3374b5072eee",t=new Function("return this")(),l="__coverage__",i={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",statementMap:{0:{start:{line:15,column:4},end:{line:21,column:5}},1:{start:{line:25,column:6},end:{line:29,column:7}},2:{start:{line:26,column:8},end:{line:26,column:23}},3:{start:{line:28,column:8},end:{line:28,column:22}},4:{start:{line:32,column:6},end:{line:36,column:7}},5:{start:{line:33,column:8},end:{line:33,column:25}},6:{start:{line:35,column:8},end:{line:35,column:26}},7:{start:{line:40,column:8},end:{line:40,column:27}},8:{start:{line:44,column:8},end:{line:44,column:24}},9:{start:{line:45,column:8},end:{line:45,column:30}},10:{start:{line:46,column:8},end:{line:46,column:25}},11:{start:{line:47,column:8},end:{line:47,column:31}},12:{start:{line:48,column:8},end:{line:48,column:27}},13:{start:{line:49,column:8},end:{line:49,column:34}},14:{start:{line:50,column:8},end:{line:50,column:35}},15:{start:{line:56,column:6},end:{line:56,column:113}},16:{start:{line:59,column:6},end:{line:59,column:56}},17:{start:{line:62,column:19},end:{line:64,column:8}},18:{start:{line:66,column:19},end:{line:66,column:46}},19:{start:{line:67,column:6},end:{line:67,column:43}},20:{start:{line:68,column:17},end:{line:68,column:58}},21:{start:{line:69,column:6},end:{line:72,column:7}},22:{start:{line:73,column:6},end:{line:73,column:18}},23:{start:{line:76,column:6},end:{line:76,column:32}},24:{start:{line:79,column:6},end:{line:79,column:48}},25:{start:{line:79,column:42},end:{line:79,column:48}},26:{start:{line:80,column:6},end:{line:80,column:84}},27:{start:{line:82,column:6},end:{line:86,column:7}},28:{start:{line:83,column:8},end:{line:83,column:30}},29:{start:{line:85,column:8},end:{line:85,column:28}},30:{start:{line:89,column:6},end:{line:105,column:10}},31:{start:{line:92,column:28},end:{line:92,column:41}},32:{start:{line:93,column:10},end:{line:98,column:11}},33:{start:{line:94,column:12},end:{line:94,column:41}},34:{start:{line:96,column:29},end:{line:96,column:46}},35:{start:{line:97,column:12},end:{line:97,column:56}},36:{start:{line:99,column:10},end:{line:99,column:61}},37:{start:{line:100,column:10},end:{line:100,column:52}},38:{start:{line:101,column:10},end:{line:104,column:42}},39:{start:{line:108,column:6},end:{line:124,column:10}},40:{start:{line:111,column:28},end:{line:111,column:41}},41:{start:{line:112,column:10},end:{line:117,column:11}},42:{start:{line:113,column:12},end:{line:113,column:41}},43:{start:{line:115,column:29},end:{line:115,column:46}},44:{start:{line:116,column:12},end:{line:116,column:56}},45:{start:{line:118,column:10},end:{line:118,column:61}},46:{start:{line:119,column:10},end:{line:119,column:52}},47:{start:{line:120,column:10},end:{line:123,column:42}},48:{start:{line:128,column:19},end:{line:128,column:21}},49:{start:{line:129,column:18},end:{line:129,column:19}},50:{start:{line:130,column:18},end:{line:130,column:20}},51:{start:{line:131,column:6},end:{line:152,column:8}},52:{start:{line:132,column:8},end:{line:134,column:9}},53:{start:{line:133,column:10},end:{line:133,column:48}},54:{start:{line:135,column:8},end:{line:135,column:35}},55:{start:{line:138,column:8},end:{line:142,column:9}},56:{start:{line:139,column:10},end:{line:139,column:44}},57:{start:{line:141,column:10},end:{line:141,column:22}},58:{start:{line:144,column:8},end:{line:144,column:15}},59:{start:{line:146,column:8},end:{line:151,column:9}},60:{start:{line:147,column:10},end:{line:147,column:39}},61:{start:{line:148,column:10},end:{line:148,column:20}},62:{start:{line:150,column:10},end:{line:150,column:23}},63:{start:{line:157,column:6},end:{line:163,column:7}},64:{start:{line:158,column:30},end:{line:158,column:65}},65:{start:{line:160,column:21},end:{line:160,column:53}},66:{start:{line:161,column:27},end:{line:161,column:56}},67:{start:{line:162,column:8},end:{line:162,column:54}},68:{start:{line:164,column:6},end:{line:164,column:19}},69:{start:{line:167,column:16},end:{line:167,column:32}},70:{start:{line:168,column:6},end:{line:168,column:49}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:9},end:{line:22,column:3}},line:14},1:{name:"(anonymous_1)",decl:{start:{line:24,column:17},end:{line:24,column:18}},loc:{start:{line:24,column:29},end:{line:30,column:5}},line:24},2:{name:"(anonymous_2)",decl:{start:{line:31,column:16},end:{line:31,column:17}},loc:{start:{line:31,column:28},end:{line:37,column:5}},line:31},3:{name:"(anonymous_3)",decl:{start:{line:39,column:11},end:{line:39,column:12}},loc:{start:{line:39,column:23},end:{line:41,column:7}},line:39},4:{name:"(anonymous_4)",decl:{start:{line:43,column:11},end:{line:43,column:12}},loc:{start:{line:43,column:27},end:{line:51,column:7}},line:43},5:{name:"(anonymous_5)",decl:{start:{line:55,column:18},end:{line:55,column:19}},loc:{start:{line:55,column:30},end:{line:57,column:5}},line:55},6:{name:"(anonymous_6)",decl:{start:{line:58,column:17},end:{line:58,column:18}},loc:{start:{line:58,column:29},end:{line:60,column:5}},line:58},7:{name:"(anonymous_7)",decl:{start:{line:61,column:21},end:{line:61,column:22}},loc:{start:{line:61,column:33},end:{line:74,column:5}},line:61},8:{name:"(anonymous_8)",decl:{start:{line:75,column:11},end:{line:75,column:12}},loc:{start:{line:75,column:23},end:{line:77,column:5}},line:75},9:{name:"(anonymous_9)",decl:{start:{line:78,column:12},end:{line:78,column:13}},loc:{start:{line:78,column:24},end:{line:87,column:5}},line:78},10:{name:"(anonymous_10)",decl:{start:{line:88,column:21},end:{line:88,column:22}},loc:{start:{line:88,column:33},end:{line:106,column:5}},line:88},11:{name:"(anonymous_11)",decl:{start:{line:91,column:14},end:{line:91,column:15}},loc:{start:{line:91,column:26},end:{line:105,column:9}},line:91},12:{name:"(anonymous_12)",decl:{start:{line:107,column:19},end:{line:107,column:20}},loc:{start:{line:107,column:31},end:{line:125,column:5}},line:107},13:{name:"(anonymous_13)",decl:{start:{line:110,column:14},end:{line:110,column:15}},loc:{start:{line:110,column:26},end:{line:124,column:9}},line:110},14:{name:"(anonymous_14)",decl:{start:{line:127,column:18},end:{line:127,column:19}},loc:{start:{line:127,column:36},end:{line:165,column:5}},line:127},15:{name:"(anonymous_15)",decl:{start:{line:131,column:21},end:{line:131,column:22}},loc:{start:{line:131,column:31},end:{line:152,column:7}},line:131},16:{name:"(anonymous_16)",decl:{start:{line:166,column:4},end:{line:166,column:5}},loc:{start:{line:166,column:27},end:{line:169,column:5}},line:166}},branchMap:{0:{loc:{start:{line:25,column:6},end:{line:29,column:7}},type:"if",locations:[{start:{line:25,column:6},end:{line:29,column:7}},{start:{line:27,column:13},end:{line:29,column:7}}],line:25},1:{loc:{start:{line:32,column:6},end:{line:36,column:7}},type:"if",locations:[{start:{line:32,column:6},end:{line:36,column:7}},{start:{line:34,column:13},end:{line:36,column:7}}],line:32},2:{loc:{start:{line:79,column:6},end:{line:79,column:48}},type:"if",locations:[{start:{line:79,column:6},end:{line:79,column:48}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:79},3:{loc:{start:{line:79,column:10},end:{line:79,column:40}},type:"binary-expr",locations:[{start:{line:79,column:10},end:{line:79,column:25}},{start:{line:79,column:29},end:{line:79,column:40}}],line:79},4:{loc:{start:{line:82,column:6},end:{line:86,column:7}},type:"if",locations:[{start:{line:82,column:6},end:{line:86,column:7}},{start:{line:84,column:13},end:{line:86,column:7}}],line:82},5:{loc:{start:{line:93,column:10},end:{line:98,column:11}},type:"if",locations:[{start:{line:93,column:10},end:{line:98,column:11}},{start:{line:95,column:17},end:{line:98,column:11}}],line:93},6:{loc:{start:{line:112,column:10},end:{line:117,column:11}},type:"if",locations:[{start:{line:112,column:10},end:{line:117,column:11}},{start:{line:114,column:17},end:{line:117,column:11}}],line:112},7:{loc:{start:{line:132,column:8},end:{line:134,column:9}},type:"if",locations:[{start:{line:132,column:8},end:{line:134,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:132},8:{loc:{start:{line:138,column:8},end:{line:142,column:9}},type:"if",locations:[{start:{line:138,column:8},end:{line:142,column:9}},{start:{line:140,column:15},end:{line:142,column:9}}],line:138},9:{loc:{start:{line:138,column:12},end:{line:138,column:37}},type:"binary-expr",locations:[{start:{line:138,column:12},end:{line:138,column:22}},{start:{line:138,column:26},end:{line:138,column:37}}],line:138},10:{loc:{start:{line:146,column:8},end:{line:151,column:9}},type:"if",locations:[{start:{line:146,column:8},end:{line:151,column:9}},{start:{line:149,column:15},end:{line:151,column:9}}],line:146},11:{loc:{start:{line:157,column:6},end:{line:163,column:7}},type:"if",locations:[{start:{line:157,column:6},end:{line:163,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:157},12:{loc:{start:{line:166,column:16},end:{line:166,column:25}},type:"default-arg",locations:[{start:{line:166,column:24},end:{line:166,column:25}}],line:166}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0]},inputSourceMap:{version:3,sources:["RawDialog.vue"],names:[],mappings:";AAwFA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"RawDialog.vue",sourceRoot:"src/tools/CmdTlmServer",sourcesContent:["\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license \n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <v-dialog v-model=\"isVisible\" @keydown.esc=\"isVisible = false\" width=\"790px\">\n <v-card>\n <v-system-bar>\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"copy-icon\" @click=\"copyRawData\">\n mdi-content-copy\n </v-icon>\n </div>\n </template>\n <span> Copy </span>\n </v-tooltip>\n <v-spacer />\n <span> {{ type }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"download\" @click=\"downloadRawData\">\n mdi-download\n </v-icon>\n </div>\n </template>\n <span> Download </span>\n </v-tooltip>\n </v-system-bar>\n <v-card-title>\n <span> {{ header }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-btn icon data-test=\"pause\" @click=\"pause\">\n <v-icon> {{ buttonIcon }} </v-icon>\n </v-btn>\n </div>\n </template>\n <span> {{ buttonLabel }} </span>\n </v-tooltip>\n </v-card-title>\n <v-card-text>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Received Time: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedTime }} </span>\n </v-col>\n </v-row>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Count: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedCount }} </span>\n </v-col>\n </v-row>\n <v-textarea v-model=\"rawData\" class=\"pa-0 ma-0\" auto-grow readonly />\n </v-card-text>\n </v-card>\n </v-dialog>\n</template>\n\n<script>\nimport { format } from 'date-fns'\n\nimport Updater from './Updater'\n\nexport default {\n mixins: [Updater],\n props: {\n type: String,\n visible: Boolean,\n targetName: String,\n packetName: String,\n },\n data() {\n return {\n header: '',\n receivedTime: '',\n rawData: '',\n paused: false,\n receivedCount: '',\n }\n },\n computed: {\n buttonLabel: function () {\n if (this.paused) {\n return 'Resume'\n } else {\n return 'Pause'\n }\n },\n buttonIcon: function () {\n if (this.paused) {\n return 'mdi-play'\n } else {\n return 'mdi-pause'\n }\n },\n isVisible: {\n get: function () {\n return this.visible\n },\n // Reset all the data to defaults\n set: function (bool) {\n this.header = ''\n this.receivedTime = ''\n this.rawData = ''\n this.receivedCount = ''\n this.paused = false\n this.buttonLabel = 'Pause'\n this.$emit('display', bool)\n },\n },\n },\n methods: {\n buildRawData: function () {\n return `${this.header}\\nReceived Time: ${this.receivedTime}\\nCount: ${this.receivedCount}\\n${this.rawData}`\n },\n copyRawData: function () {\n navigator.clipboard.writeText(this.buildRawData())\n },\n downloadRawData: function () {\n const blob = new Blob([this.buildRawData()], {\n type: 'plain/text',\n })\n // Make a link and then 'click' on it to start the download\n const link = document.createElement('a')\n link.href = URL.createObjectURL(blob)\n const dt = format(Date.now(), 'yyyy_MM_dd_HH_mm_ss')\n link.setAttribute(\n 'download',\n `${dt}_${this.targetName}_${this.packetName}.txt`\n )\n link.click()\n },\n pause: function () {\n this.paused = !this.paused\n },\n update: function () {\n if (!this.isVisible || this.paused) return\n this.header = `Raw ${this.type} Packet: ${this.targetName} ${this.packetName}`\n\n if (this.type === 'Telemetry') {\n this.updateTelemetry()\n } else {\n this.updateCommand()\n }\n },\n updateTelemetry: function () {\n this.api\n .get_tlm_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n updateCommand: function () {\n this.api\n .get_cmd_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n // TODO: Perhaps move this to a utility library\n formatBuffer: function (buffer) {\n var string = ''\n var index = 0\n var ascii = ''\n buffer.forEach((byte) => {\n if (index % 16 === 0) {\n string += this.numHex(index, 8) + ': '\n }\n string += this.numHex(byte)\n\n // Create the ASCII representation if printable\n if (byte >= 32 && byte <= 126) {\n ascii += String.fromCharCode(byte)\n } else {\n ascii += ' '\n }\n\n index++\n\n if (index % 16 === 0) {\n string += ' ' + ascii + '\\n'\n ascii = ''\n } else {\n string += ' '\n }\n })\n\n // We're done printing all the bytes. Now check to see if we ended in the\n // middle of a line. If so we have to print out the final ASCII if\n // requested.\n if (index % 16 != 0) {\n var existing_length = (index % 16) - 1 + (index % 16) * 2\n // 47 is (16 * 2) + 15 separator spaces\n var filler = ' '.repeat(47 - existing_length)\n var ascii_filler = ' '.repeat(16 - ascii.length)\n string += filler + ' ' + ascii + ascii_filler\n }\n return string\n },\n numHex(num, width = 2) {\n var hex = num.toString(16)\n return '0'.repeat(width - hex.length) + hex\n },\n },\n}\n<\/script>\n<style scoped>\n.v-textarea :deep(textarea) {\n margin-top: 10px;\n font-family: 'Courier New', Courier, monospace;\n}\n</style>\n"]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"5089fec28d4524bf316ed8efca2d3374b5072eee"},o=t[l]||(t[l]={});o[n]&&o[n].hash===e||(o[n]=i);var a=o[n];return s=function(){return a},a}s();var u={mixins:[c.Z],props:{type:String,visible:Boolean,targetName:String,packetName:String},data:function(){return s().f[0]++,s().s[0]++,{header:"",receivedTime:"",rawData:"",paused:!1,receivedCount:""}},computed:{buttonLabel:function(){return s().f[1]++,s().s[1]++,this.paused?(s().b[0][0]++,s().s[2]++,"Resume"):(s().b[0][1]++,s().s[3]++,"Pause")},buttonIcon:function(){return s().f[2]++,s().s[4]++,this.paused?(s().b[1][0]++,s().s[5]++,"mdi-play"):(s().b[1][1]++,s().s[6]++,"mdi-pause")},isVisible:{get:function(){return s().f[3]++,s().s[7]++,this.visible},set:function(n){s().f[4]++,s().s[8]++,this.header="",s().s[9]++,this.receivedTime="",s().s[10]++,this.rawData="",s().s[11]++,this.receivedCount="",s().s[12]++,this.paused=!1,s().s[13]++,this.buttonLabel="Pause",s().s[14]++,this.$emit("display",n)}}},methods:{buildRawData:function(){return s().f[5]++,s().s[15]++,"".concat(this.header,"\nReceived Time: ").concat(this.receivedTime,"\nCount: ").concat(this.receivedCount,"\n").concat(this.rawData)},copyRawData:function(){s().f[6]++,s().s[16]++,navigator.clipboard.writeText(this.buildRawData())},downloadRawData:function(){s().f[7]++;var n=(s().s[17]++,new Blob([this.buildRawData()],{type:"plain/text"})),e=(s().s[18]++,document.createElement("a"));s().s[19]++,e.href=URL.createObjectURL(n);var t=(s().s[20]++,(0,a.Z)(Date.now(),"yyyy_MM_dd_HH_mm_ss"));s().s[21]++,e.setAttribute("download","".concat(t,"_").concat(this.targetName,"_").concat(this.packetName,".txt")),s().s[22]++,e.click()},pause:function(){s().f[8]++,s().s[23]++,this.paused=!this.paused},update:function(){if(s().f[9]++,s().s[24]++,s().b[3][0]++,!this.isVisible||(s().b[3][1]++,this.paused))return s().b[2][0]++,void s().s[25]++;s().b[2][1]++,s().s[26]++,this.header="Raw ".concat(this.type," Packet: ").concat(this.targetName," ").concat(this.packetName),s().s[27]++,"Telemetry"===this.type?(s().b[4][0]++,s().s[28]++,this.updateTelemetry()):(s().b[4][1]++,s().s[29]++,this.updateCommand())},updateTelemetry:function(){var n=this;s().f[10]++,s().s[30]++,this.api.get_tlm_buffer(this.targetName,this.packetName).then((function(e){s().f[11]++;var t=(s().s[31]++,e.buffer);if(s().s[32]++,void 0!==t.raw)s().b[5][0]++,s().s[33]++,t=t.raw;else{s().b[5][1]++;var l=(s().s[34]++,new TextEncoder);s().s[35]++,t=l.encode(t)}s().s[36]++,n.receivedTime=new Date(e.time/1e6),s().s[37]++,n.receivedCount=e.received_count,s().s[38]++,n.rawData="Address Data Ascii\n---------------------------------------------------------------------------\n"+n.formatBuffer(t)}))},updateCommand:function(){var n=this;s().f[12]++,s().s[39]++,this.api.get_cmd_buffer(this.targetName,this.packetName).then((function(e){s().f[13]++;var t=(s().s[40]++,e.buffer);if(s().s[41]++,void 0!==t.raw)s().b[6][0]++,s().s[42]++,t=t.raw;else{s().b[6][1]++;var l=(s().s[43]++,new TextEncoder);s().s[44]++,t=l.encode(t)}s().s[45]++,n.receivedTime=new Date(e.time/1e6),s().s[46]++,n.receivedCount=e.received_count,s().s[47]++,n.rawData="Address Data Ascii\n---------------------------------------------------------------------------\n"+n.formatBuffer(t)}))},formatBuffer:function(n){var e=this;s().f[14]++;var t=(s().s[48]++,""),l=(s().s[49]++,0),i=(s().s[50]++,"");if(s().s[51]++,n.forEach((function(n){s().f[15]++,s().s[52]++,l%16===0?(s().b[7][0]++,s().s[53]++,t+=e.numHex(l,8)+": "):s().b[7][1]++,s().s[54]++,t+=e.numHex(n),s().s[55]++,s().b[9][0]++,n>=32&&(s().b[9][1]++,n<=126)?(s().b[8][0]++,s().s[56]++,i+=String.fromCharCode(n)):(s().b[8][1]++,s().s[57]++,i+=" "),s().s[58]++,l++,s().s[59]++,l%16===0?(s().b[10][0]++,s().s[60]++,t+=" "+i+"\n",s().s[61]++,i=""):(s().b[10][1]++,s().s[62]++,t+=" ")})),s().s[63]++,l%16!=0){s().b[11][0]++;var o=(s().s[64]++,l%16-1+l%16*2),a=(s().s[65]++," ".repeat(47-o)),c=(s().s[66]++," ".repeat(16-i.length));s().s[67]++,t+=a+" "+i+c}else s().b[11][1]++;return s().s[68]++,t},numHex:function(n){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(s().b[12][0]++,2);s().f[16]++;var t=(s().s[69]++,n.toString(16));return s().s[70]++,"0".repeat(e-t.length)+t}}},r=u,m=(t(298),t(3483)),d=(0,m.Z)(r,i,o,!1,null,"7b88fb20",null),A=d.exports},5910:function(n,e,t){"use strict";t.r(e);var l=t(9601),i=t.n(l),o=t(2609),a=t.n(o),c=a()(i());c.push([n.id,".v-textarea[data-v-7b88fb20] textarea{margin-top:10px;font-family:Courier New,Courier,monospace}",""]),e["default"]=c},298:function(n,e,t){var l=t(5910);l.__esModule&&(l=l.default),"string"===typeof l&&(l=[[n.id,l,""]]),l.locals&&(n.exports=l.locals);var i=t(3514).Z;i("0af063f9",l,!0,{sourceMap:!1,shadowMode:!1})}}]);
2
- //# sourceMappingURL=320.js.map
1
+ (self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]=self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]||[]).push([[390],{8390:function(n,e,t){"use strict";t.d(e,{Z:function(){return A}});t(4083);function l(){var n="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",e="853a91e0ae78f53288b053e75c6209d163e3e6d4",t=new Function("return this")(),i="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",statementMap:{0:{start:{line:1,column:13},end:{line:2,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:1,column:2136}},4:{start:{line:1,column:137},end:{line:1,column:241}},5:{start:{line:1,column:229},end:{line:1,column:241}},6:{start:{line:1,column:241},end:{line:1,column:262}},7:{start:{line:1,column:319},end:{line:1,column:336}},8:{start:{line:1,column:493},end:{line:1,column:662}},9:{start:{line:1,column:874},end:{line:1,column:1042}},10:{start:{line:1,column:1268},end:{line:1,column:1463}},11:{start:{line:1,column:2084},end:{line:1,column:2099}},12:{start:{line:3,column:22},end:{line:3,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:2,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:120},end:{line:1,column:121}},loc:{start:{line:1,column:136},end:{line:1,column:263}},line:1},2:{name:"(anonymous_2)",decl:{start:{line:1,column:303},end:{line:1,column:304}},loc:{start:{line:1,column:318},end:{line:1,column:337}},line:1},3:{name:"(anonymous_3)",decl:{start:{line:1,column:469},end:{line:1,column:470}},loc:{start:{line:1,column:492},end:{line:1,column:663}},line:1},4:{name:"(anonymous_4)",decl:{start:{line:1,column:850},end:{line:1,column:851}},loc:{start:{line:1,column:873},end:{line:1,column:1043}},line:1},5:{name:"(anonymous_5)",decl:{start:{line:1,column:1244},end:{line:1,column:1245}},loc:{start:{line:1,column:1267},end:{line:1,column:1464}},line:1},6:{name:"(anonymous_6)",decl:{start:{line:1,column:2068},end:{line:1,column:2069}},loc:{start:{line:1,column:2083},end:{line:1,column:2100}},line:1}},branchMap:{0:{loc:{start:{line:1,column:137},end:{line:1,column:241}},type:"if",locations:[{start:{line:1,column:137},end:{line:1,column:241}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:1},1:{loc:{start:{line:1,column:140},end:{line:1,column:228}},type:"binary-expr",locations:[{start:{line:1,column:140},end:{line:1,column:167}},{start:{line:1,column:169},end:{line:1,column:228}}],line:1}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},b:{0:[0,0],1:[0,0]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"853a91e0ae78f53288b053e75c6209d163e3e6d4"},a=t[i]||(t[i]={});a[n]&&a[n].hash===e||(a[n]=o);var c=a[n];return l=function(){return c},c}l(),l().s[0]++;var i=function(){l().f[0]++;var n=(l().s[1]++,this),e=(l().s[2]++,n._self._c);return l().s[3]++,e("v-dialog",{attrs:{width:"790px"},on:{keydown:function(e){if(l().f[1]++,l().s[4]++,l().b[1][0]++,!e.type.indexOf("key")&&(l().b[1][1]++,n._k(e.keyCode,"esc",27,e.key,["Esc","Escape"])))return l().b[0][0]++,l().s[5]++,null;l().b[0][1]++,l().s[6]++,n.isVisible=!1}},model:{value:n.isVisible,callback:function(e){l().f[2]++,l().s[7]++,n.isVisible=e},expression:"isVisible"}},[e("v-card",[e("v-system-bar",[e("v-tooltip",{attrs:{top:""},scopedSlots:n._u([{key:"activator",fn:function(t){var i=t.on,o=t.attrs;return l().f[3]++,l().s[8]++,[e("div",n._g(n._b({},"div",o,!1),i),[e("v-icon",{attrs:{"data-test":"copy-icon"},on:{click:n.copyRawData}},[n._v(" mdi-content-copy ")])],1)]}}])},[e("span",[n._v(" Copy ")])]),e("v-spacer"),e("span",[n._v(" "+n._s(n.type)+" ")]),e("v-spacer"),e("v-tooltip",{attrs:{top:""},scopedSlots:n._u([{key:"activator",fn:function(t){var i=t.on,o=t.attrs;return l().f[4]++,l().s[9]++,[e("div",n._g(n._b({},"div",o,!1),i),[e("v-icon",{attrs:{"data-test":"download"},on:{click:n.downloadRawData}},[n._v(" mdi-download ")])],1)]}}])},[e("span",[n._v(" Download ")])])],1),e("v-card-title",[e("span",[n._v(" "+n._s(n.header)+" ")]),e("v-spacer"),e("v-tooltip",{attrs:{top:""},scopedSlots:n._u([{key:"activator",fn:function(t){var i=t.on,o=t.attrs;return l().f[5]++,l().s[10]++,[e("div",n._g(n._b({},"div",o,!1),i),[e("v-btn",{attrs:{icon:"","data-test":"pause"},on:{click:n.pause}},[e("v-icon",[n._v(" "+n._s(n.buttonIcon)+" ")])],1)],1)]}}])},[e("span",[n._v(" "+n._s(n.buttonLabel)+" ")])])],1),e("v-card-text",[e("v-row",{attrs:{dense:""}},[e("v-col",{attrs:{cols:"4"}},[e("span",[n._v(" Received Time: ")])]),e("v-col",{staticClass:"text-right"},[e("span",[n._v(" "+n._s(n.receivedTime)+" ")])])],1),e("v-row",{attrs:{dense:""}},[e("v-col",{attrs:{cols:"4"}},[e("span",[n._v(" Count: ")])]),e("v-col",{staticClass:"text-right"},[e("span",[n._v(" "+n._s(n.receivedCount)+" ")])])],1),e("v-textarea",{staticClass:"pa-0 ma-0",attrs:{"auto-grow":"",readonly:""},model:{value:n.rawData,callback:function(e){l().f[6]++,l().s[11]++,n.rawData=e},expression:"rawData"}})],1)],1)],1)},o=(l().s[12]++,[]),a=(t(8178),t(8188),t(8673),t(6886),t(4121),t(523),t(1939),t(7789),t(8233),t(9413)),c=t(4872);function s(){var n="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",e="5089fec28d4524bf316ed8efca2d3374b5072eee",t=new Function("return this")(),l="__coverage__",i={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue",statementMap:{0:{start:{line:15,column:4},end:{line:21,column:5}},1:{start:{line:25,column:6},end:{line:29,column:7}},2:{start:{line:26,column:8},end:{line:26,column:23}},3:{start:{line:28,column:8},end:{line:28,column:22}},4:{start:{line:32,column:6},end:{line:36,column:7}},5:{start:{line:33,column:8},end:{line:33,column:25}},6:{start:{line:35,column:8},end:{line:35,column:26}},7:{start:{line:40,column:8},end:{line:40,column:27}},8:{start:{line:44,column:8},end:{line:44,column:24}},9:{start:{line:45,column:8},end:{line:45,column:30}},10:{start:{line:46,column:8},end:{line:46,column:25}},11:{start:{line:47,column:8},end:{line:47,column:31}},12:{start:{line:48,column:8},end:{line:48,column:27}},13:{start:{line:49,column:8},end:{line:49,column:34}},14:{start:{line:50,column:8},end:{line:50,column:35}},15:{start:{line:56,column:6},end:{line:56,column:113}},16:{start:{line:59,column:6},end:{line:59,column:56}},17:{start:{line:62,column:19},end:{line:64,column:8}},18:{start:{line:66,column:19},end:{line:66,column:46}},19:{start:{line:67,column:6},end:{line:67,column:43}},20:{start:{line:68,column:17},end:{line:68,column:58}},21:{start:{line:69,column:6},end:{line:72,column:7}},22:{start:{line:73,column:6},end:{line:73,column:18}},23:{start:{line:76,column:6},end:{line:76,column:32}},24:{start:{line:79,column:6},end:{line:79,column:48}},25:{start:{line:79,column:42},end:{line:79,column:48}},26:{start:{line:80,column:6},end:{line:80,column:84}},27:{start:{line:82,column:6},end:{line:86,column:7}},28:{start:{line:83,column:8},end:{line:83,column:30}},29:{start:{line:85,column:8},end:{line:85,column:28}},30:{start:{line:89,column:6},end:{line:105,column:10}},31:{start:{line:92,column:28},end:{line:92,column:41}},32:{start:{line:93,column:10},end:{line:98,column:11}},33:{start:{line:94,column:12},end:{line:94,column:41}},34:{start:{line:96,column:29},end:{line:96,column:46}},35:{start:{line:97,column:12},end:{line:97,column:56}},36:{start:{line:99,column:10},end:{line:99,column:61}},37:{start:{line:100,column:10},end:{line:100,column:52}},38:{start:{line:101,column:10},end:{line:104,column:42}},39:{start:{line:108,column:6},end:{line:124,column:10}},40:{start:{line:111,column:28},end:{line:111,column:41}},41:{start:{line:112,column:10},end:{line:117,column:11}},42:{start:{line:113,column:12},end:{line:113,column:41}},43:{start:{line:115,column:29},end:{line:115,column:46}},44:{start:{line:116,column:12},end:{line:116,column:56}},45:{start:{line:118,column:10},end:{line:118,column:61}},46:{start:{line:119,column:10},end:{line:119,column:52}},47:{start:{line:120,column:10},end:{line:123,column:42}},48:{start:{line:128,column:19},end:{line:128,column:21}},49:{start:{line:129,column:18},end:{line:129,column:19}},50:{start:{line:130,column:18},end:{line:130,column:20}},51:{start:{line:131,column:6},end:{line:152,column:8}},52:{start:{line:132,column:8},end:{line:134,column:9}},53:{start:{line:133,column:10},end:{line:133,column:48}},54:{start:{line:135,column:8},end:{line:135,column:35}},55:{start:{line:138,column:8},end:{line:142,column:9}},56:{start:{line:139,column:10},end:{line:139,column:44}},57:{start:{line:141,column:10},end:{line:141,column:22}},58:{start:{line:144,column:8},end:{line:144,column:15}},59:{start:{line:146,column:8},end:{line:151,column:9}},60:{start:{line:147,column:10},end:{line:147,column:39}},61:{start:{line:148,column:10},end:{line:148,column:20}},62:{start:{line:150,column:10},end:{line:150,column:23}},63:{start:{line:157,column:6},end:{line:163,column:7}},64:{start:{line:158,column:30},end:{line:158,column:65}},65:{start:{line:160,column:21},end:{line:160,column:53}},66:{start:{line:161,column:27},end:{line:161,column:56}},67:{start:{line:162,column:8},end:{line:162,column:54}},68:{start:{line:164,column:6},end:{line:164,column:19}},69:{start:{line:167,column:16},end:{line:167,column:32}},70:{start:{line:168,column:6},end:{line:168,column:49}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:9},end:{line:22,column:3}},line:14},1:{name:"(anonymous_1)",decl:{start:{line:24,column:17},end:{line:24,column:18}},loc:{start:{line:24,column:29},end:{line:30,column:5}},line:24},2:{name:"(anonymous_2)",decl:{start:{line:31,column:16},end:{line:31,column:17}},loc:{start:{line:31,column:28},end:{line:37,column:5}},line:31},3:{name:"(anonymous_3)",decl:{start:{line:39,column:11},end:{line:39,column:12}},loc:{start:{line:39,column:23},end:{line:41,column:7}},line:39},4:{name:"(anonymous_4)",decl:{start:{line:43,column:11},end:{line:43,column:12}},loc:{start:{line:43,column:27},end:{line:51,column:7}},line:43},5:{name:"(anonymous_5)",decl:{start:{line:55,column:18},end:{line:55,column:19}},loc:{start:{line:55,column:30},end:{line:57,column:5}},line:55},6:{name:"(anonymous_6)",decl:{start:{line:58,column:17},end:{line:58,column:18}},loc:{start:{line:58,column:29},end:{line:60,column:5}},line:58},7:{name:"(anonymous_7)",decl:{start:{line:61,column:21},end:{line:61,column:22}},loc:{start:{line:61,column:33},end:{line:74,column:5}},line:61},8:{name:"(anonymous_8)",decl:{start:{line:75,column:11},end:{line:75,column:12}},loc:{start:{line:75,column:23},end:{line:77,column:5}},line:75},9:{name:"(anonymous_9)",decl:{start:{line:78,column:12},end:{line:78,column:13}},loc:{start:{line:78,column:24},end:{line:87,column:5}},line:78},10:{name:"(anonymous_10)",decl:{start:{line:88,column:21},end:{line:88,column:22}},loc:{start:{line:88,column:33},end:{line:106,column:5}},line:88},11:{name:"(anonymous_11)",decl:{start:{line:91,column:14},end:{line:91,column:15}},loc:{start:{line:91,column:26},end:{line:105,column:9}},line:91},12:{name:"(anonymous_12)",decl:{start:{line:107,column:19},end:{line:107,column:20}},loc:{start:{line:107,column:31},end:{line:125,column:5}},line:107},13:{name:"(anonymous_13)",decl:{start:{line:110,column:14},end:{line:110,column:15}},loc:{start:{line:110,column:26},end:{line:124,column:9}},line:110},14:{name:"(anonymous_14)",decl:{start:{line:127,column:18},end:{line:127,column:19}},loc:{start:{line:127,column:36},end:{line:165,column:5}},line:127},15:{name:"(anonymous_15)",decl:{start:{line:131,column:21},end:{line:131,column:22}},loc:{start:{line:131,column:31},end:{line:152,column:7}},line:131},16:{name:"(anonymous_16)",decl:{start:{line:166,column:4},end:{line:166,column:5}},loc:{start:{line:166,column:27},end:{line:169,column:5}},line:166}},branchMap:{0:{loc:{start:{line:25,column:6},end:{line:29,column:7}},type:"if",locations:[{start:{line:25,column:6},end:{line:29,column:7}},{start:{line:27,column:13},end:{line:29,column:7}}],line:25},1:{loc:{start:{line:32,column:6},end:{line:36,column:7}},type:"if",locations:[{start:{line:32,column:6},end:{line:36,column:7}},{start:{line:34,column:13},end:{line:36,column:7}}],line:32},2:{loc:{start:{line:79,column:6},end:{line:79,column:48}},type:"if",locations:[{start:{line:79,column:6},end:{line:79,column:48}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:79},3:{loc:{start:{line:79,column:10},end:{line:79,column:40}},type:"binary-expr",locations:[{start:{line:79,column:10},end:{line:79,column:25}},{start:{line:79,column:29},end:{line:79,column:40}}],line:79},4:{loc:{start:{line:82,column:6},end:{line:86,column:7}},type:"if",locations:[{start:{line:82,column:6},end:{line:86,column:7}},{start:{line:84,column:13},end:{line:86,column:7}}],line:82},5:{loc:{start:{line:93,column:10},end:{line:98,column:11}},type:"if",locations:[{start:{line:93,column:10},end:{line:98,column:11}},{start:{line:95,column:17},end:{line:98,column:11}}],line:93},6:{loc:{start:{line:112,column:10},end:{line:117,column:11}},type:"if",locations:[{start:{line:112,column:10},end:{line:117,column:11}},{start:{line:114,column:17},end:{line:117,column:11}}],line:112},7:{loc:{start:{line:132,column:8},end:{line:134,column:9}},type:"if",locations:[{start:{line:132,column:8},end:{line:134,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:132},8:{loc:{start:{line:138,column:8},end:{line:142,column:9}},type:"if",locations:[{start:{line:138,column:8},end:{line:142,column:9}},{start:{line:140,column:15},end:{line:142,column:9}}],line:138},9:{loc:{start:{line:138,column:12},end:{line:138,column:37}},type:"binary-expr",locations:[{start:{line:138,column:12},end:{line:138,column:22}},{start:{line:138,column:26},end:{line:138,column:37}}],line:138},10:{loc:{start:{line:146,column:8},end:{line:151,column:9}},type:"if",locations:[{start:{line:146,column:8},end:{line:151,column:9}},{start:{line:149,column:15},end:{line:151,column:9}}],line:146},11:{loc:{start:{line:157,column:6},end:{line:163,column:7}},type:"if",locations:[{start:{line:157,column:6},end:{line:163,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:157},12:{loc:{start:{line:166,column:16},end:{line:166,column:25}},type:"default-arg",locations:[{start:{line:166,column:24},end:{line:166,column:25}}],line:166}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0]},inputSourceMap:{version:3,sources:["RawDialog.vue"],names:[],mappings:";AAwFA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"RawDialog.vue",sourceRoot:"src/tools/CmdTlmServer",sourcesContent:["\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license \n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <v-dialog v-model=\"isVisible\" @keydown.esc=\"isVisible = false\" width=\"790px\">\n <v-card>\n <v-system-bar>\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"copy-icon\" @click=\"copyRawData\">\n mdi-content-copy\n </v-icon>\n </div>\n </template>\n <span> Copy </span>\n </v-tooltip>\n <v-spacer />\n <span> {{ type }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"download\" @click=\"downloadRawData\">\n mdi-download\n </v-icon>\n </div>\n </template>\n <span> Download </span>\n </v-tooltip>\n </v-system-bar>\n <v-card-title>\n <span> {{ header }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-btn icon data-test=\"pause\" @click=\"pause\">\n <v-icon> {{ buttonIcon }} </v-icon>\n </v-btn>\n </div>\n </template>\n <span> {{ buttonLabel }} </span>\n </v-tooltip>\n </v-card-title>\n <v-card-text>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Received Time: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedTime }} </span>\n </v-col>\n </v-row>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Count: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedCount }} </span>\n </v-col>\n </v-row>\n <v-textarea v-model=\"rawData\" class=\"pa-0 ma-0\" auto-grow readonly />\n </v-card-text>\n </v-card>\n </v-dialog>\n</template>\n\n<script>\nimport { format } from 'date-fns'\n\nimport Updater from './Updater'\n\nexport default {\n mixins: [Updater],\n props: {\n type: String,\n visible: Boolean,\n targetName: String,\n packetName: String,\n },\n data() {\n return {\n header: '',\n receivedTime: '',\n rawData: '',\n paused: false,\n receivedCount: '',\n }\n },\n computed: {\n buttonLabel: function () {\n if (this.paused) {\n return 'Resume'\n } else {\n return 'Pause'\n }\n },\n buttonIcon: function () {\n if (this.paused) {\n return 'mdi-play'\n } else {\n return 'mdi-pause'\n }\n },\n isVisible: {\n get: function () {\n return this.visible\n },\n // Reset all the data to defaults\n set: function (bool) {\n this.header = ''\n this.receivedTime = ''\n this.rawData = ''\n this.receivedCount = ''\n this.paused = false\n this.buttonLabel = 'Pause'\n this.$emit('display', bool)\n },\n },\n },\n methods: {\n buildRawData: function () {\n return `${this.header}\\nReceived Time: ${this.receivedTime}\\nCount: ${this.receivedCount}\\n${this.rawData}`\n },\n copyRawData: function () {\n navigator.clipboard.writeText(this.buildRawData())\n },\n downloadRawData: function () {\n const blob = new Blob([this.buildRawData()], {\n type: 'plain/text',\n })\n // Make a link and then 'click' on it to start the download\n const link = document.createElement('a')\n link.href = URL.createObjectURL(blob)\n const dt = format(Date.now(), 'yyyy_MM_dd_HH_mm_ss')\n link.setAttribute(\n 'download',\n `${dt}_${this.targetName}_${this.packetName}.txt`\n )\n link.click()\n },\n pause: function () {\n this.paused = !this.paused\n },\n update: function () {\n if (!this.isVisible || this.paused) return\n this.header = `Raw ${this.type} Packet: ${this.targetName} ${this.packetName}`\n\n if (this.type === 'Telemetry') {\n this.updateTelemetry()\n } else {\n this.updateCommand()\n }\n },\n updateTelemetry: function () {\n this.api\n .get_tlm_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n updateCommand: function () {\n this.api\n .get_cmd_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n // TODO: Perhaps move this to a utility library\n formatBuffer: function (buffer) {\n var string = ''\n var index = 0\n var ascii = ''\n buffer.forEach((byte) => {\n if (index % 16 === 0) {\n string += this.numHex(index, 8) + ': '\n }\n string += this.numHex(byte)\n\n // Create the ASCII representation if printable\n if (byte >= 32 && byte <= 126) {\n ascii += String.fromCharCode(byte)\n } else {\n ascii += ' '\n }\n\n index++\n\n if (index % 16 === 0) {\n string += ' ' + ascii + '\\n'\n ascii = ''\n } else {\n string += ' '\n }\n })\n\n // We're done printing all the bytes. Now check to see if we ended in the\n // middle of a line. If so we have to print out the final ASCII if\n // requested.\n if (index % 16 != 0) {\n var existing_length = (index % 16) - 1 + (index % 16) * 2\n // 47 is (16 * 2) + 15 separator spaces\n var filler = ' '.repeat(47 - existing_length)\n var ascii_filler = ' '.repeat(16 - ascii.length)\n string += filler + ' ' + ascii + ascii_filler\n }\n return string\n },\n numHex(num, width = 2) {\n var hex = num.toString(16)\n return '0'.repeat(width - hex.length) + hex\n },\n },\n}\n<\/script>\n<style scoped>\n.v-textarea :deep(textarea) {\n margin-top: 10px;\n font-family: 'Courier New', Courier, monospace;\n}\n</style>\n"]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"5089fec28d4524bf316ed8efca2d3374b5072eee"},o=t[l]||(t[l]={});o[n]&&o[n].hash===e||(o[n]=i);var a=o[n];return s=function(){return a},a}s();var u={mixins:[c.Z],props:{type:String,visible:Boolean,targetName:String,packetName:String},data:function(){return s().f[0]++,s().s[0]++,{header:"",receivedTime:"",rawData:"",paused:!1,receivedCount:""}},computed:{buttonLabel:function(){return s().f[1]++,s().s[1]++,this.paused?(s().b[0][0]++,s().s[2]++,"Resume"):(s().b[0][1]++,s().s[3]++,"Pause")},buttonIcon:function(){return s().f[2]++,s().s[4]++,this.paused?(s().b[1][0]++,s().s[5]++,"mdi-play"):(s().b[1][1]++,s().s[6]++,"mdi-pause")},isVisible:{get:function(){return s().f[3]++,s().s[7]++,this.visible},set:function(n){s().f[4]++,s().s[8]++,this.header="",s().s[9]++,this.receivedTime="",s().s[10]++,this.rawData="",s().s[11]++,this.receivedCount="",s().s[12]++,this.paused=!1,s().s[13]++,this.buttonLabel="Pause",s().s[14]++,this.$emit("display",n)}}},methods:{buildRawData:function(){return s().f[5]++,s().s[15]++,"".concat(this.header,"\nReceived Time: ").concat(this.receivedTime,"\nCount: ").concat(this.receivedCount,"\n").concat(this.rawData)},copyRawData:function(){s().f[6]++,s().s[16]++,navigator.clipboard.writeText(this.buildRawData())},downloadRawData:function(){s().f[7]++;var n=(s().s[17]++,new Blob([this.buildRawData()],{type:"plain/text"})),e=(s().s[18]++,document.createElement("a"));s().s[19]++,e.href=URL.createObjectURL(n);var t=(s().s[20]++,(0,a.Z)(Date.now(),"yyyy_MM_dd_HH_mm_ss"));s().s[21]++,e.setAttribute("download","".concat(t,"_").concat(this.targetName,"_").concat(this.packetName,".txt")),s().s[22]++,e.click()},pause:function(){s().f[8]++,s().s[23]++,this.paused=!this.paused},update:function(){if(s().f[9]++,s().s[24]++,s().b[3][0]++,!this.isVisible||(s().b[3][1]++,this.paused))return s().b[2][0]++,void s().s[25]++;s().b[2][1]++,s().s[26]++,this.header="Raw ".concat(this.type," Packet: ").concat(this.targetName," ").concat(this.packetName),s().s[27]++,"Telemetry"===this.type?(s().b[4][0]++,s().s[28]++,this.updateTelemetry()):(s().b[4][1]++,s().s[29]++,this.updateCommand())},updateTelemetry:function(){var n=this;s().f[10]++,s().s[30]++,this.api.get_tlm_buffer(this.targetName,this.packetName).then((function(e){s().f[11]++;var t=(s().s[31]++,e.buffer);if(s().s[32]++,void 0!==t.raw)s().b[5][0]++,s().s[33]++,t=t.raw;else{s().b[5][1]++;var l=(s().s[34]++,new TextEncoder);s().s[35]++,t=l.encode(t)}s().s[36]++,n.receivedTime=new Date(e.time/1e6),s().s[37]++,n.receivedCount=e.received_count,s().s[38]++,n.rawData="Address Data Ascii\n---------------------------------------------------------------------------\n"+n.formatBuffer(t)}))},updateCommand:function(){var n=this;s().f[12]++,s().s[39]++,this.api.get_cmd_buffer(this.targetName,this.packetName).then((function(e){s().f[13]++;var t=(s().s[40]++,e.buffer);if(s().s[41]++,void 0!==t.raw)s().b[6][0]++,s().s[42]++,t=t.raw;else{s().b[6][1]++;var l=(s().s[43]++,new TextEncoder);s().s[44]++,t=l.encode(t)}s().s[45]++,n.receivedTime=new Date(e.time/1e6),s().s[46]++,n.receivedCount=e.received_count,s().s[47]++,n.rawData="Address Data Ascii\n---------------------------------------------------------------------------\n"+n.formatBuffer(t)}))},formatBuffer:function(n){var e=this;s().f[14]++;var t=(s().s[48]++,""),l=(s().s[49]++,0),i=(s().s[50]++,"");if(s().s[51]++,n.forEach((function(n){s().f[15]++,s().s[52]++,l%16===0?(s().b[7][0]++,s().s[53]++,t+=e.numHex(l,8)+": "):s().b[7][1]++,s().s[54]++,t+=e.numHex(n),s().s[55]++,s().b[9][0]++,n>=32&&(s().b[9][1]++,n<=126)?(s().b[8][0]++,s().s[56]++,i+=String.fromCharCode(n)):(s().b[8][1]++,s().s[57]++,i+=" "),s().s[58]++,l++,s().s[59]++,l%16===0?(s().b[10][0]++,s().s[60]++,t+=" "+i+"\n",s().s[61]++,i=""):(s().b[10][1]++,s().s[62]++,t+=" ")})),s().s[63]++,l%16!=0){s().b[11][0]++;var o=(s().s[64]++,l%16-1+l%16*2),a=(s().s[65]++," ".repeat(47-o)),c=(s().s[66]++," ".repeat(16-i.length));s().s[67]++,t+=a+" "+i+c}else s().b[11][1]++;return s().s[68]++,t},numHex:function(n){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(s().b[12][0]++,2);s().f[16]++;var t=(s().s[69]++,n.toString(16));return s().s[70]++,"0".repeat(e-t.length)+t}}},r=u,m=(t(4269),t(3287)),d=(0,m.Z)(r,i,o,!1,null,"7b88fb20",null),A=d.exports},2482:function(n,e,t){"use strict";t.r(e);var l=t(3467),i=t.n(l),o=t(8715),a=t.n(o),c=a()(i());c.push([n.id,".v-textarea[data-v-7b88fb20] textarea{margin-top:10px;font-family:Courier New,Courier,monospace}",""]),e["default"]=c},4269:function(n,e,t){var l=t(2482);l.__esModule&&(l=l.default),"string"===typeof l&&(l=[[n.id,l,""]]),l.locals&&(n.exports=l.locals);var i=t(3514).Z;i("99dd9964",l,!0,{sourceMap:!1,shadowMode:!1})}}]);
2
+ //# sourceMappingURL=390.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"js/320.js","mappings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KACA,WACA,MAIF,EAAe0E,EAAiB,O,qFChB5BC,EAA0B,IAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,mGAAoG,KAE7I,c,sBCJA,IAAIC,EAAU,EAAQ,MACnBA,EAAQC,aAAYD,EAAUA,EAAQE,SACnB,kBAAZF,IAAsBA,EAAU,CAAC,CAACF,EAAOC,GAAIC,EAAS,MAC7DA,EAAQG,SAAQL,EAAOM,QAAUJ,EAAQG,QAE5C,IAAIE,EAAM,UACGA,EAAI,WAAYL,GAAS,EAAM,CAAC,WAAY,EAAM,YAAa,G","sources":["webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?82a1","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?b7f3","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?8e5d","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?fab9"],"sourcesContent":["var render = function render(){var _vm=this,_c=_vm._self._c;return _c('v-dialog',{attrs:{\"width\":\"790px\"},on:{\"keydown\":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,\"esc\",27,$event.key,[\"Esc\",\"Escape\"]))return null;_vm.isVisible = false}},model:{value:(_vm.isVisible),callback:function ($$v) {_vm.isVisible=$$v},expression:\"isVisible\"}},[_c('v-card',[_c('v-system-bar',[_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function({ on, attrs }){return [_c('div',_vm._g(_vm._b({},'div',attrs,false),on),[_c('v-icon',{attrs:{\"data-test\":\"copy-icon\"},on:{\"click\":_vm.copyRawData}},[_vm._v(\" mdi-content-copy \")])],1)]}}])},[_c('span',[_vm._v(\" Copy \")])]),_c('v-spacer'),_c('span',[_vm._v(\" \"+_vm._s(_vm.type)+\" \")]),_c('v-spacer'),_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function({ on, attrs }){return [_c('div',_vm._g(_vm._b({},'div',attrs,false),on),[_c('v-icon',{attrs:{\"data-test\":\"download\"},on:{\"click\":_vm.downloadRawData}},[_vm._v(\" mdi-download \")])],1)]}}])},[_c('span',[_vm._v(\" Download \")])])],1),_c('v-card-title',[_c('span',[_vm._v(\" \"+_vm._s(_vm.header)+\" \")]),_c('v-spacer'),_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function({ on, attrs }){return [_c('div',_vm._g(_vm._b({},'div',attrs,false),on),[_c('v-btn',{attrs:{\"icon\":\"\",\"data-test\":\"pause\"},on:{\"click\":_vm.pause}},[_c('v-icon',[_vm._v(\" \"+_vm._s(_vm.buttonIcon)+\" \")])],1)],1)]}}])},[_c('span',[_vm._v(\" \"+_vm._s(_vm.buttonLabel)+\" \")])])],1),_c('v-card-text',[_c('v-row',{attrs:{\"dense\":\"\"}},[_c('v-col',{attrs:{\"cols\":\"4\"}},[_c('span',[_vm._v(\" Received Time: \")])]),_c('v-col',{staticClass:\"text-right\"},[_c('span',[_vm._v(\" \"+_vm._s(_vm.receivedTime)+\" \")])])],1),_c('v-row',{attrs:{\"dense\":\"\"}},[_c('v-col',{attrs:{\"cols\":\"4\"}},[_c('span',[_vm._v(\" Count: \")])]),_c('v-col',{staticClass:\"text-right\"},[_c('span',[_vm._v(\" \"+_vm._s(_vm.receivedCount)+\" \")])])],1),_c('v-textarea',{staticClass:\"pa-0 ma-0\",attrs:{\"auto-grow\":\"\",\"readonly\":\"\"},model:{value:(_vm.rawData),callback:function ($$v) {_vm.rawData=$$v},expression:\"rawData\"}})],1)],1)],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license \n# if purchased from OpenC3, Inc.\n-->\n\n<template>\n <v-dialog v-model=\"isVisible\" @keydown.esc=\"isVisible = false\" width=\"790px\">\n <v-card>\n <v-system-bar>\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"copy-icon\" @click=\"copyRawData\">\n mdi-content-copy\n </v-icon>\n </div>\n </template>\n <span> Copy </span>\n </v-tooltip>\n <v-spacer />\n <span> {{ type }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"download\" @click=\"downloadRawData\">\n mdi-download\n </v-icon>\n </div>\n </template>\n <span> Download </span>\n </v-tooltip>\n </v-system-bar>\n <v-card-title>\n <span> {{ header }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-btn icon data-test=\"pause\" @click=\"pause\">\n <v-icon> {{ buttonIcon }} </v-icon>\n </v-btn>\n </div>\n </template>\n <span> {{ buttonLabel }} </span>\n </v-tooltip>\n </v-card-title>\n <v-card-text>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Received Time: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedTime }} </span>\n </v-col>\n </v-row>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Count: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedCount }} </span>\n </v-col>\n </v-row>\n <v-textarea v-model=\"rawData\" class=\"pa-0 ma-0\" auto-grow readonly />\n </v-card-text>\n </v-card>\n </v-dialog>\n</template>\n\n<script>\nimport { format } from 'date-fns'\n\nimport Updater from './Updater'\n\nexport default {\n mixins: [Updater],\n props: {\n type: String,\n visible: Boolean,\n targetName: String,\n packetName: String,\n },\n data() {\n return {\n header: '',\n receivedTime: '',\n rawData: '',\n paused: false,\n receivedCount: '',\n }\n },\n computed: {\n buttonLabel: function () {\n if (this.paused) {\n return 'Resume'\n } else {\n return 'Pause'\n }\n },\n buttonIcon: function () {\n if (this.paused) {\n return 'mdi-play'\n } else {\n return 'mdi-pause'\n }\n },\n isVisible: {\n get: function () {\n return this.visible\n },\n // Reset all the data to defaults\n set: function (bool) {\n this.header = ''\n this.receivedTime = ''\n this.rawData = ''\n this.receivedCount = ''\n this.paused = false\n this.buttonLabel = 'Pause'\n this.$emit('display', bool)\n },\n },\n },\n methods: {\n buildRawData: function () {\n return `${this.header}\\nReceived Time: ${this.receivedTime}\\nCount: ${this.receivedCount}\\n${this.rawData}`\n },\n copyRawData: function () {\n navigator.clipboard.writeText(this.buildRawData())\n },\n downloadRawData: function () {\n const blob = new Blob([this.buildRawData()], {\n type: 'plain/text',\n })\n // Make a link and then 'click' on it to start the download\n const link = document.createElement('a')\n link.href = URL.createObjectURL(blob)\n const dt = format(Date.now(), 'yyyy_MM_dd_HH_mm_ss')\n link.setAttribute(\n 'download',\n `${dt}_${this.targetName}_${this.packetName}.txt`\n )\n link.click()\n },\n pause: function () {\n this.paused = !this.paused\n },\n update: function () {\n if (!this.isVisible || this.paused) return\n this.header = `Raw ${this.type} Packet: ${this.targetName} ${this.packetName}`\n\n if (this.type === 'Telemetry') {\n this.updateTelemetry()\n } else {\n this.updateCommand()\n }\n },\n updateTelemetry: function () {\n this.api\n .get_tlm_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n updateCommand: function () {\n this.api\n .get_cmd_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n // TODO: Perhaps move this to a utility library\n formatBuffer: function (buffer) {\n var string = ''\n var index = 0\n var ascii = ''\n buffer.forEach((byte) => {\n if (index % 16 === 0) {\n string += this.numHex(index, 8) + ': '\n }\n string += this.numHex(byte)\n\n // Create the ASCII representation if printable\n if (byte >= 32 && byte <= 126) {\n ascii += String.fromCharCode(byte)\n } else {\n ascii += ' '\n }\n\n index++\n\n if (index % 16 === 0) {\n string += ' ' + ascii + '\\n'\n ascii = ''\n } else {\n string += ' '\n }\n })\n\n // We're done printing all the bytes. Now check to see if we ended in the\n // middle of a line. If so we have to print out the final ASCII if\n // requested.\n if (index % 16 != 0) {\n var existing_length = (index % 16) - 1 + (index % 16) * 2\n // 47 is (16 * 2) + 15 separator spaces\n var filler = ' '.repeat(47 - existing_length)\n var ascii_filler = ' '.repeat(16 - ascii.length)\n string += filler + ' ' + ascii + ascii_filler\n }\n return string\n },\n numHex(num, width = 2) {\n var hex = num.toString(16)\n return '0'.repeat(width - hex.length) + hex\n },\n },\n}\n</script>\n<style scoped>\n.v-textarea :deep(textarea) {\n margin-top: 10px;\n font-family: 'Courier New', Courier, monospace;\n}\n</style>\n","import mod from \"-!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./RawDialog.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../../node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./RawDialog.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./RawDialog.vue?vue&type=template&id=7b88fb20&scoped=true&\"\nimport script from \"./RawDialog.vue?vue&type=script&lang=js&\"\nexport * from \"./RawDialog.vue?vue&type=script&lang=js&\"\nimport style0 from \"./RawDialog.vue?vue&type=style&index=0&id=7b88fb20&prod&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../node_modules/@vue/vue-loader-v15/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"7b88fb20\",\n null\n \n)\n\nexport default component.exports","// Imports\nimport ___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___ from \"../../../../../node_modules/css-loader/dist/runtime/noSourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".v-textarea[data-v-7b88fb20] textarea{margin-top:10px;font-family:Courier New,Courier,monospace}\", \"\"]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!../../../../../node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!../../../../../node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[3]!../../../../../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./RawDialog.vue?vue&type=style&index=0&id=7b88fb20&prod&scoped=true&lang=css&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"0af063f9\", content, true, {\"sourceMap\":false,\"shadowMode\":false});"],"names":["cov_2gt25r962d","actualCoverage","s","render","f","_vm","this","_c","_self","attrs","on","$event","b","type","indexOf","_k","keyCode","key","isVisible","model","value","callback","$$v","expression","scopedSlots","_u","fn","_ref","_g","_b","copyRawData","_v","_s","_ref2","downloadRawData","header","_ref3","pause","buttonIcon","buttonLabel","staticClass","receivedTime","receivedCount","rawData","staticRenderFns","mixins","Updater","props","String","visible","Boolean","targetName","packetName","data","paused","computed","get","set","bool","$emit","methods","buildRawData","concat","navigator","clipboard","writeText","blob","Blob","link","document","createElement","href","URL","createObjectURL","dt","format","Date","now","setAttribute","click","update","updateTelemetry","updateCommand","_this","api","get_tlm_buffer","then","result","buffer_data","buffer","undefined","raw","utf8Encode","TextEncoder","encode","time","received_count","formatBuffer","_this2","get_cmd_buffer","_this3","string","index","ascii","forEach","byte","numHex","fromCharCode","existing_length","filler","repeat","ascii_filler","length","num","width","arguments","hex","toString","component","___CSS_LOADER_EXPORT___","push","module","id","content","__esModule","default","locals","exports","add"],"sourceRoot":""}
1
+ {"version":3,"file":"js/390.js","mappings":"q4FAeY,OAAAA,EAAA,kBAAAC,CAAA,EAAAA,CAAA,CAAAD,IAAAA,IAAAE,EAAA,KAfZ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,EAAOC,GAAI,mGAAoG,KAE7I,c,uBCJA,IAAIC,EAAU,EAAQ,MACnBA,EAAQC,aAAYD,EAAUA,EAAQE,SACnB,kBAAZF,IAAsBA,EAAU,CAAC,CAACF,EAAOC,GAAIC,EAAS,MAC7DA,EAAQG,SAAQL,EAAOM,QAAUJ,EAAQG,QAE5C,IAAIE,EAAM,UACGA,EAAI,WAAYL,GAAS,EAAM,CAAC,WAAY,EAAM,YAAa,G","sources":["webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/RawDialog.vue","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?52c2","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?e1b7","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?be5a","webpack://@openc3/cosmos-tool-cmdtlmserver/./src/tools/CmdTlmServer/RawDialog.vue?4f62"],"sourcesContent":["var render = function render(){var _vm=this,_c=_vm._self._c;return _c('v-dialog',{attrs:{\"width\":\"790px\"},on:{\"keydown\":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,\"esc\",27,$event.key,[\"Esc\",\"Escape\"]))return null;_vm.isVisible = false}},model:{value:(_vm.isVisible),callback:function ($$v) {_vm.isVisible=$$v},expression:\"isVisible\"}},[_c('v-card',[_c('v-system-bar',[_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function({ on, attrs }){return [_c('div',_vm._g(_vm._b({},'div',attrs,false),on),[_c('v-icon',{attrs:{\"data-test\":\"copy-icon\"},on:{\"click\":_vm.copyRawData}},[_vm._v(\" mdi-content-copy \")])],1)]}}])},[_c('span',[_vm._v(\" Copy \")])]),_c('v-spacer'),_c('span',[_vm._v(\" \"+_vm._s(_vm.type)+\" \")]),_c('v-spacer'),_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function({ on, attrs }){return [_c('div',_vm._g(_vm._b({},'div',attrs,false),on),[_c('v-icon',{attrs:{\"data-test\":\"download\"},on:{\"click\":_vm.downloadRawData}},[_vm._v(\" mdi-download \")])],1)]}}])},[_c('span',[_vm._v(\" Download \")])])],1),_c('v-card-title',[_c('span',[_vm._v(\" \"+_vm._s(_vm.header)+\" \")]),_c('v-spacer'),_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function({ on, attrs }){return [_c('div',_vm._g(_vm._b({},'div',attrs,false),on),[_c('v-btn',{attrs:{\"icon\":\"\",\"data-test\":\"pause\"},on:{\"click\":_vm.pause}},[_c('v-icon',[_vm._v(\" \"+_vm._s(_vm.buttonIcon)+\" \")])],1)],1)]}}])},[_c('span',[_vm._v(\" \"+_vm._s(_vm.buttonLabel)+\" \")])])],1),_c('v-card-text',[_c('v-row',{attrs:{\"dense\":\"\"}},[_c('v-col',{attrs:{\"cols\":\"4\"}},[_c('span',[_vm._v(\" Received Time: \")])]),_c('v-col',{staticClass:\"text-right\"},[_c('span',[_vm._v(\" \"+_vm._s(_vm.receivedTime)+\" \")])])],1),_c('v-row',{attrs:{\"dense\":\"\"}},[_c('v-col',{attrs:{\"cols\":\"4\"}},[_c('span',[_vm._v(\" Count: \")])]),_c('v-col',{staticClass:\"text-right\"},[_c('span',[_vm._v(\" \"+_vm._s(_vm.receivedCount)+\" \")])])],1),_c('v-textarea',{staticClass:\"pa-0 ma-0\",attrs:{\"auto-grow\":\"\",\"readonly\":\"\"},model:{value:(_vm.rawData),callback:function ($$v) {_vm.rawData=$$v},expression:\"rawData\"}})],1)],1)],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license \n# if purchased from OpenC3, Inc.\n-->\n\n<template>\n <v-dialog v-model=\"isVisible\" @keydown.esc=\"isVisible = false\" width=\"790px\">\n <v-card>\n <v-system-bar>\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"copy-icon\" @click=\"copyRawData\">\n mdi-content-copy\n </v-icon>\n </div>\n </template>\n <span> Copy </span>\n </v-tooltip>\n <v-spacer />\n <span> {{ type }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-icon data-test=\"download\" @click=\"downloadRawData\">\n mdi-download\n </v-icon>\n </div>\n </template>\n <span> Download </span>\n </v-tooltip>\n </v-system-bar>\n <v-card-title>\n <span> {{ header }} </span>\n <v-spacer />\n <v-tooltip top>\n <template v-slot:activator=\"{ on, attrs }\">\n <div v-on=\"on\" v-bind=\"attrs\">\n <v-btn icon data-test=\"pause\" @click=\"pause\">\n <v-icon> {{ buttonIcon }} </v-icon>\n </v-btn>\n </div>\n </template>\n <span> {{ buttonLabel }} </span>\n </v-tooltip>\n </v-card-title>\n <v-card-text>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Received Time: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedTime }} </span>\n </v-col>\n </v-row>\n <v-row dense>\n <v-col cols=\"4\">\n <span> Count: </span>\n </v-col>\n <v-col class=\"text-right\">\n <span> {{ receivedCount }} </span>\n </v-col>\n </v-row>\n <v-textarea v-model=\"rawData\" class=\"pa-0 ma-0\" auto-grow readonly />\n </v-card-text>\n </v-card>\n </v-dialog>\n</template>\n\n<script>\nimport { format } from 'date-fns'\n\nimport Updater from './Updater'\n\nexport default {\n mixins: [Updater],\n props: {\n type: String,\n visible: Boolean,\n targetName: String,\n packetName: String,\n },\n data() {\n return {\n header: '',\n receivedTime: '',\n rawData: '',\n paused: false,\n receivedCount: '',\n }\n },\n computed: {\n buttonLabel: function () {\n if (this.paused) {\n return 'Resume'\n } else {\n return 'Pause'\n }\n },\n buttonIcon: function () {\n if (this.paused) {\n return 'mdi-play'\n } else {\n return 'mdi-pause'\n }\n },\n isVisible: {\n get: function () {\n return this.visible\n },\n // Reset all the data to defaults\n set: function (bool) {\n this.header = ''\n this.receivedTime = ''\n this.rawData = ''\n this.receivedCount = ''\n this.paused = false\n this.buttonLabel = 'Pause'\n this.$emit('display', bool)\n },\n },\n },\n methods: {\n buildRawData: function () {\n return `${this.header}\\nReceived Time: ${this.receivedTime}\\nCount: ${this.receivedCount}\\n${this.rawData}`\n },\n copyRawData: function () {\n navigator.clipboard.writeText(this.buildRawData())\n },\n downloadRawData: function () {\n const blob = new Blob([this.buildRawData()], {\n type: 'plain/text',\n })\n // Make a link and then 'click' on it to start the download\n const link = document.createElement('a')\n link.href = URL.createObjectURL(blob)\n const dt = format(Date.now(), 'yyyy_MM_dd_HH_mm_ss')\n link.setAttribute(\n 'download',\n `${dt}_${this.targetName}_${this.packetName}.txt`\n )\n link.click()\n },\n pause: function () {\n this.paused = !this.paused\n },\n update: function () {\n if (!this.isVisible || this.paused) return\n this.header = `Raw ${this.type} Packet: ${this.targetName} ${this.packetName}`\n\n if (this.type === 'Telemetry') {\n this.updateTelemetry()\n } else {\n this.updateCommand()\n }\n },\n updateTelemetry: function () {\n this.api\n .get_tlm_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n updateCommand: function () {\n this.api\n .get_cmd_buffer(this.targetName, this.packetName)\n .then((result) => {\n let buffer_data = result.buffer\n if (buffer_data.raw !== undefined) {\n buffer_data = buffer_data.raw\n } else {\n let utf8Encode = new TextEncoder()\n buffer_data = utf8Encode.encode(buffer_data)\n }\n this.receivedTime = new Date(result.time / 1000000)\n this.receivedCount = result.received_count\n this.rawData =\n 'Address Data Ascii\\n' +\n '---------------------------------------------------------------------------\\n' +\n this.formatBuffer(buffer_data)\n })\n },\n // TODO: Perhaps move this to a utility library\n formatBuffer: function (buffer) {\n var string = ''\n var index = 0\n var ascii = ''\n buffer.forEach((byte) => {\n if (index % 16 === 0) {\n string += this.numHex(index, 8) + ': '\n }\n string += this.numHex(byte)\n\n // Create the ASCII representation if printable\n if (byte >= 32 && byte <= 126) {\n ascii += String.fromCharCode(byte)\n } else {\n ascii += ' '\n }\n\n index++\n\n if (index % 16 === 0) {\n string += ' ' + ascii + '\\n'\n ascii = ''\n } else {\n string += ' '\n }\n })\n\n // We're done printing all the bytes. Now check to see if we ended in the\n // middle of a line. If so we have to print out the final ASCII if\n // requested.\n if (index % 16 != 0) {\n var existing_length = (index % 16) - 1 + (index % 16) * 2\n // 47 is (16 * 2) + 15 separator spaces\n var filler = ' '.repeat(47 - existing_length)\n var ascii_filler = ' '.repeat(16 - ascii.length)\n string += filler + ' ' + ascii + ascii_filler\n }\n return string\n },\n numHex(num, width = 2) {\n var hex = num.toString(16)\n return '0'.repeat(width - hex.length) + hex\n },\n },\n}\n</script>\n<style scoped>\n.v-textarea :deep(textarea) {\n margin-top: 10px;\n font-family: 'Courier New', Courier, monospace;\n}\n</style>\n","import mod from \"-!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./RawDialog.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/thread-loader/dist/cjs.js!../../../../../node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./RawDialog.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./RawDialog.vue?vue&type=template&id=7b88fb20&scoped=true&\"\nimport script from \"./RawDialog.vue?vue&type=script&lang=js&\"\nexport * from \"./RawDialog.vue?vue&type=script&lang=js&\"\nimport style0 from \"./RawDialog.vue?vue&type=style&index=0&id=7b88fb20&prod&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"7b88fb20\",\n null\n \n)\n\nexport default component.exports","// Imports\nimport ___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___ from \"../../../../../node_modules/@vue/cli-service/node_modules/css-loader/dist/runtime/noSourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../../../node_modules/@vue/cli-service/node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_NO_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".v-textarea[data-v-7b88fb20] textarea{margin-top:10px;font-family:Courier New,Courier,monospace}\", \"\"]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../node_modules/@vue/cli-service/node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!../../../../../node_modules/@vue/cli-service/node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!../../../../../node_modules/@vue/cli-service/node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[3]!../../../../../node_modules/@vue/cli-service/node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./RawDialog.vue?vue&type=style&index=0&id=7b88fb20&prod&scoped=true&lang=css&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"99dd9964\", content, true, {\"sourceMap\":false,\"shadowMode\":false});"],"names":["cov_2gt25r962d","actualCoverage","s","render","f","_vm","this","_c","_self","attrs","on","$event","b","type","indexOf","_k","keyCode","key","isVisible","model","value","callback","$$v","expression","scopedSlots","_u","fn","_ref","_g","_b","copyRawData","_v","_s","_ref2","downloadRawData","header","_ref3","pause","buttonIcon","buttonLabel","staticClass","receivedTime","receivedCount","rawData","staticRenderFns","mixins","Updater","props","String","visible","Boolean","targetName","packetName","data","paused","computed","get","set","bool","$emit","methods","buildRawData","concat","navigator","clipboard","writeText","blob","Blob","link","document","createElement","href","URL","createObjectURL","dt","format","Date","now","setAttribute","click","update","updateTelemetry","updateCommand","_this","api","get_tlm_buffer","then","result","buffer_data","buffer","undefined","raw","utf8Encode","TextEncoder","encode","time","received_count","formatBuffer","_this2","get_cmd_buffer","_this3","string","index","ascii","forEach","byte","numHex","fromCharCode","existing_length","filler","repeat","ascii_filler","length","num","width","arguments","hex","toString","component","___CSS_LOADER_EXPORT___","push","module","id","content","__esModule","default","locals","exports","add"],"sourceRoot":""}
@@ -1,2 +1,2 @@
1
- (self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]=self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]||[]).push([[96],{6096:function(e,t,n){"use strict";function a(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",t="75253cfc4e562133211ca6266a4e61567fc5954d",n=new Function("return this")(),s="__coverage__",l={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",statementMap:{0:{start:{line:1,column:13},end:{line:2,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:1,column:1036}},4:{start:{line:1,column:238},end:{line:1,column:252}},5:{start:{line:1,column:314},end:{line:1,column:400}},6:{start:{line:1,column:572},end:{line:1,column:593}},7:{start:{line:1,column:923},end:{line:1,column:951}},8:{start:{line:3,column:22},end:{line:3,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:2,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:222},end:{line:1,column:223}},loc:{start:{line:1,column:237},end:{line:1,column:253}},line:1},2:{name:"(anonymous_2)",decl:{start:{line:1,column:294},end:{line:1,column:295}},loc:{start:{line:1,column:313},end:{line:1,column:401}},line:1},3:{name:"(anonymous_3)",decl:{start:{line:1,column:556},end:{line:1,column:557}},loc:{start:{line:1,column:571},end:{line:1,column:594}},line:1},4:{name:"(anonymous_4)",decl:{start:{line:1,column:906},end:{line:1,column:907}},loc:{start:{line:1,column:922},end:{line:1,column:952}},line:1}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},f:{0:0,1:0,2:0,3:0,4:0},b:{},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"75253cfc4e562133211ca6266a4e61567fc5954d"},o=n[s]||(n[s]={});o[e]&&o[e].hash===t||(o[e]=l);var r=o[e];return a=function(){return r},r}n.r(t),n.d(t,{default:function(){return O}}),a(),a().s[0]++;var s=function(){a().f[0]++;var e=(a().s[1]++,this),t=(a().s[2]++,e._self._c);return a().s[3]++,t("div",[t("top-bar",{attrs:{menus:e.menus,title:e.title}}),t("v-card",[t("v-tabs",{attrs:{"fixed-tabs":""},model:{value:e.curTab,callback:function(t){a().f[1]++,a().s[4]++,e.curTab=t},expression:"curTab"}},e._l(e.tabs,(function(n,s){return a().f[2]++,a().s[5]++,t("v-tab",{key:s,attrs:{to:n.url}},[e._v(" "+e._s(n.name)+" ")])})),1),t("router-view",{attrs:{"refresh-interval":e.refreshInterval}}),t("v-dialog",{attrs:{"max-width":"300"},model:{value:e.optionsDialog,callback:function(t){a().f[3]++,a().s[6]++,e.optionsDialog=t},expression:"optionsDialog"}},[t("v-card",[t("v-system-bar",[t("v-spacer"),t("span",[e._v("Options")]),t("v-spacer")],1),t("div",{staticClass:"pa-3"},[t("v-text-field",{attrs:{min:"0",max:"10000",step:"100",type:"number",label:"Refresh Interval (ms)",value:e.refreshInterval},on:{change:function(t){a().f[4]++,a().s[7]++,e.refreshInterval=t}}})],1)],1)],1)],1),t("div",{staticStyle:{height:"20px"}}),t("log-messages")],1)},l=(a().s[8]++,[]),o=(n(7950),n(4908),function(){var e=this,t=e._self._c;return t("v-card",[t("v-card-title",[e._v(" Log Messages "),t("v-tooltip",{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function(n){var a=n.on,s=n.attrs;return[t("div",e._g(e._b({},"div",s,!1),a),[t("v-btn",{attrs:{icon:"","data-test":"pause"},on:{click:e.pause}},[t("v-icon",[e._v(" "+e._s(e.buttonIcon)+" ")])],1)],1)]}}])},[t("span",[e._v(" "+e._s(e.buttonLabel)+" ")])]),t("v-spacer"),t("v-select",{staticClass:"mr-2",attrs:{label:"Filter by Severity","hide-details":"",items:e.logLevels,"data-test":"log-messages-level"},model:{value:e.logLevel,callback:function(t){e.logLevel=t},expression:"logLevel"}}),t("v-spacer"),t("v-text-field",{attrs:{"append-icon":"mdi-magnify",label:"Search","single-line":"","hide-details":"","data-test":"search-log-messages"},model:{value:e.search,callback:function(t){e.search=t},expression:"search"}})],1),t("v-data-table",{attrs:{headers:e.headers,items:e.shownData,search:e.search,"calculate-widths":"","disable-pagination":"","hide-default-footer":"","multi-sort":"",dense:"",height:"45vh","data-test":"log-messages"},scopedSlots:e._u([{key:"item.timestamp",fn:function(n){var a=n.item;return[t("time",{attrs:{title:a.timestamp,datetime:a.timestamp}},[e._v(" "+e._s(a.timestamp)+" ")])]}},{key:"item.severity",fn:function(n){var a=n.item;return[t("span",{class:e.getColorClass(a.severity)},[e._v(e._s(a.severity))])]}},{key:"item.log",fn:function(n){var a=n.item;return[t("div",{staticStyle:{"white-space":"pre-wrap"}},[e._v(e._s(a.log))])]}}])})],1)}),r=[],i=(n(1245),n(9805),n(5342),n(8188),n(3450),n(8233),n(5940),n(1639),n(8178),n(9413)),c=n(5488),u=n(6964),m=n(426),d=n(7871),v=n(7146);v.ju.staleThreshold=10;var p=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"/openc3-api/cable";(0,m.Z)(this,e),this._cable=null,this._url=t}return(0,d.Z)(e,[{key:"disconnect",value:function(){this._cable.disconnect()}},{key:"createSubscription",value:function(e,t){var n=this,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then((function(t){if(t&&OpenC3Auth.setTokens(),null==n._cable){var l=n._url+"?scope="+window.openc3Scope+"&authorization="+localStorage.openc3Token;n._cable=v.zD(l)}return n._cable.subscriptions.create((0,u.Z)({channel:e},s),a)}))}},{key:"recordPing",value:function(){this._cable.connection.monitor.recordPing()}}]),e}(),A={props:{history_count:{type:Number,default:200}},data:function(){return{data:[],shownData:[],logLevels:["DEBUG","INFO","WARN","ERROR","FATAL"],logLevel:"INFO",search:"",headers:[{text:"Time",value:"timestamp",width:200},{text:"Severity",value:"severity"},{text:"Source",value:"microservice_name"},{text:"Message",value:"log"}],cable:new p,subscription:null,paused:!1}},computed:{buttonLabel:function(){return this.paused?"Resume":"Pause"},buttonIcon:function(){return this.paused?"mdi-play":"mdi-pause"}},watch:{logLevel:function(e,t){this.createSubscription()}},created:function(){this.createSubscription()},destroyed:function(){this.subscription&&this.subscription.unsubscribe(),this.cable.disconnect()},methods:{pause:function(){this.paused=!this.paused},createSubscription:function(){var e=this;this.subscription&&(this.subscription.unsubscribe(),this.data=[],this.shownData=this.data),this.cable.createSubscription("MessagesChannel",window.openc3Scope,{received:function(t){e.cable.recordPing(),t.length>e.history_count&&t.splice(0,t.length-e.history_count),t=t.filter((function(t){switch(e.logLevel){case"DEBUG":return!0;case"INFO":if("DEBUG"!==t.severity)return!0;break;case"WARN":if("DEBUG"!==t.severity&&"INFO"!==t.severity)return!0;break;case"ERROR":if("DEBUG"!==t.severity&&"INFO"!==t.severity&&"WARN"!==t.severity)return!0;break;case"FATAL":if("DEBUG"!==t.severity&&"INFO"!==t.severity&&"WARN"!==t.severity&&"ERROR"!==t.severity)return!0;break}return!1})),t.map((function(t){if(t.timestamp=e.formatDate(t["@timestamp"]),t.log.raw&&"String"===t.log.json_class){for(var n="0x",a=0;a<t.log.raw.length;a++){var s=t.log.raw[a].toString(16).toUpperCase();s.length<2&&(s="0"+s),n+=s}t.log=n}else t.log=t.log.replaceAll("\\n","\n")})),e.data=t.reverse().concat(e.data),e.data.length>e.history_count&&(e.data.length=e.history_count),e.paused||(e.shownData=e.data)}},{history_count:this.history_count}).then((function(t){e.subscription=t}))},formatDate:function(e){return(0,i.Z)((0,c.Z)(e),"yyyy-MM-dd HH:mm:ss.SSS")},getColorClass:function(e){return"INFO"===e?"openc3-green":"WARN"===e?"openc3-yellow":"ERROR"===e||"FATAL"===e?"openc3-red":this.$vuetify.theme.dark?"openc3-white":"openc3-black"}}},f=A,h=n(3483),b=(0,h.Z)(f,o,r,!1,null,null,null),g=b.exports,C=function(){var e=this,t=e._self._c;return t("mounting-portal",{attrs:{"mount-to":"#openc3-menu",append:""}},[t("div",{staticClass:"v-toolbar__content"},[e._l(e.menus,(function(n,a){return t("v-menu",{key:a,attrs:{"offset-y":""},scopedSlots:e._u([{key:"activator",fn:function(a){var s=a.on,l=a.attrs;return[t("v-btn",e._g(e._b({staticClass:"mx-1",attrs:{outlined:"","data-test":e.formatDT("".concat(e.title," ").concat(n.label))}},"v-btn",l,!1),s),[t("span",{domProps:{textContent:e._s(n.label)}}),t("v-icon",{attrs:{right:""}},[e._v(" mdi-menu-down ")])],1)]}}],null,!0)},[t("v-list",[t("v-radio-group",{staticClass:"ma-0 pa-0",attrs:{value:n.radioGroup,"hide-details":"",dense:""}},[e._l(n.items,(function(a,s){return[a.divider?t("v-divider"):t("v-list-item",{key:s,attrs:{disabled:a.disabled,"data-test":e.formatDT("".concat(e.title," ").concat(n.label," ").concat(a.label))},on:{click:function(e){return a.command(a)}}},[a.radio?t("v-list-item-action",[t("v-radio",{attrs:{color:"secondary",label:a.label,value:a.label}})],1):e._e(),a.checkbox?t("v-list-item-action",[t("v-checkbox",{attrs:{color:"secondary",label:a.label},model:{value:a.checked,callback:function(t){e.$set(a,"checked",t)},expression:"option.checked"}})],1):e._e(),a.icon?t("v-list-item-icon",[t("v-icon",{attrs:{disabled:a.disabled}},[e._v(e._s(a.icon))])],1):e._e(),a.radio||a.checkbox?e._e():t("v-list-item-title",{style:"cursor: pointer;"+(a.disabled?"opacity: 0.2":"")},[e._v(e._s(a.label))])],1)]}))],2)],1)],1)})),t("v-spacer"),t("v-toolbar-title",[e._v(e._s(e.title))]),t("v-spacer")],2)])},_=[],y={props:{menus:{type:Array,default:function(){return[]}},title:{type:String,default:""}},methods:{formatDT:function(e){return e.replaceAll(" ","-").toLowerCase()}},mounted:function(){"COSMOS "===this.title.substring(0,7)?document.title=this.title.substring(7):document.title=this.title}},S=y,k=(n(4888),(0,h.Z)(S,C,_,!1,null,"2eb37f67",null)),T=k.exports;function x(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",t="d9b7390842e35bfa96bb69f8f3bd732a80b4a478",n=new Function("return this")(),a="__coverage__",s={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",statementMap:{0:{start:{line:10,column:4},end:{line:55,column:5}},1:{start:{line:49,column:16},end:{line:49,column:41}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:9},end:{line:56,column:3}},line:9},1:{name:"(anonymous_1)",decl:{start:{line:48,column:23},end:{line:48,column:24}},loc:{start:{line:48,column:29},end:{line:50,column:15}},line:48}},branchMap:{},s:{0:0,1:0},f:{0:0,1:0},b:{},inputSourceMap:{version:3,sources:["CmdTlmServer.vue"],names:[],mappings:";AA2DA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"CmdTlmServer.vue",sourceRoot:"src/tools/CmdTlmServer",sourcesContent:['\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license \n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <div>\n <top-bar :menus="menus" :title="title" />\n <v-card>\n <v-tabs v-model="curTab" fixed-tabs>\n <v-tab v-for="(tab, index) in tabs" :key="index" :to="tab.url">\n {{ tab.name }}\n </v-tab>\n </v-tabs>\n <router-view :refresh-interval="refreshInterval" />\n <v-dialog v-model="optionsDialog" max-width="300">\n <v-card>\n <v-system-bar>\n <v-spacer />\n <span>Options</span>\n <v-spacer />\n </v-system-bar>\n <div class="pa-3">\n <v-text-field\n min="0"\n max="10000"\n step="100"\n type="number"\n label="Refresh Interval (ms)"\n :value="refreshInterval"\n @change="refreshInterval = $event"\n />\n </div>\n </v-card>\n </v-dialog>\n </v-card>\n <div style="height: 20px" />\n <log-messages />\n </div>\n</template>\n\n<script>\nimport LogMessages from \'@openc3/tool-common/src/components/LogMessages\'\nimport TopBar from \'@openc3/tool-common/src/components/TopBar\'\nexport default {\n components: {\n LogMessages,\n TopBar,\n },\n data() {\n return {\n title: \'COSMOS CmdTlmServer\',\n curTab: null,\n tabs: [\n {\n name: \'Interfaces\',\n url: \'/interfaces\',\n },\n {\n name: \'Targets\',\n url: \'/targets\',\n },\n {\n name: \'Cmd Packets\',\n url: \'/cmd-packets\',\n },\n {\n name: \'Tlm Packets\',\n url: \'/tlm-packets\',\n },\n {\n name: \'Routers\',\n url: \'/routers\',\n },\n {\n name: \'Status\',\n url: \'/status\',\n },\n ],\n updater: null,\n refreshInterval: 1000,\n optionsDialog: false,\n menus: [\n {\n label: \'File\',\n items: [\n {\n label: \'Options\',\n command: () => {\n this.optionsDialog = true\n },\n },\n ],\n },\n ],\n }\n },\n}\n<\/script>\n\n<style scoped>\n.v-list :deep(.v-label) {\n margin-left: 5px;\n}\n.v-list-item__icon {\n /* For some reason the default margin-right is huge */\n margin-right: 15px !important;\n}\n.v-list-item__title {\n color: white;\n}\n</style>\n']},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"d9b7390842e35bfa96bb69f8f3bd732a80b4a478"},l=n[a]||(n[a]={});l[e]&&l[e].hash===t||(l[e]=s);var o=l[e];return x=function(){return o},o}x();var w={components:{LogMessages:g,TopBar:T},data:function(){var e=this;return x().f[0]++,x().s[0]++,{title:"COSMOS CmdTlmServer",curTab:null,tabs:[{name:"Interfaces",url:"/interfaces"},{name:"Targets",url:"/targets"},{name:"Cmd Packets",url:"/cmd-packets"},{name:"Tlm Packets",url:"/tlm-packets"},{name:"Routers",url:"/routers"},{name:"Status",url:"/status"}],updater:null,refreshInterval:1e3,optionsDialog:!1,menus:[{label:"File",items:[{label:"Options",command:function(){x().f[1]++,x().s[1]++,e.optionsDialog=!0}}]}]}}},R=w,I=(n(4907),(0,h.Z)(R,s,l,!1,null,"435cb5a8",null)),O=I.exports},3618:function(e,t,n){"use strict";n.r(t);var a=n(9601),s=n.n(a),l=n(2609),o=n.n(l),r=o()(s());r.push([e.id,".v-list[data-v-435cb5a8] .v-label{margin-left:5px}.v-list-item__icon[data-v-435cb5a8]{margin-right:15px!important}.v-list-item__title[data-v-435cb5a8]{color:#fff}",""]),t["default"]=r},6294:function(e,t,n){"use strict";n.r(t);var a=n(9601),s=n.n(a),l=n(2609),o=n.n(l),r=o()(s());r.push([e.id,".v-list[data-v-2eb37f67] .v-label{margin-left:5px}.v-list-item__icon[data-v-2eb37f67]{margin-right:15px!important}.v-list-item__title[data-v-2eb37f67]{color:#fff}",""]),t["default"]=r},4907:function(e,t,n){var a=n(3618);a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals);var s=n(3514).Z;s("52afc085",a,!0,{sourceMap:!1,shadowMode:!1})},4888:function(e,t,n){var a=n(6294);a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals);var s=n(3514).Z;s("706a3f6d",a,!0,{sourceMap:!1,shadowMode:!1})}}]);
2
- //# sourceMappingURL=96.js.map
1
+ (self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]=self["webpackChunk_openc3_cosmos_tool_cmdtlmserver"]||[]).push([[521],{521:function(e,t,n){"use strict";function a(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",t="75253cfc4e562133211ca6266a4e61567fc5954d",n=new Function("return this")(),s="__coverage__",l={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",statementMap:{0:{start:{line:1,column:13},end:{line:2,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:1,column:1036}},4:{start:{line:1,column:238},end:{line:1,column:252}},5:{start:{line:1,column:314},end:{line:1,column:400}},6:{start:{line:1,column:572},end:{line:1,column:593}},7:{start:{line:1,column:923},end:{line:1,column:951}},8:{start:{line:3,column:22},end:{line:3,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:2,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:222},end:{line:1,column:223}},loc:{start:{line:1,column:237},end:{line:1,column:253}},line:1},2:{name:"(anonymous_2)",decl:{start:{line:1,column:294},end:{line:1,column:295}},loc:{start:{line:1,column:313},end:{line:1,column:401}},line:1},3:{name:"(anonymous_3)",decl:{start:{line:1,column:556},end:{line:1,column:557}},loc:{start:{line:1,column:571},end:{line:1,column:594}},line:1},4:{name:"(anonymous_4)",decl:{start:{line:1,column:906},end:{line:1,column:907}},loc:{start:{line:1,column:922},end:{line:1,column:952}},line:1}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},f:{0:0,1:0,2:0,3:0,4:0},b:{},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"75253cfc4e562133211ca6266a4e61567fc5954d"},o=n[s]||(n[s]={});o[e]&&o[e].hash===t||(o[e]=l);var r=o[e];return a=function(){return r},r}n.r(t),n.d(t,{default:function(){return O}}),a(),a().s[0]++;var s=function(){a().f[0]++;var e=(a().s[1]++,this),t=(a().s[2]++,e._self._c);return a().s[3]++,t("div",[t("top-bar",{attrs:{menus:e.menus,title:e.title}}),t("v-card",[t("v-tabs",{attrs:{"fixed-tabs":""},model:{value:e.curTab,callback:function(t){a().f[1]++,a().s[4]++,e.curTab=t},expression:"curTab"}},e._l(e.tabs,(function(n,s){return a().f[2]++,a().s[5]++,t("v-tab",{key:s,attrs:{to:n.url}},[e._v(" "+e._s(n.name)+" ")])})),1),t("router-view",{attrs:{"refresh-interval":e.refreshInterval}}),t("v-dialog",{attrs:{"max-width":"300"},model:{value:e.optionsDialog,callback:function(t){a().f[3]++,a().s[6]++,e.optionsDialog=t},expression:"optionsDialog"}},[t("v-card",[t("v-system-bar",[t("v-spacer"),t("span",[e._v("Options")]),t("v-spacer")],1),t("div",{staticClass:"pa-3"},[t("v-text-field",{attrs:{min:"0",max:"10000",step:"100",type:"number",label:"Refresh Interval (ms)",value:e.refreshInterval},on:{change:function(t){a().f[4]++,a().s[7]++,e.refreshInterval=t}}})],1)],1)],1)],1),t("div",{staticStyle:{height:"20px"}}),t("log-messages")],1)},l=(a().s[8]++,[]),o=(n(7950),n(4908),function(){var e=this,t=e._self._c;return t("v-card",[t("v-card-title",[e._v(" Log Messages "),t("v-tooltip",{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function(n){var a=n.on,s=n.attrs;return[t("div",e._g(e._b({},"div",s,!1),a),[t("v-btn",{attrs:{icon:"","data-test":"pause"},on:{click:e.pause}},[t("v-icon",[e._v(" "+e._s(e.buttonIcon)+" ")])],1)],1)]}}])},[t("span",[e._v(" "+e._s(e.buttonLabel)+" ")])]),t("v-spacer"),t("v-select",{staticClass:"mr-2",attrs:{label:"Filter by Severity","hide-details":"",items:e.logLevels,"data-test":"log-messages-level"},model:{value:e.logLevel,callback:function(t){e.logLevel=t},expression:"logLevel"}}),t("v-spacer"),t("v-text-field",{attrs:{"append-icon":"mdi-magnify",label:"Search","single-line":"","hide-details":"","data-test":"search-log-messages"},model:{value:e.search,callback:function(t){e.search=t},expression:"search"}})],1),t("v-data-table",{attrs:{headers:e.headers,items:e.shownData,search:e.search,"calculate-widths":"","disable-pagination":"","hide-default-footer":"","multi-sort":"",dense:"",height:"45vh","data-test":"log-messages"},scopedSlots:e._u([{key:"item.timestamp",fn:function(n){var a=n.item;return[t("time",{attrs:{title:a.timestamp,datetime:a.timestamp}},[e._v(" "+e._s(a.timestamp)+" ")])]}},{key:"item.severity",fn:function(n){var a=n.item;return[t("span",{class:e.getColorClass(a.severity)},[e._v(e._s(a.severity))])]}},{key:"item.log",fn:function(n){var a=n.item;return[t("div",{staticStyle:{"white-space":"pre-wrap"}},[e._v(e._s(a.log))])]}}])})],1)}),r=[],i=(n(1245),n(9805),n(5342),n(8188),n(3450),n(8233),n(5940),n(1639),n(8178),n(9413)),c=n(5488),u=n(6964),m=n(426),d=n(7871),v=n(7146);v.ju.staleThreshold=10;var p=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"/openc3-api/cable";(0,m.Z)(this,e),this._cable=null,this._url=t}return(0,d.Z)(e,[{key:"disconnect",value:function(){this._cable.disconnect()}},{key:"createSubscription",value:function(e,t){var n=this,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then((function(t){if(t&&OpenC3Auth.setTokens(),null==n._cable){var l=n._url+"?scope="+window.openc3Scope+"&authorization="+localStorage.openc3Token;n._cable=v.zD(l)}return n._cable.subscriptions.create((0,u.Z)({channel:e},s),a)}))}},{key:"recordPing",value:function(){this._cable.connection.monitor.recordPing()}}]),e}(),A={props:{history_count:{type:Number,default:200}},data:function(){return{data:[],shownData:[],logLevels:["DEBUG","INFO","WARN","ERROR","FATAL"],logLevel:"INFO",search:"",headers:[{text:"Time",value:"timestamp",width:200},{text:"Severity",value:"severity"},{text:"Source",value:"microservice_name"},{text:"Message",value:"log"}],cable:new p,subscription:null,paused:!1}},computed:{buttonLabel:function(){return this.paused?"Resume":"Pause"},buttonIcon:function(){return this.paused?"mdi-play":"mdi-pause"}},watch:{logLevel:function(e,t){this.createSubscription()}},created:function(){this.createSubscription()},destroyed:function(){this.subscription&&this.subscription.unsubscribe(),this.cable.disconnect()},methods:{pause:function(){this.paused=!this.paused},createSubscription:function(){var e=this;this.subscription&&(this.subscription.unsubscribe(),this.data=[],this.shownData=this.data),this.cable.createSubscription("MessagesChannel",window.openc3Scope,{received:function(t){e.cable.recordPing(),t.length>e.history_count&&t.splice(0,t.length-e.history_count),t=t.filter((function(t){switch(e.logLevel){case"DEBUG":return!0;case"INFO":if("DEBUG"!==t.severity)return!0;break;case"WARN":if("DEBUG"!==t.severity&&"INFO"!==t.severity)return!0;break;case"ERROR":if("DEBUG"!==t.severity&&"INFO"!==t.severity&&"WARN"!==t.severity)return!0;break;case"FATAL":if("DEBUG"!==t.severity&&"INFO"!==t.severity&&"WARN"!==t.severity&&"ERROR"!==t.severity)return!0;break}return!1})),t.map((function(t){if(t.timestamp=e.formatDate(t["@timestamp"]),t.log.raw&&"String"===t.log.json_class){for(var n="0x",a=0;a<t.log.raw.length;a++){var s=t.log.raw[a].toString(16).toUpperCase();s.length<2&&(s="0"+s),n+=s}t.log=n}else t.log=t.log.replaceAll("\\n","\n")})),e.data=t.reverse().concat(e.data),e.data.length>e.history_count&&(e.data.length=e.history_count),e.paused||(e.shownData=e.data)}},{history_count:this.history_count}).then((function(t){e.subscription=t}))},formatDate:function(e){return(0,i.Z)((0,c.Z)(e),"yyyy-MM-dd HH:mm:ss.SSS")},getColorClass:function(e){return"INFO"===e?"openc3-green":"WARN"===e?"openc3-yellow":"ERROR"===e||"FATAL"===e?"openc3-red":this.$vuetify.theme.dark?"openc3-white":"openc3-black"}}},f=A,h=n(3287),b=(0,h.Z)(f,o,r,!1,null,null,null),g=b.exports,C=function(){var e=this,t=e._self._c;return t("mounting-portal",{attrs:{"mount-to":"#openc3-menu",append:""}},[t("div",{staticClass:"v-toolbar__content"},[e._l(e.menus,(function(n,a){return t("v-menu",{key:a,attrs:{"offset-y":""},scopedSlots:e._u([{key:"activator",fn:function(a){var s=a.on,l=a.attrs;return[t("v-btn",e._g(e._b({staticClass:"mx-1",attrs:{outlined:"","data-test":e.formatDT("".concat(e.title," ").concat(n.label))}},"v-btn",l,!1),s),[t("span",{domProps:{textContent:e._s(n.label)}}),t("v-icon",{attrs:{right:""}},[e._v(" mdi-menu-down ")])],1)]}}],null,!0)},[t("v-list",[t("v-radio-group",{staticClass:"ma-0 pa-0",attrs:{value:n.radioGroup,"hide-details":"",dense:""}},[e._l(n.items,(function(a,s){return[a.divider?t("v-divider"):t("v-list-item",{key:s,attrs:{disabled:a.disabled,"data-test":e.formatDT("".concat(e.title," ").concat(n.label," ").concat(a.label))},on:{click:function(e){return a.command(a)}}},[a.radio?t("v-list-item-action",[t("v-radio",{attrs:{color:"secondary",label:a.label,value:a.label}})],1):e._e(),a.checkbox?t("v-list-item-action",[t("v-checkbox",{attrs:{color:"secondary",label:a.label},model:{value:a.checked,callback:function(t){e.$set(a,"checked",t)},expression:"option.checked"}})],1):e._e(),a.icon?t("v-list-item-icon",[t("v-icon",{attrs:{disabled:a.disabled}},[e._v(e._s(a.icon))])],1):e._e(),a.radio||a.checkbox?e._e():t("v-list-item-title",{style:"cursor: pointer;"+(a.disabled?"opacity: 0.2":"")},[e._v(e._s(a.label))])],1)]}))],2)],1)],1)})),t("v-spacer"),t("v-toolbar-title",[e._v(e._s(e.title))]),t("v-spacer")],2)])},_=[],y={props:{menus:{type:Array,default:function(){return[]}},title:{type:String,default:""}},methods:{formatDT:function(e){return e.replaceAll(" ","-").toLowerCase()}},mounted:function(){"COSMOS "===this.title.substring(0,7)?document.title=this.title.substring(7):document.title=this.title}},S=y,k=(n(2916),(0,h.Z)(S,C,_,!1,null,"2eb37f67",null)),T=k.exports;function x(){var e="/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",t="d9b7390842e35bfa96bb69f8f3bd732a80b4a478",n=new Function("return this")(),a="__coverage__",s={path:"/openc3/plugins/packages/openc3-cosmos-tool-cmdtlmserver/src/tools/CmdTlmServer/CmdTlmServer.vue",statementMap:{0:{start:{line:10,column:4},end:{line:55,column:5}},1:{start:{line:49,column:16},end:{line:49,column:41}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:9},end:{line:56,column:3}},line:9},1:{name:"(anonymous_1)",decl:{start:{line:48,column:23},end:{line:48,column:24}},loc:{start:{line:48,column:29},end:{line:50,column:15}},line:48}},branchMap:{},s:{0:0,1:0},f:{0:0,1:0},b:{},inputSourceMap:{version:3,sources:["CmdTlmServer.vue"],names:[],mappings:";AA2DA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"CmdTlmServer.vue",sourceRoot:"src/tools/CmdTlmServer",sourcesContent:['\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license \n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <div>\n <top-bar :menus="menus" :title="title" />\n <v-card>\n <v-tabs v-model="curTab" fixed-tabs>\n <v-tab v-for="(tab, index) in tabs" :key="index" :to="tab.url">\n {{ tab.name }}\n </v-tab>\n </v-tabs>\n <router-view :refresh-interval="refreshInterval" />\n <v-dialog v-model="optionsDialog" max-width="300">\n <v-card>\n <v-system-bar>\n <v-spacer />\n <span>Options</span>\n <v-spacer />\n </v-system-bar>\n <div class="pa-3">\n <v-text-field\n min="0"\n max="10000"\n step="100"\n type="number"\n label="Refresh Interval (ms)"\n :value="refreshInterval"\n @change="refreshInterval = $event"\n />\n </div>\n </v-card>\n </v-dialog>\n </v-card>\n <div style="height: 20px" />\n <log-messages />\n </div>\n</template>\n\n<script>\nimport LogMessages from \'@openc3/tool-common/src/components/LogMessages\'\nimport TopBar from \'@openc3/tool-common/src/components/TopBar\'\nexport default {\n components: {\n LogMessages,\n TopBar,\n },\n data() {\n return {\n title: \'COSMOS CmdTlmServer\',\n curTab: null,\n tabs: [\n {\n name: \'Interfaces\',\n url: \'/interfaces\',\n },\n {\n name: \'Targets\',\n url: \'/targets\',\n },\n {\n name: \'Cmd Packets\',\n url: \'/cmd-packets\',\n },\n {\n name: \'Tlm Packets\',\n url: \'/tlm-packets\',\n },\n {\n name: \'Routers\',\n url: \'/routers\',\n },\n {\n name: \'Status\',\n url: \'/status\',\n },\n ],\n updater: null,\n refreshInterval: 1000,\n optionsDialog: false,\n menus: [\n {\n label: \'File\',\n items: [\n {\n label: \'Options\',\n command: () => {\n this.optionsDialog = true\n },\n },\n ],\n },\n ],\n }\n },\n}\n<\/script>\n\n<style scoped>\n.v-list :deep(.v-label) {\n margin-left: 5px;\n}\n.v-list-item__icon {\n /* For some reason the default margin-right is huge */\n margin-right: 15px !important;\n}\n.v-list-item__title {\n color: white;\n}\n</style>\n']},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"d9b7390842e35bfa96bb69f8f3bd732a80b4a478"},l=n[a]||(n[a]={});l[e]&&l[e].hash===t||(l[e]=s);var o=l[e];return x=function(){return o},o}x();var w={components:{LogMessages:g,TopBar:T},data:function(){var e=this;return x().f[0]++,x().s[0]++,{title:"COSMOS CmdTlmServer",curTab:null,tabs:[{name:"Interfaces",url:"/interfaces"},{name:"Targets",url:"/targets"},{name:"Cmd Packets",url:"/cmd-packets"},{name:"Tlm Packets",url:"/tlm-packets"},{name:"Routers",url:"/routers"},{name:"Status",url:"/status"}],updater:null,refreshInterval:1e3,optionsDialog:!1,menus:[{label:"File",items:[{label:"Options",command:function(){x().f[1]++,x().s[1]++,e.optionsDialog=!0}}]}]}}},R=w,I=(n(1888),(0,h.Z)(R,s,l,!1,null,"435cb5a8",null)),O=I.exports},4186:function(e,t,n){"use strict";n.r(t);var a=n(3467),s=n.n(a),l=n(8715),o=n.n(l),r=o()(s());r.push([e.id,".v-list[data-v-435cb5a8] .v-label{margin-left:5px}.v-list-item__icon[data-v-435cb5a8]{margin-right:15px!important}.v-list-item__title[data-v-435cb5a8]{color:#fff}",""]),t["default"]=r},3535:function(e,t,n){"use strict";n.r(t);var a=n(3467),s=n.n(a),l=n(8715),o=n.n(l),r=o()(s());r.push([e.id,".v-list[data-v-2eb37f67] .v-label{margin-left:5px}.v-list-item__icon[data-v-2eb37f67]{margin-right:15px!important}.v-list-item__title[data-v-2eb37f67]{color:#fff}",""]),t["default"]=r},1888:function(e,t,n){var a=n(4186);a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals);var s=n(3514).Z;s("1d2afc1a",a,!0,{sourceMap:!1,shadowMode:!1})},2916:function(e,t,n){var a=n(3535);a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[e.id,a,""]]),a.locals&&(e.exports=a.locals);var s=n(3514).Z;s("5f049f38",a,!0,{sourceMap:!1,shadowMode:!1})}}]);
2
+ //# sourceMappingURL=521.js.map