allow click legend after update chart
This commit is contained in:
@@ -88,9 +88,9 @@
|
||||
mounted: function (chartContext, config) {
|
||||
renderLegend(chartContext);
|
||||
},
|
||||
updated: function (chartContext, config) {
|
||||
{{-- updated: function (chartContext, config) {
|
||||
renderLegend(chartContext);
|
||||
}
|
||||
} --}}
|
||||
}
|
||||
|
||||
this.data.tooltip = {
|
||||
@@ -117,6 +117,7 @@
|
||||
|
||||
// generate custom legend view
|
||||
function renderLegend(chartContext) {
|
||||
console.log(chartContext)
|
||||
var legendContainer = document.querySelector('#chart-legend-{{ $name }}');
|
||||
|
||||
if (!legendContainer) return;
|
||||
|
||||
@@ -36,6 +36,7 @@ new class extends Component {
|
||||
$dailyChangeQuery = DailyChange::query();
|
||||
|
||||
if (isset($this->portfolio)) {
|
||||
|
||||
$dailyChangeQuery->portfolio($this->portfolio->id);
|
||||
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user