WIP My Account.

This commit is contained in:
Cindy Chang
2024-08-27 14:25:20 +08:00
parent 49b8233909
commit 56096a01de
4 changed files with 49 additions and 19 deletions

View File

@@ -66,6 +66,8 @@ export default {
const onBtnMyAccountClick = async() => {
acctMgmtStore.closeAcctMenu();
await acctMgmtStore.getAllUserAccounts(); // in case we haven't fetched yet
await acctMgmtStore.setCurrentViewingUser(loginUserData.value.username);
await router.push('/my-account');
}

View File

@@ -191,6 +191,7 @@
</li>
</ul>
</TabPanel>
<!-- 從shortest_traces開始迭代 -->
<TabPanel v-for="([field, label], i) in fieldNamesAndLabelNames" :key="i" :header="label"
contentClass="text-sm">
<p v-if="insights[field].length === 0" class="bg-neutral-100 p-2 rounded">No data</p>
@@ -250,7 +251,7 @@ import i18next from '@/i18n/i18n';
import { INSIGHTS_FIELDS_AND_LABELS } from '@/constants/constants';
// 刪除第一個和第二個元素
const fieldNamesAndLabelNames = [...INSIGHTS_FIELDS_AND_LABELS].splice(0, 2);
const fieldNamesAndLabelNames = [...INSIGHTS_FIELDS_AND_LABELS].slice(2);
export default {
props:{
sidebarState: {
@@ -266,7 +267,7 @@ export default {
required: false,
}
},
setup(){
setup(props){
const pageAdmin = PageAdmin();
const mapPathStore = MapPathStore();
@@ -276,18 +277,12 @@ export default {
const isBPMNOn = computed(() => mapPathStore.isBPMNOn);
const onActiveTraceClick = (clickedActiveTraceIndex) => {
if(isBPMNOn.value) {
return;
}
mapPathStore.clearAllHighlight();
activeTrace.value = clickedActiveTraceIndex;
mapPathStore.highlightClickedPath(clickedActiveTraceIndex, clickedPathListIndex.value);
}
const onPathOptionClick = (clickedPath) => {
if(isBPMNOn.value) {
return;
}
clickedPathListIndex.value = clickedPath;
mapPathStore.highlightClickedPath(activeTrace.value, clickedPathListIndex.value);
};