From 373dfa54f88c78b4d864b8afd00cff0e06a86887 Mon Sep 17 00:00:00 2001 From: Artur Galyamov Date: Thu, 28 Jul 2022 18:48:25 +0500 Subject: [PATCH] =?UTF-8?q?=D0=90=D0=B4=D0=BC=D0=B8=D0=BD=D0=B8=D1=81?= =?UTF-8?q?=D1=82=D1=80=D0=B0=D1=82=D0=BE=D1=80=20=D0=BC=D0=BE=D0=B6=D0=B5?= =?UTF-8?q?=D1=82=20=D1=80=D0=B5=D0=B4=D0=B0=D0=BA=D1=82=D0=B8=D1=80=D0=BE?= =?UTF-8?q?=D0=B2=D0=B0=D1=82=D1=8C=20=D0=BF=D0=BE=D0=BB=D0=B5=20"=D0=9E?= =?UTF-8?q?=20=D1=81=D0=B5=D0=B1=D0=B5"=20=D0=B4=D0=BB=D1=8F=20=D0=BF?= =?UTF-8?q?=D0=BE=D0=BB=D1=8C=D0=B7=D0=BE=D0=B2=D0=B0=D1=82=D0=B5=D0=BB?= =?UTF-8?q?=D1=8F=20#3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- routers/web/admin/users.go | 1 + services/forms/admin.go | 1 + templates/admin/user/edit.tmpl | 6 ++++++ 3 files changed, 8 insertions(+) diff --git a/routers/web/admin/users.go b/routers/web/admin/users.go index 8aaa654a39..4b94fe9e10 100644 --- a/routers/web/admin/users.go +++ b/routers/web/admin/users.go @@ -371,6 +371,7 @@ func EditUserPost(ctx *context.Context) { emailChanged := !strings.EqualFold(u.Email, form.Email) u.Email = form.Email u.Website = form.Website + u.Description = form.Description u.Location = form.Location u.LocationCoordinate = form.LocationCoordinate u.MaxRepoCreation = form.MaxRepoCreation diff --git a/services/forms/admin.go b/services/forms/admin.go index 435e5d4c15..38dcf9f219 100644 --- a/services/forms/admin.go +++ b/services/forms/admin.go @@ -41,6 +41,7 @@ type AdminEditUserForm struct { Email string `binding:"Required;Email;MaxSize(254)"` Password string `binding:"MaxSize(255)"` Website string `binding:"ValidUrl;MaxSize(255)"` + Description string Location string `binding:"MaxSize(50)"` LocationCoordinate string `binding:"MaxSize(255)"` MaxRepoCreation int diff --git a/templates/admin/user/edit.tmpl b/templates/admin/user/edit.tmpl index f88e2bbc56..531101a2a9 100644 --- a/templates/admin/user/edit.tmpl +++ b/templates/admin/user/edit.tmpl @@ -73,6 +73,12 @@

{{.i18n.Tr "admin.users.password_helper"}}

+
+ + +