|
@@ -122,30 +122,35 @@
|
|
|
<el-table-column label="单位" align="center" prop="unitName" />
|
|
|
<el-table-column label="姓名" align="center" prop="peopleName" />
|
|
|
<el-table-column label="工作岗位" align="center" prop="job" />
|
|
|
- <el-table-column label="人员类别" align="center" prop="classId" />
|
|
|
+ <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>
|
|
|
- <!-- <template slot-scope="scope">-->
|
|
|
- <el-button @click="tianJia"> 添加体检信息 </el-button>
|
|
|
- <el-button @click="chaKan"> 查看 </el-button>
|
|
|
- <!-- <el-button
|
|
|
- size="btu"
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <!-- <el-button @click="handleUpdate"> 添加体检信息 </el-button>
|
|
|
+ <el-button @click="chaKan"> 查看 </el-button> -->
|
|
|
+ <el-button
|
|
|
type="text"
|
|
|
@click="handleUpdate(scope.row)"
|
|
|
v-hasPermi="['medicalhealth:examine:edit']"
|
|
|
- >修改</el-button
|
|
|
+ >添加体检信息</el-button
|
|
|
>
|
|
|
<el-button
|
|
|
size="btd"
|
|
|
type="text"
|
|
|
- @click="handleDelete(scope.row)"
|
|
|
- v-hasPermi="['medicalhealth:examine:remove']"
|
|
|
- >删除</el-button
|
|
|
- > -->
|
|
|
+ @click="handleUpdates(scope.row)"
|
|
|
+ v-hasPermi="['medicalhealth:examine:edit']"
|
|
|
+ >查看</el-button
|
|
|
+ >
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
@@ -183,21 +188,21 @@
|
|
|
:key="i"
|
|
|
:value="item.id"
|
|
|
:label="item.name"
|
|
|
- @click.native="xingMing(item.name)"
|
|
|
+ @click.native="xingMing(item)"
|
|
|
>
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="工作岗位" prop="job">
|
|
|
+ <!-- <el-form-item label="工作岗位" prop="job">
|
|
|
<el-input v-model="form.job" placeholder="请输入工作岗位" />
|
|
|
</el-form-item>
|
|
|
<el-form-item label="人员类别" prop="classId">
|
|
|
<el-input v-model="form.classId" placeholder="请输入人员类别" />
|
|
|
- </el-form-item>
|
|
|
+ </el-form-item> -->
|
|
|
</el-form>
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
|
|
- <el-button @click="cancel">取 消</el-button>
|
|
|
+ <el-button @click="cancel" size="btn">取 消</el-button>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
|
|
@@ -209,34 +214,48 @@
|
|
|
append-to-body
|
|
|
:close-on-click-modal="false"
|
|
|
>
|
|
|
- 年份
|
|
|
- <input type="text" />
|
|
|
- <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>
|
|
|
+ <el-form ref="form" :model="form" :rules="rules">
|
|
|
+ <el-form-item label="年份" prop="yeardate">
|
|
|
+ <el-input v-model="form.yeardate" />
|
|
|
+ </el-form-item>
|
|
|
+ <div class="jiben">体检信息</div>
|
|
|
+ <el-form-item>
|
|
|
+ <quill-editor
|
|
|
+ class="quill-editor"
|
|
|
+ ref="myTextEditor"
|
|
|
+ v-model="form.checkInformation"
|
|
|
+ style="height: 150px; width: 920px; margin-left: 0px"
|
|
|
+ ></quill-editor>
|
|
|
+ </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="openes"
|
|
|
width="700px"
|
|
|
append-to-body
|
|
|
:close-on-click-modal="false"
|
|
|
>
|
|
|
- 年份
|
|
|
- <input type="text" />
|
|
|
- <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>
|
|
|
+ <el-form ref="form" :model="form" :rules="rules">
|
|
|
+ <el-form-item label="年份" prop="yeardate">
|
|
|
+ <el-input v-model="form.yeardate" />
|
|
|
+ </el-form-item>
|
|
|
+ <div class="jiben">体检信息</div>
|
|
|
+ <el-form-item>
|
|
|
+ <quill-editor
|
|
|
+ class="quill-editor"
|
|
|
+ ref="myTextEditor"
|
|
|
+ v-model="form.checkInformation"
|
|
|
+ style="height: 150px; width: 920px; margin-left: 0px"
|
|
|
+ ></quill-editor>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
</el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
@@ -268,6 +287,7 @@ export default {
|
|
|
Treeselect,
|
|
|
quillEditor,
|
|
|
},
|
|
|
+ dicts: ["personnel_type"],
|
|
|
data() {
|
|
|
return {
|
|
|
// 遮罩层
|
|
@@ -317,6 +337,25 @@ export default {
|
|
|
this.getList();
|
|
|
},
|
|
|
methods: {
|
|
|
+ // // 添加人员体检信息
|
|
|
+ // submitForms() {
|
|
|
+ // addExamine(this.form).then((response) => {
|
|
|
+ // this.$modal.msgSuccess("新增成功");
|
|
|
+ // this.opene = false;
|
|
|
+ // this.getList();
|
|
|
+ // });
|
|
|
+ // },
|
|
|
+ // 点击查看人员体检信息
|
|
|
+ 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() {
|
|
|
this.opene = true;
|
|
@@ -326,8 +365,11 @@ export default {
|
|
|
this.openes = true;
|
|
|
},
|
|
|
// 点击人员触发
|
|
|
- xingMing(name) {
|
|
|
- this.form.peopleName = name;
|
|
|
+ xingMing(data) {
|
|
|
+ // console.log(data);
|
|
|
+ this.classId = data.classId;
|
|
|
+ this.job = data.job;
|
|
|
+ this.form.peopleName = data.name;
|
|
|
},
|
|
|
/** 查询部门下拉树结构 */
|
|
|
getTreeselect() {
|
|
@@ -390,14 +432,13 @@ export default {
|
|
|
const id = row.id || this.ids;
|
|
|
getExamine(id).then((response) => {
|
|
|
this.form = response.data;
|
|
|
- this.getRenYuan(this.form.unitId);
|
|
|
- this.open = true;
|
|
|
- this.title = "修改人员体检信息";
|
|
|
+ // this.getRenYuan(this.form.unitId);
|
|
|
+ this.opene = true;
|
|
|
+ this.title = "新增人员体检信息";
|
|
|
});
|
|
|
},
|
|
|
// 点击单位触发
|
|
|
shuxing(data) {
|
|
|
- console.log(data);
|
|
|
this.form.unitId = data.id;
|
|
|
this.form.unitName = data.label;
|
|
|
this.getRenYuan(this.form.unitId);
|
|
@@ -413,9 +454,11 @@ export default {
|
|
|
this.$refs["form"].validate((valid) => {
|
|
|
if (valid) {
|
|
|
if (this.form.id != null) {
|
|
|
+ console.log(this.form);
|
|
|
updateExamine(this.form).then((response) => {
|
|
|
this.$modal.msgSuccess("修改成功");
|
|
|
this.open = false;
|
|
|
+ this.opene = false;
|
|
|
this.getList();
|
|
|
});
|
|
|
} else {
|