mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-29 10:09:10 +01:00
Get nextmatch header down to one line, hopefully looking a little nicer
This commit is contained in:
parent
5cab1f7811
commit
5b26a5faed
@ -726,9 +726,8 @@ var et2_nextmatch_header_bar = Class.extend(et2_INextmatchHeader, {
|
|||||||
// Left
|
// Left
|
||||||
|
|
||||||
// Record count
|
// Record count
|
||||||
this.count = jQuery(document.createElement("div"))
|
this.count = jQuery(document.createElement("span"))
|
||||||
.addClass("header_count")
|
.addClass("header_count ui-corner-all");
|
||||||
.appendTo(this.div);
|
|
||||||
|
|
||||||
// Need to figure out how to update this as grid scrolls
|
// Need to figure out how to update this as grid scrolls
|
||||||
//this.count.append("? - ? ").append(egw.lang("of")).append(" ");
|
//this.count.append("? - ? ").append(egw.lang("of")).append(" ");
|
||||||
@ -743,7 +742,8 @@ var et2_nextmatch_header_bar = Class.extend(et2_INextmatchHeader, {
|
|||||||
|
|
||||||
// Right
|
// Right
|
||||||
|
|
||||||
this.filters = jQuery(document.createElement("div")).appendTo(this.div);
|
this.filters = jQuery(document.createElement("div")).appendTo(this.div)
|
||||||
|
.addClass("filters");
|
||||||
|
|
||||||
|
|
||||||
// Add category
|
// Add category
|
||||||
@ -762,20 +762,6 @@ var et2_nextmatch_header_bar = Class.extend(et2_INextmatchHeader, {
|
|||||||
this.filter2 = this._build_select('filter2', 'select', settings.filter2, settings.filter2_no_lang);
|
this.filter2 = this._build_select('filter2', 'select', settings.filter2, settings.filter2_no_lang);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Search
|
|
||||||
this.search = et2_createWidget("textbox", {"blur":egw.lang("search")}, this.nextmatch);
|
|
||||||
this.search.input.attr("type", "search")
|
|
||||||
.css("left", "40%").css("position", "relative");
|
|
||||||
this.search.input.val(settings.search);
|
|
||||||
|
|
||||||
jQuery(document.createElement("button"))
|
|
||||||
.appendTo(this.filters)
|
|
||||||
.css("left", "40%").css("position", "relative")
|
|
||||||
.text(">")
|
|
||||||
.click(this.nextmatch, function(event) {
|
|
||||||
event.data.activeFilters.search = self.search.getValue()
|
|
||||||
event.data.applyFilters();
|
|
||||||
});
|
|
||||||
|
|
||||||
// Export
|
// Export
|
||||||
if(!settings.no_csv_export)
|
if(!settings.no_csv_export)
|
||||||
@ -796,6 +782,23 @@ var et2_nextmatch_header_bar = Class.extend(et2_INextmatchHeader, {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.count.appendTo(this.filters);
|
||||||
|
|
||||||
|
// Search
|
||||||
|
this.search = et2_createWidget("textbox", {"blur":egw.lang("search")}, this.nextmatch);
|
||||||
|
this.search.input.attr("type", "search");
|
||||||
|
this.search.input.val(settings.search);
|
||||||
|
|
||||||
|
jQuery(document.createElement("button"))
|
||||||
|
.appendTo(this.filters)
|
||||||
|
.text(">")
|
||||||
|
.click(this.nextmatch, function(event) {
|
||||||
|
event.data.activeFilters.search = self.search.getValue()
|
||||||
|
event.data.applyFilters();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Letter search
|
// Letter search
|
||||||
var current_letter = this.nextmatch.options.settings.searchletter ?
|
var current_letter = this.nextmatch.options.settings.searchletter ?
|
||||||
this.nextmatch.options.settings.searchletter :
|
this.nextmatch.options.settings.searchletter :
|
||||||
@ -846,14 +849,19 @@ var et2_nextmatch_header_bar = Class.extend(et2_INextmatchHeader, {
|
|||||||
"label": this.nextmatch.options.settings[name+"_label"]
|
"label": this.nextmatch.options.settings[name+"_label"]
|
||||||
},this.nextmatch);
|
},this.nextmatch);
|
||||||
|
|
||||||
// Set value
|
|
||||||
select.set_value(value);
|
|
||||||
|
|
||||||
// Set options
|
// Set options
|
||||||
|
// Check in content for options-<name>
|
||||||
var mgr = this.nextmatch.getArrayMgr("content");
|
var mgr = this.nextmatch.getArrayMgr("content");
|
||||||
var options = mgr.getEntry("options-" + name);
|
var options = mgr.getEntry("options-" + name);
|
||||||
|
// Look in sel_options
|
||||||
|
if(!options) options = this.nextmatch.getArrayMgr("sel_options").getEntry(name);
|
||||||
|
// Check parent sel_options, because those are usually global and don't get passed down
|
||||||
|
if(!options) options = this.nextmatch.getArrayMgr("sel_options").parentMgr.getEntry(name);
|
||||||
if(options) select.set_select_options(options);
|
if(options) select.set_select_options(options);
|
||||||
|
|
||||||
|
// Set value
|
||||||
|
select.set_value(value);
|
||||||
|
|
||||||
// Set onChange
|
// Set onChange
|
||||||
var input = select.input;
|
var input = select.input;
|
||||||
if(this.nextmatch.options.settings[name+"_onchange"])
|
if(this.nextmatch.options.settings[name+"_onchange"])
|
||||||
|
@ -511,14 +511,19 @@ label input, label span, label div, label select, label textarea {
|
|||||||
/* background-color: silver;*/
|
/* background-color: silver;*/
|
||||||
}
|
}
|
||||||
|
|
||||||
.nextmatch_header > .header_count {
|
.nextmatch_header .header_count {
|
||||||
|
padding: 0px 20px;
|
||||||
|
margin: 0px 20px;
|
||||||
|
border: 1px solid #E0E0E0;
|
||||||
|
float:right;
|
||||||
|
font-size: 150%;
|
||||||
text-align: center
|
text-align: center
|
||||||
}
|
}
|
||||||
.nextmatch_header .et2_button_icon {
|
.nextmatch_header > .filters {
|
||||||
vertical-align: middle;
|
padding: 5px;
|
||||||
}
|
}
|
||||||
.nextmatch_header select {
|
.nextmatch_header .et2_button_icon {
|
||||||
position: relative;
|
vertical-align: middle;
|
||||||
}
|
}
|
||||||
.nextmatch_sortheader {
|
.nextmatch_sortheader {
|
||||||
color: #003075;
|
color: #003075;
|
||||||
|
Loading…
Reference in New Issue
Block a user