Skip to content

Commit

Permalink
Merge pull request #263 from smu-nity/feat_issue_262
Browse files Browse the repository at this point in the history
Feat issue 262
  • Loading branch information
hyunmin0317 authored Dec 24, 2023
2 parents 5bc1217 + 65398e6 commit ecde08b
Show file tree
Hide file tree
Showing 8 changed files with 365 additions and 382 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SMUNITY ![Python versions](https://img.shields.io/badge/Python-3.9-blue) ![License](https://img.shields.io/badge/license-MIT-green) ![Release](https://img.shields.io/badge/release-1.3.1-red)
# SMUNITY ![Python versions](https://img.shields.io/badge/Python-3.9-blue) ![License](https://img.shields.io/badge/license-MIT-green) ![Release](https://img.shields.io/badge/release-1.4.0-red)
#### 상명대학교 졸업요건 검사 사이트

![SMUNITY](https://github.com/smu-nity/SMUNITY/assets/63601183/f1e9be66-3894-42f7-a3a7-b730e8066a58)
Expand Down
2 changes: 1 addition & 1 deletion core/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def course_update(request):
if not Course.objects.filter(user=request.user, subject=subject):
Course.objects.create(user=request.user, subject=subject, year=sub['SCH_YEAR'], semester=sub['SMT_NM'], credit=sub['CDT'], type=sub['CMP_DIV_NM'], domain=domain)
messages.error(request, '기이수과목이 업데이트 되었습니다.')
return redirect('core:mypage')
return redirect('core:result')
messages.error(request, '⚠️ 샘물 포털 ID/PW를 다시 확인하세요! (Caps Lock 확인)')
return redirect('core:mypage')

Expand Down
134 changes: 120 additions & 14 deletions static/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,7 @@ input[type="button"]
text-align:left;
padding:1.5rem 2rem 1.5rem 2rem;
border: 1px solid rgb(216, 216, 216);
line-height: 1.2;
}
.popup_box li{
line-height: 2.5rem;
Expand Down Expand Up @@ -677,6 +678,7 @@ strong {
font-size: 1rem;
padding-top: 2rem;
padding-bottom: 1rem;
line-height: 1.2;
}
.myth {
height: 2.5rem;
Expand All @@ -699,10 +701,10 @@ strong {
color: rgb(199, 199, 199)
}
.partdiv {
padding-top: 2rem;
padding-bottom: 5rem;
padding: 2rem 0;
font-size: 1.5rem;
letter-spacing: 1.5px;
line-height: 1.2;
}
.gear {
animation: i 5s linear infinite;
Expand Down Expand Up @@ -781,7 +783,7 @@ strong {
}
.modal-title {
text-align: center;
padding-top:2rem;
padding-top:1rem;
font-weight: bold;
font-size:2rem;
margin-top:1.7rem;
Expand Down Expand Up @@ -867,6 +869,7 @@ input[type=checkbox] {
color:white;
border-radius: 3px;
background-color: #6188E8;
word-break: keep-all;
}
.target_color_span {
font-size: 1.8rem;
Expand Down Expand Up @@ -1221,8 +1224,6 @@ input[type=checkbox] {
width: 100%;
text-align: center;
margin:0 auto;
margin-top:1rem;
margin-bottom:1rem;
}
.grade_table_th {
font-size: 1rem;
Expand Down Expand Up @@ -1646,9 +1647,16 @@ body:not(.device-touch) .suc_btn
.modal_title {
font-size: 1.5rem;
}
.modal-test {
max-height: 600px;
.modal-scroll {
max-height: 300px;
overflow-y: auto;
}
.scroll {
height: 300px;
overflow-y: auto;
overflow-x: hidden;
margin-top: 1rem;
margin-bottom: 1rem;
}
.box-margin1 {
margin-top: 1rem;
Expand All @@ -1668,6 +1676,12 @@ body:not(.device-touch) .suc_btn
.form-readonly {
background-color:rgb(248,249,250);
}
.resultbox-mobile {
display: none;
}
.modal-ul {
padding: 0;
}
@media screen and (max-width: 1024px) {
.main-img {
justify-content: center;
Expand Down Expand Up @@ -1720,16 +1734,39 @@ body:not(.device-touch) .suc_btn
font-size: 0.8rem;
}
.modal-title {
font-size: 1.8rem;
font-size: 1.6rem;
margin-top: 1.5rem;
margin-bottom: 1.5rem;
}
.table_hidden {
display: none;
}
.modal_title {
font-size: 1.4rem;
}
.modal-test {
max-height: 500px;
.modal-scroll {
max-height: 250px;
}
.resultbox-main {
display: none;
}
.resultbox-mobile {
display: block;
}
.partdiv {
font-size: 1.3rem;
}
.popup_content {
width: 90%;
}
.popup_box {
font-size: 0.95rem;
}
.link_site {
font-size: 0.7rem;
}
.popup_check {
font-size: 1rem;
}
}
@media screen and (max-width: 767px) {
Expand Down Expand Up @@ -1774,6 +1811,7 @@ body:not(.device-touch) .suc_btn
}
.update_modal_content {
width: 70%;
padding: 2rem;
}
.close {
font-size: 2.1rem;
Expand All @@ -1782,7 +1820,9 @@ body:not(.device-touch) .suc_btn
font-size: 0.7rem;
}
.modal-title {
font-size: 1.6rem;
font-size: 1.3rem;
margin-top: 1rem;
margin-bottom: 1rem;
}
.info_content {
font-size:0.85rem;
Expand All @@ -1798,7 +1838,7 @@ body:not(.device-touch) .suc_btn
font-size: 1rem;
}
.mydiv {
font-size: 0.9rem;
font-size: 0.7rem;
line-height: 1.2;
}
.target_num_div {
Expand All @@ -1814,12 +1854,78 @@ body:not(.device-touch) .suc_btn
.modal_title {
font-size: 1.3rem;
}
.modal-test {
max-height: 400px;
.modal-scroll {
max-height: 200px;
}
.white-box {
width: 80%;
}
.resultbox {
width: 95%;
box-sizing: border-box;
margin: 0.8rem auto;
height: auto;
}
.lcontainer {
padding-bottom : 1.5rem;
}
.result_name {
margin: 0.5rem 1rem 0 1rem;
font-size: 1.1rem;
}
.small {
font-size: 1rem;
}
.result_container {
margin: 1rem;
}
.result_content {
width: 100px;
height: 100px;
align-items: center;
display: grid;
}
.result_content_number {
font-size: 2rem;
height: 60px;
}
.pie-chart {
margin-left: 5px;
width: 90px;
height: 90px;
}
.result_content_info {
font-size: 0.7rem;
}
.recommend {
left: 70%;
height: 2rem;
width: 6rem;
font-size: 0.8rem;
}
.partdiv {
font-size: 0.9rem;
}
.mytable {
width: 100%;
padding-top: 1rem;
font-size: 0.5rem;
}
.myth {
font-size: 0.6rem;
}
.popup_content {
width: 95%;
}
.popup_box {
font-size: 0.75rem;
}
.link_site {
font-size: 0.6rem;
}
.popup_check {
font-size: 0.8rem;
}
}
@media screen and (max-width: 400px) {
.bg_small_text {
Expand Down
19 changes: 1 addition & 18 deletions static/js/head.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,21 +28,4 @@ var Spanclick_set_cookie = function (x, y) {
}
}
}

// 검사대상표 모달
var target_btn = document.getElementById("target_btn");
var target_modal = document.getElementById('target_modal');
var target_close = document.getElementById("target_close");
Btnclick(target_btn, target_modal);
Spanclick(target_close, target_modal);
Spanclick_set_cookie(span, modal);
window.onclick = function (event) {
if (event.target == target_modal) {
target_modal.style.display = "none";
}
}
window.onclick = function (event) {
if (event.target == modal) {
modal.style.display = "none";
}
}
Spanclick_set_cookie(span, modal);
37 changes: 19 additions & 18 deletions templates/accounts/agree.html
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
</div>
<!-- 검사대상표 모달 -->
<div id="target_modal" class="modal" >
<div class="update_modal_content modal-test">
<div class="update_modal_content">
<span class="close" id="target_close">&times;</span>
<br>
<div class="modal_div">
Expand All @@ -73,23 +73,24 @@
<div class='target_num_div'>
현재 총 <span class='target_color_span'>{{ dept_num }}</span>개 학과 검사 가능
</div>

<table class="target_table" style="width: 100%;">
<tr>
<th class="target_table_th" style='border-left: 1px solid #dadada;'>학과</th>
<th class="target_table_th table_hidden">단과대학</th>
<th class="target_table_th">학번</th>
<th class="target_table_th table_hidden">교육과정</th>
</tr>
{% for department in departments %}
<tr>
<td class="target_table_td" style='border-left: 1px solid #dadada;'>{{ department.name }}</td>
<td class="target_table_td table_hidden">{{ department.college }}</td>
<td class="target_table_td">23, 22, 21, 20, 19, 18, 17</td>
<td class="target_table_td table_hidden"><a class="link_site" href="{{ department.url }}" target="_blank">교육과정</a></td>
</tr>
{% endfor %}
</table>
<div class="modal-scroll">
<table class="target_table" style="width: 100%;">
<tr>
<th class="target_table_th" style='border-left: 1px solid #dadada;'>학과</th>
<th class="target_table_th table_hidden">단과대학</th>
<th class="target_table_th">학번</th>
<th class="target_table_th table_hidden">교육과정</th>
</tr>
{% for department in departments %}
<tr>
<td class="target_table_td" style='border-left: 1px solid #dadada;'>{{ department.name }}</td>
<td class="target_table_td table_hidden">{{ department.college }}</td>
<td class="target_table_td">23, 22, 21, 20, 19, 18, 17</td>
<td class="target_table_td table_hidden"><a class="link_site" href="{{ department.url }}" target="_blank">교육과정</a></td>
</tr>
{% endfor %}
</table>
</div>
</div>
</div>
</div>
Expand Down
Loading

0 comments on commit ecde08b

Please sign in to comment.