<template>
  <unit-manage-home @changeOperation="changeOperation" v-if="!operationType" />
  <unit-manage-edit :current-op-obj="currentOpObj" :operation-type="operationType" @changeOperation="changeOperation" v-else />
</template>

<script>
import UnitManageHome from "@/views/main/c-views/system-manage/unit-manage/UnitManageHome.vue";
import UnitManageEdit from "@/views/main/c-views/system-manage/unit-manage/UnitManageEdit.vue";
import {useClickRouterToHome} from "@/units/use-method/usePagination";
export default {
  name: "UnitManage",
  components: {UnitManageEdit, UnitManageHome},
  setup(){
    const {changeOperation,operationType,currentOpObj} =useClickRouterToHome();
    return {
      changeOperation,operationType,currentOpObj
    }
  }
}
</script>

<style scoped  lang="scss">
.fade-leave-active,.fade-enter-active{
  transition: 1s all;
}
.fade-leave-to,.fade-enter-from{
  opacity: 0;
  transform: translateX(30px);
}
</style>