Signed-off-by: TIANHE <TIANHE@GMAIL.COM>
This commit is contained in:
TIANHE
2025-12-29 04:45:59 +08:00
parent d5e987b8ee
commit 278b88ec71
26 changed files with 3220 additions and 317 deletions
-6
View File
@@ -1,6 +0,0 @@
FROM nginx
RUN rm /etc/nginx/conf.d/default.conf
ADD deploy/nginx.conf /etc/nginx/conf.d/default.conf
COPY dist/ /usr/share/nginx/html/
-21
View File
@@ -1,21 +0,0 @@
MIT License
Copyright (c) 2018 Anan Yang
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
@@ -934,6 +934,7 @@ const locale = {
'dashboard.aiStrategies': 'AI Strategies',
'dashboard.indicatorStrategies': 'Indicator Strategies',
'dashboard.running': 'Running',
'dashboard.enabled': 'Enabled',
'dashboard.pnlHistory': 'P&L History',
'dashboard.strategyPerformance': 'Strategy Performance',
'dashboard.recentTrades': 'Recent Trades',
@@ -959,6 +960,7 @@ const locale = {
'dashboard.orderTable.amount': 'Amount',
'dashboard.orderTable.price': 'Filled Price',
'dashboard.orderTable.status': 'Status',
'dashboard.orderTable.timeInfo': 'Time',
'dashboard.orderTable.executedAt': 'Executed Time',
'dashboard.orderTable.exchange': 'Exchange',
'dashboard.orderTable.notify': 'Notify',
@@ -842,6 +842,7 @@ const locale = {
'dashboard.aiStrategies': 'AI 策略',
'dashboard.indicatorStrategies': '指标策略',
'dashboard.running': '运行中',
'dashboard.enabled': '已启用',
'dashboard.pnlHistory': '历史盈亏',
'dashboard.strategyPerformance': '策略盈亏占比',
'dashboard.recentTrades': '最近交易',
@@ -867,6 +868,7 @@ const locale = {
'dashboard.orderTable.amount': '数量',
'dashboard.orderTable.price': '成交价',
'dashboard.orderTable.status': '状态',
'dashboard.orderTable.timeInfo': '时间',
'dashboard.orderTable.executedAt': '执行时间',
'dashboard.orderTable.exchange': '交易所',
'dashboard.orderTable.notify': '通知方式',
@@ -843,6 +843,7 @@ const locale = {
'dashboard.aiStrategies': 'AI 策略',
'dashboard.indicatorStrategies': '指標策略',
'dashboard.running': '運行中',
'dashboard.enabled': '已啟用',
'dashboard.pnlHistory': '歷史盈虧',
'dashboard.strategyPerformance': '策略盈虧佔比',
'dashboard.recentTrades': '最近交易',
@@ -868,6 +869,7 @@ const locale = {
'dashboard.orderTable.amount': '數量',
'dashboard.orderTable.price': '成交價',
'dashboard.orderTable.status': '狀態',
'dashboard.orderTable.timeInfo': '時間',
'dashboard.orderTable.executedAt': '執行時間',
'dashboard.orderTable.exchange': '交易所',
'dashboard.orderTable.notify': '通知方式',
+12 -42
View File
@@ -41,7 +41,7 @@
<!-- 运行中 AI 策略 -->
<a-col :xs="12" :sm="12" :md="6">
<div class="dashboard-card info-card clickable-card" @click="$router.push('/ai-trading-assistant')">
<div class="dashboard-card info-card">
<div class="card-icon">
<a-icon type="thunderbolt" theme="filled" />
</div>
@@ -49,7 +49,7 @@
<div class="card-label">{{ $t('dashboard.aiStrategies') }}</div>
<div class="card-value">
<span class="number">{{ summary.ai_strategy_count }}</span>
<span class="unit">{{ $t('dashboard.running') }}</span>
<span class="unit">{{ $t('dashboard.enabled') }}</span>
</div>
</div>
</div>
@@ -229,29 +229,12 @@
</div>
<div v-else style="color: #999;">-</div>
</template>
<template slot="created_at" slot-scope="text">
{{ formatTime(text) }}
</template>
<template slot="executed_at" slot-scope="text">
<span v-if="text">{{ formatTime(text) }}</span>
<span v-else style="color: #999;">-</span>
</template>
<template slot="actions" slot-scope="text, record">
<a-popconfirm
:title="$t('dashboard.orderTable.deleteConfirm')"
:okText="$t('dashboard.orderTable.delete')"
:cancelText="$t('cancel')"
@confirm="handleDeletePendingOrder(record)"
>
<a-button
type="link"
size="small"
:disabled="record && String(record.status).toLowerCase() === 'processing'"
>
<a-icon type="delete" />
{{ $t('dashboard.orderTable.delete') }}
</a-button>
</a-popconfirm>
<template slot="time_info" slot-scope="text, record">
<div>{{ formatTime(record.created_at) }}</div>
<div v-if="record.executed_at" style="font-size: 12px; color: #999;">
{{ formatTime(record.executed_at) }}
</div>
<div v-else style="font-size: 12px; color: #999;">-</div>
</template>
</a-table>
</a-card>
@@ -372,12 +355,6 @@ export default {
},
orderColumns () {
return [
{
title: this.$t('dashboard.orderTable.time'),
dataIndex: 'created_at',
scopedSlots: { customRender: 'created_at' },
width: 160
},
{
title: this.$t('dashboard.orderTable.strategy'),
dataIndex: 'strategy_name',
@@ -430,17 +407,10 @@ export default {
width: 150
},
{
title: this.$t('dashboard.orderTable.executedAt'),
dataIndex: 'executed_at',
scopedSlots: { customRender: 'executed_at' },
width: 160
},
{
title: this.$t('dashboard.orderTable.actions'),
key: 'actions',
scopedSlots: { customRender: 'actions' },
width: 110,
fixed: 'right'
title: this.$t('dashboard.orderTable.timeInfo'),
dataIndex: 'created_at',
scopedSlots: { customRender: 'time_info' },
width: 180
}
]
}