Goit

Simple and lightweight Git web server
git clone https://git.omkov.net/Goit
git clone [email protected]:Goit
Log | Tree | Refs | README | Download

Goit/res/user/edit.html (66 lines, 2.4 KiB) -rw-r--r-- blame download

01234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
<!DOCTYPE html>
<html lang="en">
	<head>{{template "base/head" .}}</head>
	<body>
		<header>{{template "user/header" .}}</header><hr>
		<main>
			<h1>{{.Title}}</h1><hr>
			<form action="/user/edit" method="post">
				{{.CsrfField}}
				<table>
					<tr><td><label for="username">Username</label></td></tr>
					<tr><td><input type="text" name="username" value="{{.Form.Name}}" spellcheck="false"></td></tr>
					<tr><td><label for="fullname">Full Name</label></td></tr>
					<tr><td><input type="text" name="fullname" value="{{.Form.FullName}}" spellcheck="false"></td></tr>
					<tr><td><label for="visibility">Default Visibility</label></td></tr>
					<tr>
						<td>
							<select name="visibility">
								<option value="public" {{if eq .Form.DefaultVisibility "public"}}selected{{end}}>
									Public
								</option>
								<option value="private" {{if eq .Form.DefaultVisibility "private"}}selected{{end}}>
									Private
								</option>
								<option value="limited" {{if eq .Form.DefaultVisibility "limited"}}selected{{end}}>
									Limited
								</option>
							</select>
						</td>
					</tr>
					<tr>
						<td>
							<input type="submit" name="submit" value="Update">
							<!-- <a href="/" style="color: inherit;">Cancel</a> -->
							<span style="color: #AA0000">{{.MessageA}}</span>
						</td>
					</tr>
					<!-- <tr><td style="color: #AA0000">{{.MessageA}}</td></tr> -->
				</table>
			</form><hr>
			<form action="/user/edit" method="post">
				{{.CsrfField}}
				<table>
					<tr><td><label for="password">Current Password</label></td></tr>
					<tr><td><input type="password" name="password"></td></tr>
					<tr><td><label for="new_password">New Password</label></td></tr>
					<tr><td><input type="password" name="new_password"></td></tr>
					<tr><td><label for="confirm_password">Confirm New Password</label></td></tr>
					<tr><td><input type="password" name="confirm_password"></td></tr>
					<tr>
						<td>
							<input type="submit" name="submit" value="Update Password">
							<!-- <a href="/" style="color: inherit;">Cancel</a> -->
							<span style="color: #AA0000">{{.MessageB}}</span>
						</td>
					</tr>
					<!-- <tr><td style="color: #AA0000">{{.MessageB}}</td></tr> -->
				</table>
			</form><hr>
			<table>
				<tr><td style="text-align: right;"><span>ID:</span></td><td><span>{{.Form.ID}}</span></td></tr>
			</table>
		</main>
	</body>
</html>