Telerik Forums
UI for ASP.NET MVC Forum
3 answers
367 views

Hello,

We wish to be able to select/deselect the checkbox in the Checkbox selection column on click of the row as well as clicking the checkbox directly.

I can't seem to see any examples of this in your demos.

Thank you

Lucy

Konstantin Dikov
Telerik team
 answered on 04 Apr 2018
1 answer
137 views

I have a Grid, and I have it configured that if I double click a row, it opens an Edit Template.  Upon clicking Update, it would call into the MVC Action corresponding to the Update, and would process.  Today however, it is no longer working.  As far as I'm aware of the only change was to downgrade System.Web.Mvc from 5.2.4 to 5.2.3 because that's what the Kendo.Mvc required.

Using CDN version 2018.1.117.

Here is the code to the grid itself:

@(Html.Kendo().Grid<ClaimsImport>()
      .AutoBind(false)
      .Name("importGrid")
      .Resizable(r => r.Columns(true))
      .Scrollable(s => s.Height("auto"))
      .Sortable()
      .Pageable()
      .Filterable(f => f.Enabled(true))
      .Groupable()
      .Selectable()
      .Events(ev =>
      {
          ev.DataBound("gridBound");
      })
      .Columns(cols =>
      {
          // using a double click to select & edit record cuz I hate how the Telerik Grid buttons look...
          // cols.Command(c => c.Edit().Text(" "));
          cols.ForeignKey(f => f.ImportStatus, (IEnumerable) ViewData["importStatus"], "Value", "Text").Width(150);
          cols.ForeignKey(f => f.Disposition, (IEnumerable) ViewData["dispositions"], "Value", "Text").Width(150);
          cols.Bound(c => c.ClaimId);
          cols.ForeignKey(f => f.ClaimAdminId, (IEnumerable) ViewData["claimAdmins"], "ClaimAdminId", "ClaimAdminName").Width(200);
          cols.Bound(c => c.Carrier);
          cols.Bound(c => c.ClaimNumber);
          cols.Bound(c => c.ClaimantSSN);
          cols.Bound(c => c.ClaimantName);
          cols.Bound(c => c.ClaimStatus);
          cols.Bound(c => c.CloseDate).Format("{0:d}");
          cols.Bound(c => c.DateOfInjury).Format("{0:d}");
          cols.Bound(c => c.Processed).ClientTemplate("#: Processed ? 'Yes' : 'No' #");
      })
      .Editable(e => e.Mode(GridEditMode.PopUp).TemplateName("ClaimImport").Window(w => w.Title("Edit Import Disposition").Width(700)))
      .DataSource(ds => ds
          .Ajax()
          .PageSize(100)
          .ServerOperation(true)
          .Read(r => r.Action("GetImportData", "Claims").Data("addLabelToRead").Type(HttpVerbs.Get))
          .Update(u => u.Action("SaveImportRecord", "Claims").Type(HttpVerbs.Post))
          .Events(ev =>
          {
              ev.RequestEnd("requestEnd");
              ev.RequestStart("requestStart");
              ev.Error("errorHandler");
          })
          .Model(m =>
          {
              m.Id(d => d.ID);
              m.Field(d => d.Disposition);
              m.Field(d => d.ClaimAdminId);
          })
      )
      .ToolBar(tb =>
      {
          tb.Custom().Text("Clear Filter").HtmlAttributes(new {id = "gridFilterReset", style = "float:right;"});
          tb.Custom().Text("Re-Run Claim Match").HtmlAttributes(new { id = "reRunClaimMatch", style = "float:left;" });
          tb.Custom().Text("Update Claim Financials").HtmlAttributes(new { id = "updateClaimFinancials", style = "float:left;" });
      }))

 

Here's the appropriate MVC Action:

public ActionResult SaveImportRecord([DataSourceRequest] DataSourceRequest request, ClaimsImport editedRec)
       {
           ClaimsImport thisRec = WebApiHelper.CallPostAPI<ClaimsImport, ClaimsImport>($"{_baseURL}{_monthEndPath}SaveImportRecord", editedRec);
           return Json(new[] {thisRec}.ToDataSourceResult(request));
       }

 

I have put a break point in the MVC action, and it never gets called.  Never.  I've tried adding an extra javascript function call via the Updates .Data() method, and even it does not get called.  I really need some help with this.

As I said, everything was fine up until today.  Any idea whatsoever about what might be happening.

Joe
Top achievements
Rank 1
 answered on 03 Apr 2018
3 answers
313 views

Hi,

I'm using Bootstraps Tab component with two Tabs: Overview and Under 10K. There is 1 Grid on each Tab. Both load correctly but the one on the non-visible Tab doesn't get rendered correctly, attached a screenshot.

When i resize the view or open debugging tools it then displays correctly, so is there a way i can trigger "re-draw" or "re-size" event?

Thanks,
Lee.

Preslav
Telerik team
 answered on 03 Apr 2018
3 answers
137 views

Hi, 

I'm trying to make scheduler in which you could remove group like in example(https://demos.telerik.com/aspnet-mvc/scheduler) also remove that group name from calendar view, i'm doing it by filtering the datasource of resource.

But then i need to use scheduler.view(scheduler.viewName()) to repaint calendar and it makes post to get information to server. I would like to remove this unnecessary request, because i'm getting data via filter button and on scheduler navigate.

Is there any way to remove unnecessary request.

I'm attaching the modified view file from example package.

 

Veselin Tsvetanov
Telerik team
 answered on 03 Apr 2018
2 answers
604 views

Hello,

Why this error is appears every time when I run the program?
Error: “An element with the same key has already been added”
I have two grids on the page. IDs GRIDs is different.

Thanks.

Olexandr
Top achievements
Rank 1
 answered on 02 Apr 2018
8 answers
793 views
Hello,

I'm planning to use Editor in my ASP.NET MVC application to edit and print some HTML content that I store in database. But, as I could see in THIS demo Editor does not contain tools (buttons) such as Save and Print. I've used your ASP.NET Ajax editor in my previous ASP.NET Web Forms applications to achieve same functionality and that editor had this buttons.

My question is, how can I save changes and print ONLY the content of Editor in ASP.NET MVC? Any example?
Paul
Top achievements
Rank 1
 answered on 30 Mar 2018
2 answers
671 views
I've just upgraded my ASP.NET MVC project from Bootstrap 3 to 4. I also updated to the latest Telerik UI for ASP.NET MVC version 2018.1.221. Now I'm just trying to figure out which files need to be included in my bundles to make it work. There was a nice walk-through on the documentation site on setting up bundles for with Bootstrap 3 but I can't find anything equivalent for Bootstrap 4. What needs to be included?
Jesse
Top achievements
Rank 1
Veteran
 answered on 30 Mar 2018
1 answer
236 views

Hi Telerik Team,

Currently I setup my mvc pivot grid as follow:

 

@(Html.Kendo().PivotConfigurator()
                        .Name("configurator")
                        .HtmlAttributes(new { @class = "hidden-on-narrow" })
                        .Filterable(true)
                        .Sortable()
                        .Height(580)
            )

@(Html.Kendo().PivotGrid<EmployeeTurnOverDto>
    ()
    .Name("pivotgrid")
    .HtmlAttributes(new { @class = "hidden-on-narrow" })
    .Filterable(true)
    .Sortable()
    .Configurator("#configurator")
    .ColumnWidth(120)
    .Height(580)
    .BindTo(Model)
    .DataSource(dataSource => dataSource
    .Ajax()
    .Schema(schema => schema
    .Cube(cube => cube
    .Dimensions(dimensions =>
    {
    dimensions.Add(model => model.FullName).Caption(L("Staffs"));
    dimensions.Add(model => model.Institution).Caption(L("Institution"));
    dimensions.Add(model => model.Department).Caption(L("Department"));
    dimensions.Add(model => model.TurnOverDate).Caption(L("TurnOverDate"));
    })
    .Measures(measures =>
    {
    measures.Add("In").Field(model => model.JoinFlag).AggregateName("sum").Caption(L("In"));
    measures.Add("Out").Field(model => model.ResignFlag).AggregateName("sum").Caption(L("Out"));
    })
    )
    )
    .Columns(columns =>
    {
    columns.Add("TurnOverDate").Expand(true);
    })
    .Rows(rows => rows.Add("Denomination").Expand(true))
    .Measures(measures => measures.Values("In"))
    .Events(e => e.Error("onError"))
    )
    )

 

