Commit 1c4748d3 authored by Robert's avatar Robert 👽

UPD: Color code transactions in EVlog

parent df38215c
Pipeline #132023 passed with stages
in 6 minutes and 49 seconds
......@@ -26,6 +26,7 @@
import EVLogService from '@/api-services/evlog.service'
import Loading from '@/components/Loading'
import apiutil from '@/util/apiutil'
import '@/util/colorutil'
export default {
name: 'EVLogViewer',
......@@ -36,6 +37,11 @@ export default {
record_types: {},
top_n: 25,
table_fields: [
{
key: 'ta',
label: '',
tdAttr: this.ta_color
},
{
key: 'data',
label: 'Beschreibung'
......@@ -83,11 +89,14 @@ export default {
const res = await EVLogService.getByFK(this.$store.state.netdb_axios_config, this.ref_obj_fq, this.refobj_id_field, this.refobj_id_value, parseInt(this.top_n))
this.records = res.data[1]
this.record_types = apiutil.dict_by_value_of_array(res.data[2], 'short_name')
window.console.log(this.records)
},
ta_color(value, key, item, type) {
return {style: 'background: ' + item.ta_timestamp.toHSL({lit: [30, 40]})}
}
}
}
</script>
<style scoped>
</style>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment