Rails, one model, many screens

I have a model with many fields (about 40). The client wants the fields to be shared between multiple screens. The model also has several has_manys that should look like they are part of the same model.

How can a model be divided and what are the trade-offs between its methods?

I see a couple of possibilities:

1) Use JavaScript to show and hide parts of the form. I think I can do this job.

2) Use forms that represent different actions. Can form_ be used with the appropriate parameters?

I am also looking for other ideas.

+3
source share
2 answers

. -.

, , Javascript , . jQuery UI, , , , .

+2
+1

Source: https://habr.com/ru/post/1708232/


All Articles