This commit is contained in:
ChenQiuYu 2025-05-06 12:02:29 +08:00
parent e98fc8cca8
commit a961680501
8 changed files with 201 additions and 69 deletions

View File

@ -5,6 +5,7 @@ export enum apiConfig{
"ManagerLogin"="manager/user/login",//登录 "ManagerLogin"="manager/user/login",//登录
"signIn"="sign/in",//签到 "signIn"="sign/in",//签到
"signOut"="sign/out",//签退 "signOut"="sign/out",//签退
"getInfo"="manager/user/verify",//获取用户信息
/** /**
* *
*/ */

View File

@ -85,7 +85,6 @@ const clickFirst = () => {
clickItem(ChargeQueueList.value[0]) clickItem(ChargeQueueList.value[0])
} }
const getOrderList = () => { const getOrderList = () => {
debugger
post("medical/record/getChargeQueue", {query: query.value}).then( post("medical/record/getChargeQueue", {query: query.value}).then(
(res: any) => { (res: any) => {
ChargeQueueList.value = res.list ChargeQueueList.value = res.list

View File

@ -11,8 +11,9 @@
<router-link to="/social" class="menu-item" active-class="active active7">医保</router-link> <router-link to="/social" class="menu-item" active-class="active active7">医保</router-link>
<router-link to="/statistics" class="menu-item" active-class="active active8">统计</router-link> <router-link to="/statistics" class="menu-item" active-class="active active8">统计</router-link>
<router-link to="/settings" class="menu-item" active-class="active active9">设置</router-link> <router-link to="/settings" class="menu-item" active-class="active active9">设置</router-link>
<div class="btn"> <div class="info">
<el-button :icon="Right" style="float: right;color: #fff" @click="logout" text>退出登录</el-button> <span class="username">{{username}}</span>
<el-button class="hover" :icon="Right" style="color: #fff" @click="logout" text>退出登录</el-button>
</div> </div>
</div> </div>
@ -146,12 +147,24 @@ header {
padding: 15px 0; padding: 15px 0;
} }
.btn { .info {
color: #FFF; color: #FFF;
font-size: 18px; font-size: 18px;
float: right; float: right;
margin-right: 24px; display: flex;
margin-top: 10px; align-items: center; //
.username{
display: inline-block;
height: 50px;
line-height: 50px;
}
.hover{
margin-left: 10px;
cursor: pointer;
&:hover{
color: #4d6de4 !important;
}
}
} }
</style> </style>
<script setup lang="ts"> <script setup lang="ts">
@ -159,8 +172,9 @@ import {useRouter} from 'vue-router'
import {type Action, ElMessage, ElMessageBox} from 'element-plus' import {type Action, ElMessage, ElMessageBox} from 'element-plus'
import {apiConfig} from "@/assets/config/apiConfig.ts"; import {apiConfig} from "@/assets/config/apiConfig.ts";
import {post} from "@/utils/request"; import {post} from "@/utils/request";
import {singStatus} from "@/stores/counter.ts";
import {Right} from "@element-plus/icons-vue"; import {Right} from "@element-plus/icons-vue";
import {onMounted,ref} from "vue";
let logout = function () { let logout = function () {
ElMessageBox.confirm( ElMessageBox.confirm(
@ -186,4 +200,13 @@ let logout = function () {
useRouter().push("/") useRouter().push("/")
}) })
} }
onMounted(()=>{
getInfo()
})
const username=ref<any>('')
const getInfo=()=>{
post(apiConfig.getInfo).then((res: any) => {
username.value=res.username
})
}
</script> </script>

View File

@ -24,16 +24,16 @@
<!-- </el-radio-group>--> <!-- </el-radio-group>-->
<!-- </el-form-item>--> <!-- </el-form-item>-->
<!-- </el-descriptions-item>--> <!-- </el-descriptions-item>-->
<el-descriptions-item label=""> <el-descriptions-item label="名">
<el-form-item prop="name"> <el-form-item prop="name">
<el-input v-model="edit_data.name" placeholder="请输入" clearable></el-input> <el-input v-model="edit_data.name" placeholder="请输入名" clearable></el-input>
</el-form-item> </el-form-item>
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item label="性别"> <el-descriptions-item label="性别">
<el-form-item prop="gender"> <el-form-item prop="gender">
<el-radio-group v-model="edit_data.gender"> <el-radio-group v-model="edit_data.gender">
<el-radio value="1"></el-radio> <el-radio :value="1"></el-radio>
<el-radio value="2"></el-radio> <el-radio :value="2"></el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-descriptions-item> </el-descriptions-item>
@ -42,6 +42,21 @@
<el-input v-model.number="edit_data.age" placeholder="请输入年龄"></el-input> <el-input v-model.number="edit_data.age" placeholder="请输入年龄"></el-input>
</el-form-item> </el-form-item>
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item label="科室">
<el-form-item>
<el-select
v-model="edit_data.sectionId"
placeholder="选择科室"
>
<el-option
v-for="item in sectionList"
:key="item.id"
:label="item.name"
:value="item.id"
/>
</el-select>
</el-form-item>
</el-descriptions-item>
<el-descriptions-item label="医生"> <el-descriptions-item label="医生">
<el-form-item prop="organizationDoctorId"> <el-form-item prop="organizationDoctorId">
<el-select <el-select
@ -58,6 +73,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item label="证件类型"> <el-descriptions-item label="证件类型">
<el-form-item prop="certType"> <el-form-item prop="certType">
<el-select v-model="edit_data.certType" placeholder="证件类型"> <el-select v-model="edit_data.certType" placeholder="证件类型">
@ -89,8 +105,19 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item label="备注"> <el-descriptions-item label="待遇状态">
<el-form-item prop="treatmentStatus">
<el-select v-model="edit_data.treatmentStatus" placeholder="待遇状态">
<el-option label="新患者" :value="0"></el-option>
<el-option label="老患者" :value="1"></el-option>
</el-select>
</el-form-item>
</el-descriptions-item>
<el-descriptions-item
label="备注">
<el-form-item>
<el-input v-model="edit_data.memo" placeholder="备注"></el-input> <el-input v-model="edit_data.memo" placeholder="备注"></el-input>
</el-form-item>
</el-descriptions-item> </el-descriptions-item>
</el-descriptions> </el-descriptions>
</el-form> </el-form>
@ -152,6 +179,8 @@ import Mask from "@/components/common/Mask.vue";
import psnCertTypes from "@/assets/config/directory/psnCertTypes.json" import psnCertTypes from "@/assets/config/directory/psnCertTypes.json"
import {getKey} from "@/utils/discrotyUtil.ts"; import {getKey} from "@/utils/discrotyUtil.ts";
import insutypes from "@/assets/config/directory/insutypes.json" import insutypes from "@/assets/config/directory/insutypes.json"
import depts from "@/assets/config/directory/depts.json";
// //
interface Doctor { interface Doctor {
@ -259,6 +288,7 @@ const socialCard: any = ref({
const id = ref<any>(null) const id = ref<any>(null)
const init = () => { const init = () => {
isShow.value = true isShow.value = true
list()
edit_data.value.organizationDoctorId = props.doctorId edit_data.value.organizationDoctorId = props.doctorId
id.value = props.id id.value = props.id
if (id.value) { if (id.value) {
@ -299,10 +329,17 @@ const deleteCard = () => {
const showBtn = ref(false) const showBtn = ref(false)
const showCardBtn = () => { const showCardBtn = () => {
showBtn.value = true showBtn.value = true
} }
const hide = () => { const hide = () => {
showBtn.value = false showBtn.value = false
} }
const sectionList = ref<any>([])
const list = () => {
post('organization/section/allList').then((res: any) => {
sectionList.value = res
})
}
defineExpose({init}) defineExpose({init})
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">

View File

@ -1,35 +1,63 @@
<template> <template>
<el-table :data="props.patientList" @row-click="rowClick"> <div class="patient-list">
<el-table-column prop="createDatetime" label="日期" width="180"> <el-table
:data="props.patientList"
@row-click="rowClick"
style="height: 100%"
>
<el-table-column prop="name" label="姓名" width="180"></el-table-column>
<el-table-column prop="gender" label="性别" width="180">
<template #default="scope"> <template #default="scope">
{{formatDate(scope.row.createDatetime)||'-'}} <img style="width: 25px;height: 25px"
:src="scope.row.gender === 1 ? '/public/static/images/member/man.png' :scope.row.gender === 2 ? '/public/static/images/member/women.png':'无'"
alt="" srcset="">
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="name" label="姓名" width="180"></el-table-column> <el-table-column prop="phone" label="手机号" width="180"></el-table-column>
<el-table-column prop="status" label="状态" width="180">
<template #default="scope">
<el-tag
:type="scope.row.status === 1 ? 'warning' : scope.row.status === 2 ? 'success' : scope.row.status === 3 ? 'info' : 'danger'"
>
{{
scope.row.status === 1 ? '待诊' : scope.row.status === 2 ? '在诊' : scope.row.status === 3 ? '已诊' : '-'
}}
</el-tag>
</template>
</el-table-column>
<el-table-column prop="section_name" label="科室"></el-table-column>
<el-table-column prop="organizationDoctorId" label="医生"> <el-table-column prop="organizationDoctorId" label="医生">
<template #default="scope"> <template #default="scope">
{{roleList.find((item:any)=>item.id===scope.row.organizationDoctorId)?.name||'-'}} {{ roleList.find((item: any) => item.id === scope.row.organizationDoctorId)?.name || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="visitType" label="初|复诊"> <el-table-column prop="visitType" label="初|复诊">
<template #default="scope"> <template #default="scope">
{{visitType[scope.row.visitType]||'-'}} {{ visitType[scope.row.visitType] || '-' }}
</template>
</el-table-column>
<el-table-column prop="createDatetime" label="挂号日期" width="180">
<template #default="scope">
{{ formatDate(scope.row.createDatetime) || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="memo" label="备注"></el-table-column> <el-table-column prop="memo" label="备注"></el-table-column>
</el-table> </el-table>
</div>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import {defineProps, onMounted,ref} from 'vue' import {defineProps, onMounted, ref} from 'vue'
import {formatDate} from "@/utils/dateUtils.ts"; import {formatDate} from "@/utils/dateUtils.ts";
import {post} from "@/utils/request.ts"; import {post} from "@/utils/request.ts";
const props = defineProps({ const props = defineProps({
patientList: { patientList: {
type: Array, type: Array,
default: () => [] default: () => []
} }
}) })
onMounted(()=>{ onMounted(() => {
initDoctor() initDoctor()
}) })
const visitType = ref<any>({ const visitType = ref<any>({
@ -37,20 +65,24 @@ const visitType = ref<any>({
1: '复诊' 1: '复诊'
}) })
const roleList = ref<any>([]) const roleList = ref<any>([])
const initDoctor=()=> { const initDoctor = () => {
let query={ let query = {
keyword: null, keyword: null,
role:1 role: 1
} }
post('organization/member/search',{query:query}).then((res: any) => { post('organization/member/search', {query: query}).then((res: any) => {
roleList.value=res roleList.value = res
}) })
} }
const emit=defineEmits(['rowClick']) const emit = defineEmits(['rowClick'])
const rowClick = (row: any) => { const rowClick = (row: any) => {
emit('rowClick',row) emit('rowClick', row)
} }
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
.patient-list {
width: 100%;
padding: 0 24px;
height: 100%;
}
</style> </style>

View File

@ -12,6 +12,7 @@ import {useWsStore} from "@/stores/wsStore.ts";
const username = ref('') const username = ref('')
const password = ref('') const password = ref('')
const router = useRouter(); const router = useRouter();
const loading = ref(false)
interface NetWorkType { interface NetWorkType {
ip: string, ip: string,
@ -25,6 +26,7 @@ const netWork = ref<NetWorkType>({
const handleLogin = () => { const handleLogin = () => {
loading.value = true
if (netWork.value.mac == "00-00-00-00-00") { if (netWork.value.mac == "00-00-00-00-00") {
// IP使IP // IP使IP
ElMessage({ ElMessage({
@ -33,33 +35,40 @@ const handleLogin = () => {
duration: 1000, duration: 1000,
}) })
} }
post(apiConfig.ManagerLogin, {username: username.value, password: password.value},{catch_error: true}).then((token: any) => {
post(apiConfig.ManagerLogin, {username: username.value, password: password.value}).then((token: any) => {
localStorage.setItem('token', token) localStorage.setItem('token', token)
// success,error // success,error
ElMessage({
message: "登录成功,正在读卡签到,请稍后...",
type: 'success',
duration: 1000,
})
post(apiConfig.signIn, {mac: netWork.value.mac, ip: netWork.value.ip}, {catch_error: true}).then((res: any) => { post(apiConfig.signIn, {mac: netWork.value.mac, ip: netWork.value.ip}, {catch_error: true}).then((res: any) => {
success() success()
}).catch(() => { }).catch(() => {
error() error()
}) })
}).catch(() => {
loading.value = false
}) })
} }
const success = () => { const success = () => {
ElMessage({ loading.value = false
message: "登录成功,即将为您跳转到首页", ElMessageBox.alert('登录成功且签到,即将为您进入到首页', '签到提示', {
type: 'success', type:'success',
duration: 1000, showClose: false,
onClose: () => { callback: (action: Action) => {
router.push("/home/index") router.push("/home/index")
} },
}) })
} }
const error = () => { const error = () => {
ElMessageBox.alert('签到失败,我们将已非签到模式启动系统', '签到提示', { loading.value = false
ElMessageBox.alert('读卡签到失败,我们将以非签到模式启动系统', '签到提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
type:'error',
showClose: false, showClose: false,
callback: (action: Action) => { callback: (action: Action) => {
router.push("/home/index") router.push("/home/index")
@ -105,7 +114,10 @@ const showAuth = () => {
<div class="particle particle-4"></div> <div class="particle particle-4"></div>
</div> </div>
<div class="login-card"> <div class="login-card"
v-loading="loading"
element-loading-text="正在登录,请稍候......"
>
<h1 class="title">欢迎使用药慧精灵</h1> <h1 class="title">欢迎使用药慧精灵</h1>
<div class="input-group"> <div class="input-group">
<i class="fas fa-user input-icon"></i> <i class="fas fa-user input-icon"></i>

View File

@ -205,6 +205,7 @@ watch(() => registerId.value, (newValue) => {
flex: 1; flex: 1;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
min-width: 0;
.case { .case {
background: #FFFFFF; background: #FFFFFF;

View File

@ -17,10 +17,10 @@
<div class="role_list"> <div class="role_list">
<ul> <ul>
<li v-for="(item, index) in roleList" :key="index" <li v-for="(item, index) in roleList" :key="index"
@click="isShowNum=index"> @click="openDialog(item,index)" :class="{active:isShowNum==index}" >
<span class="name">{{ item.name }}</span> <span class="name">{{ item.name }}</span>
<span class="section_name">{{ item.sectionName }}</span> <span class="section_name">{{ item.sectionName }}</span>
<span class="btn" @click="openDialog(item)">挂号</span> <span class="btn">挂号</span>
</li> </li>
</ul> </ul>
</div> </div>
@ -77,7 +77,7 @@ import {formatDate, getToday, formatDateArray} from "@/utils/dateUtils.ts";
import Calendar from "@/components/common/Calendar.vue"; import Calendar from "@/components/common/Calendar.vue";
import Panel from "@/components/common/Panel.vue"; import Panel from "@/components/common/Panel.vue";
const isShowNum = ref(0) const isShowNum = ref(-1)
const roleList = ref<any>([]) const roleList = ref<any>([])
onMounted(() => { onMounted(() => {
@ -129,7 +129,8 @@ const rowClick = (row: any) => {
}) })
} }
const editRef = ref<any>('') const editRef = ref<any>('')
const openDialog = (item: any) => { const openDialog = (item: any,index: any) => {
isShowNum.value=index
doctorId.value = item.id doctorId.value = item.id
nextTick(() => { nextTick(() => {
editRef.value?.init() editRef.value?.init()
@ -171,31 +172,42 @@ const close = () => {
height: 50px; height: 50px;
display: flex; display: flex;
font-size: 14px; font-size: 14px;
justify-content: space-between;
align-items: center;
padding: 0 10px; padding: 0 10px;
border-radius: 5px; border-radius: 5px;
align-items: center;
cursor: pointer;
&:hover {
background: #4D6DE4;
.name { .name {
color: #999; color: #fff;
} }
.section_name { .section_name {
color: #fff;
}
.btn {
color: #fff;
}
}
.name {
color: #999;
width: 100px;
}
.section_name {
flex: 1;
color: #999; color: #999;
} }
.btn { .btn {
width: 50px;
color: #b9b9ba; color: #b9b9ba;
border: 1px solid #b9b9ba;
padding: 5px; padding: 5px;
border-radius: 3px; border-radius: 3px;
cursor: pointer;
&:hover {
color: #fff;
background: #4D6DE4;
}
} }
@ -209,13 +221,28 @@ const close = () => {
margin-top: 10px; margin-top: 10px;
} }
.active {
background: #4D6DE4;
.name {
color: #fff;
}
.section_name {
color: #fff;
}
.btn {
color: #fff;
}
}
} }
.right { .right {
margin-left: 20px; margin-left: 20px;
flex: 1; flex: 1;
height: 100%; height: 100%;
min-width: 0;
.right-content { .right-content {
padding-left: 20px; padding-left: 20px;
display: flex; display: flex;