* Relevé de notes
* @author onic
*/
-eliot.notes.saisie.appreciations.Application = function() {
+eliot.notes.saisie.appreciations.Application = function () {
/**
* Définit la classe qui sera instanciée comme singleton
*/
var Clazz = Ext.extend(Ext.util.Observable, {
- constructor: function() {
+ constructor:function () {
this.ns = eliot.notes.saisie.appreciations;
this.ConfigServeur = this.ns.ConfigServeur;
this.eleveModel = new this.ns.EleveModel();
this.eleveController = new this.ns.EleveController(this.eleveModel);
this.eleveView = new this.ns.EleveView(
- this.eleveController.storeEleve,
+ this.eleveController.storeEleve,
this.eleveModel
- );
+ );
this.eleveController.observeView(this.eleveView);
- this.eleveView.observeController(this.eleveController);
+ this.eleveView.observeController(this.eleveController);
// Toolbar
this.toolbarView = new this.ns.ToolbarView(this.eleveModel);
// Saisie des appréciations
this.appreciationsController = new this.ns.AppreciationsController({
- eleveModel: this.eleveModel,
- banqueAppreciation: this.banqueAppreciation,
- graph: this.graph
+ eleveModel:this.eleveModel,
+ banqueAppreciation:this.banqueAppreciation,
+ graph:this.graph
});
this.appreciationsView = new this.ns.AppreciationsView({
- storeSaisie: this.appreciationsController.storeSaisie,
- storeAppreciation: this.appreciationsController.storeAppreciation,
- banqueAppreciation: this.banqueAppreciation,
- storeDetailsNotes: this.appreciationsController.storeDetailsNotes
+ storeSaisie:this.appreciationsController.storeSaisie,
+ storeAppreciation:this.appreciationsController.storeAppreciation,
+ banqueAppreciation:this.banqueAppreciation,
+ storeDetailsNotes:this.appreciationsController.storeDetailsNotes
});
this.appreciationsController.observeToolbarView(this.toolbarView);
var centerRegionItems = [
{
- id: 'eliot.notes.Constantes.viewport.idMainPane',
+ id:'eliot.notes.Constantes.viewport.idMainPane',
xtype:'panel',
layout:'border',
- frame: false,
- border: false,
- autoScroll: true,
- autoShow: true,
+ frame:false,
+ border:false,
+ autoScroll:true,
+ autoShow:true,
items:[
{
- region: 'north',
- height: 40,
- border: false,
- frame: false,
+ region:'north',
+ height:40,
+ border:false,
+ frame:false,
layout:'border',
- items: [
+ items:[
{
- region: 'center',
+ region:'center',
cls:'x-panel-mc',
- border: true,
- frame: false,
+ border:true,
+ frame:false,
layout:'column',
bodyStyle:'padding:1px 25px 2px',
- items: [
+ items:[
{
- width: 350,
- layout: 'form',
- border: false,
- frame: false,
- labelWidth: 70,
- labelPad: 4,
- labelAlign: 'right',
- items: this.eleveView.eleveCompositeField
+ width:350,
+ layout:'form',
+ border:false,
+ frame:false,
+ labelWidth:70,
+ labelPad:4,
+ labelAlign:'right',
+ items:this.eleveView.eleveCompositeField
}
]
}
]
},
{
- region: 'center',
- xtype: 'panel',
+ region:'center',
+ xtype:'panel',
layout:'border',
- frame: false,
- border: false,
- plain: true,
+ frame:false,
+ border:false,
+ plain:true,
items:[
new Ext.TabPanel({
- region: 'center',
- activeTab: 0,
- frame: false,
- border: false,
- plain: false,
+ region:'center',
+ activeTab:0,
+ frame:false,
+ border:false,
+ plain:false,
items:[
{
- title: this.ConfigServeur.libelle.saisie,
- xtype: 'panel',
+ title:this.ConfigServeur.libelle.saisie,
+ xtype:'panel',
layout:'border',
- frame: false,
- border: false,
+ frame:false,
+ border:false,
items:[
{
- region: 'north',
- height: 35,
- border: false,
- frame: false,
+ region:'north',
+ height:35,
+ border:false,
+ frame:false,
items:[
this.toolbarView.toolbar
]
},
{
- region: 'center',
- xtype: 'panel',
- border: false,
- frame: false,
- layout: 'fit',
- items: appreciationsView.items
+ region:'center',
+ xtype:'panel',
+ border:false,
+ frame:false,
+ layout:'fit',
+ items:appreciationsView.items
}
]
},
{
- title: this.ConfigServeur.libelle.graph,
- xtype: 'panel',
- border: false,
- frame: false,
- autoScroll: true,
- layout: 'border',
- items: [
+ title:this.ConfigServeur.libelle.graph,
+ xtype:'panel',
+ border:false,
+ frame:false,
+ autoScroll:true,
+ layout:'border',
+ items:[
{
- border: false,
- frame: false,
- layout: 'border',
- region: 'center',
- items: [
+ border:false,
+ frame:false,
+ layout:'border',
+ region:'center',
+ items:[
{
- border: false,
- frame: false,
- region: 'center',
- layout: 'fit',
+ border:false,
+ frame:false,
+ region:'center',
+ layout:'fit',
- items: [
+ items:[
appreciationsView.graphPanel
]
},
{
- region: 'east',
- xtype: 'panel',
+ region:'east',
+ xtype:'panel',
- border: false,
- frame : false,
- layout: 'border',
- split: true,
- width: 200,
- minSize: 20,
- collapseMode: 'mini',
+ border:false,
+ frame:false,
+ layout:'border',
+ split:true,
+ width:200,
+ minSize:20,
+ collapseMode:'mini',
- items: [
+ items:[
{
- region: 'center',
- border: false,
- frame : false,
- layout : 'fit',
- items: [
+ region:'center',
+ border:false,
+ frame:false,
+ layout:'fit',
+ items:[
appreciationsView.graphLegendPanel
]
}
]
},
{
- xtype: 'toolbar',
- region: 'south',
- buttonAlign: 'left',
- height: 30,
- items: [
+ xtype:'toolbar',
+ region:'south',
+ buttonAlign:'left',
+ height:30,
+ items:[
{
- icon: this.ConfigServeurGraph.icon.graphEtoile,
- tooltip: this.ConfigServeurGraph.libelle.graphEtoile,
- toggleGroup: 'graph',
- allowDepress: false,
- pressed: true,
- handler: function() {
+ icon:this.ConfigServeurGraph.icon.graphEtoile,
+ tooltip:this.ConfigServeurGraph.libelle.graphEtoile,
+ toggleGroup:'graph',
+ allowDepress:false,
+ style:"margin-left:5px;",
+ pressed:true,
+ handler:function () {
appreciationsView.graph.typeGraph = appreciationsView.graph.Constantes.type.graph.etoile;
appreciationsView.fireEvent(appreciationsView.Constantes.eventId.actionActualiserGraph);
}
},
{
- icon: this.ConfigServeurGraph.icon.graphEleveClasseCompare,
- tooltip: this.ConfigServeurGraph.libelle.graphEleveClasseCompare,
- toggleGroup: 'graph',
- allowDepress: false,
- handler: function() {
+ icon:this.ConfigServeurGraph.icon.graphEleveClasseCompare,
+ tooltip:this.ConfigServeurGraph.libelle.graphEleveClasseCompare,
+ toggleGroup:'graph',
+ allowDepress:false,
+ handler:function () {
appreciationsView.graph.typeGraph = appreciationsView.graph.Constantes.type.graph.eleveClasseCompare;
appreciationsView.fireEvent(appreciationsView.Constantes.eventId.actionActualiserGraph);
}
},
'->',
{
- text: this.ConfigServeur.libelle.imprimer,
- handler: function() {
+ text:this.ConfigServeur.libelle.imprimer,
+ pressed:true,
+ style:"margin-right:10px;margin-top:2px",
+ handler:function () {
appreciationsView.graph.imprime();
}
}
];
// Rendu du viewport
- Ext.onReady(function() {
+ Ext.onReady(function () {
Ext.QuickTips.init();
eliot.layout.doLayout(
'idViewport',
'idNorthPanel',
'idCenterPanel',
centerRegionItems
- );
+ );
var ns = eliot.notes.saisie.appreciations;
});
},
- getTipRenderer : function() {
+ getTipRenderer:function () {
var typeNote = this.ConfigServeur.data.isPeriodeAnnee ? 'moyenne' : 'note';
- return eliot.notes.commun.Utils.getNoteRenderer({type: typeNote});
+ return eliot.notes.commun.Utils.getNoteRenderer({type:typeNote});
}
});
// Construit l'instance singleton
return new Clazz({
- name: 'eliot-notes-consultation-releve-app'
+ name:'eliot-notes-consultation-releve-app'
});
}();