Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6.1.4 版本设置 destroyOnClose 为true后,重新打开,弹窗里的内容没有渲染 #410

Open
wfwfwf128 opened this issue Mar 22, 2023 · 0 comments

Comments

@wfwfwf128
Copy link

使用BetaSchemaForm, drawer的版本号为6.1.4时,弹窗打开再关才后,再次打开时,弹窗里的内容没有渲染,一片空白。

<BetaSchemaForm
      layoutType="DrawerForm"
      formRef={formRef}
      title={titleTxt}
      columns={fromType === 'parent' ? parentColumns : childColumns}
      visible={visible}
      drawerProps={{
        destroyOnClose: true,
        maskClosable: type === 'view',
      }}
      onFinish={onFinish}
      onVisibleChange={async (vis: boolean) => {
        await setParam({ versionName: '', id: null });
        if (!vis) {
          if (formRef?.current) {
            formRef?.current.resetFields();
          }
          onClose(false);
        } else {
          if (record && record.id) {
            if (formRef?.current) {
              formRef?.current?.setFieldsValue(record);
            }
          } else {
            formRef?.current?.resetFields();
          }
        }
      }}
    />

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant