mirror of
				https://github.com/lingble/chatwoot.git
				synced 2025-10-30 18:47:51 +00:00 
			
		
		
		
	chore: Display app version on settings/admin area
This commit is contained in:
		| @@ -1,6 +1,6 @@ | ||||
| .logo-brand { | ||||
|   margin-bottom: $space-normal; | ||||
|   padding: $space-normal $space-smaller; | ||||
|   padding: $space-normal $space-smaller $space-small; | ||||
|   text-align: center; | ||||
| } | ||||
|  | ||||
| @@ -70,3 +70,9 @@ | ||||
|   left: $space-normal; | ||||
|   position: fixed; | ||||
| } | ||||
|  | ||||
| .app-version { | ||||
|   color: $color-gray; | ||||
|   font-size: $font-size-small; | ||||
|   padding-top: $space-smaller; | ||||
| } | ||||
|   | ||||
| @@ -13,6 +13,7 @@ html { | ||||
|   line-height: 1.15; /* 1 */ | ||||
|   -ms-text-size-adjust: 100%; /* 2 */ | ||||
|   -webkit-text-size-adjust: 100%; /* 2 */ | ||||
|   -moz-osx-font-smoothing: grayscale; | ||||
| } | ||||
|  | ||||
| /* Sections | ||||
|   | ||||
| @@ -17,6 +17,8 @@ class DashboardController < ActionController::Base | ||||
|       'PRIVACY_URL', | ||||
|       'DISPLAY_MANIFEST', | ||||
|       'CREATE_NEW_ACCOUNT_FROM_DASHBOARD' | ||||
|     ).merge( | ||||
|       APP_VERSION: Chatwoot.config[:version] | ||||
|     ) | ||||
|   end | ||||
| end | ||||
|   | ||||
| @@ -64,6 +64,10 @@ | ||||
|           </label> | ||||
|         </div> | ||||
|       </div> | ||||
|       <div class="current-version"> | ||||
|         {{ `v${globalConfig.appVersion}` }} | ||||
|       </div> | ||||
|  | ||||
|       <woot-submit-button | ||||
|         class="button nice success button--fixed-right-top" | ||||
|         :button-text="$t('GENERAL_SETTINGS.SUBMIT')" | ||||
| @@ -106,6 +110,7 @@ export default { | ||||
|   }, | ||||
|   computed: { | ||||
|     ...mapGetters({ | ||||
|       globalConfig: 'globalConfig/get', | ||||
|       getAccount: 'accounts/getAccount', | ||||
|       uiFlags: 'accounts/getUIFlags', | ||||
|     }), | ||||
| @@ -196,4 +201,10 @@ export default { | ||||
|     padding: $space-normal; | ||||
|   } | ||||
| } | ||||
|  | ||||
| .current-version { | ||||
|   font-size: var(--font-size-small); | ||||
|   text-align: center; | ||||
|   padding: var(--space-normal); | ||||
| } | ||||
| </style> | ||||
|   | ||||
| @@ -1,4 +1,5 @@ | ||||
| const { | ||||
|   APP_VERSION: appVersion, | ||||
|   CREATE_NEW_ACCOUNT_FROM_DASHBOARD: createNewAccountFromDashboard, | ||||
|   INSTALLATION_NAME: installationName, | ||||
|   LOGO_THUMBNAIL: logoThumbnail, | ||||
| @@ -9,6 +10,7 @@ const { | ||||
| } = window.globalConfig; | ||||
|  | ||||
| const state = { | ||||
|   appVersion, | ||||
|   createNewAccountFromDashboard, | ||||
|   installationName, | ||||
|   logo, | ||||
|   | ||||
| @@ -22,6 +22,7 @@ as defined by the routes in the `admin/` namespace | ||||
| <div class="navigation" role="navigation"> | ||||
|   <div class="logo-brand"> | ||||
|     <%= link_to image_tag('/brand-assets/logo.svg', alt: 'Chatwoot Admin Dashboard'), super_admin_root_url %> | ||||
|     <div class="app-version">v<%= Chatwoot.config[:version] %></div> | ||||
|   </div> | ||||
|  | ||||
|   <ul> | ||||
| @@ -45,8 +46,10 @@ as defined by the routes in the `admin/` namespace | ||||
|       <%= link_to "Sidekiq", sidekiq_web_url %> | ||||
|     </li> | ||||
|   </ul> | ||||
|   <li class="navigation__link logout"> | ||||
|     <i class="ion ion-log-out"></i> | ||||
|     <%= link_to "Logout", super_admin_logout_url %> | ||||
|   </li> | ||||
|   <ul class="logout"> | ||||
|     <li class="navigation__link"> | ||||
|       <i class="ion ion-log-out"></i> | ||||
|       <%= link_to "Logout", super_admin_logout_url %> | ||||
|     </li> | ||||
|   </ul> | ||||
| </div> | ||||
|   | ||||
| @@ -1,5 +1,5 @@ | ||||
| shared: &shared | ||||
|   version: '1.6.1' | ||||
|   version: '1.7.0' | ||||
|  | ||||
| development: | ||||
|   <<: *shared | ||||
| @@ -7,8 +7,8 @@ development: | ||||
| production: | ||||
|   <<: *shared | ||||
|  | ||||
| staging:  | ||||
| staging: | ||||
|   <<: *shared | ||||
|  | ||||
| test:  | ||||
|   <<: *shared | ||||
| test: | ||||
|   <<: *shared | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Pranav Raj Sreepuram
					Pranav Raj Sreepuram