Could you advise how to add the Year and/or Month (in MMM format) component of the TurnOverDate in the Column fields?

 

Note that I am not using cube, but using a flat data.

 

Thank you.

 

Regards,

Hage

 

Alex Hajigeorgieva
Telerik team
 answered on 28 Mar 2018
1 answer
725 views

Hi,

I have a grid which has a column bound to a boolean value indicating if the record is a priority or not.

I wan't to be able to sort the grid so that records with priority set to true to be at the top.

I cannot find any way to do this in the docs, is it possible? I notice that even the default sorting does not work (by clicking the header) so trying to set a sort order on the DataSource model is just failing on page load.

This is the child grid in a hierarchical situation if that makes any difference...

 

.Sort(s =>
{
s.Add(m => m.Priority).Ascending();
s.Add(m => m.Start).Descending();
}))
 
columns.Bound(m => m.Priority).Filterable(false).ClientTemplate("\\#= Priority ? '" + Resources.BUTTON_YES + "' : '" + Resources.BUTTON_NO + "' \\#")
Stefan
Telerik team
 answered on 28 Mar 2018
2 answers
857 views

Hi,

 

I'm having an issue with columns widths on Internet Explorer.

 

This occurred when upgrading from 2017.1.223 to 2018.1.221.

 

Changing the widths of columns on the razor code doesn't change anything in IE. If I render the page, then try to change the width by dragging the header cell, the columns align, but still don't take up the full width, like normal. I have attached a screenshot of the columns aligned after messing with them is called after-align.png

 

I have attached screenshots of the grid in both Chrome and IE too. Again, the grid works in Chrome, but doesn't work in IE. Let me know if you need any more information!

 

Thanks,

Jessica

Viktor Tachev
Telerik team
 answered on 27 Mar 2018
Narrow your results
Selected tags
Tags
Grid
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
ComboBox
Upload
MultiSelect
ListView
Window
TabStrip
Menu
Installer and VS Extensions
Spreadsheet
AutoComplete
TreeList
Gantt
PanelBar
NumericTextBox
Filter
ToolTip
Map
Diagram
Button
PivotGrid
Form
ListBox
Splitter
Application
FileManager
Sortable
Calendar
View
MaskedTextBox
PDFViewer
TextBox
Toolbar
Dialog
MultiColumnComboBox
DropDownTree
Checkbox
Slider
Switch
Notification
Accessibility
ListView (Mobile)
Pager
Security
ColorPicker
DateRangePicker
Wizard
Styling
Chat
DateInput
MediaPlayer
TileLayout
Drawer
SplitView
Template
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Licensing
Rating
ScrollView
ButtonGroup
CheckBoxGroup
NavBar
ProgressBar
QRCode
RadioButton
Scroller
Timeline
TreeMap
TaskBoard
OrgChart
Captcha
ActionSheet
Signature
DateTimePicker
AppBar
BottomNavigation
Card
FloatingActionButton
Localization
MultiViewCalendar
PopOver (Mobile)
Ripple
ScrollView (Mobile)
Switch (Mobile)
PivotGridV2
FlatColorPicker
ColorPalette
DropDownButton
AIPrompt
PropertyGrid
ActionSheet (Mobile)
BulletGraph
Button (Mobile)
Collapsible
Loader
CircularGauge
SkeletonContainer
Popover
HeatMap
Avatar
ColorGradient
CircularProgressBar
SplitButton
StackLayout
TimeDurationPicker
Chip
ChipList
DockManager
ToggleButton
Sankey
OTPInput
ChartWizard
SpeechToTextButton
InlineAIPrompt
TimePicker
StockChart
RadialGauge
ContextMenu
ArcGauge
AICodingAssistant
SmartPasteButton
PromptBox
SegmentedControl
LLM Kit
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?