19 KB
14.9 KB
18.7 KB
18.5 KB
18.1 KB
16.6 KB
18.4 KB
18 KB
17 KB
17.7 KB
17.3 KB
14 KB
18.3 KB
17.7 KB
13.6 KB
14.1 KB
15.9 KB
18 KB
17.7 KB
18.6 KB
19.1 KB
19 KB
20.4 KB
18 KB
20.4 KB
18.1 KB
16.7 KB
15.2 KB
15.6 KB
16.8 KB
18.3 KB
18.1 KB
18.5 KB
17.9 KB
17.4 KB
17.1 KB
16.6 KB
17.5 KB
16.3 KB
19.5 KB
18 KB
21.4 KB
17 KB
17.8 KB
18.5 KB
15.1 KB
14.5 KB
19.9 KB
13.3 KB
19.4 KB
17.9 KB
20.8 KB
16.6 KB
17.6 KB
18.3 KB
19.9 KB
16.7 KB
20.8 KB
16.1 KB
19 KB
15.4 KB
19.4 KB
16.7 KB
17.6 KB
17.6 KB
18 KB
15.3 KB
17.5 KB
14 KB
17.7 KB
16.7 KB
15.9 KB
17.8 KB
16.6 KB
18 KB
19.9 KB
16.5 KB
20 KB
18.1 KB
16.1 KB
18 KB
18.6 KB
16.7 KB
13.5 KB
19.6 KB
17.2 KB
20.7 KB
16.6 KB
15.9 KB
18 KB
18.2 KB
17.6 KB
19.8 KB
16.5 KB
17.9 KB
17 KB
16.8 KB
16.4 KB
17.7 KB
16.5 KB
16.3 KB
14.9 KB
13.5 KB
18.1 KB
15.9 KB
15.7 KB
21.1 KB
17.3 KB
20.5 KB
18.8 KB
17.2 KB
20 KB
18.4 KB
16.6 KB
17.3 KB
13.3 KB
16.8 KB
18.4 KB
16.1 KB
17.3 KB
17.1 KB
14.5 KB
19 KB
15.8 KB
18.6 KB
18.4 KB
19.5 KB
19.3 KB
17.9 KB
16.8 KB
15.6 KB
17.4 KB
17.9 KB
18.9 KB
18.8 KB
15.3 KB
18.6 KB
17.8 KB
19 KB
19 KB
17.9 KB
18 KB
15.1 KB
20.8 KB
16 KB
1 | <template> | 1 | <template> |
2 | - <div> | 2 | + <div class="detail"> |
3 | - <h1>{{ $route.params.userId }}</h1> | 3 | + <div class="header"> |
4 | <h1>{{ userId }}</h1> | 4 | <h1>{{ userId }}</h1> |
5 | - <h1>{{ userPk }}</h1> | 5 | + </div> |
6 | - <span></span> | 6 | + <div class="body"> |
7 | - <ul> | 7 | + <div class="assist"> |
8 | - <li v-for="avg in average"> | 8 | + <b-button>Pick Assistant</b-button> |
9 | - <h1>id : {{ avg.id }}</h1> | 9 | + </div> |
10 | - <h1>winrate : {{ avg.winrate }}</h1> | 10 | + <div class="team"> |
11 | - </li> | 11 | + <div class="team_best"> |
12 | - </ul> | 12 | + <h1>tb {{ inference_team[0]['id'] }}</h1> |
13 | + </div> | ||
14 | + <div class="team_worst"> | ||
15 | + <h1>tw {{ inference_team[inference_team.length -1]['id'] }}</h1> | ||
16 | + </div> | ||
17 | + </div> | ||
18 | + | ||
19 | + <b-container fluid class="wrap"> | ||
20 | + <b-row class="items flex-row flex-nowrap"> | ||
21 | + <template v-for="team in inference_team"> | ||
22 | + <b-card class="card"> | ||
23 | + <b-card-text>{{ team['id'] }}</b-card-text> | ||
24 | + <b-card-text>{{ team['coefficient'] }}</b-card-text> | ||
25 | + </b-card> | ||
26 | + </template> | ||
27 | + </b-row> | ||
28 | + </b-container> | ||
29 | + | ||
30 | + <div class="wrap"> | ||
31 | + <div class="items"> | ||
32 | + <h1>1234123412348123840182304981-23841-2034812-384123479012374917340917394073907409172394071092374901723940172394710923749012734091723407102374</h1> | ||
33 | + </div> | ||
34 | + </div> | ||
35 | + | ||
36 | + <div class="enemy"> | ||
37 | + <div class="enemy_best"> | ||
38 | + <h1>eb {{ inference_enemy[0]["id"] }}</h1> | ||
39 | + </div> | ||
40 | + <div class="enemy_worst"> | ||
41 | + <h1>ew {{ inference_enemy[inference_enemy.length -1]["id"] }}</h1> | ||
42 | + </div> | ||
43 | + </div> | ||
44 | + <div class="myPick"> | ||
45 | + </div> | ||
46 | + </div> | ||
13 | </div> | 47 | </div> |
14 | </template> | 48 | </template> |
15 | 49 | ||
... | @@ -18,9 +52,12 @@ export default { | ... | @@ -18,9 +52,12 @@ export default { |
18 | name: 'DetailPage', | 52 | name: 'DetailPage', |
19 | data () { | 53 | data () { |
20 | return { | 54 | return { |
21 | - userId: this.$route.params.userId, | 55 | + userId: null, |
22 | userPk: null, | 56 | userPk: null, |
23 | - average: [], | 57 | + inference_team: [], |
58 | + inference_enemy: [], | ||
59 | + inference_secondary: [], | ||
60 | + myPick: [], | ||
24 | } | 61 | } |
25 | }, | 62 | }, |
26 | created () { | 63 | created () { |
... | @@ -28,19 +65,48 @@ export default { | ... | @@ -28,19 +65,48 @@ export default { |
28 | //this.axios.post('http://127.0.0.1:8000/GameData/search/', {'game_id': "laurelwoods"}, { | 65 | //this.axios.post('http://127.0.0.1:8000/GameData/search/', {'game_id': "laurelwoods"}, { |
29 | // headers: { 'Content-Type': 'application/json'} | 66 | // headers: { 'Content-Type': 'application/json'} |
30 | //}) | 67 | //}) |
31 | - this.axios.get('http://127.0.0.1:8000/GameData/search/', { | 68 | + this.axios.get('http://127.0.0.1:8000/GameData/search/', { params: { game_id: 'laurelwoods' }}) |
32 | - params: { game_id: 'laurelwoods' } | ||
33 | - }) | ||
34 | .then((response) => { | 69 | .then((response) => { |
35 | this.userPk = response.data.id; | 70 | this.userPk = response.data.id; |
36 | - this.axios.get('http://127.0.0.1:8000/GameData/' + this.userPk + '/average/') | 71 | + this.userId = response.data.game_id; |
72 | + // inference : team | ||
73 | + this.axios.get('http://127.0.0.1:8000/GameData/' + this.userPk + '/inference/', { params: { model_type: 'team'}}) | ||
74 | + .then((response) => { this.inference_team = response.data; }) | ||
75 | + | ||
76 | + // inference : enemy | ||
77 | + this.axios.get('http://127.0.0.1:8000/GameData/' + this.userPk + '/inference/', { params: { model_type: 'enemy'}}) | ||
78 | + .then((response) => { this.inference_enemy = response.data; }) | ||
79 | + | ||
80 | + // inference : secondary | ||
81 | + this.axios.get('http://127.0.0.1:8000/GameData/' + this.userPk + '/inference/', { params: { model_type: 'secondary'}}) | ||
37 | .then((response) => { | 82 | .then((response) => { |
38 | - this.average = response.data; | 83 | + this.inference_secondary = response.data; }) |
84 | + | ||
85 | + // average : myPick | ||
86 | + this.axios.get('http://127.0.0.1:8000/GameData/' + this.userPk + '/average/') | ||
87 | + .then((response) => { this.myPick = response.data; }) | ||
39 | }) | 88 | }) |
89 | + .catch((error) => { | ||
90 | + console.log(error.response) | ||
40 | }) | 91 | }) |
92 | + | ||
41 | } | 93 | } |
42 | } | 94 | } |
43 | </script> | 95 | </script> |
44 | 96 | ||
45 | <style scoped> | 97 | <style scoped> |
98 | +.warp { | ||
99 | + display: flex; | ||
100 | + flex-direction: column; | ||
101 | + height: 500px; | ||
102 | +} | ||
103 | +.items { | ||
104 | + display: flex; | ||
105 | + flex: 1; | ||
106 | + overflow: auto; | ||
107 | +} | ||
108 | +.card { | ||
109 | + min-height: 300px; | ||
110 | + min-width: 300px; | ||
111 | +} | ||
46 | </style> | 112 | </style> |
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
1 | <template> | 1 | <template> |
2 | <div class="front"> | 2 | <div class="front"> |
3 | <div class="title"> | 3 | <div class="title"> |
4 | - <h1>League of Legends</h1> | ||
5 | <h1>Winrate Prediction</h1> | 4 | <h1>Winrate Prediction</h1> |
6 | </div> | 5 | </div> |
7 | <div class="search"> | 6 | <div class="search"> |
8 | <b-form-input v-model="inputUserId" placeholder="Enter your ID"></b-form-input> | 7 | <b-form-input v-model="inputUserId" placeholder="Enter your ID"></b-form-input> |
9 | - <h1>{{ inputUserId }}</h1> | ||
10 | <b-button><router-link :to="{ path: inputUserId }">search</router-link></b-button> | 8 | <b-button><router-link :to="{ path: inputUserId }">search</router-link></b-button> |
11 | </div> | 9 | </div> |
12 | </div> | 10 | </div> | ... | ... |
-
Please register or login to post a comment