Commit 11a11554 by 施宇

111

parent ecc7aa04
...@@ -19,11 +19,29 @@ App({ ...@@ -19,11 +19,29 @@ App({
customerName: "IC助手客服", customerName: "IC助手客服",
isRelogin: true, //登入环信失败后是否重新登入,只允许重新登入一次 isRelogin: true, //登入环信失败后是否重新登入,只允许重新登入一次
bus: bus, bus: bus,
imBoolean:false, imBoolean: false,
},
setNav: function () {//设置导航
let menuButtonObject = wx.getMenuButtonBoundingClientRect();
wx.getSystemInfo({
success: res => {
//导航高度
let statusBarHeight = res.statusBarHeight,
navTop = menuButtonObject.top,
navHeight = statusBarHeight + menuButtonObject.height + (menuButtonObject.top - statusBarHeight) * 2;
this.globalData.navHeight = navHeight;
this.globalData.navTop = navTop;
this.globalData.windowHeight = res.windowHeight;
},
fail(err) {
console.log(err);
}
})
}, },
getImUser: chat.getImUser, getImUser: chat.getImUser,
conn: chat.conn, conn: chat.conn,
addChatMember: function(id, userId) { //id为环信id userId为账户id addChatMember: function (id, userId) { //id为环信id userId为账户id
let token = wx.getStorageSync('access_token') || ''; let token = wx.getStorageSync('access_token') || '';
this.addChatMemberStorage(id); this.addChatMemberStorage(id);
...@@ -31,7 +49,7 @@ App({ ...@@ -31,7 +49,7 @@ App({
getData(apis.addrecord, 'GET', { getData(apis.addrecord, 'GET', {
"token": token, "token": token,
"user_id": userId "user_id": userId
}, function(res) { }, function (res) {
if (res.errcode === 0) { if (res.errcode === 0) {
} else { } else {
...@@ -39,7 +57,7 @@ App({ ...@@ -39,7 +57,7 @@ App({
} }
}, false); }, false);
}, },
addChatMemberStorage: function(id) { addChatMemberStorage: function (id) {
let member = wx.getStorageSync("member") || []; let member = wx.getStorageSync("member") || [];
member.push(id); member.push(id);
wx.setStorageSync("member", member) wx.setStorageSync("member", member)
...@@ -47,6 +65,7 @@ App({ ...@@ -47,6 +65,7 @@ App({
onLaunch() { onLaunch() {
wx.removeStorageSync('im'); wx.removeStorageSync('im');
this.versionUpdate(); this.versionUpdate();
this.setNav();
//验证是否授权 //验证是否授权
if (this.globalData.auth) { if (this.globalData.auth) {
//是否登录 //是否登录
...@@ -60,7 +79,7 @@ App({ ...@@ -60,7 +79,7 @@ App({
}); });
} }
} else { } else {
if (!judgeToken()){ if (!judgeToken()) {
wx.reLaunch({ wx.reLaunch({
url: '/pages/person/auth/index' url: '/pages/person/auth/index'
}); });
...@@ -75,23 +94,23 @@ App({ ...@@ -75,23 +94,23 @@ App({
chat.webimListen(); chat.webimListen();
this.checkIsIPhoneX(); this.checkIsIPhoneX();
}, },
versionUpdate: function() {//小程序检测版本更新 versionUpdate: function () { //小程序检测版本更新
if (wx.canIUse('getUpdateManager')) { if (wx.canIUse('getUpdateManager')) {
const updateManager = wx.getUpdateManager() const updateManager = wx.getUpdateManager()
updateManager.onCheckForUpdate(function(res) { updateManager.onCheckForUpdate(function (res) {
if (res.hasUpdate) { if (res.hasUpdate) {
updateManager.onUpdateReady(function() { updateManager.onUpdateReady(function () {
wx.showModal({ wx.showModal({
title: '更新提示', title: '更新提示',
content: '新版本已经准备好,是否重启应用?', content: '新版本已经准备好,是否重启应用?',
success: function(res) { success: function (res) {
if (res.confirm) { if (res.confirm) {
updateManager.applyUpdate() updateManager.applyUpdate()
} }
} }
}) })
}) })
updateManager.onUpdateFailed(function() { updateManager.onUpdateFailed(function () {
wx.showModal({ wx.showModal({
title: '已经有新版本了哟~', title: '已经有新版本了哟~',
content: '新版本已经上线啦~,请您删除当前小程序,重新搜索打开哟~' content: '新版本已经上线啦~,请您删除当前小程序,重新搜索打开哟~'
...@@ -106,10 +125,10 @@ App({ ...@@ -106,10 +125,10 @@ App({
}) })
} }
}, },
checkIsIPhoneX: function() { checkIsIPhoneX: function () {
const me = this const me = this
wx.getSystemInfo({ wx.getSystemInfo({
success: function(res) { success: function (res) {
// 根据 model 进行判断 // 根据 model 进行判断
if (res.model.search('iPhone X') != -1) { if (res.model.search('iPhone X') != -1) {
me.globalData.isIPX = true me.globalData.isIPX = true
......
...@@ -59,7 +59,6 @@ ...@@ -59,7 +59,6 @@
"window": { "window": {
"backgroundTextStyle": "light", "backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#fff", "navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "WeChat",
"navigationBarTextStyle": "black" "navigationBarTextStyle": "black"
}, },
"tabBar": { "tabBar": {
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<block> <block>
<!-- 询报价展示 --> <!-- 询报价展示 -->
<block wx:if="{{priceType==1}}"> <block wx:if="{{priceType==1}}">
<view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" bindtap="emitevent" data-inquiryitemsid="{{item['inquiry_items_id']}}" data-offerid="{{item['offer_id']}} " data-type="{{xb}}" data-pricetype="1" data-isclick="{{isClick}}"> <view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" catchtap="emitevent" data-inquiryitemsid="{{item['inquiry_items_id']}}" data-offerid="{{item['offer_id']}} " data-type="{{xb}}" data-pricetype="1" data-isclick="{{isClick}}">
<view class="item-header px-hr-bottom row verCenter bothSide nowrap"> <view class="item-header px-hr-bottom row verCenter bothSide nowrap">
<view class="row verCenter"> <view class="row verCenter">
<text class="mark xun" wx:if="{{xb==1}}">询</text> <text class="mark xun" wx:if="{{xb==1}}">询</text>
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
</block> </block>
<!-- 搜索页的商品展示 --> <!-- 搜索页的商品展示 -->
<block wx:if="{{priceType==2}}"> <block wx:if="{{priceType==2}}">
<view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" bindtap="emitevent" data-goodid="{{item.goods_id}}" data-pricetype="2"> <view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" catchtap="emitevent" data-goodid="{{item.goods_id}}" data-pricetype="2">
<view class="item-header px-hr-bottom row verCenter bothSide nowrap "> <view class="item-header px-hr-bottom row verCenter bothSide nowrap ">
<view class="row verCenter"> <view class="row verCenter">
<text class="mark bao"> <text class="mark bao">
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
</block> </block>
<!-- 搜索页面询报价展示 --> <!-- 搜索页面询报价展示 -->
<block wx:if="{{priceType==3}}"> <block wx:if="{{priceType==3}}">
<view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" bindtap="emitevent" data-inquiryitemsid="{{item['inquiry_items_id']}}" data-offerid="{{item['offer_id']}} " data-type="{{xb}}" data-pricetype="3" data-isclick="{{isClick}}"> <view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" catchtap="emitevent" data-inquiryitemsid="{{item['inquiry_items_id']}}" data-offerid="{{item['offer_id']}} " data-type="{{xb}}" data-pricetype="3" data-isclick="{{isClick}}">
<view class="item-header px-hr-bottom row verCenter bothSide nowrap"> <view class="item-header px-hr-bottom row verCenter bothSide nowrap">
<view class="row verCenter"> <view class="row verCenter">
<text class="mark xun" wx:if="{{xb==1}}">询价</text> <text class="mark xun" wx:if="{{xb==1}}">询价</text>
...@@ -91,7 +91,10 @@ ...@@ -91,7 +91,10 @@
<text class="num-bj" wx:if="{{item.offer_num}}">{{item.offer_num}}个报价</text> <text class="num-bj" wx:if="{{item.offer_num}}">{{item.offer_num}}个报价</text>
<text class="no-bj" wx:else>等待报价</text> <text class="no-bj" wx:else>等待报价</text>
</block> </block>
<text class="price" wx:else>¥{{item.price}}</text> <text class="price" wx:else>
<block wx:if="{{item.currency == 1}}">¥{{item.price}}</block>
<block wx:else>${{item.price}}</block>
</text>
</view> </view>
<view class="item-middle row verCenter nowrap"> <view class="item-middle row verCenter nowrap">
<text class="brand ellipsis"><text>品牌:</text>{{item.brand_name}}</text> <text class="brand ellipsis"><text>品牌:</text>{{item.brand_name}}</text>
...@@ -104,7 +107,7 @@ ...@@ -104,7 +107,7 @@
</block> </block>
<!-- 我的报价展示 --> <!-- 我的报价展示 -->
<block wx:if="{{priceType==4}}"> <block wx:if="{{priceType==4}}">
<view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" bindtap="emitevent"> <view class="price-item" wx:for="{{priceList}}" wx:key="{{index}}" catchtap="emitevent">
<view class="item-header px-hr-bottom row verCenter bothSide nowrap"> <view class="item-header px-hr-bottom row verCenter bothSide nowrap">
<view class="row verCenter"> <view class="row verCenter">
<text class="mark bao">报价</text> <text class="mark bao">报价</text>
...@@ -143,7 +146,7 @@ ...@@ -143,7 +146,7 @@
</block> </block>
<!-- 商品管理 --> <!-- 商品管理 -->
<block wx:if="{{priceType == 5}}"> <block wx:if="{{priceType == 5}}">
<view class="price-item good-item" wx:for="{{priceList}}" wx:key="{{index}}" bindtap="emitevent" data-goodid="{{item.goods_id}}" data-pricetype="5"> <view class="price-item good-item" wx:for="{{priceList}}" wx:key="{{index}}" catchtap="emitevent" data-goodid="{{item.goods_id}}" data-pricetype="5">
<view class="item-header row verCenter bothSide nowrap good-header"> <view class="item-header row verCenter bothSide nowrap good-header">
<view class="row verCenter"> <view class="row verCenter">
<text class="name ellipsis good-name">{{item.goods_name}}</text> <text class="name ellipsis good-name">{{item.goods_name}}</text>
......
// components/tohome/index.js
Component({
/**
* 组件的属性列表
*/
properties: {
homeShow: { //是否展示该home图标
type: Boolean
},
},
/**
* 组件的初始数据
*/
data: {
},
/**
* 组件的方法列表
*/
methods: {
tohome: function() {
wx.switchTab({
url: '/pages/tab/home/home'
});
}
}
})
\ No newline at end of file
{
"component": true,
"usingComponents": {}
}
\ No newline at end of file
<!--components/tohome/index.wxml-->
<view class="to-home-view" wx:if="{{homeShow}}" >
<image src="../../res/images/icons/tohome.png" catchtap="tohome"></image>
</view>
\ No newline at end of file
/* components/tohome/index.wxss */
.to-home-view{
position: fixed;
bottom:103rpx;
right:24rpx;
height:80rpx;
width:80rpx;
background-color: #000;
opacity: .2;
border-radius: 50% 50%;
z-index: 99;
}
.to-home-view image{
height:50rpx;
width:50rpx;
margin:15rpx 0 0 15rpx;
}
\ No newline at end of file
...@@ -17,7 +17,8 @@ Page({ ...@@ -17,7 +17,8 @@ Page({
info: null, info: null,
editOrShow: -1, //1编辑 2在线沟通 editOrShow: -1, //1编辑 2在线沟通
goodId: "", goodId: "",
type: "" type: "",//1 自己 2 别人 3 分享
homeShow: false,
}, },
/** /**
...@@ -27,7 +28,9 @@ Page({ ...@@ -27,7 +28,9 @@ Page({
let me = this; let me = this;
this.setData({ this.setData({
goodId: options.goodId || '', goodId: options.goodId || '',
type: options.type || '' type: options.type || '',
homeShow: options.type == 3 ? true : false
}); });
this.getData(false,true) this.getData(false,true)
getApp().globalData.bus.off('editGood'); getApp().globalData.bus.off('editGood');
......
{ {
"usingComponents": {}, "usingComponents": {
"tohome": "/components/tohome/index"
},
"navigationBarBackgroundColor": "#0D84D1", "navigationBarBackgroundColor": "#0D84D1",
"navigationBarTextStyle": "white", "navigationBarTextStyle": "white",
"backgroundColor": "#0d84d1", "backgroundColor": "#0d84d1",
......
<!--pages/detail/good/index.wxml--> <!--pages/detail/good/index.wxml-->
<wxs module="dateUtil" src="../../../utils/timeUtil.wxs"></wxs> <wxs module="dateUtil" src="../../../utils/timeUtil.wxs"></wxs>
<tohome home-show="{{homeShow}}"></tohome>
<view class="detail-view"> <view class="detail-view">
<view class="t-desc"> <view class="t-desc">
<view class="t-desc-content" wx:if="{{info}}"> <view class="t-desc-content" wx:if="{{info}}">
......
...@@ -19,7 +19,10 @@ Page({ ...@@ -19,7 +19,10 @@ Page({
currency: 0, currency: 0,
isClick: true, isClick: true,
isShowTip: true, isShowTip: true,
array: ['RMB', 'USD'] array: ['RMB', 'USD'],
obj:{},
hq:"1",
day:""
}, },
bindPickerChange: function (e) { bindPickerChange: function (e) {
this.setData({ this.setData({
...@@ -54,13 +57,11 @@ Page({ ...@@ -54,13 +57,11 @@ Page({
if (!obj.day.trim().length) { if (!obj.day.trim().length) {
tips('请填写货期'); tips('请填写货期');
return return
} else if (isNaN(Number(obj.day.trim()))) { }
tips('货期必须为数字'); // else if (obj.day.trim().length > 3) {
return // tips('货期不能大于3个字符');
} else if (obj.day.trim().length > 3) { // return
tips('货期不能大于3个字符'); // }
return
}
} }
} }
this.postData(obj); this.postData(obj);
...@@ -120,12 +121,27 @@ Page({ ...@@ -120,12 +121,27 @@ Page({
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
*/ */
onLoad: function (options) { onLoad: function (options) {
console.log(options)
this.setData({ this.setData({
inquiryItemsId: options.inquiryItemsId || "", inquiryItemsId: options.inquiryItemsId || "",
offerId: options.offerId || "", offerId: options.offerId || "",
type: options.type || "" type: options.type || "",
}) obj:JSON.parse(options.obj||'{}')
});
console.log(this.data.obj)
let delivery_time = this.data.obj.delivery_time;
if (this.data.obj.currency=='2'){
this.setData({
currency: 1
})
}
if (delivery_time != '现货') {
let day = delivery_time.replace('天', '');
this.setData({
hq: "2",
isShowTime:true,
day: day
})
}
}, },
/** /**
......
...@@ -11,35 +11,35 @@ ...@@ -11,35 +11,35 @@
<view class="form-item row verCenter"> <view class="form-item row verCenter">
<text class="form-item-title">*型号</text> <text class="form-item-title">*型号</text>
<view class="form-item-right"> <view class="form-item-right">
<input placeholder="请输入产品型号(必填)" placeholder-class="placeholderClass" type="text" name="goods_name"></input> <input placeholder="请输入产品型号(必填)" placeholder-class="placeholderClass" type="text" name="goods_name" value="{{obj.goods_name}}"></input>
</view> </view>
</view> </view>
<view class="form-item row verCenter px-hr-top"> <view class="form-item row verCenter px-hr-top">
<text class="form-item-title">*品牌</text> <text class="form-item-title">*品牌</text>
<view class="form-item-right"> <view class="form-item-right">
<input placeholder="请输入品牌(必填)" placeholder-class="placeholderClass" type="text" name="brand_name"></input> <input placeholder="请输入品牌(必填)" placeholder-class="placeholderClass" type="text" name="brand_name" value="{{obj.brand_name}}"></input>
</view> </view>
</view> </view>
<view class="form-item row verCenter px-hr-top"> <view class="form-item row verCenter px-hr-top">
<text class="form-item-title"> 封装</text> <text class="form-item-title"> 封装</text>
<view class="form-item-right"> <view class="form-item-right">
<input placeholder="请输入封装" placeholder-class="placeholderClass" type="text" name="encap"></input> <input placeholder="请输入封装" placeholder-class="placeholderClass" type="text" name="encap" value="{{obj.encap}}"></input>
</view> </view>
</view> </view>
<view class="form-item row verCenter px-hr-top"> <view class="form-item row verCenter px-hr-top">
<text class="form-item-title">*数量</text> <text class="form-item-title">*数量</text>
<view class="form-item-right"> <view class="form-item-right">
<input placeholder="请输入数量(必填)" placeholder-class="placeholderClass" type="number" name="number"></input> <input placeholder="请输入数量(必填)" placeholder-class="placeholderClass" type="number" name="number" value="{{obj.number}}"></input>
</view> </view>
</view> </view>
<view class="form-item row verCenter px-hr-top bj-item"> <view class="form-item row verCenter px-hr-top bj-item">
<text class="form-item-title">*报价</text> <text class="form-item-title">*报价</text>
<view class="form-item-right row verCenter bothSide"> <view class="form-item-right row verCenter bothSide">
<input placeholder="请输入单价" placeholder-class="placeholderClass" type="digit" name="price"></input> <input placeholder="请输入单价" placeholder-class="placeholderClass" type="digit" name="price" value="{{obj.price}}"></input>
<picker class="price-type" value="{{currency}}" range="{{array}}" bindchange="bindPickerChange"> <picker class="price-type" value="{{currency}}" range="{{array}}" bindchange="bindPickerChange">
<text class="price-value">{{array[currency]}}</text> <text class="price-value">{{array[currency]}}</text>
<text class="icon iconfont iconbianzu1"></text> <text class="icon iconfont iconbianzu1"></text>
</picker> </picker>
</view> </view>
</view> </view>
<view class="form-item row verCenter px-hr-top qx-item"> <view class="form-item row verCenter px-hr-top qx-item">
...@@ -47,10 +47,10 @@ ...@@ -47,10 +47,10 @@
<view class="form-item-right"> <view class="form-item-right">
<radio-group name="hq" bindchange="radioChange"> <radio-group name="hq" bindchange="radioChange">
<label> <label>
<radio value="1" checked/>现货 <radio value="1" checked="{{hq==1}}" />现货
</label> </label>
<label> <label>
<radio value="2" />期货 <radio value="2" checked="{{hq==2}}" />期货
</label> </label>
</radio-group> </radio-group>
</view> </view>
...@@ -58,14 +58,14 @@ ...@@ -58,14 +58,14 @@
<view class="form-item row verCenter px-hr-top" hidden="{{!isShowTime}}"> <view class="form-item row verCenter px-hr-top" hidden="{{!isShowTime}}">
<text class="form-item-title">*时间</text> <text class="form-item-title">*时间</text>
<view class="form-item-right"> <view class="form-item-right">
<input placeholder="请输入货期时间(天)" placeholder-class="placeholderClass" type="number" name="day"></input> <input placeholder="请输入货期时间(天)" placeholder-class="placeholderClass" type="number" name="day" value="{{day}}"></input>
</view> </view>
</view> </view>
<view class="form-hr"></view> <view class="form-hr"></view>
<view class="form-item row px-hr-bottom"> <view class="form-item row px-hr-bottom">
<text class="form-item-title">备注</text> <text class="form-item-title">备注</text>
<view class="form-item-right"> <view class="form-item-right">
<textarea placeholder="请输入备注" placeholder-class="placeholderClass" maxlength="-1" name="remark"/> <textarea placeholder="请输入备注" placeholder-class="placeholderClass" maxlength="-1" name="remark" value="{{obj.remark}}" />
</view> </view>
</view> </view>
<button class="btn-com btn-com-b hf-btn" form-type="submit">回复报价</button> <button class="btn-com btn-com-b hf-btn" form-type="submit">回复报价</button>
......
...@@ -84,7 +84,6 @@ Page({ ...@@ -84,7 +84,6 @@ Page({
}); });
if (infoObj.delivery_time !== '现货') { if (infoObj.delivery_time !== '现货') {
let day = infoObj.delivery_time.replace('天', ''); let day = infoObj.delivery_time.replace('天', '');
console.log(day)
this.setData({ this.setData({
isShowTime: 2, isShowTime: 2,
hq: 2, hq: 2,
...@@ -121,13 +120,14 @@ Page({ ...@@ -121,13 +120,14 @@ Page({
if (!obj.day.trim().length) { if (!obj.day.trim().length) {
tips('请填写货期'); tips('请填写货期');
return return
} else if (isNaN(Number(obj.day.trim()))) { }
tips('货期必须为数字'); // else if (isNaN(Number(obj.day.trim()))) {
return // tips('货期必须为数字');
} else if (obj.day.trim().length > 3) { // return
tips('货期不能大于3个字符'); // } else if (obj.day.trim().length > 3) {
return // tips('货期不能大于3个字符');
} // return
// }
} }
} }
this.postData(obj); this.postData(obj);
......
...@@ -23,6 +23,7 @@ Page({ ...@@ -23,6 +23,7 @@ Page({
offerId: "", offerId: "",
// isShowImg: false, // isShowImg: false,
isShareType: 0, //分享后点进来的页面 1代表自己的询价 2代表别人的询价 isShareType: 0, //分享后点进来的页面 1代表自己的询价 2代表别人的询价
homeShow:false,
}, },
/** /**
...@@ -33,7 +34,8 @@ Page({ ...@@ -33,7 +34,8 @@ Page({
this.setData({ this.setData({
inquiryItemsId: options.inquiryItemsId || '', inquiryItemsId: options.inquiryItemsId || '',
type: options.type || '', type: options.type || '',
offerId: options.offerId || '' offerId: options.offerId || '',
homeShow: options.type == 3 ? true:false
}); });
this.getTopInfo(); this.getTopInfo();
if (this.data.type == 1) { if (this.data.type == 1) {
...@@ -202,7 +204,7 @@ Page({ ...@@ -202,7 +204,7 @@ Page({
onPullDownRefresh: function() { onPullDownRefresh: function() {
}, },
companyHome: function () {//跳转到公司首页 companyHome: function() { //跳转到公司首页
let userId = wx.getStorageSync("user_id"); let userId = wx.getStorageSync("user_id");
if (this.data.topInfo.user_id == userId) { if (this.data.topInfo.user_id == userId) {
wx.navigateTo({ wx.navigateTo({
...@@ -219,8 +221,8 @@ Page({ ...@@ -219,8 +221,8 @@ Page({
* 页面上拉触底事件的处理函数 * 页面上拉触底事件的处理函数
*/ */
onReachBottom: function() { onReachBottom: function() {
if (this.data.type == 2 || this.data.isShareType==2){ if (this.data.type == 2 || this.data.isShareType == 2) {
return return
} }
let allPage = Math.ceil(this.data.total / this.data.limit); let allPage = Math.ceil(this.data.total / this.data.limit);
let p = this.data.p; let p = this.data.p;
...@@ -257,14 +259,27 @@ Page({ ...@@ -257,14 +259,27 @@ Page({
duration: 2000 duration: 2000
}); });
} else { } else {
if (this.data.total == 0) { if (this.data.total == 0) { //新增报价
let info = this.data.topInfo
let obj = {
brand_name: info.brand_name,
currency: info.currency,
delivery_time: info.delivery_time,
encap: info.encap,
goods_name: info.goods_name,
number: info.number,
price: info.price,
remark: info.remark
}
wx.navigateTo({ wx.navigateTo({
url: "/pages/form/bj/index?type=1&inquiryItemsId=" + this.data.inquiryItemsId, url: "/pages/form/bj/index?type=1&inquiryItemsId=" + this.data.inquiryItemsId + '&obj=' + JSON.stringify(obj),
}) })
} else { } else { //继续报价
let offerId = this.data.priceList[0].offer_id || '' let length = this.data.priceList.length;
let offerId = this.data.priceList[0].offer_id || '';
let obj = this.data.priceList[length - 1];
wx.navigateTo({ wx.navigateTo({
url: "/pages/form/bj/index?type=2&offerId=" + offerId, url: "/pages/form/bj/index?type=2&offerId=" + offerId + '&obj=' + JSON.stringify(obj),
}) })
} }
......
{ {
"usingComponents": { "usingComponents": {
"priceItem": "/components/priceItem/priceItem" "priceItem": "/components/priceItem/priceItem",
"tohome": "/components/tohome/index"
}, },
"navigationBarBackgroundColor": "#0D84D1", "navigationBarBackgroundColor": "#0D84D1",
"navigationBarTextStyle": "white", "navigationBarTextStyle": "white",
......
<!--pages/list/xj/index.wxml--> <!--pages/list/xj/index.wxml-->
<wxs module="dateUtil" src="../../../utils/timeUtil.wxs"></wxs> <wxs module="dateUtil" src="../../../utils/timeUtil.wxs"></wxs>
<tohome home-show="{{homeShow}}"></tohome>
<template name="info"> <template name="info">
<view class="xb-com-content"> <view class="xb-com-content">
<view class="x-info"> <view class="x-info">
...@@ -31,7 +32,8 @@ ...@@ -31,7 +32,8 @@
<text class="c-com {{(!topInfo.price||topInfo.price=='0.00'||topInfo.price=='0')?'':'bold red'}}"> <text class="c-com {{(!topInfo.price||topInfo.price=='0.00'||topInfo.price=='0')?'':'bold red'}}">
<block wx:if="{{!topInfo.price||topInfo.price=='0.00'||topInfo.price=='0'}}">无</block> <block wx:if="{{!topInfo.price||topInfo.price=='0.00'||topInfo.price=='0'}}">无</block>
<block wx:else> <block wx:else>
<block wx:if="{{topInfo.currency == 1}}">¥{{topInfo.price}}</block><block wx:else>${{topInfo.price}} <block wx:if="{{topInfo.currency == 1}}">¥{{topInfo.price}}</block>
<block wx:else>${{topInfo.price}}
</block> </block>
</block> </block>
</text> </text>
...@@ -55,10 +57,10 @@ ...@@ -55,10 +57,10 @@
<view class="bj-data"> <view class="bj-data">
<view class="xb-com-t row bothSide verCenter px-hr-bottom "> <view class="xb-com-t row bothSide verCenter px-hr-bottom ">
<text class="num bold beforeLine">收到的报价 <text>{{total}}</text></text> <text class="num bold beforeLine">收到的报价 <text>{{total}}</text></text>
<view class="jgpx"> <!-- <view class="jgpx">
<text class="icon iconfont iconiconxiantiaoshouji10"></text> <text class="icon iconfont iconiconxiantiaoshouji10"></text>
<text>价格排序</text> <text>价格排序</text>
</view> </view> -->
</view> </view>
<view class="bj-list"> <view class="bj-list">
<view wx:if="{{priceList&&priceList.length==0}}" class="nodata"> <view wx:if="{{priceList&&priceList.length==0}}" class="nodata">
...@@ -100,7 +102,7 @@ ...@@ -100,7 +102,7 @@
</view> </view>
</view> </view>
<view class="bj-btn-view" wx:if="{{priceList}}"> <view class="bj-btn-view" wx:if="{{priceList}}">
<view class="btn-com bj-btn {{total!=3?'btn-com-b':'btn-com-disable'}}" bindtap="go_bj"> <view class="btn-com bj-btn {{total!=3?'btn-com-b':'btn-com-disable'}}" bindtap="go_bj">
<block wx:if="{{total == 3}}"> <block wx:if="{{total == 3}}">
剩余0次 剩余0次
</block> </block>
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
</block> </block>
</view> </view>
<view class="txt"> <view class="txt">
<textarea name='com_desc' value="{{userInfo.com_desc}}" auto-height placeholder="请输入企业简介" class="tarea" placeholder-class="textarea-placeholder" /> <textarea name='com_desc' value="{{userInfo.com_desc}}" placeholder="请输入企业简介" class="tarea" placeholder-class="textarea-placeholder" />
</view> </view>
<view class="hr"></view> <view class="hr"></view>
<view class="list row verCenter bothSide bor"> <view class="list row verCenter bothSide bor">
......
// const auth_url = 'https://authapi.icsales.com'; const auth_url = 'https://authapi.icsales.com';
// const so_url = 'https://soapi.icsales.com'; const so_url = 'https://soapi.icsales.com';
// const offer_url = "https://offerapi.icsales.com"; const offer_url = "https://offerapi.icsales.com";
// const user_url = 'https://userapi.icsales.com'; const user_url = 'https://userapi.icsales.com';
// const goods_url = 'https://goodsapi.icsales.com'; const goods_url = 'https://goodsapi.icsales.com';
// const home_url = 'https://home.icsales.com'; const home_url = 'https://home.icsales.com';
// const welfare_url = 'https://welfareapi.icsales.com' const welfare_url = 'https://welfareapi.icsales.com'
const auth_url = 'http://authapi.icsales.cc'; // const auth_url = 'http://authapi.icsales.cc';
const so_url = 'http://soapi.icsales.cc'; // const so_url = 'http://soapi.icsales.cc';
const offer_url = "http://offerapi.icsales.cc"; // const offer_url = "http://offerapi.icsales.cc";
const user_url = 'http://userapi.icsales.cc'; // const user_url = 'http://userapi.icsales.cc';
const goods_url = 'http://goodsapi.icsales.cc'; // const goods_url = 'http://goodsapi.icsales.cc';
const home_url = 'http://home.icsales.cc'; // const home_url = 'http://home.icsales.cc';
const welfare_url = 'http://welfareapi.icsales.cc'; // const welfare_url = 'http://welfareapi.icsales.cc';
const apis = { const apis = {
......
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