-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
390 additions
and
122 deletions.
There are no files selected for viewing
This file was deleted.
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,40 @@ | ||
# fishingram | ||
|
||
from rest_framework import serializers | ||
|
||
from service.models import FishingPlaceInfoData | ||
|
||
import os | ||
import glob | ||
|
||
from pathlib import Path | ||
|
||
BASE_DIR = Path(__file__).resolve(strict=True).parent.parent | ||
|
||
|
||
class FishingPlcInfoSerializer(serializers.ModelSerializer): | ||
class Meta: | ||
model = FishingPlaceInfoData | ||
fields = ( | ||
'sigun_name', | ||
'sigun_code', | ||
'facility_name', | ||
'facility_type', | ||
'refine_roadnm_addr', | ||
'refine_lotnm_addr', | ||
'refine_lat', | ||
'refine_logt', | ||
'facility_tel', | ||
'wtr_ar', | ||
'fishkind_nm', | ||
'aceptnc_posbl_psn_cnt', | ||
'wtr_facility_info', | ||
'chrg_info', | ||
'main_plc_info', | ||
'safe_facility_info', | ||
'convnce_facility_info', | ||
'circumfr_tursm_info', | ||
'manage_inst_telno', | ||
'manage_inst_name', | ||
'data_std_de' | ||
) |
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,66 @@ | ||
{% extends "base.html" %} | ||
|
||
{% block title%}원달러 환율 - Unlucky Strike{% endblock title %} | ||
|
||
{% block content %} | ||
|
||
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script> | ||
<style> | ||
/* 차트를 감싸는 컨테이너 스타일 */ | ||
.chart-container { | ||
width: 80%; | ||
margin: auto; | ||
padding: 20px; | ||
background-color: #f0f0f0; | ||
border-radius: 8px; | ||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); | ||
} | ||
</style> | ||
|
||
<h2 id="lottery">원달러 환율</h2> | ||
|
||
<section class="component"> | ||
<section class="chart-container"> | ||
<h2>Monthly Sales Chart</h2> | ||
<!-- Canvas 요소를 사용하여 차트를 그릴 공간을 마련 --> | ||
<canvas id="myChart" width="800" height="400"></canvas> | ||
</section> | ||
|
||
<script> | ||
// 차트 데이터 설정 | ||
const data = { | ||
labels: ['January', 'February', 'March', 'April', 'May', 'June'], | ||
datasets: [{ | ||
label: 'Sales', | ||
backgroundColor: 'rgba(54, 162, 235, 0.6)', | ||
borderColor: 'rgba(54, 162, 235, 1)', | ||
borderWidth: 1, | ||
data: [65, 59, 80, 81, 56, 55], | ||
}] | ||
}; | ||
|
||
// 차트 옵션 설정 | ||
const options = { | ||
scales: { | ||
yAxes: [{ | ||
ticks: { | ||
beginAtZero: true | ||
} | ||
}] | ||
} | ||
}; | ||
|
||
// Canvas 요소 가져오기 | ||
const ctx = document.getElementById('excRateChart').getContext('2d'); | ||
|
||
// 차트 생성 | ||
const excRateChart = new Chart(ctx, { | ||
type: 'line', | ||
data: data, | ||
options: options | ||
}); | ||
</script> | ||
</section> | ||
|
||
|
||
{% endblock %} |
Oops, something went wrong.