Skip to content

Commit ef85f52

Browse files
Merge pull request #414 from yetanalytics/sql-250
[SQL-250] UI no longer cares about HTML
2 parents d967da8 + 23af8f2 commit ef85f52

File tree

5 files changed

+4
-7
lines changed

5 files changed

+4
-7
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
# Version of LRS Admin UI to use
44

5-
LRS_ADMIN_UI_VERSION ?= v0.1.20
5+
LRS_ADMIN_UI_VERSION ?= v0.1.21
66
LRS_ADMIN_UI_LOCATION ?= https://github.com/yetanalytics/lrs-admin-ui/releases/download/${LRS_ADMIN_UI_VERSION}/lrs-admin-ui.zip
77
LRS_ADMIN_ZIPFILE ?= lrs-admin-ui-${LRS_ADMIN_UI_VERSION}.zip
88

doc/endpoints.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ The response body contains a newly generated JSON Web Token (JWT) on success. A
4141

4242
#### Misc Admin Routes
4343

44-
- `GET http://example.org/admin/env`: Get select environment variables about the configuration which may aid in client-side operations. Currently returns a map containing the configuration variables `urlPrefix` and `enableStmtHtml`.
44+
- `GET http://example.org/admin/env`: Get select environment variables about the configuration which may aid in client-side operations.
4545
- `DELETE http://example.org/admin/agents`: Runs a *hard delete* of all records of an actor, and associated records (statements, attachments, etc). Intended for privacy purposes like GDPR. Body should be a JSON object of form `{"actor-ifi":<actor-ifi>}`. Disabled unless the configuration variable enableAdminDeleteActor to be set to `true`.
4646

4747
### Reaction Management Routes

doc/env_vars.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ These config vars enable and configure browser security response headers from th
201201
| `LRSQL_ENABLE_ADMIN_DELETE_ACTOR` | `enableAdminDeleteActor` | Whether or not to enable the route and UI for deleting actors and related documents | `false` |
202202
| `LRSQL_ENABLE_ADMIN_UI` | `enableAdminUi` | Whether or not to serve the administrative UI at `/admin` | `true` |
203203
| `LRSQL_ENABLE_ADMIN_STATUS` | `enableAdminStatus` | Whether or not to serve admin system status data that queries the database. | `true` |
204-
| `LRSQL_ENABLE_STMT_HTML` | `enableStmtHtml` | Whether or not HTML data is returned in the LRS HTTP response. If `false` disables HTML rendering even if `LRSQL_ENABLE_ADMIN_UI` is `true`. In that case the UI will not display the Statement Browser feature. | `true` |
204+
| `LRSQL_ENABLE_STMT_HTML` | `enableStmtHtml` | Whether or not HTML data is returned in the LRS HTTP response if the Accept type is specified as text/html. If `false` disables HTML rendering regardless of Accept type. | `true` |
205205
| `LRSQL_ADMIN_LANGUAGE` | `adminLanguage` | Allows override of default RFC5646 language code (`en-US`). May require that you add new language map entries to `resources/lrsql/localization/language.json` to add a new language. | `en-US` |
206206

207207
[<- Back to Index](index.md)

src/main/lrsql/admin/interceptors/ui.clj

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
:enter
3434
(fn get-env [ctx]
3535
(let [{url-prefix ::i/path-prefix
36-
enable-stmt-html ::i/statement-html?
3736
oidc-env ::oidc-i/admin-env} ctx]
3837
(assoc ctx
3938
:response
@@ -42,7 +41,6 @@
4241
(merge
4342
(cond-> {:url-prefix url-prefix
4443
:proxy-path proxy-path
45-
:enable-stmt-html (some? enable-stmt-html)
4644
:enable-admin-delete-actor enable-admin-delete-actor
4745
:enable-admin-status enable-admin-status
4846
:enable-reactions enable-reactions

src/test/lrsql/admin/route_test.clj

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,8 +142,7 @@
142142
(let [{:keys [status body]} (get-env content-type)
143143
edn-body (u/parse-json body)]
144144
(is (= 200 status))
145-
(is (= (get edn-body "url-prefix") "/xapi"))
146-
(is (= (get edn-body "enable-stmt-html") true))))
145+
(is (= (get edn-body "url-prefix") "/xapi"))))
147146
(testing "create account with username `myname` and password `swordfish`"
148147
(let [{:keys [status
149148
body]} (create-account headers req-body)

0 commit comments

Comments
 (0)