提交 2bf5ad89 authored 作者: 曾美红's avatar 曾美红

授权码

上级 e89b848e
......@@ -10,7 +10,7 @@
</picker> -->
<view class='item-avatar-xs'>
<text><text class="required">*</text>会议名称:</text>
<input type='text' placeholder='请输入会议名称' name="messageName" />
<input type='text' value="{{message.messageName}}" placeholder='请输入会议名称' name="messageName" />
</view>
<view class='item-avatar-xs'>
<text><text class="required">*</text>发起人:</text>
......@@ -29,7 +29,7 @@
</view>
<view class='item-avatar-xs'>
<text>会议信息:</text>
<textarea placeholder='输入内容' name="messageContent"></textarea>
<textarea placeholder='输入内容' value="{{message.messageContent}}" name="messageContent"></textarea>
</view>
<view class="graySpace"></view>
<view class='add_bg'>
......
......@@ -37,7 +37,8 @@ Page({
min:0,
},
username:""
username:"",
message:{}
},
//方式选项点击
clicks: function(e) {
......@@ -601,32 +602,21 @@ console.log(e.currentTarget.dataset.hour);
},
onLoad: function(query) {
//showView: (options.showView == "true" ? true : false);
//生成会议id
var _this = this;
// console.log("会议id",_this.data.mid);
if (_this.data.mid==null){
dd.httpRequest({
url: generateMidUrl,
method: 'POST',
dataType: 'json',
success: function(res) {
var mid = res.data.result;
console.log('mid----', res)
_this.setData({
mid: mid
var _this = this;
//再次预定 数据回显
var message= _this.data.message;
message['cnum'] =query.cnum;
message['messageName'] =query.messageName;
message['messageCompere'] =query.messageCompere;
message['messageContent'] =query.messageContent;
_this.setData({
message
})
},
fail: function(res) {
console.log("httpRequestFail---", res)
dd.alert({ content: JSON.stringify(res) });
},
complete: function(res) {
dd.hideLoading();
}
});
}
//生成会议id
// console.log("会议id",_this.data.mid);
//查询当天会议时间段
var timeList = this.data.timeList;
var hours = this.data.allTime.hours;
......@@ -809,7 +799,29 @@ console.log(e.currentTarget.dataset.hour);
onReady() {
// 页面加载完成
if (_this.data.mid==null){
dd.httpRequest({
url: generateMidUrl,
method: 'POST',
dataType: 'json',
success: function(res) {
var mid = res.data.result;
console.log('mid----', res)
_this.setData({
mid: mid
})
},
fail: function(res) {
console.log("httpRequestFail---", res)
dd.alert({ content: JSON.stringify(res) });
},
complete: function(res) {
dd.hideLoading();
}
});
}
// console.log(this.data.timeList);
},
......
......@@ -14,21 +14,20 @@
</view>
<view class='list_content'>
<view a:for="{{conferenceList}}" a:for-index="index" a:for-item="conference">
<navigator class='list_b' url="../details/details?cnum={{conference.conferenceNumber}}" open-type="navigate">
<view class='list_b' onTap="goDetail" data-cnum="{{conference.conferenceNumber}}" data-reserveCode="{{conference.reserveCode}}" >
<image src="{{imageUrl}}{{conference.photoUrl}}" onError="setImageUrl" data-index="{{index}}" id="images-{{index}}"></image>
<view class='list_title2'>
<text>{{conference.area.areaName}} </text>
<text>{{conference.conferenceName}}</text>
</view>
<text class="function_text"> 功能: <block a:for="{{conference.functions}}" a:for-item="fun">{{fun.functionName}},</block>
</text>
</text>
<button class='list_btn1'><view a:if="{{conference.enable == 1}}">可用</view><view a:elif="{{conference.enable == 0}}">不可用</view></button>
<button class='list_btn2'>{{conference.maxPerson}}人</button>
</view>
</navigator>
</view>
</view>
</view>
</view>
......@@ -28,10 +28,24 @@ Page({
},
goDetail:function(e){
// var cnum=e.currentTarget.dataset.cnum;
var cnum=e.currentTarget.dataset.cnum;
dd.navigateTo({
url:'../details/details?cnum='+cnum
});
let reserveCode = e.currentTarget.dataset.reserveCode;
console.log("reserveCode" ,reserveCode);
if(reserveCode != "" && reserveCode!=null ){
dd.navigateTo({
url:'../details/details?cnum='+cnum
})
}else{
dd.alert({
content: '该会议室没有授权码',
buttonText: '我知道了',
})
}
// dd.navigateTo({
// url:'../details/details?cnum='+cnum
// });
},
onLoad(query) {
// 页面加载
......@@ -61,6 +75,7 @@ Page({
data: {
authCode: res.authCode,
corpId: app.globalData.corpId,
reserveCode: res.reserveCode,
},
dataType: 'json',
success: function(res) {
......@@ -108,6 +123,16 @@ Page({
_this.setData({
conferenceList: res.data.result
})
// if(reserveCode !== ""){
// dd.navigateTo({
// url:'../details/details?cnum='+cnum
// })
// }else{
// dd.alert({
// content: '该会议室没有授权码',
// buttonText: '我知道了',
// })
// }
},
fail: function(res) {
console.log("httpRequestFail---", res)
......@@ -144,6 +169,7 @@ Page({
});
},
fail: (err) => {
dd.alert({
content: JSON.stringify(err)
......@@ -151,10 +177,9 @@ Page({
}
});
},
onReady() {
// 页面加载完成
},
......
......@@ -51,11 +51,11 @@
border: 1px solid #eee;
}
.ver{
width: 46%;
width: 68%;
height: 60rpx;
line-height: 60rpx;
position: absolute;
margin-top: 20rpx;
position: relative;
top: -10rpx;
}
.btn{
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论