Commit 6bd9dcb5 by 施宇

11

parent 6da4b563
......@@ -13,7 +13,7 @@
<text class="upload-text">上传图片</text>
</view>
<view class="hasImg" wx:else>
<cover-image src="{{imgUrl}}"></cover-image>
<image src="{{imgUrl}}" class="img"></image>
<text class="icon iconfont iconiconxiantiaoshouji7 deleteImg" bindtap="deleteImg"></text>
</view>
<view class="text">据说上传图片更容易被采纳报价</view>
......
......@@ -13,7 +13,7 @@
<text class="upload-text">上传图片</text>
</view>
<view class="hasImg" wx:else>
<cover-image src="{{imgUrl}}"></cover-image>
<image src="{{imgUrl}}" class="img"></image>
<text class="icon iconfont iconiconxiantiaoshouji7 deleteImg" bindtap="deleteImg"></text>
</view>
<view class="text">据说上传图片更容易让人报价</view>
......
......@@ -85,7 +85,7 @@ Page({
'userinfo[nickName]': self.data.userinfo.nickName
}, function (res) {
if (res.err_code === 0) {
if (res.errcode === 0) {
wx.setStorage({
key: "openid",
......
......@@ -132,22 +132,22 @@ Page({
mobile: this.data.formData.mobile,
code_type: 3
}, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
this.getCode();
this.setData({
disabled: true
});
} else if (res.err_code === 500) {
} else if (res.errcode === 500) {
//图形验证码不正确的时候
this.refreshVerification();
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......@@ -366,13 +366,13 @@ Page({
}
http.getData(apis.resetPassword, 'POST', params, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
this.setData({
type: 3
});
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......
......@@ -72,7 +72,7 @@ Page({
encryptedData: e.detail.encryptedData,
iv: e.detail.iv
}, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
//注入token
wx.setStorage({
key: "access_token",
......
......@@ -208,7 +208,7 @@ Page({
http.getData(apis.authlogin, 'POST', e.detail.value, function (res) {
if (res.err_code === 0) {
if (res.errcode === 0) {
//注入token
wx.setStorage({
......@@ -234,7 +234,7 @@ Page({
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......
......@@ -129,22 +129,22 @@ Page({
mobile: this.data.formData.mobile,
code_type: 1
}, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
this.getCode();
this.setData({
disabled: true
});
} else if (res.err_code === 500) {
} else if (res.errcode === 500) {
//图形验证码不正确的时候
this.refreshVerification();
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......@@ -349,7 +349,7 @@ Page({
});
http.getData(apis.authRegister, 'POST', e.detail.value, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
//注入token
wx.setStorage({
......@@ -366,17 +366,17 @@ Page({
url: '/pages/person/successfully/index'
});
} else if (res.err_code === 500) {
} else if (res.errcode === 500) {
//图形验证码不正确的时候
this.refreshVerification();
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......
......@@ -150,7 +150,7 @@ Page({
});
http.getData(apis.editPwd, 'POST', e.detail.value, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
wx.navigateBack({
delta: 2
});
......@@ -161,7 +161,7 @@ Page({
});
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......
......@@ -85,13 +85,13 @@ Page({
http.getData(apis.authLogout, 'POST', null, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
wx.switchTab({
url: '/pages/tab/home/home'
});
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......
......@@ -125,22 +125,22 @@ Page({
mobile: this.data.formData.mobile,
code_type: 2
}, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
this.getCode();
this.setData({
disabled: true
});
} else if (res.err_code === 500) {
} else if (res.errcode === 500) {
//图形验证码不正确的时候
this.refreshVerification();
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......@@ -296,7 +296,7 @@ Page({
});
http.getData(apis.authMobilelogin, 'POST', e.detail.value, (res) => {
if (res.err_code === 0) {
if (res.errcode === 0) {
//注入token
wx.setStorage({
......@@ -311,17 +311,17 @@ Page({
url: '/pages/tab/home/home'
})
} else if (res.err_code === 500) {
} else if (res.errcode === 500) {
//图形验证码不正确的时候
this.refreshVerification();
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
} else {
wx.showToast({
title: res.err_msg,
title: res.errmsg,
icon: 'none',
duration: 2000
});
......
......@@ -48,7 +48,7 @@ Page({
random: obj.randomStr,
signature: obj.singnatrueStr
}, function(res) {
if (res.err_code === 0) {
if (res.errcode === 0) {
if (res.data.length) {
me.setData({
rmList: res.data
......
......@@ -109,7 +109,7 @@ Page({
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
console.log(111)
},
/**
......
......@@ -2,5 +2,7 @@
"usingComponents": {
"priceItem": "/components/priceItem/priceItem"
},
"navigationBarTitleText": "商品管理"
"navigationBarTitleText": "商品管理",
"enablePullDownRefresh":true,
"backgroundTextStyle": "dark"
}
\ No newline at end of file
......@@ -2,14 +2,14 @@
.good-view {
min-height: 100%;
padding:180rpx 0 118rpx;
padding:0 0 118rpx;
box-sizing: border-box;
}
.good-view .search-com {
height: 86rpx;
box-sizing: border-box;
position: fixed;
/* position: fixed; */
top: 0;
left: 0;
right: 0;
......@@ -24,7 +24,7 @@
color: #adb6bf;
height: 94rpx;
box-sizing: border-box;
position: fixed;
/* position: fixed; */
top: 86rpx;
left: 0;
right: 0;
......
.form-view {
}
.form-item {
margin-left: 24rpx;
padding: 27rpx 0;
......@@ -61,6 +60,7 @@ textarea {
.hf-btn {
margin: 60rpx 55rpx;
}
.hf-btn .icon {
margin-right: 8rpx;
font-size: 32rpx;
......@@ -94,29 +94,32 @@ textarea {
width: 220rpx;
position: relative;
}
.hasImg img{
height:100%;
width:100%;
}
.deleteImg{
font-size:30rpx !important;
color:#fff;
position: absolute;
top:0;
right:0;
transform: translate(30%,-30%);
background-color: #EA1717;
height:44rpx;
width:44rpx;
text-align: center;
line-height: 44rpx;
border-radius: 50%;
}
.delete-btn{
margin-bottom:60rpx;
border:2rpx solid #D8DFE6;
.hasImg .img {
height: 100%;
width: 100%;
}
.deleteImg {
font-size: 30rpx !important;
color: #fff;
position: absolute;
top: 0;
right: 0;
transform: translate(30%, -30%);
background-color: #ea1717;
height: 44rpx;
width: 44rpx;
text-align: center;
line-height: 44rpx;
border-radius: 50%;
z-index: 2;
}
.delete-btn {
margin-bottom: 60rpx;
border: 2rpx solid #d8dfe6;
background-color: #fff;
color:#686E73;
color: #686e73;
box-sizing: border-box;
}
......@@ -2563,7 +2563,7 @@ var $pres = null;
* (Function) callback - Function that will fire on Http error
*
* Example:
* function onError(err_code){
* function onError(errcode){
* //do stuff
* }
*
......
// const auth_url = 'https://authapi.icsales.com';
// const so_url = 'https://soapi.icsales.com';
// const offer_url = "https://offerapi.icsales.com";
// const user_url = 'https://userapi.icsales.com';
// const goods_url = 'https://goodsapi.icsales.com';
// const home_url = 'https://home.icsales.com';
const auth_url = 'http://authapi.icsales.cc';
const so_url = 'http://soapi.icsales.cc';
const offer_url = "http://offerapi.icsales.cc";
const user_url = 'http://userapi.icsales.cc';
const goods_url = 'http://goodsapi.icsales.cc';
const home_url = 'http://home.icsales.cc';
const auth_url = 'https://authapi.icsales.com';
const so_url = 'https://soapi.icsales.com';
const offer_url = "https://offerapi.icsales.com";
const user_url = 'https://userapi.icsales.com';
const goods_url = 'https://goodsapi.icsales.com';
const home_url = 'https://home.icsales.com';
// const auth_url = 'http://authapi.icsales.cc';
// const so_url = 'http://soapi.icsales.cc';
// const offer_url = "http://offerapi.icsales.cc";
// const user_url = 'http://userapi.icsales.cc';
// const goods_url = 'http://goodsapi.icsales.cc';
// const home_url = 'http://home.icsales.cc';
const apis = {
/**
......
......@@ -40,7 +40,7 @@ const getImUser = () => {
getData(apis.authme, 'get', {
"token": token,
}, function(res) {
if (res.err_code == 0) {
if (res.errcode == 0) {
wx.setStorageSync('user_id', res.data.user_id + '');
wx.setStorageSync('avatar', res.data.avatar);
wx.setStorageSync('company_name', res.data.company_name);
......
......@@ -50,7 +50,7 @@ const getData = (url, type, param, callBack, loading, isheader, istoken) => {
}
//处理token失效的情况
if (res.data.hasOwnProperty('data')) {
if (res.data.err_code == 501 || res.data.errcode == 501) {
if (res.data.errcode == 501 || res.data.errcode == 501) {
wx.redirectTo({
url: '/pages/person/login/index'
});
......@@ -58,7 +58,7 @@ const getData = (url, type, param, callBack, loading, isheader, istoken) => {
typeof callBack == "function" && callBack(res.data, "");
}
} else {
if (res.data.err_code == 501 || res.data.errcode == 501) {
if (res.data.errcode == 501 || res.data.errcode == 501) {
wx.redirectTo({
url: '/pages/person/login/index'
});
......@@ -100,7 +100,6 @@ const uploadFile = (url, path, callBack) => {
source: 2
},
success: (res) => {
console.log(res)
var data = JSON.parse(res.data);
if (data.errcode == 103200) {
callBack(data.data[0])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment