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

dcat版本从1.0更新到2.2.3后,所有弹窗表单中的动态按钮(如Export导出,Raw列 操作)都点不动了 #2135

Open
putianxin opened this issue Sep 3, 2024 · 3 comments

Comments

@putianxin
Copy link

putianxin commented Sep 3, 2024

  • Laravel Version: 9
  • PHP Version: 8.0
  • Dcat Admin Version: 2.2.3-beta

Description:

dcat版本从1.0更新到2.2.3后,所有弹窗表单中的动态按钮(如Export导出,Raw列 操作)都点不动了

本地测试报错:jQuery.Deferred exception: e.filter is not a function TypeError: e.filter is not a function

Steps To Reproduce:

@yi4396
Copy link

yi4396 commented Sep 4, 2024

大版本更新,请看升级文档:https://learnku.com/docs/dcat-admin/2.x/1-x-upgrade-guide/9645

@putianxin
Copy link
Author

putianxin commented Sep 11, 2024

是按照文档更新的,另外Modal弹窗在$this->response()->success() 操作后不会自动关闭,但是有提示成功。感觉是版本没兼容.
代码:
$tools->append(Modal::make() // 大号弹窗 ->lg() // 弹窗标题 ->title('用户余额加减钱') // 按钮 ->button('<button class="btn btn-primary"><i class="feather icon-dollar-sign"></i> 弹窗表单</button>') // 弹窗内容 ->body(TestModal::make()));
弹窗内容:
public function handle(array $input) { return $this->response()->success(“修改成功10001”); }
请求接口的返回:

{
    "status": true,
    "data": {
        "message": "修改成功10001",
        "type": "success"
    }
}

控制台报错信息:

SweetAlert2: showLoaderOnConfirm is set to true, but preConfirm is not defined.
showLoaderOnConfirm should be used together with preConfirm, see usage example:
https://sweetalert2.github.io/#ajax-request

@putianxin putianxin changed the title dcat版本从1.0更新到2.2.2后,所有弹窗表单中的动态按钮(如Export导出,Raw列 操作)都点不动了 dcat版本从1.0更新到2.2.3后,所有弹窗表单中的动态按钮(如Export导出,Raw列 操作)都点不动了 Sep 11, 2024
@PorygonCN
Copy link
Collaborator

2.0的modal在接收到成功后并不会自动关闭 需要使用 ->refresh()主动进行刷新页面来关闭

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

3 participants