-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[S03P31A503-109] feature/FE/meetinganalysis : Add meeting analysis de…
…sign
- Loading branch information
1 parent
9838e7e
commit 919efd4
Showing
12 changed files
with
432 additions
and
83 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { Doughnut } from "vue-chartjs"; | ||
|
||
export default { | ||
extends: Doughnut, | ||
props: { | ||
data: Object | ||
}, | ||
mounted() { | ||
this.renderChart(this.data, { | ||
borderWidth: "10px", | ||
hoverBackgroundColor: "red", | ||
hoverBorderWidth: "10px", | ||
legend: { | ||
labels: { | ||
fontColor: "#FEFEFE" | ||
} | ||
}, | ||
}); | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,59 @@ | ||
<template> | ||
<div> | ||
|
||
<div class="mx-auto mt-3"> | ||
<div class="row no-gutters"> | ||
<div class="col-5"> | ||
<h3 class="analysis-title">최근 음주 통계</h3> | ||
<div v-if="recentData"> | ||
<recent class="analysis" :data="recentData"></recent> | ||
</div> | ||
</div> | ||
<div class="col-5 offset-2"> | ||
<h3 class="analysis-title">주종 통계</h3> | ||
<div v-if="alcoholTypeData"> | ||
<alcohol-type class="analysis" :data="alcoholTypeData"></alcohol-type> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
import { mapActions, mapState } from 'vuex'; | ||
import Recent from "@/components/mypage/RecentChart.js"; | ||
import AlcoholType from "@/components/mypage/AlcoholTypeChart.js"; | ||
export default { | ||
name: 'Analysis' | ||
name: 'Analysis', | ||
components: { | ||
Recent, | ||
AlcoholType | ||
}, | ||
computed: { | ||
...mapState(['user']), | ||
...mapState('mypageStore', ['recentData', 'alcoholTypeData']) | ||
}, | ||
watch: { | ||
user() { | ||
this.fetchAnalysisData(); | ||
} | ||
}, | ||
methods: { | ||
...mapActions('mypageStore', ['fetchAnalysisData']) | ||
}, | ||
created() { | ||
this.fetchAnalysisData(); | ||
} | ||
} | ||
</script> | ||
|
||
<style scoped> | ||
.analysis-title { | ||
color: white !important; | ||
} | ||
.analysis { | ||
max-width: 25vw; | ||
margin-left: auto; | ||
margin-right: auto; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.