add plain-text support for user page
parent
a5aa10d6f4
commit
34c3753d2c
|
|
@ -5,6 +5,7 @@ import type CustomTabBar from '../../custom-tab-bar';
|
||||||
import './user.scss';
|
import './user.scss';
|
||||||
import { AtList, AtListItem } from 'taro-ui';
|
import { AtList, AtListItem } from 'taro-ui';
|
||||||
import PageFooter from '@/components/PageFooter/PageFooter';
|
import PageFooter from '@/components/PageFooter/PageFooter';
|
||||||
|
import pt from '@/plain-text';
|
||||||
|
|
||||||
export default class UserPage extends Component {
|
export default class UserPage extends Component {
|
||||||
// 以下是TabBar相关
|
// 以下是TabBar相关
|
||||||
|
|
@ -44,30 +45,30 @@ export default class UserPage extends Component {
|
||||||
<View>
|
<View>
|
||||||
<AtList>
|
<AtList>
|
||||||
<AtListItem
|
<AtListItem
|
||||||
title='我的工单'
|
title={pt.get().userPage.ticketColumn.title}
|
||||||
note='在这里查看历史工单!'
|
note={pt.get().userPage.ticketColumn.note}
|
||||||
arrow='right'
|
arrow='right'
|
||||||
iconInfo={{ size: 25, color: '#E69966', value: 'clock' }}
|
iconInfo={{ size: 25, color: '#E69966', value: 'clock' }}
|
||||||
onClick={this.myTicketPage}
|
onClick={this.myTicketPage}
|
||||||
/>
|
/>
|
||||||
<AtListItem
|
<AtListItem
|
||||||
title='我的信息'
|
title={pt.get().userPage.infoColumn.title}
|
||||||
note='能帮助亦可更好地找到你哦!'
|
note={pt.get().userPage.infoColumn.note}
|
||||||
arrow='right'
|
arrow='right'
|
||||||
iconInfo={{ size: 25, color: '#78A4FA', value: 'user' }}
|
iconInfo={{ size: 25, color: '#78A4FA', value: 'user' }}
|
||||||
onClick={this.informPage}
|
onClick={this.informPage}
|
||||||
/>
|
/>
|
||||||
<AtListItem
|
<AtListItem
|
||||||
title='设置'
|
title={pt.get().userPage.settingsColumn.title}
|
||||||
note='配置小程序'
|
note={pt.get().userPage.settingsColumn.note}
|
||||||
extraText=''
|
extraText=''
|
||||||
arrow='right'
|
arrow='right'
|
||||||
iconInfo={{ size: 25, color: '#808080', value: 'filter' }}
|
iconInfo={{ size: 25, color: '#808080', value: 'filter' }}
|
||||||
onClick={this.settingsPage}
|
onClick={this.settingsPage}
|
||||||
/>
|
/>
|
||||||
<AtListItem
|
<AtListItem
|
||||||
title='意见反馈'
|
title={pt.get().userPage.reportColumn.title}
|
||||||
note='有什么想说的都可以告诉我们哦!'
|
note={pt.get().userPage.reportColumn.note}
|
||||||
extraText=''
|
extraText=''
|
||||||
arrow='right'
|
arrow='right'
|
||||||
iconInfo={{ size: 25, color: '#9ACD32', value: 'message' }}
|
iconInfo={{ size: 25, color: '#9ACD32', value: 'message' }}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,41 @@
|
||||||
|
export interface UserPageText {
|
||||||
|
mainTitleLine: string;
|
||||||
|
subTitleLine: string;
|
||||||
|
ticketColumn: {
|
||||||
|
title: string;
|
||||||
|
note: string;
|
||||||
|
};
|
||||||
|
infoColumn: {
|
||||||
|
title: string;
|
||||||
|
note: string;
|
||||||
|
};
|
||||||
|
settingsColumn: {
|
||||||
|
title: string;
|
||||||
|
note: string;
|
||||||
|
};
|
||||||
|
reportColumn: {
|
||||||
|
title: string;
|
||||||
|
note: string;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
export const userPageZhCn: UserPageText = {
|
||||||
|
mainTitleLine: '您好,这里是E志者协会',
|
||||||
|
subTitleLine: '维修请至【东三-204】实验室',
|
||||||
|
ticketColumn: {
|
||||||
|
title: '我的工单',
|
||||||
|
note: '在这里查看历史工单!',
|
||||||
|
},
|
||||||
|
infoColumn: {
|
||||||
|
title: '我的信息',
|
||||||
|
note: '能帮助亦可更好地找到你哦!',
|
||||||
|
},
|
||||||
|
settingsColumn: {
|
||||||
|
title: '应用设置',
|
||||||
|
note: '在这里配置小程序',
|
||||||
|
},
|
||||||
|
reportColumn: {
|
||||||
|
title: '意见反馈',
|
||||||
|
note: '有什么想说的都可以告诉亦可哦!',
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
@ -1,14 +1,17 @@
|
||||||
import { PageFooterText, pageFooterZhCn } from './PageFooter';
|
import { PageFooterText, pageFooterZhCn } from './PageFooter';
|
||||||
import { MainPageText, mainPageZhCn } from './MainPage';
|
import { MainPageText, mainPageZhCn } from './MainPage';
|
||||||
|
import { UserPageText, userPageZhCn } from './UserPage';
|
||||||
|
|
||||||
interface TextRecord {
|
interface TextRecord {
|
||||||
pageFooter: PageFooterText;
|
pageFooter: PageFooterText;
|
||||||
mainPage: MainPageText;
|
mainPage: MainPageText;
|
||||||
|
userPage: UserPageText;
|
||||||
}
|
}
|
||||||
|
|
||||||
const textZhCn: TextRecord = {
|
const textZhCn: TextRecord = {
|
||||||
pageFooter: pageFooterZhCn,
|
pageFooter: pageFooterZhCn,
|
||||||
mainPage: mainPageZhCn,
|
mainPage: mainPageZhCn,
|
||||||
|
userPage: userPageZhCn,
|
||||||
};
|
};
|
||||||
|
|
||||||
// type Lang = 'zh_CN' | 'en_US' | ...;
|
// type Lang = 'zh_CN' | 'en_US' | ...;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue