The most important round you’ll play all year.
Make a difference. Help the Y stay on course.
The true power of the Y is in the hearts and actions of every person who believes in our vision of a stronger community for all. Every day, the Y provides food for those who are hungry; a safe, nurturing space for kids to learn and grow and outreach to seniors. Every day, we improve our game thanks to generosity of people like you, our members, our volunteers and our donors.
When you and your friends participate in our Annual Golf Tournament, you help us support adults, youth and families in our community with the YMCA programs and services they need to thrive.
WHEN:
Wednesday, October 18, 2023
WHERE:
Lyman Orchards Golf Club, Jones Course
70 Lyman Rd, Middlefield, CT P 860 200 2730
PLANS:
11:00am Registration
11:30am Lunch
12:30pm Shotgun Start (Scramble)
5:00pm Reception/Dinner, Auction/Raffle, Awards
";
var GoalStatWidthPercent = 0;
var NbrOfDivisions = Settings.Divisions.length;
if(NbrOfDivisions > 0) {
GoalStatWidthPercent = Math.floor(100/NbrOfDivisions);
}
var OldGoalStatWidthPercent = GoalStatWidthPercent;
var GoalStatPercentWidths = [];
var ConsideredTotalPercent = 0;
var ConsiderMaxValueTotalPercent = 0;
for (var j = 0; j < Settings.Divisions.length; j++) {
var DivObj = Settings.Divisions[j];
var GoalStatCalculatedWidth = Math.floor((DivObj.MaxValue / GoalPledgeAmount) * 100) - ConsideredTotalPercent;
GoalStatPercentWidths.push(GoalStatCalculatedWidth);
ConsideredTotalPercent += GoalStatCalculatedWidth;
}
Style = Style.replace("%GoalStatWidthPercent%", GoalStatWidthPercent+"%");
var ProgressPercent = Math.floor((ActualPledgeAmount/GoalPledgeAmount)*100);
Style = Style.replace("%ProgressPercent%", ProgressPercent+"%");
$iframe.ready(function() {
$iframe.contents().find("head").html(Style);
var html = '';
html += '
'+Settings.ChartTitle+'
';
html += '
';
var DivSeparatorCount = 0;
for(var j = 0; j < Settings.Divisions.length; j++) {
if(j > 0) {
DivSeparatorCount += 1;
} else {
DivSeparatorCount += 2;
}
}
//divisions
var GoalStatIndex = 0;
for(var j = 0; j < Settings.Divisions.length; j++) {
var DivObj = Settings.Divisions[j];
var RightLineClass = "";
var GoalNbrMargin = "";
var GoalStatWidth = "";
var SkipMin = j > 0;
if(GoalStatIndex != DivSeparatorCount-1 && GoalStatIndex != DivSeparatorCount-2) {
RightLineClass = " NeedsRightLine";
}
if(GoalStatIndex != 0 && GoalStatIndex != DivSeparatorCount-1) {
GoalNbrMargin = "margin-left:-" + Math.ceil(msr.Measurer.measureRoundedTextWidth(DivObj.FormattedMinValue, FontVal) / 2)+"px";
}
if(GoalStatIndex == DivSeparatorCount-1) {
GoalStatWidth = "width:10px";
}
if (GoalStatIndex == DivSeparatorCount - 2) {
if (GoalStatPercentWidths[GoalStatIndex]) {
GoalStatWidthPercent = GoalStatPercentWidths[GoalStatIndex];
} else {
GoalStatWidthPercent = OldGoalStatWidthPercent;
}
GoalStatWidth = "width:100px; max-width: 14%;";
if (GoalStatWidthPercent > 20 && GoalStatWidthPercent - 10 > 14) {
GoalStatWidth = "width:100px; max-width: " + (GoalStatWidthPercent - 10) + "%;min-width: " + (GoalStatWidthPercent - 10) + "%;";
} else if (GoalStatWidthPercent < 14 || GoalStatWidthPercent - 10 < 14) {
if (GoalStatWidthPercent - 10 > 5) {
GoalStatWidth = "width:100px; max-width: " + (GoalStatWidthPercent - 10) + "%;min-width: " + (GoalStatWidthPercent - 10) + "%;";
} else {
GoalStatWidth = "width:100px; max-width: 5%;";
}
}
if(DivSeparatorCount == 2) {
GoalStatWidth = "width:95%; max-width: 95%;";
}
}
if (GoalStatIndex != DivSeparatorCount - 1 && GoalStatIndex != DivSeparatorCount - 2) {
if (GoalStatPercentWidths[GoalStatIndex]) {
GoalStatWidthPercent = GoalStatPercentWidths[GoalStatIndex];
} else {
GoalStatWidthPercent = OldGoalStatWidthPercent;
}
GoalStatWidth = "width:" + GoalStatWidthPercent+ "%;"
}
var divHtml = '
'+DivObj.FormattedMinValue+'
';
if(SkipMin) {
divHtml = '';
} else {
GoalStatIndex += 1;
}
RightLineClass = "";
GoalNbrMargin = "";
GoalStatWidth = "";
if(GoalStatIndex != DivSeparatorCount-1 && GoalStatIndex != DivSeparatorCount-2) {
RightLineClass = " NeedsRightLine";
}
if(GoalStatIndex != 0 && GoalStatIndex != DivSeparatorCount-1) {
GoalNbrMargin = "margin-left:-" + Math.ceil(msr.Measurer.measureRoundedTextWidth(DivObj.FormattedMaxValue, FontVal) / 2)+"px";
}
if(GoalStatIndex == DivSeparatorCount-1) {
GoalStatWidth = "width:10px";
}
if (GoalStatIndex == DivSeparatorCount - 2) {
if (GoalStatPercentWidths[GoalStatIndex]) {
GoalStatWidthPercent = GoalStatPercentWidths[GoalStatIndex];
} else {
GoalStatWidthPercent = OldGoalStatWidthPercent;
}
GoalStatWidth = "width:100px; max-width: 14%;";
if(GoalStatWidthPercent > 20 && GoalStatWidthPercent-10 > 14) {
GoalStatWidth = "width:100px; max-width: "+(GoalStatWidthPercent-10)+"%;min-width: "+(GoalStatWidthPercent-10)+"%;";
} else if (GoalStatWidthPercent < 14 || GoalStatWidthPercent - 10 < 14) {
if (GoalStatWidthPercent - 10 > 5) {
GoalStatWidth = "width:100px; max-width: " + (GoalStatWidthPercent - 10) + "%;min-width: " + (GoalStatWidthPercent - 10) + "%;";
} else {
GoalStatWidth = "width:100px; max-width: 5%;";
}
}
if(DivSeparatorCount == 2) {
GoalStatWidth = "width:95%; max-width: 95%;";
}
}
if (GoalStatIndex != DivSeparatorCount - 1 && GoalStatIndex != DivSeparatorCount - 2) {
if (GoalStatPercentWidths[GoalStatIndex]) {
GoalStatWidthPercent = GoalStatPercentWidths[GoalStatIndex];
} else {
GoalStatWidthPercent = OldGoalStatWidthPercent;
}
GoalStatWidth = "width:" + GoalStatWidthPercent + "%;"
}
divHtml += '
'+DivObj.FormattedMaxValue+'
';
GoalStatIndex += 1;
html += divHtml;
}
html += '
';
$iframe.contents().find("body").html(html);
});
$('#Thermometer').show();
};
window.RefreshThermometer = function (CampaignerID, GuestID) {
try {
$.ajax({
url: '/Sales/Product/LoadGuestThermometerSettings',
data: {
GuestID: GuestID
},
method: 'POST',
success: function (response) {
try {
response = JSON.parse(response);
} catch (e) {
}
if (response && response.GoalPledgeAmount > 0) {
window.Thermo.DrawChart(true, response, response.GoalPledgeAmount, response.ActualPledgeAmount)
} else {
$("#Thermometer").hide();
}
}
})
} catch (e) {
console.log(e);
$("#Thermometer").hide();
}
};
function UpdateCampaignerHeader(CampaignerID) {
$('#CampaignerID').val(CampaignerID)
$.ajax({
url: '/Sales/Product/CampaignerHeaderUpdate',
data: {
CampaignerID: CampaignerID,
ActivityID: $('#ActivityID').val(),
GuestID: $('#GuestID').val()
},
method: 'POST',
success: function (response) {
$('#CampaignerHeader').html(response)
}
})
window.RefreshThermometer(CampaignerID, $('#GuestID').val());
}
132202 !== 0 && LoadCampaigners(0)
// Change campaginer header
$(document).on('change', '.Guest-Campaigner-Select', function () {
UpdateCampaignerHeader($(this).val())
});
$(document).on('change', '#ActivityID', function () {
LoadCampaigners()
})
$('.MiscInfo-PhoneInput').each(function (idx, input) {
$(input).mask('999-999-9999');
})
})