This commit is contained in:
@@ -10,7 +10,7 @@ export default {
|
|||||||
role.SalesFull,
|
role.SalesFull,
|
||||||
role.SalesLimited
|
role.SalesLimited
|
||||||
],
|
],
|
||||||
title: "Priciest widgets",
|
title: "Priciest widgets (all time) ",
|
||||||
type: "GzDashTestListWidgetsPriciest"
|
type: "GzDashTestListWidgetsPriciest"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -7,11 +7,11 @@
|
|||||||
v-bind="$attrs"
|
v-bind="$attrs"
|
||||||
>
|
>
|
||||||
<template slot="main">
|
<template slot="main">
|
||||||
<div class="ml-4 mt-1 d-flex align-center">
|
<div class="ml-4 mt-1">
|
||||||
<div>
|
<template v-for="(item, i) in obj"
|
||||||
max list items:{{ maxListItems }}
|
><span :key="i"
|
||||||
<span class="green--text">{{ obj }}</span>
|
>{{ localizedCurrency(item[1].v) }} - {{ item[0].v }} <br /></span
|
||||||
</div>
|
></template>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</gz-dash>
|
</gz-dash>
|
||||||
@@ -33,7 +33,11 @@ export default {
|
|||||||
GzDash
|
GzDash
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return { obj: [] };
|
return {
|
||||||
|
obj: [],
|
||||||
|
currencyName: window.$gz.locale.getCurrencyName(),
|
||||||
|
languageName: window.$gz.locale.getBrowserFirstLanguage()
|
||||||
|
};
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
maxListItems: { type: Number, default: 10 }
|
maxListItems: { type: Number, default: 10 }
|
||||||
@@ -50,6 +54,13 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
this.obj = [];
|
this.obj = [];
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
localizedCurrency(value) {
|
||||||
|
return window.$gz.locale.currencyLocalized(
|
||||||
|
value,
|
||||||
|
this.languageName,
|
||||||
|
this.currencyName
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -227,6 +227,9 @@ Vue.prototype.$ay = {
|
|||||||
},
|
},
|
||||||
sd: function(timestamp) {
|
sd: function(timestamp) {
|
||||||
return locale.utcDateToShortDateLocalized(timestamp);
|
return locale.utcDateToShortDateLocalized(timestamp);
|
||||||
|
},
|
||||||
|
cur: function(value) {
|
||||||
|
return locale.currencyLocalized(value);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
new Vue({
|
new Vue({
|
||||||
|
|||||||
@@ -27,7 +27,6 @@
|
|||||||
</v-card-text>
|
</v-card-text>
|
||||||
|
|
||||||
<v-divider></v-divider>
|
<v-divider></v-divider>
|
||||||
|
|
||||||
<v-card-actions>
|
<v-card-actions>
|
||||||
<v-btn
|
<v-btn
|
||||||
color="primary"
|
color="primary"
|
||||||
|
|||||||
Reference in New Issue
Block a user