Hello there,
i attached Photos so that you can see my problem ..
First i had the selection tag attached to my scheduler ..
So i had to click on the day and then click on the (...) Button to navigate to the correct day ..
if i click on a day and then click the (...) Button from another day .. it will navigate to the day i clicked on before clicking on the (...) Button ..
So i removed the selction tag (for now) ..
now i can't select .. so i go directly and click on the Button .. and as you can see on the Pics .. it's not going the right direction !!
PS : IT'S NAVIGATING TO THE ANOTHER DAY AT THE SAME MONTH !!!!!!
Hi,
As an expansion on my title, Im exporting a grid with some grouping to PDF, and the results make up 2 pages, but they are both being printed on the same page, please see the attachment so I dont sound crazy.
Here follows my template, pdf config and css styling:
<
script
id
=
"template-pdf-export"
type
=
"text/x-kendo-template"
>
<
div
class
=
"pdf-export"
>
<
div
class
=
"header"
>
<
div
style
=
"float: right"
>Page #: pageNum # of #: totalPages #</
div
>
Version Number x.y.z
</
div
>
<
div
class
=
"footer"
>
Page #: pageNum # of #: totalPages #
</
div
>
</
div
>
</
script
>
pdf: {
fileName:
"BFO-Export.pdf"
,
landscape:
true
,
margin: { top:
"2cm"
, right:
"1cm"
, bottom:
"1cm"
, left:
"1cm"
},
paperSize:
"A4"
,
// Required so that template and scale are used
scale: 0.8,
// Scale down the text size when printing to PDF
template: $(
"#template-pdf-export"
).html()
}
/* Basic styling for a PDF export template */
.pdf-export {
font-family
:
"DejaVu Sans"
,
"Arial"
,
sans-serif
;
position
:
absolute
;
width
:
100%
;
height
:
100%
;
top
:
0
;
left
:
0
;
}
.pdf-export .header {
position
:
absolute
;
top
:
30px
;
left
:
30px
;
right
:
30px
;
border-bottom
:
1px
solid
#888
;
color
:
#888
;
}
.pdf-export .footer {
position
:
absolute
;
bottom
:
30px
;
left
:
30px
;
right
:
30px
;
border-top
:
1px
solid
#888
;
text-align
:
center
;
color
:
#888
;
}
Please Advise.
Thanks,
Grant
Hello,
I'm trying to send selected values (from grid) but the creation is coming from the scheduler ..
I saved the values in a global variable and i tried to this ..
THIS is the ActionMethod in the Controller :
public
ActionResult Cal_Create ([DataSourceRequest]DataSourceRequest request, KommunikationViewModel kommunikation,
string
[] SIDMITARBEITER,
string
[] SIDPERSONEN, List<UserViewModel> MITARBEITER_OBJ)
{}
Create() method from my scheduler :
.Create(create => create.Action(
"Cal_Create"
,
"Home"
).Data(
"pass_Einladung_Miatarbeiter_Personen"
))
PS : i copy pasted only the create() so that i don't need to copy my whole scheduler !
This is the additional function that attached to the create() function :
function
pass_Einladung_Miatarbeiter_Personen() {
console.log(
"passing the array"
);
console.log(Global_Array_Grid_mitarbeiter_Selected);
var
Mitarbeiter_Grids_IDs =
new
Array();
var
Personen_Grids_IDs =
new
Array();
Global_Array_Grid_mitarbeiter_Selected.forEach(
function
(item, index) {
var
SID_MITARBEITER_AUS_GLOBAL = item.Sid_mitarbeiter;
Mitarbeiter_Grids_IDs.push(SID_MITARBEITER_AUS_GLOBAL);
});
Global_Array_Grid_person_Selected.forEach(
function
(item, index) {
var
SID_Personen_AUS_GLOBAL = item.Sid_personen;
Personen_Grids_IDs.push(SID_Personen_AUS_GLOBAL);
});
var
xxoop = JSON.stringify(Global_Array_Grid_mitarbeiter_Selected);
return
{
SIDMITARBEITER: Mitarbeiter_Grids_IDs,
SIDPERSONEN: Personen_Grids_IDs,
MITARBEITER_OBJ: xxoop}
}
// so i took one value from the object and put it into an array .. and that worked like a charm .. so defining a string[] as a parameter in the create ActionMethod .. did not make any problem .. but defining a List of object (like the code snippet) or a list of Objects .. is giving always NULL ! and it's not NULL because I'm console logging this variable in almost every step .. to follow if kendo delete the values after some action .. but no .. it's there .. but not getting sent to the ActionMethod ..
Thanks in Advance ..
Here is my data source:
var gridDataSource = new kendo.data.DataSource({
data: orderData,
schema: {
model: {
fields: {
Blank: { type: "string" },
ERevisionsUpdated: { type: "string" },
TIMOrderNumber: { type: "number" },
TBContractNumber: { type: "string" },
NccOrderNumber: { type: "string" },
AEName: { type: "string", },
OrderOriginalGross: { type: "number" },
ClientName: { type: "string" },
AgencyId: { type: "string" },
AgencyName: { type: "string" },
OrigMonthlyGross: { type: "number" },
TIMGross: { type: "number" },
TIMVariance: { type: "number" },
TIMWhole: { type: "string" },
TnBGross: { type: "number" },
TnBVariance: { type: "number" },
TnBWholePercent: { type: "number" },
Clearance: { type: "string" },
StartDate: { type: "date" },
EndDate: { type: "date" },
Market: { type: "string" },
LatestTimNote: { type: "string" },
TrafficSystemId: { type: "number" }
}
}
},
aggregate: [
{ field: "TnBGross", aggregate: "average" }
],
pageSize: 10,
sort: {
field: "TIMOrderNumber",
dir: "asc"
}
});
Here is the grid:
$("#ordersGrid").kendoGrid({
selectable: true,
allowCopy: true,
toolbar: ["excel", "pdf", "search"],
pdf: {
allPages: true
},
resizable: true,
//noRecords: {
// template: "No Records Found! Click search to query for records."
//},
excel: {
allPages: true
},
columnMenu: false,
columns: [
{ command: { text: "Dropped Spots", click: showDetails }, title: " ", width: "125px" },
{ command: { text: "SET", click: showDetails }, title: " ", width: "85px" },
{ field: "ERevisionsUpdated", title: "eRevision Status", width: "135px" },
{ field: "TIMOrderNumber", title: "TIM Order #", width: "114px", minResizableWidth: 100 },
{ field: "TrafficSystemId", title: "Traffic Id #", width: "100px", minResizableWidth: 80 },
{ field: "Revision", title: "Revision Info", width: "114px", minResizableWidth: 80 },
{ field: "TBContractNumber", title: "TB Contract #", width: "121px" },
{ field: "NccOrderNumber", title: "NCC Order #", width: "114px" },
{ field: "AEName", title: "AE Name", width: "150px" },
{ field: "ClientName", title: "Client Name", width: "275px", minResizableWidth: 150 },
{ field: "AgencyId", title: "Agency Id", width: "275px", minResizableWidth: 150 },
{ field: "AgencyName", title: "Agency Name", width: "275px", minResizableWidth: 150 },
{ field: "OrderOriginalGross", title: "Order Original Gross", format: "{0:c}", width: "154px" },
{ field: "OrigMonthlyGross", title: "Orig. Monthly Gross", format: "{0:c}", width: "150px" },
{ field: "TIMGross", title: "TIM Gross", format: "{0:c}", width: "120px" },
{ field: "TIMVariance", title: "TIM Variance", format: "{0:c}", width: "121px" },
{ field: "TIMWhole", title: "TIM Whole %", template: TIMWholeFunction, width: "115px" },
{ field: "TnBGross", title: "T&B Gross", format: "{0:c}", width: "100px", footerTemplate: "" },
{ field: "TnBVariance", title: "T&B Variance", format: "{0:c}", width: "115px" },//, aggregates: ["average"], footerTemplate: "Average: #=average#"},
{ field: "TnBWholePercent", title: "T&B Whole %", template: '#=kendo.format("{0:p}", TnBWholePercent / 100)#', width: "121px" },
{ field: "Clearance", title: "Clearance Rate %", width: "147px" }, //template: '#=kendo.format("{0:p}", Clearance / 100)#',
{ field: "StartDate", title: "Start", template: startDateFunction, width: "90px" },
{ field: "EndDate", title: "End", template: endDateFunction, width: "90px" },
{ field: "Market", title: "Market", width: "175px" },
{ field: "LatestTimNote", title: "Latest TIM Note", width: "800px" }
//{ field: "TrafficSystemId", hidden: true }
],
filterable: {
extra: false
},
sortable: true,
groupable: false,
pageable: {
pageSize: 10,
alwaysVisible: true,
buttonCount: 5,
refresh: false,
pageSizes: true
},
change: onGridChange,
dataSource: gridDataSource,
rowTemplate: '<tr class=\"#=GetRowColorValue(StartDate, EndDate)#\" data-uid="#= uid #"><td role="gridcell"> <a class="k-button" href=\"#=GetDroppedSpotsLink(TIMOrderNumber, TrafficSystemId)#\" target="_blank">Dropped Spots</a> </td><td role="gridcell"> <a class="k-button" href=\"#=GetSetLink(TBContractNumber, AreaId)#\" target="_blank">SET</a> </td><td role="gridcell" class=\"\"><img src=\"#:GetERevImage(ERevisionsUpdated)#" height=20 width=20></td><td role="gridcell"> <a href=\"#=GetTimOrderLink(TIMOrderNumber)#\" target="_blank">#:TIMOrderNumber#</a> </td><td role="gridcell"><a class="k-button" onclick="GetTrafficSystem(#=TrafficSystemId#)" target="_blank">#: TrafficSystemId #</a> </td><td role="gridcell" ><span class="\" onclick="GetRevisionInfo(#=TIMOrderNumber#)" target="_blank"><img src=\/Content\/images\/Exclamation.svg.png height=20 width=20></span></td><td role="gridcell">#: TBContractNumber #</td><td role="gridcell">#:NccOrderNumber#</td><td role="gridcell">#: AEName #</td><td role="gridcell">#: ClientName #</td><td role="gridcell">#: GetAgencyId(AgencyId) #</td><td role="gridcell">#: AgencyName #</td><td role="gridcell">#= GetOrderOriginalGross(OrderOriginalGross) #</td><td role="gridcell">#: GetOriginalMonthlyGross(OrigMonthlyGross) #</td><td role="gridcell">#: GetTIMGross(TIMGross) #</td><td role="gridcell">#: GetTIMVariance(TIMVariance) #</td><td role="gridcell" class=\"#=GetTimWholeColorValue(TIMWhole)#\" >#: GetTIMWhole(TIMWhole) #</td><td role="gridcell">#: GetTnBGross(TnBGross) #</td><td role="gridcell">#: GetTnBVariance(TnBVariance) #</td><td role="gridcell" class=\"#=GetTnBWholeColorValue(TnBWholePercent)#\">#: GetTnBWholePercent(TnBWholePercent) #</td><td role="gridcell">#:GetClearanceValue(Clearance)#</td><td role="gridcell">#=startDateFunction(StartDate) #</td><td role="gridcell">#=startDateFunction(EndDate) #</td><td>#: Market #</td><td role="gridcell"><a href=\"#=GetTimNoteLink(TimSystemId, TIMOrderNumber)#\" target="_blank">#: LatestTimNote #</a></td></tr>'
});
The field TnBGross has footerTemplate value = "". i.e. empty string. This works fine. However if you insert anything, even a space like " ", then grid breaks. What could be going wrong here?
Thank You!
Please help me to find what is wrong in here...
Hi,
I'm wondering if anyone could point me in the direction of an example to be able to select multiple scheduler events programatically if I have the data-uid for each event to be selected.
Also I am looking to be able to de-select a single event programatically when multiple are selected.
Thanks,
Francis
How to define different layout based on media queries? Autoflow to another row etc?
We want to implement something which is similar to the "EditForm" edit-mode in RadGrid for ASP.NET Ajax.
This looks promising: https://docs.telerik.com/kendo-ui/controls/scheduling/scheduler/how-to/editing/external-editor-form
However, we are in the situation where the grid's columns are created dynamically, based on configuration from a database.
Thus, we would have to implement the external editor form dynamically as well. Not impossible, of course, but I would rather avoid it :-)
The standard popup editor is, as far as I understand it, created dynamically, based on the columns of the grid. So, perhaps I could use the popup editor's template, but use it as an external form. Would that be possible (assuming you understand my question :-)
A follow-up question:
Once I have solved this (either by implementing it myself or re-using the popup editor), I would like to generate one external form per row in the grid.
In other words, if there are three rows in the grid, there would be three instances of external forms (stacked vertically). Is that possible? A sample for this, maybe based on this would be ideal! https://dojo.telerik.com/ITaciTAc
Thanks!
/Fredrik