健康填报
This commit is contained in:
parent
f397dc0f5f
commit
5ae2c91ac1
21
src/api/politics/health.ts
Normal file
21
src/api/politics/health.ts
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
import { http } from '@/utils/http';
|
||||||
|
|
||||||
|
// 健康数据提交API
|
||||||
|
export function addApi(data : Object) {
|
||||||
|
return http({
|
||||||
|
url: '/cxcGwjktb/cxcGwjktb/addData',
|
||||||
|
method: 'POST',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 判断是否是三级高血压人员
|
||||||
|
export function queryIf3rdGxyApi(ldhth : string) { // 根据username获取职位名称和审批领导列表
|
||||||
|
return http({
|
||||||
|
url: '/cxcGwjktbHmc/cxcGwjktbHmc/queryIf3rdGxy',
|
||||||
|
method: 'GET',
|
||||||
|
data: {
|
||||||
|
ldhth
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
159
src/pages-politics/health/add.vue
Normal file
159
src/pages-politics/health/add.vue
Normal file
@ -0,0 +1,159 @@
|
|||||||
|
<route lang="json5" type="page">
|
||||||
|
{
|
||||||
|
layout: 'default',
|
||||||
|
style: {
|
||||||
|
navigationStyle: 'custom',
|
||||||
|
navigationBarTitleText: '健康填报',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</route>
|
||||||
|
<template>
|
||||||
|
<PageLayout navTitle="健康填报">
|
||||||
|
<view class="form-container">
|
||||||
|
<wd-form ref="form" :model="model">
|
||||||
|
<!-- 血压数据卡片 -->
|
||||||
|
<view class="card">
|
||||||
|
<wd-cell-group title="血压数据">
|
||||||
|
<wd-input type="number" label="高压值(mmHg)" prop="gyz" v-model="model.gyz" label-width="200px"
|
||||||
|
:rules="[{ required: true, message: '请输入高压值' }]" />
|
||||||
|
<wd-input type="number" label="低压值(mmHg)" prop="dyz" v-model="model.dyz" label-width="200px"
|
||||||
|
:rules="[{ required: true, message: '请输入低压值' }]" />
|
||||||
|
</wd-cell-group>
|
||||||
|
</view>
|
||||||
|
<!-- 健康指标卡片 -->
|
||||||
|
<view class="card">
|
||||||
|
<wd-cell-group title="健康指标">
|
||||||
|
<wd-input type="number" label="心率(次/分)" prop="xl" v-model="model.xl" label-width="200px"
|
||||||
|
:rules="[{ required: true, message: '请输入心率' }]" />
|
||||||
|
<wd-input type="number" label="血糖值(mmol/L)" prop="xtz" v-model="model.xtz" label-width="200px"
|
||||||
|
:rules="[{ required: true, message: '请输入血糖值' }]" />
|
||||||
|
<wd-input type="number" label="体重(kg)" prop="tz" v-model="model.tz" label-width="200px"
|
||||||
|
:rules="[{ required: true, message: '请输入体重' }]" />
|
||||||
|
</wd-cell-group>
|
||||||
|
</view>
|
||||||
|
<!-- 其他信息卡片 -->
|
||||||
|
<view class="card">
|
||||||
|
<wd-cell-group title="其他信息">
|
||||||
|
<wd-input label="当前位置" prop="wzzb" v-model="model.wzzb" label-width="200px" />
|
||||||
|
<wd-cell title="附件" prop="path" title-width="200px">
|
||||||
|
<wd-upload :accept="accept" v-model:file-list="model.path" :action="uploadUrl"
|
||||||
|
multiple></wd-upload>
|
||||||
|
</wd-cell>
|
||||||
|
</wd-cell-group>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<!-- 提交按钮 -->
|
||||||
|
<view class="footer">
|
||||||
|
<wd-button type="primary" size="large" @click="handleSubmit" block>
|
||||||
|
提交健康数据
|
||||||
|
</wd-button>
|
||||||
|
</view>
|
||||||
|
</wd-form>
|
||||||
|
</view>
|
||||||
|
</PageLayout>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
import {
|
||||||
|
useMessage,
|
||||||
|
useToast
|
||||||
|
} from 'wot-design-uni'
|
||||||
|
import {
|
||||||
|
useAppStore
|
||||||
|
} from '@/store';
|
||||||
|
import {
|
||||||
|
useUserStore
|
||||||
|
} from '@/store/user';
|
||||||
|
import {
|
||||||
|
addApi,
|
||||||
|
queryIf3rdGxyApi
|
||||||
|
} from '@/api/politics/health'
|
||||||
|
import {
|
||||||
|
getEnvBaseUrl
|
||||||
|
} from '@/utils/index'
|
||||||
|
|
||||||
|
const message = useMessage()
|
||||||
|
const toast = useToast()
|
||||||
|
const appStore = useAppStore();
|
||||||
|
const userStore = useUserStore(); //登录人信息
|
||||||
|
const form = ref()
|
||||||
|
const model = reactive({
|
||||||
|
gyz: '', // 高压值
|
||||||
|
dyz: '', // 低压值
|
||||||
|
xl: '', // 心率
|
||||||
|
xtz: '', // 血糖值
|
||||||
|
tz: '', // 体重
|
||||||
|
wzzb: appStore.location, // 位置坐标
|
||||||
|
path: [] // 附件
|
||||||
|
})
|
||||||
|
const accept = ref('image')
|
||||||
|
const uploadUrl = ref(getEnvBaseUrl() + '/sys/common/upload?appPath=健康填报/' + userStore.userInfo.department + '/' +
|
||||||
|
userStore.userInfo.realname)
|
||||||
|
|
||||||
|
const handleSubmit = () => {
|
||||||
|
form.value.validate().then(({
|
||||||
|
valid,
|
||||||
|
errors
|
||||||
|
}) => {
|
||||||
|
if (valid) {
|
||||||
|
const submitData = {
|
||||||
|
...model,
|
||||||
|
path: model.path.map(item => {
|
||||||
|
const response = JSON.parse(item.response);
|
||||||
|
return response.message;
|
||||||
|
}).join(',')
|
||||||
|
}
|
||||||
|
message
|
||||||
|
.confirm({
|
||||||
|
msg: '确认提交健康数据?',
|
||||||
|
title: '提示',
|
||||||
|
})
|
||||||
|
.then(() => {
|
||||||
|
addApi(submitData).then(res => {
|
||||||
|
if (res.success) {
|
||||||
|
toast.success(res.message)
|
||||||
|
} else {
|
||||||
|
toast.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
.catch(() => {})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const if3rdGxy = () => {
|
||||||
|
/**获取当前用户是否是三级高血压,是需要上传视频,否可以上传图片*/
|
||||||
|
queryIf3rdGxyApi(userStore.userInfo.workNo).then(res => {
|
||||||
|
if (res) {
|
||||||
|
accept.value = 'video';
|
||||||
|
} else {
|
||||||
|
accept.value = 'image';
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
onLoad(() => {
|
||||||
|
if3rdGxy()
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.form-container {
|
||||||
|
padding: 20rpx;
|
||||||
|
background-color: #f5f7fa;
|
||||||
|
min-height: 100vh;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card {
|
||||||
|
background: #ffffff;
|
||||||
|
border-radius: 16rpx;
|
||||||
|
box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.05);
|
||||||
|
margin-bottom: 30rpx;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer {
|
||||||
|
padding: 40rpx 0;
|
||||||
|
}
|
||||||
|
</style>
|
@ -102,7 +102,7 @@
|
|||||||
console.log(11)
|
console.log(11)
|
||||||
//办理任务,直接进入办理页面
|
//办理任务,直接进入办理页面
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url:`/pages/process/taskHandle?data=${JSON.stringify(item)}`
|
url:`/pages-process/taskHandle?data=${JSON.stringify(item)}`
|
||||||
})
|
})
|
||||||
}else{
|
}else{
|
||||||
message
|
message
|
@ -130,24 +130,6 @@
|
|||||||
"navigationBarTitleText": "H5在线预览"
|
"navigationBarTitleText": "H5在线预览"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"path": "pages/process/approvalTabbar",
|
|
||||||
"type": "page",
|
|
||||||
"layout": "default",
|
|
||||||
"style": {
|
|
||||||
"navigationStyle": "custom",
|
|
||||||
"navigationBarTitleText": "流程审批导航"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"path": "pages/process/taskHandle",
|
|
||||||
"type": "page",
|
|
||||||
"layout": "default",
|
|
||||||
"style": {
|
|
||||||
"navigationStyle": "custom",
|
|
||||||
"navigationBarTitleText": "任务处理"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"path": "pages/user/people",
|
"path": "pages/user/people",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
@ -346,7 +328,7 @@
|
|||||||
"root": "pages-humanResource",
|
"root": "pages-humanResource",
|
||||||
"pages": [
|
"pages": [
|
||||||
{
|
{
|
||||||
"path": "absence/apply",
|
"path": "absence/add",
|
||||||
"type": "page",
|
"type": "page",
|
||||||
"layout": "default",
|
"layout": "default",
|
||||||
"style": {
|
"style": {
|
||||||
@ -374,9 +356,42 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"root": "pages-politics",
|
||||||
|
"pages": [
|
||||||
|
{
|
||||||
|
"path": "health/add",
|
||||||
|
"type": "page",
|
||||||
|
"layout": "default",
|
||||||
|
"style": {
|
||||||
|
"navigationStyle": "custom",
|
||||||
|
"navigationBarTitleText": "健康填报"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"root": "pages-process",
|
"root": "pages-process",
|
||||||
"pages": []
|
"pages": [
|
||||||
|
{
|
||||||
|
"path": "approvalTabbar",
|
||||||
|
"type": "page",
|
||||||
|
"layout": "default",
|
||||||
|
"style": {
|
||||||
|
"navigationStyle": "custom",
|
||||||
|
"navigationBarTitleText": "流程审批导航"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "taskHandle",
|
||||||
|
"type": "page",
|
||||||
|
"layout": "default",
|
||||||
|
"style": {
|
||||||
|
"navigationStyle": "custom",
|
||||||
|
"navigationBarTitleText": "任务处理"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
@ -107,7 +107,7 @@
|
|||||||
|
|
||||||
const goToProcess = ()=>{
|
const goToProcess = ()=>{
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/process/approvalTabbar'
|
url: '/pages-process/approvalTabbar'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,45 +0,0 @@
|
|||||||
<route lang="json5" type="page">
|
|
||||||
{
|
|
||||||
layout: 'default',
|
|
||||||
style: {
|
|
||||||
navigationStyle: 'custom',
|
|
||||||
navigationBarTitleText: '流程审批导航',
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</route>
|
|
||||||
<template>
|
|
||||||
<PageLayout nav-title="运行流程" >
|
|
||||||
<wd-tabs v-model="tab" swipeable color="#39b54a" autoLineWidth>
|
|
||||||
<wd-tab title="我的任务">
|
|
||||||
<myTask></myTask>
|
|
||||||
</wd-tab>
|
|
||||||
<wd-tab title="历史任务">
|
|
||||||
<view class="content">内容1</view>
|
|
||||||
</wd-tab>
|
|
||||||
</wd-tabs>
|
|
||||||
</PageLayout>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
import {
|
|
||||||
useAppStore
|
|
||||||
} from '@/store'
|
|
||||||
import {
|
|
||||||
ref
|
|
||||||
} from 'vue'
|
|
||||||
import {
|
|
||||||
onLoad,
|
|
||||||
onShow
|
|
||||||
} from '@dcloudio/uni-app';
|
|
||||||
import myTask from './components/myTask.vue'
|
|
||||||
const appStore = useAppStore();
|
|
||||||
const tab = ref(0)
|
|
||||||
|
|
||||||
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped lang="scss">
|
|
||||||
::v-deep .wd-tabs__line{
|
|
||||||
background: #39b54a;
|
|
||||||
}
|
|
||||||
</style>
|
|
@ -1,170 +0,0 @@
|
|||||||
<template>
|
|
||||||
|
|
||||||
<view class="container">
|
|
||||||
<wd-loading v-if="loading && pageNo === 1" class="loading-tip">加载中...</wd-loading>
|
|
||||||
<template v-for="(item, i) in list" :key="i">
|
|
||||||
<wd-card :title="item.bpmBizTitle" title-bold border-radius="8" use-footer-slot @click="goToPage(item)">
|
|
||||||
<view class="card-content">
|
|
||||||
<wd-row style="color: #666666;">
|
|
||||||
<wd-col :span="4">
|
|
||||||
<text>当前环节:</text>
|
|
||||||
</wd-col>
|
|
||||||
<wd-col :span="20">
|
|
||||||
{{item.taskName}}
|
|
||||||
</wd-col>
|
|
||||||
</wd-row>
|
|
||||||
<wd-row style="padding-bottom: 2px;color: #666666;">
|
|
||||||
<wd-col :span="4">
|
|
||||||
<text>流程名称:</text>
|
|
||||||
</wd-col>
|
|
||||||
<wd-col :span="20">
|
|
||||||
{{item.processDefinitionName}}
|
|
||||||
</wd-col>
|
|
||||||
</wd-row>
|
|
||||||
<view class="meta-info">
|
|
||||||
<wd-icon name="time" size="14px" color="#999"></wd-icon>
|
|
||||||
<text class="meta-text">{{item.taskBeginTime?item.taskBeginTime.substring(0,10):''}}</text>
|
|
||||||
<wd-icon name="user" size="14px" color="#999" style="margin-left: auto;"></wd-icon>
|
|
||||||
<text class="meta-text">{{item.processApplyUserName}}</text>
|
|
||||||
</view>
|
|
||||||
<wd-row style="padding-top: 10px;">
|
|
||||||
<view v-if="item.taskAssigneeName&&item.taskAssigneeName!=''">
|
|
||||||
<wd-col :span="16">
|
|
||||||
<wd-button>办理</wd-button>
|
|
||||||
</wd-col>
|
|
||||||
<wd-col :span="8">
|
|
||||||
<wd-button>委托</wd-button>
|
|
||||||
</wd-col>
|
|
||||||
</view>
|
|
||||||
<view v-else>
|
|
||||||
<wd-col :span="12">
|
|
||||||
<wd-button @click="goToPage(item)">签收</wd-button>
|
|
||||||
</wd-col>
|
|
||||||
<wd-col :span="12">
|
|
||||||
</wd-col>
|
|
||||||
</view>
|
|
||||||
</wd-row>
|
|
||||||
</view>
|
|
||||||
</wd-card>
|
|
||||||
</template>
|
|
||||||
<view class="load-more" v-if="loading && pageNo > 1">
|
|
||||||
<wd-loading size="16px">正在加载...</wd-loading>
|
|
||||||
</view>
|
|
||||||
<wd-message-box></wd-message-box>
|
|
||||||
</view>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
import { taskListApi,claim } from '@/api/process'
|
|
||||||
import {
|
|
||||||
ref
|
|
||||||
} from 'vue'
|
|
||||||
import {
|
|
||||||
onLoad,
|
|
||||||
onShow,
|
|
||||||
onReachBottom,
|
|
||||||
onPullDownRefresh
|
|
||||||
} from '@dcloudio/uni-app';
|
|
||||||
import { useToast, useMessage } from 'wot-design-uni'
|
|
||||||
defineOptions({
|
|
||||||
name: 'myTask',
|
|
||||||
options: {
|
|
||||||
styleIsolation: 'shared',
|
|
||||||
},
|
|
||||||
})
|
|
||||||
const toast = useToast()
|
|
||||||
const message = useMessage()
|
|
||||||
let pageNo = 1
|
|
||||||
let pageSize = 10
|
|
||||||
let loading = false
|
|
||||||
const list = ref([])
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const getList = () => {
|
|
||||||
taskListApi({
|
|
||||||
pageNo,
|
|
||||||
pageSize
|
|
||||||
}).then((res) => {
|
|
||||||
console.log(res)
|
|
||||||
if (res.success) {
|
|
||||||
list.value = [...list.value,...res.result.records];
|
|
||||||
}
|
|
||||||
loading = false
|
|
||||||
}).catch((err) => {
|
|
||||||
loading = false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
const goToPage = (item)=>{
|
|
||||||
//判断是否是签收项目,提示是否签收
|
|
||||||
if(item.taskAssigneeName&&item.taskAssigneeName!=''){
|
|
||||||
console.log(11)
|
|
||||||
//办理任务,直接进入办理页面
|
|
||||||
uni.navigateTo({
|
|
||||||
url:`/pages/process/taskHandle?data=${JSON.stringify(item)}`
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
message
|
|
||||||
.confirm({
|
|
||||||
msg: '是否签收该任务?',
|
|
||||||
title: '确认签收吗',
|
|
||||||
})
|
|
||||||
.then(() => {
|
|
||||||
claim({taskId:item.id}).then(()=>{
|
|
||||||
uni.redirectTo({
|
|
||||||
url: './approvalTabbar'
|
|
||||||
});
|
|
||||||
})
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
onReachBottom(() => {
|
|
||||||
if (loading) return
|
|
||||||
pageNo++
|
|
||||||
getList()
|
|
||||||
})
|
|
||||||
|
|
||||||
onPullDownRefresh(() => {
|
|
||||||
pageNo = 1
|
|
||||||
list.value = []
|
|
||||||
getList()
|
|
||||||
uni.stopPullDownRefresh()
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
onShow(() => {
|
|
||||||
list.value = []
|
|
||||||
pageNo = 1
|
|
||||||
pageSize = 10
|
|
||||||
loading = false
|
|
||||||
getList()
|
|
||||||
})
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.container {
|
|
||||||
padding: 5px 0 5px;
|
|
||||||
min-height: 100vh;
|
|
||||||
background-color: #f7f7f7;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-content {
|
|
||||||
padding: 8px 0;
|
|
||||||
|
|
||||||
.meta-info {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
font-size: 12px;
|
|
||||||
color: #666;
|
|
||||||
|
|
||||||
.meta-text {
|
|
||||||
margin-left: 4px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
::v-deep .wd-card__title-content{
|
|
||||||
border-bottom: 1px solid #efefef;
|
|
||||||
}
|
|
||||||
</style>
|
|
@ -1,98 +0,0 @@
|
|||||||
<route lang="json5" type="page">
|
|
||||||
{
|
|
||||||
layout: 'default',
|
|
||||||
style: {
|
|
||||||
navigationStyle: 'custom',
|
|
||||||
navigationBarTitleText: '任务处理',
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</route>
|
|
||||||
<template>
|
|
||||||
<PageLayout nav-title="流程办理">
|
|
||||||
<wd-tabs v-model="tab" swipeable color="#39b54a" autoLineWidth>
|
|
||||||
<wd-tab title="单据">
|
|
||||||
</wd-tab>
|
|
||||||
<wd-tab title="任务处理">
|
|
||||||
<view class="content">内容2</view>
|
|
||||||
</wd-tab>
|
|
||||||
<wd-tab title="流程图">
|
|
||||||
<img :src="imgPath" style="border:2px;cursor:hand;" alt="流程图" usemap="#planetmap">
|
|
||||||
</wd-tab>
|
|
||||||
</wd-tabs>
|
|
||||||
</PageLayout>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
import {
|
|
||||||
ref
|
|
||||||
} from 'vue'
|
|
||||||
import {
|
|
||||||
onLoad,
|
|
||||||
onShow,
|
|
||||||
onReachBottom,
|
|
||||||
onPullDownRefresh
|
|
||||||
} from '@dcloudio/uni-app';
|
|
||||||
import { useToast, useMessage } from 'wot-design-uni'
|
|
||||||
import {
|
|
||||||
useAppStore
|
|
||||||
} from '@/store'
|
|
||||||
import {
|
|
||||||
getProcessNodeInfo,
|
|
||||||
getHisProcessNodeInfo
|
|
||||||
} from '@/api/process'
|
|
||||||
import {
|
|
||||||
getEnvBaseUrl
|
|
||||||
} from '@/utils/index'
|
|
||||||
import { json } from 'stream/consumers';
|
|
||||||
|
|
||||||
const formData = ref({})
|
|
||||||
const path = ref('') //url路径
|
|
||||||
const appStore = useAppStore();
|
|
||||||
const tab = ref(0)
|
|
||||||
|
|
||||||
|
|
||||||
const handleClickLeft = () => {
|
|
||||||
uni.navigateBack()
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
onLoad((options) => {
|
|
||||||
let useData = JSON.parse(options.data);
|
|
||||||
console.log(123)
|
|
||||||
getProcessNodeInfo({taskId:useData.id}).then(res=>{
|
|
||||||
console.log(res)
|
|
||||||
if(res.success){
|
|
||||||
let data = {
|
|
||||||
dataId:res.result.dataId,
|
|
||||||
taskId:useData.id,
|
|
||||||
taskDefKey:useData.taskId,
|
|
||||||
procInsId:useData.processInstanceId,
|
|
||||||
tableName:res.result.tableName,
|
|
||||||
permissionList:res.result.permissionList,
|
|
||||||
vars:res.result.records
|
|
||||||
}
|
|
||||||
formData.value = data;//流程信息
|
|
||||||
|
|
||||||
let tempFormUrl = res.result.formUrlMobile;
|
|
||||||
|
|
||||||
path.value = tempFormUrl; //url路径
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
|
||||||
|
|
||||||
const imgPath = () => {
|
|
||||||
var params = JSON.stringify({
|
|
||||||
'processInstanceId': formData.procInsId
|
|
||||||
})
|
|
||||||
let url = `${getEnvBaseUrl()}/act/task/traceImage?${params}`;
|
|
||||||
console.log(url)
|
|
||||||
return url;
|
|
||||||
}
|
|
||||||
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
::v-deep .wd-tabs__line{
|
|
||||||
background: #39b54a;
|
|
||||||
}
|
|
||||||
</style>
|
|
9
src/types/uni-pages.d.ts
vendored
9
src/types/uni-pages.d.ts
vendored
@ -13,8 +13,6 @@ interface NavigateToOptions {
|
|||||||
"/pages/onlinePreview/detail" |
|
"/pages/onlinePreview/detail" |
|
||||||
"/pages/onlinePreview/onlinePreview" |
|
"/pages/onlinePreview/onlinePreview" |
|
||||||
"/pages/onlinePreview/onlinePreviewH5" |
|
"/pages/onlinePreview/onlinePreviewH5" |
|
||||||
"/pages/process/approvalTabbar" |
|
|
||||||
"/pages/process/taskHandle" |
|
|
||||||
"/pages/user/people" |
|
"/pages/user/people" |
|
||||||
"/pages/workHome/index" |
|
"/pages/workHome/index" |
|
||||||
"/pages-home/home/home" |
|
"/pages-home/home/home" |
|
||||||
@ -33,9 +31,12 @@ interface NavigateToOptions {
|
|||||||
"/pages-operate/file/detail" |
|
"/pages-operate/file/detail" |
|
||||||
"/pages-operate/file/index" |
|
"/pages-operate/file/index" |
|
||||||
"/pages-operate/sc/index" |
|
"/pages-operate/sc/index" |
|
||||||
"/pages-humanResource/absence/apply" |
|
"/pages-humanResource/absence/add" |
|
||||||
"/pages-humanResource/absence/index" |
|
"/pages-humanResource/absence/index" |
|
||||||
"/pages-integrated/duty/index";
|
"/pages-integrated/duty/index" |
|
||||||
|
"/pages-politics/health/add" |
|
||||||
|
"/pages-process/approvalTabbar" |
|
||||||
|
"/pages-process/taskHandle";
|
||||||
}
|
}
|
||||||
interface RedirectToOptions extends NavigateToOptions {}
|
interface RedirectToOptions extends NavigateToOptions {}
|
||||||
|
|
||||||
|
@ -343,29 +343,29 @@ export const getLocation = () => {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
fail: function (err) {
|
fail: function (err) {
|
||||||
uni.showToast({
|
// uni.showToast({
|
||||||
title: '位置解析失败',
|
// title: '位置解析失败',
|
||||||
icon: 'error'
|
// icon: 'error'
|
||||||
})
|
// })
|
||||||
handleDefaultLocation()
|
handleDefaultLocation()
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
fail: function (err) {
|
fail: function (err) {
|
||||||
// 根据不同错误码处理
|
// 根据不同错误码处理
|
||||||
if (err.errCode === 2 || err.errCode === 12) {
|
// if (err.errCode === 2 || err.errCode === 12) {
|
||||||
// 2: 位置服务不可用, 12: 定位权限未开启
|
// // 2: 位置服务不可用, 12: 定位权限未开启
|
||||||
uni.showToast({
|
// uni.showToast({
|
||||||
title: '请开启定位服务',
|
// title: '请开启定位服务',
|
||||||
icon: 'error'
|
// icon: 'error'
|
||||||
})
|
// })
|
||||||
|
|
||||||
} else {
|
// } else {
|
||||||
uni.showToast({
|
// uni.showToast({
|
||||||
title: '定位获取失败',
|
// title: '定位获取失败',
|
||||||
icon: 'error'
|
// icon: 'error'
|
||||||
})
|
// })
|
||||||
}
|
// }
|
||||||
handleDefaultLocation()
|
handleDefaultLocation()
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -388,7 +388,7 @@ function handleDefaultLocation() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function weatherRequest(params : { lat ?: string; lon ?: string; q ?: string }) {
|
function weatherRequest(params : { lat ?: number; lon ?: number; q ?: string }) {
|
||||||
const store = useAppStore()
|
const store = useAppStore()
|
||||||
uni.request({
|
uni.request({
|
||||||
url: 'https://api.openweathermap.org/data/2.5/weather',
|
url: 'https://api.openweathermap.org/data/2.5/weather',
|
||||||
@ -407,17 +407,17 @@ function weatherRequest(params : { lat ?: string; lon ?: string; q ?: string })
|
|||||||
res.data.weather[0].icon
|
res.data.weather[0].icon
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
uni.showToast({
|
// uni.showToast({
|
||||||
title: '天气数据格式错误',
|
// title: '天气数据格式错误',
|
||||||
icon: 'error'
|
// icon: 'error'
|
||||||
})
|
// })
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
fail: function () {
|
// fail: function () {
|
||||||
uni.showToast({
|
// uni.showToast({
|
||||||
title: '天气获取失败',
|
// title: '天气获取失败',
|
||||||
icon: 'error'
|
// icon: 'error'
|
||||||
})
|
// })
|
||||||
}
|
// }
|
||||||
});
|
});
|
||||||
}
|
}
|
@ -68,6 +68,7 @@ export default ({ command, mode }) => {
|
|||||||
'src/pages-operate',
|
'src/pages-operate',
|
||||||
'src/pages-humanResource',
|
'src/pages-humanResource',
|
||||||
'src/pages-integrated',
|
'src/pages-integrated',
|
||||||
|
'src/pages-politics',
|
||||||
'src/pages-process',
|
'src/pages-process',
|
||||||
], // 是个数组,可以配置多个,但是不能为pages里面的目录
|
], // 是个数组,可以配置多个,但是不能为pages里面的目录
|
||||||
dts: 'src/types/uni-pages.d.ts',
|
dts: 'src/types/uni-pages.d.ts',
|
||||||
|
Loading…
Reference in New Issue
Block a user