| | |
| | | :visible.sync="dialogVisible" |
| | | title="奖惩记录" |
| | | width="50%" |
| | | @open="getUserList" |
| | | @open=" |
| | | () => { |
| | | this.getUserList(); |
| | | this.getRewardPunishNameList(); |
| | | } |
| | | " |
| | | > |
| | | <div style="height: 40vh"> |
| | | <el-form ref="form" :model="form" :rules="rules" label-width="120px"> |
| | |
| | | <el-col :span="12"> |
| | | <el-form-item label="员工姓名" prop="userId"> |
| | | <el-select |
| | | :disabled="form.id" |
| | | :disabled="form.id == null" |
| | | v-model="form.userId" |
| | | placeholder="请选择员工姓名" |
| | | size="small" |
| | |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="奖惩名称" prop="rewardPunishName"> |
| | | <el-input |
| | | placeholder="请输入奖惩名称" |
| | | type="textarea" |
| | | :rows="1" |
| | | v-model="form.rewardPunishName" |
| | | <el-select |
| | | size="small" |
| | | ></el-input> |
| | | placeholder="请输入奖惩名称" |
| | | v-model="form.rewardPunishName" |
| | | style="width: 100%" |
| | | > |
| | | <el-option |
| | | :key="index" |
| | | v-for="(item, index) in rewardPunishNameList" |
| | | :label="item.dictLabel" |
| | | :value="item.dictValue" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="奖惩时间" prop="rewardPunishTime"> |
| | | <el-date-picker |
| | | v-model="form.rewardPunishTime" |
| | | format="yyyy-MM-dd" |
| | | format="yyyy-MM-dd HH:mm:ss" |
| | | placeholder="选择日期" |
| | | size="small" |
| | | style="width: 100%" |
| | | type="date" |
| | | value-format="yyyy-MM-dd" |
| | | type="datetime" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | controls-position="right" |
| | | :precision="2" |
| | | style="width: 100%" |
| | | :min="0" |
| | | v-model="form.rewardPunishSum" |
| | | size="small" |
| | | placeholder="请输入奖惩金额" |
| | |
| | | } from "@/api/cnas/personal/personRewardPunishmentRecord"; |
| | | import { selectUserListByPerformance } from "@/api/system/user"; |
| | | import { transformExcel } from "@/utils/file"; |
| | | import { getDicts } from "@/api/system/dict/data"; |
| | | |
| | | export default { |
| | | data() { |
| | |
| | | { |
| | | required: true, |
| | | message: "请输入奖惩名称", |
| | | trigger: "blur", |
| | | trigger: "change", |
| | | }, |
| | | ], |
| | | rewardPunishTime: [ |
| | |
| | | ], |
| | | }, |
| | | responsibleOptions: [], |
| | | rewardPunishNameList: [], |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.getPersonnelTraining(); |
| | | this.getUserList(); |
| | | this.getRewardPunishNameList(); |
| | | }, |
| | | methods: { |
| | | getRewardPunishNameList() { |
| | | this.rewardPunishNameList = []; |
| | | getDicts("sys_rewardandpunishment_type").then((res) => { |
| | | this.rewardPunishNameList = res.data; |
| | | }); |
| | | }, |
| | | refreshTable() { |
| | | this.search.userName = ""; |
| | | this.search.searchTimeList = []; |