Help with _hc based on filter selected #392
-
Hi I'm wondering if it's possible to hide a column based on the filter selected. In our case I'd like to hide the "Mark As" column only if the "Completed" filter has been clicked. This is so that staff can't mark an already completed job as completed again. Dean |
Beta Was this translation helpful? Give feedback.
Replies: 7 comments 1 reply
-
Hi Dean,
This isn't currently possible with KTL, to hide a column based on a filter
(as far as I'm aware). You could however harness the ktl function
hideTableColumn and unhideTableColumn, which could be triggered on the
click event of the filter buttons.
Amanda
…On Tue, 8 Oct 2024 at 22:16, Deanobeano2 ***@***.***> wrote:
Hi
I'm wondering if it's possible to hide a column based on the filter
selected.
In our case I'd like to hide the "Mark As" column only if the "Completed"
filter has been clicked. This is so that staff can't mark an already
completed job as completed again.
image.png (view on web)
<https://github.com/user-attachments/assets/5be784fa-c045-4cdf-99f4-2fe5fb940f9c>
Dean
—
Reply to this email directly, view it on GitHub
<#392>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/ATAWKK54BBWTQP34NC5NEZLZ2RDSRAVCNFSM6AAAAABPTEMUGCVHI2DSMVQWIX3LMV43ERDJONRXK43TNFXW4OZXGI4TEMRYGE>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Hi Amanda Is this a new keyword, as I don't see it in the Keywords page? Dean |
Beta Was this translation helpful? Give feedback.
-
Hey Dean,
It’s not a keyword but a function in the ktl that you can call from your
code. It’s the function used by the _hc keyword.
Let me if need any guidance.
Amanda
…On Wed, 9 Oct 2024 at 21:29, Deanobeano2 ***@***.***> wrote:
Hi Amanda
Is this a new keyword, as I don't see it in the Keywords page?
Dean
—
Reply to this email directly, view it on GitHub
<#392 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ATAWKK735TV3SXHKPJY3YZLZ2WG2DAVCNFSM6AAAAABPTEMUGCVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTAOBZGY4TCMQ>
.
You are receiving this because you commented.Message ID:
<cortexrd/Knack-Toolkit-Library/repo-discussions/392/comments/10896912@
github.com>
|
Beta Was this translation helpful? Give feedback.
-
Hi Amanda I think I'll need guidance with this, if you would be so kind. Dean |
Beta Was this translation helpful? Give feedback.
-
Dean, Wouldn't is be simpler to add a display rule to the Mark As action column to hide the action when its Job state value is Completed? If you can't do it in the Builder, maybe it's because Job state is a connected field? Then you can certainly use the _cfv keyword with the hide option. |
Beta Was this translation helpful? Give feedback.
-
Norm Thank you. That worked and sorry for over-looking the obvious. Dean |
Beta Was this translation helpful? Give feedback.
-
@Deanobeano2 |
Beta Was this translation helpful? Give feedback.
@Deanobeano2
Glad it worked out.
Don't forget to set as Answered!