| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { departmentAdd, departmentEdit, departmentDetail } from '@/api/system/deptment'; |
| | | import {departmentAdd, departmentDetail, departmentEdit} from '@/api/system/deptment'; |
| | | import winSm from '@/components/win/win-sm'; |
| | | import myButton from '@/components/myButton/myButton'; |
| | | import * as finsystenant from '@/api/baseSetting/finsystenant'; |
| | | import { findParentIds } from '@/utils/index'; |
| | | import { mapGetters } from 'vuex'; |
| | | import {findParentIds} from '@/utils/index'; |
| | | |
| | | export default { |
| | | components: { winSm, myButton }, |
| | |
| | | if (this.setting.id) { |
| | | // 编辑接口 |
| | | departmentEdit(params).then((res) => { |
| | | if (res) { |
| | | this.$message.success('保存成功!'); |
| | | this.close(); |
| | | this.$emit('search'); |
| | | } else { |
| | | this.$message.error('保存失败'); |
| | | } |
| | | |
| | | this.$message.success('保存成功!'); |
| | | this.close(); |
| | | this.$emit('search'); |
| | | }); |
| | | } else { |
| | | departmentAdd(params).then((res) => { |
| | | if (res) { |
| | | this.$message.success('保存成功!'); |
| | | this.close(); |
| | | this.$emit('search'); |
| | | } else { |
| | | this.$message.error('保存失败'); |
| | | } |
| | | this.$message.success('保存成功!'); |
| | | this.close(); |
| | | this.$emit('search'); |
| | | }); |
| | | } |
| | | } else { |