{"version":3,"sources":["webpack:///./src/views/vessel/Diagnostics/index.vue?7f36","webpack:///./src/views/vessel/Diagnostics/DiagnosticsKyma.vue?1006","webpack:///./src/components/diagnostics/LongTrendFilterModal.vue?b6ef","webpack:///./src/services/api.ts","webpack:///./src/components/diagnostics/LongTrendFilterModal.vue","webpack:///./src/components/diagnostics/LongTrendFilterModal.vue?4451","webpack:///./src/components/diagnostics/LongTrendFilterModal.vue?0f17","webpack:///./src/views/vessel/Diagnostics/DiagnosticsKyma.vue","webpack:///./src/views/vessel/Diagnostics/DiagnosticsKyma.vue?1e16","webpack:///./src/views/vessel/Diagnostics/DiagnosticsKyma.vue?4c1b","webpack:///./src/views/vessel/Diagnostics/DiagnosticsISO.vue?e0bf","webpack:///./src/Scripts/utilities/auto-granularity.js","webpack:///./src/components/Vessel/VesselEventsTable.vue?61bc","webpack:///./src/components/Vessel/VesselEventsTable.vue","webpack:///./src/components/Vessel/VesselEventsTable.vue?abc7","webpack:///./src/components/Vessel/VesselEventsTable.vue?8cae","webpack:///./src/components/PerformanceIndicatorChart.vue?c3de","webpack:///./src/components/PerformanceIndicatorChart.vue","webpack:///./src/components/PerformanceIndicatorChart.vue?9cd6","webpack:///./src/components/PerformanceIndicatorChart.vue?8ad5","webpack:///./src/views/vessel/Diagnostics/DiagnosticsISO.vue","webpack:///./src/views/vessel/Diagnostics/DiagnosticsISO.vue?1844","webpack:///./src/views/vessel/Diagnostics/DiagnosticsISO.vue?4df7","webpack:///./src/views/vessel/Diagnostics/index.vue","webpack:///./src/views/vessel/Diagnostics/index.vue?cbd2","webpack:///./src/views/vessel/Diagnostics/index.vue?e492","webpack:///./src/components/Vessel/VesselEventsTable.vue?a3c4","webpack:///./src/components/PerformanceIndicatorChart.vue?8cc3","webpack:///./src/views/vessel/Diagnostics/index.vue?e91d","webpack:///../../../src/components/VTextarea/VTextarea.ts","webpack:///./src/views/vessel/Diagnostics/DiagnosticsKyma.vue?eafc"],"names":["render","_vm","this","_h","$createElement","_c","_self","staticClass","attrs","DiagnosticViewTypes","on","onViewTypeChanged","model","value","callback","$$v","DiagnosticViewType","expression","component","tag","staticRenderFns","_e","staticStyle","scopedSlots","_u","key","fn","_v","proxy","nativeOn","$event","stopPropagation","createEvent","eventTableHeaders","eventTableRows","ref","header","_s","text","_g","item","formatEventDate","date","type","origin","editEvent","event","deleteEvent","preventDefault","exportExcel","isCloudLongTrendFeatureEnabled","showSpeedLogDeviation","_b","openFilterModal","EditEventOpen","FilterModalOpen","onFilterUpdated","notification","duration","$set","message","_l","trend","longTrend","id","name","visible","showDiagnosticsDetails","indexOf","_k","keyCode","cancel","apply","arguments","dialog","fieldRequired","mcr","numericFilter","filter","_n","windBeaufort","required","isSaveDisabled","updateFilter","apiFetch","endpoint","options","accessToken","store","getters","headers","Authorization","fetch","process","response","ok","Error","status","contentType","get","includes","json","apiGet","method","apiPut","data","body","JSON","stringify","Vessels","getModule","VesselsModule","Snackbar","SnackbarModule","LongTrendFilterModal","currentVessel","minPercentMcr","maxBeaufortWind","window","expect","target","toString","test","vessel","fetchFilter","$emit","showSnackbar","color","Vue","__decorate","PropSync","Boolean","default","Component","VBtn","VCard","VCardActions","VCardText","VCardTitle","VDialog","VSelect","VSpacer","VTextField","VesselEvents","VesselEventsModule","LongTrends","LongTrendsModule","DiagnosticsKyma","detailsError","isLoading","showError","align","sortable","features","some","feature","vesselLongTrends","shipSpeedDeviationKey","Object","keys","forEach","push","allEvents","tableRows","events","timestamp","source","actions","Promise","all","fetchEvents","updateTrendEventTypes","fetchVesselLongTrends","console","warn","editVessel","open","success","vesselEvent","confirmDelete","confirmed","filterModal","vesselId","diagnosticsDetails","LongTrendExportClient","moment","utc","format","Ref","components","FeatureNotAvailable","ConfirmDialog","EditVesselEvent","DiagnosticsDetails","DiagnosticCard","VCheckbox","VDataTable","VDivider","VExpansionPanel","VExpansionPanelContent","VExpansionPanelHeader","VExpansionPanels","VIcon","VList","VListItem","VListItemTitle","VMenu","VSkeletonLoader","VSnackbar","VTooltip","eventsByVesselId","ISO19030PerformanceLogVariable","logDataMinDate","eventUpdated","chart","i","getISOChartTypePeriods","ISO19030PerformanceLogData","isAnyEventUpdated","selectedTimeInMinutes","style","maxWidth","openEventModal","tableHeaders","eventModal","typeSelectValidation","eventTypes","dateValidation","indockingDateMenu","startTimestamp","outdockingDateMenu","formattedDataMinDate","thresholdValidation","dateMenu","v","length","isSaveButtonDisabled","saveEvent","ISO19030","ISO19030Module","VesselEventsTable","isEventEditing","endTimestamp","eventType","maintenanceThreshold","comment","Number","$route","params","syncEvents","find","isEventMaintenance","dataMinDate","dateHelper","getFormatedDateString","dates","mode","row","e","updateEvent","resetFormData","titleFontSize","Prop","VDatePicker","VForm","VTextarea","title","ChartOptions","chartReady","chartEvents","formatDateForDisplay","selectedEvent","domProps","htmlStatistics","isEvaluationPeriodAvailable","hasCalculatedPeriods","PerformanceIndicatorChart","chartLoaded","mutatedPeriods","parse","periods","setTimeout","update","reflow","setDryDockingEvaluationPeriod","setEvaluationPeriodAverage","setReferencesPeriodsAverage","setDryDockingDifferenceInPerformance","setSelectedReferencePeriodAverage","setDifferenceInPerformanceOfSelectedEvent","setTriggerValue","selectedEvaluationPeriod","formatDateString","periodStartDate","selectedReferencePeriod","periodEndDate","period","periodType","referencePeriods","reduce","acc","average","findPeriodOfSelectedEvent","eventId","evaluationPeriods","lastDryDockingEvent","currentDate","dryDockingEvents","diff","lastMaintenanceEvent","maintenanceEvents","isMaintenanceEffectChart","differenceInPerformanceOfSelectedEvent","toFixed","toLowerCase","referencePeriodsWithoutCurrentAverage","triggerValue","referencePeriodsWithoutCurrent","isBefore","dryDockingDifferenceInPerformance","isDryDockingChart","set","periodLines","PeriodLine","Date","isPeriodReferenceType","firstReferenceIndex","findIndex","line","firstEvaluationIndex","delete","startDateMS","endDateMS","lineWidth","periodLineLabel","linkedTo","marker","radius","symbol","zIndex","dateMS","x","y","dataLabels","enabled","useHTML","formatter","performanceData","series","remove","scatterPoints","entries","map","scatterPointsSerie","stickyTracking","fillColor","maintenancePlotLines","dockingPlotLines","dryDockingPlotBands","selectedEventPlotBand","plotLines","html","getPlotLineLabelsHtml","valueOf","width","label","rotation","letter","plotBands","from","to","className","plotBandStartDate","plotBandEndDate","eventPeriods","isAfter","start","end","height","spacingTop","zoomType","fontFamily","Highcharts","ctx","chartSettings","legend","yAxis","labels","min","max","xAxis","plotOptions","scatter","tooltip","outside","headerFormat","pointFormat","valueDecimals","valueSuffix","xDateFormat","states","inactive","opacity","seriesData","credits","exporting","Watch","Chart","VAlert","LogVariables","LogVariablesModule","DiagnosticsISO","performanceIndicatorsLogVariable","ISOChartTypes","performanceIndicators","chartName","logVariableByName","_","isEmpty","minDate","maxDate","logDataMaxDate","minutesDiff","LogDataClient","findLogData","autoGranularity","fromDate","toDate","getTime","Math","abs","round","fetchPerformanceIndicators","fetchPerformanceIndicatorsData","state","initViewData","Store","Diagnostics","log","localStorage","setItem","strDiagnosticViewType","getItem","currentVesselLogVariables","refreshCurrentVesselLogVariables","parseInt","setDiagnosticViewType","baseMixins","mixins","extend","props","autoGrow","noResize","rowHeight","String","validator","isNaN","parseFloat","rows","computed","classes","noResizeHandle","call","watch","val","$nextTick","calculateInputHeight","$refs","input","_this$$refs$input","removeProperty","lazyValue","mounted","methods","scrollHeight","minHeight","genInput","onInput","onKeyDown","isFocused"],"mappings":"yHAAA,IAAIA,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,qBAAqB,CAACF,EAAG,SAAS,CAACE,YAAY,yBAAyBC,MAAM,CAAC,MAAQ,SAAS,UAAY,IAAI,KAAO,KAAK,CAACH,EAAG,WAAW,CAACG,MAAM,CAAC,MAAQP,EAAIQ,oBAAoB,YAAY,OAAO,MAAQ,wBAAwB,eAAe,GAAG,gBAAgB,GAAG,QAAU,GAAG,OAAS,GAAG,MAAQ,GAAG,KAAO,IAAIC,GAAG,CA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qI,Q,yDChH5B","file":"js/chunk-2f3159e8.59e7705d.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"diagnostics pt-15\"},[_c('v-card',{staticClass:\"diagnostic-view-select\",attrs:{\"color\":\"accent\",\"elevation\":\"3\",\"dark\":\"\"}},[_c('v-select',{attrs:{\"items\":_vm.DiagnosticViewTypes,\"item-text\":\"text\",\"label\":\"Diagnostics View Type\",\"hide-details\":\"\",\"return-object\":\"\",\"rounded\":\"\",\"filled\":\"\",\"dense\":\"\",\"dark\":\"\"},on:{\"change\":_vm.onViewTypeChanged},model:{value:(_vm.DiagnosticViewType),callback:function ($$v) {_vm.DiagnosticViewType=$$v},expression:\"DiagnosticViewType\"}})],1),_c(_vm.DiagnosticViewType.component,{tag:\"component\"})],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[(_vm.featureEnabled)?_c('div',[(_vm.isLoading)?[_c('v-skeleton-loader',{attrs:{\"type\":\"table\",\"max-width\":\"800\"}}),(_vm.isLoading)?_c('v-skeleton-loader',{attrs:{\"type\":\"image, list-item-two-line, image, list-item-two-line, image, list-item-two-line\"}}):_vm._e()]:[_c('v-expansion-panels',{staticStyle:{\"max-width\":\"800px\"}},[_c('v-expansion-panel',[_c('v-expansion-panel-header',{staticClass:\"white--text\",attrs:{\"color\":\"primary\"},scopedSlots:_vm._u([{key:\"actions\",fn:function(){return [_c('v-icon',{attrs:{\"color\":\"white\"}},[_vm._v(\" $expand \")])]},proxy:true}],null,false,2794704483)},[_c('span',{staticClass:\"font-weight-semibold\"},[_vm._v(\"Events\")]),_c('v-spacer'),_c('v-btn',{staticClass:\"mr-3 font-weight-semibold\",attrs:{\"small\":\"\",\"color\":\"white\",\"max-width\":\"150\"},nativeOn:{\"click\":function($event){$event.stopPropagation();return _vm.createEvent()}}},[_c('v-icon',{attrs:{\"left\":\"\"}},[_vm._v(\"mdi-plus\")]),_vm._v(\" New event \")],1)],1),_c('v-expansion-panel-content',[_c('v-data-table',{attrs:{\"headers\":_vm.eventTableHeaders,\"items\":_vm.eventTableRows,\"dense\":\"\",\"loading-text\":\"Loading... Please wait\",\"no-data-text\":\"No events\",\"hide-default-footer\":\"\",\"disable-pagination\":\"\",\"fixed-header\":\"\",\"sort-by\":\"date\",\"sort-desc\":true},scopedSlots:_vm._u([{key:\"header.date\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('span',{staticClass:\"primary--text\"},[_vm._v(_vm._s(header.text))])]}},{key:\"header.name\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('span',{staticClass:\"primary--text\"},[_vm._v(_vm._s(header.text))])]}},{key:\"header.type\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('span',_vm._g({staticClass:\"primary--text\"},on),[_vm._v(_vm._s(header.text))])]}}],null,true)},[_c('span',[_vm._v(\"Event can be either 'Trend event' or 'Info event'\")])])]}},{key:\"header.origin\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('span',_vm._g({staticClass:\"primary--text\"},on),[_vm._v(_vm._s(header.text))])]}}],null,true)},[_c('span',[_vm._v(\"Where was the event created\")])])]}},{key:\"header.actions\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('span',{staticClass:\"primary--text\"},[_vm._v(_vm._s(header.text))])]}},{key:\"item.date\",fn:function(ref){\nvar item = ref.item;\nreturn [_c('span',[_vm._v(\" \"+_vm._s(_vm.formatEventDate(item.date))+\" \")])]}},{key:\"item.type\",fn:function(ref){\nvar item = ref.item;\nreturn [_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-icon',_vm._g({attrs:{\"color\":item.type === 'TrendEvent' ? 'success' : 'info'}},on),[_vm._v(\" \"+_vm._s(item.type === \"TrendEvent\" ? \"mdi-alpha-t-circle\" : \"mdi-alpha-i-circle\")+\" \")])]}}],null,true)},[_c('span',[_vm._v(_vm._s(item.type))])])]}},{key:\"item.origin\",fn:function(ref){\nvar item = ref.item;\nreturn [_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-icon',_vm._g({},on),[_vm._v(_vm._s(item.origin === \"Office\" ? \"mdi-home\" : \"mdi-ferry\"))])]}}],null,true)},[_c('span',[_vm._v(_vm._s(item.origin))])])]}},{key:\"item.actions\",fn:function(ref){\nvar item = ref.item;\nreturn [_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-btn',_vm._g({staticClass:\"mr-4\",attrs:{\"small\":\"\",\"icon\":\"\"},on:{\"click\":function($event){return _vm.editEvent(item.event)}}},on),[_c('v-icon',[_vm._v(\"mdi-pencil\")])],1)]}}],null,true)},[_c('span',[_vm._v(\"Edit event\")])]),_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-btn',_vm._g({attrs:{\"small\":\"\",\"icon\":\"\"},on:{\"click\":function($event){return _vm.deleteEvent(item.event)}}},on),[_c('v-icon',{attrs:{\"color\":\"red\"}},[_vm._v(\"mdi-delete-outline\")])],1)]}}],null,true)},[_c('span',[_vm._v(\"Delete event\")])])]}}],null,true)})],1)],1)],1),_c('v-divider',{staticClass:\"my-3\"}),_c('div',{staticClass:\"d-flex justify-space-between\"},[_c('v-tooltip',{attrs:{\"top\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-btn',_vm._g({staticClass:\"mt-1 font-weight-semibold\",attrs:{\"small\":\"\",\"href\":\"#\",\"color\":\"accent\"},on:{\"click\":function($event){$event.preventDefault();return _vm.exportExcel()}}},on),[_c('v-icon',{attrs:{\"left\":\"\"}},[_vm._v(\"mdi-microsoft-excel\")]),_vm._v(\" Export all \")],1)]}}],null,false,443364442)},[_c('span',[_vm._v(\"Export all diagnostics data to Excel\")])]),(!_vm.isCloudLongTrendFeatureEnabled)?_c('v-checkbox',{staticClass:\"pt-0 mt-1\",attrs:{\"label\":\"Show speed loss trend as displayed on the vessel\"},model:{value:(_vm.showSpeedLogDeviation),callback:function ($$v) {_vm.showSpeedLogDeviation=$$v},expression:\"showSpeedLogDeviation\"}}):_vm._e(),(_vm.isCloudLongTrendFeatureEnabled)?_c('v-menu',{attrs:{\"bottom\":\"\",\"left\":\"\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nvar attrs = ref.attrs;\nreturn [_c('v-btn',_vm._g(_vm._b({attrs:{\"color\":\"primary\",\"icon\":\"\"}},'v-btn',attrs,false),on),[_c('v-icon',[_vm._v(\"mdi-cog\")])],1)]}}],null,false,1952843081)},[_c('v-list',{staticClass:\"ship-speed-loss-settings-list\"},[_c('v-list-item',{on:{\"click\":function($event){return _vm.openFilterModal()}}},[_c('v-list-item-title',[_vm._v(\"Filter settings\")])],1)],1)],1):_vm._e()],1),_c('ConfirmDialog',{ref:\"confirmDelete\"}),_c('EditVesselEvent',{ref:\"editVessel\",attrs:{\"isOpen\":_vm.EditEventOpen},on:{\"update:isOpen\":function($event){_vm.EditEventOpen=$event},\"update:is-open\":function($event){_vm.EditEventOpen=$event}}}),_c('LongTrendFilterModal',{ref:\"filterModal\",attrs:{\"is-open\":_vm.FilterModalOpen},on:{\"update:isOpen\":function($event){_vm.FilterModalOpen=$event},\"update:is-open\":function($event){_vm.FilterModalOpen=$event},\"filterUpdated\":_vm.onFilterUpdated}}),_c('DiagnosticsDetails',{ref:\"diagnosticsDetails\"}),_c('v-snackbar',{attrs:{\"timeout\":_vm.notification.duration,\"color\":\"primary\"},model:{value:(_vm.notification.visible),callback:function ($$v) {_vm.$set(_vm.notification, \"visible\", $$v)},expression:\"notification.visible\"}},[_c('v-icon',{staticClass:\"mr-2\",attrs:{\"dark\":\"\"}},[_vm._v(\"mdi-check\")]),_vm._v(_vm._s(_vm.notification.message)+\" \")],1),_c('div',{staticClass:\"d-flex flex-column\"},_vm._l((_vm.vesselLongTrends),function(trend){return _c('DiagnosticCard',{key:trend.longTrend.id,staticClass:\"mb-5\",attrs:{\"longTrendName\":trend.longTrend.name,\"visible\":trend.visible},on:{\"plotBandClicked\":_vm.showDiagnosticsDetails}})}),1)]],2):_c('FeatureNotAvailable')],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('v-dialog',{attrs:{\"max-width\":\"400px\"},on:{\"keydown\":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,\"esc\",27,$event.key,[\"Esc\",\"Escape\"])){ return null; }return _vm.cancel.apply(null, arguments)},\"click:outside\":_vm.cancel},model:{value:(_vm.dialog),callback:function ($$v) {_vm.dialog=$$v},expression:\"dialog\"}},[_c('v-card',[_c('v-card-title',[_c('span',{staticClass:\"headline\"},[_vm._v(\"Filter settings\")])]),_c('v-card-text',[_c('v-text-field',{staticClass:\"mcr-input mt-6 mb-3\",attrs:{\"type\":\"number\",\"min\":\"1\",\"label\":\"MCR %\",\"rules\":[_vm.fieldRequired.mcr],\"hint\":\"Values are excluded from calculations if vessel power is below the % chosen above\",\"persistent-placeholder\":\"\",\"persistent-hint\":\"\",\"flat\":\"\",\"dense\":\"\",\"outlined\":\"\"},on:{\"keypress\":_vm.numericFilter},model:{value:(_vm.filter.minPercentMcr),callback:function ($$v) {_vm.$set(_vm.filter, \"minPercentMcr\", _vm._n($$v))},expression:\"filter.minPercentMcr\"}}),_c('v-select',{staticClass:\"windBeaufort-select elevation-0\",attrs:{\"items\":_vm.windBeaufort,\"item-value\":\"value\",\"item-text\":\"text\",\"label\":\"Beaufort Scale\",\"rules\":[_vm.fieldRequired.required],\"hint\":\"Values are excluded from calculations if wind speed is above the Beaufort scale chosen above\",\"persistent-placeholder\":\"\",\"persistent-hint\":\"\",\"dense\":\"\",\"outlined\":\"\"},model:{value:(_vm.filter.maxBeaufortWind),callback:function ($$v) {_vm.$set(_vm.filter, \"maxBeaufortWind\", $$v)},expression:\"filter.maxBeaufortWind\"}})],1),_c('v-card-actions',{staticClass:\"pt-3\"},[_c('v-spacer'),_c('v-btn',{staticClass:\"font-weight-semibold\",attrs:{\"color\":\"accent\",\"type\":\"submit\",\"elevation\":\"0\",\"disabled\":_vm.isSaveDisabled},on:{\"click\":_vm.updateFilter}},[_vm._v(\" Save \")]),_c('v-btn',{staticClass:\"font-weight-semibold\",attrs:{\"color\":\"primary-lighten-90\",\"text\":\"\"},on:{\"click\":function($event){$event.stopPropagation();$event.preventDefault();return _vm.cancel.apply(null, arguments)}}},[_vm._v(\" Cancel \")])],1)],1)],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import store from \"@/store\";\r\n\r\nexport interface FetchOptions extends RequestInit {\r\n headers?: Record;\r\n}\r\n\r\nasync function apiFetch(endpoint: string, options: FetchOptions = {}): Promise {\r\n const accessToken = store.getters[\"Auth/getAccessToken\"];\r\n const headers: Record = {\r\n \"Content-Type\": \"application/json\",\r\n Authorization: accessToken ? `Bearer ${accessToken}` : \"\",\r\n ...options.headers,\r\n };\r\n\r\n const response = await fetch(`${process.env.VUE_APP_API_BASE_URL}${endpoint}`, {\r\n ...options,\r\n headers,\r\n });\r\n\r\n if (!response.ok) {\r\n throw new Error(`HTTP request failed. Status: ${response.status}`);\r\n }\r\n\r\n const contentType = response.headers.get(\"content-type\");\r\n return contentType && contentType.includes(\"application/json\")\r\n ? response.json()\r\n : response.text();\r\n}\r\n\r\nexport async function apiGet(endpoint: string, options: FetchOptions = {}): Promise {\r\n return apiFetch(endpoint, { ...options, method: \"GET\" });\r\n}\r\n\r\nexport async function apiPost(endpoint: string, data: T, options: FetchOptions = {}): Promise {\r\n return apiFetch(endpoint, {\r\n ...options,\r\n method: \"POST\",\r\n body: JSON.stringify(data),\r\n });\r\n}\r\n\r\nexport async function apiPut(endpoint: string, data: T, options: FetchOptions = {}): Promise {\r\n return apiFetch(endpoint, {\r\n ...options,\r\n method: \"PUT\",\r\n body: JSON.stringify(data),\r\n });\r\n}\r\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, PropSync, Vue } from \"vue-property-decorator\";\nimport store from \"@/store\";\n// types\nimport { ExtendedVessel } from \"@/types/vessel\";\nimport { LongTrendFilter } from \"@/types/LongTrendFilter\";\n// modules\nimport { getModule } from \"vuex-module-decorators\";\nimport VesselsModule from \"@/store/clients/Vessels.module\";\nimport SnackbarModule from \"@/store/clients/Snackbar.module\";\nimport { apiGet, apiPut } from \"@/services/api\";\n\nconst Vessels = getModule(VesselsModule, store);\nconst Snackbar = getModule(SnackbarModule, store);\n\n@Component\nexport default class LongTrendFilterModal extends Vue {\n @PropSync(\"isOpen\", { type: Boolean, default: false }) dialog!: boolean;\n\n filter: LongTrendFilter = {} as LongTrendFilter;\n windBeaufort = [\n { text: \"BF3\", value: 3 },\n { text: \"BF4\", value: 4 },\n { text: \"BF5\", value: 5 },\n { text: \"BF6\", value: 6 },\n { text: \"BF7\", value: 7 },\n { text: \"BF8\", value: 8 },\n { text: \"BF9\", value: 9 },\n { text: \"BF10\", value: 10 },\n { text: \"BF11\", value: 11 },\n { text: \"BF12\", value: 12 },\n ];\n\n // @Getters\n get vessel(): ExtendedVessel | null {\n if (!Vessels.currentVessel) return null;\n return Vessels.currentVessel;\n }\n\n get isSaveDisabled(): boolean {\n return !this.filter.minPercentMcr || !this.filter.maxBeaufortWind;\n }\n\n fieldRequired = {\n required: (value: any) => !!value || \"Field is required\",\n mcr: (value: any) => {\n if (!!!value) return \"Field is required\";\n else return (1 <= value && value <= 100) || \"MCR must be a number between 1 and 100.\";\n },\n };\n\n numericFilter(event: any): void {\n event = event ? event : window.event;\n const expect = event.target.value.toString() + event.key.toString();\n return !/^\\d+$/.test(expect) ? event.preventDefault() : false;\n }\n\n async fetchFilter(): Promise {\n if (!this.vessel) return;\n this.filter = await apiGet(`/LongTrend/Filter?vesselId=${this.vessel.id}`);\n }\n\n open(): void {\n this.fetchFilter();\n this.dialog = true;\n }\n\n cancel(): void {\n this.dialog = false;\n }\n\n async updateFilter(): Promise {\n try {\n await apiPut(\"/LongTrend/Filter\", this.filter);\n this.$emit(\"filterUpdated\");\n Snackbar.showSnackbar({ text: \"Filter settings successfully updated\", color: \"success\" });\n } catch (error) {\n Snackbar.showSnackbar({ text: \"Failed to update filter settings\" });\n } finally {\n this.dialog = false;\n }\n }\n\n async created(): Promise {\n if (!this.vessel) return;\n await this.fetchFilter();\n }\n}\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--15-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./LongTrendFilterModal.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--15-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./LongTrendFilterModal.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./LongTrendFilterModal.vue?vue&type=template&id=c20bad70&scoped=true&\"\nimport script from \"./LongTrendFilterModal.vue?vue&type=script&lang=ts&\"\nexport * from \"./LongTrendFilterModal.vue?vue&type=script&lang=ts&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"c20bad70\",\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VBtn } from 'vuetify/lib/components/VBtn';\nimport { VCard } from 'vuetify/lib/components/VCard';\nimport { VCardActions } from 'vuetify/lib/components/VCard';\nimport { VCardText } from 'vuetify/lib/components/VCard';\nimport { VCardTitle } from 'vuetify/lib/components/VCard';\nimport { VDialog } from 'vuetify/lib/components/VDialog';\nimport { VSelect } from 'vuetify/lib/components/VSelect';\nimport { VSpacer } from 'vuetify/lib/components/VGrid';\nimport { VTextField } from 'vuetify/lib/components/VTextField';\ninstallComponents(component, {VBtn,VCard,VCardActions,VCardText,VCardTitle,VDialog,VSelect,VSpacer,VTextField})\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, Ref, Vue } from \"vue-property-decorator\";\nimport store from \"@/store\";\nimport moment from \"moment\";\nimport LongTrendExportClient from \"@/Scripts/clients/long-trend-export-client\";\n//modules\nimport { getModule } from \"vuex-module-decorators\";\nimport LongTrendsModule from \"@/store/clients/LongTrends.module\";\nimport VesselsModule from \"@/store/clients/Vessels.module\";\nimport VesselEventsModule from \"@/store/clients/VesselEvents.module\";\n//components\nimport FeatureNotAvailable from \"@/components/FeatureNotAvailable.vue\";\nimport ConfirmDialog from \"@/components/ConfirmDialog.vue\";\nimport EditVesselEvent from \"@/components/EditVesselEvent.vue\";\nimport DiagnosticsDetails from \"@/components/diagnosticsDetails/DiagnosticsDetails.vue\";\nimport DiagnosticCard from \"@/components/DiagnosticCard.vue\";\nimport LongTrendFilterModal from \"@/components/diagnostics/LongTrendFilterModal.vue\";\n//types\nimport { VesselEvent } from \"@/types/vesselEvent\";\nimport { ExtendedVessel } from \"@/types/vessel\";\nimport { IVesselLongTrend, IVesselLongTrends } from \"@/types/vesselLongTrends\";\n\nconst Vessels = getModule(VesselsModule, store);\nconst VesselEvents = getModule(VesselEventsModule, store);\nconst LongTrends = getModule(LongTrendsModule, store);\n\nexport interface IVesselLongTrendsExtended extends IVesselLongTrend {\n visible: boolean;\n}\n\n@Component({\n components: {\n FeatureNotAvailable,\n ConfirmDialog,\n EditVesselEvent,\n DiagnosticsDetails,\n DiagnosticCard,\n LongTrendFilterModal,\n },\n})\nexport default class DiagnosticsKyma extends Vue {\n @Ref(\"confirmDelete\") confirmDelete!: any;\n @Ref(\"editVessel\") editVessel!: any;\n @Ref(\"filterModal\") filterModal!: any;\n @Ref(\"diagnosticsDetails\") diagnosticsDetails!: any;\n EditEventOpen = false;\n FilterModalOpen = false;\n detailsError = false;\n notification = {\n message: \"\",\n duration: 2000,\n visible: false,\n };\n\n isLoading = true;\n showError = false;\n showSpeedLogDeviation = true;\n\n get vessel(): ExtendedVessel | null {\n return Vessels.currentVessel;\n }\n\n get featureEnabled(): boolean {\n if (!this.vessel) return false;\n return this.vessel.features.some(feature => feature.name === \"Diagnostics\");\n }\n\n get isCloudLongTrendFeatureEnabled(): boolean {\n if (!this.vessel) return false;\n return this.vessel.features.some(feature => feature.name === \"CloudLongTrend\");\n }\n\n get vesselLongTrends(): IVesselLongTrendsExtended[] {\n const vesselLongTrends: IVesselLongTrendsExtended[] = [];\n const trend: IVesselLongTrends = { ...LongTrends.vesselLongTrends };\n const shipSpeedDeviationKey = \"ShipSpeedDev\";\n Object.keys(trend).forEach(key => {\n if (key === shipSpeedDeviationKey) {\n vesselLongTrends.push({ ...trend[key], visible: this.showSpeedLogDeviation });\n } else {\n vesselLongTrends.push({ ...trend[key], visible: true });\n }\n });\n\n return vesselLongTrends;\n }\n\n get events(): VesselEvent[] {\n return VesselEvents.allEvents;\n }\n\n eventTableHeaders = [\n { text: \"Date\", align: \"start\", sortable: false, value: \"date\" },\n { text: \"Name\", align: \"start\", sortable: false, value: \"name\" },\n { text: \"Type\", align: \"start\", sortable: false, value: \"type\" },\n { text: \"Origin\", align: \"start\", sortable: false, value: \"origin\" },\n { text: \"Actions\", align: \"start\", sortable: false, value: \"actions\" },\n ];\n\n get eventTableRows(): any[] {\n const tableRows: any[] = [];\n\n this.events.forEach(event => {\n tableRows.push({\n event,\n date: event.timestamp,\n name: event.name,\n type: event.type,\n origin: event.source,\n actions: [\"edit\", \"delete\"],\n });\n });\n\n return tableRows;\n }\n\n async created(): Promise {\n if (!this.vessel) {\n this.showError = true;\n } else {\n try {\n await Promise.all([VesselEvents.fetchEvents(this.vessel.id), VesselEvents.updateTrendEventTypes(), LongTrends.fetchVesselLongTrends(this.vessel.id)]);\n } catch (error) {\n console.warn(error);\n this.showError = true;\n } finally {\n this.isLoading = false;\n }\n }\n }\n\n async createEvent(): Promise {\n const success = await this.editVessel.open();\n if (success) {\n this.notification.message = \"Event created\";\n this.notification.visible = true;\n this.vessel ? LongTrends.fetchVesselLongTrends(this.vessel.id) : null;\n }\n }\n\n async editEvent(vesselEvent: VesselEvent): Promise {\n const success = await this.editVessel.open(vesselEvent);\n if (success) {\n this.notification.message = \"Event edited\";\n this.notification.visible = true;\n this.vessel ? LongTrends.fetchVesselLongTrends(this.vessel.id) : null;\n }\n }\n\n async deleteEvent(vesselEvent: VesselEvent): Promise {\n const confirmed = await this.confirmDelete.open(`Delete ${vesselEvent.name}`, \"Are you sure you want to delete this event?\");\n if (confirmed) {\n await VesselEvents.deleteEvent(vesselEvent);\n this.notification.message = \"Event deleted\";\n this.notification.visible = true;\n this.vessel ? LongTrends.fetchVesselLongTrends(this.vessel.id) : null;\n }\n }\n\n async onFilterUpdated(): Promise {\n if (!this.vessel) {\n this.showError = true;\n } else {\n this.isLoading = true;\n try {\n await Promise.all([VesselEvents.fetchEvents(this.vessel.id), VesselEvents.updateTrendEventTypes(), LongTrends.fetchVesselLongTrends(this.vessel.id)]);\n } catch (error) {\n console.warn(error);\n this.showError = true;\n } finally {\n this.isLoading = false;\n }\n }\n }\n\n openFilterModal(): void {\n this.filterModal.open();\n }\n\n showDiagnosticsDetails(data: any): void {\n if (!data.vesselId) return;\n this.diagnosticsDetails.open(data);\n }\n\n exportExcel(): void {\n if (this.vessel) {\n LongTrendExportClient.exportExcel(this.vessel.id);\n }\n }\n\n formatEventDate(date: string): string {\n return moment.utc(date).format(\"DD.MMM YYYY\");\n }\n}\n","import mod from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--15-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./DiagnosticsKyma.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--15-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./DiagnosticsKyma.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./DiagnosticsKyma.vue?vue&type=template&id=5dcd4ee3&scoped=true&\"\nimport script from \"./DiagnosticsKyma.vue?vue&type=script&lang=ts&\"\nexport * from \"./DiagnosticsKyma.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./DiagnosticsKyma.vue?vue&type=style&index=0&id=5dcd4ee3&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"5dcd4ee3\",\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VBtn } from 'vuetify/lib/components/VBtn';\nimport { VCheckbox } from 'vuetify/lib/components/VCheckbox';\nimport { VDataTable } from 'vuetify/lib/components/VDataTable';\nimport { VDivider } from 'vuetify/lib/components/VDivider';\nimport { VExpansionPanel } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanelContent } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanelHeader } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanels } from 'vuetify/lib/components/VExpansionPanel';\nimport { VIcon } from 'vuetify/lib/components/VIcon';\nimport { VList } from 'vuetify/lib/components/VList';\nimport { VListItem } from 'vuetify/lib/components/VList';\nimport { VListItemTitle } from 'vuetify/lib/components/VList';\nimport { VMenu } from 'vuetify/lib/components/VMenu';\nimport { VSkeletonLoader } from 'vuetify/lib/components/VSkeletonLoader';\nimport { VSnackbar } from 'vuetify/lib/components/VSnackbar';\nimport { VSpacer } from 'vuetify/lib/components/VGrid';\nimport { VTooltip } from 'vuetify/lib/components/VTooltip';\ninstallComponents(component, {VBtn,VCheckbox,VDataTable,VDivider,VExpansionPanel,VExpansionPanelContent,VExpansionPanelHeader,VExpansionPanels,VIcon,VList,VListItem,VListItemTitle,VMenu,VSkeletonLoader,VSnackbar,VSpacer,VTooltip})\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[(_vm.featureEnabled)?_c('div',[(_vm.isLoading)?_c('div',[_c('v-skeleton-loader',{attrs:{\"type\":\"table\",\"max-width\":\"800\"}}),(_vm.isLoading)?_c('v-skeleton-loader',{attrs:{\"type\":\"image, list-item-two-line, image, list-item-two-line, image, list-item-two-line\"}}):_vm._e()],1):_c('div',{staticClass:\"diagnostics-iso\"},[_c('VesselEventsTable',{attrs:{\"eventsList\":_vm.eventsByVesselId,\"dataMinDate\":_vm.ISO19030PerformanceLogVariable.logDataMinDate},on:{\"update:eventsList\":function($event){_vm.eventsByVesselId=$event},\"update:events-list\":function($event){_vm.eventsByVesselId=$event},\"eventUpdated\":_vm.eventUpdated}}),_vm._l((_vm.ISOChartTypes),function(chart,i){return _c('PerformanceIndicatorChart',{key:(\"\" + chart + i),attrs:{\"title\":chart,\"periods\":_vm.getISOChartTypePeriods(chart),\"eventsList\":_vm.eventsByVesselId,\"performanceData\":_vm.ISO19030PerformanceLogData,\"isAnyEventUpdated\":_vm.isAnyEventUpdated},on:{\"update:eventsList\":function($event){_vm.eventsByVesselId=$event},\"update:events-list\":function($event){_vm.eventsByVesselId=$event}}})})],2)]):_c('FeatureNotAvailable',{scopedSlots:_vm._u([{key:\"text\",fn:function(){return [_c('p',[_vm._v(\" We are sorry, the \"),_c('strong',[_vm._v(\"ISO19030\")]),_vm._v(\" module is not activated for \"),_c('span',[_vm._v(_vm._s(_vm.vessel.name))]),_vm._v(\".\"),_c('br'),_vm._v(\" This module requires that the vessel is equipped with a \"),_c('b',[_vm._v(\"Delfini\")]),_vm._v(\" ship performance system. \")]),_c('p',{staticClass:\"mb-0\"},[_vm._v(\"Please contact \"),_c('a',{attrs:{\"href\":\"mailto:sales@danelec.com\"}},[_vm._v(\"sales@danelec.com\")]),_vm._v(\" for more information about \"),_c('b',[_vm._v(\"ISO19030\")]),_vm._v(\" and \"),_c('b',[_vm._v(\"Delfini\")]),_vm._v(\".\")])]},proxy:true}])})],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","export default function(selectedTimeInMinutes) {\r\n if (selectedTimeInMinutes <= 1440) {\r\n return \"Raw\";\r\n } else if (selectedTimeInMinutes <= 2880) {\r\n return \"Minute\";\r\n } else if (selectedTimeInMinutes <= 20160) {\r\n return \"QuarterHour\";\r\n } else if (selectedTimeInMinutes <= 129600) {\r\n return \"Hour\";\r\n }\r\n\r\n return \"Day\";\r\n}\r\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('v-expansion-panels',{style:((\"max-width: \" + _vm.maxWidth + \"px;\")),attrs:{\"value\":0}},[_c('v-expansion-panel',[_c('v-expansion-panel-header',{staticClass:\"white--text\",attrs:{\"color\":\"primary\"},scopedSlots:_vm._u([{key:\"actions\",fn:function(){return [_c('v-icon',{attrs:{\"color\":\"white\"}},[_vm._v(\" $expand \")])]},proxy:true}])},[_c('span',{staticClass:\"font-weight-semibold\"},[_vm._v(\"Events\")]),_c('v-spacer'),_c('v-btn',{staticClass:\"mr-3 font-weight-semibold\",attrs:{\"small\":\"\",\"color\":\"white\",\"max-width\":\"150\"},nativeOn:{\"click\":function($event){$event.stopPropagation();return _vm.openEventModal()}}},[_c('v-icon',{attrs:{\"left\":\"\"}},[_vm._v(\"mdi-plus\")]),_vm._v(\" New event \")],1)],1),_c('v-expansion-panel-content',[_c('v-data-table',{attrs:{\"headers\":_vm.tableHeaders,\"items\":_vm.tableRows,\"dense\":\"\",\"loading-text\":\"Loading... Please wait\",\"no-data-text\":\"No events\",\"items-per-page\":10,\"sort-by\":\"date\",\"sort-desc\":true},scopedSlots:_vm._u([{key:\"header.dates\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('span',{staticClass:\"primary--text\"},[_vm._v(_vm._s(header.text))])]}},{key:\"header.actions\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('span',{staticClass:\"primary--text\"},[_vm._v(_vm._s(header.text))])]}},{key:\"header.eventType\",fn:function(ref){\nvar header = ref.header;\nreturn [_c('span',{staticClass:\"primary--text\"},[_vm._v(_vm._s(header.text))])]}},{key:\"item.dates\",fn:function(ref){\nvar item = ref.item;\nreturn [_c('span',[_vm._v(\" \"+_vm._s(_vm.formatEventDate(item))+\" \")])]}},{key:\"item.actions\",fn:function(ref){\nvar item = ref.item;\nreturn [_c('v-tooltip',{attrs:{\"top\":\"\",\"color\":\"primary lighten-2\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-btn',_vm._g({attrs:{\"icon\":\"\"},on:{\"click\":function($event){return _vm.openEventModal('edit', item)}}},on),[_c('v-icon',{attrs:{\"small\":\"\",\"color\":\"primary lighten-3\"}},[_vm._v(\"mdi-pencil\")])],1)]}}],null,true)},[_c('span',[_vm._v(\"Edit event\")])]),_c('v-tooltip',{attrs:{\"top\":\"\",\"color\":\"primary lighten-2\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-btn',_vm._g({attrs:{\"icon\":\"\"},on:{\"click\":function($event){return _vm.deleteEvent(item)}}},on),[_c('v-icon',{attrs:{\"small\":\"\",\"color\":\"primary lighten-3\"}},[_vm._v(\"mdi-delete\")])],1)]}}],null,true)},[_c('span',[_vm._v(\"Delete event\")])])]}}],null,true)})],1)],1)],1),_c('v-dialog',{attrs:{\"max-width\":\"400px\"},on:{\"keydown\":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,\"esc\",27,$event.key,[\"Esc\",\"Escape\"])){ return null; }return _vm.cancel.apply(null, arguments)},\"click:outside\":_vm.cancel},model:{value:(_vm.eventModal),callback:function ($$v) {_vm.eventModal=$$v},expression:\"eventModal\"}},[_c('v-card',[_c('v-card-title',[_c('span',{staticClass:\"headline\"},[_vm._v(\"Create event\")])]),_c('v-form',{staticClass:\"mt-2\"},[_c('v-card-text',[_c('v-select',{attrs:{\"rules\":[_vm.typeSelectValidation.required],\"value\":\"trendEventTypeName\",\"label\":\"Event type\",\"prepend-icon\":\"mdi-format-list-bulleted-type\",\"items\":_vm.eventTypes,\"item-text\":\"trendEventTypeName\",\"item-value\":\"trendEventTypeId\"},model:{value:(_vm.event.eventType),callback:function ($$v) {_vm.$set(_vm.event, \"eventType\", $$v)},expression:\"event.eventType\"}}),(_vm.isEventDryDocking)?_c('div',[_c('div',{staticClass:\"d-flex\"},[_c('v-menu',{attrs:{\"close-on-content-click\":false,\"nudge-right\":40,\"transition\":\"scale-transition\",\"offset-y\":\"\",\"min-width\":\"auto\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nvar attrs = ref.attrs;\nreturn [_c('v-text-field',_vm._g(_vm._b({attrs:{\"rules\":[_vm.dateValidation.required],\"label\":\"In-docking date\",\"prepend-icon\":\"mdi-calendar\",\"readonly\":\"\"},model:{value:(_vm.event.startTimestamp),callback:function ($$v) {_vm.$set(_vm.event, \"startTimestamp\", $$v)},expression:\"event.startTimestamp\"}},'v-text-field',attrs,false),on))]}}],null,false,2735545862),model:{value:(_vm.indockingDateMenu),callback:function ($$v) {_vm.indockingDateMenu=$$v},expression:\"indockingDateMenu\"}},[_c('v-date-picker',{on:{\"input\":function($event){_vm.indockingDateMenu = false}},model:{value:(_vm.event.startTimestamp),callback:function ($$v) {_vm.$set(_vm.event, \"startTimestamp\", $$v)},expression:\"event.startTimestamp\"}})],1),_c('v-menu',{attrs:{\"close-on-content-click\":false,\"nudge-right\":40,\"transition\":\"scale-transition\",\"offset-y\":\"\",\"min-width\":\"auto\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nvar attrs = ref.attrs;\nreturn [_c('v-text-field',_vm._g(_vm._b({attrs:{\"rules\":[_vm.dateValidation.required],\"label\":\"Out-docking date\",\"prepend-icon\":\"mdi-calendar\",\"disabled\":_vm.event.startTimestamp === null,\"readonly\":\"\"},model:{value:(_vm.event.endTimestamp),callback:function ($$v) {_vm.$set(_vm.event, \"endTimestamp\", $$v)},expression:\"event.endTimestamp\"}},'v-text-field',attrs,false),on))]}}],null,false,3474714540),model:{value:(_vm.outdockingDateMenu),callback:function ($$v) {_vm.outdockingDateMenu=$$v},expression:\"outdockingDateMenu\"}},[_c('v-date-picker',{attrs:{\"min\":_vm.event.startTimestamp},on:{\"input\":function($event){_vm.outdockingDateMenu = false}},model:{value:(_vm.event.endTimestamp),callback:function ($$v) {_vm.$set(_vm.event, \"endTimestamp\", $$v)},expression:\"event.endTimestamp\"}})],1),_c('v-tooltip',{attrs:{\"top\":\"\",\"max-width\":\"400px\",\"color\":\"primary lighten-2\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-icon',_vm._g({staticClass:\"mb-1 ml-1 flex-grow-0\",staticStyle:{\"cursor\":\"pointer\"},attrs:{\"color\":\"primary lighten-2\",\"left\":\"\"}},on),[_vm._v(\"mdi-alert-circle\")])]}}],null,false,411864530)},[_c('span',{staticClass:\"mx-auto\"},[_vm._v(\"Started collecting speed-loss performance-values \"+_vm._s(_vm.formattedDataMinDate)+\". Will not be able to calculate vessel performance according to ISO 19030 before this date.\")])])],1),_c('v-text-field',{staticClass:\"mb-2\",attrs:{\"label\":\"Maintenance Threshold %\",\"prepend-icon\":\"mdi-percent-box-outline\",\"rules\":[_vm.thresholdValidation.required],\"type\":\"text\"},model:{value:(_vm.event.maintenanceThreshold),callback:function ($$v) {_vm.$set(_vm.event, \"maintenanceThreshold\", _vm._n($$v))},expression:\"event.maintenanceThreshold\"}})],1):_c('div',[_c('v-menu',{attrs:{\"close-on-content-click\":false,\"nudge-right\":40,\"transition\":\"scale-transition\",\"offset-y\":\"\",\"min-width\":\"auto\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nvar attrs = ref.attrs;\nreturn [_c('v-text-field',_vm._g(_vm._b({attrs:{\"rules\":[_vm.dateValidation.required],\"label\":\"Event date\",\"prepend-icon\":\"mdi-calendar\",\"readonly\":\"\"},scopedSlots:_vm._u([{key:\"append\",fn:function(){return [_c('v-tooltip',{attrs:{\"top\":\"\",\"max-width\":\"400px\",\"color\":\"primary lighten-2\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-icon',_vm._g({staticClass:\"mb-1 ml-1 flex-grow-0\",staticStyle:{\"cursor\":\"pointer\"},attrs:{\"color\":\"primary lighten-2\",\"left\":\"\"}},on),[_vm._v(\"mdi-alert-circle\")])]}}],null,true)},[_c('span',{staticClass:\"mx-auto\"},[_vm._v(\"Started collecting speed-loss performance-values \"+_vm._s(_vm.formattedDataMinDate)+\". Will not be able to calculate vessel performance according to ISO 19030 before this date.\")])])]},proxy:true}],null,true),model:{value:(_vm.event.startTimestamp),callback:function ($$v) {_vm.$set(_vm.event, \"startTimestamp\", $$v)},expression:\"event.startTimestamp\"}},'v-text-field',attrs,false),on))]}}]),model:{value:(_vm.dateMenu),callback:function ($$v) {_vm.dateMenu=$$v},expression:\"dateMenu\"}},[_c('v-date-picker',{on:{\"input\":function($event){_vm.dateMenu = false}},model:{value:(_vm.event.startTimestamp),callback:function ($$v) {_vm.$set(_vm.event, \"startTimestamp\", $$v)},expression:\"event.startTimestamp\"}})],1),_c('v-textarea',{attrs:{\"label\":\"Comment\",\"prepend-icon\":\"mdi-comment-outline\",\"rules\":[function (v) { return v && v.length <= 100 || 'Max 100 characters'; }],\"auto-grow\":\"\",\"rows\":\"2\",\"row-height\":\"20\",\"counter\":\"\",\"clearable\":\"\"},model:{value:(_vm.event.comment),callback:function ($$v) {_vm.$set(_vm.event, \"comment\", $$v)},expression:\"event.comment\"}})],1)],1),_c('v-card-actions',{staticClass:\"pt-3\"},[_c('v-spacer'),_c('v-btn',{attrs:{\"color\":\"accent\",\"form\":\"edit-event-form\",\"elevation\":\"0\",\"disabled\":_vm.isSaveButtonDisabled},on:{\"click\":_vm.saveEvent}},[_vm._v(\"Save\")]),_c('v-btn',{staticClass:\"font-weight-semibold\",attrs:{\"color\":\"primary-lighten-90\",\"text\":\"\"},on:{\"click\":function($event){$event.stopPropagation();$event.preventDefault();return _vm.cancel.apply(null, arguments)}}},[_vm._v(\"Cancel\")])],1)],1)],1)],1),_c('ConfirmDialog',{ref:\"confirmDelete\",staticClass:\"confirm-dialog\"})],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, Vue, Ref, Prop, PropSync } from \"vue-property-decorator\";\n// utilities\nimport moment from \"moment\";\nimport dateHelper from \"@/Scripts/utilities/date-helper\";\nimport store from \"@/store\";\n// components\nimport ConfirmDialog from \"@/components/ConfirmDialog.vue\";\n// types\nimport { ISO19030Event } from \"@/types/ISO19030Event\";\n// modules\nimport { getModule } from \"vuex-module-decorators\";\nimport ISO19030Module from \"@/store/clients/ISO19030.module\";\nimport SnackbarModule from \"@/store/clients/Snackbar.module\";\n\nconst ISO19030 = getModule(ISO19030Module, store);\nconst Snackbar = getModule(SnackbarModule, store);\n\ninterface TableRow {\n id: number;\n eventType: string;\n actions: string[];\n dates: {\n startTimestamp: string | null;\n endTimestamp: string | null;\n };\n}\n\n@Component({\n components: {\n ConfirmDialog,\n },\n})\nexport default class VesselEventsTable extends Vue {\n @PropSync(\"eventsList\", { required: true }) syncEvents!: any;\n @Prop({ default: 800 }) maxWidth!: number;\n @Prop() dataMinDate!: string;\n @Ref(\"confirmDelete\") confirmDelete!: any;\n\n isLoading = false;\n eventModal = false;\n dateMenu = false;\n indockingDateMenu = false;\n outdockingDateMenu = false;\n isEventEditing = false;\n eventTypes = [\"Docking\", \"Maintenance\"];\n event: ISO19030Event = {\n id: 0,\n vesselId: this.vesselId,\n startTimestamp: null,\n endTimestamp: null,\n eventType: \"Maintenance\", // by default\n maintenanceThreshold: null,\n comment: \"\",\n };\n tableHeaders = [\n { text: \"Date\", align: \"start\", sortable: false, value: \"dates\" },\n { text: \"Type\", align: \"start\", sortable: false, value: \"eventType\" },\n { text: \"Actions\", align: \"start\", sortable: false, value: \"actions\" },\n ];\n\n thresholdValidation = {\n required: (value: string) => !!value || \"Maintenance Threshold required\",\n };\n\n dateValidation = {\n required: (value: string) => !!value || \"Event date required\",\n };\n\n typeSelectValidation = {\n required: (value: any) => !!value || \"Type required\",\n };\n\n get vesselId(): number {\n return Number(this.$route.params.vesselId);\n }\n\n get isEventDryDocking(): boolean {\n return this.event.eventType === \"Docking\";\n }\n\n get isEventMaintenance(): boolean {\n return this.event.eventType === \"Maintenance\";\n }\n\n get isNewEvent(): boolean {\n if (!this.event.id) return true;\n return Boolean(!this.syncEvents.find((event: ISO19030Event) => event.id === this.event.id));\n }\n\n get isSaveButtonDisabled(): boolean {\n if (this.isEventMaintenance) return Boolean(this.event.eventType === null || this.event.startTimestamp === null);\n else return Boolean(this.event.eventType === null || this.event.startTimestamp === null || this.event.endTimestamp === null || this.event.maintenanceThreshold === null);\n }\n\n get formattedDataMinDate(): string {\n return this.dataMinDate ? dateHelper.getFormatedDateString(this.dataMinDate) : \"N/A\";\n }\n\n get tableRows(): TableRow[] {\n if (!this.syncEvents.length) return [];\n const tableRows: TableRow[] = [];\n\n this.syncEvents.forEach((event: any) => {\n tableRows.push({\n id: event.id,\n eventType: event.eventType,\n actions: [\"edit\", \"delete\"],\n dates: {\n startTimestamp: event.startTimestamp,\n endTimestamp: event.endTimestamp,\n },\n });\n });\n return tableRows;\n }\n\n formatEventDate(item: any): string {\n if (item.dates.startTimestamp && item.dates.endTimestamp) {\n return `${moment.utc(item.dates.startTimestamp).format(\"DD.MMM YYYY\")} - ${moment.utc(item.dates.endTimestamp).format(\"DD.MMM YYYY\")}`;\n } else {\n return moment.utc(item.dates.startTimestamp).format(\"DD.MMM YYYY\");\n }\n }\n\n openEventModal(mode: string, row: TableRow): void {\n this.isEventEditing = mode ? mode === \"edit\" : false;\n if (this.isEventEditing) {\n // incoming format \"2020-03-16T00:00:00\" is not compatible with datepicker\n this.event = this.syncEvents.find((e: ISO19030Event) => e.id === row.id);\n this.event.startTimestamp = moment(this.event.startTimestamp).format(\"YYYY-MM-DD\");\n this.event.endTimestamp = moment(this.event.endTimestamp).format(\"YYYY-MM-DD\");\n }\n this.eventModal = true;\n }\n\n async saveEvent(): Promise {\n try {\n if (this.isEventEditing) {\n await ISO19030.updateEvent(this.event);\n this.$emit(\"eventUpdated\", true);\n } else await ISO19030.createEvent(this.event);\n this.eventModal = false;\n Snackbar.showSnackbar({ text: `Event ${this.event.eventType} was ${this.isEventEditing ? \"updated\" : \"created\"}`, color: \"success\" });\n this.resetFormData();\n } catch (err) {\n Snackbar.showSnackbar({ text: \"Failed to create event\" });\n }\n }\n\n async deleteEvent(row: TableRow): Promise {\n const confirmDelete = await this.confirmDelete.open(`Delete ${row.eventType} | ${this.formatEventDate(row)}`, \"Are you sure you want to delete this event?\", { titleFontSize: \"1.05rem\" });\n if (!confirmDelete) return;\n\n try {\n await ISO19030.deleteEvent(row.id);\n this.eventModal = false;\n Snackbar.showSnackbar({ text: `Event '${row.eventType}' was deleted`, color: \"success\" });\n this.resetFormData();\n } catch (err) {\n Snackbar.showSnackbar({ text: \"Failed to create event\" });\n }\n }\n\n cancel(): void {\n this.resetFormData();\n this.eventModal = false;\n }\n\n resetFormData(): void {\n this.event = {\n id: 0,\n vesselId: this.vesselId,\n startTimestamp: null,\n endTimestamp: null,\n eventType: null,\n maintenanceThreshold: null,\n comment: \"\",\n };\n }\n}\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--15-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./VesselEventsTable.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--15-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./VesselEventsTable.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./VesselEventsTable.vue?vue&type=template&id=c7d6039a&scoped=true&\"\nimport script from \"./VesselEventsTable.vue?vue&type=script&lang=ts&\"\nexport * from \"./VesselEventsTable.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./VesselEventsTable.vue?vue&type=style&index=0&id=c7d6039a&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"c7d6039a\",\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VBtn } from 'vuetify/lib/components/VBtn';\nimport { VCard } from 'vuetify/lib/components/VCard';\nimport { VCardActions } from 'vuetify/lib/components/VCard';\nimport { VCardText } from 'vuetify/lib/components/VCard';\nimport { VCardTitle } from 'vuetify/lib/components/VCard';\nimport { VDataTable } from 'vuetify/lib/components/VDataTable';\nimport { VDatePicker } from 'vuetify/lib/components/VDatePicker';\nimport { VDialog } from 'vuetify/lib/components/VDialog';\nimport { VExpansionPanel } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanelContent } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanelHeader } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanels } from 'vuetify/lib/components/VExpansionPanel';\nimport { VForm } from 'vuetify/lib/components/VForm';\nimport { VIcon } from 'vuetify/lib/components/VIcon';\nimport { VMenu } from 'vuetify/lib/components/VMenu';\nimport { VSelect } from 'vuetify/lib/components/VSelect';\nimport { VSpacer } from 'vuetify/lib/components/VGrid';\nimport { VTextField } from 'vuetify/lib/components/VTextField';\nimport { VTextarea } from 'vuetify/lib/components/VTextarea';\nimport { VTooltip } from 'vuetify/lib/components/VTooltip';\ninstallComponents(component, {VBtn,VCard,VCardActions,VCardText,VCardTitle,VDataTable,VDatePicker,VDialog,VExpansionPanel,VExpansionPanelContent,VExpansionPanelHeader,VExpansionPanels,VForm,VIcon,VMenu,VSelect,VSpacer,VTextField,VTextarea,VTooltip})\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('v-card',{staticClass:\"mt-5 pb-4\"},[_c('v-card-title',[_c('span',{staticClass:\"font-weight-semibold p-title\"},[_vm._v(_vm._s(_vm.title))])]),(_vm.periods)?_c('div',{staticClass:\"highchart-container\"},[_c('Highcharts',{ref:\"chart\",staticClass:\"chart\",attrs:{\"options\":_vm.ChartOptions,\"deepCopyOnUpdate\":false,\"callback\":_vm.chartReady}})],1):_vm._e(),_c('div',{staticClass:\"highchart-container-footer justify-space-between\"},[_c('div',{staticClass:\"content-left mx-4\"},[_c('v-expansion-panels',{staticClass:\"statistics mb-4\"},[_c('v-expansion-panel',[_c('v-expansion-panel-header',{staticClass:\"text-overline white--text\",attrs:{\"color\":\"primary\",\"ripple\":\"\"},scopedSlots:_vm._u([{key:\"actions\",fn:function(){return [_c('v-icon',{attrs:{\"color\":\"white\"}},[_vm._v(\" mdi-chevron-down \")])]},proxy:true}])},[_c('v-icon',{staticClass:\"mb-1 mr-2 flex-grow-0\",attrs:{\"color\":\"white\"}},[_vm._v(\"mdi-chart-bar\")]),_vm._v(\" Statistics \"),_c('v-tooltip',{attrs:{\"top\":\"\",\"max-width\":\"400px\"},scopedSlots:_vm._u([{key:\"activator\",fn:function(ref){\nvar on = ref.on;\nreturn [_c('v-icon',_vm._g({staticClass:\"mb-1 ml-1 flex-grow-0\",attrs:{\"color\":\"white\",\"left\":\"\"}},on),[_vm._v(\"mdi-information-outline\")])]}}])},[_c('span',{staticClass:\"mx-auto\"},[_vm._v(\"Percentage speed loss compared to reference curve\")])])],1),_c('v-expansion-panel-content',{staticClass:\"mt-3\"},[(_vm.title !== 'Maintenance Trigger')?_c('v-select',{attrs:{\"items\":_vm.chartEvents,\"item-value\":\"id\",\"return-object\":\"\",\"outlined\":\"\",\"dense\":\"\"},scopedSlots:_vm._u([{key:\"selection\",fn:function(data){return [_vm._v(\" \"+_vm._s(_vm.formatDateForDisplay(data.item.startTimestamp, data.item.endTimestamp))+\" | \"+_vm._s(data.item.eventType)+\" \")]}},{key:\"item\",fn:function(data){return [_vm._v(\" \"+_vm._s(_vm.formatDateForDisplay(data.item.startTimestamp, data.item.endTimestamp))+\" | \"+_vm._s(data.item.eventType)+\" \")]}}],null,false,2990774396),model:{value:(_vm.selectedEvent),callback:function ($$v) {_vm.selectedEvent=$$v},expression:\"selectedEvent\"}}):_vm._e(),_c('div',{domProps:{\"innerHTML\":_vm._s(_vm.htmlStatistics)}})],1)],1)],1),(_vm.isAnyEventUpdated)?_c('v-alert',{staticStyle:{\"font-size\":\"14px\"},attrs:{\"dense\":\"\",\"outlined\":\"\",\"color\":\"primary lighten-2\",\"type\":\"info\"}},[_vm._v(\" If any of the events have recently been edited, evaluation and reference periods will be updated within 5 minutes. \")]):_vm._e()],1),_c('div',{staticClass:\"content-right mx-4 width-50\"},[(!_vm.isEvaluationPeriodAvailable && this.title !== 'Maintenance Trigger' && _vm.hasCalculatedPeriods)?_c('v-alert',{staticStyle:{\"font-size\":\"14px\"},attrs:{\"dense\":\"\",\"outlined\":\"\",\"color\":\"accent\",\"type\":\"info\"}},[_vm._v(\" There is not enough data to calculate evaluation period. \")]):(!_vm.hasCalculatedPeriods)?_c('v-alert',{staticStyle:{\"font-size\":\"14px\"},attrs:{\"dense\":\"\",\"outlined\":\"\",\"color\":\"accent\",\"type\":\"info\"}},[_vm._v(\" There is not enough data to calculate evaluation and reference periods. \")]):_vm._e()],1)])],1)],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, Vue, Prop, PropSync, Watch } from \"vue-property-decorator\";\n// utilities\nimport { Chart } from \"highcharts-vue\";\nimport Highcharts from \"highcharts\";\nimport dateHelper from \"@/Scripts/utilities/date-helper\";\nimport moment from \"moment\";\n// types\nimport { PerformanceIndicatorPeriod } from \"@/types/PerformanceIndicatorPeriod\";\nimport { IPlotLine } from \"@/types/highcharts/plotLine\";\nimport { LogData } from \"@/types/logData\";\nimport { IPlotBand } from \"@/types/highcharts/plotBand\";\nimport { ISO19030Event } from \"@/types/ISO19030Event\";\n\n@Component({\n components: {\n Highcharts: Chart,\n },\n})\nexport default class PerformanceIndicatorChart extends Vue {\n @Prop() title!: string;\n @Prop() isAnyEventUpdated = false;\n @Prop({ required: true }) periods!: PerformanceIndicatorPeriod[];\n @Prop({ required: true }) performanceData!: LogData;\n @PropSync(\"eventsList\", { required: true }) syncEvents!: ISO19030Event[];\n\n chart!: any;\n chartLoaded = false;\n selectedEvent: ISO19030Event = {} as ISO19030Event;\n mutatedPeriods: PerformanceIndicatorPeriod[] = JSON.parse(JSON.stringify(this.periods));\n\n @Watch(\"eventsList\")\n onEventsListChanged(): void {\n setTimeout(() => {\n this.chart.update(this.ChartOptions, true);\n this.chart.reflow();\n }, 500);\n }\n\n @Watch(\"selectedEvent\")\n onSelectedDockingEventChanged(): void {\n // re-setup evaluation period and recalculate statistics when event changed\n this.setDryDockingEvaluationPeriod();\n }\n\n get htmlStatistics(): string | undefined {\n switch (this.title) {\n case \"DryDocking Performance\":\n return `
    \n
  • Evaluation period average: ${this.setEvaluationPeriodAverage}
  • \n
  • Reference periods average: ${this.setReferencesPeriodsAverage}
  • \n
  • Difference in performance: ${this.setDryDockingDifferenceInPerformance}
  • \n
`;\n case \"InService Performance\":\n case \"Maintenance Effect\":\n return `
    \n
  • Evaluation period average: ${this.setEvaluationPeriodAverage}
  • \n
  • Reference period average: ${this.setSelectedReferencePeriodAverage}
  • \n
  • Difference in performance: ${this.setDifferenceInPerformanceOfSelectedEvent}
  • \n
`;\n case \"Maintenance Trigger\":\n return `
    \n
  • Reference period average: ${this.setSelectedReferencePeriodAverage}
  • \n
  • Maintenance trigger level (%): ${this.setTriggerValue}
  • \n ${\n this.selectedEvaluationPeriod\n ? `
  • Trigger period start date: ${this.formatDateString(this.selectedEvaluationPeriod?.periodStartDate)}
  • \n
  • Trigger period end date: ${this.formatDateString(this.selectedReferencePeriod?.periodEndDate)}
  • \n
  • Difference in performance: ${this.setDifferenceInPerformanceOfSelectedEvent}
  • `\n : `\n Maintenance trigger level not reached\n `\n }\n
`;\n }\n }\n\n get Highchart(): any {\n return this.chart;\n }\n\n get vesselId(): number {\n return Number(this.$route.params.vesselId);\n }\n\n get referencePeriods(): PerformanceIndicatorPeriod[] {\n return this.mutatedPeriods.filter(period => period.periodType === \"Reference Period\");\n }\n\n get referencePeriodsAverage(): number {\n return this.referencePeriods.reduce((acc: number, period: PerformanceIndicatorPeriod) => acc + period.average, 0) / this.referencePeriods.length;\n }\n\n get selectedReferencePeriod(): PerformanceIndicatorPeriod {\n let selectedReferencePeriod!: PerformanceIndicatorPeriod;\n if (this.selectedEvent) {\n // find period of selected event and set it as current\n const findPeriodOfSelectedEvent = this.periods.find(period => period.eventId === this.selectedEvent.id);\n if (findPeriodOfSelectedEvent) selectedReferencePeriod = findPeriodOfSelectedEvent;\n }\n return selectedReferencePeriod;\n }\n\n get isEvaluationPeriodAvailable(): boolean {\n return Boolean(this.selectedEvaluationPeriod);\n }\n\n get selectedEvaluationPeriod(): PerformanceIndicatorPeriod {\n let selectedEvaluationPeriod!: PerformanceIndicatorPeriod;\n if (this.selectedEvent) {\n const findPeriodOfSelectedEvent = this.evaluationPeriods.find(period => period.eventId === this.selectedEvent.id);\n if (findPeriodOfSelectedEvent) selectedEvaluationPeriod = findPeriodOfSelectedEvent;\n }\n\n return selectedEvaluationPeriod;\n }\n\n get lastDryDockingEvent(): ISO19030Event {\n const currentDate = moment().format(\"YYYY-MM-DD\");\n let lastDryDockingEvent!: ISO19030Event;\n this.dryDockingEvents.forEach(event => {\n const diff = moment(event.endTimestamp).diff(moment(currentDate), \"days\");\n if (diff > 0) {\n if (lastDryDockingEvent) {\n if (moment(event.endTimestamp).diff(moment(lastDryDockingEvent.endTimestamp), \"days\") < 0) {\n lastDryDockingEvent = event;\n }\n }\n } else {\n lastDryDockingEvent = event;\n }\n });\n return lastDryDockingEvent;\n }\n\n get lastMaintenanceEvent(): ISO19030Event {\n const currentDate = moment().format(\"YYYY-MM-DD\");\n let lastMaintenanceEvent!: ISO19030Event;\n this.maintenanceEvents.forEach(event => {\n const diff = moment(event.endTimestamp).diff(moment(currentDate), \"days\");\n if (diff > 0) {\n if (lastMaintenanceEvent) {\n if (moment(event.endTimestamp).diff(moment(lastMaintenanceEvent.endTimestamp), \"days\") < 0) {\n lastMaintenanceEvent = event;\n }\n }\n } else {\n lastMaintenanceEvent = event;\n }\n });\n return lastMaintenanceEvent;\n }\n\n get dryDockingEvents(): ISO19030Event[] {\n return this.syncEvents.filter(event => event.eventType === \"Docking\");\n }\n\n get maintenanceEvents(): ISO19030Event[] {\n return this.syncEvents.filter(event => event.eventType === \"Maintenance\");\n }\n\n get chartEvents(): ISO19030Event[] {\n if (this.isMaintenanceEffectChart) {\n return this.syncEvents.filter(event => event.eventType === \"Maintenance\");\n } else {\n return this.dryDockingEvents;\n }\n }\n\n get evaluationPeriods(): PerformanceIndicatorPeriod[] {\n return this.mutatedPeriods.filter(period => period.periodType === \"Evaluation Period\");\n }\n\n get hasCalculatedPeriods(): boolean {\n return Boolean(this.periods.length);\n }\n\n get differenceInPerformanceOfSelectedEvent(): number {\n return this.selectedEvaluationPeriod?.average - this.selectedReferencePeriod?.average;\n }\n\n get setDifferenceInPerformanceOfSelectedEvent(): string {\n return Boolean(this.differenceInPerformanceOfSelectedEvent) ? `${this.differenceInPerformanceOfSelectedEvent?.toFixed(1)}%` : \"N/A\";\n }\n\n get isDryDockingChart(): boolean {\n return this.title.toLowerCase().includes(\"docking\");\n }\n\n get isMaintenanceEffectChart(): boolean {\n return this.title === \"Maintenance Effect\";\n }\n\n get setEvaluationPeriodAverage(): string {\n return this.isEvaluationPeriodAvailable ? `${this.selectedEvaluationPeriod.average.toFixed(1)}%` : \"N/A\";\n }\n\n get setReferencesPeriodsAverage(): string {\n if (Boolean(this.referencePeriodsWithoutCurrentAverage)) {\n return `${this.referencePeriodsWithoutCurrentAverage.toFixed(1)}%`;\n } else {\n return \"N/A (There is no reference periods to calculate the average)\";\n }\n }\n\n get setSelectedReferencePeriodAverage(): string {\n return this.selectedReferencePeriod ? `${this.selectedReferencePeriod.average.toFixed(1)}%` : \"N/A\";\n }\n\n get setTriggerValue(): number | string | null | undefined {\n return this.selectedEvent ? this.selectedEvent?.triggerValue : \"N/A\";\n }\n\n get referencePeriodsWithoutCurrentAverage(): number {\n const referencePeriods = this.periods.filter(period => period.periodType === \"Reference Period\");\n const selectedReferencePeriod = this.periods.find(period => period.id === this.selectedReferencePeriod?.id);\n if (selectedReferencePeriod) {\n const referencePeriodsWithoutCurrent = referencePeriods.filter(period => {\n // check if period end date is before selected reference period start date\n if (moment(period.periodEndDate).isBefore(selectedReferencePeriod?.periodStartDate, \"day\") && period.id !== this.selectedReferencePeriod?.id) {\n return period;\n }\n });\n return referencePeriodsWithoutCurrent.reduce((acc: number, period: PerformanceIndicatorPeriod) => acc + period.average, 0) / referencePeriodsWithoutCurrent.length;\n } else {\n return referencePeriods.reduce((acc: number, period: PerformanceIndicatorPeriod) => acc + period.average, 0) / referencePeriods.length;\n }\n }\n\n get dryDockingDifferenceInPerformance(): number {\n if (!this.selectedReferencePeriod) return 0;\n const referencePeriodsWithoutCurrent = this.referencePeriods.filter(period => period.id !== this.selectedReferencePeriod?.id);\n const referencePeriodsWithoutCurrentAverage =\n referencePeriodsWithoutCurrent.reduce((acc: number, period: PerformanceIndicatorPeriod) => acc + period.average, 0) / referencePeriodsWithoutCurrent.length;\n return this.selectedReferencePeriod?.average - referencePeriodsWithoutCurrentAverage;\n }\n\n get setDryDockingDifferenceInPerformance(): string {\n return Boolean(this.dryDockingDifferenceInPerformance) ? `${this.dryDockingDifferenceInPerformance.toFixed(1)}%` : \"N/A\";\n }\n\n setDryDockingEvaluationPeriod(): void {\n // set selected reference period as evaluation period for dry docking chart\n if (!this.isDryDockingChart || !this.selectedReferencePeriod) return;\n this.mutatedPeriods = this.periods.filter((period: PerformanceIndicatorPeriod) => {\n if (moment(period.periodEndDate).isBefore(this.selectedEvent.startTimestamp, \"day\") || period.id === this.selectedReferencePeriod.id) {\n if (this.selectedReferencePeriod.id === period.id) {\n Vue.set(period, \"periodType\", \"Evaluation Period\");\n } else {\n Vue.set(period, \"periodType\", \"Reference Period\");\n }\n return period;\n }\n });\n }\n\n isPeriodReferenceType(type: string): boolean {\n return type === \"Reference Period\";\n }\n\n get periodLines(): any {\n if (!this.mutatedPeriods.length) return [];\n const periodLines: any = [];\n this.mutatedPeriods.forEach((period: any) => {\n // show period line if they have existed event\n if (this.syncEvents.filter(event => event.id === period.eventId).length) {\n periodLines.push(\n this.PeriodLine(\n Date.parse(period.periodStartDate),\n Date.parse(period.periodEndDate),\n period.average,\n this.isPeriodReferenceType(period.periodType) ? \"R\" : \"E\",\n this.isPeriodReferenceType(period.periodType) ? \"#ff5252\" : \"#0037ff\"\n )\n );\n }\n });\n\n // group lines by id to display common legend\n const firstReferenceIndex = periodLines.findIndex((line: any) => line.name === \"Reference period\");\n const firstEvaluationIndex = periodLines.findIndex((line: any) => line.name === \"Evaluation period\");\n if (firstReferenceIndex >= 0) {\n Vue.set(periodLines[firstReferenceIndex], \"id\", \"Reference\");\n Vue.delete(periodLines[firstReferenceIndex], \"linkedTo\");\n }\n if (firstEvaluationIndex >= 0) {\n Vue.set(periodLines[firstEvaluationIndex], \"id\", \"Evaluation\");\n Vue.delete(periodLines[firstEvaluationIndex], \"linkedTo\");\n }\n return periodLines;\n }\n\n PeriodLine(startDateMS: number, endDateMS: number, average: number, text: string, color: string): any {\n return {\n name: `${text === \"R\" ? \"Reference\" : \"Evaluation\"} period`,\n type: \"line\",\n color: color,\n lineWidth: 2,\n data: [[startDateMS, average], this.periodLineLabel(endDateMS, average, text, color)],\n linkedTo: `${text === \"R\" ? \"Reference\" : \"Evaluation\"}`,\n marker: {\n radius: 2.5,\n symbol: \"circle\",\n },\n zIndex: 5,\n };\n }\n\n periodLineLabel(dateMS: number, average: number, text: string, color: string): any {\n return {\n x: dateMS,\n y: average,\n dataLabels: {\n enabled: true,\n useHTML: true,\n formatter: function () {\n return `${text}`;\n },\n zIndex: 10,\n },\n };\n }\n\n get seriesData(): any {\n if (!this.performanceData.data) return [];\n if (this.chart.series.length) {\n /* IMPORTANT:\n There is also a bug in Highcharts when it has more than 2 series\n and they are updated dynamically it \"loses\" correct indexes of the\n series and displays data in a weird manner so the solution is to\n clear the series array before it will be updated */\n while (this.chart.series.length) {\n this.chart.series[0].remove();\n }\n }\n const scatterPoints = Object.entries(this.performanceData.data).map(([timestamp, value]) => {\n return [Date.parse(`${timestamp}Z`), value !== null ? Number(value) : null];\n });\n const scatterPointsSerie = {\n name: \"Speed Loss\",\n type: \"scatter\",\n data: scatterPoints,\n stickyTracking: false,\n /* IMPORTANT:\n https://www.highcharts.com/forum/viewtopic.php?f=9&t=44589\n Turns out scatter points have a bug. When they get updated they can be displayed as line-through-dots\n with property lineWidth: 2 so here we need to set the lineWidth: 0, otherwise it should be set always\n through chart.series.forEach loop in serie.options.lineWidth\n */\n lineWidth: 0,\n marker: {\n radius: 2.5,\n symbol: \"circle\",\n fillColor: \"#448eeb5c\",\n },\n };\n const series = [...this.periodLines, scatterPointsSerie];\n\n return series;\n }\n\n get plotLines(): IPlotLine[] {\n if (this.isMaintenanceEffectChart) {\n return [...this.maintenancePlotLines];\n } else {\n return [...this.dockingPlotLines];\n }\n }\n\n get plotBands(): IPlotBand[] {\n return [...this.dryDockingPlotBands, this.selectedEventPlotBand];\n }\n\n get maintenancePlotLines(): IPlotLine[] {\n if (!this.syncEvents.length) return [];\n const plotLines: IPlotLine[] = [];\n this.syncEvents.forEach((event: any) => {\n if (event.eventType !== \"Maintenance\") return;\n const html = this.getPlotLineLabelsHtml(event);\n plotLines.push({\n id: `plotline-${event.id}`,\n color: \"#2196F3\",\n value: moment.utc(event.startTimestamp).valueOf(),\n width: 2,\n zIndex: 5,\n label: {\n rotation: 0,\n style: { color: \"#2196F3\" },\n text: html,\n useHTML: true,\n y: -15,\n x: -11,\n },\n });\n });\n return plotLines;\n }\n\n get dockingPlotLines(): IPlotLine[] {\n if (!this.syncEvents.length) return [];\n const plotLines: IPlotLine[] = [];\n this.syncEvents.forEach(event => {\n if (event.eventType !== \"Docking\") return;\n plotLines.push(\n {\n id: `plotline-${event.id}`,\n color: \"#008000\",\n value: moment.utc(event.startTimestamp).valueOf(),\n width: 2,\n zIndex: 7,\n label: {\n rotation: 0,\n style: { color: \"#008000\" },\n text: this.getPlotLineLabelsHtml(event, \"start\", \"d\"),\n useHTML: true,\n y: -15,\n x: -11,\n },\n },\n {\n id: `plotline-${event.id}`,\n color: \"#008000\",\n value: moment.utc(event.endTimestamp).valueOf(),\n width: 2,\n zIndex: 7,\n label: {\n rotation: 0,\n style: { color: \"#008000\" },\n text: this.getPlotLineLabelsHtml(event, \"end\", \"d\"),\n useHTML: true,\n y: -15,\n x: -11,\n },\n }\n );\n });\n return plotLines;\n }\n\n getPlotLineLabelsHtml(event: ISO19030Event, timestamp = \"start\", letter = \"e\"): string {\n return `\n \n
\n ID: ${event.id}

\n

\n ${timestamp} date: ${\n timestamp === \"start\" ? dateHelper.getFormatedDateString(event.startTimestamp) : dateHelper.getFormatedDateString(event.endTimestamp)\n }\n

\n

${timestamp === \"start\" ? \"In-docking\" : \"Out-docking\"}

\n

${event.comment ?? \"No comment\"}

\n
\n `;\n }\n\n get dryDockingPlotBands(): IPlotBand[] {\n const plotBands: IPlotBand[] = [];\n if (!this.syncEvents.length || this.isMaintenanceEffectChart) return plotBands;\n\n this.syncEvents.forEach(event => {\n if (event.eventType !== \"Docking\") return;\n plotBands.push({\n from: moment.utc(event.startTimestamp).valueOf(),\n to: moment.utc(event.endTimestamp).valueOf(),\n id: event.id,\n className: \"performance-graph__plot-bands\",\n color: \"#0080001f\",\n zIndex: 4,\n });\n });\n\n return plotBands;\n }\n\n get selectedEventPlotBand(): IPlotBand {\n if (this.title === \"Maintenance Trigger\") return {} as IPlotBand;\n const eventPeriods: PerformanceIndicatorPeriod[] = this.mutatedPeriods.filter(period => period.eventId === this.selectedEvent.id);\n let plotBandStartDate!: string | undefined | null;\n let plotBandEndDate!: string | undefined | null;\n\n if (this.isMaintenanceEffectChart) {\n plotBandStartDate = eventPeriods.find(period => {\n // plotBandStartDate is the start date of the period BEFORE the event\n if (moment(period.periodStartDate).isBefore(this.selectedEvent.startTimestamp, \"day\")) {\n return period;\n }\n })?.periodStartDate;\n plotBandEndDate = eventPeriods.find(period => {\n // plotBandEndDate is the end date of the period AFTER the event\n if (moment(period.periodEndDate).isAfter(this.selectedEvent.startTimestamp, \"day\")) {\n return period;\n }\n })?.periodEndDate;\n } else {\n plotBandStartDate = this.selectedEvent?.startTimestamp;\n plotBandEndDate = eventPeriods.find(period => {\n if (moment(period.periodEndDate).isAfter(this.selectedEvent.startTimestamp, \"day\") && period.periodType === \"Evaluation Period\") {\n return period;\n }\n })?.periodEndDate;\n }\n\n if (!plotBandStartDate && !plotBandEndDate) return {} as IPlotBand;\n\n return {\n from: moment.utc(plotBandStartDate).valueOf(),\n to: moment.utc(plotBandEndDate).valueOf(),\n id: this.selectedEvent.id,\n className: \"performance-graph__plot-bands\",\n color: \"#6363f636\",\n zIndex: 4,\n };\n }\n\n formatDateForDisplay(start: string, end: string): string {\n if (!dateHelper.getFormatedDateString(end).length) return dateHelper.getFormatedDateString(start);\n else return `${dateHelper.getFormatedDateString(start)} - ${dateHelper.getFormatedDateString(end)}`;\n }\n\n formatDateString(date: string | null): string {\n if (!date) return \"\";\n return dateHelper.getFormatedDateString(date);\n }\n\n get chartSettings(): any {\n if (!this.chartLoaded) return {};\n return {\n type: \"line\",\n height: 300,\n spacingTop: 30,\n zoomType: \"x\",\n style: { fontFamily: \"Helvetica Neue\" },\n };\n }\n get ChartOptions(): any {\n if (!this.chartLoaded || !Highcharts) return {};\n const ctx = this;\n const options = {\n chart: ctx.chartSettings,\n title: { text: \"\" },\n legend: {\n enabled: true,\n },\n yAxis: {\n title: {\n text: \"Percent (%)\",\n style: { color: \"#331714\" },\n },\n labels: {\n format: \"{value}\",\n style: { color: \"#331714\" },\n },\n min: -50,\n max: 50,\n },\n xAxis: {\n type: \"datetime\",\n labels: {\n style: { color: \"#331714\" },\n },\n plotLines: this.plotLines,\n plotBands: this.plotBands,\n },\n plotOptions: {\n scatter: {\n lineWidth: 0,\n marker: {\n radius: 2.5,\n symbol: \"circle\",\n fillColor: \"#448eeb5c\",\n },\n tooltip: {\n outside: true,\n headerFormat: \"{point.key}
\",\n pointFormat: \"Value: {point.y}\",\n valueDecimals: 1,\n valueSuffix: \"%\",\n xDateFormat: \"%d. %b, %Y\",\n zIndex: 7,\n },\n },\n line: {\n tooltip: {\n outside: true,\n headerFormat: \"{point.key}
\",\n pointFormat: \"Value: {point.y}\",\n valueDecimals: 1,\n valueSuffix: \"%\",\n xDateFormat: \"%d. %b, %Y\",\n zIndex: 7,\n },\n },\n series: {\n states: {\n inactive: {\n opacity: 1,\n },\n },\n },\n },\n tooltip: {\n format: \"{value}\",\n zIndex: 50,\n },\n series: this.seriesData,\n credits: { enabled: false },\n exporting: { enabled: false },\n };\n\n return options;\n }\n\n chartReady(chart: any): void {\n this.chart = chart;\n this.chart.update(this.ChartOptions, true);\n this.chartLoaded = true;\n }\n\n mounted(): void {\n if (this.title !== \"Maintenance Effect\") {\n this.selectedEvent = this.lastDryDockingEvent;\n } else {\n this.selectedEvent = this.lastMaintenanceEvent;\n }\n this.setDryDockingEvaluationPeriod();\n }\n}\n","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--15-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./PerformanceIndicatorChart.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/ts-loader/index.js??ref--15-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./PerformanceIndicatorChart.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./PerformanceIndicatorChart.vue?vue&type=template&id=1040bbe5&scoped=true&\"\nimport script from \"./PerformanceIndicatorChart.vue?vue&type=script&lang=ts&\"\nexport * from \"./PerformanceIndicatorChart.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./PerformanceIndicatorChart.vue?vue&type=style&index=0&id=1040bbe5&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"1040bbe5\",\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VAlert } from 'vuetify/lib/components/VAlert';\nimport { VCard } from 'vuetify/lib/components/VCard';\nimport { VCardTitle } from 'vuetify/lib/components/VCard';\nimport { VExpansionPanel } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanelContent } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanelHeader } from 'vuetify/lib/components/VExpansionPanel';\nimport { VExpansionPanels } from 'vuetify/lib/components/VExpansionPanel';\nimport { VIcon } from 'vuetify/lib/components/VIcon';\nimport { VSelect } from 'vuetify/lib/components/VSelect';\nimport { VTooltip } from 'vuetify/lib/components/VTooltip';\ninstallComponents(component, {VAlert,VCard,VCardTitle,VExpansionPanel,VExpansionPanelContent,VExpansionPanelHeader,VExpansionPanels,VIcon,VSelect,VTooltip})\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, Vue } from \"vue-property-decorator\";\nimport store from \"@/store\";\nimport _ from \"underscore\";\nimport autoGranularity from \"Utilities/auto-granularity\";\n// components\nimport FeatureNotAvailable from \"@/components/FeatureNotAvailable.vue\";\nimport VesselEventsTable from \"@/components/Vessel/VesselEventsTable.vue\";\nimport PerformanceIndicatorChart from \"@/components/PerformanceIndicatorChart.vue\";\n// types\nimport { ISO19030Event } from \"@/types/ISO19030Event.js\";\nimport { PerformanceIndicatorPeriod } from \"@/types/PerformanceIndicatorPeriod.js\";\nimport { LogVariable } from \"@/types/logVariable.js\";\nimport { LogData } from \"@/types/logData.js\";\nimport { ExtendedVessel } from \"@/types/Vessel\";\n// modules\nimport { getModule } from \"vuex-module-decorators\";\nimport LogVariablesModule from \"@/store/clients/LogVariables.module\";\nimport ISO19030Module from \"@/store/clients/ISO19030.module\";\nimport LogDataClient from \"Clients/log-data-client\";\nimport VesselsModule from \"@/store/clients/Vessels.module\";\n\nconst ISO19030 = getModule(ISO19030Module, store);\nconst LogVariables = getModule(LogVariablesModule, store);\nconst Vessels = getModule(VesselsModule, store);\n\n@Component({\n components: {\n FeatureNotAvailable,\n VesselEventsTable,\n PerformanceIndicatorChart,\n },\n})\nexport default class DiagnosticsISO extends Vue {\n isLoading = false;\n performanceIndicatorsLogVariable: LogVariable = {} as LogVariable;\n ISO19030PerformanceLogData: LogData = {} as LogData;\n ISOChartTypes = [\"DryDocking Performance\", \"InService Performance\", \"Maintenance Trigger\", \"Maintenance Effect\"];\n isAnyEventUpdated = false;\n\n get vessel(): ExtendedVessel | null {\n return Vessels.currentVessel;\n }\n\n get featureEnabled(): boolean {\n if (!this.vessel) return false;\n return this.vessel.features.some(feature => feature.name === \"Iso19030\");\n }\n\n get vesselId(): number {\n return Number(this.$route.params.vesselId);\n }\n\n get eventsByVesselId(): ISO19030Event[] {\n return ISO19030.eventsByVesselId(this.vesselId);\n }\n\n get performanceIndicators(): PerformanceIndicatorPeriod[] {\n return ISO19030.performanceIndicators;\n }\n\n getISOChartTypePeriods(type: string): PerformanceIndicatorPeriod[] {\n switch (type) {\n case \"DryDocking Performance\":\n return this.performanceIndicators.filter(item => item.chartName === \"DryDocking Performance\");\n case \"InService Performance\":\n return this.performanceIndicators.filter(item => item.chartName === \"InService Performance\");\n case \"Maintenance Trigger\":\n return this.performanceIndicators.filter(item => item.chartName === \"Maintenance Trigger\");\n case \"Maintenance Effect\":\n return this.performanceIndicators.filter(item => item.chartName === \"Maintenance Effect\");\n default:\n return [] as PerformanceIndicatorPeriod[];\n }\n }\n\n get ISO19030PerformanceLogVariable(): LogVariable {\n return LogVariables.logVariableByName(\"ISO19030 Performance Value\");\n }\n\n async fetchPerformanceIndicatorsData(): Promise {\n if (_.isEmpty(this.ISO19030PerformanceLogVariable)) return;\n const minDate = this.ISO19030PerformanceLogVariable.logDataMinDate ?? \"\";\n const maxDate = this.ISO19030PerformanceLogVariable.logDataMaxDate ?? \"\";\n const selectedTimeInMinutes = this.minutesDiff(new Date(minDate), new Date(maxDate));\n\n this.ISO19030PerformanceLogData = await LogDataClient.findLogData(this.ISO19030PerformanceLogVariable.id, minDate, maxDate, autoGranularity(selectedTimeInMinutes));\n }\n\n minutesDiff(fromDate: Date, toDate: Date): number {\n const diff = (fromDate.getTime() - toDate.getTime()) / 1000 / 60;\n\n return Math.abs(Math.round(diff));\n }\n\n async initViewData(): Promise {\n this.isLoading = true;\n try {\n await Promise.all([await ISO19030.fetchEvents(), await ISO19030.fetchPerformanceIndicators(this.vesselId), await this.fetchPerformanceIndicatorsData()]);\n } catch (error) {\n console.warn(error);\n } finally {\n this.isLoading = false;\n }\n }\n\n eventUpdated(state: boolean): void {\n this.isAnyEventUpdated = state;\n }\n\n async created(): Promise {\n await this.initViewData();\n }\n}\n","import mod from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--15-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./DiagnosticsISO.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--15-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./DiagnosticsISO.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./DiagnosticsISO.vue?vue&type=template&id=051faa15&scoped=true&\"\nimport script from \"./DiagnosticsISO.vue?vue&type=script&lang=ts&\"\nexport * from \"./DiagnosticsISO.vue?vue&type=script&lang=ts&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"051faa15\",\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VSkeletonLoader } from 'vuetify/lib/components/VSkeletonLoader';\ninstallComponents(component, {VSkeletonLoader})\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Component, Vue } from \"vue-property-decorator\";\nimport Store from \"@/store\";\n//components\nimport DiagnosticsKyma from \"./DiagnosticsKyma.vue\";\nimport DiagnosticsISO from \"./DiagnosticsISO.vue\";\nimport FeatureNotAvailable from \"@/components/FeatureNotAvailable.vue\";\n// modules\nimport { getModule } from \"vuex-module-decorators\";\nimport LogVariablesModule from \"@/store/clients/LogVariables.module\";\n\nconst LogVariables = getModule(LogVariablesModule, Store);\n\n@Component({\n components: {\n DiagnosticsKyma,\n DiagnosticsISO,\n FeatureNotAvailable,\n },\n})\nexport default class Diagnostics extends Vue {\n DiagnosticViewTypes = [\n {\n component: \"DiagnosticsKyma\",\n text: \"Kyma\",\n },\n {\n component: \"DiagnosticsISO\",\n text: \"ISO19030\",\n },\n ];\n DiagnosticViewType = this.DiagnosticViewTypes[0];\n\n onViewTypeChanged(): void {\n console.log(\"onViewTypeChanged => onViewTypeChanged:\");\n localStorage.setItem(\"DiagnosticViewType\", JSON.stringify(this.DiagnosticViewType));\n }\n\n setDiagnosticViewType(): void {\n const strDiagnosticViewType: any = localStorage.getItem(\"DiagnosticViewType\") ?? this.DiagnosticViewTypes[0];\n if (typeof strDiagnosticViewType === \"string\") this.DiagnosticViewType = JSON.parse(strDiagnosticViewType);\n else this.DiagnosticViewType = strDiagnosticViewType;\n }\n\n async created(): Promise {\n if (!LogVariables.currentVesselLogVariables.length) await LogVariables.refreshCurrentVesselLogVariables(parseInt(this.$route.params.vesselId));\n this.setDiagnosticViewType();\n }\n}\n","import mod from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--15-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--15-0!../../../../node_modules/thread-loader/dist/cjs.js!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/ts-loader/index.js??ref--15-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./index.vue?vue&type=template&id=46fb2a2e&scoped=true&\"\nimport script from \"./index.vue?vue&type=script&lang=ts&\"\nexport * from \"./index.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./index.vue?vue&type=style&index=0&id=46fb2a2e&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"46fb2a2e\",\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VCard } from 'vuetify/lib/components/VCard';\nimport { VSelect } from 'vuetify/lib/components/VSelect';\ninstallComponents(component, {VCard,VSelect})\n","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--9-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--9-oneOf-1-1!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--9-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--9-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./VesselEventsTable.vue?vue&type=style&index=0&id=c7d6039a&lang=scss&scoped=true&\"","export * from \"-!../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--9-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--9-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--9-oneOf-1-2!../../node_modules/sass-loader/dist/cjs.js??ref--9-oneOf-1-3!../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./PerformanceIndicatorChart.vue?vue&type=style&index=0&id=1040bbe5&lang=scss&scoped=true&\"","export * from \"-!../../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--9-oneOf-1-0!../../../../node_modules/css-loader/dist/cjs.js??ref--9-oneOf-1-1!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/postcss-loader/src/index.js??ref--9-oneOf-1-2!../../../../node_modules/sass-loader/dist/cjs.js??ref--9-oneOf-1-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./index.vue?vue&type=style&index=0&id=46fb2a2e&lang=scss&scoped=true&\"","// Styles\nimport './VTextarea.sass'\n\n// Extensions\nimport VTextField from '../VTextField/VTextField'\n\n// Utilities\nimport mixins from '../../util/mixins'\n\n// Types\nimport Vue from 'vue'\n\ninterface options extends Vue {\n $refs: {\n input: HTMLTextAreaElement\n }\n}\n\nconst baseMixins = mixins\n>(\n VTextField\n)\n\n/* @vue/component */\nexport default baseMixins.extend({\n name: 'v-textarea',\n\n props: {\n autoGrow: Boolean,\n noResize: Boolean,\n rowHeight: {\n type: [Number, String],\n default: 24,\n validator: (v: any) => !isNaN(parseFloat(v)),\n },\n rows: {\n type: [Number, String],\n default: 5,\n validator: (v: any) => !isNaN(parseInt(v, 10)),\n },\n },\n\n computed: {\n classes (): object {\n return {\n 'v-textarea': true,\n 'v-textarea--auto-grow': this.autoGrow,\n 'v-textarea--no-resize': this.noResizeHandle,\n ...VTextField.options.computed.classes.call(this),\n }\n },\n noResizeHandle (): boolean {\n return this.noResize || this.autoGrow\n },\n },\n\n watch: {\n autoGrow (val: boolean) {\n this.$nextTick(() => {\n val\n ? this.calculateInputHeight()\n : this.$refs.input?.style.removeProperty('height')\n })\n },\n lazyValue () {\n this.autoGrow && this.$nextTick(this.calculateInputHeight)\n },\n rowHeight () {\n this.autoGrow && this.$nextTick(this.calculateInputHeight)\n },\n },\n\n mounted () {\n setTimeout(() => {\n this.autoGrow && this.calculateInputHeight()\n }, 0)\n },\n\n methods: {\n calculateInputHeight () {\n const input = this.$refs.input\n if (!input) return\n\n input.style.height = '0'\n const height = input.scrollHeight\n const minHeight = parseInt(this.rows, 10) * parseFloat(this.rowHeight)\n // This has to be done ASAP, waiting for Vue\n // to update the DOM causes ugly layout jumping\n input.style.height = Math.max(minHeight, height) + 'px'\n },\n genInput () {\n const input = VTextField.options.methods.genInput.call(this)\n\n input.tag = 'textarea'\n delete input.data!.attrs!.type\n input.data!.attrs!.rows = this.rows\n\n return input\n },\n onInput (e: Event) {\n VTextField.options.methods.onInput.call(this, e)\n this.autoGrow && this.calculateInputHeight()\n },\n onKeyDown (e: KeyboardEvent) {\n // Prevents closing of a\n // dialog when pressing\n // enter\n if (this.isFocused && e.keyCode === 13) {\n e.stopPropagation()\n }\n\n this.$emit('keydown', e)\n },\n },\n})\n","export * from \"-!../../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--9-oneOf-1-0!../../../../node_modules/css-loader/dist/cjs.js??ref--9-oneOf-1-1!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/postcss-loader/src/index.js??ref--9-oneOf-1-2!../../../../node_modules/sass-loader/dist/cjs.js??ref--9-oneOf-1-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./DiagnosticsKyma.vue?vue&type=style&index=0&id=5dcd4ee3&lang=scss&scoped=true&\""],"sourceRoot":""}