Merge branch 'zxrapp' into 'master'

Zxrapp

See merge request cxcxt/jeecguniapp!18
This commit is contained in:
张 祥瑞 2025-06-26 09:28:46 +08:00
commit 72c98dba18
7 changed files with 308 additions and 4 deletions

View File

@ -2,7 +2,7 @@ import { http } from '@/utils/http';
//
export function followpersonList(config : object) { // 访
return http({
url: '/Hmcappselect/appselect/Hmcapplist',
@ -10,3 +10,35 @@ export function followpersonList(config : object) { // 获取随访人员信息
data: config
})
}
//
export function addhealthList(config : object) { // 访
return http({
url: '/tbbApp/Tbbapp/applist',
method: 'GET',
data: config
})
}
//
export function addByCld(config : object) { //
return http({
url: '/jksf.tbb/cxcGwjktbTbb/addByCld',
method: 'GET',
data: config
})
}
/*通过id查询数据*/
//
export function queryByIdApi(id : string) {
return http({
url: '/tbbApp/Tbbapp/queryById',
method: 'GET',
data: { id }
})
}

View File

@ -0,0 +1,77 @@
<route lang="json5" type="page">
{
layout: 'default',
style: {
navigationStyle: 'custom',
navigationBarTitleText: '健康随访详情',
},
}
</route>
<template>
<PageLayout navTitle="健康随访详情">
<wd-cell-group v-for="(item, i) in info" :key="i" border>
<wd-cell title="填报内容:" :value="item.tbnr" />
<wd-cell title="是否:" :value="item.sf" />
</wd-cell-group>
</PageLayout>
</template>
<script setup>
import {
useMessage,
useToast
} from 'wot-design-uni'
import {
followpersonList,
addhealthList,
queryByIdApi
} from '@/api/healthfollow/healthfllow'
import {
imgUrl
} from '@/utils/index'
import {
useUserStore
} from '@/store/user'
const message = useMessage()
const toast = useToast()
const userStore = useUserStore();
const info = ref({})
const path = ref([])
const image = ref([])
const resumptiontime = ref(0)
const minDate = ref(0)
const queryById = (e) => {
console.log("3334eeeeeeeeeee--", e)
queryByIdApi(e).then((res) => {
if (res.success) {
info.value = res.result.records
console.log("res---", res.result.records)
}
})
}
// sort
const sortedInfo = computed(() => {
if (info.value && info.value.records) {
return [...info.value.records].sort((a, b) => {
return parseInt(a.sort) - parseInt(b.sort)
})
}
return []
})
onLoad((options) => {
console.log("options---传进来的id--", options)
queryById(options.id)
})
</script>
<style lang="scss" scoped>
.footer {
padding: 12px;
}
</style>

View File

@ -0,0 +1,173 @@
<template>
<PageLayout :navbarShow="false">
<wd-card id="top1">
<wd-row>
<wd-col :span="16">
<wd-datetime-picker type="year-month" v-model="dataValue" label="填报时间" @confirm="getList" id="top1" />
</wd-col>
<wd-col :span="8" style="display: flex; justify-content: center;">
<wd-button @click="clear">重置</wd-button>
</wd-col>
</wd-row>
</wd-card>
<view v-for="(item, i) in list" :key="i" @click="jump(`./HealthDetails?id=${item.id}`)">
<wd-card
:title="item.xm+'的'+item.createTime.substring(0,4)+'年'+item.createTime.substring(5,7)+'月'+'的健康随访填报表'">
<view class="card-content">
<view class="meta-info">
<wd-icon name="usergroup" size="14px" color="#999"></wd-icon>
<text class="meta-text">{{item.depart_dictText}}</text>
<!-- <wd-icon name="time" size="14px" color="#999" style="margin-left: auto;"></wd-icon> -->
<!-- <text class="meta-text">
{{item.ksny}}</text> -->
</view>
</view>
</wd-card>
</view>
</PageLayout>
</template>
<script setup>
import {
useMessage,
useToast
} from 'wot-design-uni'
import SelectDept from '@/components/SelectDept/SelectDept'
import {
followpersonList,
addhealthList
} from '@/api/healthfollow/healthfllow'
const realname = ref('') //
const list = ref([])
const total = ref(0)
const screenHeight = ref(0)
const screenWidth = ref(0)
const tableHeight = ref(0)
const range = ref([]) //
const dataValue = ref(Date.now())
let pageNo = 1
let pageSize = 10
let loading = false
const clear = () => {
dataValue.value = Date.now()
getpersonList();
}
//
const getList = () => {
const date = new Date(dataValue.value);
const year = date.getFullYear();
const month = date.getMonth() + 2;
let monthdate = '';
if(month<10){
monthdate = '0'+month;
}else{
monthdate = month;
}
let params = {
}
console.log("res--按时间查询-params-111-",params)
addhealthList({
// ...params,
cxdata: year + '-' + monthdate,
pageNo,
pageSize
}).then(res => {
console.log("res--按时间查询-222-",res)
if (res.success) {
list.value = res.result.records.map((item, index) => ({
...item, //
}));
total.value = res.result.total
}
})
}
//
const getpersonList = (e)=> {
const date = new Date();
const year = date.getFullYear();
const month = date.getMonth() + 1;
let monthdate = '';
if(month<10){
monthdate = '0'+month;
}else{
monthdate = month;
}
let params = {
// ksny: year + '-' + monthdate +'-01'
}
console.log("res--初始化----params-111-",params)
addhealthList({
// ...params,
cxdata: year + '-' + monthdate,
pageNo,
pageSize
}).then((res) => {
console.log("res--初始化---222--", res)
if (res.success) {
list.value = res.result.records.map((item, index) => ({
...item, //
}));
total.value = res.result.total
}
})
.catch((err) => {
console.log(err);
});
}
/*切换页码*/
const handleChange = ({
value
}) => {
pageNo = value
getpersonList(1)
}
const calculateTableHeight = () => {
const systemInfo = uni.getSystemInfoSync();
screenWidth.value = systemInfo.screenWidth;
screenHeight.value = systemInfo.screenHeight;
// +
const query = uni.createSelectorQuery();
query.select('#top1').boundingClientRect(data => {
const topHeight = data ? data.height : 0;
const navHeight = 88; //
const margin = 20; //
//
tableHeight.value = screenHeight.value - topHeight - navHeight;
}).exec();
}
const jump = (url) => {
uni.navigateTo({
url: url
});
}
onMounted(() => {
getpersonList();
followpersonList();
calculateTableHeight();
//
uni.onWindowResize(() => {
calculateTableHeight();
});
})
onReachBottom(() => {
if (loading) return
queryLeave(1); //1
})
</script>
<style>
</style>

View File

@ -17,9 +17,8 @@
<wd-checkbox v-model="row.checked" @change="handleCheckboxChange(row)"></wd-checkbox>
</template>
</wd-table-col>
<wd-table-col prop="xh" label="序号" align="center" :width="screenWidth / 5"></wd-table-col>
<!-- <wd-table-col prop="dw" label="单位" align="center" :width="screenWidth /5"></wd-table-col> -->
<wd-table-col prop="xm" label="姓名" align="center" :width="screenWidth / 5"></wd-table-col>
<wd-table-col prop="gfxry_dictText" label="疾病类别" align="center" :width="screenWidth /5"></wd-table-col>
<wd-table-col prop="nl" label="年龄" align="center" :width="screenWidth /5"></wd-table-col>
<wd-table-col prop="xb_dictText" label="性别" align="center" :width="screenWidth / 5"></wd-table-col>
</wd-table>
@ -36,7 +35,8 @@
import SelectDept from '@/components/SelectDept/SelectDept'
import {
followpersonList
followpersonList,
addByCld
} from '@/api/healthfollow/healthfllow'
@ -88,6 +88,11 @@
// ldhth
const ldhthValues = selectedData.map(item => item.ldhth).join(',');
console.log('拼接后的 ldhth 值:', ldhthValues);
addByCld({
ldhths:ldhthValues
}).then(res=>{
console.log("res----",res)
})
}

View File

@ -18,6 +18,7 @@
<send></send>
</view>
<view v-if="current === 1">
<lookhealth></lookhealth>
</view>
</view>
</PageLayout>
@ -42,6 +43,7 @@
getEnvBaseUrl
} from '@/utils/index'
import send from './send'
import lookhealth from './lookhealth'
const items = ref(['发送随访信息', '查看随访信息'])
const userStore = useUserStore(); //

View File

@ -489,6 +489,19 @@
"navigationBarTitleText": "健康随访"
}
},
{
"path": "healthfollow/HealthDetails",
"type": "page",
"layout": "default",
"style": {
"navigationStyle": "custom",
"navigationBarTitleText": "健康随访详情"
}
},
{
"path": "healthfollow/lookhealth",
"type": "page"
},
{
"path": "healthfollow/send",
"type": "page"

View File

@ -54,6 +54,8 @@ interface NavigateToOptions {
"/pages-integrated/duty/index" |
"/pages-politics/health/add" |
"/pages-politics/health/followup" |
"/pages-politics/healthfollow/HealthDetails" |
"/pages-politics/healthfollow/lookhealth" |
"/pages-politics/healthfollow/send" |
"/pages-politics/healthfollow/sendmessage" |
"/pages-process/approvalTabbar" |