Cleanup of Web server resources

pull/91/head
Francis Lachapelle 2014-09-12 10:17:48 -04:00
parent bb9e8c0348
commit 21f63c15fc
8 changed files with 0 additions and 2566 deletions

View File

@ -1,635 +0,0 @@
/********** Window & layouts **********/
BODY {
top: 1em;
bottom: 1em;
right: 1em;
left: 1em;
overflow:auto;
}
.toolbar {
display:none;
}
DIV#leftSide {
position: absolute;
top:0;
bottom:0;
left:0;
right:0;
max-width:220px;
overflow-y:auto;
}
DIV.colorBox {
display: inline-block;
}
TD DIV.colorBox, TD DIV.colorBox:hover {
border-color: #fff;
}
TABLE#eventsList .colorBox {
margin-right: 4px;
}
/********** Print settings **********/
INPUT#inputFieldTitle {
width:120px;
}
DIV#rightFrameTitle {
font-size:20px;
text-decoration:underline;
}
/********** What to print **********/
/********** Buttons **********/
#printButtons {
position:absolute;
bottom:0;
right:0;
}
#printButton {
font-weight:bold;
}
/********** RightSide **********/
.divEventsPreview, .divTasksPreview {
border:solid black 2px;
border-radius:5px;
margin-top:3px;
overflow:hidden;
}
.eventsTitle, .tasksTitle {
text-align:center;
}
.overdueTasks {
color:red;
}
.completedTasks {
font-style:italic;
}
DIV#rightSide {
position: absolute;
left:230px;
top:0;
bottom:0;
right:0;
}
DIV#rightFrame {
position:absolute;
right:0;
left:0;
top:12px;
bottom:30px;
background-color:#FFFFFF;
border-radius:5px;
border-top: 1px solid #909090;
border-left: 1px solid #909090;
border-bottom: 1px solid #FFFFFF;
border-right: 1px solid #FFFFFF;
padding-left:5px;
padding-right:5px;
overflow-y:auto;
}
#rightFrameEvents {
width:49.5%;
float:left;
}
#rightFrameTasks {
width:49.5%;
float:right;
}
DIV#rightFrame TH {
text-align: left;
}
DIV#rightFrame TD.cellFormat {
color: #666;
text-align: right;
min-width:52px;
vertical-align:top;
}
/********** Overriding SchedulerUI.css **********/
DIV#calendarHeader {
position:relative;
top:0;
height:38px;
right: 0px;
}
DIV#calendarHeader DIV.calendarLabels
{ top: 1px;
height: 20px;
border-left: 1px solid #ccc;
text-align: center;
font-style:italic;
font-size:150%;
}
DIV#calendarHeader DIV.calendarLabels,
DIV#calendarHeader DIV.dayLabels,
DIV#calendarHeader DIV.days {
position:relative;
left: 0;
margin-left:50px;
}
DIV#calendarHeader DIV.dayLabels
{ top: 1px; }
DIV#calendarHeader DIV.days {
top: 0;
height: 1px;
left: 0;
right: 0;
cursor:initial;
}
DIV#daysView {
position: relative;
top: 0;
right: 8px;
border-right: 1px solid #ccc;
}
DIV#daysView DIV.hours {
height: auto;
}
DIV#daysView DIV.day DIV.clickableHourCell {
height: 29px;
cursor:initial;
}
DIV#daysView DIV.hour {
height: 27px;
}
.minutes15, .minutes30, .minutes45 {
height: 25%;
}
DIV.event {
z-index:1;
background-color: white;
border-radius:5px;
border:1px solid black;
}
DIV.event > DIV.eventInside {
width:100%;
cursor:initial;
}
DIV#daysView DIV.event.starts0
{ top: 0px; }
DIV#daysView DIV.event.lasts0
{ height: 0px; }
DIV#daysView DIV.event.starts1
{ top: 7.5px; }
DIV#daysView DIV.event.lasts1
{ height: 7.25px; }
DIV#daysView DIV.event.starts2
{ top: 15.0px; }
DIV#daysView DIV.event.lasts2
{ height: 14.5px; }
DIV#daysView DIV.event.starts3
{ top: 22.5px; }
DIV#daysView DIV.event.lasts3
{ height: 21.75px; }
DIV#daysView DIV.event.starts4
{ top: 30.0px; }
DIV#daysView DIV.event.lasts4
{ height: 29.0px; }
DIV#daysView DIV.event.starts5
{ top: 37.5px; }
DIV#daysView DIV.event.lasts5
{ height: 36.25px; }
DIV#daysView DIV.event.starts6
{ top: 45.0px; }
DIV#daysView DIV.event.lasts6
{ height: 43.5px; }
DIV#daysView DIV.event.starts7
{ top: 52.5px; }
DIV#daysView DIV.event.lasts7
{ height: 50.75px; }
DIV#daysView DIV.event.starts8
{ top: 60.0px; }
DIV#daysView DIV.event.lasts8
{ height: 58.0px; }
DIV#daysView DIV.event.starts9
{ top: 67.5px; }
DIV#daysView DIV.event.lasts9
{ height: 65.25px; }
DIV#daysView DIV.event.starts10
{ top: 75.0px; }
DIV#daysView DIV.event.lasts10
{ height: 72.5px; }
DIV#daysView DIV.event.starts11
{ top: 82.5px; }
DIV#daysView DIV.event.lasts11
{ height: 79.75px; }
DIV#daysView DIV.event.starts12
{ top: 90.0px; }
DIV#daysView DIV.event.lasts12
{ height: 87.0px; }
DIV#daysView DIV.event.starts13
{ top: 97.5px; }
DIV#daysView DIV.event.lasts13
{ height: 94.25px; }
DIV#daysView DIV.event.starts14
{ top: 105.0px; }
DIV#daysView DIV.event.lasts14
{ height: 101.5px; }
DIV#daysView DIV.event.starts15
{ top: 112.5px; }
DIV#daysView DIV.event.lasts15
{ height: 108.75px; }
DIV#daysView DIV.event.starts16
{ top: 120.0px; }
DIV#daysView DIV.event.lasts16
{ height: 116.0px; }
DIV#daysView DIV.event.starts17
{ top: 127.5px; }
DIV#daysView DIV.event.lasts17
{ height: 123.25px; }
DIV#daysView DIV.event.starts18
{ top: 135.0px; }
DIV#daysView DIV.event.lasts18
{ height: 130.5px; }
DIV#daysView DIV.event.starts19
{ top: 142.5px; }
DIV#daysView DIV.event.lasts19
{ height: 137.75px; }
DIV#daysView DIV.event.starts20
{ top: 150.0px; }
DIV#daysView DIV.event.lasts20
{ height: 145.0px; }
DIV#daysView DIV.event.starts21
{ top: 157.5px; }
DIV#daysView DIV.event.lasts21
{ height: 152.25px; }
DIV#daysView DIV.event.starts22
{ top: 165.0px; }
DIV#daysView DIV.event.lasts22
{ height: 159.5px; }
DIV#daysView DIV.event.starts23
{ top: 172.5px; }
DIV#daysView DIV.event.lasts23
{ height: 166.75px; }
DIV#daysView DIV.event.starts24
{ top: 180.0px; }
DIV#daysView DIV.event.lasts24
{ height: 174.0px; }
DIV#daysView DIV.event.starts25
{ top: 187.5px; }
DIV#daysView DIV.event.lasts25
{ height: 181.25px; }
DIV#daysView DIV.event.starts26
{ top: 195.0px; }
DIV#daysView DIV.event.lasts26
{ height: 188.5px; }
DIV#daysView DIV.event.starts27
{ top: 202.5px; }
DIV#daysView DIV.event.lasts27
{ height: 195.75px; }
DIV#daysView DIV.event.starts28
{ top: 210.0px; }
DIV#daysView DIV.event.lasts28
{ height: 203.0px; }
DIV#daysView DIV.event.starts29
{ top: 217.5px; }
DIV#daysView DIV.event.lasts29
{ height: 210.25px; }
DIV#daysView DIV.event.starts30
{ top: 225.0px; }
DIV#daysView DIV.event.lasts30
{ height: 217.5px; }
DIV#daysView DIV.event.starts31
{ top: 232.5px; }
DIV#daysView DIV.event.lasts31
{ height: 224.75px; }
DIV#daysView DIV.event.starts32
{ top: 240.0px; }
DIV#daysView DIV.event.lasts32
{ height: 232.0px; }
DIV#daysView DIV.event.starts33
{ top: 247.5px; }
DIV#daysView DIV.event.lasts33
{ height: 239.25px; }
DIV#daysView DIV.event.starts34
{ top: 255.0px; }
DIV#daysView DIV.event.lasts34
{ height: 246.5px; }
DIV#daysView DIV.event.starts35
{ top: 262.5px; }
DIV#daysView DIV.event.lasts35
{ height: 253.75px; }
DIV#daysView DIV.event.starts36
{ top: 270.0px; }
DIV#daysView DIV.event.lasts36
{ height: 261.0px; }
DIV#daysView DIV.event.starts37
{ top: 277.5px; }
DIV#daysView DIV.event.lasts37
{ height: 268.25px; }
DIV#daysView DIV.event.starts38
{ top: 285.0px; }
DIV#daysView DIV.event.lasts38
{ height: 275.5px; }
DIV#daysView DIV.event.starts39
{ top: 292.5px; }
DIV#daysView DIV.event.lasts39
{ height: 282.75px; }
DIV#daysView DIV.event.starts40
{ top: 300.0px; }
DIV#daysView DIV.event.lasts40
{ height: 290.0px; }
DIV#daysView DIV.event.starts41
{ top: 307.5px; }
DIV#daysView DIV.event.lasts41
{ height: 297.25px; }
DIV#daysView DIV.event.starts42
{ top: 315.0px; }
DIV#daysView DIV.event.lasts42
{ height: 304.5px; }
DIV#daysView DIV.event.starts43
{ top: 322.5px; }
DIV#daysView DIV.event.lasts43
{ height: 311.75px; }
DIV#daysView DIV.event.starts44
{ top: 330.0px; }
DIV#daysView DIV.event.lasts44
{ height: 319.0px; }
DIV#daysView DIV.event.starts45
{ top: 337.5px; }
DIV#daysView DIV.event.lasts45
{ height: 326.25px; }
DIV#daysView DIV.event.starts46
{ top: 345.0px; }
DIV#daysView DIV.event.lasts46
{ height: 333.5px; }
DIV#daysView DIV.event.starts47
{ top: 352.5px; }
DIV#daysView DIV.event.lasts47
{ height: 340.75px; }
DIV#daysView DIV.event.starts48
{ top: 360.0px; }
DIV#daysView DIV.event.lasts48
{ height: 348.0px; }
DIV#daysView DIV.event.starts49
{ top: 367.5px; }
DIV#daysView DIV.event.lasts49
{ height: 355.25px; }
DIV#daysView DIV.event.starts50
{ top: 375.0px; }
DIV#daysView DIV.event.lasts50
{ height: 362.5px; }
DIV#daysView DIV.event.starts51
{ top: 382.5px; }
DIV#daysView DIV.event.lasts51
{ height: 369.75px; }
DIV#daysView DIV.event.starts52
{ top: 390.0px; }
DIV#daysView DIV.event.lasts52
{ height: 377.0px; }
DIV#daysView DIV.event.starts53
{ top: 397.5px; }
DIV#daysView DIV.event.lasts53
{ height: 384.25px; }
DIV#daysView DIV.event.starts54
{ top: 405.0px; }
DIV#daysView DIV.event.lasts54
{ height: 391.5px; }
DIV#daysView DIV.event.starts55
{ top: 412.5px; }
DIV#daysView DIV.event.lasts55
{ height: 398.75px; }
DIV#daysView DIV.event.starts56
{ top: 420.0px; }
DIV#daysView DIV.event.lasts56
{ height: 406.0px; }
DIV#daysView DIV.event.starts57
{ top: 427.5px; }
DIV#daysView DIV.event.lasts57
{ height: 413.25px; }
DIV#daysView DIV.event.starts58
{ top: 435.0px; }
DIV#daysView DIV.event.lasts58
{ height: 420.5px; }
DIV#daysView DIV.event.starts59
{ top: 442.5px; }
DIV#daysView DIV.event.lasts59
{ height: 427.75px; }
DIV#daysView DIV.event.starts60
{ top: 450.0px; }
DIV#daysView DIV.event.lasts60
{ height: 435.0px; }
DIV#daysView DIV.event.starts61
{ top: 457.5px; }
DIV#daysView DIV.event.lasts61
{ height: 442.25px; }
DIV#daysView DIV.event.starts62
{ top: 465.0px; }
DIV#daysView DIV.event.lasts62
{ height: 449.5px; }
DIV#daysView DIV.event.starts63
{ top: 472.5px; }
DIV#daysView DIV.event.lasts63
{ height: 456.75px; }
DIV#daysView DIV.event.starts64
{ top: 480.0px; }
DIV#daysView DIV.event.lasts64
{ height: 464.0px; }
DIV#daysView DIV.event.starts65
{ top: 487.5px; }
DIV#daysView DIV.event.lasts65
{ height: 471.25px; }
DIV#daysView DIV.event.starts66
{ top: 495.0px; }
DIV#daysView DIV.event.lasts66
{ height: 478.5px; }
DIV#daysView DIV.event.starts67
{ top: 502.5px; }
DIV#daysView DIV.event.lasts67
{ height: 485.75px; }
DIV#daysView DIV.event.starts68
{ top: 510.0px; }
DIV#daysView DIV.event.lasts68
{ height: 493.0px; }
DIV#daysView DIV.event.starts69
{ top: 517.5px; }
DIV#daysView DIV.event.lasts69
{ height: 500.25px; }
DIV#daysView DIV.event.starts70
{ top: 525.0px; }
DIV#daysView DIV.event.lasts70
{ height: 507.5px; }
DIV#daysView DIV.event.starts71
{ top: 532.5px; }
DIV#daysView DIV.event.lasts71
{ height: 514.75px; }
DIV#daysView DIV.event.starts72
{ top: 540.0px; }
DIV#daysView DIV.event.lasts72
{ height: 522.0px; }
DIV#daysView DIV.event.starts73
{ top: 547.5px; }
DIV#daysView DIV.event.lasts73
{ height: 529.25px; }
DIV#daysView DIV.event.starts74
{ top: 555.0px; }
DIV#daysView DIV.event.lasts74
{ height: 536.5px; }
DIV#daysView DIV.event.starts75
{ top: 562.5px; }
DIV#daysView DIV.event.lasts75
{ height: 543.75px; }
DIV#daysView DIV.event.starts76
{ top: 570.0px; }
DIV#daysView DIV.event.lasts76
{ height: 551.0px; }
DIV#daysView DIV.event.starts77
{ top: 577.5px; }
DIV#daysView DIV.event.lasts77
{ height: 558.25px; }
DIV#daysView DIV.event.starts78
{ top: 585.0px; }
DIV#daysView DIV.event.lasts78
{ height: 565.5px; }
DIV#daysView DIV.event.starts79
{ top: 592.5px; }
DIV#daysView DIV.event.lasts79
{ height: 572.75px; }
DIV#daysView DIV.event.starts80
{ top: 600.0px; }
DIV#daysView DIV.event.lasts80
{ height: 580.0px; }
DIV#daysView DIV.event.starts81
{ top: 607.5px; }
DIV#daysView DIV.event.lasts81
{ height: 587.25px; }
DIV#daysView DIV.event.starts82
{ top: 615.0px; }
DIV#daysView DIV.event.lasts82
{ height: 594.5px; }
DIV#daysView DIV.event.starts83
{ top: 622.5px; }
DIV#daysView DIV.event.lasts83
{ height: 601.75px; }
DIV#daysView DIV.event.starts84
{ top: 630.0px; }
DIV#daysView DIV.event.lasts84
{ height: 609.0px; }
DIV#daysView DIV.event.starts85
{ top: 637.5px; }
DIV#daysView DIV.event.lasts85
{ height: 616.25px; }
DIV#daysView DIV.event.starts86
{ top: 645.0px; }
DIV#daysView DIV.event.lasts86
{ height: 623.5px; }
DIV#daysView DIV.event.starts87
{ top: 652.5px; }
DIV#daysView DIV.event.lasts87
{ height: 630.75px; }
DIV#daysView DIV.event.starts88
{ top: 660.0px; }
DIV#daysView DIV.event.lasts88
{ height: 638.0px; }
DIV#daysView DIV.event.starts89
{ top: 667.5px; }
DIV#daysView DIV.event.lasts89
{ height: 645.25px; }
DIV#daysView DIV.event.starts90
{ top: 675.0px; }
DIV#daysView DIV.event.lasts90
{ height: 652.5px; }
DIV#daysView DIV.event.starts91
{ top: 682.5px; }
DIV#daysView DIV.event.lasts91
{ height: 659.75px; }
DIV#daysView DIV.event.starts92
{ top: 690.0px; }
DIV#daysView DIV.event.lasts92
{ height: 667.0px; }
DIV#daysView DIV.event.starts93
{ top: 697.5px; }
DIV#daysView DIV.event.lasts93
{ height: 674.25px; }
DIV#daysView DIV.event.starts94
{ top: 705.0px; }
DIV#daysView DIV.event.lasts94
{ height: 681.5px; }
DIV#daysView DIV.event.starts95
{ top: 712.5px; }
DIV#daysView DIV.event.lasts95
{ height: 688.75px; }
DIV#daysView DIV.event.starts96
{ top: 720.0px; }
DIV#daysView DIV.event.lasts96
{ height: 696.0px; }
/********** Overriding generic.css **********/
TABLE.frame {
width:97%;
text-align: left;
background:#dddddd;
border-radius:8px;
display:table;
}
SPAN.caption {
background: -webkit-linear-gradient(bottom, #E6E7E6, #dddddd); /* For Safari 5.1 to 6.0 */
background: -o-linear-gradient(bottom, #E6E7E6, #dddddd); /* For Opera 11.1 to 12.0 */
background: -moz-linear-gradient(bottom, #E6E7E6, #dddddd); /* For Firefox 3.6 to 15 */
background: linear-gradient(to bottom, #E6E7E6, #dddddd); /* Standard syntax (must be last) */
}
LABEL {
margin-left:0;
}
/********** Calling print(); from the browser **********/
@media print{
.no-print, SPAN.caption, SPAN.weeksHeader, SPAN.daysHeader {
display:none;
}
BODY, DIV#calendarHeader DIV.dayLabels DIV.day, DIV#calendarHeader DIV.days DIV.weekEndDay, DIV#daysView DIV.day DIV.clickableHourCell.outOfDay,
DIV#daysView DIV.weekEndDay DIV.clickableHourCell, DIV#daysView DIV.weekEndDay DIV.clickableHourCell.outOfDay,DIV#monthDaysView DIV.dayOfToday,
DIV.daysViewFor7Days#calendarHeader DIV.days DIV.dayOfToday, DIV.daysViewFor7Days#daysView DIV.dayOfToday DIV.clickableHourCell {
background-color:white;
}
DIV#rightSide {
position:static;
top:5px;
left:5px;
}
DIV#rightFrame {
border:none;
overflow:visible;
}
DIV#calendarHeader DIV.calendarLabels {
font-size:120%;
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,40 +0,0 @@
DIV
{ clear: both; }
FIELDSET
{ margin-bottom: 5px;
border: 1px solid #FFFFFF;
border-top: 1px solid #909090;
border-left: 1px solid #909090; }
FIELDSET DIV
{ margin-left: 20px;
margin-right: 10px; }
SPAN.label
{ cursor: default;
width: 55px;
text-align: right;
line-height: 2em;
float: left;
display: block; }
SPAN.content
{ line-height: 1.5em;
vertical-align: middle;
margin-left: 4px; }
SPAN.content INPUT.textField
{ width: 160px; }
DIV#buttons
{ position: absolute;
bottom: 5px;
right: 5px;
padding: 10px;
padding-top: 5px;
text-align: right; }
LABEL
{ white-space: nowrap; }

View File

@ -1,69 +0,0 @@
/* -*- Mode: java; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
function onLoadContactFolderProperties() {
var tabsContainer = $("propertiesTabs");
var controller = new SOGoTabsController();
controller.attachToTabsContainer(tabsContainer);
var okButton = $("okButton");
okButton.observe("click", onOKClick);
var cancelButton = $("cancelButton");
cancelButton.observe("click", onCancelClick);
Event.observe(document, "keydown", onDocumentKeydown);
}
function onOKClick(event) {
var AddressBookName = $("addressBookName");
var folders = parent$("contactFolders");
var selected = folders.getSelectedNodes()[0];
if (!AddressBookName.value.blank()) {
var newName = AddressBookName.value;
var currentName = AddressBookName.defaultValue;
if (newName && newName.length > 0 && newName != currentName) {
if (selected.getAttribute("owner") != "nobody") {
var url = (URLForFolderID(selected.getAttribute("id")) + "/renameFolder?name=" + escape(newName.utf8encode()));
triggerAjaxRequest(url, folderRenameCallback, {node: selected, name: newName});
}
else {
alert_("You do not own this address book");
}
}
else
window.close();
}
else
alert(_("Please specify an address book name."));
Event.stop(event);
}
function folderRenameCallback(http) {
if (http.readyState == 4) {
if (isHttpStatus204(http.status)) {
var dict = http.callbackData;
dict["node"].childNodesWithTag("span")[0].innerHTML = dict["name"];
window.close();
}
}
}
function onCancelClick(event) {
window.close();
}
function onDocumentKeydown(event) {
var target = Event.element(event);
if (target.tagName == "INPUT" || target.tagName == "SELECT") {
if (event.keyCode == Event.KEY_RETURN) {
onOKClick(event);
}
}
if (event.keyCode == Event.KEY_ESC) {
onCancelClick();
}
}
document.observe("dom:loaded", onLoadContactFolderProperties);

View File

@ -1,221 +0,0 @@
/*************** Dialog *****************/
DIV.dialog.searchMail {
position: relative;
padding: 0px;
opacity: 1;
width: 85%;
height: 75%;
margin: 2em auto;
}
DIV.dialog.searchMail > DIV {
min-height: 500px;
}
/*************** Table adjustment *****************/
TABLE#searchMailHeader
{ width: 100%;
margin-bottom: 1em; }
DIV#searchFiltersList
{
border: 1px solid #909090;
padding-top:2px;
border-radius: 3px;
max-height:105px;
height:105px;
overflow-y:auto;
overflow-x:hidden;
width:100%;
}
DIV#resultsTable
{
border: 1px solid #909090;
margin-top:5px;
border-radius: 3px;
overflow-y: auto;
width:100%;
}
TD#mailAccountsCell {
overflow:hidden;
white-space: nowrap;
}
TR.filterRow, DIV#searchFiltersList > TABLE
{
width:100%;
}
TR.filterRow > TD
{
width: 20%;
vertical-align:middle;
}
TR.filterRow > TD.buttonsCell
{
width: 40px;
}
TR.filterRow > TD.inputsCell
{
width:55%;
}
.td_table_1, .td_table_2, .td_table_3, .td_table_4 {
cursor:default;
}
TD.sortasc {
background:#bfc2bf;
background-image: url(/SOGo.woa/WebServerResources/arrow-up.png);
background-repeat: no-repeat;
background-position:right center;
}
TD.sortdesc {
background:#bfc2bf;
background-image: url(/SOGo.woa/WebServerResources/arrow-down.png);
background-repeat: no-repeat;
background-position:right center;
}
.td_header {
white-space:initial !important;
border-bottom: solid #909090 1px;
border-right: solid #909090 1px;
height:18px;
width:20%;
cursor:pointer;
background: -webkit-linear-gradient(left top, #f0f1f0 , #e6e7e6); /* For Safari 5.1 to 6.0 */
background: -o-linear-gradient(bottom right, #f0f1f0, #e6e7e6); /* For Opera 11.1 to 12.0 */
background: -moz-linear-gradient(bottom right, #f0f1f0, #e6e7e6); /* For Firefox 3.6 to 15 */
background: linear-gradient(to bottom right, #f0f1f0 , #e6e7e6); /* Standard syntax */
}
.td_header:hover
{text-decoration: underline; }
#buttonExpandHeader {
width: 20px;
}
/*************** Button adjustment *****************/
#headerButtons
{
width:175px;
white-space: nowrap;
}
#searchButton, #cancelButton
{
margin-top:0;
}
.searchByList, .searchArgumentsList, .searchInput
{
width:98%;
paddin:0;
margin:0;
}
DIV#optionsButtons
{
position:relative;
height:22px;
}
A#deleteButton, A#openButton
{
float:left;
margin-top:5px;
}
.button
{
font-style:normal;
}
#resizeFrame
{
text-align: -webkit-right;
margin-top:1em;
}
#resizeButton
{
display:inline-block;
text-align: -webkit-center;
}
#resultsFound {
position:absolute;
bottom:20px;
right:10px;
}
#listCollapse
{ position: relative;
border: 1px solid transparent; }
#listCollapse img
{ position: absolute; }
#listCollapse img.collapse
{ clip: rect(0 18px 18px 0);
top: 0;
left: 0; }
#listCollapse img.collapse:hover
{ clip: rect(0 36px 18px 18px);
top: 0;
left: -18px; }
#listCollapse img.rise
{ clip: rect(18px 18px 36px 0);
top: -18px;
left: 0; }
#listCollapse img.rise:hover
{ clip: rect(18px 36px 36px 18px);
top: -18px;
left: -18px; }
.filterButtons
{
width: 40px;
}
.filterButtons IMG
{
z-index: 1;
cursor: pointer;
vertical-align: middle;
}
/* Glow */
.glow {
display: inline-block;
-webkit-transition-duration: 0.3s;
transition-duration: 0.3s;
-webkit-transition-property: box-shadow;
transition-property: box-shadow;
-webkit-transform: translateZ(0);
transform: translateZ(0);
box-shadow: 0 0 1px rgba(0, 0, 0, 0);
}
.glow:hover, .glow:focus, .glow:active {
box-shadow: 0 0 8px rgba(0, 0, 0, 0.6);
}
/*************** Lists *****************/
.hidden
{ display:none; }

View File

@ -1,473 +0,0 @@
/* -*- Mode: js2; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
var searchParams = {
searchLocation: "",
subfolder: true,
filterMatching: "AND",
filters: []
};
// This variable allowed the user to stop the ongoing search
var stopOngoingSearch = false;
/************ Search mail header ************/
function onSearchClick() {
// This function updates the searchParams
var filterRows = $$(".filterRow");
var searchButton = $("searchButton").down().innerHTML;
var mailAccountsList = $("mailAccountsList").options;
if (searchButton == _("Search")) {
searchParams.filters = [];
stopOngoingSearch = false;
// Get the mailboxe(s)
for (i = 0; i < mailAccountsList.length ; i++) {
if (mailAccountsList[i].selected) {
searchParams.searchLocation = mailAccountsList[i].innerHTML;
break;
}
}
for (i = 0; i < filterRows.length; i++) {
// Get the information from every filter row before triggering the AJAX call
var filter = {};
var searchByOptions = filterRows[i].down(".searchByList").options;
var searchArgumentsOptions = filterRows[i].down(".searchArgumentsList").options;
var searchInput = filterRows[i].down(".searchInput");
// Get the searchBy
// Options : 0-Subject, 1-From, 2-To, 3-Cc, 4-Body
filter.searchBy = searchByOptions[searchByOptions.selectedIndex].getAttribute("value");
// Get the searchArgument
// Options : 0-contains, 1-doesn't contains; on the IMAP query add the prefix NOT to negate the statement
filter.negative = ((searchArgumentsOptions == 1) ? true:false);
filter.searchArgument = "doesContain";
// Get the input text
filter.searchInput = searchInput.getValue();
// Add the filter inside the searchParams.filters if the input is not empty
if (!filter.searchInput.empty())
searchParams.filters.push(filter);
}
// Send the request only if there is at least one filter
if (searchParams.filters.length > 0) {
$("searchButton").down().innerHTML = _("Stop");
searchMails();
}
else
alert(_("Please specify at least one filter"));
}
else {
stopOngoingSearch = true;
onSearchEnd();
}
}
function searchMails() {
// Variables for the subfolders search
var optionsList = $("mailAccountsList").options;
var nbOptions = optionsList.length;
var selectedIndex = optionsList.selectedIndex;
var accountNumber, folderPath, folderName;
var mailAccountIndex = mailAccounts.indexOf(searchParams.searchLocation);
var root = false;
if (mailAccountIndex != -1) {
accountNumber = "/" + mailAccountIndex;
folderName = "INBOX";
folderPath = accountNumber + "/folderINBOX";
root = true;
}
else {
var searchLocation = searchParams.searchLocation.split("/");
accountNumber = "/" + userNames.indexOf(searchLocation[0]);
folderName = optionsList[optionsList.selectedIndex].text.split("/").pop();
var paths = optionsList[optionsList.selectedIndex].value.split("/");
folderPath = accountNumber;
for (j = 1; j < paths.length; j++) {
folderPath += "/folder" + paths[j];
}
}
var subfolders = [];
if (searchParams.subfolder === true) {
for (i = 1; i < nbOptions; i++) {
var paths = optionsList[i].value.split("/");
var subfolder = accountNumber;
for (j = 1; j < paths.length; j++) {
subfolder += "/folder" + paths[j];
}
if (root || subfolder.indexOf(folderPath) == 0) {
var keypair = {"folderPath" : subfolder,
"folderName" : optionsList[i].text.split("/").pop() };
subfolders.push(keypair);
}
}
}
var urlstr = (ApplicationBaseURL + folderPath + "/uids");
var callbackData = {"folderName" : folderName, "folderPath" : folderPath, "subfolders" : subfolders, "newSearch" : true};
var object = {"filters":searchParams.filters, "sortingAttributes":{"match":searchParams.filterMatching}};
var content = Object.toJSON(object);
document.searchMailsAjaxRequest = triggerAjaxRequest(urlstr, searchMailsCallback, callbackData, content, {"content-type": "application/json"});
}
function searchMailsCallback(http) {
if (http.readyState == 4 && http.status == 200 && !stopOngoingSearch) {
var response = http.responseText.evalJSON();
var table = $("searchMailFooter").down("tbody");
// Erase all previous entries before proceeding with the current request
if (http.callbackData.newSearch) {
var oldEntries = table.rows;
var count = oldEntries.length - 1;
for (var x = count; x >= 0; x--){
$(oldEntries[x]).remove();
}
}
// ["To", "Attachment", "Flagged", "Subject", "From", "Unread", "Priority", "Date", "Size", "rowClasses", "labels", "rowID", "uid"]
if (response.headers.length > 1) {
if ($("noSearchResults"))
$("noSearchResults").remove();
for (var i = 1; i < response.headers.length; i++) { // Starts at 1 because the position 0 in the array are the headers of the table
var row = document.createElement("tr");
Element.addClassName(row, "resultsRow");
row.setAttribute("uid", response.headers[i][12]);
row.setAttribute("folderPath", http.callbackData.folderPath);
var cell1 = document.createElement("td");
Element.addClassName(cell1, "td_table_1");
cell1.innerHTML = response.headers[i][3];
row.appendChild(cell1);
var cell2 = document.createElement("td");
Element.addClassName(cell2, "td_table_2");
cell2.innerHTML = response.headers[i][4];
row.appendChild(cell2);
var cell3 = document.createElement("td");
Element.addClassName(cell3, "td_table_3");
cell3.innerHTML = response.headers[i][0];
row.appendChild(cell3);
var cell4 = document.createElement("td");
Element.addClassName(cell4, "td_table_4");
cell4.innerHTML = response.headers[i][7];
row.appendChild(cell4);
var cell5 = document.createElement("td");
Element.addClassName(cell5, "td_table_5");
cell5.setAttribute("colspan", "2");
cell5.innerHTML = http.callbackData.folderName;
row.appendChild(cell5);
table.appendChild(row);
}
}
else if (http.callbackData.newSearch) {
if (!table.down("tr")) {
var row = table.insertRow(0);
var cell = row.insertCell(0);
var element = document.createElement("span");
cell.setAttribute("id", "noSearchResults");
cell.setAttribute("colspan", "4");
element.innerHTML = _("No matches found");
cell.appendChild(element);
}
}
if (http.callbackData.subfolders.length > 0) {
var folderName = http.callbackData.subfolders[0].folderName;
var folderPath = http.callbackData.subfolders[0].folderPath;
var subfolders = http.callbackData.subfolders;
subfolders.splice(0, 1);
var urlstr = (ApplicationBaseURL + folderPath + "/uids");
var callbackData = {"folderName" : folderName, "folderPath" : folderPath, "subfolders" : subfolders, "newSearch" : false};
// TODO - need to add these following contents ; asc, no-headers, sort
var object = {"filters":searchParams.filters, "sortingAttributes":{"match":searchParams.filterMatching}};
var content = Object.toJSON(object);
document.searchMailsAjaxRequest = triggerAjaxRequest(urlstr, searchMailsCallback, callbackData, content, {"content-type": "application/json"});
}
else {
onSearchEnd();
}
}
}
function onSearchEnd() {
$("searchButton").down().innerHTML = _("Search");
var nbResults = $$(".resultsRow").length;
if (nbResults == 1)
$("resultsFound").innerHTML = nbResults + " " + _("result found");
else if (nbResults > 0)
$("resultsFound").innerHTML = nbResults + " " + _("results found");
else
$("resultsFound").innerHTML = "";
TableKit.reloadSortableTable($("searchMailFooter"));
$("buttonExpandHeader").addClassName("nosort");
}
function onCancelClick() {
disposeDialog();
$("searchMailView").remove();
$("toolbarSearchButton").disabled = false;
}
function onSearchSubfoldersCheck(event) {
searchParams.subfolder = (event.checked ? true : false);
}
function onMatchFilters(event) {
searchParams.filterMatching = ((event.getAttribute("id") == "matchAllFilters") ? "AND" : "OR");
}
/**** Search mail body ****/
function onAddFilter() {
var table = $("searchFiltersList").down("TABLE");
var searchByList = $("searchByList").getElementsByTagName("li");
var stringArgumentsList = $("stringArgumentsList").getElementsByTagName("li");
var rowCount = table.rows.length;
var row = table.insertRow(rowCount);
Element.addClassName(row, "filterRow");
var cell1 = row.insertCell(0);
var element1 = document.createElement("select");
Element.addClassName(element1, "searchByList");
element1.setAttribute("id", "searchByListRow" + rowCount);
var options = {0:"subject", 1:"from", 2:"to", 3:"cc", 4:"body"};
for (var i = 0; i < searchByList.length; i++) {
var option = document.createElement("option");
option.value = options[i];
option.innerHTML = searchByList[i].innerHTML;
element1.appendChild(option);
}
cell1.appendChild(element1);
var cell2 = row.insertCell(1);
var element2 = document.createElement("select");
Element.addClassName(element2, "searchArgumentsList");
element2.setAttribute("id", "searchArgumentsListRow" + rowCount);
for (var i = 0; i < stringArgumentsList.length; i++) {
var option = document.createElement("option");
option.innerHTML = stringArgumentsList[i].innerHTML;
element2.appendChild(option);
}
cell2.appendChild(element2);
var cell3 = row.insertCell(2);
Element.addClassName(cell3, "inputsCell");
var element3 = document.createElement("input");
Element.addClassName(element3, "searchInput");
element3.setAttribute("type", "text");
element3.setAttribute("name", "searchInput");
element3.setAttribute("id", "searchInputRow" + rowCount);
cell3.appendChild(element3);
var cell4 = row.insertCell(3);
Element.addClassName(cell4, "buttonsCell");
cell4.setAttribute("align", "center");
var buttonsDiv = document.createElement("div");
var imageAddFilter = document.createElement("img");
var imageRemoveFilter = document.createElement("img");
imageAddFilter.setAttribute("src", "/SOGo.woa/WebServerResources/add-icon.png");
imageRemoveFilter.setAttribute("src", "/SOGo.woa/WebServerResources/remove-icon.png");
Element.addClassName(imageAddFilter, "glow");
Element.addClassName(imageRemoveFilter, "glow");
imageAddFilter.setAttribute("name", "addFilter");
imageAddFilter.setAttribute("id", "addFilterButtonRow" + rowCount);
$(imageAddFilter).on("click", onAddFilter);
imageRemoveFilter.setAttribute("name", "removeFilter");
imageRemoveFilter.setAttribute("id", "removeFilterButtonRow" + rowCount);
$(imageRemoveFilter).on("click", onRemoveFilter);
Element.addClassName(buttonsDiv, "filterButtons");
buttonsDiv.appendChild(imageAddFilter);
buttonsDiv.appendChild(imageRemoveFilter);
cell4.appendChild(buttonsDiv);
}
function onRemoveFilter() {
var rows = $("searchFiltersList").getElementsByTagName("tr");
var currentRow = this.up(".filterRow");
if(rows.length > 1)
$(currentRow).remove();
}
/**** Search mail Footer ****/
function onResultSelectionChange(event) {
var table = $("searchMailFooter").down("tbody");
if (event && (event.target.innerHTML != _("No matches found"))) {
var node = getTarget(event);
if (node.tagName == "SPAN")
node = node.parentNode;
// Update rows selection
onRowClick(event, node);
}
}
/**** Search mail optionsButtons ****/
function onOpenClick(event) {
// This function is linked with the openButton and the doubleClick on a message
var selectedRow = $("searchMailFooter").down("._selected");
var msguid = selectedRow.getAttribute("uid");
var folderPath = selectedRow.getAttribute("folderPath");
var accountUser = userNames[0];
var url = "/SOGo/so/" + accountUser + "/Mail" + folderPath + "/" + msguid + "/popupview";
if (selectedRow) {
openMessageWindow(msguid, url);
}
}
function onDeleteClick(event) {
var messageList = $("resultsTable").down("TABLE");
var row = $(messageList).getSelectedRows()[0];
if (row) {
var rowIds = row.getAttribute("uid");
var uids = new Array(); // message IDs
var paths = new Array(); // row IDs
var unseenCount = 0;
var refreshFolder = false;
if (rowIds) {
messageList.deselectAll();
if (unseenCount < 1) {
if (row.hasClassName("mailer_unreadmail"))
unseenCount--;
else
unseenCount = 1;
$(row).remove();
}
var uid = rowIds;
var path = Mailer.currentMailbox + "/" + uid;
uids.push(uid);
paths.push(path);
deleteMessageRequestCount++;
deleteCachedMessage(path);
if (Mailer.currentMessages[Mailer.currentMailbox] == uid) {
if (messageContent) messageContent.innerHTML = '';
Mailer.currentMessages[Mailer.currentMailbox] = null;
}
Mailer.dataTable.remove(uid);
updateMessageListCounter(0 - rowIds.length, true);
if (unseenCount < 0) {
var node = mailboxTree.getMailboxNode(Mailer.currentMailbox);
if (node) {
updateUnseenCount(node, unseenCount, true);
}
}
var url = ApplicationBaseURL + encodeURI(Mailer.currentMailbox) + "/batchDelete";
var parameters = "uid=" + uids.join(",");
var data = { "id": uids, "mailbox": Mailer.currentMailbox, "path": paths, "refreshUnseenCount": (unseenCount > 0), "refreshFolder": refreshFolder };
triggerAjaxRequest(url, deleteMessageCallback, data, parameters,
{ "Content-type": "application/x-www-form-urlencoded" });
}
}
return false;
}
function deleteMessageCallback (http){
if (isHttpStatus204(http.status) || http.status == 200) {
var data = http.callbackData;
if (http.status == 200) {
// The answer contains quota information
var rdata = http.responseText.evalJSON(true);
if (rdata.quotas && data["mailbox"].startsWith('/0/'))
updateQuotas(rdata.quotas);
}
if (data["refreshUnseenCount"])
// TODO : the unseen count should be returned when calling the batchDelete remote action,
// in order to avoid this extra AJAX call.
getUnseenCountForFolder(data["mailbox"]);
if (data["refreshFolder"])
Mailer.dataTable.refresh();
}
else if (!http.callbackData["withoutTrash"]) {
showConfirmDialog(_("Warning"),
_("The messages could not be moved to the trash folder. Would you like to delete them immediately?"),
deleteMessagesWithoutTrash.bind(document, http.callbackData),
function() { refreshCurrentFolder(); disposeDialog(); });
}
else {
var html = new Element('div').update(http.responseText);
log ("Messages deletion failed (" + http.status + ") : ");
log (html.down('p').innerHTML);
showAlertDialog(_("Operation failed"));
refreshCurrentFolder();
}
onSearchEnd();
}
function onResizeClick() {
var searchFiltersList = jQuery("#searchFiltersList");
var img = $("listCollapse").select('img').first();
var dialogWindowHeight = $("searchMailView").getHeight();
var state = "collapse";
if (searchFiltersList[0].visible()) {
state = "rise";
searchFiltersList.fadeOut(300, function() {
adjustResultsTable(state);
img.removeClassName('collapse').addClassName('rise');
});
}
else {
adjustResultsTable(state);
searchFiltersList.fadeIn();
img.removeClassName('rise').addClassName('collapse');
}
}
function adjustResultsTable(state) {
var resultsTable = $("resultsTable");
var height = "innerHeight" in $("searchMailView") ? $("searchMailView").innerHeight : $("searchMailView").offsetHeight;
if (state == "collapse") {
height -= 266;
}
else
height -= 152;
$(resultsTable).style.height = height + "px";
}
/*************** Init ********************/
function initSearchMailView () {
// Add one filterRow
onAddFilter();
adjustResultsTable("collapse");
// Observers : Event.on(element, eventName[, selector], callback)
$("searchMailFooter").down("tbody").on("mousedown", "tr", onResultSelectionChange);
$("searchMailFooter").down("tbody").on("dblclick", "tr", onOpenClick);
Event.observe(window, "resize", function() {
var state = ($("searchFiltersList").visible() ? "collapse": "rise");
adjustResultsTable(state);
});
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 413 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 473 B