This commit is contained in:
SelfRidicule 2024-03-01 15:07:02 +08:00
parent f94715fb79
commit 616c47b17a
7 changed files with 328 additions and 208 deletions

View File

@ -0,0 +1,11 @@
import {
request
} from '../selfRequest';
// 查询条件筛选
export function loginRq(param) {
return request({
url: '/api/roomContent/searchInfo/' + param,
method: "get",
});
}

View File

@ -1,6 +1,6 @@
import { import {
request request
} from '../../selfRequest'; } from '../selfRequest';
// 微信登录接口 // 微信登录接口
export function companyRq(data) { export function companyRq(data) {

View File

@ -5,7 +5,28 @@ Page({
* 页面的初始数据 * 页面的初始数据
*/ */
data: { data: {
IMG_NAME: app.IMG_NAME IMG_NAME: app.IMG_NAME,
queryParam: {
switchTitle1: '包邮',
switchTitle2: '团购',
itemTitle: '筛选',
meetingTypeDict: {
list: [{
text: '会议室类型',
value: 0
},
{
text: '会议室',
value: 1
},
{
text: '茶室',
value: 2
},
],
value: 0,
}
}
}, },
/** /**
@ -18,10 +39,20 @@ Page({
}) })
}, },
// 查询条件-会议类型
meetingTypeQueryChange(e){
console.log('meetingTypeQueryChange', e);
let queryParam = this.data.queryParam;
queryParam.meetingTypeDict.value = e.detail;
this.setData({
queryParam
})
},
// 会议室 // 会议室
jumpMeetingRoom(){ jumpMeetingRoom() {
wx.navigateTo({ wx.navigateTo({
url: "/pages/meeting/meetingRoom/meetingRoom", url: "/pages/meeting/meetingRoom/meetingRoom",
}) })
}, },

View File

@ -1,5 +1,9 @@
{ {
"usingComponents": { "usingComponents": {
"van-field": "@vant/weapp/field/index" "van-dropdown-menu": "@vant/weapp/dropdown-menu/index",
} "van-dropdown-item": "@vant/weapp/dropdown-item/index",
"van-cell": "@vant/weapp/cell/index",
"van-switch": "@vant/weapp/switch/index",
"van-button": "@vant/weapp/button/index"
}
} }

View File

@ -1,4 +1,12 @@
<view class="container"> <view class="containerView public">
<!-- 筛选条件 -->
<view class="queryView">
<van-dropdown-menu active-color="#4e96f8">
<van-dropdown-item value="{{ queryParam.meetingTypeDict.value }}" options="{{ queryParam.meetingTypeDict.list }}" bind:change="meetingTypeQueryChange"/>
</van-dropdown-menu>
</view>
<!-- 会议室列表 --> <!-- 会议室列表 -->
<view class="meetingRoomView"> <view class="meetingRoomView">
<view class="meetingRoomItem" bind:tap="jumpMeetingRoom" wx:for="{{6}}" wx:for-index="idx"> <view class="meetingRoomItem" bind:tap="jumpMeetingRoom" wx:for="{{6}}" wx:for-index="idx">

View File

@ -1,10 +1,15 @@
.container {
width: 100vw; .queryView{
height: 100vh; position: fixed;
background: #ffffff; left: 0;
top: 0;
z-index: 999;
width: 100%;
} }
.meetingRoomView { .meetingRoomView {
margin-top: 100rpx;
padding: 30rpx 30rpx; padding: 30rpx 30rpx;
} }

View File

@ -1,216 +1,277 @@
let app = getApp(); let app = getApp();
import { import {
companyRq companyRq
} from "../../../api/meeting/visitorIinvitation/visitorIinvitation.js" } from "../../../api/meeting/visitorIinvitation.js"
Page({ Page({
/** /**
* 页面的初始数据 * 页面的初始数据
*/ */
data: { data: {
IMG_NAME: app.IMG_NAME, IMG_NAME: app.IMG_NAME,
value: '', value: '',
companyShow:false, companyShow: false,
usernameShow:false, usernameShow: false,
cardTypeShow: false, cardTypeShow: false,
arriveShow:false, arriveShow: false,
leaveShow:false, leaveShow: false,
submitSuccesShow:false, submitSuccesShow: false,
companyColumns:['公司1','公司2','公司3'], companyColumns: ['公司1', '公司2', '公司3'],
columns: ['身份证', '护照', '通行证'], columns: ['身份证', '护照', '通行证'],
fileList: [], fileList: [],
currentDate: new Date().getTime(), currentDate: new Date().getTime(),
/** 索引栏*/ /** 索引栏*/
indexList: ["A", "B", "C", "D"], indexList: ["A", "B", "C", "D"],
scrollTop: 0, scrollTop: 0,
/** mock客户数据*/ /** mock客户数据*/
customerList: [ customerList: [{
{ firstLetter: "A",
firstLetter: "A", list: [{
list: [ code: "AB01",
{ code: "AB01", name: "A1客户" }, name: "A1客户"
{ code: "AB02", name: "A2客户" }, },
{ code: "AB03", name: "A3客户" }, {
], code: "AB02",
}, name: "A2客户"
{ },
firstLetter: "B", {
list: [ code: "AB03",
{ code: "BB01", name: "B1客户" }, name: "A3客户"
{ code: "BB02", name: "B2客户" }, },
{ code: "BB03", name: "B3客户" }, ],
{ code: "BB04", name: "B4客户" }, },
], {
}, firstLetter: "B",
{ list: [{
firstLetter: "C", code: "BB01",
list: [ name: "B1客户"
{ code: "CB01", name: "C1客户" }, },
{ code: "CB02", name: "C2客户" }, {
{ code: "CB03", name: "C3客户" }, code: "BB02",
{ code: "CB04", name: "C4客户" }, name: "B2客户"
{ code: "CB05", name: "C5客户" }, },
], {
}, code: "BB03",
{ name: "B3客户"
firstLetter: "D", },
list: [ {
{ code: "DB01", name: "D1客户" }, code: "BB04",
{ code: "DB02", name: "D2客户" }, name: "B4客户"
{ code: "DB03", name: "D3客户" }, },
{ code: "DB04", name: "D4客户" }, ],
{ code: "DB05", name: "D5客户" }, },
{ code: "DB06", name: "D6客户" }, {
], firstLetter: "C",
}, list: [{
], code: "CB01",
name: "C1客户"
}, },
{
code: "CB02",
name: "C2客户"
},
{
code: "CB03",
name: "C3客户"
},
{
code: "CB04",
name: "C4客户"
},
{
code: "CB05",
name: "C5客户"
},
],
},
{
firstLetter: "D",
list: [{
code: "DB01",
name: "D1客户"
},
{
code: "DB02",
name: "D2客户"
},
{
code: "DB03",
name: "D3客户"
},
{
code: "DB04",
name: "D4客户"
},
{
code: "DB05",
name: "D5客户"
},
{
code: "DB06",
name: "D6客户"
},
],
},
],
/** },
* 生命周期函数--监听页面加载
*/
onLoad(options) {
// 页面初始化 options为页面跳转所带来的参数
wx.setNavigationBarTitle({
title: options.name
})
console.log('options.goods_id',options.name)
companyRq({}).then( res =>{
console.log('res',res)
if(res.code ==0){
// res.row
}
}) /**
}, * 生命周期函数--监听页面加载
*/
onLoad(options) {
// 页面初始化 options为页面跳转所带来的参数
wx.setNavigationBarTitle({
title: options.name
})
console.log('options.goods_id', options.name)
companyRq({}).then(res => {
console.log('res', res)
if (res.code == 0) {
// res.row
}
/** })
* 生命周期函数--监听页面卸载 },
*/
onUnload() {
}, /**
* 生命周期函数--监听页面卸载
*/
onUnload() {
/** },
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
}, /**
onChange(event) { * 页面相关事件处理函数--监听用户下拉动作
// event.detail 为当前输入的值 */
console.log(event.detail); onPullDownRefresh() {
},
/** },
* 页面上拉触底事件的处理函数 onChange(event) {
*/ // event.detail 为当前输入的值
onReachBottom() { console.log(event.detail);
},
}, /**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
/** },
* 用户点击右上角分享
*/
onShareAppMessage() {
}, /**
getUsernameHandle(){ * 用户点击右上角分享
// this.setData({ */
// usernameShow: true onShareAppMessage() {
// });
wx.navigateTo({
url: '/pages/meeting/visitorIinvitation/indexBar/indexBar'
})
}, },
getCompanyHandle() { getUsernameHandle() {
this.setData({ // this.setData({
companyShow: true // usernameShow: true
}); // });
}, wx.navigateTo({
getCardTypeHandle() { url: '/pages/meeting/visitorIinvitation/indexBar/indexBar'
this.setData({ })
cardTypeShow: true
});
},
changeHandler(e){
console.log(e)
}, },
// confirmHandle(){ getCompanyHandle() {
this.setData({
companyShow: true
});
},
getCardTypeHandle() {
this.setData({
cardTypeShow: true
});
},
changeHandler(e) {
console.log(e)
// }, },
confirmHandle(){ // confirmHandle(){
this.setData({
companyShow:false,
usernameShow:false,
cardTypeShow: false,
arriveShow: false,
leaveShow:false
});
},
cancelHandle(){
this.setData({
companyShow:false,
usernameShow:false,
cardTypeShow: false,
arriveShow: false,
leaveShow:false
});
},
getArriveHandle(){
this.setData({
arriveShow: true
});
}, // },
getLeaveHandle(){ confirmHandle() {
this.setData({ this.setData({
leaveShow: true companyShow: false,
}); usernameShow: false,
}, cardTypeShow: false,
onClose(){ arriveShow: false,
this.setData({ leaveShow: false
usernameShow: true });
}); },
}, cancelHandle() {
afterRead(event) { this.setData({
const { file } = event.detail; companyShow: false,
// 当设置 mutiple 为 true 时, file 为数组格式,否则为对象格式 usernameShow: false,
wx.uploadFile({ cardTypeShow: false,
url: 'https://example.weixin.qq.com/upload', // 仅为示例,非真实的接口地址 arriveShow: false,
filePath: file.url, leaveShow: false
name: 'file', });
formData: { user: 'test' }, },
success(res) { getArriveHandle() {
// 上传完成需要更新 fileList this.setData({
const { fileList = [] } = this.data; arriveShow: true
fileList.push({ ...file, url: res.data }); });
this.setData({ fileList });
},
});
},
onInput(event) {
this.setData({
currentDate: event.detail,
});
},
submitFormFn(){
this.setData({
submitSuccesShow: true,
});
}, },
submitDialogFn(){ getLeaveHandle() {
this.setData({ this.setData({
submitSuccesShow: false, leaveShow: true
}); });
setTimeout(() => { },
wx.navigateTo({ onClose() {
url: '/pages/meeting/visitorIinvitation/appointmentRecord/appointmentRecord', this.setData({
}) usernameShow: true
}, 10); });
} },
afterRead(event) {
const {
file
} = event.detail;
// 当设置 mutiple 为 true 时, file 为数组格式,否则为对象格式
wx.uploadFile({
url: 'https://example.weixin.qq.com/upload', // 仅为示例,非真实的接口地址
filePath: file.url,
name: 'file',
formData: {
user: 'test'
},
success(res) {
// 上传完成需要更新 fileList
const {
fileList = []
} = this.data;
fileList.push({
...file,
url: res.data
});
this.setData({
fileList
});
},
});
},
onInput(event) {
this.setData({
currentDate: event.detail,
});
},
submitFormFn() {
this.setData({
submitSuccesShow: true,
});
},
submitDialogFn() {
this.setData({
submitSuccesShow: false,
});
setTimeout(() => {
wx.navigateTo({
url: '/pages/meeting/visitorIinvitation/appointmentRecord/appointmentRecord',
})
}, 10);
}
}) })