Browse Source

屏蔽一些小程序审核不过的功能

master
xuxu 5 years ago
parent
commit
050b73b1a0
  1. 10
      app.js
  2. BIN
      images/temp_1.png
  3. 17
      pages/resource/list/index.js
  4. 2
      pages/resource/list/index.wxml
  5. 6
      pages/topics/interactive/submitTopic/index.js
  6. 36
      pages/topics/interactive/submitTopic/index.wxml

10
app.js

@ -18,6 +18,13 @@ App({
http.fetchAuthToken(res => {
// console.log(res)
})
http.getConfig(res=>{
if(res.result.projectFlag == 1){
this.globalData.flag = 1;
}
})
},
globalData: {
userInfo: null,
@ -27,6 +34,7 @@ App({
faceImg:'',
},
windowHeight:'',
screenHeight:''
screenHeight:'',
flag:0
}
})

BIN
images/temp_1.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

17
pages/resource/list/index.js

@ -34,13 +34,26 @@ Component({
}
if(this.properties.tp == '1'){ // 资源列表
if(e.currentTarget.dataset.url){
if(e.currentTarget.dataset.url){ // 跳转网站
wx.navigateTo({
url: '/pages/resource/navigate/index?url=' + encodeURIComponent(e.currentTarget.dataset.url)
})
return;
}else{
}else if(e.currentTarget.dataset.appid){ // 跳转小程序
wx.navigateToMiniProgram({
appId: e.currentTarget.dataset.appid,
// path: 'page/index/index?id=123',
extraData: {
// foo: 'bar'
},
envVersion: 'release',
success(res) {
// 打开成功
}
})
return;
}else{ // 查看详情
wx.navigateTo({
url: '/pages/resource/detail/index?id=' + e.currentTarget.dataset.id
})

2
pages/resource/list/index.wxml

@ -1,6 +1,6 @@
<!--pages/resource/list/index.wxml-->
<view class="container">
<view class="column" wx:for="{{ list }}" bindtap="detail" data-id="{{item.id}}" data-url="{{item.url}}">
<view class="column" wx:for="{{ list }}" bindtap="detail" data-id="{{item.id}}" data-url="{{item.url}}" data-appid="{{item.appid}}">
<view class="left">
<block wx:if="{{tp == '1'}}">
<view class="articleImg">

6
pages/topics/interactive/submitTopic/index.js

@ -3,7 +3,7 @@ import { config } from '../../../../config.js'
import { store } from '../../../../utils/store.js'
import { TopicModel } from '../../../../models/topic.js'
let topicModel = new TopicModel()
const app = getApp()
Page({
/**
@ -12,7 +12,8 @@ Page({
data: {
topicTitle:"",
topicDetail:"",
files:[]
files:[],
flag:0
},
/**
@ -20,6 +21,7 @@ Page({
*/
onLoad: function (options) {
this.setData({
flag:app.globalData.flag,
uplaodFile: this.uplaodFile.bind(this)
})
},

36
pages/topics/interactive/submitTopic/index.wxml

@ -1,22 +1,24 @@
<!--pages/topics/interactive/submitTopic/index.wxml-->
<view class="container">
<view class="item">
<view class="must_fill">*</view>
<input class="title" maxlength="95" value="{{topicTitle}}" bindinput="bindTextInput" placeholder="议题标题"></input>
</view>
<view class="line-view"></view>
<block wx:if="{{flag}}">
<view class="container">
<view class="item">
<view class="must_fill">*</view>
<textarea class="textArea" maxlength="1000" value="{{topicDetail}}" bindinput="bindTextAreaInput" placeholder="议题内容" />
<input class="title" maxlength="95" value="{{topicTitle}}" bindinput="bindTextInput" placeholder="议题标题"></input>
</view>
<view class="line-view"></view>
<view class="item">
<view class="must_fill">*</view>
<textarea class="textArea" maxlength="1000" value="{{topicDetail}}" bindinput="bindTextAreaInput" placeholder="议题内容" />
</view>
<mp-cells ext-class="uploader_bd">
<mp-cell>
<mp-uploader ext-class="myUploader" binddelete="deleteFile" upload="{{uplaodFile}}" files="{{files}}" max-count="9" delete="true"></mp-uploader>
</mp-cell>
</mp-cells>
<view class="btnView">
<e-ibutton title="提交" bind:onTap="submit"/>
</view>
<mp-cells ext-class="uploader_bd">
<mp-cell>
<mp-uploader ext-class="myUploader" binddelete="deleteFile" upload="{{uplaodFile}}" files="{{files}}" max-count="9" delete="true"></mp-uploader>
</mp-cell>
</mp-cells>
<view class="btnView">
<e-ibutton title="提交" bind:onTap="submit"/>
</view>
</view>
</block>
Loading…
Cancel
Save