Merge remote-tracking branch 'origin/main'
This commit is contained in:
commit
255dbc15c0
|
|
@ -4,7 +4,7 @@
|
|||
<meta charset="UTF-8">
|
||||
<link rel="icon" href="/favicon.ico">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Vite App</title>
|
||||
<title>药慧精灵智慧诊所</title>
|
||||
</head>
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
|
|
|
|||
Binary file not shown.
|
Before Width: | Height: | Size: 126 KiB After Width: | Height: | Size: 239 KiB |
|
|
@ -3,7 +3,8 @@ export enum apiConfig{
|
|||
* 用户操作
|
||||
*/
|
||||
"ManagerLogin"="manager/user/login",//登录
|
||||
"signUp"="signUp/signUp",//签到
|
||||
"signIn"="sign/in",//签到
|
||||
"signOut"="sign/out",//签退
|
||||
/**
|
||||
* 接诊操作
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -11,8 +11,10 @@
|
|||
<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="/settings" class="menu-item" active-class="active active9">设置</router-link>
|
||||
<div style="float: right;color: #fff">
|
||||
<el-button style="float: right;color: #fff" @click="logout" type="text">退出登录</el-button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
|
@ -147,13 +149,22 @@ header {
|
|||
<script setup lang="ts">
|
||||
import {useRouter} from 'vue-router'
|
||||
import {ElMessage} from 'element-plus'
|
||||
import {apiConfig} from "@/assets/config/apiConfig.ts";
|
||||
import {post} from "@/utils/request";
|
||||
import {singStatus} from "@/stores/counter.ts";
|
||||
|
||||
let logout = function () {
|
||||
localStorage.removeItem('token')
|
||||
useRouter().push("/manager/login")
|
||||
ElMessage({
|
||||
message: "退出成功,即将为您跳转到登录页面",
|
||||
message: "退出成功并退出签到,即将为您跳转到登录页面",
|
||||
type: 'success',
|
||||
duration: 1000,
|
||||
onClose: () => {
|
||||
post(apiConfig.signOut).then((res: any) => {
|
||||
useRouter().push("/manager/login")
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
const status = singStatus()
|
||||
</script>
|
||||
|
|
|
|||
|
|
@ -73,6 +73,7 @@ const closeBtn = () => {
|
|||
position: relative;
|
||||
height: 72px;
|
||||
padding: 0 4px;
|
||||
border-bottom: 1px solid #EAEAEC;
|
||||
|
||||
.title {
|
||||
position: absolute;
|
||||
|
|
|
|||
|
|
@ -1,38 +1,46 @@
|
|||
<template>
|
||||
<div class="edit-panel" v-loading="isLoading" element-loading-text="正在保存......">
|
||||
<div class="top">
|
||||
<el-form :model="inventory_order_data" :rules="formRules" ref="orderForm">
|
||||
<el-descriptions title="采购订单" border>
|
||||
<el-descriptions-item label="订单编号">
|
||||
<el-form :model="inventory_order_data" label-position="top" :rules="formRules" ref="orderForm">
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="订单编号">
|
||||
<div style="width: 234px;">
|
||||
{{ inventory_order_data.code != null ? inventory_order_data.code : "创建后自动生成" }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="采购人">
|
||||
<el-input disabled v-model="userInfo.name"></el-input>
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="采购日期">
|
||||
<el-form-item prop="purchaseDate" :label="''" :rules="formRules.purchaseDate">
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="采购人">
|
||||
<el-input style="width: 234px;" disabled v-model="userInfo.name"></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item prop="purchaseDate" label="采购日期" :rules="formRules.purchaseDate">
|
||||
<el-date-picker
|
||||
v-model="inventory_order_data.purchaseDate"
|
||||
type="date"
|
||||
placeholder="选择一个创建日期"
|
||||
size="default"
|
||||
style="width: 234px;"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="货单号">
|
||||
<el-form-item prop="shippingCode" :label="''" :rules="formRules.shippingCode">
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item prop="shippingCode" label="货单号" :rules="formRules.shippingCode">
|
||||
<el-input v-model="inventory_order_data.shippingCode"></el-input>
|
||||
</el-form-item>
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="发票号">
|
||||
<el-form-item prop="invoiceCode">
|
||||
<el-input v-model="inventory_order_data.invoiceCode"></el-input>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item prop="invoiceCode" label="发票号">
|
||||
<el-input style="width: 234px;" v-model="inventory_order_data.invoiceCode"></el-input>
|
||||
</el-form-item>
|
||||
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="供应商">
|
||||
<el-form-item prop="supplierId" :label="''" :rules="formRules.supplierId">
|
||||
<el-select v-model="inventory_order_data.supplierId" placeholder="请选择供应商" style="width:300px">
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item prop="supplierId" label="供应商" :rules="formRules.supplierId">
|
||||
<el-select style="width: 234px;" v-model="inventory_order_data.supplierId" placeholder="请选择供应商">
|
||||
<el-option
|
||||
v-for="item in supplier_list"
|
||||
:key="item.id"
|
||||
|
|
@ -41,15 +49,23 @@
|
|||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="备注">
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="备注" :rules="formRules.purchaseDate">
|
||||
<el-input v-model="inventory_order_data.remark"/>
|
||||
</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
</div>
|
||||
<GoodsSearch @selectCallBack="goodsSelectCallBack"></GoodsSearch>
|
||||
<div class="table_content">
|
||||
<div class="add_goods">
|
||||
<span>添加商品</span>
|
||||
<div class="search">
|
||||
<GoodsSearch @selectCallBack="goodsSelectCallBack"></GoodsSearch>
|
||||
<el-button :icon="Search" type="primary">搜索</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<el-table :data="table_list" style="width: 100%" height="300" max-height="550">
|
||||
<el-table-column prop="name" label="药品名称" width="180" show-overflow-tooltip/>
|
||||
<el-table-column label="售价" prop="unitPrice" width="80">
|
||||
|
|
@ -147,7 +163,7 @@ import Edit from "@/components/inventory/goods/Edit.vue";
|
|||
import Mask from "@/components/common/Mask.vue";
|
||||
import {ElMessage} from "element-plus";
|
||||
import GoodsSearch from "@/components/inventory/GoodsSearch.vue";
|
||||
import CloseBtn from "@/components/CloseBtn.vue";
|
||||
import {Search} from "@element-plus/icons-vue";
|
||||
|
||||
const orderForm = ref()
|
||||
const formRules = ref({
|
||||
|
|
@ -387,4 +403,24 @@ onMounted(() => {
|
|||
.error {
|
||||
background-color: #F00;
|
||||
}
|
||||
.edit-panel{
|
||||
margin-top: 24px;
|
||||
}
|
||||
.table_content{
|
||||
margin-top: 24px;
|
||||
background: #F9FAFC;
|
||||
.add_goods{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
font-weight: 800;
|
||||
font-size: 18px;
|
||||
color: #333333;
|
||||
font-style: normal;
|
||||
.search{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,7 +1,6 @@
|
|||
<template>
|
||||
<el-form :model="form" label-width="auto">
|
||||
<el-descriptions
|
||||
:title="props.id?'编辑' : '新增'"
|
||||
:column="4"
|
||||
direction="vertical"
|
||||
border
|
||||
|
|
|
|||
|
|
@ -1,12 +1,10 @@
|
|||
import { ref, computed } from 'vue'
|
||||
import { defineStore } from 'pinia'
|
||||
|
||||
export const useCounterStore = defineStore('counter', () => {
|
||||
const count = ref(0)
|
||||
const doubleCount = computed(() => count.value * 2)
|
||||
function increment() {
|
||||
count.value++
|
||||
export const singStatus = defineStore('counter', () => {
|
||||
const singShow = ref<any>(null)
|
||||
function setSingShow(val:any){
|
||||
singShow.value = val
|
||||
}
|
||||
|
||||
return { count, doubleCount, increment }
|
||||
return { singShow,setSingShow}
|
||||
})
|
||||
|
|
|
|||
|
|
@ -31,8 +31,6 @@ const handleLogin = () => {
|
|||
message: "获取本地IP地址失败,将使用默认IP地址",
|
||||
type: 'warning',
|
||||
duration: 1000,
|
||||
onClose: () => {
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
|
|
@ -40,7 +38,7 @@ const handleLogin = () => {
|
|||
post(apiConfig.ManagerLogin, {username: username.value, password: password.value}).then((token: any) => {
|
||||
localStorage.setItem('token', token)
|
||||
//签到,如果 签到成功,则直接调用success,如果失败,调用error
|
||||
post('signUp/signUp', {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()
|
||||
}).catch(() => {
|
||||
error()
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<Mask :is-show="isShow" @close="init()" :height="570">
|
||||
<Mask :is-show="isShow" @close="init()" :height="570" :title="id?'编辑':'新增'">
|
||||
<SectionEdit :id="id" ref="sectionRef" @onSubmit="init()"></SectionEdit>
|
||||
</Mask>
|
||||
</template>
|
||||
|
|
|
|||
Loading…
Reference in New Issue