Commit cc5b26c7 by fengzhaoyu

钉盘

parent 98c23655
......@@ -177,4 +177,11 @@ export function getScheduleDetail (data) {
data: JSON.stringify(data),
url: `/meet/schedule/getScheduleDetail`
})
}
// 文件上传
export function uploadPermissions () {
return $http({
method: 'get',
url: `/admin/ddOpenApi/getCustomSpaceAndGrantCustomSpace?type=add&ddUserId=${getApp().globalData.userid}`
})
}
\ No newline at end of file
{
"pages": [
"pages/index/index",
"pages/scheduleDetail/scheduleDetail",
"pages/index/index",
"pages/attendingSituation/attendingSituation",
"pages/createOrEditSchedule/createOrEditSchedule",
"pages/place/place",
......
......@@ -154,4 +154,14 @@ page {
}
.buttonGroup text {
vertical-align: top;
}
.describe {
padding: 0 32rpx;
display: flex;
background: #fff;
margin-top: 16rpx;
}
.describe .text {
padding: 27rpx 0;
line-height: 44rpx;
}
\ No newline at end of file
<view class="scheduleDetail">
<view class="scheduleInfo">
<!-- 标题 -->
<view class="title">
<view class="icon icondidianmiaoshu iconfont">
</view>
......@@ -7,6 +8,7 @@
{{title}}
</view>
</view>
<!-- 地址 -->
<view class="place" a:if="{{!!location.locationName}}">
<view class="icon icondingwei iconfont">
</view>
......@@ -14,6 +16,7 @@
{{location.locationName}}
</view>
</view>
<!-- 时间 -->
<view class="time">
<view class="icon iconshijian iconfont">
</view>
......@@ -28,10 +31,11 @@
</view>
</view>
</view>
<!-- 参会人 -->
<view class="participants">
<view class="icon iconcanhuiren1 iconfont">
</view>
<view class="scroll">
<view class="scroll" v-if="{{!!userList.length}}">
<text class="imageGroup" a:for="{{userList}}" a:for-item="item">
<text>
<image a:if="{{!!item.participator.headUrl}}" mode="scaleToFill" src="{{item.participator.headUrl}}"/>
......@@ -40,24 +44,34 @@
</text>
</view>
<view class="right">
<text class="number">3人参与</text>
<text class="number">{{userList.length}}人参与</text>
<text class="iconyoujinru iconfont"></text>
</view>
</view>
<view class="remind">
<!-- 重复 -->
<view class="remind" a:if="{{aheadTimes.length}}">
<view class="icon iconshijian iconfont">
</view>
<view class="text">
提前15分钟提醒
提前<text a:for="{{aheadTimes}}" a:for-item="item">{{item}}分</text>钟提醒
</view>
</view>
<!-- 会议描述 -->
<view class="describe" a:if="describe">
<view class="icon iconhuiyimiaoshu iconfont">
</view>
<view class="text">
本次会议重要议程是确定交互最终方案。
</view>
</view>
<!-- 会议动态 -->
<view class="dynamic">
<view class="icon iconhuiyimiaoshu iconfont">
</view>
<view class="text">
会议动态
</view>
<view class="upload">
<view class="upload" onTap="upload">
<text>文件上传</text>
<text class="icontianjia iconfont"></text>
</view>
......
import { getScheduleDetail } from '../../api/request.js'
import { getScheduleDetail, uploadPermissions } from '../../api/request.js'
Page({
data: {
title: '',
......@@ -8,7 +8,10 @@ Page({
weeks: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'],
week: '',
userList: [],
isAcrossDay: true
aheadTimes: [],
isAcrossDay: true,
describe: '',
spaceId: ''
},
onLoad() {
......@@ -25,9 +28,16 @@ Page({
startTime: res.data.data.startTime,
endTime: res.data.data.endTime,
userList: res.data.data.userList,
week: this.data.weeks[new Date(res.data.data.startTime).getDay()- 1]
aheadTimes: res.data.data.aheadTimes,
describe: res.data.data.describe,
week: this.data.weeks[new Date(res.data.data.startTime).getDay() - 1]
})
this.acrossDay(res.data.data.startTime, res.data.data.endTime)
return uploadPermissions()
}).then(res => {
this.setData({
spaceId: res.data.data
})
})
},
// 是否跨天
......@@ -46,7 +56,7 @@ Page({
},
// 处理时间
dealTime(time) {
let time1 = time.replace(/-/g,"/")
let time1 = time.replace(/-/g, "/")
let date = new Date(time1)
let day = date.getDate()
let year = date.getFullYear()
......@@ -56,6 +66,28 @@ Page({
month: month,
day: day
}
},
upload() {
dd.uploadAttachmentToDingTalk({
image: { multiple: true, compress: false, max: 9, spaceId: this.data.spaceId },
space: { spaceId: this.data.spaceId, max: 9 },
file: { spaceId: this.data.spaceId, max: 1 },
types: ["photo", "camera", "file", "space"],//PC端仅支持["photo","file","space"]
success: (res) => {
console.log(JSON.stringify(res), 1111)
dd.alert({
content: '上传成功'
})
},
fail: (err) => {
console.log(JSON.stringify(err), 1111)
dd.alert({
content: '上传失败'
})
console.log(err)
}
})
}
});
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 to comment