diff --git a/gms-ui/.env.development b/gms-ui/.env.development index 50ae1fd484dd4309452661c0062b6c50eaedadcc..e5ef8f853e0bb42437854d0bcb914c25c38e832e 100644 --- a/gms-ui/.env.development +++ b/gms-ui/.env.development @@ -1,2 +1,3 @@ VUE_APP_API_CLIENT = 'mock' VUE_APP_API_BASE_URL = '' +VUE_APP_SHOW_USER_ID_IN_SEARCH = true diff --git a/gms-ui/.env.production b/gms-ui/.env.production index 6010f55022316c82ff11bfeeb216720afd9614ea..249ade861148481d6ff7b8f6744b65df1ba9ae18 100644 --- a/gms-ui/.env.production +++ b/gms-ui/.env.production @@ -1,2 +1,3 @@ VUE_APP_API_CLIENT = 'server' VUE_APP_API_BASE_URL = '' +VUE_APP_SHOW_USER_ID_IN_SEARCH = true diff --git a/gms-ui/package-lock.json b/gms-ui/package-lock.json index 87acba771c61e74fa8cf1a3ad1da2c5ee972070f..d46c5e955a85cc4c17b7fd8dea6e811727c983e1 100644 --- a/gms-ui/package-lock.json +++ b/gms-ui/package-lock.json @@ -6573,7 +6573,8 @@ "dependencies": { "acorn": { "version": "6.1.1", - "resolved": "", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-6.1.1.tgz", + "integrity": "sha512-jPTiwtOxaHNaAPg/dmrJ/beuzLRnXtB0kQPQ8JpotKJgTB6rX6c8mlf315941pyjBSaPg8NHXS9fhP4u17DpGA==", "dev": true }, "acorn-jsx": { diff --git a/gms-ui/src/components/modals/SearchUser.vue b/gms-ui/src/components/modals/SearchUser.vue index 5f96f4bbdfdb6ffcb7d3e417cc6bfcd9601a57d8..a37151d3a81518133eaa032f3f53fa8af3217d76 100644 --- a/gms-ui/src/components/modals/SearchUser.vue +++ b/gms-ui/src/components/modals/SearchUser.vue @@ -17,6 +17,8 @@ </template> <script> +const SHOW_USER_ID_IN_SEARCH = process.env.VUE_APP_SHOW_USER_ID_IN_SEARCH === 'true'; + import client from 'api-client'; import debounce from 'debounce'; // for delaying the input event (search filter) @@ -50,7 +52,7 @@ export default { let user = res[i]; this.users.push({ value: user.id, - text: user.displayName + ' [' + user.id + ']' + text: user.displayName + (SHOW_USER_ID_IN_SEARCH ? ' [' + user.id + ']' : '') }); } if (this.users.length > 0) { diff --git a/gms/pom.xml b/gms/pom.xml index 47d61e3a46cfc29fdfb27805792ebb1e8fbfdfca..c54b41834f454586d6e13ff304687ec9fddd5b8c 100644 --- a/gms/pom.xml +++ b/gms/pom.xml @@ -16,6 +16,7 @@ <properties> <java.version>1.8</java.version> + <show.user_id_in_search>true</show.user_id_in_search> </properties> <dependencies> @@ -75,6 +76,9 @@ <version>1.7.6</version> <configuration> <nodeVersion>v12.6.0</nodeVersion> + <environmentVariables> + <VUE_APP_SHOW_USER_ID_IN_SEARCH>${show.user_id_in_search}</VUE_APP_SHOW_USER_ID_IN_SEARCH> + </environmentVariables> </configuration> <executions> <execution>