zxr 2 жил өмнө
parent
commit
c535eda6a4

+ 53 - 0
src/api/barracksManagement/repair.js

@@ -0,0 +1,53 @@
+import request from '@/utils/request'
+
+// 查询维修申请列表
+export function listRepair(query) {
+  return request({
+    url: '/barracksManagement/repair/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询维修申请详细
+export function getRepair(id) {
+  return request({
+    url: '/barracksManagement/repair/' + id,
+    method: 'get'
+  })
+}
+
+// 新增维修申请
+export function addRepair(data) {
+  return request({
+    url: '/barracksManagement/repair',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改维修申请
+export function updateRepair(data) {
+  return request({
+    url: '/barracksManagement/repair',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除维修申请
+export function delRepair(id) {
+  return request({
+    url: '/barracksManagement/repair/' + id,
+    method: 'delete'
+  })
+}
+
+// 完成
+export function repairSuccess(data) {
+  return request({
+    url: '/barracksManagement/repair/repairSuccess',
+    method: 'put',
+    data: data
+  })
+}

+ 44 - 0
src/api/grassrootsregistration/cookbookPrc.js

@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 查询一周工作食普图列表
+export function listCookbookPrc(query) {
+  return request({
+    url: '/grassrootsregistration/cookbookPrc/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询一周工作食普图详细
+export function getCookbookPrc(id) {
+  return request({
+    url: '/grassrootsregistration/cookbookPrc/' + id,
+    method: 'get'
+  })
+}
+
+// 新增一周工作食普图
+export function addCookbookPrc(data) {
+  return request({
+    url: '/grassrootsregistration/cookbookPrc',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改一周工作食普图
+export function updateCookbookPrc(data) {
+  return request({
+    url: '/grassrootsregistration/cookbookPrc',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除一周工作食普图
+export function delCookbookPrc(id) {
+  return request({
+    url: '/grassrootsregistration/cookbookPrc/' + id,
+    method: 'delete'
+  })
+}

+ 34 - 3
src/api/medicalhealth/examine.js

@@ -69,7 +69,7 @@ export function exportExamine(query) {
     params: query
   })
 }
-// 查询部门 
+// 查询部门
 export function getDept(query) {
   return request({
     url: '/grassrootsregistration/common/getDept',
@@ -82,6 +82,37 @@ export function getZhuChiRen(data) {
   return request({
     url: '/grassrootsregistration/common/getZhuChiRen',
     method: 'get',
-    params: { deptId: data }
+    params: {
+      deptId: data
+    }
   })
-}
+}
+
+// 统计
+export function getPeopleExaminationcount(data) {
+  return request({
+    url: '/peopleManage/people/getPeopleExaminationcount',
+    method: 'get',
+    params: {
+      deptId: data
+    }
+  })
+}
+
+// 查询人员体检信息列表
+export function getlist(query) {
+  return request({
+    url: 'peopleManage/people/getPeopleExaminationList',
+    method: 'get',
+    params: query
+  })
+}
+
+//体检完成
+export function Examinationedit(data) {
+  return request({
+    url: '/peopleManage/people/Examinationedit',
+    method: 'put',
+    data: data
+  })
+}

+ 67 - 64
src/views/access/Renaccess/index.vue

@@ -9,13 +9,7 @@
     >
       <el-form-item prop="offduty">
         <el-select v-model="ipDi" placeholder="请选择考勤地址" clearable>
-          <el-option
-            v-for="item in ipList"
-            :key="item.id"
-            :label="item.ip"
-            :value="item.ip"
-          >
-          </el-option>
+          <el-option v-for="item in ipList" :key="item.id" :label="item.ip" :value="item.ip"></el-option>
         </el-select>
       </el-form-item>
       <el-form-item>
@@ -29,15 +23,11 @@
         :highlightedDates="year"
         v-on:change="dateChange2"
       ></vue-horizontal-calendar>
-      <el-form-item> </el-form-item>
+      <el-form-item></el-form-item>
     </el-form>
-    <el-row :gutter="10" class="mb8"> </el-row>
+    <el-row :gutter="10" class="mb8"></el-row>
     <div class="tables" :class="{ sollore: length > 3 }" v-if="length > 1">
-      <div
-        v-for="(item, i) in length"
-        :key="i"
-        style="width: 400px; margin-right: 20px"
-      >
+      <div v-for="(item, i) in length" :key="i" style="width: 400px; margin-right: 20px">
         <el-table
           v-loading="loading"
           :data="bdglevenList[i]"
@@ -45,21 +35,18 @@
         >
           <el-table-column label="序号" type="index" width="50" align="center">
             <template scope="scope">
-              <span>{{
+              <span>
+                {{
                 (queryParams.pageNum - 1) * queryParams.pageSize +
                 scope.$index +
                 1
-              }}</span>
+                }}
+              </span>
             </template>
           </el-table-column>
           <!-- <el-table-column label="编号" align="center" prop="pin" width="50" /> -->
-          <el-table-column label="姓名" align="center" prop="ename"/>
-          <el-table-column
-            label="时间"
-            align="center"
-            prop="checktime"
-            show-overflow-tooltip
-          />
+          <el-table-column label="姓名" align="center" prop="ename" />
+          <el-table-column label="时间" align="center" prop="checktime" show-overflow-tooltip />
         </el-table>
       </div>
     </div>
@@ -71,38 +58,38 @@
       >
         <el-table-column label="序号" type="index" width="50" align="center">
           <template scope="scope">
-            <span>{{
+            <span>
+              {{
               (queryParams.pageNum - 1) * queryParams.pageSize +
               scope.$index +
               1
-            }}</span>
+              }}
+            </span>
           </template>
         </el-table-column>
         <!-- <el-table-column label="编号" align="center" prop="pin" /> -->
         <el-table-column label="姓名" align="center" prop="ename" />
-        <el-table-column
-          label="时间"
-          align="center"
-          prop="checktime"
-          show-overflow-tooltip
-        />
+        <el-table-column label="时间" align="center" prop="checktime" show-overflow-tooltip />
       </el-table>
     </div>
   </div>
-</template> 
+</template>
 <script>
 import axios from "axios";
 // 导入树形结构
 import Treeselect from "@riophae/vue-treeselect";
 import "@riophae/vue-treeselect/dist/vue-treeselect.css";
-import { listIpaddressconfig } from "@/api/access/accessControl";
+import {
+  listIpaddressconfig,
+  attendancerecordList
+} from "@/api/access/accessControl";
 //日期
 import VueHorizontalCalendar from "vue-horizontal-calendar";
 export default {
   name: "Raccess",
   components: {
     Treeselect,
-    VueHorizontalCalendar,
+    VueHorizontalCalendar
   },
   data() {
     return {
@@ -110,7 +97,7 @@ export default {
       queryParams: {
         number: 0,
         pageNum: 1,
-        pageSize: 10,
+        pageSize: 10
       },
       bdglevenList: [],
       // 显示搜索条件
@@ -131,9 +118,9 @@ export default {
           {
             type: "email",
             message: "请输入正确的邮箱地址",
-            trigger: ["blur", "change"],
-          },
-        ],
+            trigger: ["blur", "change"]
+          }
+        ]
       },
       // 树形结构列表
       deptOptions: [],
@@ -150,14 +137,14 @@ export default {
       // 考勤机ipList
       ipList: [],
       ipDi: null,
-      qian:null,
-      hou:null
+      qian: null,
+      hou: null
     };
   },
   created() {
     // // 获取列表
     this.getTiem();
-    listIpaddressconfig().then((res) => {
+    listIpaddressconfig().then(res => {
       this.ipList = res.rows;
     });
   },
@@ -188,7 +175,7 @@ export default {
       this.xinDate = qian;
       // console.log(qian);
       var hou = Y + M + D + "23:59:59";
-      this.hou=hou
+      this.hou = hou;
       this.yearFn();
       this.getList(qian, hou);
     },
@@ -245,26 +232,43 @@ export default {
     // 获取列表
     getList(starttime, endtime, number) {
       this.loading = false;
-      axios
-        .post(
-          `http://${this.ipDi}/api/v2/transaction/get/?key=2633p84hnnlavzcy9afjcbtj1jdnega0ftscjkka6h7a`,
-          {
-            starttime,
-            endtime,
-          }
-        )
-        .then((res) => {
-          this.loading = false;
-          var groupedArray = this.group(res.data.data.items, 15);
-          this.length = groupedArray.length;
-          if (groupedArray.length > 1) {
-            this.bdglevenList = groupedArray;
-          } else {
-            this.bdglevenList = res.data.data.items;
-          }
-        });
-    },
-  },
+      attendancerecordList({
+        starttime,
+        endtime,
+        createTime: starttime
+      }).then(res => {
+        this.loading = false;
+        var groupedArray = this.group(res.rows, 15);
+        this.length = groupedArray.length;
+        this.bdglevenList = groupedArray;
+        // this.length = res.total;
+        if (groupedArray.length > 1) {
+          this.bdglevenList = groupedArray;
+        } else {
+          this.bdglevenList = res.rows;
+        }
+      });
+      // axios
+      //   .post(
+      //     // `http://${this.ipDi}/api/v2/transaction/get/?key=2633p84hnnlavzcy9afjcbtj1jdnega0ftscjkka6h7a`,
+      //     `http://${this.ipDi}/api/v2/grassrootsregistration/attendancerecord/list`,
+      //     {
+      //       starttime,
+      //       endtime
+      //     }
+      //   )
+      //   .then(res => {
+      //     this.loading = false;
+      //     var groupedArray = this.group(res.data.data.items, 15);
+      //     this.length = groupedArray.length;
+      //     if (groupedArray.length > 1) {
+      //       this.bdglevenList = groupedArray;
+      //     } else {
+      //       this.bdglevenList = res.data.data.items;
+      //     }
+      //   });
+    }
+  }
 };
 </script>
   <style scoped>
@@ -471,5 +475,4 @@ export default {
   overflow-x: scroll;
 }
 </style>
-  
-    
+

+ 460 - 0
src/views/barracksManagement/repair/index.vue

@@ -0,0 +1,460 @@
+<template>
+  <div class="app-container">
+    <el-form
+      :model="queryParams"
+      ref="queryForm"
+      size="small"
+      :inline="true"
+      v-show="showSearch"
+      label-width="68px"
+    >
+      <el-form-item label prop="contacts">
+        <el-input
+          v-model="queryParams.contacts"
+          placeholder="请输入联系人"
+          clearable
+          @keyup.enter.native="handleQuery"
+          @input="handleQuery"
+        />
+      </el-form-item>
+      <!-- <el-form-item label="联系方式" prop="contactInformation">
+        <el-input
+          v-model="queryParams.contactInformation"
+          placeholder="请输入联系方式"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="维修地址" prop="addressUnit">
+        <el-input
+          v-model="queryParams.addressUnit"
+          placeholder="请输入维修地址"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="维修类型" prop="repairType">
+        <el-select v-model="queryParams.repairType" placeholder="请选择维修类型" clearable>
+          <el-option
+            v-for="dict in dict.type.repair_type"
+            :key="dict.value"
+            :label="dict.label"
+            :value="dict.value"
+          />
+        </el-select>
+      </el-form-item>
+      <el-form-item label="具体描述" prop="description">
+        <el-input
+          v-model="queryParams.description"
+          placeholder="请输入具体描述"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="完成状态" prop="state">
+        <el-input
+          v-model="queryParams.state"
+          placeholder="请输入完成状态"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>-->
+      <el-form-item>
+        <!-- <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button> -->
+        <el-button size="btr" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['barracksManagement:repair:add']"
+        >新增</el-button>
+      </el-col>
+      <!-- <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['barracksManagement:repair:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['barracksManagement:repair:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['barracksManagement:repair:export']"
+        >导出</el-button>
+      </el-col>-->
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table
+      v-loading="loading"
+      :data="repairList"
+      @selection-change="handleSelectionChange"
+      :header-cell-style="{ background: '#003C69', color: 'white' }"
+    >
+      <el-table-column type="selection" width="55" align="center" />
+      <!-- <el-table-column label="${comment}" align="center" prop="id" /> -->
+      <el-table-column label="序号" type="index" width="100" align="center">
+        <template scope="scope">
+          <span>
+            {{
+            (queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1
+            }}
+          </span>
+        </template>
+      </el-table-column>
+      <el-table-column label="联系人" align="center" prop="contacts" width="130" />
+      <el-table-column label="联系方式" align="center" prop="contactInformation" width="130" />
+      <el-table-column label="维修类型" align="center" prop="repairType" width="130">
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.repair_type" :value="scope.row.repairType" />
+        </template>
+      </el-table-column>
+      <el-table-column label="维修地址" align="center" prop="addressUnit" width="250" />
+      <el-table-column label="具体描述" align="center" prop="description" width="500" />
+      <el-table-column label="完成状态" align="center" prop="state" width="100">
+        <template slot-scope="scope">
+          <span v-if="scope.row.state==0" style="color: rgb(255 106 0)">未完成</span>
+          <span v-if="scope.row.state==1" style="color: rgb(2 255 2)">已完成</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="btk"
+            v-if="scope.row.state==0"
+            type="text"
+            @click="handlewancheng(scope.row)"
+          >
+            <span class="chakan">完成</span>
+          </el-button>
+          <el-button
+            size="btu"
+            type="text"
+            v-if="scope.row.state==0"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['barracksManagement:repair:edit']"
+          >
+            <span>修改</span>
+          </el-button>
+          <el-button
+            size="btd"
+            type="text"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['barracksManagement:repair:remove']"
+          >
+            <span class="delete">删除</span>
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改维修申请对话框 -->
+    <el-dialog
+      :title="title"
+      :visible.sync="open"
+      width="1080px"
+      append-to-body
+      :close-on-click-modal="false"
+    >
+      <el-form ref="form" :model="form" :rules="rules" :inline="true" label-width="120px">
+        <div class="jiben">基本信息</div>
+        <el-form-item label="联系人" prop="contacts">
+          <el-input v-model="form.contacts" placeholder="请输入联系人" />
+        </el-form-item>
+        <el-form-item label="联系方式" prop="contactInformation">
+          <el-input v-model="form.contactInformation" placeholder="请输入联系方式" />
+        </el-form-item>
+        <el-form-item label="维修地址" prop="addressUnit">
+          <el-input v-model="form.addressUnit" placeholder="请输入维修地址" />
+        </el-form-item>
+        <el-form-item label="维修类型" prop="repairType">
+          <el-select v-model="form.repairType" placeholder="请选择维修类型">
+            <el-option
+              v-for="dict in dict.type.repair_type"
+              :key="dict.value"
+              :label="dict.label"
+              :value="parseInt(dict.value)"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <div class="jiben">具体描述</div>
+        <el-form-item label prop="description">
+          <el-input type="textarea" v-model="form.description" placeholder="请输入具体描述" />
+        </el-form-item>
+        <!-- <el-form-item label="完成状态" prop="state">
+          <el-input v-model="form.state" placeholder="请输入完成状态" />
+        </el-form-item>-->
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel" size="btn">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  listRepair,
+  getRepair,
+  delRepair,
+  addRepair,
+  updateRepair,
+  repairSuccess
+} from "@/api/barracksManagement/repair";
+
+export default {
+  name: "Repair",
+  dicts: ["repair_type"],
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 维修申请表格数据
+      repairList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        contacts: null,
+        contactInformation: null,
+        addressUnit: null,
+        repairType: null,
+        description: null,
+        state: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        contactInformation: [
+          // { required: true, message: "手机号码不能为空", trigger: "blur" },
+          {
+            pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
+            message: "请输入正确的手机号码",
+            trigger: "blur"
+          }
+        ]
+      }
+    };
+  },
+  created() {
+    this.getList();
+  },
+  methods: {
+    handlewancheng(row) {
+      row.state = 1;
+      repairSuccess(row).then(res => {
+        if (res.code == 200) {
+          this.$modal.msgSuccess("完成已通过");
+        }
+      });
+    },
+    /** 查询维修申请列表 */
+    getList() {
+      this.loading = true;
+      listRepair(this.queryParams).then(response => {
+        this.repairList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        contacts: null,
+        contactInformation: null,
+        addressUnit: null,
+        repairType: null,
+        description: null,
+        state: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id);
+      this.single = selection.length !== 1;
+      this.multiple = !selection.length;
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加维修申请";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids;
+      getRepair(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改维修申请";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateRepair(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            this.form.state = 0;
+            addRepair(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal
+        .confirm('是否确认删除维修申请编号为"' + ids + '"的数据项?')
+        .then(function() {
+          return delRepair(ids);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("删除成功");
+        })
+        .catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download(
+        "barracksManagement/repair/export",
+        {
+          ...this.queryParams
+        },
+        `repair_${new Date().getTime()}.xlsx`
+      );
+    }
+  }
+};
+</script>
+<style scoped >
+::v-deep .el-input--small .el-input__inner {
+  color: #fff;
+  height: 36px;
+  line-height: 36px;
+}
+
+/* 对话框背景颜色 */
+::v-deep .el-dialog {
+  background: #004d86 !important;
+}
+
+::v-deep .el-textarea__inner {
+  width: 920px;
+  height: 104px;
+}
+
+::v-deep .el-dialog__header {
+  border-bottom: 1px solid #718a9d;
+}
+
+::v-deep .el-dialog__title {
+  color: #fff;
+  font: 18px;
+}
+
+::v-deep .el-dialog__headerbtn .el-dialog__close {
+  color: #fff;
+}
+
+::v-deep .el-input--small .el-input__inner {
+  width: 200px;
+  height: 36px;
+  line-height: 36px;
+}
+::v-deep .el-input--medium .el-input__inner {
+  background: #004d86;
+  color: #fff;
+}
+
+.el-form-item ::v-deep .el-input__inner {
+  width: 200px;
+  height: 36px;
+  background: transparent !important;
+  color: #fff;
+  border: 1px solid #fff !important;
+}
+
+::v-deep .el-textarea__inner {
+  width: 990px;
+  height: 104px;
+}
+</style>

+ 481 - 0
src/views/grassrootsregistration/cookbookPrc/index.vue

@@ -0,0 +1,481 @@
+<template>
+  <div class="app-container">
+    <el-form
+      :model="queryParams"
+      ref="queryForm"
+      size="small"
+      :inline="true"
+      v-show="showSearch"
+      label-width="68px"
+    >
+      <!-- <el-form-item label="上传人" prop="upPeople">
+        <el-input
+          v-model="queryParams.upPeople"
+          placeholder="请输入上传人"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>-->
+      <el-form-item label prop="upTime">
+        <el-date-picker
+          clearable
+          v-model="queryParams.upTime"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="请选择上传时间"
+          @change="time"
+        ></el-date-picker>
+      </el-form-item>
+      <!-- <el-form-item label="上传单位" prop="upUnit">
+        <el-input
+          v-model="queryParams.upUnit"
+          placeholder="请输入上传单位"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="备注" prop="remarks">
+        <el-input
+          v-model="queryParams.remarks"
+          placeholder="请输入备注"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>-->
+      <el-form-item>
+        <!-- <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button> -->
+        <el-button icon size="btr" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['grassrootsregistration:cookbookPrc:add']"
+        >新增</el-button>
+      </el-col>
+      <!-- <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['grassrootsregistration:cookbookPrc:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['grassrootsregistration:cookbookPrc:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['grassrootsregistration:cookbookPrc:export']"
+        >导出</el-button>
+      </el-col>-->
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table
+      v-loading="loading"
+      :data="cookbookPrcList"
+      @selection-change="handleSelectionChange"
+      :header-cell-style="{ background: '#003C69', color: 'white' }"
+    >
+      <el-table-column type="selection" width="55" align="center" />
+      <!-- <el-table-column label="${comment}" align="center" prop="id" />-->
+      <el-table-column label="序号" type="index" width="100" align="center">
+        <template scope="scope">
+          <span>
+            {{
+            (queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1
+            }}
+          </span>
+        </template>
+      </el-table-column>
+      <el-table-column label="上传图片" align="center" prop="urlImage">
+        <template slot-scope="scope">
+          <img :src="downurl +scope.row.urlImage" alt :width="50" :height="50" />
+          <!-- <image :src="downurl +scope.row.urlImage" :width="50" :height="50" /> -->
+          <!-- <span>{{ parseTime(scope.row.upTime, '{y}-{m}-{d}') }}</span> -->
+        </template>
+      </el-table-column>
+      <!-- <el-table-column label="上传人" align="center" prop="upPeople" /> -->
+      <el-table-column label="上传时间" align="center" prop="upTime" width="180">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.upTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <!-- <el-table-column label="上传单位" align="center" prop="upUnit" /> -->
+      <el-table-column label="备注" align="center" prop="remarks" />
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button size="btk" type="text" @click="handleChakan(scope.row)">
+            <span class="chakan">预览</span>
+          </el-button>
+          <el-button
+            size="btu"
+            type="text"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['grassrootsregistration:cookbookPrc:edit']"
+          >
+            <span>修改</span>
+          </el-button>
+          <el-button
+            size="btd"
+            type="text"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['grassrootsregistration:cookbookPrc:remove']"
+          >
+            <span class="delete">删除</span>
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改一周工作食普图对话框 -->
+    <el-dialog
+      :title="title"
+      :visible.sync="open"
+      width="1016px"
+      append-to-body
+      :close-on-click-modal="false"
+    >
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <!-- <el-form-item label="图片存放地址">
+          <image-upload v-model="form.urlImage" />
+        </el-form-item>-->
+        <!-- <el-form-item label="上传时间" prop="upTime">
+          <el-date-picker
+            clearable
+            v-model="form.upTime"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="请选择上传时间"
+          ></el-date-picker>
+        </el-form-item>-->
+        <div class="jiben">图片上传</div>
+        <!-- <quill-editor
+            class="quill-editor"
+            ref="myTextEditor"
+            v-model="form.contents"
+            style="height: 150px; width: 920px; margin-left: 0px"
+        ></quill-editor>-->
+        <ImageUpload v-model="form.urlImage"></ImageUpload>
+        <div class="jiben" style="margin-top:20px;">上传时间</div>
+        <el-date-picker
+          clearable
+          v-model="form.upTime"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="请选择上传时间"
+        ></el-date-picker>
+        <div class="jiben" style="margin-top:20px;">备注</div>
+        <el-input v-model="form.remarks" type="textarea" placeholder="请输入内容" autosize />
+        <!-- <el-input v-model="form.remarks" placeholder="请输入备注" /> -->
+        <!-- <el-form-item label="上传人" prop="upPeople">
+          <el-input v-model="form.upPeople" placeholder="请输入上传人" />
+        </el-form-item>-->
+
+        <!-- <el-form-item label="上传单位" prop="upUnit">
+          <el-input v-model="form.upUnit" placeholder="请输入上传单位" />
+        </el-form-item>-->
+        <!-- <el-form-item label="备注" prop="remarks">
+          <el-input v-model="form.remarks" placeholder="请输入备注" />
+        </el-form-item>-->
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel" size="btn">取 消</el-button>
+      </div>
+    </el-dialog>
+    <el-dialog
+      :title="title"
+      :visible.sync="open2"
+      width="1016px"
+      append-to-body
+      :close-on-click-modal="false"
+    >
+      <img class="urlImage" :src="downurl + urlImage" alt />
+      <div slot="footer" class="dialog-footer">
+        <!-- <el-button type="primary" @click="submitForm2">确 定</el-button> -->
+        <el-button @click="cancel2" size="btn">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  listCookbookPrc,
+  getCookbookPrc,
+  delCookbookPrc,
+  addCookbookPrc,
+  updateCookbookPrc
+} from "@/api/grassrootsregistration/cookbookPrc";
+
+export default {
+  name: "CookbookPrc",
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 一周工作食普图表格数据
+      cookbookPrcList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        urlImage: null,
+        upPeople: null,
+        upTime: null,
+        upUnit: null,
+        remarks: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {},
+      // 下载文件路径
+      downurl: process.env.VUE_APP_BASE_API,
+      open2: false
+    };
+  },
+  created() {
+    this.getList();
+  },
+  methods: {
+    cancel2() {
+      this.open2 = false;
+    },
+    // 搜索时间触发
+    time() {
+      this.getList();
+    },
+    handleChakan(row) {
+      this.title = "图片预览";
+      this.urlImage = row.urlImage;
+      this.open2 = true;
+    },
+    /** 查询一周工作食普图列表 */
+    getList() {
+      this.loading = true;
+      listCookbookPrc(this.queryParams).then(response => {
+        this.cookbookPrcList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        urlImage: null,
+        upPeople: null,
+        upTime: null,
+        upUnit: null,
+        remarks: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id);
+      this.single = selection.length !== 1;
+      this.multiple = !selection.length;
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加一周工作食普图";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids;
+      getCookbookPrc(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改一周工作食普图";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateCookbookPrc(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addCookbookPrc(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal
+        .confirm('是否确认删除一周工作食普图编号为"' + ids + '"的数据项?')
+        .then(function() {
+          return delCookbookPrc(ids);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("删除成功");
+        })
+        .catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download(
+        "grassrootsregistration/cookbookPrc/export",
+        {
+          ...this.queryParams
+        },
+        `cookbookPrc_${new Date().getTime()}.xlsx`
+      );
+    }
+  }
+};
+</script>
+<style scoped>
+/* 对话框背景颜色 */
+::v-deep .el-dialog {
+  background: #004d86 !important;
+}
+
+::v-deep .el-textarea__inner {
+  width: 920px;
+  height: 104px;
+}
+
+::v-deep .el-dialog__header {
+  border-bottom: 1px solid #718a9d;
+}
+
+::v-deep .el-dialog__title {
+  color: #fff;
+  font: 18px;
+}
+
+::v-deep .el-dialog__headerbtn .el-dialog__close {
+  color: #fff;
+}
+
+::v-deep .el-form-item__label {
+  font: 16px;
+  color: #fff;
+  width: 100px !important;
+}
+
+::v-deep .el-textarea__inner {
+  width: 920px;
+  /* margin: auto; */
+  min-height: 120px !important;
+}
+#chakan /deep/ .el-dialog__body {
+  padding: 30px 64px;
+  margin-left: 39px;
+}
+.shouForm /deep/ .el-input__inner {
+  width: 220px;
+}
+
+::v-deep .boxtext .el-textarea__inner {
+  width: 810px;
+}
+
+/* 时间选择 */
+::v-deep .el-input--small .el-input__inner {
+  width: 200px;
+  height: 36px;
+  line-height: 36px;
+}
+::v-deep .el-input--medium .el-input__inner {
+  background: #004d86;
+  color: #fff;
+}
+::v-deep .el-date-editor.el-input .el-input__inner {
+  height: 36px;
+  line-height: 36px;
+}
+::v-deep .el-upload--picture-card {
+  background: #004d86;
+  color: #fff;
+}
+::v-deep .el-upload__tip {
+  color: #fff;
+}
+
+::v-deep .el-input--small .el-input__inner {
+  color: #fff;
+}
+.urlImage {
+  width: 970px;
+  object-fit: contain;
+}
+</style>

+ 919 - 0
src/views/medicalhealth/examine2/index.vue

@@ -0,0 +1,919 @@
+<template>
+  <div class="app-container">
+    <!-- <el-form
+      :model="queryParams"
+      ref="queryForm"
+      :inline="true"
+      v-show="showSearch"
+      label-width="68px"
+    >
+      <el-form-item label prop="unitName">
+        <el-input v-model="queryParams.unitName" placeholder="请输入单位" clearable size="small" />
+      </el-form-item>
+      <el-form-item label prop="job">
+        <el-input v-model="queryParams.job" placeholder="请输入工作岗位" clearable size="small" />
+      </el-form-item>
+      <el-form-item label prop="classId">
+        <el-select v-model="queryParams.classId" placeholder="请选择人员类别" clearable>
+          <el-option
+            v-for="(item, i) in renLie"
+            :key="i"
+            :label="item.dictLabel"
+            :value="item.dictValue"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <input class="input" v-model.number="queryParams.minAge" placeholder="输⼊年龄段" type="number" />
+      <span class="span">----</span>
+      <input class="input1" v-model.number="queryParams.maxAge" placeholder="输⼊年龄段" type="number" />
+      <el-form-item>
+        <el-button type="primary" size="btn" @click="handleQuery">搜索</el-button>
+        <el-button size="btr" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>-->
+
+    <!-- <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['medicalhealth:examine:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['medicalhealth:examine:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          :loading="exportLoading"
+          @click="handleExport"
+          v-hasPermi="['medicalhealth:examine:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar
+        :showSearch.sync="showSearch"
+        @queryTable="getList"
+      ></right-toolbar>
+    </el-row>-->
+    <div class="hezi">
+      <div class="tji">人员体检统计</div>
+      <div style="display: flex; flex-wrap: wrap; padding: 11px 20px">
+        <div style="width: 30%; display: flex; align-items: center; height: 100px">
+          <div class="div-l" style="flex: 2; text-align: right; margin-right: 30px">
+            <span>总体检人数</span>
+          </div>
+          <div class="div-r" style="flex: 1; text-align: right; margin-right: 120px">
+            <span>
+              <span style="font-size: 25px; margin-right: 18px">{{ }}</span>份
+            </span>
+          </div>
+        </div>
+        <div style="width: 30%; display: flex; align-items: center; height: 100px">
+          <div class="div-l" style="flex: 2; text-align: right; margin-right: 30px">
+            <span>已体检人数</span>
+          </div>
+          <div class="div-r" style="flex: 1; text-align: right; margin-right: 120px">
+            <span>
+              <span style="font-size: 25px; margin-right: 18px">{{ }}</span>份
+            </span>
+          </div>
+        </div>
+        <div style="width: 30%; display: flex; align-items: center; height: 100px">
+          <div class="div-l" style="flex: 2; text-align: right; margin-right: 30px">
+            <span>未体检人数</span>
+          </div>
+          <div class="div-r" style="flex: 1; text-align: right; margin-right: 120px">
+            <span>
+              <span style="font-size: 25px; margin-right: 18px">{{ }}</span>份
+            </span>
+          </div>
+        </div>
+      </div>
+    </div>
+
+    <el-table
+      v-loading="loading"
+      :data="examineList"
+      @selection-change="handleSelectionChange"
+      :header-cell-style="{ background: '#003C69', color: 'white' }"
+    >
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="序号" align="center">
+        <template scope="scope">
+          <span>
+            {{
+            (queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1
+            }}
+          </span>
+        </template>
+      </el-table-column>
+      <el-table-column label="单位" align="center" prop="deptName" />
+      <el-table-column label="姓名" align="center" prop="name" />
+      <el-table-column label="年龄" align="center" prop="age" />
+      <el-table-column label="身份证号" align="center" prop="idcard" width="170" />
+      <!-- <el-table-column label="工作岗位" align="center" prop="job" /> -->
+      <el-table-column label="人员类别" align="center" prop="classId">
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.personnel_type" :value="scope.row.classId" />
+        </template>
+      </el-table-column>
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="btp"
+            type="text"
+            @click="tijiann(scope.row)"
+            v-hasPermi="['peopleManage:people:Examinationedit']"
+          >体检完成</el-button>
+          <!-- <el-button
+            size="btp"
+            type="text"
+            @click="tianJia(scope.row)"
+            v-hasPermi="['medicalhealth:examine:edit']"
+          >添加体检信息</el-button>
+          <el-button
+            size="btu"
+            type="text"
+            @click="handleUpdates(scope.row)"
+            v-hasPermi="['medicalhealth:examine:edit']"
+          >查看</el-button>-->
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total > 0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改人员体检信息对话框 -->
+    <el-dialog
+      :title="title"
+      :visible.sync="open"
+      width="500px"
+      append-to-body
+      :close-on-click-modal="false"
+    >
+      <div class="qq">
+        <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+          <el-form-item label="单位" prop="unitId">
+            <treeselect
+              v-model="form.unitId"
+              placeholder="请选择单位"
+              :options="deptOptions"
+              @select="shuxing"
+            />
+          </el-form-item>
+          <el-form-item label="姓名" prop="peopleId">
+            <el-select v-model="form.peopleId" placeholder="请选择姓名">
+              <el-option
+                class="input_xiala"
+                v-for="(item, i) in renYuan"
+                :key="i"
+                :value="item.id"
+                :label="item.name"
+                @click.native="xingMing(item)"
+              ></el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item label="工作岗位" prop="job">
+            <el-input v-model="form.job" placeholder />
+          </el-form-item>
+          <el-form-item label="年龄" prop="age">
+            <el-input v-model="form.age" placeholder disabled />
+          </el-form-item>
+          <el-form-item label="身份证号" prop="idMunber">
+            <el-input v-model="form.idMunber" placeholder disabled />
+          </el-form-item>
+        </el-form>
+      </div>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel" size="btn">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 添加体检信息 -->
+
+    <el-dialog
+      title="添加体检信息"
+      :visible.sync="opene"
+      width="980px"
+      append-to-body
+      :close-on-click-modal="false"
+    >
+      <div class="ww">
+        <el-form ref="form" :model="form" :rules="rules1" :inline="true" style="margin-left: 30px">
+          <el-form-item label="年份" prop="year">
+            <el-input v-model="form.year" placeholder="请输入年份" />
+          </el-form-item>
+          <div class="xiangMu">
+            <el-form-item label="项目" prop="month">
+              <el-select v-model="form.month" placeholder="请选择项目">
+                <el-option
+                  v-for="dict in dict.type.project"
+                  :key="dict.value"
+                  :label="dict.label"
+                  :value="dict.value"
+                ></el-option>
+              </el-select>
+            </el-form-item>
+          </div>
+          <div class="jiben">附件</div>
+          <el-form-item>
+            <FileUpload v-model="fuWenList" />
+          </el-form-item>
+          <div class="jiben">体检信息</div>
+          <el-form-item>
+            <el-input v-model="form.contents" type="textarea" placeholder style="width: 870px"></el-input>
+          </el-form-item>
+        </el-form>
+      </div>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFormT">确 定</el-button>
+        <el-button @click="cancel" size="btn">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 查看体检信息 -->
+
+    <el-dialog
+      :title="title"
+      :visible.sync="openes"
+      width="985px"
+      append-to-body
+      :close-on-click-modal="false"
+    >
+      <el-form ref="form" :model="form" :rules="rules" :inline="true" style="margin-left: 30px">
+        <div class="jiben">体检人员</div>
+        <el-form-item label="单位" prop="yeardate" style="margin-right: 45px; margin-left: 17px">
+          <el-input v-model="form.unitName" disabled />
+        </el-form-item>
+        <el-form-item label="姓名" prop="yeardate" style="margin-right: 45px">
+          <el-input v-model="form.peopleName" disabled />
+        </el-form-item>
+        <el-form-item label="工作岗位" prop="yeardate">
+          <el-input v-model="form.job" disabled />
+        </el-form-item>
+        <div class="ee" v-for="(item, index) in form.examineDetails" :key="item.id">
+          <div class="jiben">
+            体检信息
+            <span style="margin-left: 226px">
+              时间 :
+              <span>{{ item.createTime }}</span>
+            </span>
+            <el-button
+              style="margin-left: 326px"
+              size="btd"
+              type="text"
+              @click="shanchus(item, index)"
+            >删除</el-button>
+          </div>
+          <el-form-item label="年份" prop="yeardate" style="margin-left: 17px">
+            <el-input v-model="item.year" disabled />
+          </el-form-item>
+          <div class="xiangMu">
+            <el-form-item label="项目" prop="type">
+              <el-select v-model="item.month" placeholder="请选择项目" disabled>
+                <el-option
+                  v-for="dict in dict.type.project"
+                  :key="dict.value"
+                  :label="dict.label"
+                  :value="dict.value"
+                ></el-option>
+              </el-select>
+            </el-form-item>
+          </div>
+
+          <div
+            style="
+              margin-bottom: 20px;
+              margin-left: 17px;
+              display: flex;
+              align-items: center;
+            "
+          >
+            <span class="filename">{{ item.fileName }}</span>
+            <a
+              :href="url + item.filePath"
+              :download="item.fileName"
+              title="下载"
+              style="color: white; margin-left: 10px"
+              class="downloadfile"
+            >下载附件</a>
+          </div>
+          <el-form-item style="margin-left: 17px">
+            <el-input
+              v-model="item.contents"
+              type="textarea"
+              placeholder
+              disabled
+              style="width: 839px"
+            ></el-input>
+          </el-form-item>
+        </div>
+      </el-form>
+      <div slot="footer" class="dialog-footer" style="margin-right: 32px">
+        <el-button @click="cancelss" size="btn">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  listExamine,
+  getExamine,
+  delExamine,
+  addExamine,
+  updateExamine,
+  exportExamine,
+  getDept,
+  getZhuChiRen,
+  details,
+  delshanchu,
+  getPeopleExaminationcount,
+  getlist,
+  Examinationedit
+} from "@/api/medicalhealth/examine";
+// 导入树形结构
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+
+// 富文本
+import "quill/dist/quill.core.css";
+import "quill/dist/quill.snow.css";
+import "quill/dist/quill.bubble.css";
+import { quillEditor } from "vue-quill-editor";
+
+// 查询字典
+import { getDicts } from "@/api/system/dict/data";
+
+export default {
+  name: "Examine",
+  components: {
+    Treeselect,
+    quillEditor
+  },
+  dicts: ["personnel_type", "project"],
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 导出遮罩层
+      exportLoading: false,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 人员体检信息表格数据
+      examineList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 是否显示添加体检弹出层
+      opene: false,
+      // 是否显示查看体检弹出层
+      openes: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        unitId: null,
+        peopleId: null,
+        job: null,
+        classId: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {},
+      // 表单校验
+      rules1: {
+        year: [{ required: true, message: "年份不能为空", trigger: "blur" }],
+        month: [{ required: true, message: "项目不能为空", trigger: "change" }]
+      },
+      // 树形单位
+      deptOptions: [],
+      // 人员列表
+      renYuan: [],
+      // 人员类别
+      renLie: [],
+      // 附件列表
+      fuWenList: [],
+      idss: null,
+      // 查看数据
+      topView: [],
+      url: process.env.VUE_APP_BASE_API,
+      tongjilist: []
+    };
+  },
+  created() {
+    this.getList();
+    this.getRenLei();
+    this.getPeopleExaminationcount();
+  },
+  methods: {
+    tijiann(row) {
+      var myDate = new Date();
+      row.job = myDate.getFullYear();
+      Examinationedit(row).then(res => {
+        if (res.code == 200) {
+          this.$modal.msgSuccess("体检已成功");
+          this.getList();
+        }
+      });
+    },
+    getPeopleExaminationcount() {
+      getPeopleExaminationcount().then(res => {
+        console.log(res);
+        if (res.code == 200) {
+          this.tongjilist = res.data;
+        }
+      });
+    },
+    // 删除
+    shanchus(row, index) {
+      const ids = row.id || this.ids;
+      this.$modal
+        .confirm("是否确认删除?")
+        .then(function() {
+          return delshanchu(ids);
+        })
+        .then(() => {
+          this.form.examineDetails.splice(index, 1);
+          this.$modal.msgSuccess("删除成功");
+        })
+        .catch(() => {});
+    },
+    // 获取人员类别
+    getRenLei() {
+      // 字典查询数据
+      this.getDicts("personnel_type").then(response => {
+        this.renLie = response.data;
+      });
+    },
+    // 点击查看人员体检信息
+    handleUpdates(row) {
+      this.reset();
+      this.getTreeselect();
+      const id = row.id || this.ids;
+      getExamine(id).then(response => {
+        this.form = response.data;
+        this.openes = true;
+        this.title = "查看人员体检信息";
+      });
+    },
+    // 点击添加人员体检信息
+    tianJia(row) {
+      this.opene = true;
+      this.idss = row.id;
+      this.reset();
+    },
+    // 点击查看人员体检信息
+    chaKan() {
+      this.openes = true;
+    },
+    cancelss() {
+      this.openes = false;
+    },
+    // 点击人员触发
+    xingMing(data) {
+      this.$set(this.form, "age", data.age);
+      this.$set(this.form, "idMunber", data.idcard);
+      this.classId = data.classId;
+      this.form.peopleName = data.name;
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      getDept().then(response => {
+        this.deptOptions = response.data;
+      });
+    },
+    /** 查询人员体检信息列表 */
+    getList() {
+      this.loading = true;
+      var myDate = new Date();
+      this.queryParams.job = myDate.getFullYear();
+      getlist(this.queryParams).then(response => {
+        this.examineList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.opene = false;
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        unitId: null,
+        peopleId: null,
+        job: null,
+        classId: null
+      };
+      this.fuWenList = [];
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.minAge = null;
+      this.queryParams.maxAge = null;
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id);
+      this.single = selection.length !== 1;
+      this.multiple = !selection.length;
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.getTreeselect();
+      this.reset();
+      this.open = true;
+      this.title = "添加人员体检信息";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      this.getTreeselect();
+      const id = row.id || this.ids;
+      getExamine(id).then(response => {
+        this.form = response.data;
+        this.form.yeardate = null;
+        this.form.checkInformation = null;
+        this.form.type = null;
+        // this.getRenYuan(this.form.unitId);
+        this.opene = true;
+        this.title = "新增人员体检信息";
+      });
+    },
+    // 点击单位触发
+    shuxing(data) {
+      this.form.unitId = data.id;
+      this.form.unitName = data.label;
+      this.getRenYuan(this.form.unitId);
+    },
+    // 获取人员
+    getRenYuan(id) {
+      getZhuChiRen(id).then(res => {
+        this.renYuan = res.data;
+      });
+    },
+    // 体检信息提交
+    submitFormT() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.fuWenList.length > 0) {
+            this.form.fileName = this.fuWenList[0].name;
+            this.form.filePath = this.fuWenList[0].url;
+          }
+          this.form.examineId = this.idss;
+          details(this.form).then(response => {
+            this.$modal.msgSuccess("新增成功");
+            this.opene = false;
+            this.getList();
+            this.reset();
+          });
+        }
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      // this.$refs["form"].validate((valid) => {
+      // if (valid) {
+      if (this.form.id != null) {
+        updateExamine(this.form).then(response => {
+          this.$modal.msgSuccess("修改成功");
+          this.open = false;
+          this.opene = false;
+          this.getList();
+        });
+      } else {
+        addExamine(this.form).then(response => {
+          this.$modal.msgSuccess("新增成功");
+          this.open = false;
+          this.getList();
+        });
+      }
+      // }
+      // });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$confirm("是否确认删除人员体检信息的数据项?", "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      })
+        .then(function() {
+          return delExamine(ids);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("删除成功");
+        })
+        .catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm("是否确认导出所有人员体检信息数据项?", "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      })
+        .then(() => {
+          this.exportLoading = true;
+          return exportExamine(queryParams);
+        })
+        .then(response => {
+          this.$download.name(response.msg);
+          this.exportLoading = false;
+        })
+        .catch(() => {});
+    }
+  }
+};
+</script>
+<style scoped>
+/* 单位树形下拉框 */
+::v-deep .vue-treeselect {
+  width: 280px !important;
+}
+::v-deep .upload-file-list {
+  width: 540px !important;
+}
+/* 对话框背景颜色 */
+.qq {
+  padding: 30px 30px 20px 30px !important;
+}
+::v-deep .qq .vue-treeselect__control {
+  width: 280px !important;
+}
+::v-deep .qq .el-input__inner {
+  width: 280px !important;
+}
+.qq .el-dialog__footer {
+  margin-right: 70px !important;
+}
+::v-deep .el-dialog {
+  background: #004d86 !important;
+}
+::v-deep .el-dialog__header {
+  border-bottom: 1px solid #718a9d;
+}
+::v-deep .el-dialog__title {
+  color: #fff;
+  font: 18px;
+}
+::v-deep .el-input__inner {
+  /* width: 200px !important; */
+  height: 36px;
+  background: transparent;
+  color: #fff;
+  border: 1px solid white !important;
+  margin-top: -10px;
+}
+/* 添加体检信息 */
+.ww .el-form {
+  margin-bottom: 70px !important;
+}
+::v-deep .el-dialog__footer {
+  margin-right: 27px !important;
+}
+/*调整表单间距 */
+::v-deep .el-form-item__content {
+  width: 200px;
+}
+.ee .el-form {
+  margin-bottom: 70px !important;
+}
+
+/* 单位框背景颜色 */
+::v-deep .vue-treeselect__control {
+  background: #004d86 !important;
+}
+/* 单位下拉菜单选中字体颜色 */
+::v-deep .vue-treeselect__single-value {
+  color: #fff !important;
+}
+::v-deep .qq > .el-form-item__content > .vue-treeselect__control {
+  width: 280px !important;
+}
+/* 富文本删除功能 */
+::v-deep .ql-blockquote {
+  display: none !important;
+}
+::v-deep .ql-strike {
+  display: none !important;
+}
+::v-deep .ql-script {
+  display: none !important;
+}
+::v-deep .ql-code-block {
+  display: none !important;
+}
+::v-deep .ql-direction {
+  display: none !important;
+}
+::v-deep .ql-toolbar.ql-snow .ql-formats {
+  margin-right: 7px;
+}
+/* 富文本 */
+::v-deep .ql-snow .ql-fill,
+.ql-snow .ql-stroke.ql-fill {
+  fill: #fff !important;
+}
+::v-deep .ql-snow .ql-stroke {
+  stroke: #fff !important;
+}
+::v-deep .ql-snow .ql-picker {
+  color: #fff !important;
+}
+::v-deep .ql-editor ql-blank {
+  color: #fff !important;
+}
+.xiangMu {
+  display: inline-block;
+}
+.xiangMu > .el-form-item {
+  margin-left: 35px;
+}
+/* 体检 btp */
+.el-button--btp.is-active,
+.el-button--btp:active {
+  background: #1d96ff;
+  border-color: #1d96ff;
+  color: #ffffff;
+}
+
+.el-button--btp:focus,
+.el-button--btp:hover {
+  background: #1d96ff;
+  border-color: #1d96ff;
+  color: #ffffff;
+}
+
+.el-button--btp {
+  width: 116px !important;
+  border: 1px solid transparent;
+  padding: 3px 8px;
+  font-size: 14px;
+  line-height: 1.5;
+  border-radius: 3px;
+  color: #fff;
+  background-color: #1d96ff;
+}
+.el-select-dropdown__item.selected {
+  color: #111;
+}
+::v-deep .el-input.is-disabled .el-input__inner {
+  background-color: transparent;
+  color: #fff;
+}
+.input {
+  width: 150px;
+  height: 36px;
+  line-height: 36px;
+  border: 1px solid #fff;
+  background-color: transparent;
+  outline: none;
+  color: #fff;
+  padding: 0 20px;
+  font-size: 14px;
+  border-radius: 4px;
+}
+.input1 {
+  width: 150px;
+  height: 36px;
+  line-height: 36px;
+  border: 1px solid #fff;
+  background-color: transparent;
+  outline: none;
+  color: #fff;
+  padding: 0 20px;
+  font-size: 14px;
+  margin-right: 10px;
+  border-radius: 4px;
+}
+.span {
+  margin: 0 5px;
+  color: #fff;
+}
+.input,
+.input1::-webkit-outer-spin-button,
+input::-webkit-inner-spin-button {
+  -webkit-appearance: none;
+}
+.input,
+.input1[type="number"] {
+  -moz-appearance: textfield;
+}
+::v-deep .el-upload__tip {
+  color: #fff;
+  margin-top: 0px;
+  margin-left: 0px;
+}
+::v-deep .el-link.el-link--default {
+  color: #fff;
+  padding-left: 19px;
+}
+::v-deep .upload-file-uploader {
+  display: flex;
+  width: 500px;
+}
+::v-deep .el-upload {
+  margin-right: 13px;
+}
+::v-deep .upload-file-list .el-upload-list .el-upload-list--text {
+  width: 442px;
+}
+/* 附件名称样式 */
+.filename {
+  display: inline-block;
+  color: white;
+  width: 728px;
+  height: 30px;
+  border: 1px solid white;
+  line-height: 30px;
+  text-indent: 1em;
+}
+/* 下载按钮 */
+.downloadfile {
+  border: 1px solid white;
+  display: inline-block;
+  width: 100px;
+  height: 33px;
+  border-radius: 5px;
+  line-height: 33px;
+  text-align: center;
+}
+::v-deep .el-textarea__inner {
+  min-height: 145px !important;
+}
+::v-deep .upload-file-list {
+  width: 500px;
+}
+
+.hezi {
+  margin-bottom: 13px;
+  margin-top: 15px;
+  position: relative;
+  background: rgb(0, 60, 105);
+  color: #fff;
+  font-size: 18px;
+  font-weight: 600;
+}
+
+.tji {
+  width: 176px;
+  height: 36px;
+  text-align: center;
+  line-height: 36px;
+  position: absolute;
+  top: -18px;
+  right: 87px;
+  color: #fff;
+  font-size: 18px;
+  font-weight: 600;
+  background: #004d86;
+}
+</style>

+ 13 - 5
src/views/peopleManage/people/index.vue

@@ -555,6 +555,16 @@
           </el-table-column>
           <el-table-column label="年龄" align="center" prop="age" />
           <el-table-column label="身份证号" align="center" prop="idcard" width="170" />
+          <el-table-column label="在位情况" align="center" prop="reign" width="150">
+            <template slot-scope="scope">
+              <dict-tag
+                style="display:inline-block;"
+                :options="dict.type.people_state"
+                :value="scope.row.reign"
+              />
+              <span v-if="scope.row.statusrk">- {{scope.row.statusrk}}</span>
+            </template>
+          </el-table-column>
           <el-table-column label="部职别" align="center" width="300" prop="duty" />
           <el-table-column label="职务" align="center" width="120" prop="postId">
             <template slot-scope="scope">
@@ -568,11 +578,6 @@
             </template>
           </el-table-column>
           <el-table-column label="籍贯" align="center" prop="origin" width="150" />
-          <el-table-column label="在位情况" align="center" prop="reign" width="90">
-            <template slot-scope="scope">
-              <dict-tag :options="dict.type.people_state" :value="scope.row.reign" />
-            </template>
-          </el-table-column>
           <el-table-column label="操作" align="center" width="200" fixed="right">
             <template slot-scope="scope">
               <el-button
@@ -965,6 +970,9 @@
               placeholder
             ></el-date-picker>
           </el-form-item>
+          <el-form-item label="在位备注" prop="statusrk">
+            <el-input v-model="form.statusrk" placeholder />
+          </el-form-item>
           <div class="jiben">家庭信息</div>
           <!-- <span @click="tiaddfun" class="zengJia">+</span> -->
           <el-row