Skip to content

Commit

Permalink
경로 변경 및 컴포넌트를 단일 페이지에 나타내기 위한 컨테이너 컴포넌트 생성
Browse files Browse the repository at this point in the history
  • Loading branch information
yhlee002 committed Jul 22, 2024
1 parent 2e414be commit 73434e2
Show file tree
Hide file tree
Showing 20 changed files with 212 additions and 38 deletions.
4 changes: 2 additions & 2 deletions src/App.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script setup>
import {RouterView} from 'vue-router'
import HeaderComponent from './components/fragment/HeaderComponent.vue'
import FooterComponent from './components/fragment/FooterComponent.vue'
import HeaderComponent from '@/components/fragment/HeaderComponent.vue'
import FooterComponent from '@/components/fragment/FooterComponent.vue'
import BasicModal from '@/components/BasicModal.vue';
import {useModalStore} from '@/stores/modal.js';
import {storeToRefs} from "pinia";
Expand Down
2 changes: 1 addition & 1 deletion src/components/admin/AdminCommentImpComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div class="inner-block">
<div class="content">
<div class="block-title-box">
<h2 class="block-title">관리자 페이지 > 공지사항</h2>
<h2 class="block-title">관리자 페이지 > 게시글 댓글 조회</h2>
</div>


Expand Down
2 changes: 1 addition & 1 deletion src/components/admin/AdminComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ commentStore.getComments(1, 10, null);
<div class="block-title">
<h3>회원 관리</h3>
<small>
<router-link to="/users">더보기</router-link>
<router-link to="/admin/users">더보기</router-link>
</small>
</div>
<div class="block-content">
Expand Down
27 changes: 27 additions & 0 deletions src/components/admin/user/AdminUserBoardContainer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<script setup>
import AdminUserBoard from "@/components/admin/user/sub/AdminUserBoardComponent.vue";
const props = defineProps(['memNo']);
</script>

<template>
<div id="index_user_boards" class="wrapper-block">
<div class="inner">
<div class="inner-block">
<div class="content">
<div class="block-title-box">
<h2 class="block-title">회원이 작성한 게시글</h2>
</div>



<AdminUserBoard :memNo="memNo"></AdminUserBoard>
</div>
</div>
</div>
</div>
</template>

<style scoped>
</style>
25 changes: 25 additions & 0 deletions src/components/admin/user/AdminUserBoardRecommendedContainer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<script setup>
import AdminUserBoardRecommended from "@/components/admin/user/sub/AdminUserBoardRecommendedComponent.vue";
const props = defineProps(['memNo']);
</script>

<template>
<div id="index_user_boards" class="wrapper-block">
<div class="inner">
<div class="inner-block">
<div class="content">
<div class="block-title-box">
<h2 class="block-title">회원이 추천한 게시글</h2>
</div>

<AdminUserBoardRecommended :memNo="memNo"></AdminUserBoardRecommended>
</div>
</div>
</div>
</div>
</template>

<style scoped>
</style>
25 changes: 25 additions & 0 deletions src/components/admin/user/AdminUserCommentImpContainer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<script setup>
import AdminUserComment from "@/components/admin/user/sub/AdminUserCommentImpComponent.vue";
const props = defineProps(['memNo']);
</script>

<template>
<div id="index_userdetail" class="wrapper-block">
<div class="inner">
<div class="inner-block">
<div class="content">
<div class="block-title-box">
<h2 class="block-title">회원이 작성한 댓글</h2>
</div>

<AdminUserComment :memNo="memNo"></AdminUserComment>
</div>
</div>
</div>
</div>
</template>

<style scoped>
</style>
11 changes: 11 additions & 0 deletions src/components/admin/user/AdminUserCommentMovContainer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<script setup>
</script>

<template>

</template>

