This commit is contained in:
wangweidong 2026-01-12 10:42:10 +08:00
parent 87bf3497b9
commit 17a679efb5
3 changed files with 515 additions and 45 deletions

View File

@ -74,56 +74,72 @@
<view class="mengban" v-if="jszlshow" @click="jszlshow = false"></view>
</view>
<view class="photo-father">
<!-- :style="indexmessage?.startTime?{}:{filter: `grayscale(60%)`}" -->
<view class="juzhong" style="margin-left: -30rpx;z-index: 1;">
<view class="juzhong" style="margin-left: -30rpx;" :style="indexmessage?.startTime?{}:{filter: `grayscale(60%)`}">
<donghua :width="`1300rpx`" :height="`900rpx`" :links="blueArray" :playing="photoplay" :loop="true"
:interval="120" />
</view>
<!-- <view class="juzhong" style="z-index: 2;margin-top: 80rpx;">
<donghua :width="`800rpx`" :height="`500rpx`" :links="bluesmallArray" :playing="photoplay" :loop="true"
:interval="120" />
</view> -->
<view class="weight-time">
10:00 - 10:10
<view class="pao-father">
<view class="" v-if="indexmessage?.startTime">
{{ indexmessage?.startTime.slice(11, 16) }}
-
{{ indexmessage?.endTime.slice(11, 16) }}
</view>
<view style="height: 5vw;" v-show="!indexmessage?.startTime">
</view>
<view class="pao-father" v-show="indexmessage?.startTime">
<image class="pao-img" :src="`/static/index/newindex/states/pao.png`" />
<view style="z-index: 1;">
待执行
{{indexmessage?.izStart=='N'?'待执行':'执行中'}}
</view>
</view>
</view>
<image class="big-img" :src="`/static/index/newindex/leftmenu/bigimg.png`" />
<!-- <image class="big-img-nomessage"
:src="`/static/index/newindex/wendu/2.png`" /> -->
<tanchuang :show="open==3" font="是否结束服务指令?" @back="open = 0" @right="ends()"> </tanchuang>
<image class="big-img" v-if="topbuttontarget==0" :style="!indexmessage?.previewFile?'width: 450rpx':''"
:src="indexmessage?.previewFile? 'https://www.focusnu.com/media/upFiles/' + indexmessage?.previewFile: `/static/index/newindex/wendu/2.png`" mode="aspectFill"/>
<view style="display: flex;align-items: center;">
<view class="server-name">
{{ filteredMenu(2)[menutarget]?.nuName }}
<view class="server-name" v-if="indexmessage?.startTime">
{{ indexmessage?.directiveName }}
</view>
</view>
<!-- <view class="server-number">
业务单号{{ filteredMenu(2)[menutarget]?.id }}
</view> -->
<view style="display: flex;margin-top: 40rpx;">
<view style="display: flex;margin-top: 40rpx;" v-if="indexmessage?.startTime">
<view style="width: 240rpx;height: 90rpx;margin-right: 40rpx;">
<view class="start-button">
<view :class="indexmessage?.izStart=='N'?'start-button':'end-button'" v-show="indexmessage?.startTime" @click="start(indexmessage)">
开始服务
</view>
</view>
<view style="width: 240rpx;height: 90rpx;">
<view class="end-button">
<view :class="(indexmessage?.izStart=='Y'&& indexmessage?.izFinish=='N')?'start-button':'end-button'" @click="end(indexmessage)">
结束服务
</view>
</view>
</view>
</view>
<view class="left-menu">
<view v-for="(item,index) in leftArray" :key="index" style="margin: 30rpx 0;">
<view class="left-ball">
<image class="left-menu-img" :src="item" />
<view class="left-menu" v-show="indexmessage?.startTime">
<view style="margin: 30rpx 0;" @click="errmsgclk(0,1)">
<view class="left-ball" :style="indexmessage?.serviceContent!=''?'background-color: #fff;':'background-color:RGBA(228, 229, 231, 1);'">
<image class="left-menu-img" :src="'/static/index/newindex/leftmenu/left'+0+'.png'" />
</view>
</view>
<view style="margin: 30rpx 0;" @click="errmsgclk(1,1)">
<view class="left-ball" :style="indexmessage?.mp3File!=''?'background-color: #fff;':'background-color:RGBA(228, 229, 231, 1);'">
<image class="left-menu-img" :src="'/static/index/newindex/leftmenu/left'+1+'.png'" />
</view>
</view>
<view style="margin: 30rpx 0;" @click="errmsgclk(2,1)">
<view class="left-ball" :style="indexmessage?.mp4File!=''?'background-color: #fff;':'background-color:RGBA(228, 229, 231, 1);'">
<image class="left-menu-img" :src="'/static/index/newindex/leftmenu/left'+2+'.png'" />
</view>
</view>
<view v-for="(item,index) in [3,4]" :key="index" style="margin: 30rpx 0;" @click="errmsgclk(item,2)">
<view class="left-ball" :style="indexmessage?.izStart=='Y'?'background-color: #fff;':'background-color:RGBA(228, 229, 231, 1);'">
<image class="left-menu-img" :src="'/static/index/newindex/leftmenu/left'+item+'.png'" />
</view>
</view>
</view>
<view class="right-menu">
@ -237,32 +253,35 @@
</view> -->
</view>
</view>
<view class="fixed-card" :style="openleft?{right: '2.4vw'}:{right:`-33vw`}">
<view class="fixed-card" :style="openleft?{}:{right:`-33vw`}" v-show="indexmessage?.startTime">
<view class="fixed-card-left">
<image class="card-left-img" :src="`/static/index/newindex/wendu/2.png`" />
<image class="card-left-img" :style="!indexmessage?.previewFile?'width: 450rpx':''"
:src="indexmessage?.previewFile? 'https://www.focusnu.com/media/upFiles/' + indexmessage?.previewFile: `/static/index/newindex/wendu/2.png`" mode="aspectFill"/>
<view class="">
库存盘点
{{ indexmessage?.directiveName }}
</view>
</view>
<view>
<view class="big-time">
10:00 - 10:10
<view class="big-time" v-if="indexmessage?.startTime">
{{ indexmessage?.startTime.slice(11, 16) }}
-
{{ indexmessage?.endTime.slice(11, 16) }}
</view>
<view class="icon-people">
<image class="people-img" src="/static/index/newindex/leftmenu/iconleft.png" />
单人执行
<image style="margin-left: 1vw;" class="people-img"
src="/static/index/newindex/leftmenu/iconright.png" />
王金福
{{indexmessage.employeeName}}
</view>
<view style="color: #555555;">
<!-- <view style="color: #555555;">
业务单号P10120251010001
</view>
</view> -->
<view class="icon-button">
<view class="button-left">
<view :class="indexmessage?.izStart=='N'?'button-right':'button-left'" @click="start(indexmessage)">
开始服务
</view>
<view class="button-right">
<view :class="(indexmessage?.izStart=='Y'&& indexmessage?.izFinish=='N')?'button-right':'button-left'" @click="end(indexmessage)">
结束服务
</view>
</view>
@ -271,13 +290,128 @@
<image :style="openleft?{}:{transform: `rotate(180deg)`}" class="open-img"
src="/static/index/newindex/leftmenu/openleft.png" />
</view>
<view class="mengban" v-if="topbuttontarget>0" @click="topbuttontarget=0"></view>
<view class="photowall" v-show="topbuttontarget>0" :style="donghuaopo?{opacity:1}:{opacity:0}">
<view class="photowall-title">
<view class="photowall-name">
{{ topbuttontarget==1?`照片`:`录像` }}
</view>
</view>
<scroll-view scroll-y="true" class="photowall-other" scroll-with-animation enable-flex v-if="topbuttontarget>0">
<view class="photowall-other" >
<view class="photowall-other-one" v-for="(item,index) in ilanarr" :key="index"
@click="previewImage(item,index,ilanarr)">
<view v-if="topbuttontarget==1" style="width: 100%;height: 70%;border-radius: 30rpx;position: relative;">
<image style="width: 100%;height: 100%;border-radius: 30rpx;"
:src="item?serverUrl + item:'/static/ceshiyaoshan.png'" mode="aspectFill"
:lazy-load="true"/>
<view @click.stop="open=1;del(item,index)"
style="width: 1.6vw;
height: 1.6vw;
z-index: 20;
position: absolute;
right: -1vw;
top: -0.7vw;
background: red;
display: flex;
justify-content: center;
border-radius: 50%;
align-items: center;"
v-if="topbuttontarget>0&&(listobj.izStart=='Y'&& listobj.izFinish=='N')">
<image src="/static/index/warehouse/procurement/x.png" mode="aspectFill"
style="width: 1.4vw;
height: 1.4vw;"></image>
</view>
</view>
<view v-if="topbuttontarget==2" style="width: 100%;height: 70%;border-radius: 30rpx ;position: relative;" >
<video style="width: 100%;height: 100%;border-radius: 30rpx;" :id="'myVideo'+index"
:src="servervideoUrl+item"
mode="aspectFill" ></video>
<view @click.stop="ilanarr.splice(index,1)"
v-if="topbuttontarget>0&&(listobj.izStart=='Y'&& listobj.izFinish=='N')"
style="width: 1.6vw;
height: 1.6vw;
z-index: 20;
position: absolute;
right: -1vw;
top: -0.7vw;
background: red;
display: flex;
justify-content: center;
border-radius: 50%;
align-items: center;">
<image src="/static/index/warehouse/procurement/x.png" mode="aspectFill"
style="width: 1.4vw;
height: 1.4vw;"></image>
</view>
</view>
<!-- <view style="margin-top: 20rpx;">
<text style="color: #888888;">
上传时间:
</text>
<text style="margin-left: 15rpx;">
{{item.createTime.replace(/-/g, '.')}}
</text>
</view>
<view style="margin-top: 10rpx;">
<text style="color: #888888;letter-spacing: 8.9rpx;">
上传人:
</text>
<text>
{{item.createBy}}
</text>
</view> -->
</view>
<view class="photowall-other-one" v-if="topbuttontarget>0&&(listobj.izStart=='Y'&& listobj.izFinish=='N')">
<view style="width: 100%;height: 71%;display: flex;flex-direction: column;
justify-content: center;align-items: center;position: absolute;top:0vw;left: 0;
background-color:#fafdff ;border: 1rpx solid #78B1EB;border-radius: 30rpx;" @click="uplod(1)">
<image style="width: 70rpx;height: 70rpx;margin-bottom: 5rpx;"
src="/static/index/warehouse/procurement/picking/addphoto.png" />
<view style="color: #78B1EB;">
点击上传{{topbuttontarget==1?'图片':'录像'}}
</view>
</view>
</view>
<!-- <view class="noarray" v-if="!ilanarr.length">
<image class="noarray-img" src="/static/index/warehouse/procurement/picking/noarray.png"
mode="aspectFill" />
<view class="noarray-font">
暂无照片
</view>
</view> -->
</view>
</scroll-view>
<view style="position: absolute;right: 2vw;bottom: 0.8vw;height: 4vw;" v-if="topbuttontarget>0&&(listobj.izStart=='Y'&& listobj.izFinish=='N')">
<view
style="width: 8.2vw;
height: 3.3vw;
background: #EDEDEF;
border-radius: 1.6vw;
font-weight: 400;
font-size: 1.6vw;
color: #888888;
display: flex;
justify-content: center;
align-items: center;
border: 1px solid #EDEDEF;
background: linear-gradient(0deg, #CAE0F9, #E9F4FF);
border: 1px solid rgba(3,133,250,0.34);
color: #0385FA;" @click="submit" >确定</view>
</view>
</view>
<tanchuang :show="open==1" font="是否删除此图片" @back="open = 0" @right="del1()"> </tanchuang>
</view>
</template>
<script setup lang="ts">
import { ref, onMounted, onBeforeUnmount, computed, nextTick, watch } from 'vue';
import { ref, onMounted, onBeforeUnmount, computed, nextTick, watch,reactive } from 'vue';
import { queryPadPageList } from '@/pages/watch/api/lunpan.js'
import { queryWorkOrderList,queryCountByType,queryAll } from '@/pages/NursingNew/component/api.js'
import {queryOrderList,queryOrderInfoList,startOrder,endOrder,editSubPicPath,editSubMp4} from '@/pages/NursingNew/component/doctorask/api/api.js'
const jszlshow = ref(false)
const props = defineProps({
isShow: {
@ -286,6 +420,258 @@
},
});
const indexmessage = ref({});
const serverUrl = ref(uni.getStorageSync('serverUrl') + '/sys/common/static/')
const servervideoUrl = ref(uni.getStorageSync('serverUrl') + '/sys/commonVideo/staticVideo/')
const form = reactive({
pageNo: 1,
pageSize: 10,
employeeId:uni.getStorageSync('userInfo').employessId,
nuId:uni.getStorageSync('nuId')
})
const plsbuy = ref([])
const firstgetqueryCgdList = (nuId) => {
form.nuId = nuId;
console.log(form)
queryOrderList(form).then(res => {
console.log(res)
// plsbuy.value.push(...res.result.records);
if(res.result.records.length>0){
clickLeftMenu(0,res.result.records[0])
}else{
indexmessage.value = {};
}
})
}
const clickLeftMenu = (index : any, item : object) => {
queryOrderInfoList({ mainId: item.id }).then(res => {
if(res.result.length>0){
indexmessage.value = res.result[0]
}else{
indexmessage.value = {};
}
})
}
const open = ref(0)
const donghuaopo = ref(false);
const topbuttontarget = ref(0);
const ilanarr = ref([]);
const listobj = ref({});
const ysptp = (v,i,r) =>{
// v.manuallyPicPath
if(r == 1&&v.manuallyPicPath){
ilanarr.value = v.manuallyPicPath.split(",");
ilanarr.value = ilanarr.value.filter(item => item !== '');
}else if(r == 2&&v.manuallyMp4Path){
ilanarr.value = v.manuallyMp4Path.split(",");
ilanarr.value = ilanarr.value.filter(item => item !== '');
}else if(r == 3&&v.tplinkPath){
ilanarr.value = v.tplinkPath.split(",");
ilanarr.value = ilanarr.value.filter(item => item !== '');
}
else{
ilanarr.value = [];
}
listobj.value = v;
topbuttontarget.value = r;
donghuaopo.value = true;
}
const uplod = (v) => {
if(topbuttontarget.value==1){
uni.chooseImage({
count: 1, //9
sizeType: ['compressed'], //
sourceType: ['camera'], //
success: (e) => {
let ar = JSON.stringify(e.tempFilePaths)
uni.compressImage({
src: JSON.parse(ar)[0],
quality: 60,
success: res => {
sxdupld(res.tempFilePath)
// v.picPatharr.push(res.tempFilePath);
// console.log(v.picPatharr)
}
})
}
});
}else{
uni.chooseVideo({
sourceType: ['camera' ],
success: (e)=> {
uni.compressVideo({
src: e.tempFilePath,
quality: 60,
success: res => {
sxdupld(res.tempFilePath)
// v.picPatharr.push(res.tempFilePath);
// console.log(v.picPatharr)
}
})
// sxdupld(res.tempFilePath )
}
});
}
}
const sxdupld = (e) => {
let now = new Date();
let year = now.getFullYear();
let month = now.getMonth() + 1;
uni.uploadFile({
url: uni.getStorageSync('serverUrl') + '/sys/common/upload',
filePath: e,
name: 'file',
fileType:topbuttontarget.value==2?'video':'image',
formData: {
biz: year + '/' + month + (topbuttontarget.value==1?'/fwxm/manuallyPicPath':'/fwxm/manuallyMp4Path')
},
header: {
'X-Access-Token': uni.getStorageSync('token')
},
success: res => {
const data = JSON.parse(res.data);
console.log(data)
ilanarr.value.push(data.message)
},
fail: () => {
uni.showToast({ title: '上传失败', icon: 'none' })
}
})
}
const submit = ()=>{
let sub = "";
ilanarr.value.forEach(item=>{
sub+=item+','
})
if(topbuttontarget.value == 1){
editSubPicPath({id:listobj.value.id,manuallyPicPath:sub}).then(res=>{
if(res.success){
topbuttontarget.value = 0;
donghuaopo.value = false;
clickLeftMenu(0,{id:indexmessage.value.mainId})
}
})
}else{
editSubMp4({id:listobj.value.id,manuallyMp4Path:sub}).then(res=>{
if(res.success){
topbuttontarget.value = 0;
donghuaopo.value = false;
clickLeftMenu(0,{id:indexmessage.value.mainId})
}
})
}
}
const previewImage = (v, i, arr) => {
if(topbuttontarget.value == 1){
let u = []
arr.forEach(e => {
u.push(serverUrl.value + e)
console.log(serverUrl.value + e)
})
uni.previewImage({
current: i,
urls: u,
showmenu: false,
longPressActions: {
itemList: [],
}
})
}
}
const videoContext = ref(null)
const play = (e,i)=>{
videoContext.value = uni.createVideoContext('myVideo'+i);
videoContext.value.play()
}
const pici = ref(0);
const del = (v,i) =>{
pici.value = i;
}
const del1=()=>{
ilanarr.value.splice(pici.value,1);
open.value = 0
}
//
const openerror = ref(false);
const errmsg = ref('')
const errmsgclk = (e,k)=>{
console.log(indexmessage.value,k)
if(k==1){
if(indexmessage.value?.izStart=='Y'){
switch (e){
case 0:
if(indexmessage.value?.serviceContent==''){return}
errmsg.value = indexmessage.value?.serviceContent
break;
case 1:
if(indexmessage.value?.mp3File==''){return}
errmsg.value = indexmessage.value?.mp3File
break;
case 2:
if(indexmessage.value?.mp4File==''){return}
errmsg.value = indexmessage.value?.mp4File
break;
default:
break;
}
openerror.value = true;
}
}else{
if(indexmessage.value?.izStart=='Y'){
switch (e){
case 3:
ysptp(indexmessage.value,0,1)
break;
case 4:
ysptp(indexmessage.value,0,2)
break;
default:
break;
}
}
}
}
const start = (v) =>{
if(v.izStart!='N'){return}
console.log(v)
startOrder({id:v.id}).then(res=>{
console.log(res)
if(res.success){
v.izStart = "Y";
}else{
}
})
}
const end = (v)=>{
if(indexmessage.value.izStart=='Y'&& indexmessage.value.izFinish=='N'){
open.value=3;
}
}
const ends = ()=>{
endOrder({id:indexmessage.value.id}).then(res=>{
if(res.success){
open.value=0;
firstgetqueryCgdList(uni.getStorageSync('nuId'))
}else{
}
})
}
const leftMenuArray = ref([]);
const openleft = ref(false)
@ -299,7 +685,8 @@
uni.setStorageSync('elderId', data.elderInfo ? data.elderInfo?.id : null);
console.log(uni.getStorageSync('elderId'),uni.getStorageSync('nuId'),data.elderInfo)
uni.setStorageSync('NUall', data);
emit('swip')
firstgetqueryCgdList(data.nuId);
emit('swip');
hlylhq(data.nuId )
zlfunc(data.nuId )
}
@ -502,6 +889,71 @@
</script>
<style scoped lang="less">
.mengban {
width: 100vw;
height: 100vh;
position: fixed;
top: 0;
left: 0;
z-index: 100;
background: RGBA(239, 240, 244, 0.55);
}
.photowall {
position: fixed;
top: 54%;
left: 50%;
transform: translate(-50%, -50%);
width: 80vw;
height: 83%;
border-radius: 30rpx;
background-color: #fff;
transition: all 0.3s;
z-index: 9990;
box-shadow: 0 0 10rpx rgba(0, 0, 0, 0.1);
padding: 0 90rpx;
.photowall-title {
margin-top: 50rpx;
display: flex;
justify-content: space-between;
width: 100%;
margin-bottom: 50rpx;
.photowall-name {
font-size: 38rpx;
// font-weight: 600;
}
.photowall-left {
color: #888888;
}
.photowall-right {
font-size: 30rpx;
font-weight: 600;
}
}
.photowall-other {
width: 76vw;
height: 62vh;
display: flex;
margin-top: 20rpx;
flex-wrap: wrap;
.photowall-other-one {
width: 22vw;
height: 430rpx;
margin-right: 3vw;
margin-bottom: 0%;
border-radius: 30rpx;
display:flex;
position: relative;
video{
width: 100%;
height: 100%;
}
}
}
}
.index-content-right {
width: 19.5vw;
margin-left: 2vw;
@ -1124,7 +1576,7 @@
display: flex;
flex-direction: column;
align-items: center;
margin: 0 1.5vw;
.card-left-img {
width: 12vw;
height: 8vw;
@ -1153,7 +1605,8 @@
display: flex;
margin-top: 1vw;
font-size: 1.5vw;
width: 18.5vw;
justify-content: space-around;
.button-left {
width: 8.5vw;
height: 3.3vw;
@ -1176,7 +1629,6 @@
border-radius: 1.2vw;
border: 1rpx solid #5AAEFF;
color: #249BFA;
margin-left: 1vw;
background: linear-gradient(to bottom, #fff, #D1EAFF);
}
}

View File

@ -65,8 +65,9 @@
{{ fontnumber }}
</view>
<view class="unit-image">
<image class="all-home" src="/static/red.png" mode="aspectFit"></image>
<image class="all-home" :src="fonturl?fonturl:'/static/index/indeximage.png'" mode="aspectFit"></image>
</view>
<view class="office" @click="housactive(1)">
<image class="all-home" src="/static/index/warehouse/newindexhome/office.png" mode="aspectFit"></image>
</view>
@ -118,7 +119,7 @@
import { ref, onMounted, reactive, onBeforeUnmount, computed, nextTick } from 'vue';
import { getServiceTree0, getServiceTree1, getServiceTree2 } from '@/pages/NursingNew/component/nurse/api.js'
import { onBackPress, onShow } from "@dcloudio/uni-app"
import { queryPadPageList } from '@/pages/watch/api/lunpan.js'
import { queryPadPageList,queryDepartTreeSync } from '@/pages/watch/api/lunpan.js'
import ZyUpdate from '@/component/zy-upgrade/zy-upgrade.vue'
import exit from "@/component/public/exit.vue"
@ -130,6 +131,7 @@
const exitshow = ref(false);
const morerule = ref(false)
const fontnumber = ref("")
const fonturl = ref("")
const fontSize = computed(() => {
const len = (fontnumber.value || '').length
if (len === 10) return '1.3vw' // 10
@ -144,7 +146,15 @@
leftMenuArray.value = res.result.records;
console.log("????", res)
}))
fontnumber.value = uni.getStorageSync('orgListName')
fontnumber.value = uni.getStorageSync('orgListName');
queryDepartTreeSync().then(res=>{
console.log(res)
if(res.result[0].picUrl){
fonturl.value = uni.getStorageSync('serverUrl') + '/sys/common/static/' + res.result[0].picUrl
}else{
fonturl.value = '';
}
})
});
const filteredMenu = (index : number) => {
return leftMenuArray.value.filter(item => Number(item.areaFlag) - 1 == index);

View File

@ -26,3 +26,11 @@ export const getPermissionList = (params) => {
data: params,
})
}
export const queryDepartTreeSync = (params) => {
return request({
url: `${uni.getStorageSync('serverUrl')}/sys/sysDepart/queryDepartTreeSync`,
method: 'get',
data: params,
})
}