|
@@ -73,7 +73,7 @@
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script lang="ts" setup>
|
|
<script lang="ts" setup>
|
|
|
- import { h, reactive, ref, onMounted } from 'vue';
|
|
|
|
|
|
|
+ import { h, reactive, ref, onMounted, onBeforeUnmount } from 'vue';
|
|
|
import { BasicTable, BasicColumn } from '@/components/Table';
|
|
import { BasicTable, BasicColumn } from '@/components/Table';
|
|
|
import { Plus, DocumentAdd } from '@element-plus/icons-vue';
|
|
import { Plus, DocumentAdd } from '@element-plus/icons-vue';
|
|
|
import { roleAllList } from '@/api/system/role';
|
|
import { roleAllList } from '@/api/system/role';
|
|
@@ -94,7 +94,7 @@
|
|
|
|
|
|
|
|
const useUserDetail = useUser();
|
|
const useUserDetail = useUser();
|
|
|
const { userList, page, pageSize, totalCount } = storeToRefs(useUserDetail);
|
|
const { userList, page, pageSize, totalCount } = storeToRefs(useUserDetail);
|
|
|
- const { conditionSearch, userDel } = useUserDetail;
|
|
|
|
|
|
|
+ const { conditionSearch, userDel, getList, resetArgs } = useUserDetail;
|
|
|
|
|
|
|
|
const userStore = useUserStore();
|
|
const userStore = useUserStore();
|
|
|
|
|
|
|
@@ -201,6 +201,7 @@
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
onMounted(async () => {
|
|
onMounted(async () => {
|
|
|
|
|
+ getList();
|
|
|
const res = await roleAllList();
|
|
const res = await roleAllList();
|
|
|
roleData.value = res.list.map((item: any) => {
|
|
roleData.value = res.list.map((item: any) => {
|
|
|
return {
|
|
return {
|
|
@@ -209,6 +210,10 @@
|
|
|
};
|
|
};
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|
|
|
|
|
+
|
|
|
|
|
+ onBeforeUnmount(() => {
|
|
|
|
|
+ resetArgs();
|
|
|
|
|
+ });
|
|
|
</script>
|
|
</script>
|
|
|
<style scoped>
|
|
<style scoped>
|
|
|
.user-page {
|
|
.user-page {
|