naive-ui icon indicating copy to clipboard operation
naive-ui copied to clipboard

Datatable Filter element in children

Open OlivierLB opened this issue 3 years ago • 3 comments
trafficstars

TuSimple/naive-ui version (版本)

2.31.0

Vue version (Vue 版本)

3.2.37

Browser and its version (浏览器及其版本)

Firefox(102.0)

System and its version (系统及其版本)

Windows10

Node version (Node 版本)

Reappearance link (重现链接)

https://codesandbox.io/s/mystifying-monad-0u29kk?file=/src/Demo.vue

Reappearance steps (重现步骤)

In the datatable, filter by percent and it doesnt work

Expected results (期望的结果)

Filter data

Actual results (实际的结果)

Return empty array

Remarks (补充说明)

OlivierLB avatar Jul 08 '22 13:07 OlivierLB

I'm curious what you guys think about the correct behavior here.

  1. All parents, i.e., the direct parent, the grandparent, etc., should be kept no matter whether their values satisfy the filter or not
  2. Like the above one, but only the direct parent should be kept
  3. Only the satisfied child should be kept

equt avatar Aug 18 '22 06:08 equt

When i have create the ticket, i imagine the solution 3

OlivierLB avatar Aug 18 '22 07:08 OlivierLB

I'm curious what you guys think about the correct behavior here.

  1. All parents, i.e., the direct parent, the grandparent, etc., should be kept no matter whether their values satisfy the filter or not
  2. Like the above one, but only the direct parent should be kept
  3. Only the satisfied child should be kept

I think we should provide different modes. Keep current behavior & filter children in mode 3. This would not be easy to implement.

07akioni avatar Aug 18 '22 15:08 07akioni

This issue does not have any recent activity. If you are still experiencing similar problems, open a new error, including a minimal copy of the problem

jahnli avatar Mar 12 '24 13:03 jahnli