|
|
@ -1,13 +1,15 @@ |
|
|
<template> |
|
|
<template> |
|
|
<!-- <view class="flex flex-col h-full bg-gray-50" @click="openAuth"> --> |
|
|
<!-- <view class="flex flex-col h-full bg-gray-50" @click="openAuth"> --> |
|
|
<view class="flex flex-col h-full bg-gray-50"> |
|
|
<view class="flex flex-col h-full bg-gray-50"> |
|
|
<view class="relative" @touchmove="onMove"> |
|
|
<view class="relative"> |
|
|
|
|
|
<!-- <view class="relative" @touchmove="onMove"> --> |
|
|
<!-- 日历 --> |
|
|
<!-- 日历 --> |
|
|
<Calendar @selected-change="onDateChange" :show-back="true" ref="calendar" @handleFindPoint="handleFindPoint" /> |
|
|
<Calendar @selected-change="onDateChange" :show-back="true" ref="calendar" @handleFindPoint="handleFindPoint" /> |
|
|
<!-- 上传 导入wbs --> |
|
|
<!-- 上传 导入wbs --> |
|
|
<Upload @success="onUploadSuccess" @error="onUploadError" /> |
|
|
<Upload @success="onUploadSuccess" @error="onUploadError" /> |
|
|
</view> |
|
|
</view> |
|
|
<u-button @click="toLogin">登录</u-button> |
|
|
|
|
|
|
|
|
<u-button class="mt-4" @click="toLogin">登录</u-button> |
|
|
<!-- 项目列表 --> |
|
|
<!-- 项目列表 --> |
|
|
<Projects @getProjects="getProjects" class="flex-1 overflow-y-auto" /> |
|
|
<Projects @getProjects="getProjects" class="flex-1 overflow-y-auto" /> |
|
|
|
|
|
|
|
|
@ -96,18 +98,19 @@ |
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
// 监听触摸滑动 切换日历的模式 月/周 |
|
|
// 监听触摸滑动 切换日历的模式 月/周 |
|
|
function onMove(event) { |
|
|
// function onMove(event) { |
|
|
const y = event.changedTouches[0].pageY; |
|
|
// const y = event.changedTouches[0].pageY; |
|
|
if (y - prevY > 0) { |
|
|
// const prevY = 0; |
|
|
// 向下滑动 如果是周视图weekMode=true 就 变成 月视图weekMode=false |
|
|
// if (y - prevY > 0) { |
|
|
data.calendar.weekMode && (data.calendar.weekMode = false); |
|
|
// // 向下滑动 如果是周视图weekMode=true 就 变成 月视图weekMode=false |
|
|
} else if (y - prevY < 0) { |
|
|
// data.calendar.weekMode && (data.calendar.weekMode = false); |
|
|
// 向上滑动 如果是月视图weekMode=false 就变成 周视图weekMode=true |
|
|
// } else if (y - prevY < 0) { |
|
|
!data.calendar.weekMode && (data.calendar.weekMode = true); |
|
|
// // 向上滑动 如果是月视图weekMode=false 就变成 周视图weekMode=true |
|
|
} |
|
|
// !data.calendar.weekMode && (data.calendar.weekMode = true); |
|
|
prevY = y; |
|
|
// } |
|
|
data.calendar.initDate(); |
|
|
// prevY = y; |
|
|
} |
|
|
// data.calendar.initDate(); |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
function toLogin() { |
|
|
function toLogin() { |
|
|
uni.navigateTo({ |
|
|
uni.navigateTo({ |
|
|
|