### [[2025]]年 - [[2025-06|06月]], [[2025-06-06|<]] [[第158天]] [[2025-06-08|>]] , 土曜日
---
## 記事
| 品 | 价 | 数 |
| ------------------------- | ------------------------------------------------------------------------------------------------------------------- | --- |
| 逆転裁判+逆転裁判2 オリジナル・サウンドトラック | [3500](https://item.fril.jp/5f2644b309656d48e1b776b75f2791db) | |
| 3ost | [3200](https://paypayfleamarket.yahoo.co.jp/item/z375784596) | 等返图 |
| 4ost | [5200全](https://www.suruga-ya.jp/product/detail/120029391?branch_number=0071) | |
| 5ost | [5500新](https://paypayfleamarket.yahoo.co.jp/item/z447668210) | |
| 逆転裁判サウンドBOX | [8500meru](https://jp.mercari.com/item/m22986255190)<br>[7480](https://auctions.yahoo.co.jp/jp/auction/s1172774814) | |
oOUTall:: 31912
24512+7400
oMONOall:: 24512
11800+12712
货
tongyi
Otongyi:: 11800
amex
Oamex:: 12712
1680+2400+1176 * 3 +1312+1152+2640
消耗
tongyi
货架
Utongyi:: 7400
370yuan
收款
```dataviewjs
const d = dv.current()
// === 原始字段 ===
const amex = d.Oamex || 0
const tongyi = d.Otongyi || 0
const nashiga = d.Onashiga || 0
const use_tongyi = d.Utongyi || 0
const use_nashiga = d.Unashiga || 0
const sal_tongyi = d.Stongyi || 0
const sal_nashiga = d.Snashiga || 0
// === 汇总值 ===
const oOUTall = amex + tongyi + nashiga
const oUSEall = use_tongyi + use_nashiga
const oSALall = sal_tongyi + sal_nashiga
const oALL = oOUTall + oUSEall + oSALall
// === Chart 配置 ===
const chartData = {
type: 'doughnut',
data: {
labels: [
'总货款',
'总消耗',
'总工资'
],
datasets: [
{
label: '总支出分类',
data: [oOUTall, oUSEall, oSALall],
backgroundColor: [
'rgba(75, 192, 192, 0.6)', // OUT
'rgba(153, 102, 255, 0.6)', // USE
'rgba(255, 159, 64, 0.6)' // SAL
],
borderColor: [
'rgba(75, 192, 192, 1)',
'rgba(153, 102, 255, 1)',
'rgba(255, 159, 64, 1)'
],
borderWidth: 1
}
]
},
options: {
responsive: true,
cutout: '50%',
plugins: {
legend: {
position: 'bottom'
},
tooltip: {
enabled: true
},
centerText: {
display: true,
text: `总支出:¥${oALL.toLocaleString()}`
}
}
},
plugins: [
{
id: 'centerText',
beforeDraw: function (chart) {
const width = chart.width;
const height = chart.height;
const ctx = chart.ctx;
ctx.restore();
const fontSize = (height / 150).toFixed(2);
ctx.font = `${fontSize}em sans-serif`;
ctx.textBaseline = 'middle';
const text = chart.options.plugins.centerText.text;
const textX = Math.round((width - ctx.measureText(text).width) / 2);
const textY = height / 2;
ctx.fillText(text, textX, textY);
ctx.save();
}
}
]
}
window.renderChart(chartData, this.container)
```
---
# memos