I want to add a textfield and image field with validation in my form. I want to achieve this customly means without using any built in library. I am using yii2 advanced.
Any help will be appreciated.
This is a Demonstration on how to implement dynamic tabular forms.
Simple way to implement Dynamic Tabular Inputs
Related
I need to create split div functionality in reactjs. As shown in this fiddle. this one is implemented in extjs. I want similar implementation is reactjs. We need to add grids on either side of split panel. I am short of ideas on how to implement it. Not looking for code, but need ideas.
Hi you can check this package called react-split-pane. Also there you can find example for you case. Also there others examples.
I am looking for something p-autocomplete with result having checkboxes for every row and can allow multiple rows from the result.
Please guide me with the best possible solution or an idea with I can proceed.
Cheers!!
I would recommend using multiselect that have all the feature that you want to implement in auto-complete with a checkbox.
Writing custom functionality in a component that would be riskier than using that already built-in component that has these functionalities. This will help get less error-prone components. Writing custom checkboxes in autocomplete need lots of implementation apart from functional like accessibility, arrow keys actions, etc. So go with multi-select.
So for auto-complete in multi-select component use can use the filter property.
multiselect
How can I add a data grid in a view which has sortable columns and lookups too. Is there an inbuilt HTML feature I can use to implement this?
Any help is appreciated.
If you don't mind using jquery, I've had success using jqgrid. There is various tutorials for using it with asp.net mvc on the net.
Here is the link. see this example
http://www.trirand.com/blog/jqgrid/jqgrid.html
The Details template of MVC 3 returned a view use <fieldset> to display elements that represent all fields in one column. But I need to show elements or fields of a model in two or more columns. Is there any good template for this? what is your suggestion?
There's nothing specific about MVC here. This is just plain old html and css. I suggest getting a good book on HTML and CSS, and these sorts of things will be clear to you.
One of many many many ways you could do it:
http://www.gethifi.com/blog/html-forms-the-right-ways
One option you have is using editor templates for MVC, which allow you to take control of the how html rendering for a model is generated. Here's a blog post with an example
Using EditorTemplates in MVC 3
What you are looking for is modifying the Scaffolding Template that generated that view.
Or other option could be doing that manually, checking the best way to "display" each of your models.
For full control of your application, do you prefer a GridView or a HTML table?
And why?
For instance, I need to create on-the-fly hyperlinks-per-row in a GridView/HTML table. What object would be more easy to add that feature (or others like this one)?
Note: I'm creating programmatically my datasets
If you don't need the built in support for sorting or paging, and want more control over the rendered output then I would consider using a Repeater control to output a table. If you need the built in sorting/paging then the GridView can be very helpful.
If you want the best of both worlds, upgrade to ASP.net 3.5 and use the ListView.
EDIT: Can you clarify what you mean by 'on-the-fly hyperlinks-per-row'?
Stay away from the Gridview. It has to pull down the entire dataset to render the paging. It's much faster to render only the rows you need (e.g. rows 30 - 40 of 6,0000) and use a seperate pager control.
Also when it comes to HTML/CSS, using a repeater or listview will be much easier to debug, since you'll have total control over the code.
A plain HTML <table> generated by Response.Write is straightforward and has the added benefit that if you ever work on a non-Microsoft system, you won't feel naked without their redundant ASP.NET web controls that mostly just make it more difficult to generate the HTML everyone already knows.
I think the Repeater or the newer ListView is the way to go if you don't need sorting and/or paging. The Repeater and ListView allow you to control the HTML (the GridView is a total black box in this regard and generates atrocious HTML) while avoiding the tedious server-side code that comes with the <asp:Table> control: "OK, new row. New cell. Do something with cell. Add cell to row. Add row to table. Repeat".
On the other hand, if you need paging and sorting, the GridView is probably the better solution.
You can use GridView or more simple Repeater-like controls to build your own html, even if you have to sort/page you data.
With a Repeater for example you can build a custom system of pagination using a PagedDataSource data source with the property AllowPaging sets to true.
The only problem is clearly that with a simple Repeater you must write more code to do the work that GridView does natively.
But the result is faster.