This commit is contained in:
Teng 2025-07-24 15:55:15 +08:00
parent 5d1124e7d3
commit a4d5f3eaa3
14 changed files with 758 additions and 284 deletions

View File

@ -67,7 +67,7 @@
position: absolute;
top: 0rpx;
right: 0rpx;
width: 50rpx;
width: 55rpx;
height: 45rpx;
}
@ -476,7 +476,7 @@
align-items: center;
// background-color: rgb(233, 239, 257);
height: 80rpx;
width: 234rpx;
width: 201rpx;
border-right: 1rpx solid transparent;
border-image: repeating-linear-gradient(180deg, #0184db 0px, #0184db 6rpx, transparent 6rpx, transparent 12rpx) 1;
font-weight: 700;
@ -487,7 +487,7 @@
display: flex;
justify-content: center;
align-items: center;
width: 234rpx;
width: 201rpx;
flex-direction: column;
border-right: 1rpx solid transparent;
border-image: repeating-linear-gradient(180deg, #0184db 0px, #0184db 6rpx, transparent 6rpx, transparent 12rpx) 1;
@ -499,8 +499,11 @@
}
.title-time-font-rel {
font-size: 30rpx;
margin-top: -5rpx;
font-size: 25rpx;
margin-bottom: 5rpx;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.title-time-items {
@ -520,7 +523,7 @@
display: flex;
justify-content: center;
align-items: center;
height: 209rpx;
height: 167rpx;
width: calc(100%);
transition: all 0.8s;
border-image: repeating-linear-gradient(90deg, #0184db 0px, #0184db 6rpx, transparent 6rpx, transparent 12rpx) 1;
@ -831,8 +834,8 @@
z-index: 10;
.title-time-blue-img {
height: 209rpx;
width: 230rpx;
height: 167rpx;
width: 200rpx;
}
}
.time-button-black-spe {
@ -975,8 +978,8 @@
position: absolute;
top: -6rpx;
right: -4rpx;
width: 65rpx;
height: 60rpx;
width: 55rpx;
height: 40rpx;
}
.title-time-zhejiao {
@ -989,9 +992,9 @@
.title-time-font {
position: absolute;
top: 3rpx;
top: 0rpx;
right: 5rpx;
font-size: 20rpx;
font-size: 14rpx;
color: #fff;
}
}
@ -1710,7 +1713,7 @@
display: flex;
justify-content: center;
align-items: center;
height: 209rpx;
height: 167rpx;
width: calc(100%);
border-image: repeating-linear-gradient(90deg, #0184db 0px, #0184db 6rpx, transparent 6rpx, transparent 12rpx) 1;
flex-direction: column;
@ -1727,7 +1730,7 @@
display: flex;
justify-content: center;
align-items: center;
height: 209rpx;
height: 167rpx;
width: calc(100%);
border-image: repeating-linear-gradient(90deg, #0184db 0px, #0184db 6rpx, transparent 6rpx, transparent 12rpx) 1;
flex-direction: column;
@ -2008,7 +2011,7 @@
.boom-son {
height: 209rpx;
height: 167rpx;
width: 60rpx;
font-size: 30rpx;
display: flex;
@ -2023,7 +2026,7 @@
}
.boom-son-target {
height: 209rpx;
height: 167rpx;
width: 60rpx;
font-size: 30rpx;
display: flex;

View File

@ -89,7 +89,7 @@
<scroll-view style="height: 920rpx;width: 100%;" :scroll-left="cardLeft" scroll-x
@scroll="handleTop" :show-scrollbar="false">
<view
style="display: flex;box-shadow: 10rpx 10rpx 20rpx rgba(0, 0, 0, 0.1);width:5610rpx;background: linear-gradient(to right, #c4dbf4,#c9c2ef, #c6dcf3);">
style="display: flex;box-shadow: 10rpx 10rpx 20rpx rgba(0, 0, 0, 0.1);width:4824rpx;background: linear-gradient(to right, #c4dbf4,#c9c2ef, #c6dcf3);">
<view v-for="(item0,index0) in timearr" :key="index0">
<view class="super-card-time">
{{(item0.positioning.length == 1 ? ('0' + item0.positioning) : item0.positioning) + ":00"}}
@ -98,7 +98,7 @@
</view>
<view style="display: flex;height: calc(100% - 80rpx);">
<scroll-view style="height: 100%;width:5610rpx" :scroll-top="scrollTop"
<scroll-view style="height: 100%;width:4824rpx" :scroll-top="scrollTop"
:scroll-y="canmove && !shakyTable" @scroll="handleScrolltime"
:show-scrollbar="false">
<view style="display: flex;height: 100%;">
@ -145,7 +145,7 @@
<view class="title-time" v-if="item1.startTime"
v-show=" liang.index0 !== index0 || liang.index1 !== index1 || canmove"
style="margin-top: 5rpx;">
<view class="title-time-time" style="font-size: 25rpx;">
<view class="title-time-time" style="font-size: 25rpx;margin-top: 20rpx;">
{{item1.startTime + `-` + item1.endTime}}
</view>
<image class="title-time-button"
@ -155,8 +155,8 @@
</view>
</view>
<image v-if="item1.startTime" class="title-time-img"
src="/static/index/tu.png" />
<!-- <image v-if="item1.startTime" class="title-time-img"
src="/static/index/tu.png" /> -->
<view v-if="item1.startTime" class="title-time-font-rel">
{{splitString(item1.directiveName)[0]}}
</view>
@ -445,13 +445,13 @@
() => props.isold,
() => {
if (props.isold) {
saveEditIndex.value.index0 = 9;
saveEditIndex.value.index0 = 10;
saveEditIndex.value.index1 = 0;
cardLeft.value = 1;
scrollTop.value = 1;
nextTick(() => {
scrollTop.value = 0;
cardLeft.value = saveleft.value * 117;
cardLeft.value = 704;
})
}
@ -466,9 +466,12 @@
() => {
bottomisShaking.value = false
shakyTable.value = false;
cardLeft.value = 1;
scrollTop.value = 1;
nextTick(() => {
cardLeft.value = 702;
scrollTop.value = 0;
cardLeft.value = 704;
})
})
const bottomItems = ref([
@ -1463,23 +1466,23 @@
function centerCell() {
if (saveEditIndex.value.index0 >= 0 && saveEditIndex.value.index0 <= totalColumns && saveEditIndex.value.index1 >= 0 && saveEditIndex.value.index1 <= totalRows) {
// (rpx)
const cellCenterX = (saveEditIndex.value.index0 ) * 234;
const cellCenterY = (saveEditIndex.value.index1 ) * 210;
console.log("!!!!",saveEditIndex.value.index0)
const cellCenterX = (saveEditIndex.value.index0 + 0.5 ) * 201;
const cellCenterY = (saveEditIndex.value.index1 - 0.5 ) * 167;
// console.log("!!!!",saveEditIndex.value.index0)
// scrollLeft scrollTop使
cardLeft.value = cellCenterX - visibleWidth / 2;
scrollTop.value = cellCenterY - visibleHeight / 2;
//
const totalWidth = totalColumns * 234;
const totalHeight = totalRows * 210;
const totalWidth = totalColumns * 201;
const totalHeight = totalRows * 167;
// scrollLeft scrollTop
cardLeft.value = Math.max(0, Math.min(cardLeft.value, totalWidth - visibleWidth)) /2;
// scrollTop.value = 0
scrollTop.value = Math.max(0, Math.min(scrollTop.value, totalHeight - visibleHeight)) /2;
console.log("????",cardLeft.value,scrollTop.value)
// console.log("????",cardLeft.value,scrollTop.value)
// console.log("????",scrollLeft.value,scrollTop.value,rpx2px)
}
}

View File

@ -2,8 +2,8 @@
"name" : "护理单元",
"appid" : "__UNI__FB2D473",
"description" : "护理单元",
"versionName" : "1.2.9",
"versionCode" : 129,
"versionName" : "1.3.0",
"versionCode" : 130,
"transformPx" : false,
/* 5+App */
"app-plus" : {

View File

@ -98,6 +98,8 @@
</view>
<addball :isShow="true" @clickBall="changeType(0)" />
<decball :isShow="true" @clickBall="changeType(1)" />
<max :isShow="true" :isZhengti="scalcType!==6" @clickBall="changeRuler" />
<!-- <min :isShow="true" @clickBall="scalcType=24" /> -->
<!-- 轮盘 -->
<joystick @movecard="movecard" />
<!-- 长按的弹出层` -->
@ -130,6 +132,8 @@
import { getNclist } from "@/component/rightItemssecond/api.js";
import addball from "./addball.vue"
import decball from "./decball.vue"
import max from "./max.vue"
import min from "./min.vue"
import joystick from '@/component/public/newgame/joysticknew.vue';
//
const darkFans = ref(false);
@ -252,8 +256,8 @@
function centerCell() {
if (clickX.value >= 0 && clickX.value <= totalColumns && clickY.value >= 0 && clickY.value <= totalRows) {
// (rpx)
const cellCenterX = (clickX.value) * widthType.value;
const cellCenterY = (clickY.value) * heightType.value;
const cellCenterX = (clickX.value+0.5) * widthType.value;
const cellCenterY = (clickY.value-2) * heightType.value;
// scrollLeft scrollTop使
scrollLeft.value = cellCenterX - visibleWidth / 2;
@ -287,6 +291,7 @@
// scrollLeft.value = 0;
heightType.value = 102.5
cardFont.value = 18
centerCell();
return
case 23:
widthType.value = 96.5;
@ -700,6 +705,13 @@
break
}
}
function changeRuler(type:boolean){
if(type){
scalcType.value = 6
}else{
scalcType.value = 24
}
}
</script>
<style scoped lang="less">

146
pages/timeMatrix/max.vue Normal file
View File

@ -0,0 +1,146 @@
<template>
<!-- 使用 view 作为悬浮球容器通过绑定 style 进行定位 -->
<view class="floating-ball" v-show="isShow" :style="{ left: ballLeft + 'px', top: ballTop + 'px' }"
@touchstart="handleTouchStart" @touchmove="handleTouchMove" @touchend="handleTouchEnd"
@touchcancel="handleTouchEnd">
<!-- <image class="floating-ball-img" src="/static/index/caigouqingdan.png" /> -->
{{ isZhengti ? "标准" : `缩略图` }}
</view>
</template>
<script setup>
import {
ref,
onMounted,
defineEmits
} from 'vue';
const props = defineProps({
isShow: {
type: Boolean,
required: true,
},
isZhengti: {
type: Boolean,
required: true,
},
});
const emit = defineEmits(['clickBall'])
// const text = ref(false)
//
const ballWidth = 60; // px CSS
const ballHeight = 60; //
const longPressThreshold = 300; //
//
const ballLeft = ref(1070);
const ballTop = ref(550);
//
const isDragging = ref(false);
//
let startTouchX = 0;
let startTouchY = 0;
let initialLeft = 0;
let initialTop = 0;
let longPressTimer = null;
//
let windowWidth = 0;
let windowHeight = 0;
onMounted(() => {
// uni-app API
const res = uni.getSystemInfoSync();
windowWidth = res.windowWidth;
windowHeight = res.windowHeight;
});
//
function handleTouchStart(e) {
const touch = e.touches[0];
// console.log("????0",touch.clientX )
startTouchX = touch.clientX.toFixed(2);
startTouchY = touch.clientY.toFixed(2);
initialLeft = ballLeft.value;
initialTop = ballTop.value;
//
longPressTimer = setTimeout(() => {
isDragging.value = true;
}, longPressThreshold);
}
//
function handleTouchMove(e) {
//
if (!isDragging.value) {
const touch = e.touches[0];
// console.log("????0",touch.clientX )
const deltaX = Math.abs(touch.clientX.toFixed(2) - startTouchX);
const deltaY = Math.abs(touch.clientY.toFixed(2) - startTouchY);
if (deltaX > 5 || deltaY > 5) {
clearTimeout(longPressTimer);
isDragging.value = true;
}
}
//
if (isDragging.value) {
const touch = e.touches[0];
// console.log("????0",touch.clientX )
let newLeft = initialLeft + (touch.clientX.toFixed(2) - startTouchX);
let newTop = initialTop + (touch.clientY.toFixed(2) - startTouchY);
//
newLeft = Math.max(0, Math.min(newLeft, windowWidth - ballWidth));
//
newTop = Math.max(0, Math.min(newTop, windowHeight - ballHeight));
ballLeft.value = newLeft;
ballTop.value = newTop;
}
}
//
function handleTouchEnd(e) {
clearTimeout(longPressTimer);
if (isDragging.value) {
//
isDragging.value = false;
} else {
//
triggerClick();
}
}
//
function triggerClick() {
emit('clickBall',props.isZhengti)
}
</script>
<style lang="less" scoped>
.floating-ball {
position: fixed;
width: 140rpx;
height: 140rpx;
border-radius: 50%;
background: linear-gradient(to bottom right, #3FBBFE, #A541FF);
border: 2rpx solid #fff;
z-index: 999;
display: flex;
justify-content: center;
align-items: center;
color: #fff;
font-size: 30rpx;
/* 可根据需要添加阴影或其他样式 */
// .floating-ball-img{
// width: 70rpx;
// height: 70rpx;
// }
}
</style>

137
pages/timeMatrix/min.vue Normal file
View File

@ -0,0 +1,137 @@
<template>
<!-- 使用 view 作为悬浮球容器通过绑定 style 进行定位 -->
<view class="floating-ball" v-show="isShow"
:style="{ left: ballLeft + 'px', top: ballTop + 'px' }"
@touchstart="handleTouchStart"
@touchmove="handleTouchMove"
@touchend="handleTouchEnd"
@touchcancel="handleTouchEnd">
<!-- <image class="floating-ball-img" src="/static/index/caigouqingdan.png" /> -->
最小化
</view>
</template>
<script setup>
import { ref, onMounted,defineEmits } from 'vue';
const props = defineProps({
isShow: {
type: Boolean,
required: true,
},
});
const emit = defineEmits(['clickBall'])
//
const ballWidth = 60; // px CSS
const ballHeight = 60; //
const longPressThreshold = 300; //
//
const ballLeft = ref(980);
const ballTop = ref(550);
//
const isDragging = ref(false);
//
let startTouchX = 0;
let startTouchY = 0;
let initialLeft = 0;
let initialTop = 0;
let longPressTimer = null;
//
let windowWidth = 0;
let windowHeight = 0;
onMounted(() => {
// uni-app API
const res = uni.getSystemInfoSync();
windowWidth = res.windowWidth;
windowHeight = res.windowHeight;
});
//
function handleTouchStart(e) {
const touch = e.touches[0];
// console.log("????0",touch.clientX )
startTouchX = touch.clientX.toFixed(2);
startTouchY = touch.clientY.toFixed(2);
initialLeft = ballLeft.value;
initialTop = ballTop.value;
//
longPressTimer = setTimeout(() => {
isDragging.value = true;
}, longPressThreshold);
}
//
function handleTouchMove(e) {
//
if (!isDragging.value) {
const touch = e.touches[0];
// console.log("????0",touch.clientX )
const deltaX = Math.abs(touch.clientX.toFixed(2) - startTouchX);
const deltaY = Math.abs(touch.clientY.toFixed(2) - startTouchY);
if(deltaX > 5 || deltaY > 5){
clearTimeout(longPressTimer);
isDragging.value = true;
}
}
//
if(isDragging.value){
const touch = e.touches[0];
// console.log("????0",touch.clientX )
let newLeft = initialLeft + (touch.clientX.toFixed(2) - startTouchX);
let newTop = initialTop + (touch.clientY.toFixed(2) - startTouchY);
//
newLeft = Math.max(0, Math.min(newLeft, windowWidth - ballWidth));
//
newTop = Math.max(0, Math.min(newTop, windowHeight - ballHeight));
ballLeft.value = newLeft;
ballTop.value = newTop;
}
}
//
function handleTouchEnd(e) {
clearTimeout(longPressTimer);
if(isDragging.value){
//
isDragging.value = false;
} else {
//
triggerClick();
}
}
//
function triggerClick() {
emit('clickBall')
}
</script>
<style lang="less" scoped>
.floating-ball {
position: fixed;
width: 140rpx;
height: 140rpx;
border-radius: 50%;
background: linear-gradient(to bottom right,#3FBBFE,#A541FF);
border: 2rpx solid #fff;
z-index: 999;
display: flex;
justify-content: center;
align-items: center;
color: #fff;
font-size: 30rpx;
/* 可根据需要添加阴影或其他样式 */
// .floating-ball-img{
// width: 70rpx;
// height: 70rpx;
// }
}
</style>

Binary file not shown.

File diff suppressed because one or more lines are too long

View File

@ -7,8 +7,8 @@
"id": "__UNI__FB2D473",
"name": "护理单元",
"version": {
"name": "1.2.9",
"code": 129
"name": "1.3.0",
"code": 130
},
"description": "护理单元",
"developer": {

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

View File

@ -5546,7 +5546,7 @@
position: absolute;
top: 0;
right: 0;
width: 1.5625rem;
width: 1.71875rem;
height: 1.40625rem;
}
.super-card .right-cards .scroll-box .right-box .title-time-font[data-v-72bcf905] {
@ -5901,7 +5901,7 @@
justify-content: center;
align-items: center;
height: 2.5rem;
width: 7.3125rem;
width: 6.28125rem;
border-right: 0.03125rem solid transparent;
border-image: repeating-linear-gradient(180deg, #0184db 0px, #0184db 0.1875rem, transparent 0.1875rem, transparent 0.375rem) 1;
font-weight: 700;
@ -5911,7 +5911,7 @@
display: flex;
justify-content: center;
align-items: center;
width: 7.3125rem;
width: 6.28125rem;
flex-direction: column;
border-right: 0.03125rem solid transparent;
border-image: repeating-linear-gradient(180deg, #0184db 0px, #0184db 0.1875rem, transparent 0.1875rem, transparent 0.375rem) 1;
@ -5922,8 +5922,11 @@
margin-top: -0.15625rem;
}
.super-card .super-card-time-und .title-time-font-rel[data-v-72bcf905] {
font-size: 0.9375rem;
margin-top: -0.15625rem;
font-size: 0.78125rem;
margin-bottom: 0.15625rem;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.super-card .super-card-time-und .title-time-items[data-v-72bcf905] {
display: flex;
@ -5939,7 +5942,7 @@
display: flex;
justify-content: center;
align-items: center;
height: 6.53125rem;
height: 5.21875rem;
width: calc(100%);
transition: all 0.8s;
border-image: repeating-linear-gradient(90deg, #0184db 0px, #0184db 0.1875rem, transparent 0.1875rem, transparent 0.375rem) 1;
@ -6213,8 +6216,8 @@
z-index: 10;
}
.title-time-blue .title-time-blue-img[data-v-72bcf905] {
height: 6.53125rem;
width: 7.1875rem;
height: 5.21875rem;
width: 6.25rem;
}
.time-button-black-spe[data-v-72bcf905] {
transition: all 1s;
@ -6346,8 +6349,8 @@
position: absolute;
top: -0.1875rem;
right: -0.125rem;
width: 2.03125rem;
height: 1.875rem;
width: 1.71875rem;
height: 1.25rem;
}
.title-time .title-time-zhejiao[data-v-72bcf905] {
position: absolute;
@ -6358,9 +6361,9 @@
}
.title-time .title-time-font[data-v-72bcf905] {
position: absolute;
top: 0.09375rem;
top: 0;
right: 0.15625rem;
font-size: 0.625rem;
font-size: 0.4375rem;
color: #fff;
}
.popup-say[data-v-72bcf905] {
@ -6978,7 +6981,7 @@
display: flex;
justify-content: center;
align-items: center;
height: 6.53125rem;
height: 5.21875rem;
width: calc(100%);
border-image: repeating-linear-gradient(90deg, #0184db 0px, #0184db 0.1875rem, transparent 0.1875rem, transparent 0.375rem) 1;
flex-direction: column;
@ -6994,7 +6997,7 @@
display: flex;
justify-content: center;
align-items: center;
height: 6.53125rem;
height: 5.21875rem;
width: calc(100%);
border-image: repeating-linear-gradient(90deg, #0184db 0px, #0184db 0.1875rem, transparent 0.1875rem, transparent 0.375rem) 1;
flex-direction: column;
@ -7224,7 +7227,7 @@
z-index: 10;
}
.boom .boom-son[data-v-72bcf905] {
height: 6.53125rem;
height: 5.21875rem;
width: 1.875rem;
font-size: 0.9375rem;
display: flex;
@ -7238,7 +7241,7 @@
border-image: repeating-linear-gradient(90deg, #0184db 0px, #0184db 0.1875rem, transparent 0.1875rem, transparent 0.375rem) 1;
}
.boom .boom-son-target[data-v-72bcf905] {
height: 6.53125rem;
height: 5.21875rem;
width: 1.875rem;
font-size: 0.9375rem;
display: flex;

View File

@ -30,6 +30,22 @@
/* 可根据需要添加阴影或其他样式 */
}
.floating-ball[data-v-88de1696] {
position: fixed;
width: 4.375rem;
height: 4.375rem;
border-radius: 50%;
background: linear-gradient(to bottom right, #3FBBFE, #A541FF);
border: 0.0625rem solid #fff;
z-index: 999;
display: flex;
justify-content: center;
align-items: center;
color: #fff;
font-size: 0.9375rem;
/* 可根据需要添加阴影或其他样式 */
}
.move-circle[data-v-e20c63a2] {
position: absolute;
bottom: 2.90625rem;