added hebrew, statistics

This commit is contained in:
2024-06-09 15:44:01 +03:00
parent 8a3782e1db
commit 409b076cd0
7 changed files with 198 additions and 57 deletions

View File

@@ -3,11 +3,12 @@
<html>
<head>
{{if eq .Lang "heb"}}<link href="/public/hebrew.css" rel="stylesheet" type="text/css">{{end}}
<title>{{ .ElementsData.Title }}</title>
<link href="/public/mod.css" rel="stylesheet" type="text/css">
<script src="/public/script.js"></script>
</head>
<body>
<body {{if eq .BodyClass "m"}} class="m"{{end}}>
{{template "body" .}}
</body>
</html>

49
html/statsitics.html Normal file
View File

@@ -0,0 +1,49 @@
{{define "body"}}
<div class="container">
<div class="column">
<h1>Download Statistics</h1>
<table>
<tr>
<th>Program</th>
<th>Version</th>
<th>Download Count</th>
</tr>
{{range .VersionStats}}
<tr>
<td>
{{.ID}}
</td>
<td>
{{.Version}}
</td>
<td>
{{.Counter}}
</td>
</tr>
{{end}}
</table>
</div>
<div class="column" id="totalus">
<h1>Total Download Statistics</h1>
<table>
<tr>
<th>Package</th>
<th>Search Count</th>
</tr>
{{range .TotalStats}}
<tr>
<td>
{{.ID}}
</td>
<td>
{{.Counter}}
</td>
</tr>
{{end}}
</table>
</div>
</div>
{{end}}

View File

@@ -1,13 +1,37 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>File Upload</title>
<link href="mod.css" rel="stylesheet" type="text/css">
<script src="script.js"></script>
</head>
<body>
{{define "body"}}
<div class="form-container">
<form>
<div class="form-group">
<label for="PackageIdentifier">PackageIdentifier</label>
<input type="text" id="PackageIdentifier" name="PackageIdentifier" value="<%= frm.identifier %>">
</div>
<div class="form-group">
<label for="PackageVersion">PackageVersion</label>
<input type="text" id="PackageVersion" name="PackageVersion" value="<%= frm.version %>">
</div>
<div class="form-group">
<label for="InstallerType">InstallerType</label>
<input type="text" id="InstallerType" name="InstallerType" value="<%= frm.type %>">
</div>
<fieldset>
<legend>Installers</legend>
<div class="form-group">
<label for="InstallerUrl">InstallerUrl</label>
<input type="url" id="InstallerUrl" name="InstallerUrl" value="<%= frm.url %>">
</div>
<div class="form-group">
<label for="InstallerSha256">InstallerSha256</label>
<input type="text" id="InstallerSha256" name="InstallerSha256" value="<%= frm.checksum %>">
</div>
</fieldset>
<div class="form-group">
<label for="Dependencies">Dependencies</label>
<input type="text" id="Dependencies" name="Dependencies">
</div>
<input type="submit" value="Submit">
</form>
</div>
<!-- <div> -->
<form action="/upload" method="post" enctype="multipart/form-data">
@@ -29,5 +53,4 @@
}
});
</script>
</body>
</html>
{{end}}