43 lines
1.7 KiB
JavaScript
43 lines
1.7 KiB
JavaScript
define(['jquery', 'underscore', 'backbone','text!modules/more/moreViewTemplate.html', 'modules/base/baseView'],
|
|
function($, _, Backbone, moreViewTemplate, BaseView){
|
|
|
|
var MoreView = BaseView.extend({
|
|
|
|
collection: null,
|
|
//initialize template
|
|
template:_.template(moreViewTemplate),
|
|
|
|
initialize: function (options) {
|
|
var self = this;
|
|
MoreView.__super__.initialize.call(this);
|
|
//this.header.title = "pippo";
|
|
},
|
|
|
|
events:{
|
|
"click #converterLnk": "converterLnkClick"
|
|
},
|
|
|
|
converterLnkClick:function()
|
|
{
|
|
window.location.href = "http://www.pastamadre.eu/webapps/conversione_lieviti/index.php";
|
|
},
|
|
|
|
//render the content into div of view
|
|
render: function(){
|
|
//this.header.title = "pippo";
|
|
MoreView.__super__.render.call(this);
|
|
//this.el is the root element of Backbone.View. By default, it is a div.
|
|
//$el is cached jQuery object for the view's element.
|
|
//append the compiled template into view div container
|
|
this.$el.append(this.header.$el);
|
|
this.$el.append(this.template());
|
|
this.$el.append(this.footer.$el);
|
|
|
|
this.$el.find("#moreBtn").addClass("ui-btn-active");
|
|
//$("#homeBtn").addClass("ui-btn-active");
|
|
//return to enable chained calls
|
|
return this;
|
|
}
|
|
});
|
|
return MoreView;
|
|
}); |