Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Lightswitch using editable Grid which uses View as data source

I am trying to develop a screen in Light-Switch, in which data shown is combined from 3 or 4 tables. But the Controls becomes read only for this view.

I don't know how can I achieve this type of functionality in Light-Switch.

Is is possible the make totally custom editable Grid which has custom Save method to save the edited values in related tables?

Note: When I work on single table it works fine.

Edit:

To simulate the issue, just create a view that returns the rows from 3/4 tables by using Union, for e.g.:

Select Col1, Col2 Col3 from Table1 where Active=1
UNION
Select Col1, Col2 Col3 from Table2 where Date>GetDate()
UNION
Select Name as Col1, Col2 Col3 from Table3

Now pass this view to LightSwitch to be edited in grid.

Thanks

like image 603
user1400290 Avatar asked Nov 29 '25 13:11

user1400290


1 Answers

I was following the following article:

Using WCF RIA Service in LightSwitch

But had problems making Grid Editable.

After looking for the solution around the net. I found the following URL that solved my issue:

https://stackoverflow.com/a/21208573/1400290

like image 95
user1400290 Avatar answered Dec 01 '25 03:12

user1400290