aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--controller/controller.go2
-rw-r--r--db/model.go8
-rw-r--r--templates/entry.tmpl2
-rw-r--r--templates/index.tmpl2
4 files changed, 7 insertions, 7 deletions
diff --git a/controller/controller.go b/controller/controller.go
index 3552304..ffa89ce 100644
--- a/controller/controller.go
+++ b/controller/controller.go
@@ -42,7 +42,7 @@ func CreateEntry(c *gin.Context) {
var entry db.YdlEntry
c.ShouldBind(&entry)
db.DB.Create(&entry)
- spawnWorker(entry.Link, entry.Output_folder)
+ spawnWorker(entry.Link, entry.OutputFolder)
c.Redirect(http.StatusFound, "/")
}
diff --git a/db/model.go b/db/model.go
index 3094472..6f35cd0 100644
--- a/db/model.go
+++ b/db/model.go
@@ -4,8 +4,8 @@ import "gorm.io/gorm"
type YdlEntry struct {
gorm.Model
- Title string
- Link string
- Format string
- Output_folder string
+ Title string
+ Link string
+ Format string
+ OutputFolder string
}
diff --git a/templates/entry.tmpl b/templates/entry.tmpl
index dc5f2b6..642b501 100644
--- a/templates/entry.tmpl
+++ b/templates/entry.tmpl
@@ -16,7 +16,7 @@
</label>
<label for="output">
Output folder
- <input type="text" id="Output_folder" name="Output_folder" value="{{ .Output_folder }}" placeholder="Select a ralative folder" required>
+ <input type="text" id="OutputFolder" name="OutputFolder" value="{{ .OutputFolder }}" placeholder="Select a ralative folder" required>
</label>
<button type="submit">Submit</button>
</form>
diff --git a/templates/index.tmpl b/templates/index.tmpl
index 1880b5f..0b965f5 100644
--- a/templates/index.tmpl
+++ b/templates/index.tmpl
@@ -14,7 +14,7 @@
<tr>
<td>{{ .ID }}</td>
<td>{{ .Link }}</td>
- <td>{{ .Output_folder }}</td>
+ <td>{{ .OutputFolder }}</td>
<td>
<a href="entries/{{ .ID }}" >Edit</a>
</span>