fix: collection level authorization inheritance issue (#3852)

This commit is contained in:
Anwarul Islam
2024-02-23 20:03:08 +06:00
committed by Andrew Bastin
parent 6827e97ec5
commit bd406616ec
8 changed files with 52 additions and 52 deletions

View File

@@ -614,8 +614,8 @@ const addNewRootCollection = (name: string) => {
requests: [],
headers: [],
auth: {
authType: "inherit",
authActive: false,
authType: "none",
authActive: true,
},
})
)

View File

@@ -31,17 +31,6 @@
tabindex="0"
@keyup.escape="hide()"
>
<HoppSmartItem
label="None"
:icon="authName === 'None' ? IconCircleDot : IconCircle"
:active="authName === 'None'"
@click="
() => {
auth.authType = 'none'
hide()
}
"
/>
<HoppSmartItem
v-if="!isRootCollection"
label="Inherit"
@@ -54,6 +43,17 @@
}
"
/>
<HoppSmartItem
label="None"
:icon="authName === 'None' ? IconCircleDot : IconCircle"
:active="authName === 'None'"
@click="
() => {
auth.authType = 'none'
hide()
}
"
/>
<HoppSmartItem
label="Basic Auth"
:icon="authName === 'Basic Auth' ? IconCircleDot : IconCircle"
@@ -284,7 +284,7 @@ const authActive = pluckRef(auth, "authActive")
const clearContent = () => {
auth.value = {
authType: "none",
authType: "inherit",
authActive: true,
}
}

View File

@@ -31,17 +31,6 @@
tabindex="0"
@keyup.escape="hide()"
>
<HoppSmartItem
label="None"
:icon="authName === 'None' ? IconCircleDot : IconCircle"
:active="authName === 'None'"
@click="
() => {
auth.authType = 'none'
hide()
}
"
/>
<HoppSmartItem
v-if="!isRootCollection"
label="Inherit"
@@ -54,6 +43,17 @@
}
"
/>
<HoppSmartItem
label="None"
:icon="authName === 'None' ? IconCircleDot : IconCircle"
:active="authName === 'None'"
@click="
() => {
auth.authType = 'none'
hide()
}
"
/>
<HoppSmartItem
label="Basic Auth"
:icon="authName === 'Basic Auth' ? IconCircleDot : IconCircle"
@@ -265,7 +265,7 @@ const authActive = pluckRef(auth, "authActive")
const clearContent = () => {
auth.value = {
authType: "none",
authType: "inherit",
authActive: true,
}
}