Skip to content

Commit

Permalink
Fix Profile (adempiere#1256)
Browse files Browse the repository at this point in the history
* Fix: Profile

* update module theme
  • Loading branch information
elsiosanchez authored Jul 31, 2023
1 parent 4d4e925 commit 1d85aaa
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 16 deletions.
3 changes: 2 additions & 1 deletion src/layout/components/Sidebar/Logo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ export default {
.sidebar-logo-container {
position: relative;
width: 100%;
height: 70px;
min-height: 70px;
max-height: 90px;
// line-height: 50px;
background: #2b2f3a;
text-align: center;
Expand Down
2 changes: 1 addition & 1 deletion src/themes/default
43 changes: 29 additions & 14 deletions src/views/profile/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,20 @@
</el-col>

<el-col :span="16" :xs="24">
<el-card>
<el-tabs v-model="activeTab">
<el-tab-pane :label="$t('profile.role')" name="role">
<role />
</el-tab-pane>
<el-tab-pane :label="$t('page.settings.title')" :name="$t('page.settings.title')">
<settings />
</el-tab-pane>
</el-tabs>
<el-card shadow="always">
<el-col :span="16" style="padding-right:10px;margin-bottom:20px;">
<h1 style="margin-bottom: 5px;">{{ $t('component.dashboard.header.welcome') }} {{ userInfo.name }}</h1>
{{ userInfo.description }}
</el-col>

<el-col :span="8">
<br>
<b>{{ $t('component.dashboard.header.role') }}: </b> {{ currentRole.name }} <br>
<b>{{ $t('component.dashboard.header.client') }}: </b> {{ currentRole.clientName }} <br>
<b>{{ $t('component.dashboard.header.organization') }}: </b> {{ organization.name }} <br>
<b>{{ $t('component.dashboard.header.warehouse') }}: </b> {{ warehouse.name }} <br>
<br>
</el-col>
</el-card>
</el-col>

Expand All @@ -28,15 +33,11 @@
<script>
import { mapGetters, mapState } from 'vuex'
import UserCard from './components/UserCard'
import Role from '@/views/profile/components/role'
import { Settings } from '@/layout/components'
export default {
name: 'Profile',
components: {
UserCard,
Role,
Settings
UserCard
},
data() {
return {
Expand Down Expand Up @@ -66,6 +67,20 @@ export default {
withoutAnimation: this.sidebar.withoutAnimation,
mobile: this.device === 'mobile'
}
},
currentRole() {
return this.$store.getters['user/getRole']
},
userInfo() {
return this.$store.getters['user/userInfo']
},
organization() {
return this.$store.getters['user/getOrganization']
},
warehouse() {
return this.$store.getters['user/getWarehouse'] || {
name: ''
}
}
},
created() {
Expand Down

0 comments on commit 1d85aaa

Please sign in to comment.