Fork me on GitHub

...if that's even possible.


Possible and intended. Details are in other thread. RAD lets you either define your own elements of rendering (i.e. layout) where the built-in inputs are used, or completely take over rendering (in which case you need to understand Fulcro form-state).

Jakub Holý (HolyJak)15:06:32

In RAD reports, how can I make input controls that are not displayed in the UI so that they can only be supplied via route parameters but not edited by the user? Previously I simply defined them in ro/controls and did not mention them in ro/control-layout but now I am getting a warning about that. Is the only solution to define custom :style or :type(something like :hidden ) and register a custom rendering component such as (constantly nil) in all-controls - :com.fulcrologic.rad.control/type->style->control ?


one thing you could do is ignore the warning 😉

😂 4

jokes aside, what you're doing is what i thought you were supposed to do as well


and ignoring warnings is not the best solution

Jakub Holý (HolyJak)16:06:40

it worked for a while, with an older RAD


perhaps we should add an invisible flag to controls?

Jakub Holý (HolyJak)16:06:11

that is an option. But there are surely other possible, perhaps even better solutions? I liked the simplicity of just excluding it from :inputs ...


oh i see, sounds like there shouldn't be a warning if and only if a control is missing from the layout and is marked invisible


the warning is useful for people that want the control on the screen and cant figure out why it's not there

Jakub Holý (HolyJak)16:06:09

Perhaps :hidden? is better as it is used eg in CSS?


controls have a visibility lambda….and you can ignore the warning…it is just there to keep ppl from complaining to me that their control didn’t show up


so, either way

❤️ 4
Jakub Holý (HolyJak)15:06:09

Can I create a dynamic routing target that loads its data in :componentDidMount and has a dynamic ident (such as :person/id )? I want to avoid deferred routing because it might be causing problems. But when I do this, dyn. routing fails with will-enter for router target Person did not return a valid ident. Instead it returned: [:person/id nil] I guess I am stuck? (I have just executed (routing/route-to! app Person {:person/id "123"}) )


IF you have a route parameter for a dynamic router, then you MUST either pre-load the entity in question (before routing), or at least fix the UI graph so that the ident in question is available (i.e. (merge-component! … Person {:person/id id})), otherwise there is nothing to point to

👍 4

You must use deferred routing and load it in the lambda of deferred


If you’re using RAD, it should be handling that for you


BUT, you don’t want route-to, you want form/edit! (if it is a form)


If you’re trying to route to the display of a person, you’re also probably better off just defining it as a RAD form, and just take over the rendering (and not save it)


or study the RAD form code and state machine and understand how to manage data lifecycles.

Jakub Holý (HolyJak)17:06:56

Well, I am still troubleshooting my empty report problem and you mentioned there can be a problem with nested deferred routers so I tried to bypass it by making the middle router not using deferring.

Adrian Smith18:06:35

Inside a defsc component, we're given this and props what is this ?

Jakub Holý (HolyJak)19:06:41

As @U08E8UGF7 says. You can use it in many functions such as df/load!, comp/props etc


it’s self-reference for the instance of the defsc stateful-component


Are there any examples of how you would this compared to props in defsc?


There are plenty in the book and videos (see channel topic)