When I test, $ root is throwing an unwanted reference error These files are included, let me know if you have more information Is required but I can not honestly see what I am doing.
Do I need to do anything that is available for me $ Root? Is this exclusive for mobile apps only?
show.js
VelocityMeetings.shows = function (parameter) {var errorMessage = ko.observable (""); Var viewModel = {errorMessage: errorMessage, errorVisible: ko.computed (function () {return errorMessage (). Length! = 0;}), hideError: function () {errorMessage (""); }, ResultsItemClick: function () {warning ('OK')}}; Return visual model; };
show.dxview
& lt; Div data-option = "dxView: {name: 'show', title: 'trade show'}" & gt; & Lt; Div style = "font-size: 11px;" Class = "show-view" data-option = "dxContent: {targetPlaceholder: 'content'}" & gt; & Lt; Br / & gt; & Lt; Img src = "picture / logo.jpg" /> & Lt; Div style = "color: red; margin: 5px; font-size: 12px;" Data-bound = "visible: error view, text: error message" & gt; & Lt; / Div & gt; & Lt; Br / & gt; & Lt; Div style = "font-size: 14px; color: RGB (98, 31, 137); font-weight: bold;" & Gt; My shows & lt; / Div & gt; & Lt; Br / & gt; & Lt; Div data-bind = "dxList: {dataSource: Shows}" & gt; & Lt; Div data-option = "dxTemplate: {name: 'item'}, dxAction: $ root.resultsClick" style = "style =" border: 1px solid light; Padding: 15px; Art color; Width: 200px; Margins: Auto; "& Gt; IMG Data-Bind =" Entry: {src: image} "/>
& lt; Span Data-Bind =" Text: Date " & Gt; & lt; / span & gt; & lt; / b & gt; & lt; b & gt; & lt; span data-bound = "text: location" & gt; & lt; / span & gt; / div>
I was mixing up data-options and data-bound features.
& lt ; Div data-option = "dxTemplate: {name: 'item'}" data-bound = "dxAction: $ root.resultsItemClick" style = "border: 1px solid light; Padding: 15px; Art color; Width: 200px; Margins: Auto; "
If anyone is struggling, then what should be the template line.
Comments
Post a Comment