Browse Source

新增申购和修改默认语言

master
ltlzx 4 years ago
parent
commit
0cfb364506
  1. 18
      pages/base/index.vue
  2. 6
      pages/exchange/index.vue
  3. 12
      store/index.js

18
pages/base/index.vue

@ -44,6 +44,7 @@
<script> <script>
import Home from "./home"; import Home from "./home";
import ExchangeOperation from "./exchange-operation"; import ExchangeOperation from "./exchange-operation";
import Purchase from "../purchase/index";
import Mine from "./mine"; import Mine from "./mine";
import OptionList from "./option-list"; import OptionList from "./option-list";
// import List from "./list"; // import List from "./list";
@ -55,7 +56,8 @@ export default {
ExchangeOperation, ExchangeOperation,
OptionList, OptionList,
Mine, Mine,
Contract Contract,
Purchase
}, },
computed: { computed: {
navList() { navList() {
@ -72,12 +74,14 @@ export default {
icon: "static/img/base_link_0.png", icon: "static/img/base_link_0.png",
activeIcon: "static/img/base_link_1.png", activeIcon: "static/img/base_link_1.png",
}, },
// { {
// label: this.$t("base.a4"), // label: this.$t("base.a4"),
// tel: "option-list", // tel: "option-list",
// icon: "static/img/base_qukuai_0.png", label: this.$t("purchase.a5"),
// activeIcon: "static/img/base_qukuai_1.png", tel: "purchase",
// }, icon: "static/img/base_qukuai_0.png",
activeIcon: "static/img/base_qukuai_1.png",
},
{ {
label: this.$t("exchange.a2"), label: this.$t("exchange.a2"),
tel: "contract", tel: "contract",

6
pages/exchange/index.vue

@ -315,7 +315,8 @@ export default {
interval: this.activeTime, interval: this.activeTime,
resolutions: this.resolutions.map((item) => item.value), resolutions: this.resolutions.map((item) => item.value),
contract: 1, contract: 1,
lang:uni.getStorageSync('language')||'zh-CN' // lang:uni.getStorageSync('language')||'zh-CN'
lang:'en'
}; };
} else { } else {
return { return {
@ -326,7 +327,8 @@ export default {
// interval: this.activeTime, // interval: this.activeTime,
// resolutions: this.resolutions.map((item) => item.value), // resolutions: this.resolutions.map((item) => item.value),
// contract: 1, // contract: 1,
lang:uni.getStorageSync('language')||'zh-CN', // lang:uni.getStorageSync('language')||'zh-CN',
lang:'en',
getLinkUrl: this.app.baseUrl + "/api/app/option/getKline", getLinkUrl: this.app.baseUrl + "/api/app/option/getKline",
symbol: this.query.code, symbol: this.query.code,
theme: this.theme, theme: this.theme,

12
store/index.js

@ -68,17 +68,19 @@ let store = new Vuex.Store({
if (!uni.getStorageSync('logoMap')) return {}; if (!uni.getStorageSync('logoMap')) return {};
return JSON.parse(uni.getStorageSync('logoMap')) return JSON.parse(uni.getStorageSync('logoMap'))
})(), })(),
lang: uni.getStorageSync('language')||'zh-CN', // lang: uni.getStorageSync('language')||'zh-CN',
lang:'en',
version:uni.getStorageSync('version'), version:uni.getStorageSync('version'),
langList: [ langList: [
{
value: 'zh-CN',
label: '简体中文'
},
{ {
value: 'en', value: 'en',
label: 'English' label: 'English'
}, },
{
value: 'zh-CN',
label: '简体中文'
},
{ {
value: 'zh-TW', value: 'zh-TW',
label: '繁體中文' label: '繁體中文'

Loading…
Cancel
Save