mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-28 00:04:37 +02:00
cambio de fuentes css
This commit is contained in:
parent
660c7292a5
commit
507faa52e1
@ -28,7 +28,6 @@
|
||||
.modalheadertex{
|
||||
color:white;
|
||||
position:relative;
|
||||
font-family:Nunito;
|
||||
font-size:13pt;
|
||||
top:8px;
|
||||
}
|
||||
@ -70,7 +69,6 @@
|
||||
}
|
||||
.modalwikibuttontex{
|
||||
color:#ffffff;
|
||||
font-family:Nunito;
|
||||
font-size:10pt;
|
||||
position:relative;
|
||||
top:6px;
|
||||
|
@ -29,7 +29,6 @@
|
||||
}
|
||||
.modalheadertex{
|
||||
color:#000;
|
||||
font-family:Nunito;
|
||||
line-height: 40px;
|
||||
font-size: 23pt;
|
||||
margin-bottom:30px;
|
||||
@ -66,7 +65,6 @@
|
||||
}
|
||||
.modalokbuttontex{
|
||||
color:#82b92e;
|
||||
font-family:Nunito;
|
||||
font-size:13pt;
|
||||
}
|
||||
.modalgobutto{
|
||||
@ -80,7 +78,6 @@
|
||||
}
|
||||
.modalgobuttontex{
|
||||
color:#82b92e;
|
||||
font-family:Nunito;
|
||||
font-size:10pt;
|
||||
}
|
||||
|
||||
|
@ -29,7 +29,6 @@
|
||||
}
|
||||
.modalheadertex{
|
||||
color:#000;
|
||||
font-family:Nunito;
|
||||
line-height: 40px;
|
||||
font-size: 23pt;
|
||||
margin-bottom:30px;
|
||||
@ -66,7 +65,6 @@
|
||||
}
|
||||
.modalokbuttontex{
|
||||
color:#82b92e;
|
||||
font-family:Nunito;
|
||||
font-size:13pt;
|
||||
}
|
||||
.modalgobutto{
|
||||
@ -80,7 +78,6 @@
|
||||
}
|
||||
.modalgobuttontex{
|
||||
color:#82b92e;
|
||||
font-family:Nunito;
|
||||
font-size:10pt;
|
||||
}
|
||||
|
||||
|
@ -6,6 +6,6 @@
|
||||
C0,3.19,3.188,0,7.087,0h14.826C25.809,0,29,3.188,29,7.088V21.915z"/>
|
||||
</g>
|
||||
</g>
|
||||
<text transform="matrix(1 0 0 1 8.0737 21.2432)" fill="#FFFFFF" font-family="'Arial-BoldMT'" font-size="19">D</text>
|
||||
<text transform="matrix(1 0 0 1 8.0737 21.2432)" fill="#FFFFFF" font-size="19">D</text>
|
||||
</g>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 379 B After Width: | Height: | Size: 350 B |
@ -183,11 +183,9 @@
|
||||
|
||||
var scwLanguage;
|
||||
|
||||
function scwSetDefaultLanguage()
|
||||
{try
|
||||
{scwSetLanguage();}
|
||||
catch (exception)
|
||||
{// English
|
||||
function scwSetDefaultLanguage() {
|
||||
try { scwSetLanguage(); }
|
||||
catch (exception) {// English
|
||||
scwToday = 'Today:';
|
||||
scwDrag = 'click here to drag';
|
||||
scwArrMonthNames = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun',
|
||||
@ -436,7 +434,6 @@
|
||||
'vertical-align:middle;' +
|
||||
'border: ridge 2px;' +
|
||||
'font-size: 10pt;' +
|
||||
'font-family: Arial,Helvetica,Sans-Serif;'+
|
||||
'font-weight: bold;}' +
|
||||
'td.scwDrag,' +
|
||||
'td.scwHead {padding: 0px 0px;' +
|
||||
@ -451,7 +448,7 @@
|
||||
'margin: 2px 1px;' +
|
||||
'font-weight: bold;' +
|
||||
'font-size: 10pt;' +
|
||||
'font-family: fixedSys;}' +
|
||||
'}' +
|
||||
'td.scwWeekNumberHead,' +
|
||||
'td.scwWeek {padding: 0px;' +
|
||||
'text-align: center;' +
|
||||
@ -599,21 +596,21 @@
|
||||
// Add a method to format a date into the required pattern
|
||||
|
||||
Date.prototype.scwFormat =
|
||||
function(scwFormat)
|
||||
{var charCount = 0,
|
||||
function (scwFormat) {
|
||||
var charCount = 0,
|
||||
codeChar = '',
|
||||
result = '';
|
||||
|
||||
for (var i=0;i<=scwFormat.length;i++)
|
||||
{if (i<scwFormat.length && scwFormat.charAt(i)==codeChar)
|
||||
{// If we haven't hit the end of the string and
|
||||
for (var i = 0; i <= scwFormat.length; i++) {
|
||||
if (i < scwFormat.length && scwFormat.charAt(i) == codeChar) {// If we haven't hit the end of the string and
|
||||
// the format string character is the same as
|
||||
// the previous one, just clock up one to the
|
||||
// length of the current element definition
|
||||
charCount++;
|
||||
}
|
||||
else {switch (codeChar)
|
||||
{case 'y': case 'Y':
|
||||
else {
|
||||
switch (codeChar) {
|
||||
case 'y': case 'Y':
|
||||
result += (this.getFullYear() % Math.
|
||||
pow(10, charCount)).toString().
|
||||
scwPadLeft(charCount);
|
||||
@ -637,8 +634,7 @@
|
||||
while (charCount-- > 0) { result += codeChar; }
|
||||
}
|
||||
|
||||
if (i<scwFormat.length)
|
||||
{// Store the character we have just worked on
|
||||
if (i < scwFormat.length) {// Store the character we have just worked on
|
||||
codeChar = scwFormat.charAt(i);
|
||||
charCount = 1;
|
||||
}
|
||||
@ -650,8 +646,8 @@
|
||||
// Add a method to left pad zeroes
|
||||
|
||||
String.prototype.scwPadLeft =
|
||||
function(padToLength)
|
||||
{var result = '';
|
||||
function (padToLength) {
|
||||
var result = '';
|
||||
for (var i = 0; i < (padToLength - this.length); i++) { result += '0'; }
|
||||
return (result + this);
|
||||
};
|
||||
@ -661,16 +657,14 @@
|
||||
// arguments.
|
||||
|
||||
Function.prototype.runsAfterSCW =
|
||||
function() {var func = this,
|
||||
function () {
|
||||
var func = this,
|
||||
args = new Array(arguments.length);
|
||||
|
||||
for (var i=0;i<args.length;++i)
|
||||
{args[i] = arguments[i];}
|
||||
for (var i = 0; i < args.length; ++i) { args[i] = arguments[i]; }
|
||||
|
||||
return function()
|
||||
{// concat/join the two argument arrays
|
||||
for (var i=0;i<arguments.length;++i)
|
||||
{args[args.length] = arguments[i];}
|
||||
return function () {// concat/join the two argument arrays
|
||||
for (var i = 0; i < arguments.length; ++i) { args[args.length] = arguments[i]; }
|
||||
|
||||
return (args.shift() == scwTriggerEle)
|
||||
? func.apply(this, args) : null;
|
||||
@ -711,19 +705,19 @@
|
||||
// ****************************************************************************
|
||||
|
||||
function showCal(scwEle, scwSourceEle) { scwShow(scwEle, scwSourceEle); }
|
||||
function scwShow(scwEle,scwSourceEle)
|
||||
{scwTriggerEle = scwSourceEle;
|
||||
function scwShow(scwEle, scwSourceEle) {
|
||||
scwTriggerEle = scwSourceEle;
|
||||
|
||||
// Take any parameters that there might be from the third onwards as
|
||||
// day numbers to be disabled 0 = Sunday through to 6 = Saturday.
|
||||
|
||||
scwParmActiveToday = true;
|
||||
|
||||
for (var i=0;i<7;i++)
|
||||
{scwPassEnabledDay[(i+7-scwWeekStart)%7] = true;
|
||||
for (var j=2;j<arguments.length;j++)
|
||||
{if (arguments[j]==i)
|
||||
{scwPassEnabledDay[(i+7-scwWeekStart)%7] = false;
|
||||
for (var i = 0; i < 7; i++) {
|
||||
scwPassEnabledDay[(i + 7 - scwWeekStart) % 7] = true;
|
||||
for (var j = 2; j < arguments.length; j++) {
|
||||
if (arguments[j] == i) {
|
||||
scwPassEnabledDay[(i + 7 - scwWeekStart) % 7] = false;
|
||||
if (scwDateNow.getDay() == i) scwParmActiveToday = false;
|
||||
}
|
||||
}
|
||||
@ -738,20 +732,19 @@
|
||||
// Find the date and Strip space characters from start and
|
||||
// end of date input.
|
||||
|
||||
if (typeof scwEle.value == 'undefined')
|
||||
{var scwChildNodes = scwEle.childNodes;
|
||||
if (typeof scwEle.value == 'undefined') {
|
||||
var scwChildNodes = scwEle.childNodes;
|
||||
for (var i = 0; i < scwChildNodes.length; i++)
|
||||
if (scwChildNodes[i].nodeType == 3)
|
||||
{var scwDateValue = scwChildNodes[i].nodeValue.replace(/^\s+/,'').replace(/\s+$/,'');
|
||||
if (scwDateValue.length > 0)
|
||||
{scwTriggerEle.scwTextNode = scwChildNodes[i];
|
||||
if (scwChildNodes[i].nodeType == 3) {
|
||||
var scwDateValue = scwChildNodes[i].nodeValue.replace(/^\s+/, '').replace(/\s+$/, '');
|
||||
if (scwDateValue.length > 0) {
|
||||
scwTriggerEle.scwTextNode = scwChildNodes[i];
|
||||
scwTriggerEle.scwLength = scwChildNodes[i].nodeValue.length;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{var scwDateValue = scwEle.value.replace(/^\s+/,'').replace(/\s+$/,'');}
|
||||
else { var scwDateValue = scwEle.value.replace(/^\s+/, '').replace(/\s+$/, ''); }
|
||||
|
||||
// Set the language-dependent elements
|
||||
|
||||
@ -779,22 +772,21 @@
|
||||
scwToday + ' ' +
|
||||
scwDateNow.scwFormat(scwDateDisplayFormat);
|
||||
|
||||
if (scwDateValue.length==0)
|
||||
{// If no value is entered and today is within the range,
|
||||
if (scwDateValue.length == 0) {// If no value is entered and today is within the range,
|
||||
// use today's date, otherwise use the middle of the valid range.
|
||||
|
||||
scwBlnFullInputDate = false;
|
||||
|
||||
if ((new Date(scwBaseYear + scwDropDownYears, 0, 0)) < scwSeedDate ||
|
||||
(new Date(scwBaseYear, 0, 1)) > scwSeedDate
|
||||
)
|
||||
{scwSeedDate = new Date(scwBaseYear +
|
||||
) {
|
||||
scwSeedDate = new Date(scwBaseYear +
|
||||
Math.floor(scwDropDownYears / 2), 5, 1);
|
||||
}
|
||||
}
|
||||
else
|
||||
{function scwInputFormat()
|
||||
{var scwArrSeed = new Array(),
|
||||
else {
|
||||
function scwInputFormat() {
|
||||
var scwArrSeed = new Array(),
|
||||
scwArrInput = scwDateValue.
|
||||
split(new RegExp('[\\' + scwArrDelimiters.
|
||||
join('\\') + ']+', 'g'));
|
||||
@ -808,8 +800,8 @@
|
||||
// still appear in the output string if in the output
|
||||
// format.
|
||||
|
||||
if (scwArrInput[0]!=null)
|
||||
{if (scwArrInput[0].length==0) scwArrInput.splice(0,1);
|
||||
if (scwArrInput[0] != null) {
|
||||
if (scwArrInput[0].length == 0) scwArrInput.splice(0, 1);
|
||||
|
||||
if (scwArrInput[scwArrInput.length - 1].length == 0)
|
||||
scwArrInput.splice(scwArrInput.length - 1, 1);
|
||||
@ -817,8 +809,8 @@
|
||||
|
||||
scwBlnFullInputDate = false;
|
||||
|
||||
switch (scwArrInput.length)
|
||||
{case 1:
|
||||
switch (scwArrInput.length) {
|
||||
case 1:
|
||||
{// Year only entry
|
||||
scwArrSeed[0] = parseInt(scwArrInput[0], 10); // Year
|
||||
scwArrSeed[1] = '6'; // Month
|
||||
@ -882,8 +874,8 @@
|
||||
if (scwExpValYear.exec(scwArrSeed[0]) == null ||
|
||||
scwExpValMonth.exec(scwArrSeed[1]) == null ||
|
||||
scwExpValDay.exec(scwArrSeed[2]) == null
|
||||
)
|
||||
{if (scwShowInvalidDateMsg)
|
||||
) {
|
||||
if (scwShowInvalidDateMsg)
|
||||
alert(scwInvalidDateMsg +
|
||||
scwInvalidAlert[0] + scwDateValue +
|
||||
scwInvalidAlert[1]);
|
||||
@ -916,8 +908,8 @@
|
||||
|
||||
// Check whether the month is in digits or an abbreviation
|
||||
|
||||
if (scwArrSeedDate[1].search(/\d+/)!=0)
|
||||
{month = scwArrMonthNames.join('|').toUpperCase().
|
||||
if (scwArrSeedDate[1].search(/\d+/) != 0) {
|
||||
month = scwArrMonthNames.join('|').toUpperCase().
|
||||
search(scwArrSeedDate[1].substr(0, 3).
|
||||
toUpperCase());
|
||||
scwArrSeedDate[1] = Math.floor(month / 4) + 1;
|
||||
@ -930,8 +922,8 @@
|
||||
|
||||
// Test that we have arrived at a valid date
|
||||
|
||||
if (isNaN(scwSeedDate))
|
||||
{if (scwShowInvalidDateMsg)
|
||||
if (isNaN(scwSeedDate)) {
|
||||
if (scwShowInvalidDateMsg)
|
||||
alert(scwInvalidDateMsg +
|
||||
scwInvalidAlert[0] + scwDateValue +
|
||||
scwInvalidAlert[1]);
|
||||
@ -939,34 +931,33 @@
|
||||
Math.floor(scwDropDownYears / 2), 5, 1);
|
||||
scwBlnFullInputDate = false;
|
||||
}
|
||||
else
|
||||
{// Test that the date is within range,
|
||||
else {// Test that the date is within range,
|
||||
// if not then set date to a sensible date in range.
|
||||
|
||||
if ((new Date(scwBaseYear,0,1)) > scwSeedDate)
|
||||
{if (scwBlnStrict && scwShowOutOfRangeMsg)
|
||||
if ((new Date(scwBaseYear, 0, 1)) > scwSeedDate) {
|
||||
if (scwBlnStrict && scwShowOutOfRangeMsg)
|
||||
alert(scwOutOfRangeMsg);
|
||||
scwSeedDate = new Date(scwBaseYear, 0, 1);
|
||||
scwBlnFullInputDate = false;
|
||||
}
|
||||
else
|
||||
{if ((new Date(scwBaseYear+scwDropDownYears,0,0))<
|
||||
scwSeedDate)
|
||||
{if (scwBlnStrict && scwShowOutOfRangeMsg)
|
||||
else {
|
||||
if ((new Date(scwBaseYear + scwDropDownYears, 0, 0)) <
|
||||
scwSeedDate) {
|
||||
if (scwBlnStrict && scwShowOutOfRangeMsg)
|
||||
alert(scwOutOfRangeMsg);
|
||||
scwSeedDate = new Date(scwBaseYear +
|
||||
Math.floor(scwDropDownYears) - 1,
|
||||
11, 1);
|
||||
scwBlnFullInputDate = false;
|
||||
}
|
||||
else
|
||||
{if (scwBlnStrict && scwBlnFullInputDate &&
|
||||
else {
|
||||
if (scwBlnStrict && scwBlnFullInputDate &&
|
||||
(scwSeedDate.getDate() != scwArrSeedDate[2] ||
|
||||
(scwSeedDate.getMonth() + 1) != scwArrSeedDate[1] ||
|
||||
scwSeedDate.getFullYear() != scwArrSeedDate[0]
|
||||
)
|
||||
)
|
||||
{if (scwShowDoesNotExistMsg) alert(scwDoesNotExistMsg);
|
||||
) {
|
||||
if (scwShowDoesNotExistMsg) alert(scwDoesNotExistMsg);
|
||||
scwSeedDate = new Date(scwSeedDate.getFullYear(),
|
||||
scwSeedDate.getMonth() - 1, 1);
|
||||
scwBlnFullInputDate = false;
|
||||
@ -978,27 +969,27 @@
|
||||
// Test the disabled dates for validity
|
||||
// Give error message if not valid.
|
||||
|
||||
for (var i=0;i<scwDisabledDates.length;i++)
|
||||
{if (!((typeof scwDisabledDates[i] == 'object') &&
|
||||
(scwDisabledDates[i].constructor == Date)))
|
||||
{if ((typeof scwDisabledDates[i] == 'object') &&
|
||||
(scwDisabledDates[i].constructor == Array))
|
||||
{var scwPass = true;
|
||||
for (var i = 0; i < scwDisabledDates.length; i++) {
|
||||
if (!((typeof scwDisabledDates[i] == 'object') &&
|
||||
(scwDisabledDates[i].constructor == Date))) {
|
||||
if ((typeof scwDisabledDates[i] == 'object') &&
|
||||
(scwDisabledDates[i].constructor == Array)) {
|
||||
var scwPass = true;
|
||||
|
||||
if (scwDisabledDates[i].length !=2)
|
||||
{if (scwShowRangeDisablingError)
|
||||
if (scwDisabledDates[i].length != 2) {
|
||||
if (scwShowRangeDisablingError)
|
||||
alert(scwRangeDisablingError[0] +
|
||||
scwDisabledDates[i] +
|
||||
scwRangeDisablingError[1]);
|
||||
scwPass = false;
|
||||
}
|
||||
else
|
||||
{for (var j=0;j<scwDisabledDates[i].length;j++)
|
||||
{if (!((typeof scwDisabledDates[i][j]
|
||||
else {
|
||||
for (var j = 0; j < scwDisabledDates[i].length; j++) {
|
||||
if (!((typeof scwDisabledDates[i][j]
|
||||
== 'object') &&
|
||||
(scwDisabledDates[i][j].constructor
|
||||
== Date)))
|
||||
{if (scwShowRangeDisablingError)
|
||||
== Date))) {
|
||||
if (scwShowRangeDisablingError)
|
||||
alert(scwDateDisablingError[0] +
|
||||
scwDisabledDates[i][j] +
|
||||
scwDateDisablingError[1]);
|
||||
@ -1009,11 +1000,10 @@
|
||||
|
||||
if (scwPass &&
|
||||
(scwDisabledDates[i][0] > scwDisabledDates[i][1])
|
||||
)
|
||||
{scwDisabledDates[i].reverse();}
|
||||
) { scwDisabledDates[i].reverse(); }
|
||||
}
|
||||
else
|
||||
{if (scwShowRangeDisablingError)
|
||||
else {
|
||||
if (scwShowRangeDisablingError)
|
||||
alert(scwDateDisablingError[0] +
|
||||
scwDisabledDates[i] +
|
||||
scwDateDisablingError[1]);
|
||||
@ -1037,8 +1027,8 @@
|
||||
// It requires the following work-around to force SELECTs to display
|
||||
// correctly.
|
||||
|
||||
if (window.opera)
|
||||
{scwID('scwMonths').style.display = 'none';
|
||||
if (window.opera) {
|
||||
scwID('scwMonths').style.display = 'none';
|
||||
scwID('scwMonths').style.display = 'block';
|
||||
scwID('scwYears').style.display = 'none';
|
||||
scwID('scwYears').style.display = 'block';
|
||||
@ -1073,16 +1063,17 @@
|
||||
parseInt(scwEle.offsetHeight, 10),
|
||||
offsetLeft = parseInt(scwEle.offsetLeft, 10);
|
||||
|
||||
if (!window.opera)
|
||||
{while (scwEle.tagName!='BODY' && scwEle.tagName!='HTML')
|
||||
{offsetTop -=parseInt(scwEle.scrollTop, 10);
|
||||
if (!window.opera) {
|
||||
while (scwEle.tagName != 'BODY' && scwEle.tagName != 'HTML') {
|
||||
offsetTop -= parseInt(scwEle.scrollTop, 10);
|
||||
offsetLeft -= parseInt(scwEle.scrollLeft, 10);
|
||||
scwEle = scwEle.parentNode;
|
||||
}
|
||||
scwEle = scwTargetEle;
|
||||
}
|
||||
|
||||
do {scwEle=scwEle.offsetParent;
|
||||
do {
|
||||
scwEle = scwEle.offsetParent;
|
||||
offsetTop += parseInt(scwEle.offsetTop, 10);
|
||||
offsetLeft += parseInt(scwEle.offsetLeft, 10);
|
||||
}
|
||||
@ -1091,8 +1082,8 @@
|
||||
scwID('scw').style.top = offsetTop + 'px';
|
||||
scwID('scw').style.left = offsetLeft + 'px';
|
||||
|
||||
if (scwID('scwIframe'))
|
||||
{scwID('scwIframe').style.top=offsetTop +'px';
|
||||
if (scwID('scwIframe')) {
|
||||
scwID('scwIframe').style.top = offsetTop + 'px';
|
||||
scwID('scwIframe').style.left = offsetLeft + 'px';
|
||||
scwID('scwIframe').style.width = (scwID('scw').offsetWidth - 2) + 'px';
|
||||
scwID('scwIframe').style.height = (scwID('scw').offsetHeight - 2) + 'px';
|
||||
@ -1112,63 +1103,64 @@
|
||||
? scwSourceEle.parentNode
|
||||
: scwSourceEle;
|
||||
|
||||
if (typeof event=='undefined')
|
||||
{el.addEventListener('click',
|
||||
if (typeof event == 'undefined') {
|
||||
el.addEventListener('click',
|
||||
scwStopPropagation,
|
||||
false);
|
||||
}
|
||||
else {if (el.attachEvent)
|
||||
{el.attachEvent('onclick',scwStopPropagation);}
|
||||
else {
|
||||
if (el.attachEvent) { el.attachEvent('onclick', scwStopPropagation); }
|
||||
else { event.cancelBubble = true; }
|
||||
}
|
||||
}
|
||||
|
||||
function scwHide()
|
||||
{scwID('scw').style.visibility='hidden';
|
||||
if (scwID('scwIframe'))
|
||||
{scwID('scwIframe').style.visibility='hidden';}
|
||||
function scwHide() {
|
||||
scwID('scw').style.visibility = 'hidden';
|
||||
if (scwID('scwIframe')) { scwID('scwIframe').style.visibility = 'hidden'; }
|
||||
|
||||
if (typeof scwNextAction!='undefined' && scwNextAction!=null)
|
||||
{scwNextActionReturn = scwNextAction();
|
||||
if (typeof scwNextAction != 'undefined' && scwNextAction != null) {
|
||||
scwNextActionReturn = scwNextAction();
|
||||
// Explicit null set to prevent closure causing memory leak
|
||||
scwNextAction = null;
|
||||
}
|
||||
}
|
||||
|
||||
function scwCancel(scwEvt)
|
||||
{if (scwClickToHide) scwHide();
|
||||
function scwCancel(scwEvt) {
|
||||
if (scwClickToHide) scwHide();
|
||||
scwStopPropagation(scwEvt);
|
||||
}
|
||||
|
||||
function scwStopPropagation(scwEvt)
|
||||
{if (scwEvt.stopPropagation)
|
||||
function scwStopPropagation(scwEvt) {
|
||||
if (scwEvt.stopPropagation)
|
||||
scwEvt.stopPropagation(); // Capture phase
|
||||
else scwEvt.cancelBubble = true; // Bubbling phase
|
||||
}
|
||||
|
||||
function scwBeginDrag(event)
|
||||
{var elementToDrag = scwID('scw');
|
||||
function scwBeginDrag(event) {
|
||||
var elementToDrag = scwID('scw');
|
||||
|
||||
var deltaX = event.clientX,
|
||||
deltaY = event.clientY,
|
||||
offsetEle = elementToDrag;
|
||||
|
||||
do {deltaX -= parseInt(offsetEle.offsetLeft,10);
|
||||
do {
|
||||
deltaX -= parseInt(offsetEle.offsetLeft, 10);
|
||||
deltaY -= parseInt(offsetEle.offsetTop, 10);
|
||||
offsetEle = offsetEle.offsetParent;
|
||||
}
|
||||
while (offsetEle.tagName != 'BODY' &&
|
||||
offsetEle.tagName != 'HTML');
|
||||
|
||||
if (document.addEventListener)
|
||||
{document.addEventListener('mousemove',
|
||||
if (document.addEventListener) {
|
||||
document.addEventListener('mousemove',
|
||||
moveHandler,
|
||||
true); // Capture phase
|
||||
document.addEventListener('mouseup',
|
||||
upHandler,
|
||||
true); // Capture phase
|
||||
}
|
||||
else {elementToDrag.attachEvent('onmousemove',
|
||||
else {
|
||||
elementToDrag.attachEvent('onmousemove',
|
||||
moveHandler); // Bubbling phase
|
||||
elementToDrag.attachEvent('onmouseup',
|
||||
upHandler); // Bubbling phase
|
||||
@ -1177,14 +1169,14 @@
|
||||
|
||||
scwStopPropagation(event);
|
||||
|
||||
function moveHandler(scwEvt)
|
||||
{if (!scwEvt) scwEvt = window.event;
|
||||
function moveHandler(scwEvt) {
|
||||
if (!scwEvt) scwEvt = window.event;
|
||||
|
||||
elementToDrag.style.left = (scwEvt.clientX - deltaX) + 'px';
|
||||
elementToDrag.style.top = (scwEvt.clientY - deltaY) + 'px';
|
||||
|
||||
if (scwID('scwIframe'))
|
||||
{scwID('scwIframe').style.left =
|
||||
if (scwID('scwIframe')) {
|
||||
scwID('scwIframe').style.left =
|
||||
(scwEvt.clientX - deltaX) + 'px';
|
||||
scwID('scwIframe').style.top =
|
||||
(scwEvt.clientY - deltaY) + 'px';
|
||||
@ -1193,18 +1185,19 @@
|
||||
scwStopPropagation(scwEvt);
|
||||
}
|
||||
|
||||
function upHandler(scwEvt)
|
||||
{if (!scwEvt) scwEvt = window.event;
|
||||
function upHandler(scwEvt) {
|
||||
if (!scwEvt) scwEvt = window.event;
|
||||
|
||||
if (document.removeEventListener)
|
||||
{document.removeEventListener('mousemove',
|
||||
if (document.removeEventListener) {
|
||||
document.removeEventListener('mousemove',
|
||||
moveHandler,
|
||||
true); // Capture phase
|
||||
document.removeEventListener('mouseup',
|
||||
upHandler,
|
||||
true); // Capture phase
|
||||
}
|
||||
else {elementToDrag.detachEvent('onmouseup',
|
||||
else {
|
||||
elementToDrag.detachEvent('onmouseup',
|
||||
upHandler); // Bubbling phase
|
||||
elementToDrag.detachEvent('onmousemove',
|
||||
moveHandler); // Bubbling phase
|
||||
@ -1215,8 +1208,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
function scwShowMonth(scwBias)
|
||||
{// Set the selectable Month and Year
|
||||
function scwShowMonth(scwBias) {// Set the selectable Month and Year
|
||||
// May be called: from the left and right arrows
|
||||
// (shift month -1 and +1 respectively)
|
||||
// from the month selection list
|
||||
@ -1237,14 +1229,12 @@
|
||||
scwSelYears = scwID('scwYears');
|
||||
scwSelMonths = scwID('scwMonths');
|
||||
|
||||
if (scwSelYears.options.selectedIndex>-1)
|
||||
{scwMonthSum=12*(scwSelYears.options.selectedIndex)+scwBias;
|
||||
if (scwSelMonths.options.selectedIndex>-1)
|
||||
{scwMonthSum+=scwSelMonths.options.selectedIndex;}
|
||||
if (scwSelYears.options.selectedIndex > -1) {
|
||||
scwMonthSum = 12 * (scwSelYears.options.selectedIndex) + scwBias;
|
||||
if (scwSelMonths.options.selectedIndex > -1) { scwMonthSum += scwSelMonths.options.selectedIndex; }
|
||||
}
|
||||
else
|
||||
{if (scwSelMonths.options.selectedIndex>-1)
|
||||
{scwMonthSum+=scwSelMonths.options.selectedIndex;}
|
||||
else {
|
||||
if (scwSelMonths.options.selectedIndex > -1) { scwMonthSum += scwSelMonths.options.selectedIndex; }
|
||||
}
|
||||
|
||||
scwShowDate.setFullYear(scwBaseYear + Math.floor(scwMonthSum / 12),
|
||||
@ -1261,8 +1251,8 @@
|
||||
if ((12 * parseInt((scwShowDate.getFullYear() - scwBaseYear), 10)) +
|
||||
parseInt(scwShowDate.getMonth(), 10) < (12 * scwDropDownYears) &&
|
||||
(12 * parseInt((scwShowDate.getFullYear() - scwBaseYear), 10)) +
|
||||
parseInt(scwShowDate.getMonth(),10) > -1)
|
||||
{scwSelYears.options.selectedIndex=Math.floor(scwMonthSum/12);
|
||||
parseInt(scwShowDate.getMonth(), 10) > -1) {
|
||||
scwSelYears.options.selectedIndex = Math.floor(scwMonthSum / 12);
|
||||
scwSelMonths.options.selectedIndex = (scwMonthSum % 12);
|
||||
|
||||
scwCurMonth = scwShowDate.getMonth();
|
||||
@ -1278,43 +1268,45 @@
|
||||
|
||||
scwStartDate = new Date(scwShowDate);
|
||||
|
||||
if (scwID('scwFoot'))
|
||||
{var scwFoot = scwID('scwFoot');
|
||||
if (scwID('scwFoot')) {
|
||||
var scwFoot = scwID('scwFoot');
|
||||
|
||||
function scwFootOutput() { scwSetOutput(scwDateNow); }
|
||||
|
||||
if (scwDisabledDates.length==0)
|
||||
{if (scwActiveToday && scwParmActiveToday)
|
||||
{scwFoot.onclick = scwFootOutput;
|
||||
if (scwDisabledDates.length == 0) {
|
||||
if (scwActiveToday && scwParmActiveToday) {
|
||||
scwFoot.onclick = scwFootOutput;
|
||||
scwFoot.className = 'scwFoot';
|
||||
|
||||
if (scwID('scwIFrame'))
|
||||
{scwFoot.onmouseover = scwChangeClass;
|
||||
if (scwID('scwIFrame')) {
|
||||
scwFoot.onmouseover = scwChangeClass;
|
||||
scwFoot.onmouseout = scwChangeClass;
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{scwFoot.onclick = null;
|
||||
else {
|
||||
scwFoot.onclick = null;
|
||||
scwFoot.className = 'scwFootDisabled';
|
||||
|
||||
if (scwID('scwIFrame'))
|
||||
{scwFoot.onmouseover = null;
|
||||
if (scwID('scwIFrame')) {
|
||||
scwFoot.onmouseover = null;
|
||||
scwFoot.onmouseout = null;
|
||||
}
|
||||
|
||||
if (document.addEventListener)
|
||||
{scwFoot.addEventListener('click',
|
||||
if (document.addEventListener) {
|
||||
scwFoot.addEventListener('click',
|
||||
scwStopPropagation,
|
||||
false);
|
||||
}
|
||||
else {scwFoot.attachEvent('onclick',
|
||||
scwStopPropagation);}
|
||||
else {
|
||||
scwFoot.attachEvent('onclick',
|
||||
scwStopPropagation);
|
||||
}
|
||||
}
|
||||
else
|
||||
{for (var k=0;k<scwDisabledDates.length;k++)
|
||||
{if (!scwActiveToday || !scwParmActiveToday ||
|
||||
}
|
||||
else {
|
||||
for (var k = 0; k < scwDisabledDates.length; k++) {
|
||||
if (!scwActiveToday || !scwParmActiveToday ||
|
||||
((typeof scwDisabledDates[k] == 'object') &&
|
||||
(((scwDisabledDates[k].constructor == Date) &&
|
||||
scwDateNow.valueOf() == scwDisabledDates[k].
|
||||
@ -1328,31 +1320,32 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
{scwFoot.onclick = null;
|
||||
) {
|
||||
scwFoot.onclick = null;
|
||||
scwFoot.className = 'scwFootDisabled';
|
||||
|
||||
if (scwID('scwIFrame'))
|
||||
{scwFoot.onmouseover = null;
|
||||
if (scwID('scwIFrame')) {
|
||||
scwFoot.onmouseover = null;
|
||||
scwFoot.onmouseout = null;
|
||||
}
|
||||
|
||||
if (document.addEventListener)
|
||||
{scwFoot.addEventListener('click',
|
||||
if (document.addEventListener) {
|
||||
scwFoot.addEventListener('click',
|
||||
scwStopPropagation,
|
||||
false);
|
||||
}
|
||||
else {scwFoot.attachEvent('onclick',
|
||||
else {
|
||||
scwFoot.attachEvent('onclick',
|
||||
scwStopPropagation);
|
||||
}
|
||||
break;
|
||||
}
|
||||
else
|
||||
{scwFoot.onclick=scwFootOutput;
|
||||
else {
|
||||
scwFoot.onclick = scwFootOutput;
|
||||
scwFoot.className = 'scwFoot';
|
||||
|
||||
if (scwID('scwIFrame'))
|
||||
{scwFoot.onmouseover = scwChangeClass;
|
||||
if (scwID('scwIFrame')) {
|
||||
scwFoot.onmouseover = scwChangeClass;
|
||||
scwFoot.onmouseout = scwChangeClass;
|
||||
}
|
||||
}
|
||||
@ -1360,21 +1353,21 @@
|
||||
}
|
||||
}
|
||||
|
||||
function scwSetOutput(scwOutputDate)
|
||||
{if (typeof scwTargetEle.value == 'undefined')
|
||||
{scwTriggerEle.scwTextNode.
|
||||
function scwSetOutput(scwOutputDate) {
|
||||
if (typeof scwTargetEle.value == 'undefined') {
|
||||
scwTriggerEle.scwTextNode.
|
||||
replaceData(0, scwTriggerEle.scwLength,
|
||||
scwOutputDate.scwFormat(scwDateOutputFormat));
|
||||
}
|
||||
else
|
||||
{scwTargetEle.value =
|
||||
else {
|
||||
scwTargetEle.value =
|
||||
scwOutputDate.scwFormat(scwDateOutputFormat);
|
||||
}
|
||||
scwHide();
|
||||
}
|
||||
|
||||
function scwCellOutput(scwEvt)
|
||||
{var scwEle = scwEventTrigger(scwEvt),
|
||||
function scwCellOutput(scwEvt) {
|
||||
var scwEle = scwEventTrigger(scwEvt),
|
||||
scwOutputDate = new Date(scwStartDate);
|
||||
|
||||
if (scwEle.nodeType == 3) scwEle = scwEle.parentNode;
|
||||
@ -1385,13 +1378,13 @@
|
||||
scwSetOutput(scwOutputDate);
|
||||
}
|
||||
|
||||
function scwChangeClass(scwEvt)
|
||||
{var scwEle = scwEventTrigger(scwEvt);
|
||||
function scwChangeClass(scwEvt) {
|
||||
var scwEle = scwEventTrigger(scwEvt);
|
||||
|
||||
if (scwEle.nodeType == 3) scwEle = scwEle.parentNode;
|
||||
|
||||
switch (scwEle.className)
|
||||
{case 'scwCells':
|
||||
switch (scwEle.className) {
|
||||
case 'scwCells':
|
||||
scwEle.className = 'scwCellsHover';
|
||||
break;
|
||||
case 'scwCellsHover':
|
||||
@ -1425,13 +1418,12 @@
|
||||
return true;
|
||||
}
|
||||
|
||||
function scwEventTrigger(scwEvt)
|
||||
{if (!scwEvt) scwEvt = event;
|
||||
function scwEventTrigger(scwEvt) {
|
||||
if (!scwEvt) scwEvt = event;
|
||||
return scwEvt.target || scwEvt.srcElement;
|
||||
}
|
||||
|
||||
function scwWeekNumber(scwInDate)
|
||||
{// The base day in the week of the input date
|
||||
function scwWeekNumber(scwInDate) {// The base day in the week of the input date
|
||||
var scwInDateWeekBase = new Date(scwInDate);
|
||||
|
||||
scwInDateWeekBase.setDate(scwInDateWeekBase.getDate()
|
||||
@ -1450,16 +1442,14 @@
|
||||
);
|
||||
|
||||
if (scwFirstBaseDay <
|
||||
new Date(scwInDateWeekBase.getFullYear(),0,1))
|
||||
{scwFirstBaseDay.setDate(scwFirstBaseDay.getDate()+7);}
|
||||
new Date(scwInDateWeekBase.getFullYear(), 0, 1)) { scwFirstBaseDay.setDate(scwFirstBaseDay.getDate() + 7); }
|
||||
|
||||
// Start of Week 01
|
||||
var scwStartWeekOne = new Date(scwFirstBaseDay
|
||||
- scwWeekNumberBaseDay
|
||||
+ scwInDate.getDay());
|
||||
|
||||
if (scwStartWeekOne > scwFirstBaseDay)
|
||||
{scwStartWeekOne.setDate(scwStartWeekOne.getDate()-7);}
|
||||
if (scwStartWeekOne > scwFirstBaseDay) { scwStartWeekOne.setDate(scwStartWeekOne.getDate() - 7); }
|
||||
|
||||
// Subtract the date of the current week from the date of the
|
||||
// first week of the year to get the number of weeks in
|
||||
@ -1486,11 +1476,10 @@
|
||||
|
||||
var scwCells = scwID('scwCells');
|
||||
|
||||
for (i=0;i<scwCells.childNodes.length;i++)
|
||||
{var scwRows = scwCells.childNodes[i];
|
||||
if (scwRows.nodeType==1 && scwRows.tagName=='TR')
|
||||
{if (scwWeekNumberDisplay)
|
||||
{//Calculate the week number using scwShowDate
|
||||
for (i = 0; i < scwCells.childNodes.length; i++) {
|
||||
var scwRows = scwCells.childNodes[i];
|
||||
if (scwRows.nodeType == 1 && scwRows.tagName == 'TR') {
|
||||
if (scwWeekNumberDisplay) {//Calculate the week number using scwShowDate
|
||||
scwTmpEl = scwRows.childNodes[0];
|
||||
scwTmpEl.innerHTML = scwWeekNumber(scwShowDate);
|
||||
scwTmpEl.style.borderColor =
|
||||
@ -1501,13 +1490,12 @@
|
||||
: '';
|
||||
scwTmpEl.style.display = '';
|
||||
}
|
||||
else
|
||||
{scwRows.childNodes[0].style.display='none';}
|
||||
else { scwRows.childNodes[0].style.display = 'none'; }
|
||||
|
||||
for (j=1;j<scwRows.childNodes.length;j++)
|
||||
{var scwCols = scwRows.childNodes[j];
|
||||
if (scwCols.nodeType==1 && scwCols.tagName=='TD')
|
||||
{scwRows.childNodes[j].innerHTML=
|
||||
for (j = 1; j < scwRows.childNodes.length; j++) {
|
||||
var scwCols = scwRows.childNodes[j];
|
||||
if (scwCols.nodeType == 1 && scwCols.tagName == 'TD') {
|
||||
scwRows.childNodes[j].innerHTML =
|
||||
scwShowDate.getDate();
|
||||
var scwCell = scwRows.childNodes[j],
|
||||
scwDisabled =
|
||||
@ -1550,8 +1538,8 @@
|
||||
)
|
||||
) ? 'hidden' : '';
|
||||
|
||||
for (var k=0;k<scwDisabledDates.length;k++)
|
||||
{if ((typeof scwDisabledDates[k]=='object')
|
||||
for (var k = 0; k < scwDisabledDates.length; k++) {
|
||||
if ((typeof scwDisabledDates[k] == 'object')
|
||||
&&
|
||||
(scwDisabledDates[k].constructor ==
|
||||
Date
|
||||
@ -1559,10 +1547,9 @@
|
||||
&&
|
||||
scwCompareDateValue ==
|
||||
scwDisabledDates[k].valueOf()
|
||||
)
|
||||
{scwDisabled = true;}
|
||||
else
|
||||
{if ((typeof scwDisabledDates[k]=='object')
|
||||
) { scwDisabled = true; }
|
||||
else {
|
||||
if ((typeof scwDisabledDates[k] == 'object')
|
||||
&&
|
||||
(scwDisabledDates[k].constructor ==
|
||||
Array
|
||||
@ -1573,8 +1560,7 @@
|
||||
&&
|
||||
scwCompareDateValue <=
|
||||
scwDisabledDates[k][1].valueOf()
|
||||
)
|
||||
{scwDisabled = true;}
|
||||
) { scwDisabled = true; }
|
||||
}
|
||||
}
|
||||
|
||||
@ -1585,11 +1571,11 @@
|
||||
!scwPassEnabledDay[(j - 1 + (7 * (i * scwCells.
|
||||
childNodes.
|
||||
length / 6))) % 7]
|
||||
)
|
||||
{scwRows.childNodes[j].onclick = null;
|
||||
) {
|
||||
scwRows.childNodes[j].onclick = null;
|
||||
|
||||
if (scwID('scwIFrame'))
|
||||
{scwRows.childNodes[j].onmouseover = null;
|
||||
if (scwID('scwIFrame')) {
|
||||
scwRows.childNodes[j].onmouseover = null;
|
||||
scwRows.childNodes[j].onmouseout = null;
|
||||
}
|
||||
|
||||
@ -1613,11 +1599,11 @@
|
||||
? document.defaultView.getComputedStyle(scwCell, null).getPropertyValue('background-color')
|
||||
: '';
|
||||
}
|
||||
else
|
||||
{scwRows.childNodes[j].onclick=scwCellOutput;
|
||||
else {
|
||||
scwRows.childNodes[j].onclick = scwCellOutput;
|
||||
|
||||
if (scwID('scwIFrame'))
|
||||
{scwRows.childNodes[j].onmouseover =
|
||||
if (scwID('scwIFrame')) {
|
||||
scwRows.childNodes[j].onmouseover =
|
||||
scwChangeClass;
|
||||
scwRows.childNodes[j].onmouseout =
|
||||
scwChangeClass;
|
||||
@ -1720,12 +1706,12 @@
|
||||
"<tbody id='scwCells' " +
|
||||
"onClick='scwStopPropagation(event);'>");
|
||||
|
||||
for (i=0;i<6;i++)
|
||||
{document.write(
|
||||
for (i = 0; i < 6; i++) {
|
||||
document.write(
|
||||
"<tr>" +
|
||||
"<td class='scwWeekNo' id='scwWeek_" + i + "'></td>");
|
||||
for (j=0;j<7;j++)
|
||||
{document.write(
|
||||
for (j = 0; j < 7; j++) {
|
||||
document.write(
|
||||
"<td class='scwCells' id='scwCell_" + (j + (i * 7)) +
|
||||
"'></td>");
|
||||
}
|
||||
@ -1738,8 +1724,8 @@
|
||||
"</tbody>");
|
||||
|
||||
if ((new Date(scwBaseYear + scwDropDownYears, 0, 0)) > scwDateNow &&
|
||||
(new Date(scwBaseYear, 0, 0)) < scwDateNow)
|
||||
{document.write(
|
||||
(new Date(scwBaseYear, 0, 0)) < scwDateNow) {
|
||||
document.write(
|
||||
"<tfoot class='scwFoot'>" +
|
||||
"<tr class='scwFoot'>" +
|
||||
"<td class='scwFoot' id='scwFoot' colspan='8'>" +
|
||||
@ -1754,8 +1740,8 @@
|
||||
"</tr>" +
|
||||
"</table>");
|
||||
|
||||
if (document.addEventListener)
|
||||
{scwID('scw' ).addEventListener('click',scwCancel,false);
|
||||
if (document.addEventListener) {
|
||||
scwID('scw').addEventListener('click', scwCancel, false);
|
||||
scwID('scwHeadLeft').addEventListener('click', scwStopPropagation, false);
|
||||
scwID('scwMonths').addEventListener('click', scwStopPropagation, false);
|
||||
scwID('scwMonths').addEventListener('change', scwStopPropagation, false);
|
||||
@ -1763,7 +1749,8 @@
|
||||
scwID('scwYears').addEventListener('change', scwStopPropagation, false);
|
||||
scwID('scwHeadRight').addEventListener('click', scwStopPropagation, false);
|
||||
}
|
||||
else {scwID('scw' ).attachEvent('onclick',scwCancel);
|
||||
else {
|
||||
scwID('scw').attachEvent('onclick', scwCancel);
|
||||
scwID('scwHeadLeft').attachEvent('onclick', scwStopPropagation);
|
||||
scwID('scwMonths').attachEvent('onclick', scwStopPropagation);
|
||||
scwID('scwMonths').attachEvent('onchange', scwStopPropagation);
|
||||
@ -1779,8 +1766,7 @@
|
||||
// Start of document level event definition
|
||||
// ****************************************
|
||||
|
||||
if (document.addEventListener)
|
||||
{document.addEventListener('click',scwHide, false);}
|
||||
if (document.addEventListener) { document.addEventListener('click', scwHide, false); }
|
||||
else { document.attachEvent('onclick', scwHide); }
|
||||
|
||||
// ****************************************
|
||||
|
Loading…
x
Reference in New Issue
Block a user