fix
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 35s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
All checks were successful
Docker Build & Deploy / Build Docker Image (push) Successful in 35s
Docker Build & Deploy / Deploy to Production (push) Successful in 6s
Docker Build & Deploy / Cleanup Dangling Images (push) Successful in 1s
Docker Build & Deploy / WeChat Notification (push) Successful in 1s
This commit is contained in:
@@ -65,6 +65,14 @@
|
|||||||
<div class="bottom-spacer" />
|
<div class="bottom-spacer" />
|
||||||
</van-pull-refresh>
|
</van-pull-refresh>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- 交易详情弹窗 -->
|
||||||
|
<TransactionDetailSheet
|
||||||
|
v-model:show="showTransactionDetail"
|
||||||
|
:transaction="currentTransaction"
|
||||||
|
@save="handleTransactionSave"
|
||||||
|
@delete="handleTransactionDelete"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -75,6 +83,8 @@ import { showToast } from 'vant'
|
|||||||
import CalendarModule from './modules/Calendar.vue'
|
import CalendarModule from './modules/Calendar.vue'
|
||||||
import StatsModule from './modules/Stats.vue'
|
import StatsModule from './modules/Stats.vue'
|
||||||
import TransactionListModule from './modules/TransactionList.vue'
|
import TransactionListModule from './modules/TransactionList.vue'
|
||||||
|
import TransactionDetailSheet from '@/components/Transaction/TransactionDetailSheet.vue'
|
||||||
|
import { getTransactionDetail } from '@/api/transactionRecord'
|
||||||
|
|
||||||
// 定义组件名称(keep-alive 需要通过 name 识别)
|
// 定义组件名称(keep-alive 需要通过 name 识别)
|
||||||
defineOptions({
|
defineOptions({
|
||||||
@@ -135,12 +145,35 @@ const onDayClick = async (day) => {
|
|||||||
selectedDate.value = clickedDate
|
selectedDate.value = clickedDate
|
||||||
}
|
}
|
||||||
|
|
||||||
// 点击交易卡片 - 跳转到详情页
|
// 交易详情弹窗相关
|
||||||
const onTransactionClick = (txn) => {
|
const showTransactionDetail = ref(false)
|
||||||
router.push({
|
const currentTransaction = ref(null)
|
||||||
path: '/transaction-detail',
|
|
||||||
query: { id: txn.id }
|
// 点击交易卡片 - 打开详情弹窗
|
||||||
})
|
const onTransactionClick = async (txn) => {
|
||||||
|
try {
|
||||||
|
// 获取完整的交易详情
|
||||||
|
const response = await getTransactionDetail(txn.id)
|
||||||
|
if (response.success && response.data) {
|
||||||
|
currentTransaction.value = response.data
|
||||||
|
showTransactionDetail.value = true
|
||||||
|
} else {
|
||||||
|
showToast('获取交易详情失败')
|
||||||
|
}
|
||||||
|
} catch (error) {
|
||||||
|
console.error('获取交易详情失败:', error)
|
||||||
|
showToast('获取交易详情失败')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 保存交易后刷新列表
|
||||||
|
const handleTransactionSave = () => {
|
||||||
|
handleTransactionsChanged()
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除交易后刷新列表
|
||||||
|
const handleTransactionDelete = () => {
|
||||||
|
handleTransactionsChanged()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 点击通知按钮
|
// 点击通知按钮
|
||||||
@@ -301,6 +334,7 @@ onBeforeUnmount(() => {
|
|||||||
|
|
||||||
/* ========== 页面容器 ========== */
|
/* ========== 页面容器 ========== */
|
||||||
.calendar-v2-wrapper {
|
.calendar-v2-wrapper {
|
||||||
|
background-color: var(--bg-primary);
|
||||||
font-family: var(--font-primary);
|
font-family: var(--font-primary);
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user