<style scoped>
</style>
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import Swal from 'sweetalert2';
import {computed, ref, watch} from "vue";
import SortingComponent from "@/components/icon/SortingComponent.vue";
import PagenationComponent from "@/components/sub/PagenationComponent.vue";
import AdminUserDetailComponent from "@/components/admin/AdminUserDetailComponent.vue";
import AdminUserDetailComponent from "@/components/admin/user/AdminUserDetailComponent.vue";
import Pagenation from "@/components/sub/PagenationComponent.vue";
const props = defineProps(['page'])
const userStore = useUserStore();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<script setup>
import '@/assets/css/admin/user.css';
import {ref, watch} from "vue";
import AdminUserLoginLogsComponent from "@/components/admin/user/sub/AdminUserLoginLogsComponent.vue";
import AdminUserBoardComponent from "@/components/admin/user/sub/AdminUserBoardComponent.vue";
import AdminUserCommentComponent from "@/components/admin/user/sub/AdminUserCommentImpComponent.vue";
import AdminUserNoticeComponent from "@/components/admin/user/sub/AdminUserNoticeComponent.vue";
import UserImageComponent from "@/components/icon/UserImageComponent.vue";
import AdminUserBoardRecommendedComponent from "@/components/admin/user/sub/AdminUserBoardRecommendedComponent.vue";
import Swal from "sweetalert2";
import {useUserStore} from "@/stores/user.js";
import {ref, watch} from "vue";
import {useRouter} from "vue-router";
import AdminUserLoginLogsComponent from "@/components/admin/AdminUserLoginLogsComponent.vue";
import AdminUserBoardComponent from "@/components/admin/AdminUserBoardComponent.vue";
import AdminUserCommentComponent from "@/components/admin/AdminUserCommentComponent.vue";
import AdminUserNoticeComponent from "@/components/admin/AdminUserNoticeComponent.vue";
import {useBoardStore} from "@/stores/board";
import {useCommentStore} from "@/stores/comment";
import UserImageComponent from "@/components/icon/UserImageComponent.vue";
import AdminUserBoardRecommendedComponent from "@/components/admin/AdminUserBoardRecommendedComponent.vue";
import {useUserStore} from "@/stores/user.js";
import {useBoardStore} from "@/stores/board.js";
import {useCommentStore} from "@/stores/comment.js";
const router = useRouter();
let id = ref(router.currentRoute.value.params.id);
Expand Down Expand Up @@ -231,24 +231,39 @@ function modifyUserInfo() {

<div id="userDetailTabContents">
<div id="userDetailTab0" class="user-detail-tab">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/users/notices?memNo=${member.memNo}`">더보기</router-link>
</div>
<AdminUserNoticeComponent :memNo="id"></AdminUserNoticeComponent>
</div>

<div id="userDetailTab1" class="user-detail-tab active">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/users/boards?memNo=${member.memNo}`">더보기</router-link>
</div>
<!-- 작성한 글 -->
<AdminUserBoardComponent :memNo="id"></AdminUserBoardComponent>
</div>

<div id="userDetailTab2" class="user-detail-tab">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/users/recommended-boards?memNo=${member.memNo}`">더보기</router-link>
</div>
<AdminUserBoardRecommendedComponent :memNo="id"></AdminUserBoardRecommendedComponent>
</div>

<div id="userDetailTab3" class="user-detail-tab">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/users/imp-comments?memNo=${member.memNo}`">더보기</router-link>
</div>
<!-- 작성한 댓글 -->
<AdminUserCommentComponent :memNo="id"></AdminUserCommentComponent>
</div>

<div id="userDetailTab4" class="user-detail-tab">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/users/loginlogs?memNo=${member.memNo}`">더보기</router-link>
</div>
<!-- 로그인 기록 -->
<AdminUserLoginLogsComponent :memNo="id"></AdminUserLoginLogsComponent>
</div>
Expand Down Expand Up @@ -308,5 +323,6 @@ function modifyUserInfo() {
#userDetailTabContents .user-detail-tab.active {
display: flex;
flex-direction: column;
}
</style>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup>
import AdminUserDetail from "@/components/admin/AdminUserDetailComponent.vue";
import AdminUserDetail from "@/components/admin/user/AdminUserDetailComponent.vue";
const props = defineProps(['memNo']);
</script>
Expand Down
25 changes: 25 additions & 0 deletions src/components/admin/user/AdminUserLoginLogContainer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<script setup>
import AdminUserLoginLog from "@/components/admin/user/sub/AdminUserLoginLogsComponent.vue";
const props = defineProps(['memNo']);
</script>

<template>
<div id="index_user_notices" class="wrapper-block">
<div class="inner">
<div class="inner-block">
<div class="content">
<div class="block-title-box">
<h2 class="block-title">회원 로그인 기록</h2>
</div>

<AdminUserLoginLog :memNo="memNo"></AdminUserLoginLog>
</div>
</div>
</div>
</div>
</template>

<style scoped>
</style>
25 changes: 25 additions & 0 deletions src/components/admin/user/AdminUserNoticeContainer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<script setup>
import AdminUserNotice from "@/components/admin/user/sub/AdminUserNoticeComponent.vue";
const props = defineProps(['memNo']);
</script>

<template>
<div id="index_user_notices" class="wrapper-block">
<div class="inner">
<div class="inner-block">
<div class="content">
<div class="block-title-box">
<h2 class="block-title">회원이 작성한 공지사항</h2>
</div>

<AdminUserNotice :memNo="memNo"></AdminUserNotice>
</div>
</div>
</div>
</div>
</template>

<style scoped>
</style>
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,6 @@ function goBoardPage(id) {

<template>
<div id="userBoards">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/notices?memNo=${memNo}`">더보기</router-link>
</div>
<table id="userBoardsTable">
<thead>
<tr>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,6 @@ function goBoardPage(id) {

<template>
<div id="userRecommendedBoards">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/notices?memNo=${memNo}`">더보기</router-link>
</div>
<table id="userRecommendedBoardsTable">
<thead>
<tr>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,6 @@ function goBoardPage(id) {

<template>
<div id="userComments">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/notices?memNo=${memNo}`">더보기</router-link>
</div>
<table id="userCommentsTable">
<thead>
<tr>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@ const logs = logStore.logs;

<template>
<div id="loginLogs">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/notices?memNo=${memNo}`">더보기</router-link>
</div>
<table id="loginLogsTable">
<thead>
<tr>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script setup>
import Swal from "sweetalert2";
import {ref} from "vue";
import {useNoticeStore} from "@/stores/notice";
import {useNoticeStore} from "@/stores/notice.js";
import {useRouter} from "vue-router";
const router = useRouter()
Expand Down Expand Up @@ -63,9 +63,6 @@ function goBoardPage(id) {

<template>
<div id="userNotices">
<div style="display: flex; justify-content: end; width: 100%; margin: 0.5rem 0;">
<router-link :to="`/admin/notices?memNo=${memNo}`">더보기</router-link>
</div>
<table id="userNoticesTable">
<thead>
<tr>
Expand Down
2 changes: 1 addition & 1 deletion src/components/board/NoticeComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {useRouter} from "vue-router";
import {useUserStore} from "@/stores/user.js";
import {ref, watch} from "vue";
import Pagenation from "@/components/sub/PagenationComponent.vue";
import {useBoardStore} from "@/stores/board";
import {useBoardStore} from "@/stores/board.js";
const props = defineProps(['page']);
Expand Down
2 changes: 1 addition & 1 deletion src/components/sub/CommentItemComponent.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import UserCard from "@/components/sub/UserCardComponent.vue";
import Swal from 'sweetalert2';
import {ref} from "vue";
import {useUserStore} from "@/stores/user.js";
import {useCommentStore} from "@/stores/comment";
import {useCommentStore} from "@/stores/comment.js";
import emitter from '@/eventBus/emitter.js';
const props = defineProps(['comment', 'editMode']);
Expand Down
Loading

0 comments on commit 73434e2

Please sign in to comment.