This is a migrated thread and some comments may be shown as answers.

Loading fails

2 Answers 81 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
Greg
Top achievements
Rank 1
Greg asked on 06 Jun 2013, 05:41 PM
I have partial views under 7 tabs. first 1-2 tabs loads the content but after that it throws "loading failded" error. Please help.

Here is my code:

@(Html.Kendo().TabStrip()
.Name("tabstrip")
.Events(events => events
//.Select("onSelect")
//.Activate("onActivate")
.ContentLoad("onContentLoad")
.Error("onError")
)

.Items(tabstrip =>
{
tabstrip.Add().Text("Specifics")
.Selected(true)
.LoadContentFrom("SelectSpecifics", "Citation", new { id = @Model.CitationID, docType = @Model.DocType });

tabstrip.Add().Text("Authors")
.LoadContentFrom("Authors", "CitationAuthors", new { id = @Model.CitationID });

tabstrip.Add().Text("Abstract")
.LoadContentFrom("Abstract", "CitationAbstract", new { id = @Model.CitationID });

tabstrip.Add().Text("Notes")
.LoadContentFrom("Notes", "CitationNotes", new { id = @Model.CitationID });


tabstrip.Add().Text("Descriptors")
.LoadContentFrom("Descriptors", "CitationDescriptors", new { id = @Model.CitationID });


tabstrip.Add().Text("Groups")
.LoadContentFrom("Groups", "CitationGroups", new { id = @Model.CitationID });

tabstrip.Add().Text("DeletionHistory")
.LoadContentFrom("DeletionHistory", "CitationHistory", new { id = @Model.CitationID });

tabstrip.Add().Text("RetrievalHistory")
.LoadContentFrom("RetrievalHistory", "CitationHistory", new { id = @Model.CitationID });

tabstrip.Add().Text("Accession No.")
.LoadContentFrom("AccessionNumber", "CitationHistory", new { id = @Model.CitationID });


tabstrip.Add().Text("CopyRequest")
.LoadContentFrom("CopyRequest", "CopyRequest", new { id = @Model.CitationID });


tabstrip.Add().Text("Events")
.LoadContentFrom("Events", "CitationEvents", new { id = @Model.CitationID });

tabstrip.Add().Text("ClearingHouse")
.LoadContentFrom("ClearingHouse", "CitationClearingHouse", new { id = @Model.CitationID });
})
)

</div>

<p>
<input type="submit" id="btnSubmit" value="Submit" name="submit" />
<input type="submit" id="btnCancel" value="Cancel" name="cancel" />

</p>
}

<script>
function onSelect(e) {
//kendoConsole.log("Selected: " + $(e.item).find("> .k-link").text());
alert("Activate fired");

}

function onActivate(e) {
//kendoConsole.log("Activated: " + $(e.item).find("> .k-link").text());
alert("Activate fired");

}

function onContentLoad(e) {
//kendoConsole.log("Content loaded in <b>"+ $(e.item).find("> .k-link").text() + "</b> and starts with <b>" + $(e.contentElement).text().substr(0, 20) + "...</b>");
//alert("Activate fired");


}

function onError(e) {
//kendoConsole.error("Loading failed with " + e.xhr.statusText + " " + e.xhr.status);
alert("error fired");
}
 
Thanks
Vandana

2 Answers, 1 is accepted

Sort by
0
Greg
Top achievements
Rank 1
answered on 07 Jun 2013, 02:15 PM
Can someone answer this post please? I am stuck with this issue.

Thanks
V
0
Petur Subev
Telerik team
answered on 10 Jun 2013, 12:15 PM
Hello Greg,

We see not reason why the loading should fail, basically if two tabs load without issues rest should load fine too.

Make sure that the content of these two tabs do not load the jQuery library multiple times - this would cause the TabStrip to stop working. 

If the problem exist even when the content is just simple strings, we will need a sample project which demonstrates the case.

Kind Regards,
Petur Subev
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
TabStrip
Asked by
Greg
Top achievements
Rank 1
Answers by
Greg
Top achievements
Rank 1
Petur Subev
Telerik team
Share this question
or