[IMP] Images for the action bar
bzr revid: fva@openerp.com-20120418155314-s9i15jzid5xuv9j1
This commit is contained in:
parent
3a10debd1f
commit
dd42fc4a03
|
@ -534,7 +534,8 @@ body{
|
||||||
text-align:center;
|
text-align:center;
|
||||||
margin:3px;
|
margin:3px;
|
||||||
margin-top:6px;
|
margin-top:6px;
|
||||||
line-height: 90px;
|
//line-height: 90px;
|
||||||
|
//vertical-align:center;
|
||||||
float:left;
|
float:left;
|
||||||
|
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
|
@ -552,6 +553,12 @@ body{
|
||||||
background: -webkit-gradient(linear, left top, left bottom, from(#f0f0f0), to(#e2e2e2));
|
background: -webkit-gradient(linear, left top, left bottom, from(#f0f0f0), to(#e2e2e2));
|
||||||
-webkit-box-shadow: 0px 2px 2px rgba(0,0,0, 0.3);
|
-webkit-box-shadow: 0px 2px 2px rgba(0,0,0, 0.3);
|
||||||
}
|
}
|
||||||
|
.point-of-sale .pos-actionbar .button .label{
|
||||||
|
margin-top: 37px;
|
||||||
|
}
|
||||||
|
.point-of-sale .pos-actionbar .button .icon{
|
||||||
|
margin-top: 10px;
|
||||||
|
}
|
||||||
.point-of-sale .pos-actionbar .button:hover {
|
.point-of-sale .pos-actionbar .button:hover {
|
||||||
color: white;
|
color: white;
|
||||||
background: #7f82ac;
|
background: #7f82ac;
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 3.9 KiB |
Binary file not shown.
After Width: | Height: | Size: 2.3 KiB |
Binary file not shown.
After Width: | Height: | Size: 3.7 KiB |
|
@ -1250,6 +1250,10 @@ openerp.point_of_sale = function(session) {
|
||||||
this._super(parent, options);
|
this._super(parent, options);
|
||||||
this.label = options.label || 'button';
|
this.label = options.label || 'button';
|
||||||
this.rightalign = options.rightalign || false;
|
this.rightalign = options.rightalign || false;
|
||||||
|
if(options.icon){
|
||||||
|
this.icon = options.icon;
|
||||||
|
this.template = 'pos-action-button-with-icon';
|
||||||
|
}
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -1605,12 +1609,24 @@ openerp.point_of_sale = function(session) {
|
||||||
this.actionBar = new ActionbarWidget(null);
|
this.actionBar = new ActionbarWidget(null);
|
||||||
this.actionBar.appendTo($(".point-of-sale #content"));
|
this.actionBar.appendTo($(".point-of-sale #content"));
|
||||||
|
|
||||||
this.actionBar.addNewButton('left',{'label':'foobar'});
|
this.actionBar.addNewButton('left',{
|
||||||
|
label : 'Aide',
|
||||||
|
icon : '/point_of_sale/static/src/img/icons/png48/help-browser.png',
|
||||||
|
});
|
||||||
this.actionBar.addNewButton('left',{'label':'test'});
|
this.actionBar.addNewButton('left',{'label':'test'});
|
||||||
this.actionBar.addNewButton('left',{'label':'kikoo', rightalign:true});
|
this.actionBar.addNewButton('left',{'label':'kikoo', rightalign:true});
|
||||||
|
|
||||||
this.actionBar.addNewButton('right',{'label':'boo'});
|
this.actionBar.addNewButton('right',{'label':'boo'});
|
||||||
this.actionBar.addNewButton('right',{'label':'bah', rightalign:true});
|
this.actionBar.addNewButton('right',{
|
||||||
|
label : 'Payer',
|
||||||
|
rightalign : true,
|
||||||
|
icon : '/point_of_sale/static/src/img/icons/png48/go-next.png',
|
||||||
|
});
|
||||||
|
this.actionBar.addNewButton('right',{
|
||||||
|
label : 'Ook Ook',
|
||||||
|
rightalign : true,
|
||||||
|
icon : '/point_of_sale/static/src/img/icons/png48/face-monkey.png',
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
//returns true if the code is a valid EAN codebar number by checking the control digit.
|
//returns true if the code is a valid EAN codebar number by checking the control digit.
|
||||||
|
|
|
@ -311,7 +311,17 @@
|
||||||
</t>
|
</t>
|
||||||
<t t-name="pos-action-button">
|
<t t-name="pos-action-button">
|
||||||
<li t-att-class=" 'button '+ (widget.rightalign ? 'rightalign ' : '')">
|
<li t-att-class=" 'button '+ (widget.rightalign ? 'rightalign ' : '')">
|
||||||
<t t-esc="widget.label" />
|
<div class='label'>
|
||||||
|
<t t-esc="widget.label" />
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
</t>
|
||||||
|
<t t-name="pos-action-button-with-icon">
|
||||||
|
<li t-att-class=" 'button '+ (widget.rightalign ? 'rightalign ' : '')">
|
||||||
|
<div class='icon'>
|
||||||
|
<img t-att-src="widget.icon" />
|
||||||
|
<div class='iconlabel'><t t-esc="widget.label" /></div>
|
||||||
|
</div>
|
||||||
</li>
|
</li>
|
||||||
</t>
|
</t>
|
||||||
<!-- Onscreen Keyboard :
|
<!-- Onscreen Keyboard :
|
||||||
|
|
Loading…
Reference in New Issue