
Merge branch 'master' of http://210.180.118.83/jichoi/lms_front
@64d01a79dc3d9f8f452e685dd5bc7883135ee54f
--- client/views/pages/main/Dashboard.vue
+++ client/views/pages/main/Dashboard.vue
... | ... | @@ -20,8 +20,10 @@ |
20 | 20 |
:style="{ display: rabbitPos[1] ? 'block' : 'none' }"></div> |
21 | 21 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
22 | 22 |
data-num="1"> |
23 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[1] ? 'block' : 'none' }"> |
|
24 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[1] ? 'block' : 'none' }"> |
|
23 |
+ <img :src="labeledItems[0].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
24 |
+ :style="{ display: !rabbitCompl[1] ? 'block' : 'none' }"> |
|
25 |
+ <img :src="labeledItems[0].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
26 |
+ :style="{ display: rabbitCompl[1] ? 'block' : 'none' }"> |
|
25 | 27 |
</button> |
26 | 28 |
<p>{{ labeledItems[0].label }}</p> |
27 | 29 |
</div> |
... | ... | @@ -30,8 +32,10 @@ |
30 | 32 |
:style="{ display: rabbitPos[2] ? 'block' : 'none' }"></div> |
31 | 33 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
32 | 34 |
data-num="2"> |
33 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[2] ? 'block' : 'none' }"> |
|
34 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[2] ? 'block' : 'none' }"> |
|
35 |
+ <img :src="labeledItems[1].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
36 |
+ :style="{ display: !rabbitCompl[2] ? 'block' : 'none' }"> |
|
37 |
+ <img :src="labeledItems[1].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
38 |
+ :style="{ display: rabbitCompl[2] ? 'block' : 'none' }"> |
|
35 | 39 |
</button> |
36 | 40 |
<p>{{ labeledItems[1].label }}</p> |
37 | 41 |
</div> |
... | ... | @@ -43,8 +47,10 @@ |
43 | 47 |
:style="{ display: rabbitPos[7] ? 'block' : 'none' }"></div> |
44 | 48 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
45 | 49 |
data-num="7"> |
46 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[7] ? 'block' : 'none' }"> |
|
47 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[7] ? 'block' : 'none' }"> |
|
50 |
+ <img :src="labeledItems[6].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
51 |
+ :style="{ display: !rabbitCompl[7] ? 'block' : 'none' }"> |
|
52 |
+ <img :src="labeledItems[6].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
53 |
+ :style="{ display: rabbitCompl[7] ? 'block' : 'none' }"> |
|
48 | 54 |
</button> |
49 | 55 |
<p>{{ labeledItems[6].label }}</p> |
50 | 56 |
</div> |
... | ... | @@ -53,8 +59,10 @@ |
53 | 59 |
:style="{ display: rabbitPos[6] ? 'block' : 'none' }"></div> |
54 | 60 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
55 | 61 |
data-num="6"> |
56 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[6] ? 'block' : 'none' }"> |
|
57 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[6] ? 'block' : 'none' }"> |
|
62 |
+ <img :src="labeledItems[5].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
63 |
+ :style="{ display: !rabbitCompl[6] ? 'block' : 'none' }"> |
|
64 |
+ <img :src="labeledItems[5].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
65 |
+ :style="{ display: rabbitCompl[6] ? 'block' : 'none' }"> |
|
58 | 66 |
</button> |
59 | 67 |
<p>{{ labeledItems[5].label }}</p> |
60 | 68 |
</div> |
... | ... | @@ -64,8 +72,10 @@ |
64 | 72 |
:style="{ display: rabbitPos[5] ? 'block' : 'none' }"></div> |
65 | 73 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
66 | 74 |
data-num="5"> |
67 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[5] ? 'block' : 'none' }"> |
|
68 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[5] ? 'block' : 'none' }"> |
|
75 |
+ <img :src="labeledItems[4].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
76 |
+ :style="{ display: !rabbitCompl[5] ? 'block' : 'none' }"> |
|
77 |
+ <img :src="labeledItems[4].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
78 |
+ :style="{ display: rabbitCompl[5] ? 'block' : 'none' }"> |
|
69 | 79 |
</button> |
70 | 80 |
<p>{{ labeledItems[4].label }}</p> |
71 | 81 |
</div> |
... | ... | @@ -75,8 +85,10 @@ |
75 | 85 |
:style="{ display: rabbitPos[4] ? 'block' : 'none' }"></div> |
76 | 86 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
77 | 87 |
data-num="4"> |
78 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[4] ? 'block' : 'none' }"> |
|
79 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[4] ? 'block' : 'none' }"> |
|
88 |
+ <img :src="labeledItems[3].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
89 |
+ :style="{ display: !rabbitCompl[4] ? 'block' : 'none' }"> |
|
90 |
+ <img :src="labeledItems[3].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
91 |
+ :style="{ display: rabbitCompl[4] ? 'block' : 'none' }"> |
|
80 | 92 |
</button> |
81 | 93 |
<p>{{ labeledItems[3].label }}</p> |
82 | 94 |
</div> |
... | ... | @@ -86,8 +98,10 @@ |
86 | 98 |
:style="{ display: rabbitPos[3] ? 'block' : 'none' }"></div> |
87 | 99 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
88 | 100 |
data-num="3"> |
89 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[3] ? 'block' : 'none' }"> |
|
90 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[3] ? 'block' : 'none' }"> |
|
101 |
+ <img :src="labeledItems[2].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
102 |
+ :style="{ display: !rabbitCompl[3] ? 'block' : 'none' }"> |
|
103 |
+ <img :src="labeledItems[2].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
104 |
+ :style="{ display: rabbitCompl[3] ? 'block' : 'none' }"> |
|
91 | 105 |
</button> |
92 | 106 |
<p>{{ labeledItems[2].label }}</p> |
93 | 107 |
</div> |
... | ... | @@ -98,8 +112,10 @@ |
98 | 112 |
:style="{ display: rabbitPos[8] ? 'block' : 'none' }"></div> |
99 | 113 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
100 | 114 |
data-num="8"> |
101 |
- <img :src="item.imgSrc3" :style="{ display: !rabbitCompl[8] ? 'block' : 'none' }"> |
|
102 |
- <img :src="item.imgSrc4" :style="{ display: rabbitCompl[8] ? 'block' : 'none' }"> |
|
115 |
+ <img :src="labeledItems[7].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
116 |
+ :style="{ display: !rabbitCompl[8] ? 'block' : 'none' }"> |
|
117 |
+ <img :src="labeledItems[7].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
118 |
+ :style="{ display: rabbitCompl[8] ? 'block' : 'none' }"> |
|
103 | 119 |
</button> |
104 | 120 |
<p class="long">{{ labeledItems[7].label }}</p> |
105 | 121 |
</div> |
... | ... | @@ -109,8 +125,10 @@ |
109 | 125 |
:style="{ display: rabbitPos[9] ? 'block' : 'none' }"></div> |
110 | 126 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
111 | 127 |
data-num="9"> |
112 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[9] ? 'block' : 'none' }"> |
|
113 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[9] ? 'block' : 'none' }"> |
|
128 |
+ <img :src="labeledItems[8].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
129 |
+ :style="{ display: !rabbitCompl[9] ? 'block' : 'none' }"> |
|
130 |
+ <img :src="labeledItems[8].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
131 |
+ :style="{ display: rabbitCompl[9] ? 'block' : 'none' }"> |
|
114 | 132 |
</button> |
115 | 133 |
<p>{{ labeledItems[8].label }}</p> |
116 | 134 |
</div> |
... | ... | @@ -120,8 +138,10 @@ |
120 | 138 |
:style="{ display: rabbitPos[10] ? 'block' : 'none' }"></div> |
121 | 139 |
<button class="popTxt" v-for="(item, index) in items" :key="index" @click="toggleImage(index)" |
122 | 140 |
data-num="10"> |
123 |
- <img :src="item.imgSrc1" :style="{ display: !rabbitCompl[10] ? 'block' : 'none' }"> |
|
124 |
- <img :src="item.imgSrc2" :style="{ display: rabbitCompl[10] ? 'block' : 'none' }"> |
|
141 |
+ <img :src="labeledItems[9].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
142 |
+ :style="{ display: !rabbitCompl[10] ? 'block' : 'none' }"> |
|
143 |
+ <img :src="labeledItems[9].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
144 |
+ :style="{ display: rabbitCompl[10] ? 'block' : 'none' }"> |
|
125 | 145 |
</button> |
126 | 146 |
<p>{{ labeledItems[9].label }}</p> |
127 | 147 |
</div> |
... | ... | @@ -132,8 +152,10 @@ |
132 | 152 |
:style="{ display: rabbitPos[11] ? 'block' : 'none' }"></div> |
133 | 153 |
<button class="popTxt" v-for="(item, index) in items" :key="index" |
134 | 154 |
@click="toggleImageAndShowPopup(index, '11')" data-num="11"> |
135 |
- <img :src="item.imgSrc3" :style="{ display: !rabbitCompl[11] ? 'block' : 'none' }"> |
|
136 |
- <img :src="item.imgSrc4" :style="{ display: rabbitCompl[11] ? 'block' : 'none' }"> |
|
155 |
+ <img :src="labeledItems[10].label.length >= 4 ? item.imgSrc3 : item.imgSrc1" |
|
156 |
+ :style="{ display: !rabbitCompl[11] ? 'block' : 'none' }"> |
|
157 |
+ <img :src="labeledItems[10].label.length >= 4 ? item.imgSrc4 : item.imgSrc2" |
|
158 |
+ :style="{ display: rabbitCompl[11] ? 'block' : 'none' }"> |
|
137 | 159 |
</button> |
138 | 160 |
<p class="long">{{ labeledItems[10].label }}</p> |
139 | 161 |
</div> |
... | ... | @@ -805,4 +827,8 @@ |
805 | 827 |
bottom: 0; |
806 | 828 |
width: 40%; |
807 | 829 |
} |
830 |
+ |
|
831 |
+.race-btn p { |
|
832 |
+ width: auto; |
|
833 |
+} |
|
808 | 834 |
</style>(No newline at end of file) |
--- client/views/pages/main/MyPlan.vue
+++ client/views/pages/main/MyPlan.vue
... | ... | @@ -50,18 +50,18 @@ |
50 | 50 |
<div class="wrap mt30"> |
51 | 51 |
<p class="title1 mb20">AI 맞춤형 학습 코스는 어떨까요?</p> |
52 | 52 |
<div class="imgGroup flex justify-between"> |
53 |
- <div class="text-lf aiClick" @click="goToPage2('AIDashboard')"> |
|
53 |
+ <div class="text-lf aiClick" v-for="(ai_learning, index) in aiLearningList" :key="index" @click="goToPage('Dashboard', aiLearningList[index].unit_id)"> |
|
54 |
+ <img src="../../../resources/img/img215_22s.png" alt="" /> |
|
55 |
+ <p class="title2 mt10">추천 학습 단원</p> |
|
56 |
+ </div> |
|
57 |
+ <!-- <div class="text-lf aiClick" @click="goToPage2('AIDashboard')"> |
|
54 | 58 |
<img src="../../../resources/img/img215_22s.png" alt="" /> |
55 | 59 |
<p class="title2 mt10">추천 학습 단원</p> |
56 | 60 |
</div> |
57 | 61 |
<div class="text-lf aiClick" @click="goToPage2('AIDashboard')"> |
58 | 62 |
<img src="../../../resources/img/img215_22s.png" alt="" /> |
59 | 63 |
<p class="title2 mt10">추천 학습 단원</p> |
60 |
- </div> |
|
61 |
- <div class="text-lf aiClick" @click="goToPage2('AIDashboard')"> |
|
62 |
- <img src="../../../resources/img/img215_22s.png" alt="" /> |
|
63 |
- <p class="title2 mt10">추천 학습 단원</p> |
|
64 |
- </div> |
|
64 |
+ </div> --> |
|
65 | 65 |
</div> |
66 | 66 |
</div> |
67 | 67 |
</div> |
... | ... | @@ -92,6 +92,8 @@ |
92 | 92 |
{ label: "5교시", time: "13:00 ~ 14:00", value: "5" }, |
93 | 93 |
{ label: "6교시", time: "14:00 ~ 15:00", value: "6" }, |
94 | 94 |
], |
95 |
+ |
|
96 |
+ aiLearningList: [], |
|
95 | 97 |
}; |
96 | 98 |
}, |
97 | 99 |
methods: { |
... | ... | @@ -238,6 +240,29 @@ |
238 | 240 |
alert("단원 목록을 불러오는 중 오류가 발생했습니다."); |
239 | 241 |
}); |
240 | 242 |
}, |
243 |
+ |
|
244 |
+ selectAiLearning: function () { |
|
245 |
+ const vm = this; |
|
246 |
+ axios({ |
|
247 |
+ url: "/aiLearning/selectAILearning.json", |
|
248 |
+ method: "post", |
|
249 |
+ headers: { |
|
250 |
+ "Content-Type": "application/json; charset=UTF-8", |
|
251 |
+ }, |
|
252 |
+ data: { |
|
253 |
+ std_id: this.stdId |
|
254 |
+ } |
|
255 |
+ }) |
|
256 |
+ .then(function (response) { |
|
257 |
+ console.log("aiLearningList - response : ", response.data); |
|
258 |
+ vm.aiLearningList = response.data; |
|
259 |
+ }) |
|
260 |
+ .catch(function (error) { |
|
261 |
+ console.log("aiLearningList - error : ", error); |
|
262 |
+ alert("ai learning 조회에 오류가 발생했습니다."); |
|
263 |
+ }); |
|
264 |
+ }, |
|
265 |
+ |
|
241 | 266 |
}, |
242 | 267 |
watch: {}, |
243 | 268 |
computed: { |
... | ... | @@ -249,6 +274,7 @@ |
249 | 274 |
mounted() { |
250 | 275 |
console.log("Main2 mounted"); |
251 | 276 |
this.fetchSchedules(); |
277 |
+ this.selectAiLearning(); |
|
252 | 278 |
}, |
253 | 279 |
}; |
254 | 280 |
</script> |
Add a comment
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?