Commit 6357191f by fengzhaoyu

conflict:merge conflict

parents b728ebbe dba657f4
...@@ -18,31 +18,34 @@ export default async function login() { ...@@ -18,31 +18,34 @@ export default async function login() {
method: 'POST', method: 'POST',
dataType: 'json', dataType: 'json',
success: function (res) { success: function (res) {
const { oapiUser } = res.data.data; if (res.data.code == 0) {
getApp().globalData.token = res.data.data.accessToken.access_token; const { oapiUser } = res.data.data;
getApp().globalData.name = res.data.data.oapiUser.name; getApp().globalData.token = res.data.data.accessToken.access_token;
getApp().globalData.userid = res.data.data.oapiUser.userid; getApp().globalData.name = res.data.data.oapiUser.name;
getApp().globalData.avatar = res.data.data.oapiUser.avatar; getApp().globalData.userid = res.data.data.oapiUser.userid;
getApp().globalData.userInfo = JSON.stringify({ getApp().globalData.avatar = res.data.data.oapiUser.avatar;
username: oapiUser.name, getApp().globalData.userInfo = JSON.stringify({
userId: oapiUser.userid, username: oapiUser.name,
headUrl: oapiUser.avatar, userId: oapiUser.userid,
platform: "dingtalk" headUrl: oapiUser.avatar,
}); platform: "dingtalk"
lock = false; });
resolve(res) lock = false;
resolve(res)
} else {
lock = false;
reject(res.data);
}
}, },
fail: function (err) { fail: function (err) {
lock = false; lock = false;
reject(err); reject(err);
console.log('err:' + err);
} }
}) })
}, },
fail: function (err) { fail: function (err) {
lock = false; lock = false;
reject(err); reject(err);
console.log('fail:' + err);
} }
}) })
}) })
...@@ -51,7 +54,6 @@ export default async function login() { ...@@ -51,7 +54,6 @@ export default async function login() {
async function waitLockRelease(retry) { async function waitLockRelease(retry) {
for (let i = 0; i < retry; i++) { for (let i = 0; i < retry; i++) {
if (lock == false) { if (lock == false) {
console.log(i);
return; return;
} }
await sleep(100); await sleep(100);
......
...@@ -138,7 +138,13 @@ export function isParticipate(data) { ...@@ -138,7 +138,13 @@ export function isParticipate(data) {
url: `/meet/schedule/confirm` url: `/meet/schedule/confirm`
}); });
} }
//会议室详情的获取重复会议动态列表
export function getMeetingRoomRepeatAffairs(groupId, page) {
return $http({
method: "get",
url: `/meet/meeting-log/scheduleTemplateMeetingLogPage?category=2,3&groupId=${groupId}&size=10&current=${page}`
});
}
//会议室详情的获取动态列表 //会议室详情的获取动态列表
export function getMeetingRoomAffairs(id) { export function getMeetingRoomAffairs(id) {
return $http({ return $http({
......
import login from "./login";
export default function xFetch({ url, method, data, type }) { export default function xFetch({ url, method, data, type }) {
if (type == 'binding') { if (type == 'binding') {
url = `${getApp().globalData.globalUrl2}${url}` url = `${getApp().globalData.globalUrl2}${url}`
...@@ -14,23 +16,36 @@ export default function xFetch({ url, method, data, type }) { ...@@ -14,23 +16,36 @@ export default function xFetch({ url, method, data, type }) {
method: method, method: method,
dataType: "json", dataType: "json",
data: data, data: data,
// timeout: 280, timeout: 15000,
success: function (res) { success: function (res) {
if (res.data.code == 0) { if (res.data.code == 0) {
resolve(res); resolve(res);
} else { } else {
rejects(res); if (res.data.code == 401) {
dd.alert({ login();
content: res.data.msg || "请求数据异常", }
buttonText: "确定" alertOnce('请求异常,请重试', rejects);
});
} }
}, },
fail: function (err) { fail: function (err) {
rejects({ refresh: true }); console.log(err)
alertOnce('网络异常,请重试', rejects);
} }
}); });
}); });
} }
let alert = false;
function alertOnce(content, rejects) {
if (alert == false) {
dd.alert({
content: content,
buttonText: "确定",
success: () => {
rejects({ refresh: true });
alert = false;
}
});
}
alert = true;
}
\ No newline at end of file
...@@ -10,4 +10,14 @@ view { ...@@ -10,4 +10,14 @@ view {
.addPaddingBottom { .addPaddingBottom {
padding-bottom: 68rpx; padding-bottom: 68rpx;
}
.btn {
font-size: 32rpx;
height: 72rpx;
line-height: 72rpx;
border-radius: 48rpx;
text-align: center;
color: #fff;
background: rgba(234, 12, 40, 1);
} }
\ No newline at end of file
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<view class="sidebarContent" catchTap="preventSort"> <view class="sidebarContent" catchTap="preventSort">
<view class="sidebarLogo"> <view class="sidebarLogo">
<template is="avater" data="{{item: userInfo}}"/> <template is="avater" data="{{item: userInfo}}"/>
<view>{{ userInfo.userName }}</view> <view>{{ userInfo.username }}</view>
</view> </view>
<view class="hasAssociated" a:if="{{relatedAppList.length !== 1}}"> <view class="hasAssociated" a:if="{{relatedAppList.length !== 1}}">
<view class="associated"> <view class="associated">
......
...@@ -34,6 +34,11 @@ ...@@ -34,6 +34,11 @@
font-size: 34rpx; font-size: 34rpx;
} }
.iconicon_attender {
position: relative;
top: 4rpx;
}
.participator-title { .participator-title {
color: rgba(25, 31, 37, 1); color: rgba(25, 31, 37, 1);
font-size: 34rpx; font-size: 34rpx;
......
...@@ -63,10 +63,19 @@ ...@@ -63,10 +63,19 @@
justify-content: center; justify-content: center;
} }
.loadingToast view { .loadingToast>view {
font-size: 28rpx; font-size: 28rpx;
color: #FFFFFF; color: #FFFFFF;
padding: 18rpx 26rpx; padding: 18rpx 26rpx;
border-radius: 40rpx; border-radius: 40rpx;
background: rgba(0, 0, 0, .59) background: rgba(0, 0, 0, .59);
display: flex;
justify-content: center;
align-items: center;
}
.loadingToast image {
width: 36rpx;
height: 36rpx;
margin-right: 8rpx;
} }
\ No newline at end of file
...@@ -29,13 +29,28 @@ ...@@ -29,13 +29,28 @@
{{name ? name : 'outlook'}} {{name ? name : 'outlook'}}
</view> </view>
</view> </view>
<view class="{{isBind ? 'unBinding': 'binding'}} bindBtn {{isLoading ? 'loadingBtn' : ''}}" onTap="{{isBind ? 'showPopup' : 'bindApp'}}"> <view class="{{isBind ? 'unBinding': 'binding'}} bindBtn {{isLoading ? 'loadingBtn' : ''}}" onTap="{{isBind ? 'showPopup' : 'bindApp'}}">
<text>{{isBind ? '解绑' : '绑定'}}</text> <text>{{isBind ? '解绑' : '绑定'}}</text>
</view> </view>
</view> </view>
<view class="loadingToast" a:if="{{isLoading}}"> <view class="loadingToast" a:if="{{isLoading}}">
<view> <view a:if="{{bindStatus==='loading'}}">
账号关联中··· <image class="fix-img-width-fix" mode="scaleToFill" src="./../../assests/bindLoading.gif"/>
<view>
账号关联中···
</view>
</view>
<view a:elif="{{bindStatus==='success'}}">
<image class="fix-img-width-fix" mode="scaleToFill" src="./../../assests/bindSuccess.png"/>
<view>
关联成功
</view>
</view>
<view a:else>
<image class="fix-img-width-fix" mode="scaleToFill" src="./../../assests/bindFail.png"/>
<view>
关联失败
</view>
</view> </view>
</view> </view>
<selectpopup showSelectPopup="{{showSelectPopup}}" selectPopupList="{{selectPopupList}}" onSelectPopup="onSelectPopup" onSelectPopupCancel="onSelectPopupCancel"></selectpopup> <selectpopup showSelectPopup="{{showSelectPopup}}" selectPopupList="{{selectPopupList}}" onSelectPopup="onSelectPopup" onSelectPopupCancel="onSelectPopupCancel"></selectpopup>
\ No newline at end of file
...@@ -7,6 +7,7 @@ import { ...@@ -7,6 +7,7 @@ import {
import "dingtalk-jsapi/entry/mobile"; import "dingtalk-jsapi/entry/mobile";
import openLink from "dingtalk-jsapi/api/biz/util/openLink"; import openLink from "dingtalk-jsapi/api/biz/util/openLink";
import create from "dd-store"; import create from "dd-store";
import { fail } from "assert";
let interval = ""; let interval = "";
let requestNum = 0; let requestNum = 0;
create.Page({ create.Page({
...@@ -18,7 +19,8 @@ create.Page({ ...@@ -18,7 +19,8 @@ create.Page({
isBind: false, isBind: false,
isLoading: false, isLoading: false,
showSelectPopup: false, showSelectPopup: false,
selectPopupList: [{ text: "取消关联" }] selectPopupList: [{ text: "取消关联" }],
bindStatus: "loading"
}, },
onLoad(e) { onLoad(e) {
this.setData({ this.setData({
...@@ -31,12 +33,17 @@ create.Page({ ...@@ -31,12 +33,17 @@ create.Page({
sendRequest() { sendRequest() {
let that = this; let that = this;
interval = setInterval(() => { interval = setInterval(() => {
if (requestNum >= 300) { if (requestNum >= 180) {
requestNum = 0; requestNum = 0;
that.setData({ that.setData({
isBind: false, isBind: false,
isLoading: false bindStatus: "fail"
}); });
setTimeout(() => {
that.setData({
isLoading: false
});
}, 2000);
clearInterval(interval); clearInterval(interval);
} }
requestNum++; requestNum++;
...@@ -47,8 +54,13 @@ create.Page({ ...@@ -47,8 +54,13 @@ create.Page({
this.setData({ this.setData({
name: item.userName, name: item.userName,
isBind: true, isBind: true,
isLoading: false bindStatus: "success"
}); });
setTimeout(() => {
that.setData({
isLoading: false
});
}, 2000);
clearInterval(interval); clearInterval(interval);
this.$store.data.relatedAppNeedUpdate = true; this.$store.data.relatedAppNeedUpdate = true;
this.update(); this.update();
...@@ -62,7 +74,8 @@ create.Page({ ...@@ -62,7 +74,8 @@ create.Page({
return false; return false;
} }
this.setData({ this.setData({
isLoading: true isLoading: true,
bindStatus: "loading"
}); });
this.sendRequest(); this.sendRequest();
if (this.data.platform === "outlook") { if (this.data.platform === "outlook") {
......
@import "../../template/loading/loading.acss"; @import "../../template/loading/loading.acss";
@import "../../template/affairBlank/index.acss"; @import "../../template/affairBlank/index.acss";
@import "../../template/fullScreen/fullScreen.acss"; @import "../../template/fullScreen/fullScreen.acss";
@import "../../template/refresh/index.acss";
.dynamicBox { .dynamicBox {
width: 100%; width: 100%;
overflow: hidden; overflow: hidden;
...@@ -9,6 +10,10 @@ ...@@ -9,6 +10,10 @@
height: 100vh; height: 100vh;
} }
.dynamicBox_add_padding {
padding-bottom: 188rpx;
}
.dynamicList { .dynamicList {
width: 100%; width: 100%;
} }
...@@ -100,6 +105,7 @@ ...@@ -100,6 +105,7 @@
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
flex-direction: column;
} }
.scroll-lock { .scroll-lock {
......
<import src="../../template/loading/loading.axml"/> <import src="../../template/loading/loading.axml"/>
<import src="../../template/fullScreen/fullScreen.axml"/> <import src="../../template/fullScreen/fullScreen.axml"/>
<view a:if='{{refresh}}' onTap="onLoad">连接超时,请重试,刷新按钮</view> <import src="../../template/refresh/index.axml"/>
<template is="refresh" a:if='{{refresh}}' ></template>
<block a:else> <block a:else>
<view hidden="{{$data.tabBarIndex === '1'}}"> <view hidden="{{$data.tabBarIndex === '1'}}">
<import src="../../template/affairBlank/index.axml"/> <import src="../../template/affairBlank/index.axml"/>
<view class="{{isStopBodyScroll ? 'scroll-lock' : ''}}" onTap="closeSwipe" onTouchStart="closeSwipe" onTouchMove="closeSwipe" onTouchEnd="closeSwipe"> <view class="{{isStopBodyScroll ? 'scroll-lock' : ''}}" onTap="closeSwipe" onTouchStart="closeSwipe" onTouchMove="closeSwipe" onTouchEnd="closeSwipe">
<block a:if="{{!listLoading}}"> <block a:if="{{!listLoading}}">
<scroll-view a:if="{{dynamicList.length > 0}}" scroll-y="{{true}}" lower-threshold="{{400}}" class="dynamicBox" onScrollToLower="onScrollToLower"> <scroll-view a:if="{{dynamicList.length > 0}}" scroll-y="{{true}}" lower-threshold="{{400}}" class="dynamicBox {{isIPX ? 'dynamicBox_add_padding' : ''}}" onScrollToLower="onScrollToLower">
<view class="dynamicList"> <view class="dynamicList">
<swipe onSetBodyDisableScroll="setBodyDisableScroll" rightWidth="{{ 78 }}" leftWidth="{{ 0 }}" a:for="{{dynamicList}}" class="dynamicContent" key="{{item.scheduleId}}"> <swipe onSetBodyDisableScroll="setBodyDisableScroll" rightWidth="{{ 78 }}" leftWidth="{{ 0 }}" a:for="{{dynamicList}}" class="dynamicContent" key="{{item.scheduleId}}">
<view class="dynamicDetails"> <view class="dynamicDetails">
......
...@@ -29,6 +29,7 @@ import create from "dd-store"; ...@@ -29,6 +29,7 @@ import create from "dd-store";
let maxClickCount = 5; let maxClickCount = 5;
create.Page({ create.Page({
data: { data: {
sign: '',
refresh: false, refresh: false,
$data: null, $data: null,
iconDay: currentDate.getDate(), iconDay: currentDate.getDate(),
...@@ -61,6 +62,7 @@ create.Page({ ...@@ -61,6 +62,7 @@ create.Page({
maxYear: maxYear, maxYear: maxYear,
todayIndex: 0, todayIndex: 0,
onShow() { onShow() {
//如果是重复会议重新算 //如果是重复会议重新算
if (this.$store.data.indexNeedUpdate) { if (this.$store.data.indexNeedUpdate) {
dd.setNavigationBar({ dd.setNavigationBar({
...@@ -84,13 +86,25 @@ create.Page({ ...@@ -84,13 +86,25 @@ create.Page({
this.$store.data.isIndexAffairListNeedUpdate = false; this.$store.data.isIndexAffairListNeedUpdate = false;
this.update(); this.update();
} }
//开启一个定时器
this.timer = setInterval(() => {
this.getData()
}, 30000)
},
onHide() {
clearInterval(this.timer);
this.timer = null;
},
refresh() {
this.onLoad()
}, },
onLoad(event) { onLoad(query) {
if (JSON.stringify(event) != "{}") { console.log(query);
if (query && JSON.stringify(query) !== '{}') {
this.setData({ this.setData({
listLoading: false listLoading: false
}); });
const scheduleItem = JSON.parse(Object.keys(event)[0].split("=")[1]); const scheduleItem = JSON.parse(Object.keys(query)[0].split("=")[1]);
dd.navigateTo({ dd.navigateTo({
url: `./../meetingDetail/meetingDetail?scheduleItem=${encodeURIComponent( url: `./../meetingDetail/meetingDetail?scheduleItem=${encodeURIComponent(
JSON.stringify(scheduleItem) JSON.stringify(scheduleItem)
...@@ -184,11 +198,11 @@ create.Page({ ...@@ -184,11 +198,11 @@ create.Page({
callBack(); callBack();
} }
}).catch(err => { }).catch(err => {
// if (err && err.refresh) { if (err && err.refresh) {
// this.setData({ this.setData({
// refresh: true refresh: true
// }) })
// } }
}); });
}, },
//动态置顶 //动态置顶
...@@ -289,7 +303,23 @@ create.Page({ ...@@ -289,7 +303,23 @@ create.Page({
startTime: "2020-01-01 00:00:00", startTime: "2020-01-01 00:00:00",
endTime: "2025-12-30 23:59:59" endTime: "2025-12-30 23:59:59"
}).then(res => { }).then(res => {
this.getScheduleList(res.data.data); //是否刷新页面
if (this.data.sign && res.data.data.sign !== this.data.sign) {
DateMap = getDateMap(this.minYear, this.maxYear);
}
if (res.data.data.sign !== this.data.sign) {
this.getScheduleList(res.data.data);
}
this.setData({
sign: res.data.data.sign
})
}).catch(err => {
if (err && err.refresh) {
this.setData({
refresh: true
})
}
}); });
}, },
//生成DateMap值 //生成DateMap值
...@@ -780,7 +810,7 @@ create.Page({ ...@@ -780,7 +810,7 @@ create.Page({
maxClickCount--; maxClickCount--;
if (maxClickCount == 0) { if (maxClickCount == 0) {
dd.alert({ dd.alert({
content: "0.0.10" content: "0.0.11"
}); });
maxClickCount = 5; maxClickCount = 5;
} }
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
.affair-list { .affair-list {
background: #fff; background: #fff;
padding: 48rpx 32rpx 220rpx 32rpx; padding: 48rpx 32rpx 220rpx 32rpx;
/* height: calc(100vh - 200rpx); */
} }
.affair-list-margin-top { .affair-list-margin-top {
...@@ -113,7 +114,9 @@ page { ...@@ -113,7 +114,9 @@ page {
background: #fff; background: #fff;
z-index: 1; z-index: 1;
position: relative; position: relative;
width: 100%;
padding-bottom: 0; padding-bottom: 0;
height: 200rpx;
} }
.hideTitle { .hideTitle {
...@@ -613,4 +616,14 @@ input { ...@@ -613,4 +616,14 @@ input {
.lineThrough { .lineThrough {
text-decoration: line-through; text-decoration: line-through;
}
.loading-more {
color: rgba(234, 12, 40, 1);
font-size: 24rpx;
text-align: center;
width: 400rpx;
border-top: 1px solid rgba(239, 242, 245, 1);
padding-top: 32rpx;
margin: 0 auto 50rpx;
} }
\ No newline at end of file
...@@ -202,10 +202,10 @@ ...@@ -202,10 +202,10 @@
<!-- 动态列表 --> <!-- 动态列表 -->
<import src="../../template/avater/index.axml"/> <import src="../../template/avater/index.axml"/>
<import src="../../template/affairBlank/index.axml"/> <import src="../../template/affairBlank/index.axml"/>
<view class="affair-list {{isExpand? '' : 'affair-list-margin-top'}} {{!isExpand&&$data.participatorList.length>1 ? 'addPadding' : ''}}" onTap="hideFileOperate"> <scroll-view class="affair-list {{isExpand? '' : 'affair-list-margin-top'}} {{!isExpand&&$data.participatorList.length>1 ? 'addPadding' : ''}}" onTap="hideFileOperate" scroll-y="{{true}}" lower-threshold="{{400}}" onScrollToLower="onScrollToLower">
<view a:if="{{!isExpand}}" class="affair-list-title">会议动态</view> <view a:if="{{!isExpand}}" class="affair-list-title">会议动态</view>
<block a:if="{{!affairLoading}}"> <block a:if="{{!affairLoading}}">
<block a:for="{{affairList}}"> <block a:for="{{affairList}}" key="{{item.id}}">
<view a:if="{{item.category == '3' && item.taskViewList && item.taskViewList.length > 0}}" class='compose-column'> <view a:if="{{item.category == '3' && item.taskViewList && item.taskViewList.length > 0}}" class='compose-column'>
<view class="avater task-avater"> <view class="avater task-avater">
<text class="iconfont iconicon_task1"></text> <text class="iconfont iconicon_task1"></text>
...@@ -226,6 +226,7 @@ ...@@ -226,6 +226,7 @@
</view> </view>
<view a:if="{{item.content && ((item.category == 1 || item.taskViewList && item.taskViewList.length > 0) || ( item.fileView && item.fileView.fileInfos && item.fileView.fileInfos.length > 0 ))}}" class='simple-column'>{{item.content}} {{item.createTime}}</view> <view a:if="{{item.content && ((item.category == 1 || item.taskViewList && item.taskViewList.length > 0) || ( item.fileView && item.fileView.fileInfos && item.fileView.fileInfos.length > 0 ))}}" class='simple-column'>{{item.content}} {{item.createTime}}</view>
</block> </block>
<view class="loading-more" onTap="loadAffairMore" a:if="{{current < pages}}">加载更多动态...</view>
<view class="affair-placeholder" a:if="{{affairList.length == 1 && affairList[0].logType == 'create_schedule'}}"> <view class="affair-placeholder" a:if="{{affairList.length == 1 && affairList[0].logType == 'create_schedule'}}">
<template is="affair-placeholder" data="{{title: '添加文件', tip: '我们不开无准备的会,快来上传会议文件吧。'}}"/> <template is="affair-placeholder" data="{{title: '添加文件', tip: '我们不开无准备的会,快来上传会议文件吧。'}}"/>
</view> </view>
...@@ -243,7 +244,7 @@ ...@@ -243,7 +244,7 @@
<!-- 任务修改弹出框 --> <!-- 任务修改弹出框 -->
<task-panel a:if="{{pop.type === 'updateTask'}}" action='update' onDeleteTask="deleteTask"/> <task-panel a:if="{{pop.type === 'updateTask'}}" action='update' onDeleteTask="deleteTask"/>
</popup> </popup>
</view> </scroll-view>
</view> </view>
</block> </block>
<view class="loading" a:if="{{loading || !getData}}"> <view class="loading" a:if="{{loading || !getData}}">
......
.refresh-bg {
position: fixed;
left: 0;
top: 0;
background: #FFFFFF;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
}
.refresh-btn {
padding: 0 48rpx;
margin-top: 32rpx;
}
\ No newline at end of file
<template name="refresh">
<view class="refresh-bg">
<view>您的网络好像不给力,请重试</view>
<button class="btn refresh-btn" onTap="refresh">刷新</button>
</view>
</template>
\ 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