You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Per Newgro <pe...@gmx.ch> on 2014/06/18 09:32:04 UTC
Exclude link from disabled hierarchy
Hi,
I enable a Form by autorized role. Some users see the form enabled, some disabled. All works fine.
My problem is that i've added a goback-link which should be enabled always for all users. But because the
link is added to the form (within a button panel) it get's disabled to.
Is there a smart way to exclude the goback link form "enabledInHierarchy" processing?
Thanks for your support
Per
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Re: Exclude link from disabled hierarchy
Posted by Martin Grigorov <mg...@apache.org>.
Even simpler!
Martin Grigorov
Wicket Training and Consulting
On Wed, Jun 18, 2014 at 10:55 AM, Per Newgro <pe...@gmx.ch> wrote:
> Thanks for your respose Martin.
>
> I maybe found another solution meanwhile. There is a method in AbstractLink
>
>
> @Override
> protected boolean isLinkEnabled() {
> return isEnabledInHierarchy();
> }
>
> I've overwritten this by
>
> @Override
> protected boolean isLinkEnabled() {
> return true;
> }
>
> Now it seems to work as expected.
>
> Thanks for your support
> Per
>
> > Gesendet: Mittwoch, 18. Juni 2014 um 09:49 Uhr
> > Von: "Martin Grigorov" <mg...@apache.org>
> > An: "users@wicket.apache.org" <us...@wicket.apache.org>
> > Betreff: Re: Exclude link from disabled hierarchy
> >
> > Hi,
> >
> > I believe there is a ticket for such requirement but JIRA is too slow
> today
> > and I cannot find it.
> > In general this is not possible.
> > But it is possible for links - override
> > org.apache.wicket.markup.html.link.AbstractLink#disableLink() for this
> > special link.
> >
> > Martin Grigorov
> > Wicket Training and Consulting
> >
> >
> > On Wed, Jun 18, 2014 at 10:32 AM, Per Newgro <pe...@gmx.ch> wrote:
> >
> > > Hi,
> > >
> > > I enable a Form by autorized role. Some users see the form enabled,
> some
> > > disabled. All works fine.
> > >
> > > My problem is that i've added a goback-link which should be enabled
> always
> > > for all users. But because the
> > > link is added to the form (within a button panel) it get's disabled to.
> > >
> > > Is there a smart way to exclude the goback link form
> "enabledInHierarchy"
> > > processing?
> > >
> > > Thanks for your support
> > > Per
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > > For additional commands, e-mail: users-help@wicket.apache.org
> > >
> > >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
Aw: Re: Exclude link from disabled hierarchy
Posted by Per Newgro <pe...@gmx.ch>.
Thanks for your respose Martin.
I maybe found another solution meanwhile. There is a method in AbstractLink
@Override
protected boolean isLinkEnabled() {
return isEnabledInHierarchy();
}
I've overwritten this by
@Override
protected boolean isLinkEnabled() {
return true;
}
Now it seems to work as expected.
Thanks for your support
Per
> Gesendet: Mittwoch, 18. Juni 2014 um 09:49 Uhr
> Von: "Martin Grigorov" <mg...@apache.org>
> An: "users@wicket.apache.org" <us...@wicket.apache.org>
> Betreff: Re: Exclude link from disabled hierarchy
>
> Hi,
>
> I believe there is a ticket for such requirement but JIRA is too slow today
> and I cannot find it.
> In general this is not possible.
> But it is possible for links - override
> org.apache.wicket.markup.html.link.AbstractLink#disableLink() for this
> special link.
>
> Martin Grigorov
> Wicket Training and Consulting
>
>
> On Wed, Jun 18, 2014 at 10:32 AM, Per Newgro <pe...@gmx.ch> wrote:
>
> > Hi,
> >
> > I enable a Form by autorized role. Some users see the form enabled, some
> > disabled. All works fine.
> >
> > My problem is that i've added a goback-link which should be enabled always
> > for all users. But because the
> > link is added to the form (within a button panel) it get's disabled to.
> >
> > Is there a smart way to exclude the goback link form "enabledInHierarchy"
> > processing?
> >
> > Thanks for your support
> > Per
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > For additional commands, e-mail: users-help@wicket.apache.org
> >
> >
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Exclude link from disabled hierarchy
Posted by Martin Grigorov <mg...@apache.org>.
Hi,
I believe there is a ticket for such requirement but JIRA is too slow today
and I cannot find it.
In general this is not possible.
But it is possible for links - override
org.apache.wicket.markup.html.link.AbstractLink#disableLink() for this
special link.
Martin Grigorov
Wicket Training and Consulting
On Wed, Jun 18, 2014 at 10:32 AM, Per Newgro <pe...@gmx.ch> wrote:
> Hi,
>
> I enable a Form by autorized role. Some users see the form enabled, some
> disabled. All works fine.
>
> My problem is that i've added a goback-link which should be enabled always
> for all users. But because the
> link is added to the form (within a button panel) it get's disabled to.
>
> Is there a smart way to exclude the goback link form "enabledInHierarchy"
> processing?
>
> Thanks for your support
> Per
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>