2019-08-08 06:10:53 +12:00
< div
2020-01-31 06:12:29 +13:00
data-service="users.get"
2019-08-08 06:10:53 +12:00
data-name="user"
2020-02-10 10:44:11 +13:00
data-event="load,users.update"
2019-08-08 06:10:53 +12:00
data-param-user-id="{{router.params.id}}"
data-success="trigger"
2020-01-31 09:58:49 +13:00
data-success-param-trigger-events="users.get">
2019-05-09 18:54:39 +12:00
< div class = "cover" >
< h1 class = "zone xl margin-bottom-large" >
2020-06-10 02:43:24 +12:00
< a data-ls-attrs = "href=/console/users?project={{router.params.project}}" class = "back text-size-small link-return-animation--start" > < i class = "icon-left-open" > < / i > Users< / a >
2019-05-09 18:54:39 +12:00
< br / >
2019-05-10 04:15:51 +12:00
< span data-ls-bind = "{{user.name}}" > < / span >
2020-06-07 15:51:11 +12:00
< span data-ls-if = "{{user.name}} === ''" > Unknown< / span >
2019-05-09 18:54:39 +12:00
< / h1 >
< / div >
2020-04-24 06:49:31 +12:00
< div data-ui-modal class = "modal width-large box close" data-button-hide = "on" data-open-event = "open-json" >
< button type = "button" class = "close pull-end" data-ui-modal-close = "" > < i class = "icon-cancel" > < / i > < / button >
< h2 > JSON View< / h2 >
< div class = "margin-bottom" >
< input type = "hidden" data-ls-bind = "{{user}}" data-forms-code / >
< / div >
< button data-ui-modal-close = "" type = "button" class = "reverse" > Cancel< / button >
< / div >
2019-05-09 18:54:39 +12:00
< div class = "zone xl" >
2019-05-09 20:23:22 +12:00
< ul class = "phases clear" data-ui-phases data-selected = "{{router.params.tab}}" >
2020-05-11 16:39:00 +12:00
< li data-state = "/console/users/user?id={{router.params.id}}&project={{router.params.project}}" >
2020-07-17 09:51:43 +12:00
< h2 > Overview< / h2 >
2019-05-09 18:54:39 +12:00
2020-03-25 06:56:32 +13:00
< div data-ls-if = "{{user.status}} === <?php echo \Appwrite\Auth\Auth :: USER_STATUS_BLOCKED ; ?> " style = "display: none" class = "box padding-small danger margin-bottom-xxl text-align-center" >
2019-05-09 18:54:39 +12:00
This user account is blocked.
< / div >
< div class = "row responsive margin-top-xl" >
< div class = "col span-8" >
2020-05-01 04:35:39 +12:00
< label > < / label >
2019-05-09 18:54:39 +12:00
< div class = "box margin-bottom-large" >
2019-08-12 09:52:36 +12:00
< div class = "text-align-center" >
2020-06-11 20:58:53 +12:00
< img src = "" data-ls-attrs = "src={{user|avatar}}" data-size = "200" alt = "User Avatar" class = "avatar huge margin-top-negative-xxl" / >
2019-05-09 18:54:39 +12:00
2020-07-15 23:22:38 +12:00
< div class = "margin-top-small" data-ls-bind = "Member since {{user.registration|dateText}}" > < / div >
2019-05-09 18:54:39 +12:00
< div class = "margin-top-small" >
2020-02-24 08:27:02 +13:00
< span data-ls-if = "{{user.emailVerification}} === true" >
2019-05-09 18:54:39 +12:00
< span class = "tag green" > Verified< / span >
< / span >
2020-02-24 08:27:02 +13:00
< span data-ls-if = "{{user.emailVerification}} !== true" >
2019-05-09 18:54:39 +12:00
< span class = "tag" > Unverified< / span >
< / span >
< / div >
2019-05-10 04:15:51 +12:00
< div class = "margin-top-small" data-ls-bind = "{{user.email}}" > < / div >
2019-05-09 18:54:39 +12:00
< / div >
< / div >
< h3 class = "margin-bottom" > Preferences< / h3 >
2019-08-08 06:10:53 +12:00
< div class = "box margin-bottom"
2020-01-31 06:12:29 +13:00
data-service="users.getPrefs"
2019-08-08 06:10:53 +12:00
data-name="user-prefs"
data-event="load"
data-param-user-id="{{router.params.id}}"
data-success="trigger"
2020-01-31 09:58:49 +13:00
data-success-param-trigger-events="users.getPrefs">
2019-05-09 18:54:39 +12:00
2020-02-24 08:27:02 +13:00
< div data-ls-if = "!{{user-prefs|isEmptyObject}}" >
2019-05-09 18:54:39 +12:00
< table class = "vertical" >
< thead >
2019-08-06 18:42:47 +12:00
< tr >
< th > Key< / th >
< th > Value< / th >
< / tr >
2019-05-09 18:54:39 +12:00
< / thead >
< tbody data-ls-loop = "user-prefs" data-ls-as = "pref" >
2019-08-06 18:42:47 +12:00
< tr >
< td data-title = "Key: " >
< span data-ls-bind = "{{$index}}" > < / span >
< / td >
< td data-title = "Value: " >
< span data-ls-bind = "{{pref}}" > < / span >
< / td >
< / tr >
2019-05-09 18:54:39 +12:00
< / tbody >
< / table >
< / div >
2020-02-24 08:27:02 +13:00
< div data-ls-if = "{{user-prefs|isEmptyObject}}" >
2019-05-09 18:54:39 +12:00
No user preferences found
< / div >
< / div >
< / div >
2020-05-01 04:35:39 +12:00
< div class = "col span-4 sticky-top" >
2019-05-09 18:54:39 +12:00
< label > User ID< / label >
2020-04-24 06:49:31 +12:00
< div class = "input-copy margin-bottom" >
2020-02-17 20:16:11 +13:00
< input id = "uid" type = "text" autocomplete = "off" placeholder = "" data-ls-bind = "{{user.$id}}" disabled data-forms-copy >
2019-05-09 18:54:39 +12:00
< / div >
2020-04-24 06:49:31 +12:00
< ul class = "margin-bottom-large text-fade text-size-small" >
< li class = "margin-bottom-small" > < i class = "icon-angle-circled-right margin-start-tiny margin-end-tiny" > < / i > < button data-ls-ui-trigger = "open-json" class = "link text-size-small" > View as JSON< / button > < / li >
< / ul >
2020-03-25 06:56:32 +13:00
< div data-ls-if = "{{user.status}} !== <?php echo \Appwrite\Auth\Auth :: USER_STATUS_BLOCKED ; ?> " style = "display: none" >
2019-08-08 06:10:53 +12:00
< form name = "users.updateStatus" class = "margin-bottom"
2020-02-04 19:28:41 +13:00
data-analytics-event="submit"
data-analytics-category="console"
data-analytics-label="Update User Status"
2020-01-31 06:12:29 +13:00
data-service="users.updateStatus"
2019-08-08 06:10:53 +12:00
data-event="submit"
data-param-user-id="{{router.params.id}}"
data-success="alert,trigger"
2020-06-07 18:22:51 +12:00
data-success-param-alert-text="Blocked user successfully"
2020-01-31 09:58:49 +13:00
data-success-param-trigger-events="users.update"
2019-08-08 17:09:49 +12:00
data-failure="alert"
2020-06-07 18:22:51 +12:00
data-failure-param-alert-text="Failed to block user"
2019-08-09 01:43:24 +12:00
data-failure-param-alert-classname="error">
2019-08-08 06:10:53 +12:00
2020-03-25 06:56:32 +13:00
< button name = "status" type = "submit" class = "danger fill" value = " <?php echo \Appwrite\Auth\Auth :: USER_STATUS_BLOCKED ; ?> " > Block Account</ button >
2019-05-09 18:54:39 +12:00
< / form >
< / div >
2020-03-25 06:56:32 +13:00
< div data-ls-if = "{{user.status}} === <?php echo \Appwrite\Auth\Auth :: USER_STATUS_BLOCKED ; ?> " style = "display: none" >
2019-08-08 06:10:53 +12:00
< form name = "users.updateStatus" class = "margin-bottom"
2020-02-04 19:28:41 +13:00
data-analytics-event="submit"
data-analytics-category="console"
data-analytics-label="Update User Status"
2020-01-31 06:12:29 +13:00
data-service="users.updateStatus"
2019-08-08 06:10:53 +12:00
data-event="submit"
data-param-user-id="{{router.params.id}}"
data-success="alert,trigger"
2020-06-07 18:22:51 +12:00
data-success-param-alert-text="Activated user successfully"
2020-01-31 09:58:49 +13:00
data-success-param-trigger-events="users.update"
2019-08-08 17:09:49 +12:00
data-failure="alert"
2020-06-07 18:22:51 +12:00
data-failure-param-alert-text="Failed to activate user"
2019-08-09 01:43:24 +12:00
data-failure-param-alert-classname="error">
2019-05-09 18:54:39 +12:00
2020-03-25 06:56:32 +13:00
< button name = "status" type = "submit" class = "fill" value = " <?php echo \Appwrite\Auth\Auth :: USER_STATUS_ACTIVATED ; ?> " > Activate Account</ button >
2019-05-09 18:54:39 +12:00
< / form >
< / div >
< / div >
< / div >
< / li >
2020-05-11 16:39:00 +12:00
< li data-state = "/console/users/user/devices?id={{router.params.id}}&project={{router.params.project}}" >
2019-05-09 18:54:39 +12:00
< h2 > Devices< / h2 >
2019-08-08 06:10:53 +12:00
< div
2020-01-31 06:12:29 +13:00
data-service="users.getSessions"
2019-08-08 06:10:53 +12:00
data-name="sessions"
data-param-user-id="{{router.params.id}}"
2020-05-01 18:27:35 +12:00
data-event="load,users.update">
2019-05-09 18:54:39 +12:00
2020-05-01 06:47:08 +12:00
< div data-ls-if = "{{sessions.length}} === 0" style = "display: none" class = "margin-top-xxl margin-bottom-xxl text-align-center" >
No sessions available.
2019-05-09 18:54:39 +12:00
< / div >
2019-05-12 03:26:03 +12:00
< div data-ls-if = "{{sessions.length}} !== 0" style = "display: none" >
2019-05-09 18:54:39 +12:00
< div class = "box margin-bottom" >
< ul data-ls-loop = "sessions" data-ls-as = "session" class = "list" >
< li class = "clear" >
2019-08-08 06:10:53 +12:00
< form class = "pull-end"
2020-02-04 19:28:41 +13:00
data-analytics-event="submit"
data-analytics-category="console"
data-analytics-label="Delete User Session"
2020-01-31 06:12:29 +13:00
data-service="users.deleteSession"
2019-08-08 06:10:53 +12:00
data-event="submit"
data-loading="Loading..."
data-success="trigger"
2020-01-31 09:58:49 +13:00
data-success-param-trigger-events="users.update"
2019-08-08 17:09:49 +12:00
data-failure="alert"
2019-08-09 01:43:24 +12:00
data-failure-param-alert-text="Failed to logout session"
data-failure-param-alert-classname="error">
2019-05-10 04:15:51 +12:00
< input type = "hidden" name = "userId" data-ls-bind = "{{router.params.id}}" >
2020-05-01 18:27:35 +12:00
< input type = "hidden" name = "sessionId" data-ls-bind = "{{session.$id}}" >
2019-05-09 18:54:39 +12:00
< button class = "danger" > Logout< / button >
< / form >
2019-12-07 08:54:23 +13:00
< img data-ls-attrs = "src={{env.API}}/avatars/browsers/{{session.client.short_name|lowercase}}?width=120&height=120&project={{env.PROJECT}},title={{session.client.name}},alt={{session.client.name}}" class = "avatar trans pull-start margin-end" / >
2019-05-09 18:54:39 +12:00
2019-05-10 04:15:51 +12:00
< span data-ls-bind = "{{session.client.name}}" > < / span > < span data-ls-bind = "{{session.client.version}}" > < / span > on < span data-ls-bind = "{{session.model}}" > < / span > < span data-ls-bind = "{{session.OS.name}}" > < / span > < span data-ls-bind = "{{session.OS.version}}" > < / span >
2019-05-09 18:54:39 +12:00
2019-08-24 07:07:17 +12:00
< div class = "margin-top-small" >
2020-04-12 18:03:00 +12:00
< img data-ls-attrs = "src={{env.API}}/avatars/flags/{{session.geo.isoCode}}?width=80&height=80&project={{env.PROJECT}}" class = "avatar xxs margin-end-small inline" / >
2019-05-10 04:15:51 +12:00
< small data-ls-bind = "{{session.ip}}" > < / small > / < small data-ls-bind = "{{session.geo.country}}" > < / small >
2019-05-09 18:54:39 +12:00
< / div >
< / li >
< / ul >
< / div >
2019-08-08 06:10:53 +12:00
< form class = "inline margin-bottom-large"
2020-02-04 19:28:41 +13:00
data-analytics-event="submit"
data-analytics-category="console"
data-analytics-label="Delete User Sessions"
2020-01-31 06:12:29 +13:00
data-service="users.deleteSessions"
2019-08-08 06:10:53 +12:00
data-param-user-id="{{router.params.id}}"
data-event="submit"
data-success="trigger"
2020-01-31 09:58:49 +13:00
data-success-param-trigger-events="users.update"
2019-08-08 17:09:49 +12:00
data-failure="alert"
2019-08-09 01:43:24 +12:00
data-failure-param-alert-text="Failed to logout all sessions"
data-failure-param-alert-classname="error">
2019-05-09 18:54:39 +12:00
< button class = "danger" > Logout from all devices< / button >
< / form >
< / div >
< / div >
< / li >
2020-05-11 16:39:00 +12:00
< li data-state = "/console/users/user/audit?id={{router.params.id}}&project={{router.params.project}}" >
2020-02-29 19:24:55 +13:00
< h2 > Activity< / h2 >
2019-05-09 18:54:39 +12:00
2019-08-08 06:10:53 +12:00
< div
2020-01-31 06:12:29 +13:00
data-service="users.getLogs"
2019-08-08 06:10:53 +12:00
data-name="logs"
data-param-user-id="{{router.params.id}}"
data-event="load,logs-load">
2019-05-09 18:54:39 +12:00
2020-05-01 06:47:08 +12:00
< div data-ls-if = "{{logs.length}} === 0" style = "display: none" class = "margin-top-xxl margin-bottom-xxl text-align-center" >
No logs available.
2019-05-09 18:54:39 +12:00
< / div >
2019-05-12 03:26:03 +12:00
< div class = "box" data-ls-if = "{{logs.length}} !== 0" style = "display: none" >
2019-05-09 18:54:39 +12:00
< table class = "vertical small" >
< thead >
2019-08-06 18:42:47 +12:00
< tr >
2019-09-27 06:47:48 +12:00
< th width = "140" > Date< / th >
< th width = "175" > Event< / th >
< th > Client< / th >
< th width = "90" > Location< / th >
< th width = "90" > IP< / th >
2019-08-06 18:42:47 +12:00
< / tr >
2019-05-09 18:54:39 +12:00
< / thead >
< tbody data-ls-loop = "logs" data-ls-as = "log" >
2019-08-06 18:42:47 +12:00
< tr >
2020-07-15 23:22:38 +12:00
< td data-title = "Date: " > < span data-ls-bind = "{{log.time|dateTime}}" > < / span > < / td >
2019-09-27 06:47:48 +12:00
< td data-title = "Event: " > < span data-ls-bind = "{{log.event}}" > < / span > < / td >
< td data-title = "Client: " >
2020-05-14 09:38:18 +12:00
< img data-ls-if = "({{log.client.short_name}})" data-ls-attrs = "src={{env.API}}/avatars/browsers/{{log.client.short_name|lowercase}}?width=80&height=80&project={{env.PROJECT}},title={{log.client.name}},alt={{log.client.name}}" class = "avatar xxs inline margin-end-small" / >
< span data-ls-if = "({{log.client.name}})" data-ls-bind = "{{log.client.name}} {{log.client.version}} on {{log.model}} {{log.OS.name}} {{log.OS.version}}" > < / span >
< div data-ls-if = "(!{{log.client.name}})" class = "text-align-center text-fade" > Unknown< / div >
2019-08-06 18:42:47 +12:00
< / td >
2019-09-27 06:47:48 +12:00
< td data-title = "Location: " >
2020-04-12 18:03:00 +12:00
< img data-ls-attrs = "src={{env.API}}/avatars/flags/{{log.geo.isoCode}}?width=80&height=80&project={{env.PROJECT}}" class = "avatar xxs inline margin-end-small" / >
2019-08-06 18:42:47 +12:00
< span data-ls-bind = "{{log.geo.country}}" > < / span >
< / td >
2019-09-27 06:47:48 +12:00
< td data-title = "IP: " > < span data-ls-bind = "{{log.ip}}" > < / span > < / td >
2019-08-06 18:42:47 +12:00
< / tr >
2019-05-09 18:54:39 +12:00
< / tbody >
< / table >
< / div >
< / div >
< / li >
< / ul >
< / div >
2020-06-10 02:43:24 +12:00
< / div >