|
@@ -234,7 +234,9 @@ const state: any = reactive({
|
|
|
pageSize: 20,
|
|
|
},
|
|
|
form: {},
|
|
|
- formReal: {},
|
|
|
+ formReal: {
|
|
|
+ tenantId: AppStore.tenantInfo?.id,
|
|
|
+ },
|
|
|
sort: {},
|
|
|
result: {
|
|
|
total: 0,
|
|
@@ -394,14 +396,25 @@ onMounted(() => {
|
|
|
initDictionary()
|
|
|
onReset()
|
|
|
})
|
|
|
-const initDictionary = () => {
|
|
|
- DictionaryStore.initTenants()
|
|
|
+watch(
|
|
|
+ () => state.query.form.tenantId,
|
|
|
+ () => initRoles(),
|
|
|
+)
|
|
|
+const initRoles = () => {
|
|
|
state.invite.roleOptions = []
|
|
|
- rolesPage({ page: 1, size: 100000 }).then(({ data }: any) => {
|
|
|
+ rolesPage({
|
|
|
+ page: 1,
|
|
|
+ size: 100000,
|
|
|
+ tenantId: state.query.form.tenantId,
|
|
|
+ }).then(({ data }: any) => {
|
|
|
state.invite.roleOptions =
|
|
|
data.content?.map((v) => ({ label: v.roleName, value: v.id })) || []
|
|
|
})
|
|
|
}
|
|
|
+const initDictionary = () => {
|
|
|
+ DictionaryStore.initTenants()
|
|
|
+ initRoles()
|
|
|
+}
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped></style>
|