Debian Codegraph @

dojox/mvc/tests/test_templatedWidgetList/myMvcTemplated.js

raw symbols SCIP
1 define([
2 "dojo/_base/declare",
3 "dojox/mvc/Templated",
4 "dijit/registry",
5 "dojo/text!./test_mvc_widget_template.html",
6 "dojox/mvc/at",
7 "dijit/form/TextBox",
8 "dojox/mvc/Group",
9 "dojox/mvc/Output",
10 "dojox/mvc/Repeat"
11 ], function(declare, Templated, registry, template, at){
12 return dojo.declare("dojox.mvc.tests.test_templatedWidgetList.myMvcTemplated", [Templated], {
13 // summary:
14 // A sample templated widget for dojox.mvc
15 // description:
16 // This template is used to show how to use exprchar to avoid instance of _TemplatedMixin error in dojo.mvc data binding.
17 // If the templateString contains ${xxx}, it will throw an template error, use #{xxx} with exprchar :"#" instead.
18 // See how it works in test_mvc_widget.html and test_mvc_widget_template.html
19
20 // ctrl: dojox.mvc.ModelRefController
21 // The controller that the form widgets in the template refer to.
22 ctrl: null,
23
24 templateString: template,
25
26 startup: function(){
27 console.log("startup called in myMvcTemplated!!! ");
28 this.labelNode.set("value", at("rel:", "Serial"));
29 this.inputNode.set("value", at("rel:", "First"));
30 // this.nameInputNode.set("value", at("rel:", "First"));
31 this.inherited("startup", arguments);
32 },
33
34 buildRendering: function(){
35 console.log("call myMvcTemplated buildRendering");
36 window.at = at;
37 this.inherited(arguments);
38 },
39
40 getParent: function(){
41 console.log("Call myMvcTemplated getParent");
42 return null;
43 }
44 });
45 });