修正搜索列表无法显示数据的bug
This commit is contained in:
parent
c93271626c
commit
0d9c556153
@ -1,7 +1,7 @@
|
||||
{
|
||||
"description": "A WePY project",
|
||||
"setting": {
|
||||
"urlCheck": false,
|
||||
"urlCheck": true,
|
||||
"es6": false,
|
||||
"postcss": false,
|
||||
"minified": false,
|
||||
|
@ -1,4 +1,4 @@
|
||||
const env = 'test'; //product, test
|
||||
const env = 'product'; //product, test
|
||||
export default {
|
||||
env: env,
|
||||
apiBase: env === 'test'? 'https://ghost-test.kingsome.cn' : 'https://ghost.kingsome.cn',
|
||||
|
@ -57,7 +57,7 @@
|
||||
import recordCell from '../components/game-cell';
|
||||
import recentGame from '../components/recent-game';
|
||||
import zanLoadmore from '../components/zan-loadmore';
|
||||
import g from '../common/global';
|
||||
import global from '../common/global';
|
||||
import jcEvent from '../common/jc-event';
|
||||
|
||||
export default class SearchPage extends wepy.page {
|
||||
@ -86,7 +86,7 @@
|
||||
language: '所有语言',
|
||||
type: 0,
|
||||
languageArr: ['所有语言', '中文', '简体中文', '繁体中文', '英文', '日文', '多国语言', '德文', '法文', '欧洲', '其他'],
|
||||
typeArr: g.gameTypes,
|
||||
typeArr: global.gameTypes,
|
||||
typeName: '所有类型',
|
||||
showAll: false,
|
||||
category: '所有',
|
||||
@ -202,8 +202,11 @@
|
||||
self.current += 10;
|
||||
for (let obj of res.records) {
|
||||
(obj.open) && (obj.owned = true);
|
||||
if (this.record.type <= g.gameTypes.length) {
|
||||
this.typeStr = g.gameTypes[this.record.type - 1];
|
||||
if (obj.type <= self.typeArr.length) {
|
||||
obj.typeStr = self.typeArr[this.record.type - 1];
|
||||
}
|
||||
if (obj.images && obj.images.length > 0) {
|
||||
obj.icon = obj.images[0];
|
||||
}
|
||||
self.records.push(obj);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user