jsk 厨房进出记录
This commit is contained in:
parent
57d2bfad40
commit
b6693b020a
|
|
@ -11,10 +11,10 @@
|
|||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
format="yyyy-MM-dd" style="width: 220px"
|
||||
:picker-options="pickerOptions" >
|
||||
>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="所属组织" prop="deptIdList">
|
||||
<!-- <el-form-item label="所属组织" prop="deptIdList">
|
||||
<el-cascader v-model="queryParams.deptIdList"
|
||||
:options="deptOptions" :filterable="true" placeholder="请选择所属组织" style="width: 240px" :show-all-levels="false"
|
||||
:props="{
|
||||
|
|
@ -24,42 +24,39 @@
|
|||
value:'id',label:'label'
|
||||
}" clearable collapse-tags >
|
||||
</el-cascader>
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="关 键 字">
|
||||
<el-input v-model="queryParams.articleTitle" placeholder="请输入" maxlength="20" clearable style="width: 220px"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="所属区域" prop="placeIdList">
|
||||
<el-cascader v-model="queryParams.placeIdList"
|
||||
:options="placeOptions" :filterable="true" style="width: 240px" :show-all-levels="false"
|
||||
:props="{
|
||||
multiple: true,
|
||||
<el-form-item label="所属区域:" prop="areaId">
|
||||
<el-cascader v-model="queryParams.areaId"
|
||||
:options="treeOptions" :filterable="true" style="width: 100%;" :show-all-levels="false"
|
||||
:props="{
|
||||
emitPath: false,// 若设置 false,则只返回该节点的值,只返回最后选择的id
|
||||
checkStrictly: false,//来设置父子节点取消选中关联,从而达到选择任意一级选项的目的
|
||||
value:'id',label:'label'
|
||||
}" clearable collapse-tags >
|
||||
}" clearable @change="handleTreeChange">
|
||||
</el-cascader>
|
||||
</el-form-item>
|
||||
<el-form-item label="所属食堂" prop="placeIdList">
|
||||
<el-cascader v-model="queryParams.placeIdList"
|
||||
:options="placeOptions" :filterable="true" style="width: 240px" :show-all-levels="false"
|
||||
:props="{
|
||||
multiple: true,
|
||||
emitPath: false,// 若设置 false,则只返回该节点的值,只返回最后选择的id
|
||||
checkStrictly: false,//来设置父子节点取消选中关联,从而达到选择任意一级选项的目的
|
||||
value:'id',label:'label'
|
||||
}" clearable collapse-tags >
|
||||
</el-cascader>
|
||||
<el-form-item label="所属食堂:" prop="canteenId">
|
||||
<el-select v-model="queryParams.canteenId" @change="handleCanteenChange" style="width: 100%;" placeholder="请选择所属食堂">
|
||||
<el-option
|
||||
v-for="item in canteenOptions"
|
||||
:key="item.canteenId"
|
||||
:label="item.canteenName"
|
||||
:value="item.canteenId"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="所属位置" prop="placeIdList">
|
||||
<el-cascader v-model="queryParams.placeIdList"
|
||||
:options="placeOptions" :filterable="true" style="width: 240px" :show-all-levels="false"
|
||||
:props="{
|
||||
multiple: true,
|
||||
emitPath: false,// 若设置 false,则只返回该节点的值,只返回最后选择的id
|
||||
checkStrictly: false,//来设置父子节点取消选中关联,从而达到选择任意一级选项的目的
|
||||
value:'id',label:'label'
|
||||
}" clearable collapse-tags >
|
||||
</el-cascader>
|
||||
<el-form-item label="所属位置:" prop="subPlaceId">
|
||||
<el-select v-model="queryParams.subPlaceId" style="width: 100%;" placeholder="请选择设备位置">
|
||||
<el-option
|
||||
v-for="item in subPlaceOptions"
|
||||
:key="item.subPlaceId"
|
||||
:label="item.subPlaceName"
|
||||
:value="item.subPlaceId"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||
|
|
@ -72,8 +69,6 @@
|
|||
<el-table-column label="日期时间" align="center" prop="enterTime" :show-overflow-tooltip="true" width="280"></el-table-column>
|
||||
<el-table-column label="员工编号" align="center" prop="staffNo" :show-overflow-tooltip="true"></el-table-column>
|
||||
<el-table-column label="员工姓名" align="center" prop="staffName" :show-overflow-tooltip="true"></el-table-column>
|
||||
<el-table-column label="体温" align="center" prop="temp" :show-overflow-tooltip="true">
|
||||
</el-table-column>
|
||||
<el-table-column label="手机号" align="center" prop="mobile" :show-overflow-tooltip="true">
|
||||
</el-table-column>
|
||||
<el-table-column label="职位" align="center" prop="postName" :show-overflow-tooltip="true">
|
||||
|
|
@ -82,7 +77,7 @@
|
|||
</el-table-column>
|
||||
<el-table-column label="食堂" align="center" prop="canteenName" :show-overflow-tooltip="true">
|
||||
</el-table-column>
|
||||
<el-table-column label="位置" align="center" prop="placeFullName" :show-overflow-tooltip="true">
|
||||
<el-table-column label="位置" align="center" prop="subPlaceName" :show-overflow-tooltip="true">
|
||||
</el-table-column>
|
||||
<el-table-column label="门名称" align="center" prop="doorName" :show-overflow-tooltip="true">
|
||||
</el-table-column>
|
||||
|
|
@ -99,216 +94,14 @@
|
|||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
|
||||
<!-- 对话框 -->
|
||||
<el-dialog :title="title" :visible.sync="open" width="980px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="90px">
|
||||
<el-row justify="center">
|
||||
<table align="center" width="80%" cellspacing="0">
|
||||
<tr >
|
||||
<td colspan="4" class="table-title">个人信息</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><i class="text-red">*</i> <span >用户姓名</span></td>
|
||||
<td class="table-content"><span >{{form.nickName}}</span></td>
|
||||
<td class="table-label"><i class="text-red">*</i> <span >用户编号</span></td>
|
||||
<td class="table-content"><span >{{form.userId}}</span></td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><i class="text-red">*</i> <span >所属组织</span></td>
|
||||
<td class="table-content"><span >{{form.orgFullName}}</span></td>
|
||||
<td class="table-label"><span >用户类别2</span></td>
|
||||
<td class="table-content"><span >{{form.userType==1?'其它':'系统'}}</span></td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >用户手机号</span></td>
|
||||
<td class="table-content"><span >{{form.mobile}}</span></td>
|
||||
<td class="table-label"><span >性别</span></td>
|
||||
<td class="table-content"><span >{{form.sex==1?'男':'女'}}</span></td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >位置信息</span></td>
|
||||
<td class="table-content"><span ></span></td>
|
||||
<td class="table-label"><span >出生日期</span></td>
|
||||
<td class="table-content"><span >{{form.birthday}}</span></td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td colspan="4" class="table-title">健康信息</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >就诊号</span></td>
|
||||
<td class="table-content">
|
||||
<el-input
|
||||
v-model="form.doctorNum"
|
||||
placeholder="请输入就诊号"
|
||||
maxlength="40"
|
||||
show-word-limit
|
||||
/>
|
||||
</td>
|
||||
<td class="table-label"><span >住院号</span></td>
|
||||
<td class="table-content">
|
||||
<el-input
|
||||
v-model="form.hospitalNum"
|
||||
placeholder="请输入住院号"
|
||||
maxlength="40"
|
||||
show-word-limit
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >身高</span></td>
|
||||
<td class="table-content">
|
||||
<el-input
|
||||
v-model="form.height"
|
||||
placeholder="请输入住身高"
|
||||
maxlength="3"
|
||||
show-word-limit
|
||||
/>
|
||||
</td>
|
||||
<td class="table-label"><span >体重</span></td>
|
||||
<td class="table-content">
|
||||
<el-input
|
||||
v-model="form.weight"
|
||||
placeholder="请输入住体重"
|
||||
maxlength="5"
|
||||
show-word-limit
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >血型</span></td>
|
||||
<td class="table-content">
|
||||
<el-select v-model="form.bloodType" placeholder="请选择血型" style="width: 100%">
|
||||
<el-option v-for="item in this.bloodTypeOptions"
|
||||
:key="item.bloodType"
|
||||
:label="item.bloodTypeName"
|
||||
:value="item.bloodType"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</td>
|
||||
<td class="table-label"><span >慢性病</span></td>
|
||||
<td class="table-content">
|
||||
<el-select v-model="form.chronicList" placeholder="请选择慢性病" @change="$forceUpdate()" multiple style="width: 100%" clearable collapse-tags>
|
||||
<el-option v-for="item in chronicOptions"
|
||||
:key="item.chronicId"
|
||||
:label="item.chronicName"
|
||||
:value="item.chronicId"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >怀孕状态</span></td>
|
||||
<td class="table-content">
|
||||
<el-select v-model="form.pregnantStatus" placeholder="请选择怀孕状态" style="width: 100%">
|
||||
<el-option v-for="item in this.pregnantOptions"
|
||||
:key="item.pregnantStatus"
|
||||
:label="item.pregnantStatusName"
|
||||
:value="item.pregnantStatus"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</td>
|
||||
<td class="table-label"><span >怀孕日期</span></td>
|
||||
<td class="table-content">
|
||||
<el-date-picker
|
||||
v-model="form.pregnancyDate"
|
||||
type="date"
|
||||
align="right"
|
||||
unlink-panels
|
||||
value-format="yyyy-MM-dd" style="width: 100%"
|
||||
>
|
||||
</el-date-picker>
|
||||
</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >是否住院</span></td>
|
||||
<td class="table-content">
|
||||
<el-select v-model="form.ifHospitalized" placeholder="请选择是否住院" style="width: 100%">
|
||||
<el-option v-for="item in this.ifHospitalizedOptions"
|
||||
:key="item.ifHospitalized"
|
||||
:label="item.ifHospitalizedName"
|
||||
:value="item.ifHospitalized"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</td>
|
||||
<td class="table-label"><span >住院日期</span></td>
|
||||
<td class="table-content">
|
||||
<el-date-picker
|
||||
v-model="form.inpatientDate"
|
||||
type="date"
|
||||
align="right"
|
||||
unlink-panels
|
||||
value-format="yyyy-MM-dd" style="width: 100%"
|
||||
>
|
||||
</el-date-picker>
|
||||
</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >劳动强度</span></td>
|
||||
<td class="table-content">
|
||||
<el-select v-model="form.labourIntensity" placeholder="请选择劳动强度" style="width: 100%">
|
||||
<el-option v-for="item in this.labourIntensityOptions"
|
||||
:key="item.labourIntensity"
|
||||
:label="item.labourIntensityName"
|
||||
:value="item.labourIntensity"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</td>
|
||||
<td class="table-label"><span >过敏源</span></td>
|
||||
<td class="table-content">
|
||||
<el-input
|
||||
v-model="form.allergen"
|
||||
placeholder="请输入过敏源"
|
||||
maxlength="40"
|
||||
show-word-limit
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >饮食医嘱</span></td>
|
||||
<td class="table-content">
|
||||
<el-select v-model="form.doctorAdvice" placeholder="请选择饮食医嘱" style="width: 100%" >
|
||||
<el-option v-for="item in doctorAdviceOptions"
|
||||
:key="item.doctorAdvice"
|
||||
:label="item.doctorAdviceName"
|
||||
:value="item.doctorAdvice"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</td>
|
||||
<td class="table-label"><span >体重控制目标</span></td>
|
||||
<td class="table-content">
|
||||
<el-select v-model="form.weightControl" placeholder="请选择" style="width: 100%" >
|
||||
<el-option v-for="item in weightControlOptions"
|
||||
:key="item.weightControl"
|
||||
:label="item.weightControlName"
|
||||
:value="item.weightControl"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td class="table-label"><span >BMI(kg/m²)</span></td>
|
||||
<td class="table-content">{{form.bmi}}</td>
|
||||
<td colspan="2"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||
<el-button @click="cancel">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog :visible.sync="dialogVisible">
|
||||
<img width="100%" :src="dialogImageUrl" alt="">
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { deptTreeSelect } from '@/api/system/user'
|
||||
import { getIntoRecordsListApi } from "@/api/kitchen/intoRecords";
|
||||
import { systemAreaTreeApi,getCanteenByAreaApi } from "@/api/base/stall";
|
||||
import { getKitchenSubPlaceListAllApi } from "@/api/kitchen/devices";
|
||||
import { imgUpLoadTwo } from '@/api/system/upload'
|
||||
import { decryptWithSM4,encryptWithSM4 } from '@/utils/sm';
|
||||
export default {
|
||||
|
|
@ -335,46 +128,33 @@ export default {
|
|||
open: false,
|
||||
dateRange:[new Date(),new Date()],
|
||||
chronicOptions:[],
|
||||
deptOptions:[],
|
||||
treeOptions:[], //区域
|
||||
canteenOptions: [],
|
||||
subPlaceOptions: [],
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
articleTitle: undefined,//标题
|
||||
deptIdList:[],//组织
|
||||
chronicList:[], //慢性病
|
||||
placeIdList:[], //位置
|
||||
doctorAdvice:[],//饮食医嘱
|
||||
articleType:null //类型
|
||||
areaId:null, //所属区域
|
||||
canteenId:null, //所属食堂
|
||||
subPlaceId:null,//所属位置
|
||||
},
|
||||
form: {
|
||||
nickName:null,
|
||||
userId:null,
|
||||
areaId:null,
|
||||
canteenId:null,
|
||||
orgFullName:null,
|
||||
userType:null,
|
||||
mobile:null,
|
||||
sex:1,
|
||||
birthday:null,
|
||||
doctorNum:null,
|
||||
hospitalNum:null,
|
||||
height:null,
|
||||
weight:null,
|
||||
bloodType:null,
|
||||
chronicList:[],
|
||||
pregnantStatus:null,
|
||||
pregnancyDate:null,
|
||||
ifHospitalized:null,
|
||||
inpatientDate:null,
|
||||
labourIntensity:null,
|
||||
allergen:null,
|
||||
doctorAdvice:null,
|
||||
weightControl:null,
|
||||
},//详情
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getDeptTree()
|
||||
this.getList()
|
||||
this.getChronicList()
|
||||
this.getTreeData()
|
||||
this.getKitchenSubPlaceList()
|
||||
},
|
||||
computed: {
|
||||
//图片上传1张后,隐藏上传框
|
||||
|
|
@ -399,6 +179,39 @@ export default {
|
|||
})
|
||||
.filter((node) => node.status !== '1')
|
||||
},
|
||||
//区域树
|
||||
getTreeData() {
|
||||
systemAreaTreeApi({}).then((response) => {
|
||||
this.treeOptions = response.data;
|
||||
});
|
||||
},
|
||||
handleTreeChange(e){
|
||||
let param= {
|
||||
"areaId":e,
|
||||
"canteenType":1
|
||||
}
|
||||
console.log("param",param)
|
||||
getCanteenByAreaApi(param).then((response) => {
|
||||
this.canteenOptions=response.rows||[]
|
||||
this.$set(this.queryParams,'canteenId',null)
|
||||
});
|
||||
},
|
||||
// 食堂选项
|
||||
getCanteenList(){
|
||||
getCanteenByAreaApi({}).then((response) => {
|
||||
this.canteenOptions = response.rows
|
||||
})
|
||||
},
|
||||
handleCanteenChange(e){
|
||||
this.$set(this.queryParams,'canteenId',e)
|
||||
this.$set(this.queryParams,'subPlaceId',null)
|
||||
this.getKitchenSubPlaceList();
|
||||
},
|
||||
getKitchenSubPlaceList(){
|
||||
getKitchenSubPlaceListAllApi({canteenId:this.queryParams.canteenId}).then((response) => {
|
||||
this.subPlaceOptions = response.rows
|
||||
})
|
||||
},
|
||||
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
|
|
@ -428,19 +241,17 @@ export default {
|
|||
"pageNum":this.queryParams.pageNum,
|
||||
"pageSize":this.queryParams.pageSize,
|
||||
"articleTitle":this.queryParams.articleTitle,
|
||||
"deptIds":this.queryParams.deptIdList.join(",")||""
|
||||
}
|
||||
if(this.dateRange&&this.dateRange.length>0){
|
||||
param.startDate=this.formatDate(this.dateRange[0])
|
||||
param.endDate=this.formatDate(this.dateRange[1])
|
||||
}else{
|
||||
param.startDate=undefined;
|
||||
param.endDate=undefined;
|
||||
"deptIds":this.queryParams.deptIdList.join(",")||"",
|
||||
"startDate":this.formatDate(this.dateRange[0]),
|
||||
"areaId":this.queryParams.areaId,
|
||||
"canteenId":this.queryParams.canteenId,
|
||||
"subPlaceId":this.queryParams.subPlaceId,
|
||||
"endDate":this.formatDate(this.dateRange[1])
|
||||
}
|
||||
console.log("param",param);
|
||||
getIntoRecordsListApi(param).then(response => {
|
||||
this.tableListData = response.rows;
|
||||
// console.log("this.tableListData",this.tableListData);
|
||||
console.log("this.tableListData",this.tableListData);
|
||||
this.tableListData.forEach(item=>{
|
||||
this.$set(item,"mobile",this.getDecryptWithSM4(item.mobile))
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in New Issue