Skip to content

Commit

Permalink
fixed the extracuricular database
Browse files Browse the repository at this point in the history
  • Loading branch information
om-raheja committed Nov 23, 2024
1 parent 9f64c91 commit 3f954d4
Show file tree
Hide file tree
Showing 11 changed files with 79 additions and 120 deletions.
15 changes: 8 additions & 7 deletions ec.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,6 @@ func resultsScholarship(w http.ResponseWriter, r *http.Request) {
args = append(args, grade, grade)
}

// print query and args
fmt.Println(query)
fmt.Println(args)

// execute the query
rows, err := db.Query(query, args...)
if err != nil {
Expand All @@ -121,7 +117,7 @@ func resultsScholarship(w http.ResponseWriter, r *http.Request) {
var startGrade int
var endGrade int
var amount string
var deadline string
var deadline sql.NullString
var link string
var notes string
var category string
Expand All @@ -137,8 +133,13 @@ func resultsScholarship(w http.ResponseWriter, r *http.Request) {
<div id="` + name + `"
data-link="` + link + `"
data-amount="` + amount + `"
data-grades="` + fmt.Sprintf("%d-%d", startGrade, endGrade) + `"
data-deadline="` + deadline + `"
data-grades="` + fmt.Sprintf("%d-%d", startGrade, endGrade) + `"`

if deadline.Valid {
htmlToInsert += `data-deadline="` + deadline.String + `"`
}

htmlToInsert += `
data-category="` + category + `"
data-notes="` + notes + `">
<div class="program-name">` + name + `</div>
Expand Down
17 changes: 5 additions & 12 deletions static/ec/difficulty-scholarships.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

<body>
<div class="container">
<div class="title">aviquo.</div>
<div class="title">aquarc.</div>
<div class="subtitle">higher difficulty generally equals higher reward
</div>

Expand Down Expand Up @@ -99,31 +99,24 @@
</div>

<div class="frame-parent3">
<a href="https://www.linkedin.com/company/aviquo/" target="_blank">
<a href="https://www.linkedin.com/company/aquarc/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.tiktok.com/@aviquo_" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.instagram.com/aviquo_?igsh=MzRlODBiNWFlZA==" target="_blank">

<a href="https://www.instagram.com/_aquarc_/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://youtube.com/channel/UCuEXrlSgb-vo6kyUeuppfJA" target="_blank">
<a href="https://www.youtube.com/@aquarc_co" target="_blank">
<img
class="social-icon"
loading="lazy"
Expand Down
20 changes: 8 additions & 12 deletions static/ec/ec.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
<head>
<meta charset="utf-8" />
<meta name="viewport" content="initial-scale=1, width=device-width" />
<title>Aquarc | Extracurriculars</title>
<link rel="icon" type="image/png" sizes="128x128" href="/static/landing/images/aquLogo.png">
<link rel="icon" type="image/x-icon" href="/static/landing/images/aquLogoWhiteCircle.png">
<link rel="stylesheet" href="/static/ec/index.css" />
<link
rel="stylesheet"
Expand All @@ -36,7 +39,7 @@
<section class="subject">
<div class="primary">aquarc. </div>
<div class="secondary">
choose the type of ec (u can only choose 1)
choose your extracurricular
</div>
</section>
<div class="frame-parent2">
Expand Down Expand Up @@ -68,31 +71,24 @@
</a>
</div>
<div class="frame-parent3">
<a href="https://www.linkedin.com/company/aviquo/" target="_blank">
<a href="https://www.linkedin.com/company/aquarc/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.tiktok.com/@aviquo_" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.instagram.com/aviquo_?igsh=MzRlODBiNWFlZA==" target="_blank">

<a href="https://www.instagram.com/_aquarc_/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://youtube.com/channel/UCuEXrlSgb-vo6kyUeuppfJA" target="_blank">
<a href="https://www.youtube.com/@aquarc_co" target="_blank">
<img
class="social-icon"
loading="lazy"
Expand Down
21 changes: 8 additions & 13 deletions static/ec/grades-scholarships.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Grades - Summer Programs</title>
<title>Aquarc | Grades - Summer Programs</title>
<link rel="icon" type="image/png" sizes="128x128" href="/static/landing/images/aquLogo.png">
<link rel="icon" type="image/x-icon" href="/static/landing/images/aquLogoWhiteCircle.png">
<link rel="stylesheet" href="/static/ec/grades-scholarships.css">
<link
rel="stylesheet"
Expand All @@ -35,7 +37,7 @@

<body>
<div class="container">
<div class="title">aviquo.</div>
<div class="title">aquarc.</div>
<div class="subtitle">choose the grade(s) you will be when you apply<br>
and the program cost</div>

Expand Down Expand Up @@ -91,31 +93,24 @@
</div>

<div class="frame-parent3">
<a href="https://www.linkedin.com/company/aviquo/" target="_blank">
<a href="https://www.linkedin.com/company/aquarc/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.tiktok.com/@aviquo_" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.instagram.com/aviquo_?igsh=MzRlODBiNWFlZA==" target="_blank">

<a href="https://www.instagram.com/_aquarc_/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://youtube.com/channel/UCuEXrlSgb-vo6kyUeuppfJA" target="_blank">
<a href="https://www.youtube.com/@aquarc_co" target="_blank">
<img
class="social-icon"
loading="lazy"
Expand Down
21 changes: 8 additions & 13 deletions static/ec/grades-summer-programs.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,10 @@
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Grades - Summer Programs</title>
<title>Aquarc | Grades - Summer Programs</title>
<link rel="stylesheet" href="/static/ec/grades-summer-programs.css">
<link rel="icon" type="image/png" sizes="128x128" href="/static/landing/images/aquLogo.png">
<link rel="icon" type="image/x-icon" href="/static/landing/images/aquLogoWhiteCircle.png">
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Plus Jakarta Sans:wght@600;700&display=swap"
Expand All @@ -35,7 +37,7 @@

<body>
<div class="container">
<div class="title">aviquo.</div>
<div class="title">aquarc.</div>
<div class="subtitle">choose the grade(s) you will be when you apply<br>
and the program cost</div>

Expand Down Expand Up @@ -112,31 +114,24 @@
</form>
</div>
<div class="frame-parent3">
<a href="https://www.linkedin.com/company/aviquo/" target="_blank">
<a href="https://www.linkedin.com/company/aquarc/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.tiktok.com/@aviquo_" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.instagram.com/aviquo_?igsh=MzRlODBiNWFlZA==" target="_blank">

<a href="https://www.instagram.com/_aquarc_/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://youtube.com/channel/UCuEXrlSgb-vo6kyUeuppfJA" target="_blank">
<a href="https://www.youtube.com/@aquarc_co" target="_blank">
<img
class="social-icon"
loading="lazy"
Expand Down
20 changes: 8 additions & 12 deletions static/ec/results-competitions.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
<meta charset="utf-8" />
<meta name="viewport" content="initial-scale=1, width=device-width" />

<title>Aquarc | Results - Competitions</title>
<link rel="icon" type="image/png" sizes="128x128" href="/static/landing/images/aquLogo.png">
<link rel="icon" type="image/x-icon" href="/static/landing/images/aquLogoWhiteCircle.png">
<link rel="stylesheet" href="/static/ec/global.css" />
<link rel="stylesheet" href="/static/ec/results-competitions.css" />
<link
Expand All @@ -39,7 +42,7 @@
<section class="summer-programs-page">
<div class="program-list1">
<div class="program-item">
<a class="title">aviquo. </a>
<a class="title">aquarc. </a>
</div>
<div class="program-slider">
<div class="search1">
Expand Down Expand Up @@ -84,31 +87,24 @@
</section>
</div>
<div class="frame-parent3">
<a href="https://www.linkedin.com/company/aviquo/" target="_blank">
<a href="https://www.linkedin.com/company/aquarc/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.tiktok.com/@aviquo_" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.instagram.com/aviquo_?igsh=MzRlODBiNWFlZA==" target="_blank">

<a href="https://www.instagram.com/_aquarc_/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://youtube.com/channel/UCuEXrlSgb-vo6kyUeuppfJA" target="_blank">
<a href="https://www.youtube.com/@aquarc_co" target="_blank">
<img
class="social-icon"
loading="lazy"
Expand Down
21 changes: 8 additions & 13 deletions static/ec/results-page-summer-programs.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,11 @@
<head>
<meta charset="utf-8" />
<meta name="viewport" content="initial-scale=1, width=device-width" />

<title>Aquarc | Results - Summer Programs</title>
<link rel="stylesheet" href="/static/ec/global.css" />
<link rel="stylesheet" href="/static/ec/results-page-summer-programs.css" />
<link rel="icon" type="image/png" sizes="128x128" href="/static/landing/images/aquLogo.png">
<link rel="icon" type="image/x-icon" href="/static/landing/images/aquLogoWhiteCircle.png">
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Plus Jakarta Sans:wght@600;700&display=swap"
Expand All @@ -37,7 +39,7 @@
<div class="results-page-summer-programs">
<section class="summer-programs-page">
<div class="program-list1">
<a class="title">aviquo. </a>
<a class="title">aquarc. </a>
<div class="program-slider">
<input class="value-input" id="search" type="text" placeholder="Value" />
<div class="slider-controls">
Expand Down Expand Up @@ -76,31 +78,24 @@
<br><br>
</div>
<div class="frame-parent3">
<a href="https://www.linkedin.com/company/aviquo/" target="_blank">
<a href="https://www.linkedin.com/company/aquarc/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.tiktok.com/@aviquo_" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://www.instagram.com/aviquo_?igsh=MzRlODBiNWFlZA==" target="_blank">

<a href="https://www.instagram.com/_aquarc_/" target="_blank">
<img
class="social-icon"
loading="lazy"
alt=""
src="/static/ec/public/[email protected]"
/>
</a>
<a href="https://youtube.com/channel/UCuEXrlSgb-vo6kyUeuppfJA" target="_blank">
<a href="https://www.youtube.com/@aquarc_co" target="_blank">
<img
class="social-icon"
loading="lazy"
Expand Down
Loading

0 comments on commit 3f954d4

Please sign in to comment.