m2pool_web_frontend/mining-pool/src/views/helpCenter/index.js

96 lines
2.9 KiB
JavaScript
Raw Normal View History

export default{
name: 'HelpCenter',
data() {
return {
/** 搜索查询字符串 */
searchQuery: '',
/** 选中的语言 */
selectedLanguage: 'zh',
/** 分类按钮数据 */
categories: [
{ id: 1, name: 'API文档', route: 'apiFile' },
{ id: 2, name: '挖矿教程', route: 'AccessMiningPool/nexaAccess' },
{ id: 3, name: '服务条款', route: 'ServiceTerms' },
{ id: 3, name: '费率', route: 'rate' },
{ id: 4, name: '公告中心', route: 'announcements' },
],
/** 推荐内容数据 */
recommendedItems: [
{ id: 1, description: '矿池分配及转账规则' ,route:"allocationExplanation"},
// { id: 2, description: '余额不足如何任何偿还,该如何规划运营?' },
// { id: 3, description: '矿池选择它已经拥有综合的优势时间,怎么办?' }
],
/** 活动数据 */
activities: [
{
id: 1,
type: '最新公告',
title: 'LKY将停减税',
author: '文章ID1星期 主发布',
comments: '0'
},
{
id: 2,
type: '最新公告',
title: 'PFP将停减税',
author: '文章ID1星期 11发布',
comments: '0'
},
{
id: 3,
type: '最新公告',
title: 'ETC+ZIL停研发综合日获得',
author: '文章ID1星期 15发布',
comments: '0'
},
{
id: 4,
type: '最新公告',
title: '预计2023年06月19日SCC收益分配说明',
author: '文章ID1星期 18发布',
comments: '0'
},
{
id: 5,
type: '其他',
title: '关于临时(信为网站、备案管理、矿池编码)',
author: '文章ID1星期 19发布',
comments: '0'
}
]
}
},
methods: {
/**
* 处理搜索功能
*/
handleSearch() {
if (this.searchQuery.trim()) {
console.log('搜索内容:', this.searchQuery);
// 实际项目中这里应该调用搜索API
this.$message.success(`搜索: ${this.searchQuery}`);
}
},
/**
* 处理分类按钮点击
* @param {Object} category - 分类对象
*/
handleCategoryClick(category) {
console.log(category,"i肯定看到");
const lang = this.$i18n.locale;
this.$router.push(`/${lang}/${category.route}`);
},
/**
* 处理查看更多按钮点击
*/
handleViewMore() {
console.log('查看更多活动');
// 实际项目中这里应该跳转到活动列表页面
this.$message.info('查看更多活动');
}
}
}