| | |
| | | label-position="right" |
| | | > |
| | | <!-- 部门名称 --> |
| | | <span style="heght:18px;display:block;line-height: 14px;"> |
| | | <span style="height:18px;display:block;line-height: 14px;"> |
| | | 执法人员结构 |
| | | </span> |
| | | <el-form-item class="optionItem" label="部门名称:" prop="name"> |
| | |
| | | </template> |
| | | <script> |
| | | import { deepClone } from "@/utils/helper"; |
| | | import { updateTeamInfo } from "@/api/system/portal/teamConstruction"; |
| | | import { SUCCESS_CODE } from "@/utils"; |
| | | import {addTeam, updateTeamInfo} from "@/api/system/portal/teamConstruction"; |
| | | |
| | | export default { |
| | | data() { |
| | | |
| | | return { |
| | | updateData: null, |
| | | rules: { |
| | |
| | | submitUpdate() { |
| | | this.$refs.user.validate((valid) => { |
| | | if (valid) { |
| | | updateTeamInfo(this.updateData) |
| | | .then(({ code, message }) => { |
| | | if (code === SUCCESS_CODE) { |
| | | this.$emit('closeUpdateDialog'); |
| | | this.$message({ type: 'success', message }); |
| | | } else { |
| | | this.$message({ type: 'error', message }); |
| | | } |
| | | }) |
| | | .catch(err => { |
| | | this.$message({ type: 'error', message: err }); |
| | | }); |
| | | if (this.isUpdate) { |
| | | updateTeamInfo(this.updateData) |
| | | .then(() => { |
| | | this.$emit('closeUpdateDialog'); |
| | | this.$message({ type: 'success', message: '操作成功' }); |
| | | }) |
| | | .catch(err => { |
| | | this.$message({ type: 'error', message: err }); |
| | | }); |
| | | } else { |
| | | addTeam(this.depart) |
| | | .then(() => { |
| | | this.$message({ type: 'success', message: '操作成功' }); |
| | | this.$emit('closeUpdateDialog'); |
| | | }) |
| | | .catch(err => { |
| | | this.$message({ type: 'error', message: err }); |
| | | }); |
| | | } |
| | | } else { |
| | | this.$message({ type: 'warning', message: '请检查必填项' }); |
| | | } |
| | |
| | | this.$emit('closeUpdateDialog'); |
| | | } |
| | | }, |
| | | props: ['updateDepartmentData'] |
| | | props: ['updateDepartmentData', 'isUpdate'] |
| | | }; |
| | | </script> |
| | | <style lang="scss" scoped> |
| | | .updateUser { |
| | | border-radius: 1px; |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | |
| | | main { |
| | | text-align: left; |
| | | padding: 0 55px; |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | |
| | | .mainContent { |
| | | display: flex; |
| | |
| | | } |
| | | } |
| | | |
| | | .updateUser::v-deep .el-form-item__label { |
| | | color: #4b9bb7; |
| | | } |
| | | // .updateUser::v-deep .el-form-item__label { |
| | | // color: #4b9bb7; |
| | | // } |
| | | |
| | | .updateUser::v-deep .el-input__inner { |
| | | background-color: #09152f; |
| | | border: 1px solid #17324c; |
| | | } |
| | | // .updateUser::v-deep .el-input__inner { |
| | | // background-color: #09152f; |
| | | // border: 1px solid #17324c; |
| | | // } |
| | | |
| | | .addPerson { |
| | | display: flex; |
| | |
| | | min-height: 240px; |
| | | max-height: 260px; |
| | | overflow: hidden; |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | position: relative; |
| | | max-width: 220px; |
| | | |
| | |
| | | right: 20px; |
| | | width: 20px; |
| | | height: 180px; |
| | | background-color: #09152f; |
| | | // background-color: #09152f; |
| | | } |
| | | |
| | | .item { |