Commit 0d8c11ad by fengzhaoyu

fix:删除首页绑定第三方入口, 删除outlok

parent 69ab5f95
...@@ -6,7 +6,6 @@ ...@@ -6,7 +6,6 @@
"pages/meetingDetail/meetingDetail", "pages/meetingDetail/meetingDetail",
"pages/excutorList/excutorList", "pages/excutorList/excutorList",
"pages/createMeeting/createMeeting", "pages/createMeeting/createMeeting",
"pages/outLookContact/outLookContact",
"pages/place/place", "pages/place/place",
"pages/uploadFile/uploadFile", "pages/uploadFile/uploadFile",
"pages/participantsDetail/participantsDetail", "pages/participantsDetail/participantsDetail",
...@@ -20,4 +19,4 @@ ...@@ -20,4 +19,4 @@
"allowsBounceVertical": "YES" "allowsBounceVertical": "YES"
}, },
"pullRefresh": false "pullRefresh": false
} }
\ No newline at end of file
...@@ -48,9 +48,6 @@ ...@@ -48,9 +48,6 @@
<view a:if="{{!loading}}"> <view a:if="{{!loading}}">
<view class="scheduleHeader"> <view class="scheduleHeader">
<view>{{currentData.split('/')[0]}}年{{currentData.split('/')[1] || '1'}}月</view> <view>{{currentData.split('/')[0]}}年{{currentData.split('/')[1] || '1'}}月</view>
<view onTap="changesidebar" class="headerIcon">
<text class="iconfont iconicon_app1"></text>
<view></view></view>
</view> </view>
<scroll-view class="indexScrollView" scroll-y="{{true}}" onScroll="scroll" lower-threshold="{{400}}" onScrollToLower="lower" scroll-into-view="{{todayStr}}"> <scroll-view class="indexScrollView" scroll-y="{{true}}" onScroll="scroll" lower-threshold="{{400}}" onScrollToLower="lower" scroll-into-view="{{todayStr}}">
<block a:for="{{scheduleList}}" key="{{item.dateStr}}"> <block a:for="{{scheduleList}}" key="{{item.dateStr}}">
......
...@@ -1034,6 +1034,8 @@ create.Page({ ...@@ -1034,6 +1034,8 @@ create.Page({
}, },
// 创建任务 // 创建任务
goCreateTask(e) { goCreateTask(e) {
this.store.data.currentTask = {};
this.update();
dd.navigateTo({ url: '/pages/createTask/createTask?meetingId=' + this.store.data.scheduleId }) dd.navigateTo({ url: '/pages/createTask/createTask?meetingId=' + this.store.data.scheduleId })
}, },
// 创建会议笔记 // 创建会议笔记
......
page {
background: #fff;
}
.icon {
vertical-align: middle;
color: #1B263D;
font-size: 34rpx;
}
input {
caret-color: #3070F2;
padding-left: 0;
}
.addContact {
padding: 40rpx;
display: flex;
line-height: 1.5;
justify-content: space-between;
}
.addContact>input {
padding-left: 0;
width: 100%;
font-family: PingFangSC-Medium;
font-size: 40rpx;
height: 60rpx;
}
.addContact>.icon {
color: #3070F2;
line-height: 68rpx;
}
.contactListItem {
border-top: 1rpx solid #F1F1F1;
height: 112rpx;
line-height: 112rpx;
padding: 0 40rpx;
display: flex;
align-items: center;
}
.contactListItem:last-child {
border-bottom: 1rpx solid #F1F1F1;
}
.contactImage {
position: relative;
color: #fff;
font-size: 30rpx;
height: 80rpx;
line-height: 80rpx;
text-align: center;
width: 80rpx;
border-radius: 50%;
background-image: linear-gradient(224deg, #FFC672 0%, #FF943E 100%);
}
.contactText {
font-family: PingFangSC-Regular;
margin-left: 16rpx;
font-size: 34rpx;
color: #191F25;
}
.contactClose {
margin-left: auto;
color: #8E939D;
}
.save {
position: fixed;
bottom: 0;
left: 0;
right: 0;
padding: 32rpx;
background: #fff;
bottom: 0;
}
.button {
font-family: PingFangSC-Regular;
width: 686rpx;
height: 72rpx;
background: #EA0C28;
border-radius: 48rpx;
font-size: 32rpx;
color: #FFFFFF;
text-align: center;
line-height: 72rpx;
}
.conflict {
line-height: 15px;
vertical-align: top;
width: 15px;
height: 15px;
position: absolute;
background: #fff;
bottom: 0rpx;
color: #FF943E;
font-size: 12px;
right: -3rpx;
border-radius: 50%;
text-align: center;
}
\ No newline at end of file
<view class="outLookContact">
<!-- 输入邮箱联系人 -->
<view class="addContact">
<input placeholder="请输入邮箱" onInput="onInput" value="{{value}}" onConfirm="addEmail" onBlur="addEmail"/>
<view class="icon iconfont iconicon_add " onTap="addEmail">
</view>
</view>
<!-- 邮箱联系人列表 -->
<view class="contactList">
<view class="contactListItem" a:for="{{outlookContact}}">
<view class="contactImage">
{{item.username.substring(0,2)}}
<view a:if="{{conflictPeople.includes(item.userId)}}" class="conflict iconicon_conflict iconfont">
</view>
</view>
<view class="contactText">
{{item.username}}
</view>
<view a:if="{{(!scheduleItem || currentPeople === $data.originalData.organizer) ? !(item.userId == currentPeople) : !($data.originUsersId.includes(item.userId))}}" class="contactClose icon iconfont iconicon_close" onTap="close" data-item="{{item}}">
</view>
</view>
</view>
<!-- 保存 -->
<view class="save" onTap="save">
<view class="button">
确认添加
</view>
</view>
<toast showToast="{{conToastData.showToast}}" title="{{conToastData.title}}" onToastHidden="onToastHidden"></toast>
<centerpopup centerPopup="{{centerPopup.showCenterPopup}}" centerPopupList="{{centerPopup.centerPopupList}}" onSelectSend="onSelectSend"></centerpopup>
<selectpopup showSelectPopup="{{conSelectPopupData.showSelectPopup}}" selectPopupList="{{conSelectPopupData.editSaveList}}" onSelectPopup="onSelectPopup" onSelectPopupCancel="onSelectPopupCancel"></selectpopup>
</view>
\ No newline at end of file
import { getUserScheduleInTime } from '../../api/request.js'
import { throttle } from './../../utils/utils.js'
import pageStore from '../participantsDetail/store';
import create from 'dd-store'
// 传递给组件toast的所有数据
const conToastData = {
showToast: false,
title: '邮箱格式错误'
}
create.Page({
store: pageStore,
useAll: true,
data: {
$data: null,
outlookContact: [],
conflictPeople: [],
scheduleItem: '',
// 传递给组件toast的所有数据
conToastData: conToastData,
currentPeople: '',
value: '',
toPage: ''
},
onLoad(event) {
const _that = this
if (event.scheduleItem) {
event.scheduleItem = decodeURIComponent(event.scheduleItem)
let scheduleItem = JSON.parse(event.scheduleItem)
this.setData({
scheduleItem: scheduleItem
})
}
if (event.toPage) {
this.setData({
toPage: event.toPage
})
}
let outlookContact = []
let userList = []
if (!this.data.scheduleItem || !this.data.toPage) {
userList = this.$store.data.participatorList
} else {
userList = this.store.data.contactPeople
}
for (let value of userList) {
if (value.platform === 'outlook') {
outlookContact.push(value)
}
}
this.setData({
outlookContact: outlookContact,
currentPeople: getApp().globalData.userid
})
this.conflictPeople()
},
onShow() {
},
// input 的输入 事件
onInput(event) {
this.setData({
value: event.detail.value
})
},
// 添加email
addEmail() {
let reg = /^(?!.* )\w+((.\w+)|(-\w+))@[A-Za-z0-9]+((.|-)[A-Za-z0-9]+).[A-Za-z0-9]+$/
if (!!this.data.value) {
if (reg.test(this.data.value)) {
let outlookContact = this.data.outlookContact
outlookContact.push({
userId: this.data.value,
username: this.data.value,
headUrl: '',
platform: 'outlook'
})
outlookContact = this.setArrary(outlookContact)
this.setData({
value: '',
outlookContact: outlookContact
})
this.conflictPeople()
}
else {
this.setData({
'conToastData.showToast': true
})
}
}
},
// 关闭
close(event) {
let outlookContact = this.data.outlookContact
let index = 0
for (let value of this.data.outlookContact) {
if (value.userId === event.currentTarget.dataset.item.userId) {
outlookContact.splice(index, 1)
this.setData({
outlookContact: outlookContact
})
return
}
index++
}
},
// 数组 去重
setArrary(arr) {
let containt = {}
for (let x of arr) {
containt['id' + x.userId] = x
}
return Object.values(containt)
},
// 保存
save() {
let userList = []
let userId = []
userList.push({ userId: getApp().globalData.userid, username: getApp().globalData.name, headUrl: getApp().globalData.avatar, platform: 'dingtalk' })
userId.push(getApp().globalData.userid)
for (let value of this.data.outlookContact) {
userList.push(value)
userId.push(value.userId)
}
userList = this.setArrary(userList)
userId = [...new Set(userId)]
if (!this.data.scheduleItem || !this.data.toPage) {
this.$store.data.participatorList.push(...userList)
this.$store.data.participatorUserId.push(...userId)
this.$store.data.participatorList = this.setArrary([...this.$store.data.participatorList])
this.$store.data.participatorUserId = [...new Set(this.$store.data.participatorUserId)]
if (!this.data.toPage) {
this.$store.data.updateInfo.isUpate = true
this.$store.data.updateInfo.updateType = 'operate_user'
}
} else {
this.store.data.contactPeople.push(...userList)
this.store.data.contactPeopleId.push(...userId)
this.store.data.contactPeople = this.setArrary(this.store.data.contactPeople)
this.store.data.contactPeopleId = [...new Set(this.store.data.userId)]
if (this.store.data.contactPeople != this.$store.data.originalData.userList) {
this.$store.data.updateInfo.isUpate = true
this.$store.data.updateInfo.updateType = 'operate_user'
}
}
this.update()
dd.navigateBack({
delta: 1
})
},
// 选择弹窗
onSelectPopup(event) {
this.setData({
'conSelectPopupData.showSelectPopup': false,
'conSelectPopupData.selectPopupId': event.currentTarget.dataset.item.id,
'centerPopup.showCenterPopup': true
})
},
// toast 消失之后的回调
onToastHidden() {
this.setData({
'conToastData.showToast': false
})
},
// 会议冲突
conflictPeople() {
let userIds = []
for (let value of this.data.outlookContact) {
userIds.push(value.userId)
}
let data = {
startTime: this.$store.data.startTime.replace(/\//g, "-"),
endTime: this.$store.data.endTime.replace(/\//g, "-"),
userIds: userIds
}
getUserScheduleInTime(data).then(res => {
let conflictPeople = []
for (let value in res.data.data) {
if (!!this.data.scheduleItem) {
const arr = res.data.data[value].filter(function (item) {
return item.confirmAttendance === 1
})
if (arr.length > 1) {
conflictPeople.push(value)
}
} else {
const arr = res.data.data[value].filter(function (item) {
return item.confirmAttendance === 1
})
if (arr.length > 1) {
conflictPeople.push(value)
}
}
}
this.setData({
conflictPeople: conflictPeople
})
})
},
// onSelectPopupCancel 点击取消
onSelectPopupCancel() {
this.setData({
'conSelectPopupData.showSelectPopup': false,
'centerPopup.showCenterPopup': false
})
this.operateUserE(false)
},
// 页面卸载
onUnload() {
}
});
{
"defaultTitle": "添加邮箱联系人",
"usingComponents": {
"popup": "../../components/popup/index",
"list": "../../components/list/list",
"toast": "../../components/toast/toast",
"selectpopup": "../../components/selectPopup/selectPopup",
"centerpopup": "../../components/centerPopup/centerPopup",
"meeting-time-picker": "../../components/meetingTimePicker/meetingTimePicker"
}
}
\ No newline at end of file
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