作者 niufei

测试修改问题

... ... @@ -35,6 +35,7 @@ App({
wx.showNavigationBarLoading()
wx.showLoading({
title: '加载中',
mask: true
})
var promise = new Promise((resolve, reject) => {
let that = this;
... ... @@ -54,19 +55,7 @@ App({
if (res.data.code == '20000') {
resolve(res.data.data);
} else if (res.data.code == '10001') { //用户未
// wx.showModal({
// title: '提示',
// content: res.data.msg,
// showCancel: false,
// success: function (res) {
// if (res.confirm) {
// wx.removeStorageSync('token');
// wx.navigateTo({
// url: '/pages/start/start',
// })
// }
// }
// })
} else if (res.data.code == '40000') {
wx.showModal({
title: '提示',
... ...
... ... @@ -46,6 +46,7 @@ Page({
getdatalist() {
wx.showLoading({
title: '加载中',
mask: true
})
let that = this
let head = {
... ... @@ -88,6 +89,7 @@ Page({
wx.showToast({
title: '请输入工时',
icon: 'none',
mask: true,
duration: 1000
})
return
... ... @@ -103,6 +105,7 @@ Page({
app.post(url, params, head).then((res) => {
wx.showToast({
title: '操作成功',
mask: true,
icon: 'success',
duration: 1000,
success: () => {
... ... @@ -148,6 +151,7 @@ Page({
app.post(url, params, head).then((res) => {
wx.showToast({
title: '操作成功',
mask: true,
icon: 'success',
duration: 1000,
success: () => {
... ...
... ... @@ -613,6 +613,7 @@ Page({
app.post(url, params, head).then((res) => {
wx.showToast({
title: '提交成功,等待审核',
mask: true,
icon: 'none',
duration: 2000
})
... ... @@ -627,6 +628,7 @@ Page({
wx.showToast({
title: err,
icon: 'none',
mask: true,
duration: 2000
})
}
... ...
... ... @@ -74,6 +74,7 @@ Page({
wx.showToast({
title: '操作成功',
icon: 'success',
mask: true,
duration: 1000,
success: () => {
that.setData({
... ... @@ -140,6 +141,7 @@ Page({
wx.showToast({
title: '操作成功',
icon: 'success',
mask: true,
duration: 1000,
success: () => {
that.setData({
... ... @@ -390,6 +392,7 @@ Page({
push(form_id) {
wx.showLoading({
title: '提交中',
mask: true
})
let that = this
let url = that.data.page_type ?'index/index/editApply':'index/index/applyJoin'
... ... @@ -409,6 +412,7 @@ Page({
wx.hideLoading()
wx.showToast({
title: '报名成功',
mask: true,
duration: 1000,
success: ()=>{
wx.setStorageSync('page_type', true)
... ...
... ... @@ -47,6 +47,7 @@ Page({
success: (r) => {
wx.showToast({
title: '保存成功',
mask: true,
duration: 1000
})
}
... ... @@ -76,6 +77,7 @@ Page({
app.post(url, params, header).then((res) => {
wx.showToast({
title: '退出成功',
mask: true,
duration: 1000,
success: () => {
setTimeout(() => {
... ...
... ... @@ -136,19 +136,19 @@ Page({
* 页面上拉触底事件的处理函数
*/
onReachBottom: function() {
let that = this
if (that.data.page_type == false) {
wx.showToast({
title: '暂无更多数据',
icon: 'none',
duration: 1000
})
return false
}
that.setData({
activity_page: that.data.activity_page + 1
})
that.getdatalist()
// let that = this
// if (that.data.page_type == false) {
// wx.showToast({
// title: '暂无更多数据',
// icon: 'none',
// duration: 1000
// })
// return false
// }
// that.setData({
// activity_page: that.data.activity_page + 1
// })
// that.getdatalist()
},
/**
... ...
... ... @@ -14,6 +14,7 @@ Page({
getdatalist() {
wx.showLoading({
title: '加载中',
mask: true
})
let that = this
let head = {
... ...
... ... @@ -31,16 +31,16 @@ Page({
upimg: function() {
let that = this
let imgarr = that.data.imgarr
let allow_image = 6 - that.data.imgarr.length
let allow_image = 9 - that.data.imgarr.length
if (allow_image == 0) {
wx.showToast({
title: '最多添加6张图片',
title: '最多添加9张图片',
icon: 'none',
duration: 1000
})
return
}
wx.chooseImage({
wx. ({
count: allow_image,
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
... ... @@ -53,6 +53,10 @@ Page({
},
// 图片上传
upload_img(imgarr) {
wx.showLoading({
title: '提交中',
mask: true
})
let that = this
let myimgurl = that.data.myimgurl
let header = {
... ... @@ -76,6 +80,7 @@ Page({
myimgurl: myimgurl
})
if (that.data.myimgurl.length == imgarr.length){
wx.hideLoading()
that.push()
}
}
... ... @@ -133,6 +138,10 @@ Page({
},
push(){
let that = this
wx.showLoading({
title: '提交中',
mask: true
})
let url = 'index/index/sginIn'
let params = {
id: that.data.id,
... ... @@ -145,6 +154,7 @@ Page({
'XX-Token': wx.getStorageSync('token')
}
app.post(url, params, header).then((res) => {
wx.hideLoading()
wx.showToast({
title: '提交成功',
duration: 1000,
... ...