mirror of
https://github.com/langgenius/dify.git
synced 2026-07-31 17:29:37 +08:00
refactor(web): remove dead dataset operator context state (#39800)
This commit is contained in:
parent
b32c900761
commit
e834fa212d
@ -18,7 +18,6 @@ export const baseProviderContextValue: ProviderContextState = {
|
||||
onPlanInfoChanged: noop,
|
||||
enableReplaceWebAppLogo: false,
|
||||
modelLoadBalancingEnabled: false,
|
||||
datasetOperatorEnabled: false,
|
||||
enableEducationPlan: false,
|
||||
isEducationWorkspace: false,
|
||||
isEducationAccount: false,
|
||||
|
||||
@ -50,7 +50,6 @@ const defaultProviderContext = {
|
||||
onPlanInfoChanged: noop,
|
||||
enableReplaceWebAppLogo: false,
|
||||
modelLoadBalancingEnabled: false,
|
||||
datasetOperatorEnabled: false,
|
||||
enableEducationPlan: false,
|
||||
isEducationWorkspace: false,
|
||||
isEducationAccount: false,
|
||||
|
||||
@ -72,7 +72,6 @@ export const ProviderContextProvider = ({ children }: ProviderContextProviderPro
|
||||
const [enableBilling, setEnableBilling] = useState(true)
|
||||
const [enableReplaceWebAppLogo, setEnableReplaceWebAppLogo] = useState(false)
|
||||
const [modelLoadBalancingEnabled, setModelLoadBalancingEnabled] = useState(false)
|
||||
const [datasetOperatorEnabled, setDatasetOperatorEnabled] = useState(false)
|
||||
const [webappCopyrightEnabled, setWebappCopyrightEnabled] = useState(false)
|
||||
const [licenseLimit, setLicenseLimit] = useState({
|
||||
workspace_members: {
|
||||
@ -120,7 +119,6 @@ export const ProviderContextProvider = ({ children }: ProviderContextProviderPro
|
||||
}
|
||||
|
||||
if (data.model_load_balancing_enabled) setModelLoadBalancingEnabled(true)
|
||||
if (data.dataset_operator_enabled) setDatasetOperatorEnabled(true)
|
||||
if (data.webapp_copyright_enabled) setWebappCopyrightEnabled(true)
|
||||
setLicenseLimit({ workspace_members: resolveMemberInviteLimit(data) })
|
||||
if (data.is_allow_transfer_workspace)
|
||||
@ -207,7 +205,6 @@ export const ProviderContextProvider = ({ children }: ProviderContextProviderPro
|
||||
onPlanInfoChanged: fetchPlan,
|
||||
enableReplaceWebAppLogo,
|
||||
modelLoadBalancingEnabled,
|
||||
datasetOperatorEnabled,
|
||||
enableEducationPlan,
|
||||
isEducationWorkspace,
|
||||
isEducationAccount: isEducationDataFetchedAfterMount
|
||||
|
||||
@ -27,7 +27,6 @@ export type ProviderContextState = {
|
||||
onPlanInfoChanged: () => void
|
||||
enableReplaceWebAppLogo: boolean
|
||||
modelLoadBalancingEnabled: boolean
|
||||
datasetOperatorEnabled: boolean
|
||||
enableEducationPlan: boolean
|
||||
isEducationWorkspace: boolean
|
||||
isEducationAccount: boolean
|
||||
@ -61,7 +60,6 @@ export const baseProviderContextValue: ProviderContextState = {
|
||||
onPlanInfoChanged: noop,
|
||||
enableReplaceWebAppLogo: false,
|
||||
modelLoadBalancingEnabled: false,
|
||||
datasetOperatorEnabled: false,
|
||||
enableEducationPlan: false,
|
||||
isEducationWorkspace: false,
|
||||
isEducationAccount: false,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user