From: Chuck Scott Date: Fri, 24 Feb 2017 16:46:11 +0000 (-0500) Subject: Deleted all legacy code. X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/index.cgi?a=commitdiff_plain;h=9436554ba5672afcbe782e9badc22fb1aab9f88b;p=WP-Plugins%2Fglm-member-db-eventManagement.git Deleted all legacy code. --- diff --git a/THIS_IS_ON_HOLD_FOR_NOW b/THIS_IS_ON_HOLD_FOR_NOW new file mode 100644 index 0000000..e69de29 diff --git a/defines.php b/defines.php index 889f2a1..cc2c4e0 100644 --- a/defines.php +++ b/defines.php @@ -7,7 +7,7 @@ // NOTE: Plugin & Database versions are defined in "/glm-member-db.php". -define('GLM_MEMBER_EVENTMANAGEMENT_PLUGIN_NAME', 'Gaslight Media Associate Event Management and Ticketing Add-On'); +define('GLM_MEMBER_EVENTMANAGEMENT_PLUGIN_NAME', 'GLM Members Database Event Management and Ticketing'); define('GLM_MEMBER_EVENTMANAGEMENT_PLUGIN_SHORT_NAME', 'Event Management'); define('GLM_MEMBER_EVENTMANAGEMENT_PLUGIN_SLUG', 'glm-member-db-eventManagement'); diff --git a/index.php b/index.php index 016f20a..6cecbad 100644 --- a/index.php +++ b/index.php @@ -1,6 +1,6 @@ - - - ticketing - Sample Site HTML wrapper for upload to Gaslight Media Systems - - - - {GLM} - - - - diff --git a/legacy/Notes/GaslightPages/TicketCart.html b/legacy/Notes/GaslightPages/TicketCart.html deleted file mode 100755 index 195291f..0000000 --- a/legacy/Notes/GaslightPages/TicketCart.html +++ /dev/null @@ -1,322 +0,0 @@ - - - - - - - - -
-
- -
- -
-
Select another event
-
More tickets for this event
-
Purchase selected tickets
-
- - -
Selected Events and Tickets
- - -
(page intro goes here)
- - -
- -
Venue #1 Name
- - -
-
(venue description text goes here)
- -
- - -
- - -
- -
Event #1 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- - -
- -
Event #2 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- -
- - -
- -
-
-
Tickets
-
Venue Total
-
-
-
19
-
$250.00
-
-
- -
- -
- - -
- -
Venue #2 Name
- - -
-
(venue description text goes here)
- -
- - -
- - -
- -
Event #1 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- - -
- -
Event #2 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- -
- - -
- -
-
-
Tickets
-
Venue Total
-
-
-
19
-
$250.00
-
-
- -
- -
- - -
- -
Cart Summary
- -
-
-
Venues
-
Tickets
-
Grand Total
-
-
-
2
-
19
-
$250.00
-
-
- -
- - -
-
- (purchase and return policies go here) -
-
Proceed to Checkout
-
- -
- -
-
- - - - diff --git a/legacy/Notes/GaslightPages/TicketCheckout.html b/legacy/Notes/GaslightPages/TicketCheckout.html deleted file mode 100755 index f82d8b1..0000000 --- a/legacy/Notes/GaslightPages/TicketCheckout.html +++ /dev/null @@ -1,489 +0,0 @@ - - - - - - - - -
-
- - -
-
Select another event
-
More tickets for this event
-
Return to selcted tickets
-
- - -
-
Contact Information
- - -
-
First Name
-
Last Name
-
Address
-
 
-
City
-
-
State
-
- -
-
-
-
Country
-
- -
-
-
ZIP/Postal code
-
Phone
-
E-Mail
-
Verify E-Mail
-
-
OK to Sent E-Mail?
-
- - -
-
-
- -
- - -
- -
Venue #1 Name
- - -
-
(venue description text goes here)
- -
- - -
- - -
- -
Event #1 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
5
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
2
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- - -
- -
Event #2 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
5
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
2
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- -
- - -
- -
-
-
Tickets
-
Venue Total
-
-
-
19
-
$250.00
-
-
- -
- - -
- -
Payment for Venue #1 Name
- - -
-
-
Card Type
-
- -
-
-
Name on Card
-
Card #
-
-
Expiration
-
- Month - Year -
-
- -
Security #
-
-
- The Security # is the three or four digit number on the signature side of your credit card. - American Express cards may have this number on the front of the card. -
-
-
- -
- -
- - -
-
Contact Information
- - -
-
First Name
-
Last Name
-
Address
-
 
-
City
-
-
State
-
- -
-
-
-
Country
-
- -
-
-
ZIP/Postal code
-
Phone
-
E-Mail
-
Verify E-Mail
-
-
OK to Sent E-Mail?
-
Please send information on activities and offers.
-
-
- -
- - -
- -
Venue #2 Name
- - -
-
(venue description text goes here)
- -
- - -
- - -
- -
Event #1 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
5
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
2
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- - -
- -
Event #2 Name
-
-
(venue description text goes here)
-
- - -
-
-
Quant
-
Section
-
Ticket
-
Price Each
-
Total
-
-
-
5
-
Section 1
-
Type 1
-
$25.00/each
-
$125.00
-
-
-
2
-
Section 2
-
Type 2
-
$25.00
-
$50.00
-
-
-
7
-
$175.00
-
-
- -
- - -
- -
-
-
Tickets
-
Venue Total
-
-
-
19
-
$250.00
-
-
- -
- -
- - -
- -
Payment for Venue #2 Name
- - -
-
-
Card Type
-
- -
-
-
Name on Card
-
Card #
-
-
Expiration
-
- Month - Year -
-
- -
Security #
-
-
- The Security # is the three or four digit number on the signature side of your credit card. - American Express cards may have this number on the front of the card. -
-
-
- -
- -
- - -
- -
Purchase Summary
- -
-
-
Venues
-
Tickets
-
Grand Total
-
-
-
2
-
19
-
$250.00
-
-
- -
- - -
-
Complete Purchase
-
- (purchase and return policies go here) -
-
Purchase Selected Tickets
-
- -
-
- - - - diff --git a/legacy/Notes/GaslightPages/TicketSelection.html b/legacy/Notes/GaslightPages/TicketSelection.html deleted file mode 100755 index 951c615..0000000 --- a/legacy/Notes/GaslightPages/TicketSelection.html +++ /dev/null @@ -1,327 +0,0 @@ - - - - - - - - - - - - - -
-
- - -
-
Select another event
-
Review selected tickets
-
- - -
- -
-
Event Name
-
- (event description text goes here - this might include some formatting from the ckeditor input) -
-
- -
-
Select desired date:
-
-
- -
- - -
- -
-
Venue Name
-
(venue description text goes here)
- - - - -
- (This area will contain address and optionally a Google map, parking information, etc.) - -
- -
- (other detail might go here - things like credit cards accepted) -
- -
- - - -
- - -
- - - - -
- -
Section #1 Name
-
- (section information goes here) -
- - -
Select
- - -
- - - - -
- - -
Ticket Type #1 Name
-
- (ticket description and other info goes here) -
- -
-
50 seats available
-
$25.00/each
-
-
- -
- - -
- - -
Ticket Type #2 Name
-
- (ticket description and other info goes here) -
- -
-
50 seats available
-
$25.00/each
-
-
- -
- - -
- - -
Ticket Type #3 Name
-
- (ticket description and other info goes here) -
- -
-
50 seats available
-
$25.00/each
-
-
- -
- -
- -
- - -
- -
Section #2 Name
-
- (section information goes here) -
- - -
Select
- - -
- - - - -
- - -
Ticket Type #1 Name
-
- (ticket description and other info goes here) -
- -
-
50 seats available
-
$25.00/each
-
-
- -
- - -
- - -
Ticket Type #2 Name
-
- (ticket description and other info goes here) -
- -
-
50 seats available
-
$25.00/each
-
-
- -
- - -
- - -
Ticket Type #3 Name
-
- (ticket description and other info goes here) -
- -
-
50 seats available
-
$25.00/each
-
-
- -
- -
- -
- - -
(total number of tickets and total costs go here)
- - - -
- -
(purchase and return policies go here)
- -
Add to Cart
- - -
-
- - - - diff --git a/legacy/Notes/GaslightPages/css/main.css b/legacy/Notes/GaslightPages/css/main.css deleted file mode 100755 index eaabeaa..0000000 --- a/legacy/Notes/GaslightPages/css/main.css +++ /dev/null @@ -1,695 +0,0 @@ -@import - url(http://fonts.googleapis.com/css?family=Source+Sans+Pro:200,400,600,900,400italic) - ; /* normalize.css v1.1.1 | MIT License | git.io/normalize */ -article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary - { - display: block -} - -audio,canvas,video { - display: inline-block; - *display: inline; - *zoom: 1 -} - -audio:not ([controls] ){ - display: none; - height: 0 -} - -[hidden] { - display: none -} - -html { - background: #fff; - color: #000; - font-size: 100%; - -webkit-text-size-adjust: 100%; - -ms-text-size-adjust: 100% -} - -html,button,input,select,textarea { - font-family: sans-serif -} - -body { - margin: 0 -} - -a:focus { - outline: thin dotted -} - -a:active,a:hover { - outline: 0 -} - -h1 { - font-size: 2em; - margin: 0.67em 0 -} - -h2 { - font-size: 1.5em; - margin: 0.83em 0 -} - -h3 { - font-size: 1.17em; - margin: 1em 0 -} - -h4 { - font-size: 1em; - margin: 1.33em 0 -} - -h5 { - font-size: 0.83em; - margin: 1.67em 0 -} - -h6 { - font-size: 0.67em; - margin: 2.33em 0 -} - -abbr[title] { - border-bottom: 1px dotted -} - -b,strong { - font-weight: bold -} - -blockquote { - margin: 1em 40px -} - -dfn { - font-style: italic -} - -hr { - -moz-box-sizing: content-box; - box-sizing: content-box; - height: 0 -} - -mark { - background: #ff0; - color: #000 -} - -p,pre { - margin: 1em 0 -} - -code,kbd,pre,samp { - font-family: monospace, serif; - _font-family: "courier new", monospace; - font-size: 1em -} - -pre { - white-space: pre; - white-space: pre-wrap; - word-wrap: break-word -} - -q { - quotes: none -} - -q:before,q:after { - content: ''; - content: none -} - -small { - font-size: 80% -} - -sub,sup { - font-size: 75%; - line-height: 0; - position: relative; - vertical-align: baseline -} - -sup { - top: -0.5em -} - -sub { - bottom: -0.25em -} - -dl,menu,ol,ul { - margin: 1em 0 -} - -dd { - margin: 0 0 0 40px -} - -menu,ol,ul { - padding: 0 0 0 40px -} - -nav ul,nav ol { - list-style: none; - list-style-image: none -} - -img { - border: 0; - -ms-interpolation-mode: bicubic -} - -svg:not (:root ){ - overflow: hidden -} - -figure { - margin: 0 -} - -form { - margin: 0 -} - -fieldset { - border: 1px solid silver; - margin: 0 2px; - padding: 0.35em 0.625em 0.75em -} - -legend { - border: 0; - padding: 0; - white-space: normal; - *margin-left: -7px -} - -button,input,select,textarea { - font-size: 100%; - margin: 0; - vertical-align: baseline; - *vertical-align: middle -} - -button,input { - line-height: normal -} - -button,select { - text-transform: none -} - -button,html input[type="button"],input[type="reset"],input[type="submit"] - { - -webkit-appearance: button; - cursor: pointer; - *overflow: visible -} - -button[disabled],html input[disabled] { - cursor: default -} - -input[type="checkbox"],input[type="radio"] { - box-sizing: border-box; - padding: 0; - *height: 13px; - *width: 13px -} - -input[type="search"] { - -webkit-appearance: textfield; - -moz-box-sizing: content-box; - -webkit-box-sizing: content-box; - box-sizing: content-box -} - -input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration - { - -webkit-appearance: none -} - -button::-moz-focus-inner,input::-moz-focus-inner { - border: 0; - padding: 0 -} - -textarea { - overflow: auto; - vertical-align: top -} - -table { - border-collapse: collapse; - border-spacing: 0 -} - -html { - -webkit-font-smoothing: antialiased -} - -body { - font-family: "Source Sans Pro", sans-serif; - color: #3d3d3d; - font-style: normal; - line-height: 120% -} - -#GLMpageTitle { - font-size: 1.2em; - font-weight: 600; - line-height: 125% -} - -#GLMpageIntro { - font-size: 0.8em; - margin: 0 0 0.6em 0 -} - -.glmSection .glmsectionName { - margin: 0 -} - -#GLMeventName,#GLMvenueName,.glmCartBlockTitle,.glmCartEventName,.glmCartPaymentTitle - { - font-size: 1.6em; - font-weight: 600; - line-height: 125% -} - -.glmsectionName { - font-size: 1.45em; - font-weight: 600; - margin: 30px 0 0 0 -} - -#GLMeventDescr,#GLMvenueDescr,.glmCartVenueDescr,.glmCartEventDescr { - font-size: 0.8em; - margin: 0 0 0.75em 0 -} - -.glmCartVenueDescr,.glmCartEventDescr { - margin: 0 0 15px 0 -} - -.glmCartHeader:after,.glmCartTicket:after,.glmCartTotal:after { - content: ""; - display: table; - clear: both -} - -.glmCartHeader>* { - float: left; - width: 20%; - font-weight: 600 -} - -.glmCartHeader>*:last-child { - text-align: right -} - -.glmCartTicket>* { - width: 20%; - float: left -} - -.glmCartTicket>*:last-child { - text-align: right -} - -.glmCartTotal>* { - width: 50%; - float: left -} - -.glmCartTotal>*:last-child { - text-align: right -} - -.summary .glmCartTotal>*,.summary .glmCartHeader>* { - width: 33.3333% -} - -.glmCartFormInput label { - display: inline-block -} - -.glmCartEvent .glmCartTotal { - background: #f5f5f5; - margin-top: 7px; - padding: 7px 0; - border-top: 1px solid #e3e3e3 -} - -.glmCartVenueTotal .glmCartHeader>*,.glmCartVenueTotal .glmCartTotal>* { - width: 50%; - font-size: 1.25em; - text-align: center -} - -.glmCartVenueTotal .glmCartTotal>* { - float: left -} - -.glmCartTotal { - margin: 8px 0 0 0; - font-weight: 200; - font-size: 1.75em -} - -.glmCartBlock>.glmCartBlockTitle { - margin: 0 -} - -@media screen and (max-width: 480px) { - .glmCartTable { - font-size: 80% - } -} - -* { - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; - box-sizing: border-box -} - -img { - max-width: 100%; - height: auto; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px -} - -#GLMcontent { - padding: 0; - max-width: 500px; - margin: 0 auto -} - -#GLMcontent>* { - padding: 0 15px -} - -#GLMcontent>*.glmCartBlock { - padding: 0 15px 15px 15px -} - -#GLMevent,#GLMvenue { - max-width: 500px; - margin: 0 auto 1em auto -} - -#GLMnavigation,#GLMaddToCart { - margin: 0 0 15px 0; - padding: 0; - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - text-align: center; - font-weight: 600; - font-shadow: 0 1px #fff; - font-size: 0.85em; - background: #fcfcfc; - -webkit-background-clip: padding; - -moz-background-clip: padding; - background-clip: padding-box -} - -#GLMnavigation:after,#GLMaddToCart:after { - content: ""; - display: table; - clear: both -} - -.glmNavItem { - float: left; - padding: 10px; - margin: 0; - width: 50%; - border-left: 1px solid #e3e3e3 -} - -.glmNavItem:first-of-type { - border-left: none -} - -#GLMcheckout .glmNavItem,#GLMticketCart .glmNavItem { - width: 33.3333% -} - -.glmCartTable input[type="number"] { - width: 80% -} - -#GLMeventDates,#GLMvenueLocation,#GLMvenueDetail,#GLMvenueSectionMap { - margin: 0 0 15px 0 -} - -.glmPrompt { - font-weight: 600; - font-size: 1.1em -} - -.glmCartFormLine { - margin: 0 0 10px 0 -} - -.glmCartFormLine input { - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - -ms-border-radius: 3px; - -o-border-radius: 3px; - border-radius: 3px -} - -.glmCartFormPrompt { - font-weight: 600; - font-size: 1.1em -} - -.glmTicketType,.glmCartForm,.glmCartEvent,.glmCartBlock,#GLMvenue,.glmSection,#GLMevent,#GLMvenueLocation - { - margin: 0 0 15px 0; - padding: 15px; - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - -webkit-box-shadow: 0 2px #f2f2f2; - -moz-box-shadow: 0 2px #f2f2f2; - box-shadow: 0 2px #f2f2f2 -} - -.glmTicketType img,.glmCartForm img,.glmCartEvent img,.glmCartBlock img,#GLMvenue img,.glmSection img,#GLMevent img,#GLMvenueLocation img - { - width: 100%; - margin: 0 0 15px 0 -} - -.glmTicketDescr { - font-size: 0.85em -} - -.glmTicketAvailable { - margin: 5px 0; - font-weight: 600 -} - -.glmSectionTickets { - margin: 15px 0 -} - -.glmTicketName { - font-size: 1.35em; - font-weight: 600 -} - -.glmSectionSelector { - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - cursor: pointer; - background-color: #f8f8f8; - padding: 8px 15px; - margin: 5px 0; - font-size: 1.15em; - font-weight: 600; - display: inline-block; - font-shadow: 0 1px #fff -} - -.glmSectionSelector:active { - -webkit-box-shadow: inset 0 0 8px #dbdbdb; - -moz-box-shadow: inset 0 0 8px #dbdbdb; - box-shadow: inset 0 0 8px #dbdbdb -} - -#GLMticketsSummary { - font-weight: 600; - font-size: 1.35em; - margin-top: 30px -} - -#GLMpolicy { - font-size: 0.85em; - font-style: italic -} - -.glmTicketPrice { - font-weight: 600; - margin: 15px 0 5px 0; - font-size: 1.25em -} - -.glmCartForm { - margin: 10px 0 0 -} - -.glmCartPayment { - margin: 45px 0 0 0 -} - -input { - width: 100%; - padding: 5px 7px; - outline: none; - font-weight: 600; - font-size: 1em; - font-family: "Source Sans Pro", sans-serif; - color: #3d3d3d; - background: #fafafa; - border: 1px solid #d4d4d4; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - -ms-border-radius: 3px; - -o-border-radius: 3px; - border-radius: 3px -} - -#GLMaddToCart,#GLMpurchase,#GLMcheckoutBtn { - padding: 15px; - margin: 15px 0 0 0; - color: white; - font-size: 1.5em; - text-shadow: 0 1px #4cae3c; - text-align: center; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - border: 1px solid #4cae3c; - -webkit-background-clip: padding; - -moz-background-clip: padding; - background-clip: padding-box; - background-color: #6ace3a; - -webkit-box-shadow: 0 1px 4px rgba(16, 16, 17, 0.08), inset 0 1px 0 - rgba(255, 255, 255, 0.45); - -moz-box-shadow: 0 1px 4px rgba(16, 16, 17, 0.08), inset 0 1px 0 - rgba(255, 255, 255, 0.45); - box-shadow: 0 1px 4px rgba(16, 16, 17, 0.08), inset 0 1px 0 - rgba(255, 255, 255, 0.45); - cursor: pointer -} - -#GLMaddToCart:active,#GLMpurchase:active,#GLMcheckoutBtn:active { - border: 1px solid #39942a; - background-color: #4eb61b; - -webkit-box-shadow: 0 1px 4px rgba(16, 16, 17, 0.08), inset 0 0 15px - rgba(0, 0, 0, 0.3); - -moz-box-shadow: 0 1px 4px rgba(16, 16, 17, 0.08), inset 0 0 15px - rgba(0, 0, 0, 0.3); - box-shadow: 0 1px 4px rgba(16, 16, 17, 0.08), inset 0 0 15px - rgba(0, 0, 0, 0.3) -} - -body { - -webkit-animation-fill-mode: both; - -moz-animation-fill-mode: both; - -ms-animation-fill-mode: both; - -o-animation-fill-mode: both; - animation-fill-mode: both; - -webkit-animation-duration: 1s; - -moz-animation-duration: 1s; - -ms-animation-duration: 1s; - -o-animation-duration: 1s; - animation-duration: 1s -} - -@ --webkit-keyframes fadeIn { 0%{ - opacity: 0 -} - -100%{ -opacity -: -1 -} -} -@ --moz-keyframes fadeIn { 0%{ - opacity: 0 -} - -100%{ -opacity -: -1 -} -} -@ --o-keyframes fadeIn { 0%{ - opacity: 0 -} - -100%{ -opacity -: -1 -} -} -@ -keyframes fadeIn { 0%{ - opacity: 0 -} - -100%{ -opacity -: -1 -} -} -body { - -webkit-animation-name: fadeIn; - -moz-animation-name: fadeIn; - -o-animation-name: fadeIn; - animation-name: fadeIn -} - -@media screen and (max-width: 480px) { - #GLMcontent { - height: 300px; - overflow: auto - } -} \ No newline at end of file diff --git a/legacy/Notes/Sites_Using.txt b/legacy/Notes/Sites_Using.txt deleted file mode 100755 index dafdf5d..0000000 --- a/legacy/Notes/Sites_Using.txt +++ /dev/null @@ -1,8 +0,0 @@ -Sites using this common application ------------------------------------ - - -Site Version Server Database DB Server web/custom directory ---------------------------------------- ------- ------- ----------------------- ----------- -------------------------- -ticketing.greatelakesbaymag.com V3 WS6 greatlakesbaymag DS4 greatlakesbaymag - diff --git a/legacy/classes/EasyPassword.php b/legacy/classes/EasyPassword.php deleted file mode 100755 index 7194dcc..0000000 --- a/legacy/classes/EasyPassword.php +++ /dev/null @@ -1,42 +0,0 @@ - - * Released under the terms of the GNU General Public License - * Based in part on Script released by: Jochen Kupperschmidt - * - * This is a highly modified version of this password generator for this application only. - * For original code please refer to original author. - */ - - -class EasyPassword -{ - - // Get a random dictionary word from a text file - function dictionaryWord() { - $path = 'EasyPassword.words'; - $fileload = @file($path); - $i = count($fileload)-1; - $random = rtrim($fileload[rand(0,$i)]); - return $random; - } - - // This is the function to produce the password - function generateEasyPassword() - { - $word1 = $this->dictionaryWord(); - $numb = rand(1, 9); // Generate specified amount of numbers - $word2 = $this->dictionaryWord(); - - $keys = array ($word1,$numb,$word2); // Place password components in an array - $rand_keys = array_rand($keys,3); // Randomize the 3 password components - return $keys[$rand_keys[0]].$keys[$rand_keys[1]].$keys[$rand_keys[2]]; // Return the resulting password - } - - -} - - -?> \ No newline at end of file diff --git a/legacy/classes/EasyPassword.words b/legacy/classes/EasyPassword.words deleted file mode 100755 index ed13097..0000000 --- a/legacy/classes/EasyPassword.words +++ /dev/null @@ -1,828 +0,0 @@ -able -ABLE -about -account -acid -across -act -addition -after -again -against -agreement -air -all -almost -among -amount -amusement -and -angle -angry -animal -answer -ant -any -apparatus -apple -approval -arch -argument -arm -army -art -as -at -attack -attempt -attention -authority -automatic -awake -baby -back -bad -bag -balance -ball -band -base -basin -basket -bath -be -beautiful -because -bed -bee -before -behaviour -belief -bell -bent -berry -between -bird -birth -bit -black -blade -blood -blow -blue -board -boat -body -boiling -book -boot -bottle -box -boy -brain -brake -branch -brass -bread -breath -brick -bridge -bright -broken -brother -brown -brush -bucket -building -bulb -burn -burst -business -butter -button -by -cake -camera -canvas -card -care -carriage -cart -cat -cause -certain -chain -chalk -chance -change -cheap -cheese -chemical -chest -chief -chin -church -circle -clean -clear -clock -cloth -cloud -coal -coat -cold -collar -colour -comb -come -comfort -committee -common -company -comparison -complete -complex -condition -connection -conscious -control -cook -copper -copy -cord -cork -cotton -cough -country -cover -cow -crack -credit -crime -cruel -crush -cry -cup -cup -current -curtain -curve -cushion -damage -danger -dark -daughter -day -dead -dear -death -debt -decision -deep -degree -delicate -dependent -design -desire -destruction -detail -development -different -digestion -direction -dirty -discovery -discussion -disease -disgust -distance -division -do -dog -door -doubt -down -drain -drawer -dress -drink -driving -drop -dry -dust -ear -early -earth -east -edge -education -effect -egg -elastic -electric -end -engine -enough -equal -error -even -event -ever -every -example -exchange -existence -expansion -experience -expert -eye -face -fact -fall -false -family -far -farm -fat -father -fear -feather -feeble -feeling -female -fertile -fiction -field -fight -finger -fire -first -fish -fixed -flag -flame -flat -flight -floor -flower -fly -fold -food -foolish -foot -for -force -fork -form -forward -fowl -frame -free -frequent -friend -from -front -fruit -full -future -garden -general -get -girl -give -glass -glove -go -goat -gold -good -government -grain -grass -great -green -grey -grip -group -growth -guide -gun -hair -hammer -hand -hanging -happy -harbour -hard -harmony -hat -hate -have -he -healthy -hear -hearing -heart -heat -help -high -history -hole -hollow -hook -hope -horn -horse -hospital -hour -house -how -humour -ice -idea -if -ill -important -impulse -in -increase -industry -ink -insect -instrument -insurance -interest -invention -iron -island -jelly -jewel -join -journey -judge -jump -keep -kettle -key -kick -kind -kiss -knee -knife -knot -knowledge -land -language -last -late -laugh -law -lead -leaf -learning -left -leg -let -letter -level -library -lift -light -like -limit -line -linen -lip -liquid -list -little -living -lock -long -look -loose -loss -loud -love -low -machine -make -male -man -manager -map -mark -market -married -mass -match -material -may -meal -measure -meat -medical -meeting -memory -metal -middle -military -milk -mind -mine -minute -mist -mixed -money -monkey -month -moon -morning -mother -motion -mountain -mouth -move -much -muscle -music -nail -name -narrow -nation -natural -near -necessary -neck -need -needle -nerve -net -new -news -night -no -noise -normal -north -nose -not -note -now -number -nut -of -off -offer -office -oil -old -on -only -open -operation -opinion -opposite -or -orange -order -ornament -other -out -oven -over -owner -page -pain -paint -paper -parallel -parcel -part -past -paste -payment -peace -pen -pencil -person -physical -picture -pig -pin -pipe -place -plane -plant -plate -play -please -pleasure -plough -pocket -point -poison -polish -political -poor -porter -position -possible -pot -potato -powder -power -present -price -print -prison -private -probable -process -produce -profit -property -prose -protest -public -pull -pump -purpose -push -put -quality -question -quick -quiet -quite -rail -rain -range -rat -rate -ray -reaction -reading -ready -reason -receipt -record -red -regret -regular -relation -request -respect -rest -reward -rhythm -rice -right -ring -river -road -rod -roll -roof -room -root -rough -round -rub -rule -run -safe -sail -salt -same -sand -say -scale -school -science -scissors -screw -sea -seat -second -secret -see -seed -seem -self -send -sense -separate -serious -servant -sex -shade -shake -shame -sharp -sheep -shelf -ship -shirt -shock -shoe -short -shut -side -sign -silk -silver -simple -sister -size -skin -skirt -sky -sleep -slip -slope -slow -small -smash -smell -smile -smoke -smooth -snake -sneeze -snow -so -soap -society -sock -soft -solid -some - -son -song -sort -sound -soup -south -space -spade -special -sponge -spoon -spring -square -stage -stamp -star -start -statement -station -steam -steel -stem -step -stick -sticky -stiff -still -stitch -stocking -stomach -stone -stop -store -story -straight -strange -street -stretch -strong -structure -such -sudden -sugar -summer -sun -support -surprise -sweet -swim -system -table -tail -take -talk -tall -taste -tax -teaching -tendency -test -than -that -the -then -theory -there -thick -thin -thing -this -thought -thread -throat -through -through -thumb -thunder -ticket -tight -till -time -tin -tired -to -toe -together -tomorrow -tongue -tooth -top -touch -town -trade -train -transport -tray -tree -trick -trouble -trousers -true -turn -twist -umbrella -under -unit -up -use -value -verse -very -vessel -view -violent -voice -waiting -walk -wall -war -warm -wash -waste -watch -water -wave -wax -way -weather -week -weight -well -west -wet -wheel -when -where -while -whip -whistle -white -who -why -wide -will -wind -window -wine -wing -winter -wire -wise -with -woman -wood -wool -word -work -worm -wound -writing -wrong -year -yellow -yes -yesterday -you -young diff --git a/legacy/classes/GeoCalculations.php b/legacy/classes/GeoCalculations.php deleted file mode 100755 index bd43265..0000000 --- a/legacy/classes/GeoCalculations.php +++ /dev/null @@ -1,253 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: GeoCalculations.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://housing.gaslightmedia.com/admin/ - */ - -/** - * Geographic Calculations Support - * - * PHP version 5 - * - * @category Support_Services - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: GeoCalculations.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://housing.gaslightmedia.com/admin/ - */ -class EventManagementGeoCalculations -{ - /** - * Database Object - * @var $dbh - * @access public - */ - protected $dbh; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - public function __construct($dbh) - { - $this->dbh = $dbh; - } - - - /* - * Get distance from event for an array of member locations - $sort = true to sort by distance - * - * This method caches the results in the event_prop_dist table and will refer first to that table. - * If there's no entry in that table, the method will get the distance information from Google - * and add it to the cache. - * - */ - function getMemberEventDistance( - $eventID, $members, - $member_lat_field = 'lat', $member_lon_field = 'lon', - $distance_field = 'distance', - $duration_field = 'duration', - $member_id_field = 'id', - $sort = false - ) - { - - // Check for valid Event ID and members table - if (($eventID-0) == 0 || !is_array($members) || count($members) == 0) { - return false; - } - - // Get Event location - $sql = "SELECT name, event_code, lat, lon - FROM eventmgt.event - WHERE id = $eventID;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $event_data = $stmt->fetch(PDO::FETCH_ASSOC); - - // Did we get event data - if (!event_data) { - return false; - } - - // Get numeric lat and lon and check if they exist (assume no 0 valuse) - $event_lat = ($event_data['lat'] - 0); - $event_lon = ($event_data['lon'] - 0); - if ($event_lat == 0 || $event_lon == 0) { - return false; - } - - $distances = array(); - $over_query_limit = false; - - while (list($k, $m) = each($members)) { - - $members[$k][$distance_field] = false; - $members[$k][$duration_field] = false; - $members[$k]['member_id_sort_field'] = $m[$member_id_field]; - - // Initialize distance response array entry for this member - $distances[$m[$member_id_field]] = array( - 'id' => $m[$member_id_field], - 'distance' => false - ); - - // If we have lat/lon for this member - $have_latlon = false; - if ($event_lat != 0 && $event_lon != 0 && $m[$member_lat_field] != 0 && $m[$member_lon_field] != 0) { - - $have_latlon = 'YES'; - $have_distance = 'NO'; - $distance = false; - $duration = false; - - // Check for entry in distance cache table - $sql = " - SELECT * - FROM eventmgt.event_prop_dist - WHERE event = $eventID - AND event_lat = $event_lat - AND event_lon = $event_lon - AND member = ".$m[$member_id_field]." - AND memb_lat = ".$m[$member_lat_field]." - AND memb_lon = ".$m[$member_lon_field]." - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $dist_data = $stmt->fetch(PDO::FETCH_ASSOC); - if ($dist_data != false && count($dist_data) > 0) { - $distance = $dist_data['distance']; - $duration = $dist_data['duration']; - $have_distance = 'YES'; - } - - // If we don't have distance from the cache and we're not over limit - if ($have_distance == 'NO' && !$over_query_limit) { - - // Request distance from event from Google - $map_request = 'http://maps.googleapis.com/maps/api/directions/xml?' - .'origin='.$m[$member_lat_field].','.$m[$member_lon_field] - .'&destination='.$event_lat - .','.$event_lon - .'&sensor=false&mode=driving'; - - $ch = curl_init(); - $curlOptions = array( - CURLOPT_URL => $map_request, - CURLOPT_HEADER => 0, - CURLOPT_RETURNTRANSFER => 1, - CURLOPT_FAILONERROR => 1 - ); - curl_setopt_array($ch, $curlOptions); - $response = curl_exec($ch); - curl_close($ch); - - if (strstr($response, 'OVER_QUERY_LIMIT')) { - $over_query_limit = true; - } else { - - // if we got a distance and time, then use that - if ($response) { - - $xml = new SimpleXMLElement($response); - if ($xml) { - $summary = addslashes((string) $xml->route[0]->summary); - $distance = (string) $xml->route[0]->leg[0]->distance->text; - $duration = (string) $xml->route[0]->leg[0]->duration->text; - $start_addr = addslashes((string) $xml->route[0]->leg[0]->start_address); - $end_addr = addslashes((string) $xml->route[0]->leg[0]->end_address); - $have_distance = 'YES'; - - // Delete any previous entry for this member/event - $sql = " - DELETE FROM eventmgt.event_prop_dist - WHERE event = $eventID - AND member = ".$m[$member_id_field]." - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - // Add this result to the event_prop_dist table - $sql = " - INSERT INTO eventmgt.event_prop_dist - ( - event, event_lat, event_lon, - member, memb_lat, memb_lon, - summary, start_addr, end_addr, - distance, duration - ) - VALUES - ( - $eventID, $event_lat, $event_lon, - ".$m[$member_id_field].", ".$m[$member_lat_field].", ".$m[$member_lon_field].", - '$summary', '$start_addr', '$end_addr', - '$distance', '$duration' - ); - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - } // If the response contained XML - } // If we got a response from Google - } // If we're not over limit - - } // If we don't have chached distance - } // If we have lat/lon - - $members[$k][$distance_field] = $distance; - $members[$k]['geo_distance_value'] = (0.0 + $distance); - $members[$k][$duration_field] = $duration; - $members[$k]['geo_duration_value'] = (0.0 + $duration); - - } // For each member - - if ($sort) { - - - uasort($members, 'distCmp'); - - } - - return $members; - } -} - - -// Comparison function to sort by distance - Needs to be declared outside of the class (Yuck!) -function distCmp($a, $b) { - - $adist = $a['geo_distance_value']; - $bdist = $b['geo_distance_value']; - - if ($adist == $bdist) { - - // distance is the same, so sub-sort by member_id to keep things consistent - $amemb = $a['member_id_sort_field']; - $bmemb = $b['member_id_sort_field']; - - if ($amemb == $bmemb) { - return 0; - } - - return ($amemb < $bmemb) ? -1 : 1; - } - return ($adist < $bdist) ? -1 : 1; -} - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/Reports/dataEventReport.php b/legacy/classes/data/Reports/dataEventReport.php deleted file mode 100644 index 4eb627f..0000000 --- a/legacy/classes/data/Reports/dataEventReport.php +++ /dev/null @@ -1,290 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: Reports/dataEventReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -/**** - * - * NOTE: This is a data class for form input validation only. - * There is no database table assoicated with this class! - * - ****/ - - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataStates class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataStates.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ -class EventManagementDataEventReport extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = ''; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Event selection - 'conv' => array( - 'field' => 'conv', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Event Name', - 'tip' => ' -

Select the event for which you would like to produce a report.

-

You may produce an Event Summary report for only one event at a time.

- ' - ) - ), - - // contacts Selection - 'contacts_section' => array( - 'field' => 'contacts_section', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Contacts Section', - 'tip' => ' -

Selects display of Contacts information in the report.

- ' - ) - ), - - // Housing Selection - 'housing_section' => array( - 'field' => 'housing_section', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Housing Section', - 'tip' => ' -

Selects display of Housing information (properties, inventory, reservations) in the report.

- ' - ) - ), - - // Housing Summary Only - 'housing_summary_only' => array( - 'field' => 'housing_summary_only', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Housing Summary Only', - 'tip' => ' -

Selects display of Housing summary information only in the report. - When this option is selected, only the summary is displayed without all of the property and inventory detail.

- ' - ) - ), - - // Housing Available Only - 'housing_available_only' => array( - 'field' => 'housing_available_only', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => true, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Housing Available Only', - 'tip' => ' -

Removes the quantity of assigned and sold inventory and only displays the number currently available.

- ' - ) - ), - - // Reservations Selection - 'reservations_section' => array( - 'field' => 'reservations_section', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Reservations Section', - 'tip' => ' -

Selects display of Reservations information in the report.

- ' - ) - ), - - // Reservations Summary Only - 'reservations_summary_only' => array( - 'field' => 'reservations_summary_only', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Reservations Summary', - 'tip' => ' -

Selects display of Reservations summary information only in the report. - When this option is selected, only the summary is displayed without all of the reservation detail.

- ' - ) - ), - - // Output Type - 'output_type' => array( - 'field' => 'output_type', - 'as' => false, - 'type' => 'list', - 'list' => array( - 'html' => 'Display on screen', - 'print' => 'Printable Report', - 'csv' => 'Export as speadsheet (.csv)' - ), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Output Type', - 'tip' => ' -

This controls the way the report is output

-

Available options include

-
    -
  • Display on Screen - Display the report in your browser below the report request form.
  • -
  • Printable Report - Display the report in a separate browser window for output to a printer.
  • -
  • Export as Spreadsheet - Sends the report to your computer as a ".CSV" type file for import into a spreadsheet program.
  • -
-

If the Printable Report does not show, check to make sure you have permitted browser pop-ups for this Web site.

- ' - ) - ) - - - ); - } - - /** - * Create Report Controls Data - * - * @return array - */ - function newControls() - { - - $r = $this->newEntry(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$event]['default'] = true; - } - - return $r; - - } - - - /** - * Try to process controls input - * - * @return array - */ - function processControls() - { - - $r = $this->processInputData(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$event]['default'] = true; - } - - return $r; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/Reports/dataReservationReport.php b/legacy/classes/data/Reports/dataReservationReport.php deleted file mode 100755 index 33be712..0000000 --- a/legacy/classes/data/Reports/dataReservationReport.php +++ /dev/null @@ -1,357 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: Reports/dataReservationReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.visitgreatlakesbay.org/ - */ - -/**** - * - * NOTE: This is a data class for form input validation only. - * There is no database table assoicated with this class! - * - ****/ - - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataReservationReport class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataReservationReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.visitgreatlakesbay.org - */ -class EventManagementDataReservationReport extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = ''; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Event selection - 'event' => array( - 'field' => 'event', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Event Name', - 'tip' => ' -

Select the event for which you would like to produce a report.

-

You may produce an Reservations report for only one event at a time.

- ' - ) - ), - - // State selection - 'state' => array( - 'field' => 'state', - 'as' => 'state_rep', - 'type' => 'pointer', - 'p_table' => 'state_rep', - 'p_field' => 'code', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'State', - 'tip' => ' -

Optionally select a State for which you would like to produce the report.

-

If no State is selected, the report will include all states.

- ' - ) - ), - - // Team selection - 'team' => array( - 'field' => 'team', - 'as' => 'team_code', - 'type' => 'pointer', - 'p_table' => 'team', - 'p_field' => 'team_code', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Team', - 'tip' => ' -

Optionally select a Team for which you would like to produce the report.

-

If no Team is selected, the report will include all teams.

- ' - ) - ), - - // Property filter selection - 'property' => array( - 'field' => 'property', - 'as' => 'prop_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Property', - 'tip' => ' -

Optionally select a Property for which you would like to produce the report.

-

If no Property is selected, the report will include all properties matching reservations.

- ' - ) - ), - - // Status - 'status' => array( - 'field' => 'status', - 'as' => false, - 'type' => 'list', - 'list' => array( - 'all' => 'All', - 'pending' => 'Pending', - 'confirmed' => 'Confirmed', - 'declined' => 'Declined' - ), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Status', - 'tip' => ' -

This selects which reservations should be display by status

-

Available options include

-
    -
  • All - Display all reservations.
  • -
  • Pending - Display all pending reservations. This is reservations that have neither been confirmed or declined.
  • -
  • Confirmed - Display only reservations that have been confirmed.
  • -
  • Declined - Display only reservations that have been declined.
  • -
- ' - ) - ), - - - // Output Type - 'output_type' => array( - 'field' => 'output_type', - 'as' => false, - 'type' => 'list', - 'list' => array( - 'html' => 'Display on screen', - 'print' => 'Printable Report', - 'csv' => 'Export as speadsheet (.csv)' - ), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Output Type', - 'tip' => ' -

This controls the way the report is output

-

Available options include

-
    -
  • Display on Screen - Display the report in your browser below the report request form.
  • -
  • Printable Report - Display the report in a separate browser window for output to a printer.
  • -
  • Export as Spreadsheet - Sends the report to your computer as a ".CSV" type file for import into a spreadsheet program.
  • -
-

If the Printable Report does not show, check to make sure you have permitted browser pop-ups for this Web site.

- ' - ) - ) - - - - ); - } - - /** - * Create Report Controls Data - * - * @return array - */ - function newControls() - { - - $r = $this->newEntry(); - - // Get event, state, team matrix and merge that with result - $eventStateTeamData = $this->getEventStateTeamMatrix(); - $r['eventStateTeam'] = $eventStateTeamData; - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$event]['default'] = true; - $r['eventStateTeam'][$event]['default'] = true; - } - - return $r; - - } - - /** - * getStateTeamMatrix - * - */ - function getEventStateTeamMatrix() - { - - // Get property/accommodation matrix - $sql = " - SELECT C.id AS event_id, - C.name AS event_name, - C.event_code AS event_code, - S.id AS state_id, - S.code AS state_code, - S.event AS event, - T.id AS team_id, - T.team_code AS team_code, - T.name AS team_name - FROM eventmgt.event C - LEFT OUTER JOIN state_rep S ON (S.event = C.id) - LEFT OUTER JOIN team T ON (T.state = S.id) - ORDER BY C.name, S.code, T.team_code - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventStateTeamData = $stmt->fetchAll(PDO::FETCH_ASSOC); - if (count($eventStateTeamData) == 0) { - $reason[] = "No State Reps listed in the system."; - } - // *** LOOK FOR DEFAULTS *** - // Build array of Members with their accommodations - $eventStateTeam = array(); - foreach ($eventStateTeamData as $d) { - - // If event hasn't been added yet, do that. - if (!isset($eventStateTeam[$d['event_id']])) { - $eventStateTeam[$d['event_id']] = array( - 'eventID' => $d['event_id'], - 'eventName' => $d['event_name'], - 'eventCode' => $d['event_code'], - 'default' => false, - 'state' => array() - ); - } - - // If state hasn't been added yet, do that. - if ($d['state_id']) { - if (!isset($eventStateTeam[$d['event_id']]['state'][$d['state_id']])) { - $eventStateTeam[$d['event_id']]['state'][$d['state_id']] = array( - 'stateID' => $d['state_id'], - 'stateCode' => $d['state_code'], - 'team' => array() - ); - } - } - - // Add team - if ($d['team_id']) { - $eventStateTeam[$d['event_id']]['state'][$d['state_id']]['team'][$d['team_id']] = array( - 'teamID' => $d['team_id'], - 'teamName' => $d['team_name'] - ); - } - } - - return $eventStateTeam; - } - - - - /** - * Try to process controls input - * - * @return array - */ - function processControls() - { - - $r = $this->processInputData(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$event]['default'] = true; - } - - return $r; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/Reports/dataRoomBlockReport.php b/legacy/classes/data/Reports/dataRoomBlockReport.php deleted file mode 100644 index d634d7c..0000000 --- a/legacy/classes/data/Reports/dataRoomBlockReport.php +++ /dev/null @@ -1,391 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: Reports/dataRoomBlockReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -/**** - * - * NOTE: This is a data class for form input validation only. - * There is no database table assoicated with this class! - * - ****/ - - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataStates class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataRoomBlockReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataRoomBlockReport extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = ''; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Event selection - 'event' => array( - 'field' => 'event', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Event Name', - 'tip' => ' -

Select the event for which you would like to produce a report.

-

You may produce a Room Block report for only one event at a time.

- ' - ) - ), - - // State filter selection - 'state' => array( - 'field' => 'state', - 'as' => 'state_rep', - 'type' => 'pointer', - 'p_table' => 'state_rep', - 'p_field' => 'code', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'State', - 'tip' => ' -

Optionally select a State for which you would like to produce the report.

-

If no State is selected, the report will include all states.

- ' - ) - ), - - // Team filter selection - 'team' => array( - 'field' => 'team', - 'as' => 'team_code', - 'type' => 'pointer', - 'p_table' => 'team', - 'p_field' => 'team_code', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Team', - 'tip' => ' -

Optionally select a Team for which you would like to produce the report.

-

If no Team is selected, the report will include all teams.

- ' - ) - ), - - // Property filter selection - 'property' => array( - 'field' => 'property', - 'as' => 'prop_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Property', - 'tip' => ' -

Optionally select a Property for which you would like to produce the report.

-

If no Property is selected, the report will include all properties with accommodations in the matching room blocks.

- ' - ) - ), - - // Property section selection - 'property_section' => array( - 'field' => 'property_section', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Properties Section', - 'tip' => ' -

Selects display of Room Blocks listed by Property.

- ' - ) - ), - - // Assigned Selection - 'assigned_section' => array( - 'field' => 'assigned_section', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Assigned Section', - 'tip' => ' -

Selects display of Room Blocks assigned to State Reps and Teams.

- ' - ) - ), - - // Option: Show assigned quantities in addition to currently available quantities - 'option_assigned' => array( - 'field' => 'option_assigned', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Assigned Quantities', - 'tip' => ' -

When selected assigned quantities are included in addition to currently available quantities.

- ' - ) - ), - - // Output Type - 'output_type' => array( - 'field' => 'output_type', - 'as' => false, - 'type' => 'list', - 'list' => array( - 'html' => 'Display on screen', - 'print' => 'Printable Report', - 'csv' => 'Export as speadsheet (.csv)' - ), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Output Type', - 'tip' => ' -

This controls the way the report is output

-

Available options include

-
    -
  • Display on Screen - Display the report in your browser below the report request form.
  • -
  • Printable Report - Display the report in a separate browser window for output to a printer.
  • -
  • Export as Spreadsheet - Sends the report to your computer as a ".CSV" type file for import into a spreadsheet program.
  • -
-

If the Printable Report does not show, check to make sure you have permitted browser pop-ups for this Web site.

- ' - ) - ) - - ); - } - - /** - * Create Report Controls Data - * - * @return array - */ - function newControls() - { - - $r = $this->newEntry(); - - // Get event, state, team matrix and merge that with result - $eventStateTeamData = $this->getEventStateTeamMatrix(); - $r['eventStateTeam'] = $eventStateTeamData; - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['eventStateTeam'][$event]['default'] = true; - } - - return $r; - - } - - /** - * getStateTeamMatrix - * - */ - function getEventStateTeamMatrix() - { - - // Get property/accommodation matrix - $sql = " - SELECT C.id AS event_id, - C.name AS event_name, - C.event_code AS event_code, - S.id AS state_id, - S.code AS state_code, - S.event AS event, - T.id AS team_id, - T.team_code AS team_code, - T.name AS team_name - FROM eventmgt.event C - LEFT OUTER JOIN state_rep S ON (S.event = C.id) - LEFT OUTER JOIN team T ON (T.state = S.id) - ORDER BY C.name, S.code, T.team_code - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventStateTeamData = $stmt->fetchAll(PDO::FETCH_ASSOC); - if (count($eventStateTeamData) == 0) { - $reason[] = "No State Reps listed in the system."; - } -// *** LOOK FOR DEFAULTS *** - // Build array of Members with their accommodations - $eventStateTeam = array(); - foreach ($eventStateTeamData as $d) { - - // If event hasn't been added yet, do that. - if (!isset($eventStateTeam[$d['event_id']])) { - $eventStateTeam[$d['event_id']] = array( - 'eventID' => $d['event_id'], - 'eventName' => $d['event_name'], - 'eventCode' => $d['event_code'], - 'default' => false, - 'property' => array(), - 'state' => array() - ); - } - - // If state hasn't been added yet, do that. - if ($d['state_id']) { - if (!isset($eventStateTeam[$d['event_id']]['state'][$d['state_id']])) { - $eventStateTeam[$d['event_id']]['state'][$d['state_id']] = array( - 'stateID' => $d['state_id'], - 'stateCode' => $d['state_code'], - 'team' => array() - ); - } - } - - // Add team - if ($d['team_id']) { - $eventStateTeam[$d['event_id']]['state'][$d['state_id']]['team'][$d['team_id']] = array( - 'teamID' => $d['team_id'], - 'teamName' => $d['team_name'] - ); - } - } - - // Also layer in properties to event array - $sql = " - SELECT DISTINCT ON (B.event, B.member) - B.event AS event_id, B.member AS prop_id, M.name AS prop_name - FROM eventmgt.room_block B, eventmgt.member M - WHERE M.id = B.member - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $propData = $stmt->fetchAll(PDO::FETCH_ASSOC); - foreach ($propData as $p) { - $eventStateTeam[$p['event_id']]['property'][$p['prop_id']] = array( - 'propID' => $p['prop_id'], - 'propName' => $p['prop_name'] - ); - } - - - return $eventStateTeam; - } - - /** - * Try to process controls input - * - * @return array - */ - function processControls() - { - - $r = $this->processInputData(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$event]['default'] = true; - } - - return $r; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/Reports/dataRoomRequestReport.php b/legacy/classes/data/Reports/dataRoomRequestReport.php deleted file mode 100644 index 9ff4155..0000000 --- a/legacy/classes/data/Reports/dataRoomRequestReport.php +++ /dev/null @@ -1,392 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: Reports/dataRoomRequestReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -/**** - * - * NOTE: This is a data class for form input validation only. - * There is no database table assoicated with this class! - * - ****/ - - -require_once DATA_ABSTRACT; - -/** - * EventManagementRoomRequestReport class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataRoomRequestReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataRoomRequestReport extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = ''; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Event selection - 'event' => array( - 'field' => 'event', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Event Name', - 'tip' => ' -

Select the event for which you would like to produce a report.

-

You may produce an Reservations report for only one event at a time.

- ' - ) - ), - - // State selection - 'state' => array( - 'field' => 'state', - 'as' => 'state_rep', - 'type' => 'pointer', - 'p_table' => 'state_rep', - 'p_field' => 'code', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'State', - 'tip' => ' -

Optionally select a State for which you would like to produce the report.

-

If no State is selected, the report will include all states.

- ' - ) - ), - - // Team selection - 'team' => array( - 'field' => 'team', - 'as' => 'team_code', - 'type' => 'pointer', - 'p_table' => 'team', - 'p_field' => 'team_code', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Team', - 'tip' => ' -

Optionally select a Team for which you would like to produce the report.

-

If no Team is selected, the report will include all teams.

- ' - ) - ), - - // Property filter selection - 'property' => array( - 'field' => 'property', - 'as' => 'prop_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Property', - 'tip' => ' -

Optionally select a Property for which you would like to produce the report.

-

If no Property is selected, the report will include all properties with accommodations in the matching room requests.

- ' - ) - ), - - // Show pending - 'pending_select' => array( - 'field' => 'pending_select', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Show pending', - 'tip' => ' -

Selects display of pending reservtions.

- ' - ) - ), - - // Show confirmed - 'confirmed_select' => array( - 'field' => 'confirmed_select', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Show Confirmed', - 'tip' => ' -

Selects display of confirmed reservtions.

- ' - ) - ), - - // Show declined - 'declined_select' => array( - 'field' => 'declined_select', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Show Declined', - 'tip' => ' -

Selects display of declined reservtions.

- ' - ) - ), - - // Show Availabile - 'available_select' => array( - 'field' => 'available_select', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Show Available', - 'tip' => ' -

Selects display of assigned and available inventory for each room block.

- ' - ) - ), - - // Output Type - 'output_type' => array( - 'field' => 'output_type', - 'as' => false, - 'type' => 'list', - 'list' => array( - 'html' => 'Display on screen', - 'print' => 'Printable Report', - 'csv' => 'Export as speadsheet (.csv)' - ), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'quicktip' => array( - 'title' => 'Output Type', - 'tip' => ' -

This controls the way the report is output

-

Available options include

-
    -
  • Display on Screen - Display the report in your browser below the report request form.
  • -
  • Printable Report - Display the report in a separate browser window for output to a printer.
  • -
  • Export as Spreadsheet - Sends the report to your computer as a ".CSV" type file for import into a spreadsheet program.
  • -
-

If the Printable Report does not show, check to make sure you have permitted browser pop-ups for this Web site.

- ' - ) - ) - - - - ); - } - - /** - * Create Report Controls Data - * - * @return array - */ - function newControls() - { - - $r = $this->newEntry(); - - // Get event, state, team matrix and merge that with result - $eventStateTeamData = $this->getEventStateTeamMatrix(); - $r['eventStateTeam'] = $eventStateTeamData; - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['eventStateTeam'][$event]['default'] = true; - } - - return $r; - - } - - /** - * getStateTeamMatrix - * - */ - function getEventStateTeamMatrix() - { - - // Get property/accommodation matrix - $sql = " - SELECT C.id AS event_id, - C.name AS event_name, - C.event_code AS event_code, - S.id AS state_id, - S.code AS state_code, - S.event AS event, - T.id AS team_id, - T.team_code AS team_code, - T.name AS team_name - FROM eventmgt.event C - LEFT OUTER JOIN state_rep S ON (S.event = C.id) - LEFT OUTER JOIN team T ON (T.state = S.id) - ORDER BY C.name, S.code, T.team_code - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventStateTeamData = $stmt->fetchAll(PDO::FETCH_ASSOC); - if (count($eventStateTeamData) == 0) { - $reason[] = "No State Reps listed in the system."; - } - // *** LOOK FOR DEFAULTS *** - // Build array of Members with their accommodations - $eventStateTeam = array(); - foreach ($eventStateTeamData as $d) { - - // If event hasn't been added yet, do that. - if (!isset($eventStateTeam[$d['event_id']])) { - $eventStateTeam[$d['event_id']] = array( - 'eventID' => $d['event_id'], - 'eventName' => $d['event_name'], - 'eventCode' => $d['event_code'], - 'default' => false, - 'state' => array() - ); - } - - // If state hasn't been added yet, do that. - if ($d['state_id']) { - if (!isset($eventStateTeam[$d['event_id']]['state'][$d['state_id']])) { - $eventStateTeam[$d['event_id']]['state'][$d['state_id']] = array( - 'stateID' => $d['state_id'], - 'stateCode' => $d['state_code'], - 'team' => array() - ); - } - } - - // Add team - if ($d['team_id']) { - $eventStateTeam[$d['event_id']]['state'][$d['state_id']]['team'][$d['team_id']] = array( - 'teamID' => $d['team_id'], - 'teamName' => $d['team_name'] - ); - } - } - - return $eventStateTeam; - } - - - /** - * Try to process controls input - * - * @return array - */ - function processControls() - { - - $r = $this->processInputData(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$event]['default'] = true; - } - - return $r; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataAccoms.php b/legacy/classes/data/dataAccoms.php deleted file mode 100644 index 9fa360f..0000000 --- a/legacy/classes/data/dataAccoms.php +++ /dev/null @@ -1,468 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAccoms.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataAccoms class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAccoms,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataAccoms extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.accommodation'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Member name - 'member' => array( - 'field' => 'member', - 'as' => 'property', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_name', - 'p_id' => 'member_id', - 'p_where' => 'member_id in - ( - SELECT DISTINCT member_id - FROM members.member_category - WHERE category_id IN - (SELECT category_id FROM members.category WHERE accommodations) - )', - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'use' => 'ni' - ), - - // Member name - 'member_2' => array( - 'field' => 'member', - 'as' => 'property', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_name', - 'p_id' => 'member_id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'view_only' => true, - 'use' => 'gleudc' - ), - - // Accommodation Name (internal use) - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Accommodation Title (for display to users) - 'title' => array( - 'field' => 'title', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Category - Needs to be moved to a separate admin table - 'category' => array( - 'field' => 'category', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->room_category->toArray(), - 'list_keytype' => 'int', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gnieud' - ), - - // Quantity - Number of these accommodations at property - 'quant' => array( - 'field' => 'quant', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lgnieud' - ), - - // Standard # of occupants - 'occupants' => array( - 'field' => 'occupants', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'gnieud' - ), - - // Max # of occupants - 'maxoccupants' => array( - 'field' => 'maxoccupants', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'gnieud' - ), - - // Display Order (sort) - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ) - - - ); - } - - /** - * Get Accommadations list - * - * @return object containing array as sub-objects - */ - function getAccomsList($member = false) - { - - // Get any specified member listing option - default to event - $option = 'event'; - if (($membersListOption = filter_input(INPUT_GET, 'AccomsListOption', FILTER_SANITIZE_STRING))) { - $option = $membersListOption; - } - - // Get event Member from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - if ($member) { - $memberID = $member; - $option = 'member'; - } - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'TRUE'; - break; - case 'member': - if ($memberID) { - $where = "T.member = $memberID"; - } else { - $where .= "false"; - } - break; - default: - echo "Option not set"; - break; - } - - // Get list of all available Events - $accomsList = $this->getList($where, 'sort, name'); - - - if (count($accomsList) == 0) { - return false; - } - - - return $accomsList; - } - - - /** - * Get Accommodation Detail - * - * @return array - */ - function getAccomDetail() - { - - // Is there a new accom ID selected? - if (($accomID = filter_input(INPUT_GET, 'AccomID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Accom'] = $accomID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Accom'])) { - - // Otherwise, get the event ID from the session - $accomID = $_SESSION[GLM_EVENT_SESSION]['Accom']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - $accomDetail = $this->getEntry($accomID); - - return $accomDetail; - - } - - - /** - * Edit Accommodation - * - * @return array - */ - function editAccom() - { - - // Is there a new accommodaton code selected? - if (($accomID = filter_input(INPUT_GET, 'AccomID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Accom'] = $accomID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Accom'])) { - - // Otherwise, get the accommodation ID from the session - $accomID = $_SESSION[GLM_EVENT_SESSION]['Accom']; - - } else { - - // Otherwise, we don't have a accommodation id - return false; - - } - - $accomDetail = $this->editEntry($accomID); - - // echo "
".print_r($accomDetail,1)."
"; - return $accomDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); -/* - $fd = $r['fieldData']; - - // Is Start date is later than End date - if (strtotime($fd['start_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['start_date'] = 'Start date is later than end date.'; - $r['status'] = false; - } - - // Is cutoff date is later than end date - if (strtotime($fd['cutoff_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['cutoff_date'] = 'Cutoff date is later than end date.'; - $r['status'] = false; - } -*/ - return $r; - } - - /** - * Update Accommodation - * - * @return array - */ - function updateAccom() - { - - // Is there a new event code selected? - if (($accomID = filter_input(INPUT_GET, 'AccomID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Accom'] = $accomID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Accom'])) { - - // Otherwise, get the accommodation ID from the session - $accomID = $_SESSION[GLM_EVENT_SESSION]['Accom']; - - } else { - - // Otherwise, we don't have a accommodation id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($accomID); - - return $r; - - } - - /** - * Add Accommodation - * - * @return array - */ - function newAccom() - { - - $r = $this->newEntry(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Member']) && $_SESSION[GLM_EVENT_SESSION]['Member'] != false) { - $accomID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - $r['fieldData']['property']['pick_list'][$accomID]['default'] = true; - $r['fieldData']['property']['name'] = $r['fieldData']['property']['pick_list'][$accomID]['name']; - $r['fieldData']['property']['value'] = $accomID; - } - - // If succesful then set current accommodation to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Accom'] = $r['insertedID']; - } - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - /** - * Insert Accommodation - * - * @return array - */ - function insertAccom() - { - - $r = $this->insertEntry(); - - // If succesful then set current accommodation to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Accom'] = $r['insertedID']; - } - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataAddonSold.php b/legacy/classes/data/dataAddonSold.php deleted file mode 100755 index 5af00aa..0000000 --- a/legacy/classes/data/dataAddonSold.php +++ /dev/null @@ -1,290 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAddonSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataAddonSold class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAddonSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ -class EventManagementDataAddonSold extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.add_on_sold'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Ticket Order - 'ticket_order' => array( - 'field' => 'ticket_order', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'niegdl' - ), - - // Ticket Sold - 'ticket_sold' => array( - 'field' => 'ticket_sold', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'niegdl' - ), - - // Add-on Name - 'add_on_name' => array( - 'field' => 'add_on_name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Add-on type - 'add_on_type' => array( - 'field' => 'add_on_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->ticket_add_on_type->toArray(), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Add-on type name - 'add_on_type_name' => array( - 'field' => 'add_on_type_name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Unit name - 'unit_name' => array( - 'field' => 'unit_name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Unit cost number - 'unit_price_numb' => array( - 'field' => 'unit_price', - 'as' => 'unit_price_numb', - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'a' - ), - - // Unit price (money) - 'unit_price' => array( - 'field' => 'unit_price', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'lgd' - ), - - // Quantity selected - 'quant' => array( - 'field' => 'quant', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Total Price Paid - Number - 'price_paid_numb' => array( - 'field' => 'price_paid', - 'as' => 'price_paid_numb', - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'a' - ), - - // Price paid (money) - 'price_paid' => array( - 'field' => 'price_paid', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'lgd' - ) - - ); - - } - - /** - * Get Ticket Sold Add-Ons list - * - * @return object containing array as sub-objects - */ - function getAddonsSoldList($ticketSoldID = false, $where = false) - { - - // If a where clause has not been supplied, use the $TicketSoldID - Otherwise $where - if (!$where) { - - $where = 'true'; - - // Check if there's a ticket sold ID, then filter by that - $ticketSoldID = ($ticketSoldID - 0); // Make sure it's number - if ($ticketSoldID > 0) { - $where .= " AND T.ticket_sold = $ticketSoldID"; - } - - } - - $addonsSoldList = $this->getList($where, 'id'); - - return $addonsSoldList; - } - - /** - * Get Add-On Sold Detail - * - * @return array - */ - function getAddonSoldDetail($addonSoldID = false) - { - - if ($addonSoldID == false) { - - // Otherwise, we don't have an add-on id - return false; - - } - - // If the add-on sold ID is valid, get the detail - $addonSoldID = filter_input(INPUT_GET, 'AddonSoldID', FILTER_SANITIZE_NUMBER_INT); - if ($addonSoldID) { - $addonSoldDetail = $this->getEntry($addonSoldID); - - // Otherwise fail - } else { - return false; - } - - return $addonSoldDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataAddons.php b/legacy/classes/data/dataAddons.php deleted file mode 100755 index bdf6e26..0000000 --- a/legacy/classes/data/dataAddons.php +++ /dev/null @@ -1,416 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAddons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataAddons class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAddons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ -class EventManagementDataAddons extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.ticket_add_on'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Ticket - 'ticket' => array( - 'field' => 'ticket', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Ticket'], - 'use' => 'niegdl' - ), - - // Add-on Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Add-on type - 'add_on_type' => array( - 'field' => 'add_on_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->ticket_add_on_type->toArray(), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Maximum quant (0 is unlimited) - 'max_quant' => array( - 'field' => 'max_quant', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Unit name - 'unit_name' => array( - 'field' => 'unit_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Unit cost - 'unit_cost_numb' => array( - 'field' => 'unit_cost', - 'as' => 'unit_cost_numb', - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'a' - ), - - // Unit cost (money) - 'unit_cost' => array( - 'field' => 'unit_cost', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'lgd' - ) - - ); - - } - - /** - * Get Add-Ons list - * - * @return object containing array as sub-objects - */ - function getAddonsList($ticketID = false, $where = false) - { - - // If a where clause has not been supplied - if (!$where) { - - $where = 'true'; - - // Check if there's a ticket ID and filter by that ticket if there is - $ticketID = ($ticketID - 0); // Make sure it's number - if ($ticketID > 0) { - $where .= " AND T.ticket = $ticketID"; - } elseif ($_SESSION[GLM_EVENT_MGT_ADMIN]['Ticket'] > 0) { - $where .= " AND T.ticket = ".$_SESSION[GLM_EVENT_MGT_ADMIN]['Ticket']; - } - - } - - // Get list of Add-Ons - $addonsList = $this->getList($where, 'name'); - - return $addonsList; - } - - /** - * Get Add-On Detail - * - * @return array - */ - function getAddonDetail($addonID = false) - { - - // If a Add-On ID has been supplied - if ($addonID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Addon'] = $addonID; - - } elseif (($addonID = filter_input(INPUT_GET, 'AddonID', FILTER_SANITIZE_NUMBER_INT))) { - - // Otherwise if there a new add-on ID supplied via the request - $_SESSION[GLM_EVENT_SESSION]['Addon'] = $addonID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Addon'])) { - - // Otherwise, get the add-on ID from the session - $addonID = $_SESSION[GLM_EVENT_SESSION]['Addon']; - - } else { - - // Otherwise, we don't have an add-on id - return false; - - } - - $addonDetail = $this->getEntry($addonID); - - return $addonDetail; - - } - - - /** - * Edit Add-On - * - * @return array - */ - function editAddon() - { - - if (($addonID = filter_input(INPUT_GET, 'AddonID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Addon'] = $addonID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Addon'])) { - - // Otherwise, get the add-on ID from the session - $addonID = $_SESSION[GLM_EVENT_SESSION]['Addon']; - - } else { - - // Otherwise, we don't have a add-on id - return false; - - } - - $addonDetail = $this->editEntry($addonID); - - return $addonDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Add-On - * - * @return array - */ - function updateAddon() - { - - if (($addonID = filter_input(INPUT_GET, 'AddonID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Addon'] = $addonID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Addon'])) { - - // Otherwise, get the add-on ID from the session - $addonID = $_SESSION[GLM_EVENT_SESSION]['Addon']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($addonID); - - return $r; - - } - - - /** - * Add New Add-On - * - * @return array - */ - function newAddon() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert add-on - * - * @return array - */ - function insertAddon() - { - - $r = $this->insertEntry(); - - // If succesful then set current add-on to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Addon'] = $r['insertedID']; - } - - return $r; - - } - - - /** - * Delete add-on - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function addonDelete($confirm = false) - { - - // Is there a new add-on code selected? - if (($addonID = filter_input(INPUT_GET, 'AddonID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Addon'] = $addonID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Addon'])) { - - // Otherwise, get the add-on ID from the session - $addonID = $_SESSION[GLM_EVENT_SESSION]['Addon']; - - } else { - - // Otherwise, we don't have an add-on id - return false; - - } - - $addonDetail = $this->deleteEntry($addonID, $confirm); - - return $addonDetail; - - } - - /** - * Get Add-Ons Stats - * - * @return object containing array as sub-objects - */ - function getAddonsStats($where = 'true') - { - - $addonsStats = $this->getStats($where); - - return $addonsStats; - } - - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataAmenities.php b/legacy/classes/data/dataAmenities.php deleted file mode 100644 index 3f50b0f..0000000 --- a/legacy/classes/data/dataAmenities.php +++ /dev/null @@ -1,486 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAmenities.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataAmenities class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAmenities.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataAmenities extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.amenities'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Affiliation (insert) - what type of entities is this Amenity for - 'affiliation_type' => array( - 'field' => 'affiliation_type', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Affiliation (view) - 'affiliation_type_2' => array( - 'field' => 'affiliation_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->reference_type_numb->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gled' - ), - - // Amenity affiliation (non-standard pointer) - // Points to various tables depending on the "Affiliation type" value - 'owner' => array( - 'field' => 'owner', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Amenity affiliation (non-standard pointer) - // Points to various tables depending on the "Affiliation To" value - 'owner_2' => array( - 'field' => 'owner', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gled' - ), - - // Amenity Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Quantity / Size - 'quant' => array( - 'field' => 'quant', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Amenity Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Get an array of Amenities for a particular affiliated entity - * - * $listOption Optional Type of affiliation - see config.ini 'reference_type' - * If not supplied will check for AmenitiesListOption GET value - * $whereRequest If supplied, use as WHERE clause instead - * - * @return object containing array as sub-objects - */ - function getAmenities($listOption = false, $whereRequest = false) - { - - $where = ''; - - // If there's a specific whereRequest, use that only - if ($whereRequest) { - $where = $whereRequest; - } else { - - // Get Event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get Member ID from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - // Get any specified listing option - if ($listOption != '') { - $option = $listOption; - - // Otheriwse check for list options provided in request - } elseif (($AmenitiesListOption = filter_input(INPUT_GET, 'AmenitiesListOption', FILTER_SANITIZE_STRING))) { - $option = $AmenitiesListOption; - } - - // Include selection of proper affiliation type - switch ($option) { - case 'member': - if ($memberID) { - $where .= "T.affiliation_type = ".$this->config->reference_type->property - ."AND owner = $memberID\n"; - } else { - $where .= "false"; - } - break; - } - } - - // Get the Amenities - return false if none found - $amenitiesList = $this->getList($where, 'name'); - if (!is_array($amenitiesList) || count($amenitiesList) == 0) { - return false; - } - - // Get affiliation type for each Amenity - reset($amenitiesList); - while( list($key, $val) = each( $amenitiesList ) ) { - - $aData = $this->getAffiliate( - $val['affiliation_type']['value'], - $val['owner'] - ); - - if ($aData) { - $amenitiesList[$key]['affiliation_type_name'] = $aData['applied_to_name']; - $amenitiesList[$key]['owner_name'] = $aData['owner_name']; - } - - } // Get Amenities affiliation - - return $amenitiesList; - } - - /** - * Get Amenity Detail - * - * @return array - */ - function getAmenityDetail() - { - - // Is there a new Amenity ID supplied? - if (!($amenityID = filter_input(INPUT_GET, 'AmenityID', FILTER_SANITIZE_NUMBER_INT))) { - // We don't have an amenity id - return false; - - } - - $amenityDetail = $this->getEntry($amenityID); - - // Get owner data - $aData = $this->getAffiliate( - $amenityDetail['affiliation_type']['value'], - $amenityDetail['owner'] - ); - - - if ($aData) { - $amenityDetail = array_merge($amenityDetail, $aData); - } - - return $amenityDetail; - - } - - /** - * Edit Amenity - * - * @return array - */ - function editAmenity() - { - - // Is there a new amenity ID supplied? - if (!($amenityID = filter_input(INPUT_GET, 'AmenityID', FILTER_SANITIZE_NUMBER_INT))) { - // We don't have an amenity id - return false; - - } - - $amenityDetail = $this->editEntry($amenityID); - - // Get owner data - $aData = $this->getAffiliate( - $amenityDetail['affiliation_type']['value'], - $amenityDetail['owner'] - ); - - if ($aData) { - $amenityDetail = array_merge($amenityDetail, $aData); - } - - return $amenityDetail; - - } - - /** - * Update Amenity - * - * @return array - */ - function updateAmenity() - { - - // Is there a new amenity ID supplied? - if (!($amenityID = filter_input(INPUT_GET, 'AmenityID', FILTER_SANITIZE_NUMBER_INT))) { - if (!($amenityID = filter_input(INPUT_POST, 'AmenityID', FILTER_SANITIZE_NUMBER_INT))) { - echo "::::::"; - // We don't have an Amenity id - return false; - } - } - - // Try to update this data - $r = $this->updateEntry($amenityID); - - // Get owner data - $aData = $this->getAffiliate( - $amenityDetail['affiliation_type']['value'], - $amenityDetail['owner'] - ); - - if ($aData) { - $amenityDetail = array_merge($amenityDetail, $aData); - } - - return $r; - - } - - /** - * New Amenity Affiliation - * - * @return array - */ - function newAmenityAffiliation($r) - { - - // Check for specified Amenity type - // We need to check for name rather than number because that's what the js is sending us - if (!isset($_REQUEST['amenity_type_code']) || $_REQUEST['amenity_type_code'] == '') { - return false; - } - - // Get type and affiliation - $amenityType = trim($_REQUEST['amenity_type_code']); - $affiliateID = false; - - switch ($amenityType) { - case 'property': - $amenityTypeNumber = $this->config->reference_type->property; - if (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - $affiliateID = ($_SESSION[GLM_EVENT_SESSION]['Member'] - 0); - $amenityTypeName = 'Property'; - $aTable = 'eventmgt.member'; - $aField = 'name'; - $aFieldShort = $aField; - } - break; - } - - // If no match on Amenity type, then fail - if ($affiliateID == false) { - return false; - } - - // Get affiliate data - $sql = "SELECT $aField AS name, - $aFieldShort AS short_name - FROM $aTable - WHERE id = $affiliateID - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $aData = $stmt->fetch(PDO::FETCH_ASSOC); - - // if no valid affiliate data - fail - if (!$aData) { - return false; - } - - $r['fieldData']['amenity_type_name'] = $amenityTypeName; - $r['fieldData']['amenity_type_code'] = $amenityType; - $r['fieldData']['amenity_type'] = $amenityTypeNumber; - $r['fieldData']['affiliation_name'] = $aData['name']; - $r['fieldData']['affiliation'] = $affiliateID; - $r['fieldData']['affiliation_short'] = $aData['short_name']; - - return $r; - - } - - function newAmenity() - { - - $r = $this->newEntry(); - - $r = $this->newAmenityAffiliation($r); - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - - /** - * Insert Amenity - * - * @return array - */ - function insertAmenity() - { - - $r = $this->insertEntry(); - $r = $this->newAmenityAffiliation($r); - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - /** - * Get Affiliate table and name - * - */ - function getAffiliate($type, $affiliation) - { - - // Deterimine Affliate table - $aTable = ''; - $aField = ''; - switch ($type) { - case $this->config->reference_type->property: - $aType = 'Property'; - $aTable = 'eventmgt.member'; - $aField = 'name'; - $aFieldShort = $aField; - break; - } - - $r = false; - - // If we have a good affiliate relationship - if ($aField != '') { - - $sql = "SELECT $aField AS name, - $aFieldShort AS short_name - FROM $aTable - WHERE id = $affiliation - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $aData = $stmt->fetch(PDO::FETCH_ASSOC); - - if ($aData) { - $r = array( - 'amenity_type_name' => $aType, - 'affiliation_name' => $aData['name'], - 'affiliation_short' => $aData['short_name'] - ); - } - } - - return $r; - - } - -} - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataAttendance.php b/legacy/classes/data/dataAttendance.php deleted file mode 100644 index e76331d..0000000 --- a/legacy/classes/data/dataAttendance.php +++ /dev/null @@ -1,218 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAttendance.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataAttendance class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataAttendance,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ -class EventManagementDataAttendance extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.attendance'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Member ID for adding an entry - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'use' => 'nid' - ), - - // Member ID - 'member_id' => array( - 'field' => 'member', - 'as' => 'member_id', - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Attendance record name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Attendance notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Date - 'attendance_date' => array( - 'field' => 'attendance_date', - 'as' => false, - 'type' => 'date', - 'required' => false, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Actual attendance entrance state time - 'entrance_start_time' => array( - 'field' => 'entrance_start_time', - 'as' => false, - 'type' => 'time', - 't_detailed_minutes' => true, - 'required' => false, - 'unique' => false, - 'default' => date('H:i'), - 'use' => 'a' - ), - - // Actual attendance entrance end time - 'entrance_end_time' => array( - 'field' => 'entrance_end_time', - 'as' => false, - 'type' => 'time', - 't_detailed_minutes' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Actual performance start time - 'perf_start_time' => array( - 'field' => 'perf_start_time', - 'as' => false, - 'type' => 'time', - 't_detailed_minutes' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Actual performance end time - 'perf_end_time' => array( - 'field' => 'perf_end_time', - 'as' => false, - 'type' => 'time', - 't_detailed_minutes' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Check for other field related issues - * - * Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - return $r; - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataBookings.php b/legacy/classes/data/dataBookings.php deleted file mode 100644 index c613207..0000000 --- a/legacy/classes/data/dataBookings.php +++ /dev/null @@ -1,252 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataBookings.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataBookings class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataBookings.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataBookings extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.team_property'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Team - 'team' => array( - 'field' => 'team', - 'as' => 'team', - 'type' => 'pointer', - 'p_table' => 'eventmgt.team', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Property - 'property' => array( - 'field' => 'property', - 'as' => 'property', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Event - 'conv' => array( - 'field' => 'conv', - 'as' => 'event', - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Start Date - 'start' => array( - 'field' => 'start', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Stop Date - 'stop' => array( - 'field' => 'stop', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Get Bookings list - * - * @return object containing array as sub-objects - */ - function getBookingsList() - { - - // Get event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get member ID from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - // Get team ID from session - if available - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - // Get any specified bookings listing option - default to event - $option = 'event'; - if (($bookingsListOption = filter_input(INPUT_GET, 'BookingsListOption', FILTER_SANITIZE_STRING))) { - $option = $bookingsListOption; - } - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'TRUE'; - break; - case 'event': - if (!$eventID) { - return false; - } - $where = "T.conv = $eventID"; - break; - case 'member': - if (!$memberID) { - return false; - } - $where = "T.property = $memberID"; - break; - case 'team': - if (!$teamID) { - return false; - } - $where = "T.team = $teamID"; - break; - default: - echo "Option not set"; - break; - } - - // Get list of Bookings - $bookingsList = $this->getList($where); - - return $bookingsList; - } - - /** - * Get Booking Detail - * - * @return array - */ - function getBookingDetail() - { - - // Is there a new team code selected? - if (($bookingID = filter_input(INPUT_GET, 'BookingID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Booking'] = $teamID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Booking'])) { - - // Otherwise, get the booking ID from the session - $bookingID = $_SESSION[GLM_EVENT_SESSION]['Booking']; - - } else { - - // Otherwise, we don't have a booking id - return false; - - } - - $bookingDetail = $this->getEntry($bookingID); - - return $bookingDetail; - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataContacts.php b/legacy/classes/data/dataContacts.php deleted file mode 100644 index de1ba1b..0000000 --- a/legacy/classes/data/dataContacts.php +++ /dev/null @@ -1,862 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataContacts.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataContacts class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataContacts.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataContacts extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.res_contact'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Delete restrictions - * - * @var $ini - * @access public - */ - public $delRestrictions = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - // Define fields for this data table - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Contact Type - 'contact_type' => array( - 'field' => 'contact_type', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Contact Type - 'contact_type_2' => array( - 'field' => 'contact_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->reference_type_numb->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gled' - ), - - // Contact affiliation (non-standard pointer) - // Points to various tables depending on the Contact Type - 'affiliation' => array( - 'field' => 'affiliation', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Contact affiliation (non-standard pointer) - // Points to various tables depending on the Contact Type - 'affiliation_2' => array( - 'field' => 'affiliation', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gled' - ), - - // Contact First Name - 'fname' => array( - 'field' => 'fname', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact Last Name - 'lname' => array( - 'field' => 'lname', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Organization - 'org' => array( - 'field' => 'org', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact Address Line 1 - 'addr1' => array( - 'field' => 'addr1', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact Address Line 2 - 'addr2' => array( - 'field' => 'addr2', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact City - 'city' => array( - 'field' => 'city', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact State - 'state' => array( - 'field' => 'state', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->states->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 'MI', - 'use' => 'a' - ), - - // Contact Country - 'country' => array( - 'field' => 'country', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->countries->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact ZIP - 'zip' => array( - 'field' => 'zip', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Office Phone - 'office_phone' => array( - 'field' => 'office_phone', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact Mobile Phone - 'mobile_phone' => array( - 'field' => 'mobile_phone', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Alternate Phone - 'alt_phone' => array( - 'field' => 'alt_phone', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // FAX - 'fax' => array( - 'field' => 'fax', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // E-Mail - 'email' => array( - 'field' => 'email', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Optional Login ID - 'login_id' => array( - 'field' => 'login_id', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Alternate E-Mail - 'alt_email' => array( - 'field' => 'alt_email', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact create_date - 'create_date' => array( - 'field' => 'create_date', - 'as' => false, - 'type' => 'date', - 'required' => false, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Active flag - 'active' => array( - 'field' => 'active', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => true, - 'use' => 'a' - ), - - // Password - encrypted - 'password' => array( - 'field' => 'password', - 'as' => false, - 'type' => 'password', - 'pw_type' => 'strong', - 'required' => false, - 'unique' => false, - 'default' => false, - 'minLength' => 8, - 'maxLength' => 16, - 'no_update_when_blank' => true, - 'use' => 'a' - ), - - // User Rights - 'user_rights' => array( - 'field' => 'user_rights', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->permissions->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 0, // Note that this is a bitmap value - 'use' => 'a' - ) - - ); - - // Specify any delete restrictions - $this->delRestrictions = false; - - } - - /** - * Get an array of contacts for a particular affiliated entity - * - * $listOption Optional Type of affiliation - see config.ini 'reference_type' - * If not supplied will check for ContactsListOption GET value - * $whereRequest If supplied, use as WHERE clause instead - * - * @return object containing array as sub-objects - */ - function getContacts($listOption = false, $whereRequest = false) - { - - $where = ''; - - // If there's a specific whereRequest, use that only - if ($whereRequest) { - $where = $whereRequest; - } else { - - // Get Event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get Member ID from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - // Get State ID from session - if available - $stateID = $_SESSION[GLM_EVENT_SESSION]['State']; - - // Get team ID from session - if available - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - // Get any specified event listing option - default to active - if ($listOption != '') { - $option = $listOption; - - // Otheriwse check for list options provided in request - } elseif (($contactsListOption = filter_input(INPUT_GET, 'ContactsListOption', FILTER_SANITIZE_STRING))) { - $option = $contactsListOption; - } - - // Include selection of proper contact type - switch ($option) { - case 'event': - if ($eventID) { - $where .= "T.contact_type = ".$this->config->reference_type->event - ."AND affiliation = $eventID"; - } else { - $where .= "false"; - } - break; - case 'member': - if ($memberID) { - $where .= "T.contact_type = ".$this->config->reference_type->member - ."AND affiliation = $memberID\n"; - } else { - $where .= "false"; - } - break; - case 'state': - if ($stateID) { - $where .= "T.contact_type = ".$this->config->reference_type->state - ."AND affiliation = $stateID\n"; - } else { - $where .= "false"; - } - break; - case 'team': - if ($teamID) { - $where .= "T.contact_type = ".$this->config->reference_type->team - ."AND affiliation = $teamID\n"; - } else { - $where .= "false"; - } - break; - } - - } - - // Get the contacts - return false if none found - $contactsList = $this->getList($where, 'org, lname, fname'); - if (!is_array($contactsList) || count($contactsList) == 0) { - return false; - } - - // Get contact affiliation for each contact - reset($contactsList); - while( list($key, $val) = each( $contactsList ) ) { - - $aData = $this->getAffiliate( - $val['contact_type']['value'], - $val['affiliation'] - ); - - if ($aData) { - $contactsList[$key]['contact_type_name'] = $aData['contact_type_name']; - $contactsList[$key]['affiliation'] = $aData['affiliation_name']; - $contactsList[$key]['affiliation_short'] = $aData['affiliation_short']; - } - - } // Get contact affiliation - - $r = array( - 'contact_list' => $contactsList, - 'type' => $t - ); - - return $r; - } - - /** - * Get Contact Detail - * - * @return array - */ - function getContactDetail($contactID = false) - { - - // If a contact ID is supplied - if ($contactID) { - // nothing to do here - - // Is there a new event code selected? - } elseif (($contactID = filter_input(INPUT_GET, 'ContactID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Contact'] = $contactID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Contact'])) { - - // Otherwise, get the contact ID from the session - $contactID = $_SESSION[GLM_EVENT_SESSION]['Contact']; - - } else { - - // Otherwise, we don't have an contact id - return false; - - } - - $contactDetail = $this->getEntry($contactID); - - // Get affiliate data - $aData = $this->getAffiliate( - $contactDetail['contact_type']['value'], - $contactDetail['affiliation'] - ); - if ($aData) { - $contactDetail = array_merge($contactDetail, $aData); - } - - return $contactDetail; - - } - - - /** - * Edit Contact - * - * @return array - */ - function editContact() - { - - // Check for contact ID in session - if (isset($_SESSION[GLM_EVENT_SESSION]['Contact'])) { - $contactID = $_SESSION[GLM_EVENT_SESSION]['Contact']; - } else { - return false; - } - - $contactDetail = $this->editEntry($contactID); - - // Get affiliate data - $aData = $this->getAffiliate( - $contactDetail['contact_type']['value'], - $contactDetail['affiliation'] - ); - if ($aData) { - $contactDetail = array_merge($contactDetail, $aData); - } - - return $contactDetail; - - } - - /** - * Update Contact - * - * @return array - */ - function updateContact() - { - - // Check for contact ID in session - if (isset($_SESSION[GLM_EVENT_SESSION]['Contact'])) { - $contactID = $_SESSION[GLM_EVENT_SESSION]['Contact']; - } else { - return false; - } - - // Try to update this data - $r = $this->updateEntry($contactID); - - // Get affiliate data - $aData = $this->getAffiliate( - $r['fieldData']['contact_type']['value'], - $r['fieldData']['affiliation'] - ); - - if ($aData) { - $r['fieldData'] = array_merge($r['fieldData'], $aData); - } - - - return $r; - - } - - /** - * New Contact - * - * @return array - */ - function newContactAffiliation($r) - { - - // Check for specified contact type - // We need to check for name rather than number because that's what the js is sending us - if (!isset($_REQUEST['contact_type_code']) || $_REQUEST['contact_type_code'] == '') { - - $this->addDebug("dataContacts.inc", 'newContactAffiliation()', 'No contact_type_code supplied.'); - - return false; - } - - // Get type and affiliation - $contactType = trim($_REQUEST['contact_type_code']); - $affiliateID = false; - - switch ($contactType) { - case 'event': - $contactTypeNumber = $this->config->reference_type->event; - if (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - $affiliateID = ($_SESSION[GLM_EVENT_SESSION]['Event'] - 0); - $contactTypeName = $this->config->reference_type_numb->$contactTypeNumber; - $aTable = 'event'; - $aField = 'name'; - $aFieldShort = 'event_code'; - } - break; - case 'member': - $contactTypeNumber = $this->config->reference_type->member; - if (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - $affiliateID = ($_SESSION[GLM_EVENT_SESSION]['Member'] - 0); - $contactTypeName = $this->config->reference_type_numb->$contactTypeNumber; - $aTable = 'eventmgt.member'; - $aField = 'name'; - $aFieldShort = $aField; - } - break; - case 'state': - $contactTypeNumber = $this->config->reference_type->state; - if (isset($_SESSION[GLM_EVENT_SESSION]['State'])) { - $affiliateID = ($_SESSION[GLM_EVENT_SESSION]['State'] - 0); - $contactTypeName = $this->config->reference_type_numb->$contactTypeNumber; - $aTable = 'state_rep'; - $aField = 'code'; - $aFieldShort = $aField; - } - break; - case 'team': - $contactTypeNumber = $this->config->reference_type->team; - if (isset($_SESSION[GLM_EVENT_SESSION]['Team'])) { - $affiliateID = ($_SESSION[GLM_EVENT_SESSION]['Team'] - 0); - $contactTypeName = $this->config->reference_type_numb->$contactTypeNumber; - $aTable = 'team'; - $aField = 'name'; - $aFieldShort = 'team_code'; - } - break; - } - - // If no match on contact type, then fail - if ($affiliateID == false) { - return false; - } - - // Get affiliate data - $sql = "SELECT $aField AS name, - $aFieldShort AS short_name - FROM $aTable - WHERE id = $affiliateID - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $aData = $stmt->fetch(PDO::FETCH_ASSOC); - - // if no valid affiliate data - fail - if (!$aData) { - return false; - } - - $r['fieldData']['contact_type_name'] = $contactTypeName; - $r['fieldData']['contact_type_code'] = $contactType; - $r['fieldData']['contact_type'] = $contactTypeNumber; - $r['fieldData']['affiliation_name'] = $aData['name']; - $r['fieldData']['affiliation'] = $affiliateID; - $r['fieldData']['affiliation_short'] = $aData['short_name']; - - return $r; - - } - function newContact() - { - - $r = $this->newEntry(); - $r = $this->newContactAffiliation($r); - - return $r; - - } - - - /** - * Insert Contact - * - * @return array - */ - function insertContact() - { - - $r = $this->insertEntry(); - $r = $this->newContactAffiliation($r); - - // If succesful then set current contact to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Contact'] = $r['insertedID']; - } - - return $r; - - } - - /** - * Get Affiliate table and name - * - */ - function getAffiliate($type, $affiliation) - { - - // Deterimine Affliate table - $aTable = ''; - $aField = ''; - switch ($type) { - case $this->config->reference_type->event: - $aType = 'Event'; - $aTable = 'event'; - $aField = 'name'; - $aFieldShort = 'event_code'; - break; - case $this->config->reference_type->member: - $aType = 'Member'; - $aTable = 'eventmgt.member'; - $aField = 'name'; - $aFieldShort = $aField; - break; - case $this->config->reference_type->state: - $aType = 'State Rep'; - $aTable = 'state_rep'; - $aField = 'code'; - $aFieldShort = $aField; - break; - case $this->config->reference_type->team: - $aType = 'Team'; - $aTable = 'team'; - $aField = 'name'; - $aFieldShort = 'team_code'; - break; - } - - $r = false; - - // If we have a good affiliate relationship - if ($aField != '') { - - $sql = "SELECT $aField AS name, - $aFieldShort AS short_name - FROM $aTable - WHERE id = $affiliation - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $aData = $stmt->fetch(PDO::FETCH_ASSOC); - - if ($aData) { - $r = array( - 'contact_type_name' => $aType, - 'affiliation_name' => $aData['name'], - 'affiliation_short' => $aData['short_name'] - ); - } - } - - return $r; - - } - - - /** - * Delete Contact - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function contactDelete($confirm = false) - { - - // Is there a new contact code selected? - if (($contactID = filter_input(INPUT_GET, 'ContactID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Contact'] = $contactID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Contact'])) { - - // Otherwise, get the contact ID from the session - $contactID = $_SESSION[GLM_EVENT_SESSION]['Contact']; - - } else { - - // Otherwise, we don't have an contact id - return false; - - } - - $contactDetail = $this->deleteEntry($contactID, $confirm); - - // Get affiliate data - $aData = $this->getAffiliate( - $contactDetail['contact_type']['value'], - $contactDetail['affiliation'] - ); - if ($aData) { - $contactDetail = array_merge($contactDetail, $aData); - } - - return $contactDetail; - - } - - - -} - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataDivisions.php b/legacy/classes/data/dataDivisions.php deleted file mode 100644 index fb4aaa9..0000000 --- a/legacy/classes/data/dataDivisions.php +++ /dev/null @@ -1,353 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataDivisions.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataDivisions class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataDivisions.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataDivisions extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.division'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Event selection - 'conv' => array( - 'field' => 'conv', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'nid' - ), - - // Event Name display - 'conv_view' => array( - 'field' => 'conv', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Division Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Get Divisions list - * - * @return object containing array as sub-objects - */ - function getDivisionsList() - { - - // Get event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get any specified division listing option - default to event - $option = 'event'; - if (($divisionsListOption = filter_input(INPUT_GET, 'DivisionsListOption', FILTER_SANITIZE_STRING))) { - $option = $divisionsListOption; - } - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'TRUE'; - break; - case 'event': - if (!$eventID) { - return false; - } - $where = "T.conv = $eventID"; - break; - default: - echo "Option not set"; - break; - } - - // Get list of Divisions - $divisionsList = $this->getList($where, 'name'); - - return $divisionsList; - } - - /** - * Get State Division - * - * @return array - */ - function getDivisionDetail() - { - - // Is there a new Division code selected? - if (($divisionID = filter_input(INPUT_GET, 'DivisionID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Division'] = $divisionID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Division'])) { - - // Otherwise, get the division ID from the session - $divisionID = $_SESSION[GLM_EVENT_SESSION]['Division']; - - } else { - - // Otherwise, we don't have a division id - return false; - - } - - $divisionDetail = $this->getEntry($divisionID); - - return $divisionDetail; - - } - - - /** - * Edit Division - * - * @return array - */ - function editDivision() - { - - if (($divisionID = filter_input(INPUT_GET, 'DivisionID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Division'] = $stateID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Division'])) { - - // Otherwise, get the division ID from the session - $divisionID = $_SESSION[GLM_EVENT_SESSION]['Division']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - $divisionDetail = $this->editEntry($divisionID); - - return $divisionDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Division - * - * @return array - */ - function updateDivision() - { - - if (($divisionID = filter_input(INPUT_GET, 'DivisionID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Division'] = $stateID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Division'])) { - - // Otherwise, get the dvision ID from the session - $divisionID = $_SESSION[GLM_EVENT_SESSION]['Division']; - - } else { - - // Otherwise, we don't have a divisio id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($divisionID); - - return $r; - - } - - - /** - * Add New Division - * - * @return array - */ - function newDivision() - { - - $r = $this->newEntry(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $eventID = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$eventID]['default'] = true; - } - - return $r; - - } - - /** - * Insert Division - * - * @return array - */ - function insertDivision() - { - - $r = $this->insertEntry(); - - // If succesful then set current division to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Division'] = $r['insertedID']; - } - - return $r; - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataEntrances.php b/legacy/classes/data/dataEntrances.php deleted file mode 100644 index 034eed8..0000000 --- a/legacy/classes/data/dataEntrances.php +++ /dev/null @@ -1,523 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataEntrances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataEntrances class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataEntrances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataEntrances extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.entrance'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Member ID for adding entrances - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'use' => 'nid' - ), - - // Member Name display - 'member_view' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Entrance Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 1 - 'addr1' => array( - 'field' => 'addr1', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 2 - 'addr2' => array( - 'field' => 'addr2', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // City - 'city' => array( - 'field' => 'city', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // State - 'state' => array( - 'field' => 'state', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->states->toArray(), - 'required' => true, - 'unique' => false, - 'default' => 'MI', - 'use' => 'a' - ), - - // Country - 'country' => array( - 'field' => 'country', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->countries->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // ZIP - 'zip' => array( - 'field' => 'zip', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Latitude - 'lat' => array( - 'field' => 'lat', - 'as' => false, - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => 45, - 'use' => 'a' - ), - - // Longitude - 'lon' => array( - 'field' => 'lon', - 'as' => false, - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => -84, - 'use' => 'a' - ), - - // Member phone - From main member db - 'phone' => array( - 'field' => 'phone', // ID in member table is same as in eventmgt.member - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Colors for tickets and display - 'color' => array( - 'field' => 'color', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->color->toArray(), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Sort order - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 999, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - - ); - } - - /** - * Get Entrancess list - * - * @return object containing array as sub-objects - */ - function getEntrancesList($memberID = false, $where = false) - { - - // If a where clause has not been supplied - if (!$where) { - - $where = 'true'; - - // Check if there's a member ID and filter by that member if there is - $memberID = ($memberID - 0); // Make sure it's number - if ($memberID > 0) { - $where .= " AND T.member = $memberID"; - } elseif ($_SESSION[GLM_EVENT_MGT_ADMIN]['Member'] > 0) { - $where .= " AND T.member = ".$_SESSION[GLM_EVENT_MGT_ADMIN]['Member']; - } - - } - - // Get list of Entrances - $entrancesList = $this->getList($where, 'sort, name'); - - return $entrancesList; - } - - /** - * Get Entrance Detail - * - * @return array - */ - function getEntranceDetail($entranceID = false) - { - - // If a entrance ID has been supplied - if ($entranceID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Entrance'] = $entranceID; - - } elseif (($entranceID = filter_input(INPUT_GET, 'EntranceID', FILTER_SANITIZE_NUMBER_INT))) { - - // Otherwise if there a new entrance ID supplied via the request - $_SESSION[GLM_EVENT_SESSION]['Entrance'] = $entranceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Entrance'])) { - - // Otherwise, get the event ID from the session - $entranceID = $_SESSION[GLM_EVENT_SESSION]['Entrance']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - $entranceDetail = $this->getEntry($entranceID); - - return $entranceDetail; - - } - - - /** - * Edit Entrance - * - * @return array - */ - function editEntrance() - { - - if (($entranceID = filter_input(INPUT_GET, 'EntranceID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Entrance'] = $entranceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Entrance'])) { - - // Otherwise, get the entrance ID from the session - $entranceID = $_SESSION[GLM_EVENT_SESSION]['Entrance']; - - } else { - - // Otherwise, we don't have a entrance id - return false; - - } - - $entranceDetail = $this->editEntry($entranceID); - - return $entranceDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Entrance - * - * @return array - */ - function updateEntrance() - { - - if (($entranceID = filter_input(INPUT_GET, 'EntranceID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Entrance'] = $entranceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Entrance'])) { - - // Otherwise, get the entrance ID from the session - $entranceID = $_SESSION[GLM_EVENT_SESSION]['Entrance']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($entranceID); - - return $r; - - } - - - /** - * Add New Entrance - * - * @return array - */ - function newEntrance() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert entrance - * - * @return array - */ - function insertEntrance() - { - - $r = $this->insertEntry(); - - // If succesful then set current entrance to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Entrance'] = $r['insertedID']; - } - - return $r; - - } - - - /** - * Delete entrance - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function entranceDelete($confirm = false) - { - - // Is there a new entrance code selected? - if (($entranceID = filter_input(INPUT_GET, 'EntranceID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Entrance'] = $entranceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Entrance'])) { - - // Otherwise, get the entrance ID from the session - $entranceID = $_SESSION[GLM_EVENT_SESSION]['Entrance']; - - } else { - - // Otherwise, we don't have an entrance id - return false; - - } - - $entranceDetail = $this->deleteEntry($entranceID, $confirm); - - return $entranceDetail; - - } - - /** - * Get Entrances Stats - * - * @return object containing array as sub-objects - */ - function getEntrancesStats($where = 'true') - { - - $entrancesStats = $this->getStats($where); - - return $entrancesStats; - } - - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataEvents.php b/legacy/classes/data/dataEvents.php deleted file mode 100644 index ecb55e4..0000000 --- a/legacy/classes/data/dataEvents.php +++ /dev/null @@ -1,841 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataEvents.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataEvents class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataEvents,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - - - */ -class EventManagementDataEvents extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.event'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - see documentation - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged', - 'quicktip' => '' - - ), - - // Name of event - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // General description of event - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description of dates for this event - 'event_dates' => array( - 'field' => 'event_dates', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Active flag - 'active' => array( - 'field' => 'active', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // event/Event Code - 'event_code' => array( - 'field' => 'event_code', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lgnie' - ), - - // Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Team Event - 'team_event' => array( - 'field' => 'team_event', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), -/* Not using now - // Minimim number of nights stay - 'days' => array( - 'field' => 'days', - 'as' => false, - 'type' => 'integer', - 'minValue' => 1, - 'maxValue' => false, - 'required' => true, - 'unique' => false, - 'default' => 1, - 'use' => 'a' - ), - - // Minimum number of adults - 'min_adults' => array( - 'field' => 'min_adults', - 'as' => false, - 'type' => 'integer', - 'minValue' => 1, - 'maxValue' => false, - 'required' => true, - 'unique' => false, - 'default' => 1, - 'use' => 'a' - ), -*/ - - // Front end reservations by Event Code rather than displaying for selection - 'reserve_by_code' => array( - 'field' => 'reserve_by_code', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // May book multiple rooms - 'multiple_rooms' => array( - 'field' => 'multiple_rooms', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), -/* - // Maximum number of rooms that may be booked a once - 'max_rooms' => array( - 'field' => 'max_rooms', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), -*/ - // Start Date - 'start_date' => array( - 'field' => 'start_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('1/1/'.date('Y').' +4 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // End Date - 'end_date' => array( - 'field' => 'end_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('1/1/'.date('Y').' +4 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Last date event may be booked - 'cutoff_date' => array( - 'field' => 'cutoff_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('1/1/'.date('Y').' +4 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Use Required Stay - 'req_stay' => array( - 'field' => 'req_stay', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Must arrive by date - 'req_stay_arrive' => array( - 'field' => 'req_stay_arrive', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('1/1/'.date('Y').' +4 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Must depart no earlier than date - This is the date after the last required night's stay. - 'req_stay_depart' => array( - 'field' => 'req_stay_depart', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('1/1/'.date('Y').' +4 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Required Stay Notices - 'req_stay_notice' => array( - 'field' => 'req_stay_notice', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Date after which team inventory becomes available to anyone - 'open_res_date' => array( - 'field' => 'open_res_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('1/1/'.date('Y').' +4 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Confirmation hours (property must confirm by ...) - 'conf_hours' => array( - 'field' => 'conf_hours', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 48, - 'use' => 'a' - ), - - // Inventory hold time in minutes - 'inven_hold_time' => array( - 'field' => 'inven_hold_time', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 30, - 'use' => 'a' - ), - - // Sort - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 999, - 'use' => 'a' - ), - - // Address Line 1 - 'addr1' => array( - 'field' => 'addr1', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 2 - 'addr2' => array( - 'field' => 'addr2', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // City - 'city' => array( - 'field' => 'city', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // State - 'state' => array( - 'field' => 'state', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->states->toArray(), - 'required' => true, - 'unique' => false, - 'default' => 'MI', - 'use' => 'a' - ), - - // ZIP/Postal Code - 'zip' => array( - 'field' => 'zip', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Country - 'country' => array( - 'field' => 'country', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->countries->toArray(), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Latitude - 'lat' => array( - 'field' => 'lat', - 'as' => false, - 'type' => 'latitude', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lgnieudc' - ), - - // Longitude - 'lon' => array( - 'field' => 'lon', - 'as' => false, - 'type' => 'longitude', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lgnieudc' - ), - - // Central_payment - 'central_payment' => array( - 'field' => 'central_payment', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Central Payment E-Mail - 'central_payment_email' => array( - 'field' => 'central_payment_email', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Host Property - 'host_property' => array( - 'field' => 'host_property', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_name', - 'p_id' => 'member_id', - 'p_where' => 'member_id in - ( - SELECT DISTINCT member_id - FROM members.member_category - WHERE category_id IN - (SELECT category_id FROM members.category WHERE accommodations) - )', - 'p_blank' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'nieu' - ), - - // Host Property - 'host_property_2' => array( - 'field' => 'host_property', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_name', - 'p_id' => 'member_id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gldc' - ), - - // Reservation Policy - 'res_policy' => array( - 'field' => 'res_policy', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Cancelation Policy - 'can_policy' => array( - 'field' => 'can_policy', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Payment Policy - 'pmt_policy' => array( - 'field' => 'pmt_policy', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Message to display at bottom of cart - 'cart_text' => array( - 'field' => 'cart_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Reservation Message to Guest - 'res_msg' => array( - 'field' => 'res_msg', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Confirmation Message to Guest - 'conf_msg' => array( - 'field' => 'conf_msg', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - - } - - - /** - * Get Events list - * - * @param string type of events list - * - * @return object containing array as sub-objects - */ - function getEventsList($whereRequest = false) - { - $where = ''; - - // If there's a specific whereRequest, use that only - if ($whereRequest) { - - $where = $whereRequest; - - } else { - - // Get member ID from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - // Get team ID from session - if available - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - // Get any specified event listing option - default to active - $option = 'active'; - if (($eventsListOption = filter_input(INPUT_GET, 'EventsListOption', FILTER_SANITIZE_STRING))) { - $option = $eventsListOption; - } - - // Clear Session Event Selection -// $_SESSION[GLM_EVENT_SESSION]['Event'] = false; - - // Select type of list - switch ($option) { - case 'all': - $where = 'true'; - break; - case 'active': - $where = "active"; - break; - case 'inactive': - $where = "NOT active AND end_date > 'now'"; - break; - case 'expired': - $where = "active AND end_date < 'now'"; - break; - case 'archived': - $where = "NOT active AND end_date < 'now'"; - break; - case 'member': - if (!$memberID) { - return false; - } - $where = "T.id IN ( - SELECT DISTINCT event - FROM eventmgt.inventory - WHERE member = $memberID - )"; -/* Not using event_prop anymore - SELECT DISTINCT event - FROM eventmgt.event_prop - WHERE property = $memberID - */ - break; - case 'team': - if (!$teamID) { - return false; - } - $where = "T.id IN ( - SELECT DISTINCT event - FROM eventmgt.team_property - WHERE team = $teamID - )"; - break; - default: - echo "Option not set"; - break; - } - - } - - // Get list of all available Events - $eventsList = $this->getList($where, 'start_date'); - if (count($eventsList) == 0) { - return false; - } - - return $eventsList; - } - - - - /** - * Get Event Detail - * - * @return array - */ - function getEventDetail() - { - - // Is there a new event code selected? - if (($eventID = filter_input(INPUT_GET, 'EventID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Event'] = $eventID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - - // Otherwise, get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - $eventDetail = $this->getEntry($eventID); - - return $eventDetail; - - } - - /** - * Edit Event - * - * @return array - */ - function editEvent() - { - - // Is there a new event code selected? - if (($eventID = filter_input(INPUT_GET, 'EventID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Event'] = $eventID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - - // Otherwise, get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - $eventDetail = $this->editEntry($eventID); - //echo "
".print_r($eventDetail,1)."
"; - - return $eventDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - $fd = $r['fieldData']; - - // Is Start date is later than End date - if ($fd['start_date']['timestamp'] > $fd['end_date']['timestamp']) { - $r['fieldFail']['start_date'] = 'Start date is later than end date.'; - $r['status'] = false; - } - - // Is cutoff date is later than end date - if ($fd['cutoff_date']['timestamp'] > $fd['end_date']['timestamp']) { - $r['fieldFail']['cutoff_date'] = 'Cutoff date is later than end date.'; - $r['status'] = false; - } - - return $r; - } - - /** - * Update Event - * - * @return array - */ - function updateEvent() - { - // If required dates is not selected, then drop the required start and end dates. - if (!isset($_REQUEST['req_stay']) || $_REQUEST['req_stay'] == '') { - unset($this->fields['req_stay_arrive']); - unset($this->fields['req_stay_depart']); - } - - // Is there a new event code selected? - if (($eventID = filter_input(INPUT_GET, 'EventID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Event'] = $eventID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - - // Otherwise, get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($eventID); - - return $r; - - } - - /** - * Insert Event - * - * @return array - */ - function insertEvent() - { - - $r = $this->insertEntry(); - - // If succesful then set current event to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Event'] = $r['insertedID']; - } - - return $r; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataFees.php b/legacy/classes/data/dataFees.php deleted file mode 100644 index 612efab..0000000 --- a/legacy/classes/data/dataFees.php +++ /dev/null @@ -1,662 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataFees.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataFees class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataFees.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataFees extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.fees'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Applied to (insert) - what type of entities is this fee for - 'affiliation_type' => array( - 'field' => 'affiliation_type', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Applied to (view) - 'affiliation_type_2' => array( - 'field' => 'affiliation_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->reference_type_numb->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gled' - ), - - // Fee affiliation (non-standard pointer) - // Points to various tables depending on the "Applied To" value - 'owner' => array( - 'field' => 'owner', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Fee affiliation (non-standard pointer) - // Points to various tables depending on the "Applied To" value - 'owner_2' => array( - 'field' => 'owner', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gled' - ), - - // Fee method - 'fee_method' => array( - 'field' => 'fee_method', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->fee_method_numb->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Event Specific - for only one particular event - 'room_specific' => array( - 'field' => 'room_specific', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Fee Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Fee Amount - 'fee_amount' => array( - 'field' => 'fee_amount', - 'as' => false, - 'type' => 'float', - 'output_format' => '.2', - 'required' => true, - 'minValue' => 0.01, - 'unique' => false, - 'default' => 0.0, - 'use' => 'a' - ), - - // Taxable - 'taxable' => array( - 'field' => 'taxable', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Itemize - 'itemize' => array( - 'field' => 'itemize', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Optional Service - guests may select - 'optional_service' => array( - 'field' => 'optional_service', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Request Service Quantity - If off then assume single unit quantity - 'service_quant' => array( - 'field' => 'service_quant', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Maximum Service Quantity - if service_quant on - 'service_max_quant' => array( - 'field' => 'service_max_quant', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 2, - 'use' => 'a' - ), - - // Event Specific - for only one particular event - 'event_specific' => array( - 'field' => 'event_specific', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Event - if event_specific then this is the event - 'event' => array( - 'field' => 'event', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_sort' => 'start_date, name', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - used on front-end for description of service - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Get an array of fees for a particular affiliated entity - * - * $listOption Optional Type of affiliation - see config.ini 'reference_type' - * If not supplied will check for FeesListOption GET value - * $whereRequest If supplied, use as WHERE clause instead - * - * @return object containing array as sub-objects - */ - function getFees($listOption = false, $whereRequest = false) - { - - $where = ''; - - // If there's a specific whereRequest, use that only - if ($whereRequest) { - $where = $whereRequest; - } else { - - // Get Event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get Member ID from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - // Get any specified event listing option - default to active\ - if ($listOption != '') { - $option = $listOption; - - // Otheriwse check for list options provided in request - } elseif (($feesListOption = filter_input(INPUT_GET, 'FeesListOption', FILTER_SANITIZE_STRING))) { - $option = $feesListOption; - } - - // Include selection of proper affiliation type - switch ($option) { - case 'event': - if ($eventID) { - $where .= "T.affiliation_type = ".$this->config->reference_type->event - ."AND owner = $eventID"; - } else { - $where .= "false"; - } - break; - case 'member': - if ($memberID) { - $where .= "T.affiliation_type = ".$this->config->reference_type->property - ."AND owner = $memberID\n"; - } else { - $where .= "false"; - } - break; - } - } - - // Get the fees - return false if none found - $feesList = $this->getList($where, 'name'); - if (!is_array($feesList) || count($feesList) == 0) { - return false; - } - - // Get affiliation type for each fee - reset($feesList); - while( list($key, $val) = each( $feesList ) ) { - - $aData = $this->getAffiliate( - $val['affiliation_type']['value'], - $val['owner'] - ); - - if ($aData) { - $feesList[$key]['affiliation_type_name'] = $aData['applied_to_name']; - $feesList[$key]['owner_name'] = $aData['owner_name']; - } - - // Specify if fee is in % rather than $ - $feesList[$key]['feePercent'] = false; - if ($feesList[$key]['fee_method']['value'] >= 10) { - $feesList[$key]['feePercent'] = true; - } - - } // Get Fee affiliation - - return $feesList; - } - - /** - * Get Fee Detail - * - * @return array - */ - function getFeeDetail() - { - - // Is there a new fee ID supplied? - if (!($feeID = filter_input(INPUT_GET, 'FeeID', FILTER_SANITIZE_NUMBER_INT))) { - // We don't have an fee id - return false; - } - - $feeDetail = $this->getEntry($feeID); - - // Get owner data - $aData = $this->getAffiliate( - $feeDetail['affiliation_type']['value'], - $feeDetail['owner'] - ); - - if ($aData) { - $feeDetail = array_merge($feeDetail, $aData); - } - - // Specify if fee is in % rather than $ - $feeDetail['feePercent'] = false; - if ($feeDetail['fee_method']['value'] >= 10) { - $feeDetail['feePercent'] = true; - } - - return $feeDetail; - - } - - /** - * Edit Fee - * - * @return array - */ - function editFee() - { - - // Is there a new fee ID supplied? - if (!($feeID = filter_input(INPUT_GET, 'FeeID', FILTER_SANITIZE_NUMBER_INT))) { - // We don't have an fee id - return false; - - } - - $feeDetail = $this->editEntry($feeID); - - // Get owner data - $aData = $this->getAffiliate( - $feeDetail['affiliation_type']['value'], - $feeDetail['owner'] - ); - - if ($aData) { - $feeDetail = array_merge($feeDetail, $aData); - } - - return $feeDetail; - - } - - /** - * Update Fee - * - * @return array - */ - function updateFee() - { - - // Is there a new fee ID supplied? - if (!($feeID = filter_input(INPUT_GET, 'FeeID', FILTER_SANITIZE_NUMBER_INT))) { - if (!($feeID = filter_input(INPUT_POST, 'FeeID', FILTER_SANITIZE_NUMBER_INT))) { - echo "::::::"; - // We don't have an fee id - return false; - } - } - - // Try to update this data - $r = $this->updateEntry($feeID); - - // Get owner data - $aData = $this->getAffiliate( - $r['fieldData']['affiliation_type']['value'], - $r['fieldData']['owner'] - ); - - if ($aData) { - $r['fieldData'] = array_merge($r['fieldData'], $aData); - } - - // Specify if fee is in % rather than $ - $r['fieldData']['feePercent'] = false; - - if ($r['fieldData']['fee_method']['value'] >= 10) { - $r['fieldData']['feePercent'] = true; - } - - return $r; - - } - - /** - * New Fee - * - * @return array - */ - function newFeeAffiliation($r) - { - - // Check for specified Fee type - // We need to check for name rather than number because that's what the js is sending us - if (!isset($_REQUEST['fee_type_code']) || $_REQUEST['fee_type_code'] == '') { - return false; - } - - // Get type and affiliation - $feeType = trim($_REQUEST['fee_type_code']); - $affiliateID = false; - - switch ($feeType) { - case 'event': - $feeTypeNumber = $this->config->reference_type->event; - if (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - $affiliateID = ($_SESSION[GLM_EVENT_SESSION]['Event'] - 0); - $feeTypeName = 'Event'; - $aTable = 'event'; - $aField = 'name'; - $aFieldShort = 'event_code'; - } - break; - case 'property': - $feeTypeNumber = $this->config->reference_type->property; - if (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - $affiliateID = ($_SESSION[GLM_EVENT_SESSION]['Member'] - 0); - $feeTypeName = 'Property'; - $aTable = 'eventmgt.member'; - $aField = 'name'; - $aFieldShort = $aField; - } - break; - } - - // If no match on Fee type, then fail - if ($affiliateID == false) { - return false; - } - - // Get affiliate data - $sql = "SELECT $aField AS name, - $aFieldShort AS short_name - FROM $aTable - WHERE id = $affiliateID - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $aData = $stmt->fetch(PDO::FETCH_ASSOC); - - // if no valid affiliate data - fail - if (!$aData) { - return false; - } - - $r['fieldData']['fee_type_name'] = $feeTypeName; - $r['fieldData']['fee_type_code'] = $feeType; - $r['fieldData']['fee_type'] = $feeTypeNumber; - $r['fieldData']['affiliation_name'] = $aData['name']; - $r['fieldData']['affiliation'] = $affiliateID; - $r['fieldData']['affiliation_short'] = $aData['short_name']; - - return $r; - - } - - function newFee() - { - - $r = $this->newEntry(); - - $r = $this->newFeeAffiliation($r); - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - - /** - * Insert Fee - * - * @return array - */ - function insertFee() - { - - $r = $this->insertEntry(); - $r = $this->newFeeAffiliation($r); - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - /** - * Get Affiliate table and name - * - */ - function getAffiliate($type, $affiliation) - { - - // Deterimine Affliate table - $aTable = ''; - $aField = ''; - switch ($type) { - case $this->config->reference_type->event: - $aType = 'Event'; - $aTable = 'event'; - $aField = 'name'; - $aFieldShort = 'event_code'; - break; - case $this->config->reference_type->property: - $aType = 'Property'; - $aTable = 'eventmgt.member'; - $aField = 'name'; - $aFieldShort = $aField; - break; - } - - $r = false; - - // If we have a good affiliate relationship - if ($aField != '') { - - $sql = "SELECT $aField AS name, - $aFieldShort AS short_name - FROM $aTable - WHERE id = $affiliation - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $aData = $stmt->fetch(PDO::FETCH_ASSOC); - - if ($aData) { - $r = array( - 'fee_type_name' => $aType, - 'affiliation_name' => $aData['name'], - 'affiliation_short' => $aData['short_name'] - ); - } - } - - return $r; - - } - - /** - * Delete Fee - * - * @return array - */ - function feeDelete($confirm = false) - { - // Is there a new fee code selected? - if (($feeID = filter_input(INPUT_GET, 'FeeID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Fee'] = $feeID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Fee'])) { - - // Otherwise, get the fee ID from the session - $feeID = $_SESSION[GLM_EVENT_SESSION]['Fee']; - - } else { - - // Otherwise, we don't have a fee id - return false; - - } - - $feeDetail = $this->deleteEntry($feeID, $confirm); - return $feeDetail; - - } - - -} -?> \ No newline at end of file diff --git a/legacy/classes/data/dataInventory.php b/legacy/classes/data/dataInventory.php deleted file mode 100644 index 055df96..0000000 --- a/legacy/classes/data/dataInventory.php +++ /dev/null @@ -1,1141 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataInventory.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementAdminInventory class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataInventory.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataInventory extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.inventory'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'a' - ), - - // Event selection - 'event' => array( - 'field' => 'event', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'lgud' - ), - - // Event ID - 'event_id' => array( - 'field' => 'event', - 'as' => 'event_id', - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lgud' - ), - - // Property selection - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'lgud' - ), - - // Member Street Address - From main member db - 'member_street' => array( - 'field' => 'member', // ID in member table is same as in eventmgt.member - 'as' => 'street', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'street', - 'p_id' => 'member_id', - 'required' => true, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member City - From main member db - 'member_city' => array( - 'field' => 'member', // ID in member table is same as in eventmgt.member - 'as' => 'city', - 'type' => 'pointer', - 'p_table' => 'members.city', - 'p_field' => 'city_name', - 'p_id' => 'city_id', - 'p_where' => 'M.member_id = T.member AND city.city_id = M.city_id', - 'p_from' => 'members.member M', - 'p_static' => true, - 'required' => true, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // member ID - 'memb_id' => array( - 'field' => 'member', - 'as' => 'member_id', - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lgdu' - ), - - // Accommodation ID - 'accommodation_id' => array( - 'field' => 'accommodation', - 'as' => 'accommodation_id', - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'au' - ), - - // Accommodation - 'accommodation' => array( - 'field' => 'accommodation', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.accommodation', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'ni' - ), - - // Accommodation name - 'accommodation_name' => array( - 'field' => 'accommodation', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.accommodation', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'lged' - ), - - // Start Date - 'start_date' => array( - 'field' => 'start_date', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'ni' - ), - - // End Date - 'end_date' => array( - 'field' => 'end_date', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'niu' - ), - - // Date - 'date' => array( - 'field' => 'date', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => date('m/d/Y'), - 'use' => 'lgeud' - ), - - // Assigned to Event - 'assigned' => array( - 'field' => 'assigned', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'minValue' => 1, - 'use' => 'a' - ), - - // Available to reserve - 'available' => array( - 'field' => 'available', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'lgeud' - ), - - // On Hold - 'on_hold' => array( - 'field' => 'id', - 'as' => 'on_hold', - 'type' => 'pointer', - 'p_table' => 'eventmgt.inven_hold', - 'p_field' => 'quant', - 'p_id' => 'inventory', - 'p_where' => "expire_time > '".date('r')."' AND inventory = T.id", - 'p_sum' => true, - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'lg' - ), - -/* not using now - // Minimum Nights Requred - 'min_nights' => array( - 'field' => 'min_nights', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 1, - 'minValue' => 1, - 'use' => 'a' - ), -*/ - // Event Room Rate - For standard number of occupants - 'rate' => array( - 'field' => 'rate', - 'as' => false, - 'type' => 'money', - 'required' => true, - 'unique' => false, - 'default' => 0.0, - 'minValue' => 1, - 'use' => 'a' - ) -/* not using now - // Additional Person Rate - 'add_person' => array( - 'field' => 'add_person', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => 0.0, - 'minValue' => 0, - 'use' => 'a' - ) -*/ - -/* not using policies at this level for now - // Request Policy - 'res_policy' => array( - 'field' => 'res_policy', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Cancel Policy - 'can_policy' => array( - 'field' => 'can_policy', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) -*/ - ); - } - - /** - * Get Inventory list - * - * @param string type of events list - * - * @return object containing array - * timestamp of first date of inventory - * array of inventory items - */ - function getInvenList($setType = false, $setId = false) - { - - // Get any specified member listing option - default to event - if ($setType) { - - $option = $setType; - - } else { - - $option = 'accom'; - if (($invenListOption = filter_input(INPUT_GET, 'InvenListOption', FILTER_SANITIZE_STRING))) { - $option = $invenListOption; - } - - } - - // Check for setId passed in URL - $setIdRequest = ($_REQUEST['setId'] - 0); - if ($setIdRequest > 0) { - $setId = $setIdRequest; - } - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'TRUE'; - $type = 'Summary'; - break; - case 'event': - // Get event ID from session - if available - $eventID = ( $setId ? $setId : $_SESSION[GLM_EVENT_SESSION]['Event'] ); - if (!$eventID) { - return false; - } - $where = "T.event = $eventID"; - $type = 'Summary'; - break; - case 'member': - $memberID = ( $setId ? $setId : $_SESSION[GLM_EVENT_SESSION]['Member'] ); - if (!$memberID) { - return false; - } - $where = "T.member = $memberID"; - $type = 'Calendar'; - break; - case 'accom': - // Get event ID from session - if available - $accomID = ( $setId ? $setId : $_SESSION[GLM_EVENT_SESSION]['Accom'] ); - if (!$accomID) { - return false; - } - $where = "T.accommodation = $accomID"; - $type = 'Calendar'; - break; - case 'team': - $teamID = ( $setId ? $setId : $_SESSION[GLM_EVENT_SESSION]['Team'] ); - if (!$teamID) { - return false; - } - $where = " - T.member in ( - SELECT property - FROM eventmgt.team_property - WHERE team = $teamID - )"; - $type = 'Calendar'; - break; - default: - echo "Option not set"; - break; - } - - // Only look for inventory from now forward. - $where .= " AND T.date > 'now'"; - - // Get list of all available Events - $inventoryList = $this->getList($where); - - // Clean up and fix specific fields and find first date of inventory - if ($inventoryList != false) { - - $firstDate = strtotime('+5 years'); // Start with something far out in time - reset($inventoryList); - while( list($key, $val) = each( $inventoryList ) ) { - - $thisDate = strtotime($val['date']['date']); - - // Is this date earlier than any others? - if ($thisDate < $firstDate) { - $firstDate = $thisDate; - } - - // Convert dates to format required for fullcalendar - $inventoryList[$key]['cal_date'] = date('Y-m-d', $thisDate); - - // Make member_name copy safe for inclusion in JAVAscript code - $inventoryList[$key]['member_name_h'] = addslashes($val['property']); - - } - } - - // Create a summary for certain list options - $sum = array(); - $dates = array(); - $have_summary = false; - $total_properties = 0; - $total_assigned = array(); - $total_available = array(); - $total_sold = array(); - if ($type == 'Summary' && is_array($inventoryList) && count($inventoryList) > 0) { - - // Start by building list of all inventory dates - // *** should be able to do this from the event dates data *** - foreach ($inventoryList as $inv) { - // Add to dates list - $t = strtotime($inv['date']['date']); - $dates[$t] = date('m/d/Y', $t); - $total_assigned[$t] = 0; - $total_available[$t] = 0; - $total_sold[$t] = 0; - } - ksort($dates); - - // Now go through it again and build all the data - foreach ($inventoryList as $inv) { - // If event has not been set yet - $event_id = $inv['event_id']; - if (!isset($sum[$event_id])) { - $sum[$event_id] = array( - 'id' => $event_id, - 'name' => $inv['event'], - 'memb' => array() - ); - } - - // If member has not been set yet - $memb_id = $inv['member_id']; - if (!isset($sum[$event_id]['memb'][$memb_id])) { - - // Get Member credit card types - $sql = " - SELECT CT.ccard_type_name AS ccardName - FROM members.ccard_type CT, members.member_ccard_type MCT - WHERE MCT.member_id = $memb_id - AND CT.ccard_type_id = MCT.ccard_type_id - ORDER BY CT.ccard_type_name - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $cc_types = $stmt->fetchAll(PDO::FETCH_ASSOC); - if (count($cc_types) == 0) { - $cc_types = false; - } - - $sum[$event_id]['memb'][$memb_id] = array( - 'id' => $memb_id, - 'name' => $inv['member'], - 'street' => $inv['street'], - 'city' => $inv['city'], - 'accom' => array(), - 'cc_types' => $cc_types - ); - - $total_properties++; - } - - // If accommodation has not been set yet - $accom_id = $inv['accommodation_id']; - if (!isset($sum[$event_id]['memb'][$memb_id]['accom'][$accom_id])) { - $sum[$event_id]['memb'][$memb_id]['accom'][$accom_id] = array( - 'id' => $memb_id, - 'name' => $inv['accommodation'], - 'date' => array() - ); - - // Also build all the dates as empty entries - reset($dates); - while( list($k, $v) = each($dates) ) { - $sum[$event_id]['memb'][$memb_id]['accom'][$accom_id]['date'][$k] = false; - } - - } - - // Add this inventory item - $inven_id = $inv['id']; - $t = strtotime($inv['date']['date']); - $sum[$event_id]['memb'][$memb_id]['accom'][$accom_id]['date'][$t] = array( - 'id' => $inven_id, - 'date' => $inv['date']['date'], - 'assigned' => $inv['assigned'], - 'avail' => $inv['available'], - 'sold' => $inv['assigned'] - $inv['available'], - 'rate' => $inv['rate'] - ); - ksort($sum[$event_id]['memb'][$memb_id]['accom'][$accom_id]['date']); - - $total_assigned[$t] += $inv['assigned']; - $total_available[$t] += $inv['available']; - $total_sold[$t] += ($inv['assigned'] - $inv['available']); - - } - - $sum[$event_id]['total_properties'] = $total_properties; - $sum[$event_id]['total_assigned'] = $total_assigned; - $sum[$event_id]['total_available'] = $total_available; - $sum[$event_id]['total_sold'] = $total_sold; - - // Calculate overall uptake rate per day - $ta = 0; - $ts = 0; - $daily_uptake = array(); - while (list($k, $v) = each($total_assigned)) { - $ta += $v; - $ts += $total_sold[$k]; - - // Calculate uptake rate for this day - $sum[$event_id]['daily_uptake'][$k] = sprintf('%.2f', (($total_sold[$k] / $v) * 100) )."%"; - } - $sum[$event_id]['overall_uptake'] = sprintf('%.2f', (($ts / $ta) * 100) )."%"; - - $have_summary = true; - - } - - $r = array( - 'inventory' => $inventoryList, - 'firstDate' => $firstDate, - 'type' => $type, - 'dates' => $dates, - 'sum' => $sum, - 'have_sum' => $have_summary - ); - - return $r; - - } - - - /** - * Get Inventory Detail - * - * @return array - */ - function getInvenDetail($invID = false) - { - - // If an inventory ID is supplied - if ($invID) { - $inventoryID = $invID; - - // Otherwise is there a new inventory item selected selected? - } elseif (($inventoryID = filter_input(INPUT_GET, 'InvenID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Inven'] = $inventoryID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Inven'])) { - - // Otherwise, get the inventory ID from the session - $inventoryID = $_SESSION[GLM_EVENT_SESSION]['Inven']; - - } else { - - // Otherwise, we don't have an inventory id - return false; - - } - - $inventoryDetail = $this->getEntry($inventoryID); - - return $inventoryDetail; - - } - - - /** - * Edit Inventory - * - * @return array - */ - function editInven() - { - - if (($invenID = filter_input(INPUT_GET, 'InvenID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Inven'] = $invenID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Inven'])) { - - // Otherwise, get the inventory ID from the session - $invenID = $_SESSION[GLM_EVENT_SESSION]['Inven']; - - } else { - - // Otherwise, we don't have an inventory id - return false; - - } - - $invenDetail = $this->editEntry($invenID); - - return $invenDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); -/* - $fd = $r['fieldData']; - - // Is Start date is later than End date - if (strtotime($fd['start_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['start_date'] = 'Start date is later than end date.'; - $r['status'] = false; - } - - // Is cutoff date is later than end date - if (strtotime($fd['cutoff_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['cutoff_date'] = 'Cutoff date is later than end date.'; - $r['status'] = false; - } -*/ - return $r; - } - - /** - * Update Inventory - * - * @return array - */ - function updateInven() - { - - if (($invenID = filter_input(INPUT_GET, 'InvenID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Inven'] = $invenID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Inven'])) { - - // Otherwise, get the inventory ID from the session - $invenID = $_SESSION[GLM_EVENT_SESSION]['Inven']; - - } else { - - // Otherwise, we don't have a inventory id - return false; - - } - - // Assume no delete and no delete failure - $delete = false; - $deleteFail = false; - $reason = array(); - - // Check if we have valid data - $r = $this->updateEntry($invenID, 'id', false); - if ($r['status']) { - - // check if this is a Delete request - if (isset($_REQUEST['submitType']) && $_REQUEST['submitType'] == 'Delete Selected Inventory') { - - // Check if there are room block associated with this inventory - $sql = " - SELECT COUNT(id) - FROM eventmgt.room_block_seg - WHERE event = ".$r['fieldData']['event_id']." - AND accommodation = ".$r['fieldData']['accommodation_id']."; - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $blockData = $stmt->fetch(PDO::FETCH_ASSOC); - if ($blockData['count'] > 0) { - // Can't delete because room blocks associated with this inventory exist - $r['status'] = false; - $reason[] = 'The selected inventory is in use in a room block.'; - $reason[] = 'Delete the room block first if you want to delete this inventory.'; - $delete = false; - $deleteFail = true; - } else { - // No room blocks so inventory may be deleted. - $delete = true; - } - } - - // Check if this is only the original date - if ($r['fieldStore']['date'] == $r['fieldStore']['end_date'] && - $r['fieldData']['date']['date'] == $_REQUEST['original_date']) { - - $fields = $this->fields; - unset($fields['end_date']); - $this->fields = $fields; - - // It's only the original date, so do again but store it this time or delete it - if ($delete) { - - // Delete requested - $sql = "DELETE FROM eventmgt.inventory - WHERE id = ".$r['fieldData']['id'].";"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - $r['fieldData']['date']['date'] .= " *** DELETED *** "; - - } else { - - $r = $this->updateEntry($invenID); - - } - - } else { // This is either not the original date or it's a date range - - // Check for sane dates - if ($r['fieldData']['date']['timestamp'] > $r['fieldData']['end_date']['timestamp']) { - - $r['status'] = false; - $r['fieldFail']['end_date'] = "Must be equal to or later than From Date."; - - } else { - - $accom_id = ($_REQUEST['accom_id'] - 0); - $event_id = ($_REQUEST['event_id'] - 0); - $memb_id = ($_REQUEST['member_id'] - 0); - - // Delete any inventory for this accommodation and event - $sql = "DELETE FROM eventmgt.inventory - WHERE event = ".$event_id." - AND accommodation = ".$accom_id." - AND date >= '".$r['fieldData']['date']['date']."' - AND date <= '".$r['fieldData']['end_date']['date']."';"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - // Check if this is a request to delete the inventory - if (isset($_REQUEST['submitType']) && $_REQUEST['submitType'] == 'Delete Selected Inventory') { - $r['fieldData']['date']['date'] .= " through ".$r['fieldData']['end_date']['date'].' *** DELETED ***'; - } else { - - // Insert updated inventory for date range (note incriment is a bit more to accommodate leap seconds) - $sql = "INSERT INTO eventmgt.inventory - (date, member, accommodation, event, assigned, available, rate) - VALUES - ('{date}', $memb_id, $accom_id, $event_id, ".$r['fieldStore']['assigned'].", - ".$r['fieldStore']['available'].", ".$r['fieldStore']['rate']." - ); - "; - - // For each date, create new inventory. - for ($d = $r['fieldData']['date']['timestamp'] ; - $d <= $r['fieldData']['end_date']['timestamp'] ; - $d = strtotime(date('m/d/Y', $d+86500))) { - - $date = date('m/d/Y', $d); - $s = str_replace('{date}', $date, $sql); - $stmt = $this->dbh->prepare($s); - $stmt->execute(); - - } - - // Change date on detail display to show range - $r['fieldData']['date']['date'] .= " through ".$r['fieldData']['end_date']['date']; - } - } - } - - } - - // Check if there was a delete failure - if ($deleteFail) { - $r['status'] = false; - if (is_array($r['reason'])) { - $reason = array_merge($r['reason'], $reason); - } - $r['reason'] = $reason; - } - - return $r; - - } - - - /** - * Add Inventory - * - * @return array - */ - function addInven() - { - $reason = array(); - - // Make sure an Event has been selected. - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - $reason[] = "No event has been selected. Please select an Event and Property before adding inventory."; - } - - // Get selected event and property data - $eventData = $this->getEventMemberData($eventID); - - // Set dates to default to event dates - $this->fields['start_date']['default'] = strtotime($eventData['event_start_date']); - $this->fields['end_date']['default'] = strtotime($eventData['event_end_date']); - $this->fields['min_nights']['default'] = $eventData['event_days']; - - // Get new entry fields - $r = $this->newEntry(); - - // Check for available properties/accommodations - if (count($r['fieldData']['accommodation']['pick_list']) == 0) { - $r['status'] = false; - $r['reason'][] = 'No property accommodations in system to select from. Please add accommodations to a property.'; - } - - // Add in static Event and Property data - $r['fieldData'] = array_merge($r['fieldData'], $eventData); - - // Add in member/accommodation data - $membAccom = $this->getMembAccomMatrix(); - $r['membAccom'] = $membAccom; - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - /** - * Insert Inventory - * - * @return array - */ - function insertInven() - { - - // Get selected event and property data using ID's passed from form - $eventID = ($_REQUEST['event'] - 0); - $memberID = ($_REQUEST['member'] - 0); - $eventData = $this->getEventMemberData($eventID); - - // Process input, but don't store any result - $r = $this->insertEntry(false); - - // Add in static Event and Property data - $r['fieldData'] = array_merge($r['fieldData'], $eventData); - - // Check for sane dates - if ($r['fieldData']['start_date']['timestamp'] > $r['fieldData']['end_date']['timestamp']) { - $r['status'] = false; - $r['fieldFail']['start_date'] = 'First date may not be later than last date when creating inventory.'; - } - - if ($memberID > 0 && $r['status'] ) { - - // Check for existing inventory conflicting with this new inventory - $sql = "SELECT count(id) - FROM eventmgt.inventory - WHERE event = $eventID - AND member = $memberID - AND accommodation = ".$r['fieldStore']['accommodation']." - AND date BETWEEN ".$r['fieldStore']['start_date']." AND ".$r['fieldStore']['end_date']." - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventData = $stmt->fetch(PDO::FETCH_ASSOC); - - if ($eventData['count'] > 0) { - $r['status'] = false; - $r['fieldFail']['start_date'] = 'Inventory already exists for at least one of the dates requested.'; - } - } - - if ($memberID == 0) { - $r['fieldFail']['member'] = 'Member is required.'; - } - - // If it's OK to create the inventory - if ($r['status']) { - - // Add each night as separate inventory item - $s = $r['fieldData']['start_date']['timestamp']; - $e = $r['fieldData']['end_date']['timestamp']; - $sql = array(); - for ($date=$s ; $date<=$e ; $date=strtotime(date('m/d/Y',$date)." +1 day")) { - $sql[] = "INSERT INTO eventmgt.inventory - (event, member, accommodation, date, assigned, available, rate) - VALUES - ( - $eventID, $memberID, ".$r['fieldStore']['accommodation'].", - '".date('m/d/Y',$date)."', ".$r['fieldStore']['assigned'].", - ".$r['fieldStore']['assigned'].", ".$r['fieldStore']['rate']." - ); - \n"; - } -/* Not using event_prop table anymore - // Check for existing event/property table entry - $sql2 = "SELECT count(id) - FROM eventmgt.event_prop - WHERE event = $eventID - AND property = $memberID - ;"; - $stmt = $this->dbh->prepare($sql2); - $stmt->execute(); - $eventpropData = $stmt->fetch(PDO::FETCH_ASSOC); - - // If there's not an entry, add one - if ($eventpropData['count'] == 0) { - $sql[] = "INSERT INTO eventmgt.event_prop - (event, property) - VALUES - ($eventID, $memberID) - ;"; - - } -*/ - // Try to add this inventory - try { - $this->dbh->beginTransaction(); - foreach ($sql as $s) { - $this->dbh->exec($s); - } - $this->dbh->commit(); - } catch (Exception $e) { - $this->dbh->rollBack(); - $r['status'] = false; - $r['reason'][] = 'Unable to store new inventory for unknown reason. '; - // var_dump($e); - } - - // Add to event-property table - } - - // Add in member/accommodation data - $membAccom = $this->getMembAccomMatrix(); - if ($memberID > 0) { - $r['membSelected'] = $membAccom[$memberID]; - $membAccom[$memberID]['selected'] = true; - } - $r['membAccom'] = $membAccom; - - // Check for selected accommodation - $a = ($r['fieldData']['accommodation']['in'] - 0); - if ($a > 0) { - $r['membSelected']['accoms'][$a]['selected'] = true; - } - - - // If succesful then set current inventory to the one just inserted. - if ($r['status']) { - - $sql = "select currval('inventory_id_seq');"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $last = $stmt->fetch(PDO::FETCH_ASSOC); - $r['insertedID'] = $last['currval'] ; - - } - - return $r; - - } - - - - /** - * getMembAccomMatrix - * - * @param integer $memberID - */ - function getMembAccomMatrix() - { - - // Get property/accommodation matrix - if (count($reason) == 0) { - $sql = "SELECT M.id AS memb_id, - M.name AS memb_name, - A.id AS accom_id, - A.name AS accom_name - FROM eventmgt.member M, eventmgt.accommodation A - WHERE A.member = M.id - ORDER BY M.name, A.sort - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $membAccomData = $stmt->fetchAll(PDO::FETCH_ASSOC); - if (count($membAccomData) == 0) { - $reason[] = "No properties with accommodations are currently listed in the system."; - } - } - - // Build array of Members with their accommodations - $membAccom = array(); - foreach ($membAccomData as $d) { - - // If member hasn't been added to array yet - if (!isset($membAccom[$d['memb_id']])) { - $membAccom[$d['memb_id']] = array( - 'membID' => $d['memb_id'], - 'membName' => $d['memb_name'], - 'accoms' => array() - ); - } - - // Add this accommodation - $membAccom[$d['memb_id']]['accoms'][$d['accom_id']] = array( - 'accomID' => $d['accom_id'], - 'accomName' => $d['accom_name'] - ); - } - - return $membAccom; - } - - /** - * Get Event and Member information for specified event and member ID - * - * @param integer $eventID - * @param integer $memberID - */ - function getEventMemberData($eventID) - { - // Get event Data - $sql = "SELECT name, event_code, start_date, end_date, days - FROM eventmgt.event - WHERE id = $eventID; - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventData = $stmt->fetch(PDO::FETCH_ASSOC); - - // Add event information to returned array - $r['event'] = $eventData['name']; - $r['event_code'] = $eventData['event_code']; - $r['event_id'] = $eventID; - $r['event_days'] = $eventData['days']; - $r['event_start_date'] = $eventData['start_date']; - $r['event_end_date'] = $eventData['end_date']; - -/* - // Get property Data - $sql = "SELECT name - FROM eventmgt.member - WHERE id = $memberID; - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $memberData = $stmt->fetch(PDO::FETCH_ASSOC); - - // Add event information to returned array - $r['member'] = $memberData['name']; - $r['member_id'] = $memberID; -*/ - return $r; - - } - - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataMemberScansFor.php b/legacy/classes/data/dataMemberScansFor.php deleted file mode 100644 index 79d6da1..0000000 --- a/legacy/classes/data/dataMemberScansFor.php +++ /dev/null @@ -1,234 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataMemberScansFor.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataMemberScansFor class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataMemberScansFor,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataMemberScansFor extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.member_scans_for'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Pointer to a member who does the scanning - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Name of member who does the scanning - 'member_name' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Pointer to a member who the scanning is for - 'scans_for' => array( - 'field' => 'scans_for', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Name of member who does the scanning - 'scans_for_name' => array( - 'field' => 'scans_for', - 'as' => 'scans_for_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ) - - ); - } - - /** - * Get List - * - * - * @return object containing array as sub-objects - */ - public function getMemberScansForList($memberID = false) - { - - // if member ID is not supplied, try to find it - if ($memberID == false) { - - // Check submit input - $memberID = filter_input(INPUT_GET, 'MemberID', FILTER_SANITIZE_NUMBER_INT); - - // If we still don't have it - if ($memberID == false || $memberID < 1) { - - // Try the session - if (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - } - - } - - } - - // If we still don't have a valid member ID - if ($memberID == false || ($memberID - 0) <= 0) { - return false; - } - - $where = "T.member = $memberID"; - - // Get the list of members a member scans for - $memberScansFor = $this->getList($where); - if (count($memberScansFor) == 0) { - return false; - } - - return $memberScansFor; - - } - - /** - * Update member scans for list - * - * Expects request input "selectedMember[id]" array. - */ - - public function updateMemberScansForList($memberID = false) - { - - if ($memberID == false) { - return false; - } - - // Query to delete current Member Scans For list - $sql = " - BEGIN; - DELETE FROM eventmgt.member_scans_for - WHERE member = $memberID; - "; - - // Now add in any members who this member will be scanning for - $newMembers = $_REQUEST['selectedMember']; - if ($newMembers) { - foreach ($newMembers as $m) { - $sql .= " - INSERT INTO eventmgt.member_scans_for - ( member, scans_for ) - VALUES ( $memberID, $m ) - ;"; - } - } - $sql .= "COMMIT;"; - $this->dbh->exec($sql); - - return $this->getMemberScansForList($memberID); - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataMembers.php b/legacy/classes/data/dataMembers.php deleted file mode 100644 index 1666056..0000000 --- a/legacy/classes/data/dataMembers.php +++ /dev/null @@ -1,1209 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataMembers.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataMembers class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataMembers.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ -class EventManagementDataMembers extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.member'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'a' - ), - - // Member Type - 'member_type' => array( - 'field' => 'member_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->member_type->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 1, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // E-Mail - 'email' => array( - 'field' => 'email', - 'as' => false, - 'type' => 'email', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Processing E-Mail - 'proc_email' => array( - 'field' => 'proc_email', - 'as' => false, - 'type' => 'email', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Processing E-Mail #2 - 'proc_email2' => array( - 'field' => 'proc_email2', - 'as' => false, - 'type' => 'email', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Notify member of each checkout - 'checkout_notify' => array( - 'field' => 'checkout_notify', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => true, - 'use' => 'a' - ), - - // Check In Time - 'check_in' => array( - 'field' => 'check_in', - 'as' => false, - 'type' => 'time', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Check Out Time - 'check_out' => array( - 'field' => 'check_out', - 'as' => false, - 'type' => 'time', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Defalut Ticket Policy - 'def_ticket_pol' => array( - 'field' => 'def_ticket_pol', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - - /* - * Fields used whether or not we're using an integrated member database - */ - -/* not using policies at this level for now - // Defalut Reservation Policy - 'def_res_pol' => array( - 'field' => 'def_res_pol', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - - // Defalut Cancel Policy - 'def_can_pol' => array( - 'field' => 'def_can_pol', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), -*/ - // Member amenity #1 - 'amen_1' => array( - 'field' => 'amen_1', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #2 - 'amen_2' => array( - 'field' => 'amen_2', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #3 - 'amen_3' => array( - 'field' => 'amen_3', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #4 - 'amen_4' => array( - 'field' => 'amen_4', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #5 - 'amen_5' => array( - 'field' => 'amen_5', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #6 - 'amen_6' => array( - 'field' => 'amen_6', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #7 - 'amen_7' => array( - 'field' => 'amen_7', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #8 - 'amen_8' => array( - 'field' => 'amen_8', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #9 - 'amen_9' => array( - 'field' => 'amen_9', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member amenity #10 - 'amen_10' => array( - 'field' => 'amen_10', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Intro Text for front-end - 'intro_text' => array( - 'field' => 'intro_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Checkout E-Mail - 'checkout_email' => array( - 'field' => 'checkout_email', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - - - /* - * Fields used if we're using an integrated member database - */ - if ($this->config->option->member_db_integrated) { - - $integratedDb = array( - - // Member name - From main member db - Used only if db is Integrated - 'member_name' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_name', - 'p_id' => 'member_id', - // Only permit members set at providing accommodations - 'p_where' => 'member_id in - ( - SELECT DISTINCT member_id - FROM members.member_category - WHERE category_id IN - (SELECT category_id FROM members.category WHERE accommodations) - )', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'nid' - ), - - // Member name - From main member db - Used only if db is Integrated - 'member_name_view' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_name', - 'p_id' => 'member_id', - 'p_static' => true, - 'required' => true, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member login - From main member db - Used only if db is Integrated - 'member_login_view' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'member_login', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_login', - 'p_id' => 'member_id', - 'p_static' => true, - 'required' => true, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member password - From main member db - Used only if db is Integrated - 'member_passwd_view' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'member_passwd', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'member_passwd', - 'p_id' => 'member_id', - 'p_static' => true, - 'required' => false, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member Street Address - From main member db - 'member_street' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'street', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'street', - 'p_id' => 'member_id', - 'required' => true, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member City - From main member db - 'member_city' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'city', - 'type' => 'pointer', - 'p_table' => 'members.city', - 'p_field' => 'city_name', - 'p_id' => 'city_id', - 'p_where' => 'M.member_id = T.id AND city.city_id = M.city_id', - 'p_from' => 'members.member M', - 'p_static' => true, - 'required' => true, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member phone - From main member db - 'member_phone' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'phone', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'phone', - 'p_id' => 'member_id', - 'required' => true, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member Lat - From main member db - 'member_lat' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'lat', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'lat', - 'p_id' => 'member_id', - 'required' => false, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member Lon - From main member db - 'member_lon' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'lon', - 'type' => 'pointer', - 'p_table' => 'members.member', - 'p_field' => 'lon', - 'p_id' => 'member_id', - 'required' => false, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member number of rooms at property - 'prop_rooms' => array( - 'field' => 'id', // ID in member table is same as in eventmgt.member - 'as' => 'prop_rooms', - 'type' => 'pointer', - 'p_table' => 'members.member_accommodations', - 'p_field' => 'num_rooms', - 'p_id' => 'member_id', - 'required' => false, - 'unique' => true, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ) - - ); - - $this->fields = array_merge($this->fields, $integratedDb); - - } - - - /* - * Fields used if we're not using an integrated database - */ - if (!$this->config->option->member_db_integrated) { - - $nonIntegratedDb = array( - - // Member Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 1 - 'addr1' => array( - 'field' => 'addr1', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 2 - 'addr2' => array( - 'field' => 'addr2', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // City - 'city' => array( - 'field' => 'city', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // State - 'state' => array( - 'field' => 'state', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->states->toArray(), - 'required' => true, - 'unique' => false, - 'default' => 'MI', - 'use' => 'a' - ), - - // Country - 'country' => array( - 'field' => 'country', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->countries->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // ZIP - 'zip' => array( - 'field' => 'zip', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Latitude - 'lat' => array( - 'field' => 'lat', - 'as' => false, - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => 45, - 'use' => 'a' - ), - - // Longitude - 'lon' => array( - 'field' => 'lon', - 'as' => false, - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => -84, - 'use' => 'a' - ), - - // Member phone - From main member db - 'phone' => array( - 'field' => 'phone', // ID in member table is same as in eventmgt.member - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Credit Cards Accepted - multi-pick - 'cards_accepted' => array( - 'field' => 'cards_accepted', - 'as' => false, - 'type' => 'bitmap', - 'bitmap' => $this->config->ccard->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 0, // Note that this is a bitmap of card indexes - 'use' => 'a' - ), - - // Payment Gateway - 'payment_gateway' => array( - 'field' => 'payment_gateway', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->ccard_processor->toArray(), - 'required' => false, - 'unique' => false, - 'default' => '99', - 'use' => 'a' - ), - - // Payment Gateway Parameter 1 (Authorize.net: login, Merchant Solutions: acctid) - 'gateway_par1' => array( - 'field' => 'gateway_par1', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Payment Gateway Parameter 2 (Authorize.net: key, Merchant Solutions: merchantpin) - 'gateway_par2' => array( - 'field' => 'gateway_par2', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Payment Gateway Parameter 3 (Authorize.net: test, Merchant Solutions: n/a) - // test: LOCAL_TEST, LOCAL_FAIL, TRUE, FALSE (Must be FALSE for production) - 'gateway_par3' => array( - 'field' => 'gateway_par3', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->cc_mode->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Payment Gateway Parameter 4 (Authorize.net: Send Conf Flag, Merchant Solutions: n/a) - 'gateway_par4' => array( - 'field' => 'gateway_par4', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Payment Gateway Parameter 5 (Authorize.net: Merchant Email, Merchant Solutions: n/a) - 'gateway_par5' => array( - 'field' => 'gateway_par5', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // PayPal enabled flag - 'paypal' => array( - 'field' => 'paypal', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // PayPal Client ID - 'paypal_client_id' => array( - 'field' => 'paypal_client_id', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // PayPal Secret - 'paypal_secret' => array( - 'field' => 'paypal_secret', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // PayPal payment mode - // test: - 'paypal_mode' => array( - 'field' => 'paypal_mode', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->paypal_mode->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Parking Map - 'parking_map' => array( - 'field' => 'parking_map', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Ticket Sector Map - 'ticket_sec_map' => array( - 'field' => 'ticket_sec_map', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Ticket Policy - 'ticket_policy' => array( - 'field' => 'ticket_policy', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Ticket Special Request Accepted - 'ticket_spec_req' => array( - 'field' => 'ticket_spec_req', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Sort order - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 999, - 'use' => 'a' - ), - - // Member account active - 'active' => array( - 'field' => 'active', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - ); - - $this->fields = array_merge($this->fields, $nonIntegratedDb); - - } - - } - - /** - * Get Members list - * - * @param string type of events list - * - * @return object containing array as sub-objects - */ - function getMembersList($option = 'event', $where = 'TRUE') - { - - if ($option == 'all') { - $_SESSION[GLM_EVENT_SESSION]['Event'] = false; - } - - // Get event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get any specified member listing option - default to event - if (($membersListOption = filter_input(INPUT_GET, 'MembersListOption', FILTER_SANITIZE_STRING))) { - $option = $membersListOption; - } - - // Select type of list - $sortByDist = false; - switch ($option) { - - case 'all': - break; - - case 'active': - $where .= ' AND active'; - break; - - case 'accom': - $where .= " AND id in - ( - SELECT DISTINCT member - FROM eventmgt.accommodation - ) - "; - break; - - case 'event': - if (!$eventID) { - return false; - } - $where .= "AND id IN - ( - SELECT DISTINCT member - FROM eventmgt.inventory - WHERE conv = $eventID - ) - "; - /* Not using event_prop anymore - SELECT DISTINCT property - FROM eventmgt.event_prop - WHERE event = $eventID - */ - $sortByDist = true; - break; - - case 'type1': - $where .= " AND member_type = 1 AND active"; - break; - - case 'type2': - $where .= " AND member_type = 2 AND active"; - break; - - case 'type3': - $where .= " AND member_type = 3 AND active"; - break; - - default: - echo "Option not set"; - break; - } - - // Get Members List - $membersList = $this->getList($where, 'name'); - - // Add distances to the member data and sort by distance - if ($sortByDist) { - if (!class_exists('EventManagementGeoCalculations')) { - require COMMON_APP_BASE.APP_VERSION.'/classes/GeoCalculations.php'; - } - $Geo = new EventManagementGeoCalculations($this->dbh); - $membersList = $Geo->getMemberEventDistance( $eventID, $membersList, 'lat', 'lon', 'distance', 'duration', 'id', true); - } - - // echo "
".print_r($membersList,1)."
"; - return $membersList; - } - - - /** - * Get Member Detail - * - * @return array - */ - function getMemberDetail($memberID = false) - { - $this->optionIncludeSelectListData = false; - - // If a member ID has been supplied - if ($memberID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Member'] = $memberID; - - } elseif (($memberID = filter_input(INPUT_GET, 'MemberID', FILTER_SANITIZE_NUMBER_INT))) { - - // Otherwise if there a new member ID supplied via the request - $_SESSION[GLM_EVENT_SESSION]['Member'] = $memberID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - - // Otherwise, get the event ID from the session - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - $memberDetail = $this->getEntry($memberID); - - // echo "
".print_r($memberDetail,1)."
"; - return $memberDetail; - - } - - - /** - * Edit Member - * - * @return array - */ - function editMember() - { - // Is there a new member code selected? - if (($memberID = filter_input(INPUT_GET, 'MemberID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Member'] = $memberID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - - // Otherwise, get the member ID from the session - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - } else { - - // Otherwise, we don't have a member id - return false; - - } - - $memberDetail = $this->editEntry($memberID); - - return $memberDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); -/* - $fd = $r['fieldData']; - - // Is Start date is later than End date - if (strtotime($fd['start_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['start_date'] = 'Start date is later than end date.'; - $r['status'] = false; - } - - // Is cutoff date is later than end date - if (strtotime($fd['cutoff_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['cutoff_date'] = 'Cutoff date is later than end date.'; - $r['status'] = false; - } -*/ - return $r; - } - - /** - * Update Member - * - * @return array - */ - function updateMember() - { - - // Is there a new event code selected? - if (($memberID = filter_input(INPUT_GET, 'MemberID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Member'] = $memberID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - - // Otherwise, get the member ID from the session - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - } else { - - // Otherwise, we don't have a member id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($memberID); - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - /** - * Insert Member - * - * @return array - */ - function insertMember() - { - - $r = $this->insertEntry(); - - // If succesful then set current member to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Member'] = $r['insertedID']; - } - - return $r; - - } - - - /** - * Delete Member - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function memberDelete($confirm = false) - { - - // Is there a new member code selected? - if (($memberID = filter_input(INPUT_GET, 'MemberID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Member'] = $memberID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - - // Otherwise, get the member ID from the session - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - } else { - - // Otherwise, we don't have a member id - return false; - - } - - /* - * Delete all supporting information - * - * Contacts - * Performance - * Sections - * Events - * Tickets - * Ticket inventory - * Orders - * Sold - * - * - * inven_hold gets cleaned out and does not need to be deleted - */ -/* - DELETE FROM eventmgt.ticket_order - WHERE member = $memberID; - DELETE FROM eventmgt.ticket_sold - WHERE member = $memberID; -*/ - $sql = " - DELETE FROM eventmgt.res_contact - WHERE contact_type = ".$this->config->reference_type->member." - AND affiliation = $memberID; - DELETE FROM eventmgt.section - WHERE member = $memberID; - DELETE FROM eventmgt.ticket_inventory - WHERE ticket in ( - SELECT id - FROM eventmgt.ticket - WHERE member = $memberID - ); - DELETE FROM eventmgt.ticket - WHERE member = $memberID; - DELETE FROM eventmgt.performance - WHERE member = $memberID; - "; - $this->dbh->exec($sql); - - // Delete member and return their old data - $memberDetail = $this->deleteEntry($memberID, $confirm); - - return $memberDetail; - - } - - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataMisc.php b/legacy/classes/data/dataMisc.php deleted file mode 100644 index 270edeb..0000000 --- a/legacy/classes/data/dataMisc.php +++ /dev/null @@ -1,272 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataMisc.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataMisc class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataMisc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataMisc extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.misc'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // ID - in this table there's only one entry and the ID is always 1 - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Text for intro page - 'intro_text' => array( - 'field' => 'intro_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Text for section selection page - 'section_text' => array( - 'field' => 'section_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Text for ticket selection page - 'ticket_text' => array( - 'field' => 'ticket_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Text for ticket date, time, section, quantity, selection page - 'ticket_opt_text' => array( - 'field' => 'ticket_opt_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Text for cart page - 'cart_text' => array( - 'field' => 'cart_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Text for checkout page - 'checkout_text' => array( - 'field' => 'checkout_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Text for checkout success page - 'success_text' => array( - 'field' => 'success_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Google tracking script for checkout page - 'tracking' => array( - 'field' => 'tracking', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Optional Checkout Field Name #1 - 'opt_field_1_name' => array( - 'field' => 'opt_field_1_name', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Optional Checkout Field Name #2 - 'opt_field_2_name' => array( - 'field' => 'opt_field_2_name', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Optional Checkout Field Name #3 - 'opt_field_3_name' => array( - 'field' => 'opt_field_3_name', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // SSL Certificate Seal Head Script - 'ssl_seal_head_script' => array( - 'field' => 'ssl_seal_head_script', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // SSL Certificate Seal Body Script - 'ssl_seal_body_script' => array( - 'field' => 'ssl_seal_body_script', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_UNSAFE_RAW, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Central Payment Location - 'central_payment' => array( - 'field' => 'central_payment', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Central Payment Location ID - 'central_payment_id' => array( - 'field' => 'central_payment', - 'as' => 'central_payment_id', - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 0, - 'use' => 'g' - ) - - ); - } - -} -?> \ No newline at end of file diff --git a/legacy/classes/data/dataOrders.php b/legacy/classes/data/dataOrders.php deleted file mode 100755 index bb255a3..0000000 --- a/legacy/classes/data/dataOrders.php +++ /dev/null @@ -1,652 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataOrders.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataTickets class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataOrders,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataOrders extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.ticket_order'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // user_trace_info - 'user_trace_info' => array( - 'field' => 'user_trace_info', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // First Name - 'fname' => array( - 'field' => 'fname', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Last Name - 'lname' => array( - 'field' => 'lname', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 1 - 'addr1' => array( - 'field' => 'addr1', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 2 - 'addr2' => array( - 'field' => 'addr2', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // First Name - 'city' => array( - 'field' => 'city', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact State - 'state' => array( - 'field' => 'state', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->states->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 'MI', - 'use' => 'a' - ), - - // Contact Country - 'country' => array( - 'field' => 'country', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->countries->toArray(), - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Contact ZIP - 'zip' => array( - 'field' => 'zip', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Phone - 'phone' => array( - 'field' => 'phone', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // E-Mail - 'email' => array( - 'field' => 'email', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // E-Mail OK - 'email_ok' => array( - 'field' => 'email_ok', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Purchase Date - 'purchase_date' => array( - 'field' => 'purchase_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'required' => false, - 'unique' => false, - 'default' => time(), - 'use' => 'lged' - ), - - // Member ID - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Member Name display - 'member_view' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // CC Type - 'cctype' => array( - 'field' => 'cctype', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lge' - ), - - // CC Number - 'ccnumber' => array( - 'field' => 'ccnumber', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lge' - ), - - // CC Expiration - 'expire' => array( - 'field' => 'expire', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lge' - ), - - // Name on Card - 'ccname' => array( - 'field' => 'ccname', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lge' - ), - - // CC Confirmation # - 'ccconf' => array( - 'field' => 'ccconf', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lge' - ), - - // Charge Number - 'charge_numb' => array( - 'field' => 'charge_total', - 'as' => 'charge_numb', - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Charge Total Money - 'charge_total' => array( - 'field' => 'charge_total', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lge' - ), - - // Special Needs - 'special_needs' => array( - 'field' => 'special_needs', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Optional Checkout Field Name #1 - 'opt_field_1_name' => array( - 'field' => 'opt_field_1_name', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Optional Checkout Field #1 - 'opt_field_1' => array( - 'field' => 'opt_field_1', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Optional Checkout Field Name #2 - 'opt_field_1_name' => array( - 'field' => 'opt_field_1_name', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Optional Checkout Field #2 - 'opt_field_2' => array( - 'field' => 'opt_field_2', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Optional Checkout Field Name #3 - 'opt_field_1_name' => array( - 'field' => 'opt_field_1_name', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Optional Checkout Field #3 - 'opt_field_3' => array( - 'field' => 'opt_field_3', - 'as' => false, - 'type' => text, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - - /** - * Get Orders list - * - * @return object containing array as sub-objects - */ - function getOrdersList($memberID = false, $performanceID = false, $sectionID = false, $listType = false) - { - - // Get member ID - if ($memberID == false) { - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - } - - // Get performance ID - if ($performanceID == false) { - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - } - - // Get section ID - if ($sectionID == false) { - $sectionID = $_SESSION[GLM_EVENT_SESSION]['Section']; - } - - // Get URI search type - if (!$listType && isset($_REQUEST['listType'])) { - $listType = $_REQUEST['listType']; - } - - // Build query Where clause - $where = 'true'; - - switch ($listType) { - - case 'norm': - default: - if ($memberID) { - $where .= " AND T.member = $memberID"; - } - if ($performanceID) { - $where .= " AND T.performance = $performanceID"; - } - if ($sectionID) { - $where .= " AND T.section = $sectionID"; - } - break; - - case 'all': - break; - - } - - // Get list of Orders - $ordersList = $this->getList($where, 'purchase_date'); - - return $ordersList; - } - - /** - * Get Order Detail - * - * @return array - */ - function getOrderDetail($orderID = false, $memberID = false) - { - - // If a order has been specified - if ($orderID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Order'] = $orderID; - - // Otherwise if there's a order ID in the request - } elseif (($orderID = filter_input(INPUT_GET, 'OrderID', FILTER_SANITIZE_NUMBER_INT))) { - - $_SESSION[GLM_EVENT_SESSION]['Order'] = $orderID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Order'])) { - - $orderID = $_SESSION[GLM_EVENT_SESSION]['Order']; - - } else { - - // Otherwise, we don't have an order id - return false; - - } - - $where = ''; - if ($memberID) { - $where = "AND T.member = $memberID"; - } - - $orderDetail = $this->getEntry($orderID, 'id', $where); - - // If we have a member ID then make sure the sold ticket is for that member - if ($memberID && $orderDetail['member'] != $memberID) { - return false; - } - - return $orderDetail; - - } - - - /** - * Edit Order - * - * @return array - */ - function editOrder() - { - - if (($orderID = filter_input(INPUT_GET, 'OrderID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Order'] = $orderID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Order'])) { - - // Otherwise, get the order ID from the session - $orderID = $_SESSION[GLM_EVENT_SESSION]['Order']; - - } else { - - // Otherwise, we don't have an order id - return false; - - } - - $orderDetail = $this->editEntry($orderID); - - return $orderDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Order - * - * @return array - */ - function updateOrder() - { - - if (($orderID = filter_input(INPUT_GET, 'OrderID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Order'] = $orderID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Order'])) { - - // Otherwise, get the order ID from the session - $orderID = $_SESSION[GLM_EVENT_SESSION]['Order']; - - } else { - - // Otherwise, we don't have an order id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($orderID); - - return $r; - - } - - /** - * Delete Order - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function orderDelete($confirm = false) - { - - // Is there a new order code selected? - if (($orderID = filter_input(INPUT_GET, 'OrderID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Order'] = $orderID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Order'])) { - - // Otherwise, get the order ID from the session - $orderID = $_SESSION[GLM_EVENT_SESSION]['Order']; - - } else { - - // Otherwise, we don't have an order id - return false; - - } - - $orderDetail = $this->deleteEntry($orderID, $confirm); - - return $orderDetail; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataPerformances.php b/legacy/classes/data/dataPerformances.php deleted file mode 100644 index a9fea25..0000000 --- a/legacy/classes/data/dataPerformances.php +++ /dev/null @@ -1,951 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPerformances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataPerformances class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPerformances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataPerformances extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.performance'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Member ID for adding performances - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'use' => 'nid' - ), - - // Member ID for adding performances - 'member_id' => array( - 'field' => 'member', - 'as' => member_id, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gle' - ), - - // Performance Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Active - 'active' => array( - 'field' => 'active', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Admin Only Flag - 'admin_only' => array( - 'field' => 'admin_only', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Short Description - 'short_descr' => array( - 'field' => 'short_descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Start Date - 'start_date' => array( - 'field' => 'start_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // End Date - 'end_date' => array( - 'field' => 'end_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Purchase lead-time in hours - 'purch_leadtime' => array( - 'field' => 'purch_leadtime', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 24, - 'use' => 'a' - ), - - // Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Policy - 'policy' => array( - 'field' => 'policy', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Voucher Text - 'voucher_text' => array( - 'field' => 'voucher_text', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Confirmation E-Mail Text - 'conf_text' => array( - 'field' => 'conf_text', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Promote in Cart - 'promote_in_cart' => array( - 'field' => 'promote_in_cart', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Sort order - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 999, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - /* Also get some member information in case we need it */ - - - // Member Name display - 'member_view' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member Address line 1 - 'member_addr1' => array( - 'field' => 'member', - 'as' => 'member_addr1', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'addr1', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member Address line 2 - 'member_addr2' => array( - 'field' => 'member', - 'as' => 'member_addr2', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'addr2', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member City - 'member_city' => array( - 'field' => 'member', - 'as' => 'member_city', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'city', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member State - 'member_state' => array( - 'field' => 'member', - 'as' => 'member_state', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'state', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member ZIP - 'member_zip' => array( - 'field' => 'member', - 'as' => 'member_zip', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'zip', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member Country - 'member_country' => array( - 'field' => 'member', - 'as' => 'member_country', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'country', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member LAT - 'member_lat' => array( - 'field' => 'member', - 'as' => 'member_lat', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'lat', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member LON - 'member_lon' => array( - 'field' => 'member', - 'as' => 'member_lon', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'lon', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member phone - 'member_phone' => array( - 'field' => 'member', - 'as' => 'member_phone', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'phone', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member payment gateways - 'member_payment_gateway' => array( - 'field' => 'member', - 'as' => 'member_payment_gateway', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'payment_gateway', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member credit cards accepted - 'member_cards_accepted' => array( - 'field' => 'member', - 'as' => 'member_cards_accepted', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'cards_accepted', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member credit cards accepted - 'member_cards_accepted' => array( - 'field' => 'member', - 'as' => 'member_cards_accepted', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'cards_accepted', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member payment gateway parameter 1 - 'member_gateway_par1' => array( - 'field' => 'member', - 'as' => 'member_gateway_par1', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'gateway_par1', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member payment gateway parameter 2 - 'member_gateway_par2' => array( - 'field' => 'member', - 'as' => 'member_gateway_par2', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'gateway_par2', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - - - ); - } - - /** - * Get Performances list - * - * @param $listType String A particular list type ('all', 'member', 'cart_promotions', ...) - * @return object containing array as sub-objects - */ - function getPerformancesList($listType = false, $memberID = false, $includeAdminOnly = false) - { - - $where = ''; - $and = ''; - - // Determine if there's a list type request (otherwise default to call parameter $listType) - if (!$listType && isset($_REQUEST['listType'])) { - $listType = $_REQUEST['listType']; - $and = ' AND '; - } - - // Check if adminUser - if (!$includeAdminOnly) { - $where .= $and.' NOT T.admin_only'; - $and = ' AND '; - } - - switch ($listType) { - - case 'member': - if ($memberID == false) { - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - } - $where .= $and."member = $memberID"; - break; - - case 'member_and_active': - if ($memberID == false) { - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - } - $where .= $and."member = $memberID AND T.active"; - break; - - case 'cart_promotions': - $where .= $and."T.promote_in_cart AND T.active AND (SELECT active FROM eventmgt.member WHERE active = true AND member.id = T.member)"; - break; - - case 'all': - default: - break; - - } - - $performancesList = $this->getList($where, 'sort, name'); - - return $performancesList; - } - - /** - * Get Performance Detail - * - * @return array - */ - function getPerformanceDetail($performanceID = false) - { - - $where = ''; - - // If a performance has been specified - if ($performanceID != false) { - - // Don't do anything here - - // Is there a new Performance code selected? - } elseif (($performanceID = filter_input(INPUT_GET, 'PerformanceID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $performanceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Performance'])) { - - // Otherwise, get the performance ID from the session - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - - } else { - - // Otherwise, we don't have a performance specified - return false; - - } - - - $performanceDetail = $this->getEntry($performanceID, 'id', $where); - - return $performanceDetail; - - } - - - /** - * Edit Performance - * - * @return array - */ - function editPerformance() - { - - if (($performanceID = filter_input(INPUT_GET, 'PerformanceID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $performanceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Performance'])) { - - // Otherwise, get the state rep ID from the session - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - $performanceDetail = $this->editEntry($performanceID); - - return $performanceDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Performance - * - * @return array - */ - function updatePerformance() - { - - if (($performanceID = filter_input(INPUT_GET, 'PerformanceID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $performanceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Performance'])) { - - // Otherwise, get the state rep ID from the session - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($performanceID); - - // If the update was successful and we ahve start and end dates, Set inventory outside of the dates set for this performance to inactive - $start = $r['fieldData']['start_date']['date']; - $end = $r['fieldData']['end_date']['date']; - if ($r['status'] && $r['fieldData']['start_date']['date'] != '' && $r['fieldData']['end_date']['date'] != '') { - $sql = " - UPDATE eventmgt.ticket_inventory - SET active = false - WHERE id in ( - SELECT I.id - FROM eventmgt.ticket T, eventmgt.ticket_inventory I - WHERE T.performance = $performanceID - AND T.id = I.ticket - AND ( I.ticket_date < '$start' OR I.ticket_date > '$end') - ) - ;"; - $this->dbh->exec($sql); - - } - - return $r; - - } - - - /** - * Add New Performance - * - * @return array - */ - function newPerformance() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert Performance - * - * @return array - */ - function insertPerformance() - { - - $r = $this->insertEntry(); - - // If succesful then set current performance to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $r['insertedID']; - } - - return $r; - - } - - - /** - * Delete Performance - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function performanceDelete($confirm = false) - { - - // Is there a new performance code selected? - if (($performanceID = filter_input(INPUT_GET, 'PerformanceID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $performanceID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Performance'])) { - - // Otherwise, get the performance ID from the session - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - - } else { - - // Otherwise, we don't have an performance id - return false; - - } - - $performanceDetail = $this->deleteEntry($performanceID, $confirm); - - return $performanceDetail; - - } - - /** - * Get Performance Inventory Summary - * - * @return array - */ - function getPerformanceInventorySummary($performanceID = false) - { - - // If a performance has been specified - if ($performanceID != false) { - - // Don't do anything here - - // Is there a new Performance code selected? - } elseif (($performanceID = filter_input(INPUT_GET, 'PerformanceID', FILTER_SANITIZE_NUMBER_INT))) { - - // Don't do anything here - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Performance'])) { - - // Otherwise, get the performance ID from the session - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - // Get detail on the performance - $performanceDetail = $this->getPerformanceDetail($performanceID); - - // Get inventory summary data for the performance - $sql = " - SELECT I.active, I.ticket_date AS date, I.ticket_time AS time, I.id AS invenID, I.quant, I.available, I.sold, - S.id AS sectionID, S.name AS sectionName, COALESCE(sum(H.quant),0) AS quantHeld, - T.name AS ticketname, T.price, t.unlimited_quant - FROM eventmgt.ticket T, eventmgt.ticket_inventory I LEFT OUTER JOIN eventmgt.inven_hold H ON (H.inventory = I.id), - eventmgt.section S - WHERE T.performance = $performanceID - AND I.ticket = T.id - AND S.id = T.section - GROUP BY I.active, I.ticket_date, I.ticket_time, I.id, I.quant, I.available, I.sold, S.id, S.name, T.name, T.price, T.unlimited_quant - ORDER BY date, time, sectionID, ticketname - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $invData = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Build inventory summary array organized by date, time, section, ticket - $sum = array(); - $date = false; - $time = false; - $section = false; - foreach ($invData as $i) { - - $dow = date('D', strtotime($i['date'])); - - $t = explode(':', $i['time']); - $ampm = 'AM'; - $hour = ($t[0] - 0); - if ($hour > 11) { - $ampm = 'PM'; - } else { - } - if ($hour > 12) { - $hour -= 12; - } - $timeString = sprintf('%2d:%02d %s', $hour, $min, $ampm); - - // Insert ticket with inventory - $s = array( - 'id' => $i['invenid'], - 'active' => $i['active'], - 'date' => $dow." ".$i['date'], - 'time' => $timeString, - 'section' => $i['sectionname'], - 'name' => $i['ticketname'], - 'unlimited_quant' => $i['unlimited_quant'], - 'quant' => $i['quant'], - 'avail' => $i['available'], - 'sold' => $i['sold'], - 'held' => $i['quantheld'], - 'netAvail' => $i['available'] - $i['held'], - 'price' => $this->money($i['price']) - ); - - // Clear redundant values - if ($i['date'] == $date) { - $s['date'] = ''; - } else { - $date = $i['date']; - $time = false; - $section = false; - } - - if ($i['time'] == $time) { - $s['time'] = ''; - } else { - $time = $i['time']; - $section = false; - } - - if ($i['sectionname'] == $section) { - $s['section'] = ''; - } else { - $section = $i['sectionname']; - } - - - $sum[] = $s; - } - - return $sum; - - } - - /** - * Format a number as money - * - * @param $value Value to format - * @param $option Options that control output - * NOPREFIX stops the "$" prefix - * - * @return none - * @access public - */ - private function money($value, $option = "") - { - - if ($option == "NOPREFIX") - $prefix = ""; - else - $prefix = "$"; - - // Do value sanity check - - if (!is_numeric($value)) - return ($prefix."0.00"); - - return ($prefix.number_format($value, 2, ".", ",")); - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataPromoSold.php b/legacy/classes/data/dataPromoSold.php deleted file mode 100755 index 9ad7ab4..0000000 --- a/legacy/classes/data/dataPromoSold.php +++ /dev/null @@ -1,268 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPromoSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataPromoSold class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPromoSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ -class EventManagementDataPromoSold extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.promo_sold'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Ticket Order - 'ticket_order' => array( - 'field' => 'ticket_order', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'niegdl' - ), - - // Ticket Sold - 'ticket_sold' => array( - 'field' => 'ticket_sold', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'niegdl' - ), - - // Promo - 'promo' => array( - 'field' => 'promo', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'niegdl' - ), - - // Promo Name - 'promo_name' => array( - 'field' => 'promo_name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Promo type - 'promo_type' => array( - 'field' => 'promo_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->promo_ticket_type->toArray(), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Promo type name - 'promo_type_name' => array( - 'field' => 'promo_type_name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Amount - 'amount' => array( - 'field' => 'amount', - 'as' => false, - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'a' - ), - - // Amount (money) - 'amount_money' => array( - 'field' => 'amount', - 'as' => 'amount_money', - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => 0.00, - 'use' => 'lgd' - ), - - // Session ID - 'session_id' => array( - 'field' => 'session_id', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - - } - - /** - * Get Ticket Sold promos list - * - * @return object containing array as sub-objects - */ - function getPromosSoldList($ticketSoldID = false, $where = false) - { - - // If a where clause has not been supplied, use the $TicketSoldID - Otherwise $where - if (!$where) { - - $where = 'true'; - - // Check if there's a ticket sold ID, then filter by that - $ticketSoldID = ($ticketSoldID - 0); // Make sure it's number - if ($ticketSoldID > 0) { - $where .= " AND T.ticket_sold = $ticketSoldID"; - } - - } - - $promosSoldList = $this->getList($where, 'id'); - - return $promosSoldList; - } - - /** - * Get Promo Sold Detail - * - * @return array - */ - function getPromoSoldDetail($promoSoldID = false) - { - - if ($promoSoldID == false) { - - // Otherwise, we don't have an promo sold id - return false; - - } - - // If the promo sold ID is valid, get the detail - $promoSoldID = filter_input(INPUT_GET, 'PromoSoldID', FILTER_SANITIZE_NUMBER_INT); - if ($promoSoldID) { - $promoSoldDetail = $this->getEntry($promoSoldID); - - // Otherwise fail - } else { - return false; - } - - return $promoSoldDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataPromoTickets.php b/legacy/classes/data/dataPromoTickets.php deleted file mode 100644 index 183b38d..0000000 --- a/legacy/classes/data/dataPromoTickets.php +++ /dev/null @@ -1,505 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPromoTickets.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataPromoTickets class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPromoTickets,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataPromoTickets extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.promo_ticket'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Promo Code - 'promo' => array( - 'field' => 'promo', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Promomotion Name - 'promo_name' => array( - 'field' => 'promo', - 'as' => 'promo_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.promo_code', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Promomotion Description - 'promo_descr' => array( - 'field' => 'promo', - 'as' => 'promo_descr', - 'type' => 'pointer', - 'p_table' => 'eventmgt.promo_code', - 'p_field' => 'descr', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Promomotion Start Date - 'promo_start_date' => array( - 'field' => 'promo', - 'as' => 'promo_start_date', - 'type' => 'pointer', - 'p_table' => 'eventmgt.promo_code', - 'p_field' => 'start_date', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Promomotion end Date - 'promo_end_date' => array( - 'field' => 'promo', - 'as' => 'promo_end_date', - 'type' => 'pointer', - 'p_table' => 'eventmgt.promo_code', - 'p_field' => 'end_date', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket ID - 'ticket' => array( - 'field' => 'ticket', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket Name - 'ticket_name' => array( - 'field' => 'ticket', - 'as' => 'ticket_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'title', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Promo type - 'promo_type' => array( - 'field' => 'promo_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->promo_ticket_type->toArray(), - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Amount - 'amount' => array( - 'field' => 'amount', - 'as' => false, - 'type' => 'float', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Check for other field related issues - * - * Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - return $r; - } - - /** - * Get Promo Ticket list - * - * If $promoID is supplied also returns sales counts for this promo for each ticket. - * Front-end shop selection of - * - * @return object containing array as sub-objects - */ - function getPromoTicketsList($promoID = false, $promoCode = false, $where = 'true') - { - - // If promoID is supplied, get only tickets listed for that promo - if ($promoID) { - $where .= " AND T.promo = $promoID"; - } - - // If promoCode is supplied, get only tickets listed for that promo - if ($promoCode) { - $where .= " AND T.promo = (SELECT id FROM eventmgt.promo_code WHERE name = '$promoCode')"; - } - - // Get list of Promo Tickets - $promoTicketsList = $this->getList($where); - - // If a Promo ID was supplied, also get the promo code use counts per ticket - If ($promoID && is_array($promoTicketsList)) { - - // If promoID is supplied, get only tickets listed for that promo - if ($promoID) { - $where = " AND P.promo = $promoID"; - } - - // Also get total Promo counts for each ticket - reset($promoTicketsList); - while (list($key, $val) = each($promoTicketsList)) { - - // Get number sold and value sold for this ticket type and promo code - $sql = " - SELECT count(P.id) as numb_sold, sum(P.amount) as value_sold - FROM eventmgt.promo_sold P, eventmgt.ticket_sold T - WHERE T.id = P.ticket_sold - AND T.ticket = ".$val['ticket']." - $where; - "; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $sales = $stmt->fetch(PDO::FETCH_ASSOC); - - // Add it to the results - $promoTicketsList[$key]['numberSold'] = $sales['numb_sold']; - $promoTicketsList[$key]['valueSold'] = $sales['value_sold']; - $promoTicketsList[$key]['dollarsSold'] = $this->money($sales['value_sold']); - - } - - } - - return $promoTicketsList; - } - - /** - * Get Promo Ticket Detail - * - * @return array - */ - function getPromoTicketDetail($promoTicketID = false) - { - - // If a promo ticket has been specified - if ($promoTicketID != false) { - - $_SESSION[GLM_EVENT_SESSION]['PromoTicket'] = $promoTicketID; - - // Otherwise if there's a promo ticket ID in the request - } elseif (($promoTicketID = filter_input(INPUT_GET, 'PromoTicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // There's a Promo Ticket submitted, so save that - $_SESSION[GLM_EVENT_SESSION]['PromoTicket'] = $promoTicketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['PromoTicket'])) { - - // Otherwise, get the promo code ID from the session - $promoTicketID = $_SESSION[GLM_EVENT_SESSION]['PromoTicket']; - - } else { - - // Otherwise, we don't have a promo ticket id - return false; - - } - - $promoTicketDetail = $this->getEntry($promoTicketID); - - return $promoTicketDetail; - - } - - /** - * Edit Promo Ticket - * - * @return array - */ - function editPromoTicket() - { - - if (($promoTicketID = filter_input(INPUT_GET, 'PromoTicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['PromoTicket'] = $promoTicketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['PromoTicket'])) { - - // Otherwise, get the promo ticket ID from the session - $promoTicketID = $_SESSION[GLM_EVENT_SESSION]['PromoTicket']; - - } else { - - // Otherwise, we don't have a promo ticket id - return false; - - } - - $promoTicketDetail = $this->editEntry($promoTicketID); - - return $promoTicketDetail; - - } - - /** - * Update Promo Ticket - * - * @return array - */ - function updatePromoTicket() - { - - if (($promoTicketID = filter_input(INPUT_GET, 'PromoTicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['PromoTicket'] = $promoTicketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['PromoTicket'])) { - - // Otherwise, get the promo ticket ID from the session - $promoID = $_SESSION[GLM_EVENT_SESSION]['PromoTicket']; - - } else { - - // Otherwise, we don't have a promo ticket id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($promoTicketID); - - return $r; - - } - - /** - * Add New Promo Ticket - * - * @return array - */ - function newPromoTicket() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert Promo Ticket - * - * @return array - */ - function insertPromoTicket() - { - - $r = $this->insertEntry(); - - // If succesful then set current promo ticket to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['PromoTicket'] = $r['insertedID']; - } - - return $r; - - } - - /** - * Delete Promo Ticket - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function promoTicketDelete($confirm = false) - { - - // Is there a new promo ticket code selected? - if (($promoTicketID = filter_input(INPUT_GET, 'PromoTicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['PromoTicket'] = $promoTicketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['PromoTicket'])) { - - // Otherwise, get the promo code ID from the session - $promoTicketID = $_SESSION[GLM_EVENT_SESSION]['PromoTicket']; - - } else { - - // Otherwise, we don't have an promo ticket id - return false; - - } - - $promoTicketDetail = $this->deleteEntry($promoTicketID, $confirm); - - return $promoTicketDetail; - - } - - - /** - * Format a number as money - * - * @param $value Value to format - * @param $option Options that control output - * NOPREFIX stops the "$" prefix - * - * @return none - * @access public - */ - private function money($value, $option = "") - { - - if ($option == "NOPREFIX") - $prefix = ""; - else - $prefix = "$"; - - // Do value sanity check - - if (!is_numeric($value)) - return ($prefix."0.00"); - - return ($prefix.number_format($value, 2, ".", ",")); - } - - - - -} - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataPromos.php b/legacy/classes/data/dataPromos.php deleted file mode 100755 index 6773d78..0000000 --- a/legacy/classes/data/dataPromos.php +++ /dev/null @@ -1,376 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPromos.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataPromos class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataPromos,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataPromos extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.promo_code'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Promo Code Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Promo Code Long Name - 'long_name' => array( - 'field' => 'long_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Start Date - 'start_date' => array( - 'field' => 'start_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // End Date - 'end_date' => array( - 'field' => 'end_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Check for other field related issues - * - * Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - // Check that Sticky is not used with date-specific inventory - if ($r['fieldData']['date_specific']['value'] && $r['fieldData']['cart_sticky']['value']) { - $r['status'] = false; - $r['fieldFail']['cart_sticky'] = 'Sticky may not be used when "Specified Dates" is checked.'; - $r['fieldFail']['date_specific'] = 'Specified dates may not be used when "Sticky" is checked.'; - } - - return $r; - } - - /** - * Get Promo Code list - * - * @return object containing array as sub-objects - */ - function getPromosList() - { - - // Build query Where clause - $where = 'true'; - - // Get list of Promo Codes - $promosList = $this->getList($where, 'start_date, name'); - - return $promosList; - } - - /** - * Get Promo Code Detail - * - * @return array - */ - function getPromoDetail($promoID = false) - { - - // If a promo code has been specified - if ($promoID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Promo'] = $promoID; - - // Otherwise if there's a promo code ID in the request - } elseif (($promoID = filter_input(INPUT_GET, 'PromoID', FILTER_SANITIZE_NUMBER_INT))) { - - // There's a Promo Code submitted, so save that - $_SESSION[GLM_EVENT_SESSION]['Promo'] = $promoID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Promo'])) { - - // Otherwise, get the promo code ID from the session - $promoID = $_SESSION[GLM_EVENT_SESSION]['Promo']; - - } else { - - // Otherwise, we don't have a promo code id - return false; - - } - - $promoDetail = $this->getEntry($promoID); - - return $promoDetail; - - } - - /** - * Edit Promo Code - * - * @return array - */ - function editPromo() - { - - if (($promoID = filter_input(INPUT_GET, 'PromoID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Promo'] = $promoID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Promo'])) { - - // Otherwise, get the promo code ID from the session - $promoID = $_SESSION[GLM_EVENT_SESSION]['Promo']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - $promoDetail = $this->editEntry($promoID); - - return $promoDetail; - - } - - /** - * Update Promo Code - * - * @return array - */ - function updatePromo() - { - - if (($promoID = filter_input(INPUT_GET, 'PromoID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Promo'] = $promoID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Promo'])) { - - // Otherwise, get the promo code ID from the session - $promoID = $_SESSION[GLM_EVENT_SESSION]['Promo']; - - } else { - - // Otherwise, we don't have a promo code id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($promoID); - - return $r; - - } - - /** - * Add New Promo Code - * - * @return array - */ - function newPromo() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert Promo Code - * - * @return array - */ - function insertPromo() - { - - $r = $this->insertEntry(); - - // If succesful then set current promo code to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Promo'] = $r['insertedID']; - } - - return $r; - - } - - /** - * Delete Promo Code - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function promoDelete($confirm = false) - { - -echo "dataPromos.php - promoDelete() - need to also delete from promo_ticket table"; - - // Is there a new promo code code selected? - if (($promoID = filter_input(INPUT_GET, 'PromoID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Promo'] = $promoID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Promo'])) { - - // Otherwise, get the promo code ID from the session - $promoID = $_SESSION[GLM_EVENT_SESSION]['Promo']; - - } else { - - // Otherwise, we don't have an promo code id - return false; - - } - - $promoDetail = $this->deleteEntry($promoID, $confirm); - - return $promoDetail; - - } - - -} - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataReservations.php b/legacy/classes/data/dataReservations.php deleted file mode 100644 index 482382b..0000000 --- a/legacy/classes/data/dataReservations.php +++ /dev/null @@ -1,830 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataReservations.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataReservations class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataReservations.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataReservations extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.reservation'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // User Trace Info - 'user_trace_info' => array( - 'field' => 'user_trace_info', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // First Name - 'fname' => array( - 'field' => 'fname', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Last Name - 'lname' => array( - 'field' => 'lname', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Team name (stored as "org") - need to clean up field name - 'org' => array( - 'field' => 'org', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Event - 'event' => array( - 'field' => 'event', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Event name - 'event' => array( - 'field' => 'event', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'event_code', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Team - 'team' => array( - 'field' => 'team', - 'as' => 'team_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.team', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // State Rep - 'state_rep' => array( - 'field' => 'state_rep', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // State Rep Code - 'state_rep_code' => array( - 'field' => 'state_rep', - 'as' => 'state_rep_code', - 'type' => 'pointer', - 'p_table' => 'eventmgt.state_rep', - 'p_field' => 'code', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member (property) - 'member' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Member (property) ID - 'member_id' => array( - 'field' => 'member', - 'as' => 'member_id', - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lg' - ), - - // Address Line 1 - 'addr1' => array( - 'field' => 'addr1', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Address Line 2 - 'addr2' => array( - 'field' => 'addr2', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // City - 'city' => array( - 'field' => 'city', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // State - 'state' => array( - 'field' => 'state', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Country - 'country' => array( - 'field' => 'country', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lnieudc' - ), - - // Country Full - Get Detail only - 'countryFull' => array( - 'field' => 'country', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->countries->toArray(), - 'list_keytype' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'g' - ), - - // ZIP - 'zip' => array( - 'field' => 'zip', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Phone - 'phone' => array( - 'field' => 'phone', - 'as' => false, - 'type' => 'phone', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - - // Contact E-Mail - 'email' => array( - 'field' => 'email', - 'as' => false, - 'type' => 'email', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // OK to sent email - 'email_ok' => array( - 'field' => 'email_ok', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Date reservation was entered. - 'date_entered' => array( - 'field' => 'date_entered', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Arrive Date - 'arrive_date' => array( - 'field' => 'arrive_date', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Nights - 'nights' => array( - 'field' => 'nights', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Number of Rooms - 'rooms' => array( - 'field' => 'rooms', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Occupants (adults) - 'adults' => array( - 'field' => 'adults', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Payment method - 'payby' => array( - 'field' => 'payby', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->pay_types->toArray(), - 'list_keytype' => 'int', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Credit Card Type - 'cctype' => array( - 'field' => 'cctype', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Credit Card Number - 'ccnumber' => array( - 'field' => 'ccnumber', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Credit Card Expiration - 'expire' => array( - 'field' => 'expire', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Name on Credit Card - 'ccname' => array( - 'field' => 'ccname', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Credit Card CCV - 'cccode' => array( - 'field' => 'cccode', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Total Room Rate for stay (formatted) - 'hotel_price' => array( - 'field' => 'hotel_price', - 'as' => false, - 'type' => 'money', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Total Room Rate for stay (number) - 'hotel_price_numb' => array( - 'field' => 'hotel_price', - 'as' => 'hotel_price_numb', - 'type' => 'float', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'l' - ), - - // Total Taxes (formatted) - 'taxes' => array( - 'field' => 'taxes', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Total Taxes (number) - 'taxes_numb' => array( - 'field' => 'taxes', - 'as' => 'taxes_numb', - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'l' - ), - - // Grand Total (formatted) - 'grand_total' => array( - 'field' => 'grand_total', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Grand Total (number) - 'grand_total_numb' => array( - 'field' => 'grand_total', - 'as' => 'grand_total_numb', - 'type' => 'float', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'l' - ), - - // Confirmed - 'confirmed' => array( - 'field' => 'confirmed', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Declined - 'declined' => array( - 'field' => 'declined', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // date_confirmed - 'date_confirmed' => array( - 'field' => 'date_confirmed', - 'as' => false, - 'type' => 'date', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Confirmed By - 'conf_by' => array( - 'field' => 'conf_by', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Confirmation Message - 'conf_message' => array( - 'field' => 'conf_message', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Reservation Detail (serialized array) - 'res_detail' => array( - 'field' => 'res_detail', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'no_stripslashes' => true, - 'use' => 'a' - ), - - // HTML Summary of Reservation - 'summary' => array( - 'field' => 'summary', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Get Reservations list - * - * @return object containing array as sub-objects - */ - function getReservationsList() - { - - // Get event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get member ID from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - // Get accommodation ID from session - if available - $accomID = $_SESSION[GLM_EVENT_SESSION]['Accom']; - - // Get team ID from session - if available - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - // Get any specified reservation listing option - default to event - $option = 'event'; - if (($resListOption = filter_input(INPUT_GET, 'ReservationsListOption', FILTER_SANITIZE_STRING))) { - $option = $resListOption; - } - $status = 'all'; - if (($resListStatus = filter_input(INPUT_GET, 'ReservationsListStatus', FILTER_SANITIZE_STRING))) { - $status = $resListStatus; - } - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'TRUE'; - break; - case 'event': - if (!$eventID) { - return false; - } - $where = "T.event = $eventID"; - break; - case 'member': - if (!$memberID) { - return false; - } - $where = "T.member = $memberID"; - break; - case 'accom': - if (!$accomID) { - return false; - } - $where = "T.accommodation = $accomID"; - break; - case 'team': - if (!$teamID) { - return false; - } - $where = "T.team_id = $memberID"; - break; - default: - echo "Option not set"; - break; - } - - // Select by status - switch ($status) { - case 'pending': - $where .= ($where!=''?' AND ':'')." NOT T.confirmed AND NOT T.declined"; - break; - case 'confirmed': - $where .= ($where!=''?' AND ':'')." T.confirmed AND NOT T.declined"; - break; - case 'declined': - $where .= ($where!=''?' AND ':'')." T.declined"; - break; - case 'all': - default: - break; - } - - // Get list of Reservations - $resList = $this->getList($where); - return $resList; - } - - /** - * Get Reservation Detail - * - * @return array - */ - function getReservationDetail() - { - - // Is there a new reservation code selected? - if (($resID = filter_input(INPUT_GET, 'ReservationID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Reservation'] = $resID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Reservation'])) { - - // Otherwise, get the team ID from the session - $resID = $_SESSION[GLM_EVENT_SESSION]['Reservation']; - - } else { - - // Otherwise, we don't have a team id - return false; - - } - - $resDetail = $this->getEntry($resID); - - // NEED TO PUT THIS CAPABILITY INTO ABSTRACT AS AN OPTION - $resDetail['summary'] = html_entity_decode($resDetail['summary']); - - // echo "
".print_r($resDetail,1)."
"; - return $resDetail; - - } - - - /** - * Edit Reservation - * - * @return array - */ - function editReservation() - { - - if (($resID = filter_input(INPUT_GET, 'ReservationID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Reservation'] = $resID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Reservation'])) { - - // Otherwise, get the team ID from the session - $teamID = $_SESSION[GLM_EVENT_SESSION]['Reservation']; - - } else { - - // Otherwise, we don't have a team id - return false; - - } - - $resDetail = $this->editEntry($resID); - - return $resDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - // Nothing here for now - - return $r; - } - - /** - * Update Reservation - * - * @return array - */ - function updateReservation() - { - - if (($resID = filter_input(INPUT_GET, 'ReservationID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Reservation'] = $resID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Reservation'])) { - - // Otherwise, get the reservation ID from the session - $resID = $_SESSION[GLM_EVENT_SESSION]['Reservation']; - - } else { - - // Otherwise, we don't have a reservation id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($resID); - - return $r; - - } - - /** - * Insert Reservation - * - * @return array - */ - function insertReservation() - { - - echo "INSERT NOT SUPPORTED FOR RESERVATIONS IN EVENT MANAGEMENT ADMIN AREA!"; - exit; - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataRooms.php b/legacy/classes/data/dataRooms.php deleted file mode 100644 index 650e8ac..0000000 --- a/legacy/classes/data/dataRooms.php +++ /dev/null @@ -1,457 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataRooms.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataRooms class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataRooms.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataRooms extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.room_detail'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Member - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Accommodation - 'accommodation' => array( - 'field' => 'accommodation', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'i' - ), - - // Occupants - 'occupants' => array( - 'field' => 'occupants', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Room Type - Needs to be moved to a separate admin table - 'room_type' => array( - 'field' => 'room_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->room_types->toArray(), - 'list_keytype' => 'int', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Bath Type - Needs to be moved to a separate admin table - 'bath_type' => array( - 'field' => 'bath_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->bath_types->toArray(), - 'list_keytype' => 'int', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Pull-out Beds - 'pullout_beds' => array( - 'field' => 'pullout_beds', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Single Beds - 'single_beds' => array( - 'field' => 'single_beds', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Double Beds - 'double_beds' => array( - 'field' => 'double_beds', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Queen Beds - 'queen_beds' => array( - 'field' => 'queen_beds', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // King Beds - 'king_beds' => array( - 'field' => 'king_beds', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // TV - 'tv' => array( - 'field' => 'tv', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Fridge - 'fridge' => array( - 'field' => 'fridge', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Safe - 'safe' => array( - 'field' => 'safe', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Display Order (sort) - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ) - - ); - } - - /** - * Get Rooms list - * - * @return object containing array as sub-objects - */ - function getRoomsList() - { - - // Get accommodation ID from session - if available - $accomID = $_SESSION[GLM_EVENT_SESSION]['Accom']; - - if (!$accomID) { - return false; - } - - // Select type of list - $where = "T.accommodation = $accomID"; - - // Get list of States - $roomsList = $this->getList($where, 'sort'); - - // Build Beds summary - if ($roomsList && count($roomsList) > 0) { - reset($roomsList); - while( list($key, $val) = each( $roomsList ) ) { - $beds_summary = ''; - $sep = ''; - if ($val['pullout_beds'] > 0) { - $beds_summary .= $val['pullout_beds']." Pullout"; - $sep = ', '; - } - if ($val['single_beds'] > 0) { - $beds_summary .= $sep.$val['single_beds']." Single"; - $sep = ', '; - } - if ($val['double_beds'] > 0) { - $beds_summary .= $sep.$val['double_beds']." Double"; - $sep = ', '; - } - if ($val['queen_beds'] > 0) { - $beds_summary .= $val['queen_beds']." Queen"; - $sep = ', '; - } - if ($val['king_beds'] > 0) { - $beds_summary .= $val['king_beds']." King"; - $sep = ', '; - } - $roomsList[$key]['beds_summary'] = $beds_summary; - } - } - - return $roomsList; - } - - /** - * Get Room Detail - * - * @return array - */ - function getRoomDetail() - { - - // Is there a new State Rep code selected? - if (!($roomID = filter_input(INPUT_GET, 'RoomID', FILTER_SANITIZE_NUMBER_INT))) { - - return false; - - } - - $roomDetail = $this->getEntry($roomID); - - return $roomDetail; - - } - - - /** - * Edit Room - * - * @return array - */ - function editRoom() - { - if (!($roomID = filter_input(INPUT_GET, 'RoomID', FILTER_SANITIZE_NUMBER_INT))) { - - // Otherwise, we don't have a state rep id - return false; - - } - - $roomDetail = $this->editEntry($roomID); - - $roomDetail['RoomID'] = $roomID; - - // echo "
".print_r($roomDetail,1)."
"; - return $roomDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Room - * - * @return array - */ - function updateRoom() - { - - if (!($roomID = filter_input(INPUT_POST, 'RoomID', FILTER_SANITIZE_NUMBER_INT))) { - return false; - } - - // Try to update this data - $r = $this->updateEntry($roomID); - - $r['fieldData']['RoomID'] = $roomID; - - return $r; - - } - - - /** - * Add New Room - * - * @return array - */ - function newRoom() - { - // Get member and accommodation ID from session - if available - $membID = $_SESSION[GLM_EVENT_SESSION]['Member']; - $accomID = $_SESSION[GLM_EVENT_SESSION]['Accom']; - - if (!$accomID) { - return false; - } - - $r = $this->newEntry(); - - $r['fieldData']['member'] = $membID; - $r['fieldData']['accommodation'] = $accomID; - - return $r; - - } - - /** - * Insert Room - * - * @return array - */ - function insertRoom() - { - - $r = $this->insertEntry(); - - // If succesful then set current state rep to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['State'] = $r['insertedID']; - } - - return $r; - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataSections.php b/legacy/classes/data/dataSections.php deleted file mode 100644 index ae768c4..0000000 --- a/legacy/classes/data/dataSections.php +++ /dev/null @@ -1,450 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataSections.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataSections class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataSections.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataSections extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.section'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Member ID for adding sections - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'use' => 'nid' - ), - - // Member Name display - 'member_view' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Section Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Entrance - 'entrance' => array( - 'field' => 'entrance', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.entrance', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_where' => 'member = '.$_SESSION[GLM_EVENT_SESSION]['Member'], - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'nideu' - ), - - // Entrance_view - 'entrance_view' => array( - 'field' => 'entrance', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.entrance', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Entrance_id - 'entrance_id' => array( - 'field' => 'entrance', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Sort order - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 999, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - - ); - } - - /** - * Get Sections list - * - * @return object containing array as sub-objects - */ - function getSectionsList($memberID = false, $where = false) - { - - // If a where clause has not been supplied - if (!$where) { - - $where = 'true'; - - // Check if there's a member ID and filter by that member if there is - $memberID = ($memberID - 0); // Make sure it's number - if ($memberID > 0) { - $where .= " AND T.member = $memberID"; - } elseif ($_SESSION[GLM_EVENT_MGT_ADMIN]['Member'] > 0) { - $where .= " AND T.member = ".$_SESSION[GLM_EVENT_MGT_ADMIN]['Member']; - } - - } - - // Get list of Sections - $sectionsList = $this->getList($where, 'sort, name'); - - return $sectionsList; - } - - /** - * Get Section Detail - * - * @return array - */ - function getSectionDetail($sectionID = false) - { - - // If a section ID has been supplied - if ($sectionID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Section'] = $sectionID; - - } elseif (($sectionID = filter_input(INPUT_GET, 'SectionID', FILTER_SANITIZE_NUMBER_INT))) { - - // Otherwise if there a new section ID supplied via the request - $_SESSION[GLM_EVENT_SESSION]['Section'] = $sectionID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Section'])) { - - // Otherwise, get the event ID from the session - $sectionID = $_SESSION[GLM_EVENT_SESSION]['Section']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - $sectionDetail = $this->getEntry($sectionID); - - return $sectionDetail; - - } - - - /** - * Edit Section - * - * @return array - */ - function editSection() - { - - if (($sectionID = filter_input(INPUT_GET, 'SectionID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Section'] = $sectionID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Section'])) { - - // Otherwise, get the section ID from the session - $sectionID = $_SESSION[GLM_EVENT_SESSION]['Section']; - - } else { - - // Otherwise, we don't have a section id - return false; - - } - - $sectionDetail = $this->editEntry($sectionID); - - return $sectionDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Section - * - * @return array - */ - function updateSection() - { - - if (($sectionID = filter_input(INPUT_GET, 'SectionID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Section'] = $sectionID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Section'])) { - - // Otherwise, get the section ID from the session - $sectionID = $_SESSION[GLM_EVENT_SESSION]['Section']; - - } else { - - // Otherwise, we don't have a section id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($sectionID); - - return $r; - - } - - - /** - * Add New Section - * - * @return array - */ - function newSection() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert Section - * - * @return array - */ - function insertSection() - { - - $r = $this->insertEntry(); - - // If succesful then set current section to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Section'] = $r['insertedID']; - } - - return $r; - - } - - - /** - * Delete Section - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function sectionDelete($confirm = false) - { - - // Is there a new section code selected? - if (($sectionID = filter_input(INPUT_GET, 'SectionID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Section'] = $sectionID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Section'])) { - - // Otherwise, get the section ID from the session - $sectionID = $_SESSION[GLM_EVENT_SESSION]['Section']; - - } else { - - // Otherwise, we don't have an section id - return false; - - } - - $sectionDetail = $this->deleteEntry($sectionID, $confirm); - - return $sectionDetail; - - } - - /** - * Get Sections Stats - * - * @return object containing array as sub-objects - */ - function getSectionsStats($where = 'true') - { - - $sectionsStats = $this->getStats($where); - - return $sectionsStats; - } - - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataSold.php b/legacy/classes/data/dataSold.php deleted file mode 100644 index 19974bf..0000000 --- a/legacy/classes/data/dataSold.php +++ /dev/null @@ -1,789 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataSold class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataSold,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataSold extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.ticket_sold'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Ticket Sold (Voucher) ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Order ID - 'ticket_order' => array( - 'field' => 'ticket_order', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Member ID - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Member Name - 'member_name' => array( - 'field' => 'member_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Assigned (consignment to another venue) - 'assigned' => array( - 'field' => 'assigned', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Assigned From ID - 'assigned_from' => array( - 'field' => 'assigned_from', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Assigned from name - 'assigned_from_name' => array( - 'field' => 'assigned_from_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Performance ID - 'performance' => array( - 'field' => 'performance', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Performance Name - 'performance_name' => array( - 'field' => 'performance_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Entrance ID - 'entrance' => array( - 'field' => 'entrance', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Entrance Name - 'entrance_name' => array( - 'field' => 'entrance_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Entrance Color - 'entrance_color' => array( - 'field' => 'entrance_color', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Section ID - 'section' => array( - 'field' => 'section', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Section Name - 'section_name' => array( - 'field' => 'section_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Ticket ID - 'ticket' => array( - 'field' => 'ticket', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Ticket Name - 'ticket_name' => array( - 'field' => 'ticket_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Is Package - 'is_package' => array( - 'field' => 'is_package', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Ticket Package - points to ticket that is a package that includes this ticket - 0 if not part of a package - 'ticket_package' => array( - 'field' => 'ticket_package', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Package Sold ID - 'package_sold_id' => array( - 'field' => 'package_sold_id', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Package Name - 'package_name' => array( - 'field' => 'package_name', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Ticket Voucher Text - 'ticket_voucher_text' => array( - 'field' => 'ticket', - 'as' => 'ticket_voucher_text', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'voucher_text', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Ticket Voucher Type - 'ticket_voucher_type' => array( - 'field' => 'ticket', - 'as' => 'ticket_voucher_type', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'voucher_type', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Ticket Voucher Left End Text - 'ticket_voucher_leftend_text' => array( - 'field' => 'ticket', - 'as' => 'ticket_voucher_leftend_text', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'voucher_leftend_text', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Date Specific flag - 'date_specific' => array( - 'field' => 'date_specific', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Ticket Date - 'ticket_date' => array( - 'field' => 'ticket_date', - 'as' => false, - 'type' => 'date', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Time Specific flag - 'time_specific' => array( - 'field' => 'time_specific', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Ticket Time - 'ticket_time' => array( - 'field' => 'ticket_time', - 'as' => false, - 'type' => 'time', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Start Date for non-date-specific tickets - 'start_date' => array( - 'field' => 'start_date', - 'as' => false, - 'type' => 'date', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // End Date for non-date-specific tickets - 'end_date' => array( - 'field' => 'end_date', - 'as' => false, - 'type' => 'date', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Date customer will likely use this ticket - 'likely_date' => array( - 'field' => 'likely_date', - 'as' => false, - 'type' => 'date', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Price Paid - 'price_paid' => array( - 'field' => 'price_paid', - 'as' => false, - 'type' => 'money', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Policies at time of order - 'policies' => array( - 'field' => 'policies', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Unlimited Use flag - 'unlimited_use' => array( - 'field' => 'unlimited_use', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Number of uses - 'numb_uses' => array( - 'field' => 'numb_uses', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ), - - // Number of times claimed - 'numb_claimed' => array( - 'field' => 'numb_claimed', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgd' - ), - - // Time Claimed - 'time_claimed' => array( - 'field' => 'time_claimed', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y h:i:s A', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lged' - ) - - ); - } - - - /** - * Get Orders list - * - * @return object containing array as sub-objects - */ - function getSoldList($orderID = false, $memberID = false) - { - - // If a order has been specified - if ($orderID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Order'] = $orderID; - - // Otherwise if there's a order ID in the request - } elseif (($orderID = filter_input(INPUT_GET, 'OrderID', FILTER_SANITIZE_NUMBER_INT))) { - - $_SESSION[GLM_EVENT_SESSION]['Order'] = $orderID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Order'])) { - - $orderID = $_SESSION[GLM_EVENT_SESSION]['Order']; - - } else { - - // Otherwise, we don't have an order id - return false; - - } - - $where = ''; - if ($memberID) { - $where = "AND T.member = $memberID"; - } - - // Get list of Tickets Sold - $soldList = $this->getList("T.ticket_order = $orderID $where", 'T.ticket_order, T.package_sold_id, T.id'); - - // Load addonsSold class - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addonsSold.php'; - $addonsSold = new EventManagementAdminAddonsSold($this->dbh, $this->config); - - // For each ticket, check for any add-ons that have been sold with it - if ($soldList != false) { - reset($soldList); - while (list($key, $val) = each($soldList)) { - // Get any add-ons included with this ticket - $addonsSoldList = $addonsSold->getAddonsSoldList($val['id']); - if ($addonsSoldList) { - $soldList[$key]['addons_sold'] = $addonsSoldList; - } - } - } - - return $soldList; - } - - /** - * Get Ticket Sold Detail - * - * @return array - */ - function getSoldDetail($soldID = false, $memberID = false) - { - // Test Check character - $testCheck = false; - - // If a order has been specified - if ($soldID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Sold'] = $soldID; - - // Otherwise if there's a sold ID in the request - } elseif (($soldID = filter_input(INPUT_GET, 'SoldID', FILTER_SANITIZE_STRING))) { - - // Do a check character test if input from form. - $testCheck = true; - - $_SESSION[GLM_EVENT_SESSION]['Sold'] = $soldID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Sold'])) { - - $soldID = $_SESSION[GLM_EVENT_SESSION]['Sold']; - - } else { - - // Otherwise, we don't have an ticket sold id - return false; - - } - - $checkBypass = filter_input(INPUT_GET, 'checkBypass', FILTER_SANITIZE_STRING); - if ( $checkBypass == 'true') { - $testCheck = false; - } - - - $where = ''; - if ($memberID) { - $where = "AND T.member = $memberID"; - } - - // If input came from form, then test the check char - $voucherNumb = $soldID; - if ($testCheck) { - // Separate check character from voucher number - $voucherNumb = substr($soldID, 0, -2); - $checkChar = substr($soldID, -2); - - // Check if check character - $c = $this->getCheckCode($voucherNumb); - if ($c != strtoupper($checkChar)) { - - return false; - } - } - - // If number has - $soldDetail = $this->getEntry($voucherNumb, 'id', $where); - - // If we have a member ID then make sure the sold ticket is for that member - if ($memberID && $soldDetail['member'] != $memberID) { - return false; - } - - return $soldDetail; - - } - - - /** - * Edit Sold - * - * @return array - */ - function editSold() - { -echo "editSold() not competed"; -/* - if (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - $ticketDetail = $this->editEntry($ticketID); - - return $ticketDetail; -*/ - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Ticket Sold - * - * @return array - */ - function updateSold() - { - -echo "updateSold() not competed"; -/* - if (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($ticketID); - - return $r; -*/ - } - - /** - * Delete Ticket Sold - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function soldDelete($confirm = false) - { -echo "soldDelete() not competed"; -/* - - // Is there a new ticket code selected? - if (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have an ticket id - return false; - - } - - $ticketDetail = $this->deleteEntry($ticketID, $confirm); - - return $ticketDetail; -*/ - } - - - /* - * Function to add check character to end of voucher number - * - * Uses config->voucher_check_secret and voucher # to create MD5 string - * then takes last hex character off of that string and shifts it up to - * always be a character (adds 16 to numbers and 10 to the upper-case - * version of the character). - * i.e. 0 = A, 9 = J, A = K, F = - * - */ - public function getCheckCode($voucherNumb) - { - - // Create MD5 string using voucher number and secret - $md5 = md5($voucherNumb.$this->config->voucher_check_secret); - - // Get last character code of the last character in the MD5 - $cc = strtoupper(substr($md5, -2)); - $cc[0] = $this->shiftCheckCodeCharacter($cc[0]); - $cc[1] = $this->shiftCheckCodeCharacter($cc[1]); - - // Return check code - return $cc; - - } - - private function shiftCheckCodeCharacter($c) { - - $x = ord($c); - - // If it's a digit, add 16 - if ($x < 65) { - $x += 17; - // otherwise, add 10 - } else { - $x += 10; - } - - // Also skip the letter O - if (x >= ord('O')) { - $x += 1; - } - - return chr($x); - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataStates.php b/legacy/classes/data/dataStates.php deleted file mode 100644 index 7fe8857..0000000 --- a/legacy/classes/data/dataStates.php +++ /dev/null @@ -1,363 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataStates.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataStates class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataStates.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataStates extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.state_rep'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Event selection - 'conv' => array( - 'field' => 'conv', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'nid' - ), - - // Event Name display - 'conv_view' => array( - 'field' => 'conv', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // State Rep Code - 'code' => array( - 'field' => 'code', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Password - 'password' => array( - 'field' => 'password', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Get States list - * - * @return object containing array as sub-objects - */ - function getStatesList() - { - - // Get event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get any specified state rep listing option - default to event - $option = 'event'; - if (($statesListOption = filter_input(INPUT_GET, 'StatesListOption', FILTER_SANITIZE_STRING))) { - $option = $statesListOption; - } - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'TRUE'; - break; - case 'event': - if (!$eventID) { - return false; - } - $where = "T.conv = $eventID"; - break; - default: - echo "Option not set"; - break; - } - - // Get list of States - $statesList = $this->getList($where, 'code'); - - return $statesList; - } - - /** - * Get State Rep Detail - * - * @return array - */ - function getStateDetail() - { - - // Is there a new State Rep code selected? - if (($stateID = filter_input(INPUT_GET, 'StateID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['State'] = $stateID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['State'])) { - - // Otherwise, get the state rep ID from the session - $stateID = $_SESSION[GLM_EVENT_SESSION]['State']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - $stateDetail = $this->getEntry($stateID); - - return $stateDetail; - - } - - - /** - * Edit State Rep - * - * @return array - */ - function editState() - { - - if (($stateID = filter_input(INPUT_GET, 'StateID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['State'] = $stateID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['State'])) { - - // Otherwise, get the state rep ID from the session - $stateID = $_SESSION[GLM_EVENT_SESSION]['State']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - $stateDetail = $this->editEntry($stateID); - - return $stateDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update State Rep - * - * @return array - */ - function updateState() - { - - if (($stateID = filter_input(INPUT_GET, 'StateID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['State'] = $stateID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['State'])) { - - // Otherwise, get the state rep ID from the session - $stateID = $_SESSION[GLM_EVENT_SESSION]['State']; - - } else { - - // Otherwise, we don't have a state rep id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($stateID); - - return $r; - - } - - - /** - * Add New State Rep - * - * @return array - */ - function newState() - { - - $r = $this->newEntry(); - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $event = isset($_SESSION[GLM_EVENT_SESSION]['Event']); - $r['fieldData']['event_name']['pick_list'][$event]['default'] = true; - } - - return $r; - - } - - /** - * Insert State Rep - * - * @return array - */ - function insertState() - { - - $r = $this->insertEntry(); - - // If succesful then set current state rep to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['State'] = $r['insertedID']; - } - - return $r; - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataTeams.php b/legacy/classes/data/dataTeams.php deleted file mode 100644 index 73e8e51..0000000 --- a/legacy/classes/data/dataTeams.php +++ /dev/null @@ -1,735 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTeams.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataTeams class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTeams.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ -class EventManagementDataTeams extends DataAbstract -{ - /** - * Field definitions - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.team'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lg' - ), - - // Event selection - 'event' => array( - 'field' => 'event', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'nid' - ), - - // Event Name display - 'event_view' => array( - 'field' => 'event', - 'as' => 'event_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.event', - 'p_field' => 'event_code', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // State (rep) selection - 'state' => array( - 'field' => 'state', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.state_rep', - 'p_field' => 'code', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'ni' - ), - - // State (rep) Name display - 'state_view' => array( - 'field' => 'state', - 'as' => 'state_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.state_rep', - 'p_field' => 'code', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Division selection - 'division' => array( - 'field' => 'division', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.division', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'nid' - ), - - // Division Name display - 'division_view' => array( - 'field' => 'division', - 'as' => 'division_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.division', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Team name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Team Code - 'team_code' => array( - 'field' => 'team_code', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Participants - 'participants' => array( - 'field' => 'participants', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Notes - 'notes' => array( - 'field' => 'notes', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Get Teams list - * - * @return object containing array as sub-objects - */ - function getTeamsList() - { - - // Get event ID from session - if available - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - // Get member ID from session - if available - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - - // Clear Session Team Selection -// $_SESSION[GLM_EVENT_SESSION]['Team'] = false; - - // Get any specified team listing option - default to event - $option = 'event'; - if (($teamsListOption = filter_input(INPUT_GET, 'TeamsListOption', FILTER_SANITIZE_STRING))) { - $option = $teamsListOption; - } - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'TRUE'; - break; - case 'member': - if (!$memberID) { - return false; - } - $where = " - T.id in ( - SELECT team - FROM team_property - WHERE property = $memberID - ) - "; - break; - case 'event': - if (!$eventID) { - return false; - } - $where = "T.event = $eventID"; - break; - default: - echo "Option not set"; - break; - } - - // Get list of Teams - $teamsList = $this->getList($where, 'event_name,state_name,division_name,name'); - - return $teamsList; - } - - /** - * Get Team Detail - * - * @return array - */ - function getTeamDetail() - { - - // Is there a new team code selected? - if (($teamID = filter_input(INPUT_GET, 'TeamID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Team'] = $teamID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Team'])) { - - // Otherwise, get the team ID from the session - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - } else { - - // Otherwise, we don't have a team id - return false; - - } - - $teamDetail = $this->getEntry($teamID); - $teamRoster = $this->getTeamRoster($teamID, $teamDetail['participants']); - - $r = array( - 'teamDetail' => $teamDetail, - 'teamRoster' => $teamRoster - ); - - return $r; - - } - - /** - * Get Team Roster - * - * @return array - */ - function getTeamRoster($teamID, $participants) - { - // Try to get team roster - $sql = "SELECT * - FROM team_roster - WHERE team = $teamID - ORDER BY - CASE lname WHEN '' THEN 'ZZZZZZZ' ELSE lname END, - CASE fname WHEN '' THEN 'ZZZZZZZ' ELSE fname END;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $teamRoster = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Did we get less entries than team members listed? - if (count($teamRoster) < $participants) { - // Add number of additional participant slots to roster - $sql2 = array(); - for ($i=count($teamRoster) ; $i<$participants ; $i++ ) { - $sql2[] = "INSERT INTO eventmgt.team_roster (team) values ($teamID);"; - } - - try { - $this->dbh->beginTransaction(); - foreach ($sql2 as $s) { - $this->dbh->exec($s); - } - $this->dbh->commit(); - } catch (Exception $e) { - $this->dbh->rollBack(); - } - - // Get the team roster again - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $teamRoster = $stmt->fetchAll(PDO::FETCH_ASSOC); - } - - // Convert to array that has the roster ids as the index - $tr = array(); - foreach($teamRoster as $r) { - $tr[$r['id']] = $r; - } - - return $tr; - } - - - /** - * Edit Team - * - * @return array - */ - function editTeam() - { - - if (($teamID = filter_input(INPUT_GET, 'TeamID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Team'] = $teamID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Team'])) { - - // Otherwise, get the team ID from the session - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - } else { - - // Otherwise, we don't have a team id - return false; - - } - - $teamDetail = $this->editEntry($teamID); - - // echo "
".print_r($teamDetail,1)."
"; - return $teamDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); -/* - $fd = $r['fieldData']; - - // Is Start date is later than End date - if (strtotime($fd['start_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['start_date'] = 'Start date is later than end date.'; - $r['status'] = false; - } - - // Is cutoff date is later than end date - if (strtotime($fd['cutoff_date']) > strtotime($fd['end_date'])) { - $r['fieldFail']['cutoff_date'] = 'Cutoff date is later than end date.'; - $r['status'] = false; - } -*/ - return $r; - } - - /** - * Update Team - * - * @return array - */ - function updateTeam() - { - - if (($teamID = filter_input(INPUT_GET, 'TeamID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Team'] = $teamID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Team'])) { - - // Otherwise, get the team ID from the session - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - } else { - - // Otherwise, we don't have a team id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($teamID); - - return $r; - - } - - - /** - * Add New Team - * - * @return array - */ - function newTeam() - { - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - // Don't have a selected Event, so can't add a team. - return false; - } - - // Set the p_where values for State Rep and Division picklists to only display ones associated - // with the selected event. - $this->fields['state']['p_where'] = "event = $eventID"; - $this->fields['division']['p_where'] = "event = $eventID"; - - $r = $this->newEntry(); - - // Add selected event id and name for display in new team form - $r['fieldData']['event']['value'] = $eventID; - $r['fieldData']['event']['name'] = $r['fieldData']['event']['pick_list'][$eventID]['name']; - - // Set selected event - Note that the template should actally not be using the event pick_list - // for new team entry unless we get the page to reload with the correct State Rep and Division lists. - $r['fieldData']['event']['pick_list'][$eventID]['default'] = true; - - // If there's a currently selected State, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['State']) && $_SESSION[GLM_EVENT_SESSION]['State'] != false) { - $stateID = isset($_SESSION[GLM_EVENT_SESSION]['State']); - $r['fieldData']['state']['pick_list'][$stateID]['default'] = true; - } - - // If there's a currently selected Division, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Division']) && $_SESSION[GLM_EVENT_SESSION]['Division'] != false) { - $divisionID = isset($_SESSION[GLM_EVENT_SESSION]['Division']); - $r['fieldData']['division']['pick_list'][$divisionID]['default'] = true; - } - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - /** - * Insert Team - * - * @return array - */ - function insertTeam() - { - - // If there's a currently selected Event, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Event']) && $_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - // Don't have a selected Event, so can't add a team. - return false; - } - - // Set the p_where values for State Rep and Division picklists to only display ones associated - // with the selected event. - $this->fields['state']['p_where'] = "event = $eventID"; - $this->fields['division']['p_where'] = "event = $eventID"; - - $r = $this->insertEntry(); - - // If succesful then set current team to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Team'] = $r['insertedID']; - } - - // Add selected event name and value for display in new team form - $r['fieldData']['event']['name'] = $r['fieldData']['event']['pick_list'][$eventID]['name']; - $r['fieldData']['event']['value'] = $eventID; - - // Set selected event - Note that the template should actally not be using the event pick_list - // for new team entry unless we get the page to reload with the correct State Rep and Division lists. - $r['fieldData']['event']['pick_list'][$eventID]['default'] = true; - - // If there's a currently selected State, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['State']) && $_SESSION[GLM_EVENT_SESSION]['State'] != false) { - $stateID = $_SESSION[GLM_EVENT_SESSION]['State']; - $r['fieldData']['state']['pick_list'][$stateID]['default'] = true; - } - - // If there's a currently selected Division, set that as default - if (isset($_SESSION[GLM_EVENT_SESSION]['Division']) && $_SESSION[GLM_EVENT_SESSION]['Division'] != false) { - $divisionID = $_SESSION[GLM_EVENT_SESSION]['Division']; - $r['fieldData']['division']['pick_list'][$divisionID]['default'] = true; - } - - // echo "
".print_r($r,1)."
"; - return $r; - - } - - /** - * Edit Team Roster - * - * @return array - */ - function editTeamRoster() - { - - if (($teamID = filter_input(INPUT_GET, 'TeamID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Team'] = $teamID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Team'])) { - - // Otherwise, get the team ID from the session - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - } else { - - // Otherwise, we don't have a team id - return false; - - } - - // Get team detail for reference - $teamDetail = $this->getEntry($teamID); - - $teamRoster = $this->getTeamRoster($teamID, $teamDetail['participants']); - - $r = array( - 'teamDetail' => $teamDetail, - 'teamRoster' => $teamRoster - ); - - return $r; - - } - - /** - * Update Team Roster - * - * @return array - */ - function updateTeamRoster() - { - - if (($teamID = filter_input(INPUT_GET, 'TeamID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Team'] = $teamID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Team'])) { - - // Otherwise, get the team ID from the session - $teamID = $_SESSION[GLM_EVENT_SESSION]['Team']; - - } else { - - // Otherwise, we don't have a team id - return false; - - } - - // Get team detail for reference - $teamDetail = $this->getEntry($teamID); - - $teamRoster = $this->getTeamRoster($teamID, $teamDetail['participants']); - - $fieldFail = array(); - $status = true; - - // Filter and sanitize all input arrays - $lname_in = filter_input(INPUT_POST, "lname", FILTER_SANITIZE_STRING, FILTER_FLAG_NO_ENCODE_QUOTES|FILTER_REQUIRE_ARRAY); - $fname_in = filter_input(INPUT_POST, "fname", FILTER_SANITIZE_STRING, FILTER_FLAG_NO_ENCODE_QUOTES|FILTER_REQUIRE_ARRAY); - $pos_in = filter_input(INPUT_POST, "pos", FILTER_SANITIZE_STRING, FILTER_FLAG_NO_ENCODE_QUOTES|FILTER_REQUIRE_ARRAY); - $notes_in = filter_input(INPUT_POST, "notes", FILTER_SANITIZE_STRING, FILTER_FLAG_NO_ENCODE_QUOTES|FILTER_REQUIRE_ARRAY); - - // For each participant - while (list($key, $val) = each($lname_in)) { - - // Last Name - if ($lname_in[$key] || $lname_in[$key] == '') { - $teamRoster[$key]['lname'] = $lname_in[$key]; - $fieldFail[$key]['lname'] = false; - } else { - $fieldFail[$key]['lname'] = 'Provided input was not a valid string.'; - $status = false; - } - - // First Name - if ($fname_in[$key] || $fname_in[$key] == '') { - $teamRoster[$key]['fname'] = $fname_in[$key]; - $fieldFail[$key]['fname'] = false; - } else { - $fieldFail[$key]['fname'] = 'Provided input was not a valid string.'; - $status = false; - } - - // Position - if ($pos_in[$key] || $pos_in[$key] == '') { - $teamRoster[$key]['pos'] = $pos_in[$key]; - $fieldFail[$key]['pos'] = false; - } else { - $fieldFail[$key]['pos'] = 'Provided input was not a valid string.'; - $status = false; - } - - // Notes - if ($notes_in[$key] || $notes_in[$key] == '') { - $teamRoster[$key]['notes'] = $notes_in[$key]; - $fieldFail[$key]['notes'] = false; - } else { - $fieldFail[$key]['notes'] = 'Provided input was not a valid string.'; - $status = false; - } - } - - // If submission is safe, then update the roster table - if ($status) { - $sql = array(); - foreach ($teamRoster as $r) { - $sql[] = "UPDATE team_roster - SET lname = '".addslashes($r['lname'])."', - fname = '".addslashes($r['fname'])."', - pos = '".addslashes($r['pos'])."', - notes = '".addslashes($r['notes'])."' - WHERE id = ".$r['id'].";"; - } - - try { - $this->dbh->beginTransaction(); - foreach ($sql as $s) { - $this->dbh->exec($s); - } - $this->dbh->commit(); - } catch (Exception $e) { - $this->dbh->rollBack(); - } - - // Get team roster again so it's propety ordered - $teamRoster = $this->getTeamRoster($teamID, $teamDetail['participants']); - - } - - $r = array( - 'status' => $status, - 'teamDetail' => $teamDetail, - 'teamRoster' => $teamRoster, - 'fieldFail' => $fieldFail - ); - - return $r; - - } - - - -} - - - - -?> diff --git a/legacy/classes/data/dataTicketClaimTracking.php b/legacy/classes/data/dataTicketClaimTracking.php deleted file mode 100644 index bbc8ed0..0000000 --- a/legacy/classes/data/dataTicketClaimTracking.php +++ /dev/null @@ -1,216 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTicketClaimTtracking.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataTicketClaimTracking class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTicketClaimTracking,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ -class EventManagementDataTicketClaimTracking extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.ticket_claim_tracking'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Ticket Order - 'ticket_order' => array( - 'field' => 'ticket_order', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Ticket Sold - 'ticket_sold' => array( - 'field' => 'ticket_sold', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Time of scan (timestamp) - 'time_of_action' => array( - 'field' => 'time_of_action', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Action Type - 'action_type' => array( - 'field' => 'action_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->member_type->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 1, - 'use' => 'a' - ), - - // Quantity - 'quant' => array( - 'field' => 'quant', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Scan User - 'scan_user' => array( - 'field' => 'scan_user', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Scan Name - 'scan_name' => array( - 'field' => 'scan_name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Attendance Entry - 'attendance' => array( - 'field' => 'attendance', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Attendee Name - 'attendee_name' => array( - 'field' => 'attendee_name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Attendee Notes - 'attendee_notes' => array( - 'field' => 'attendee_notes', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ) - - ); - } - - /** - * Check for other field related issues - * - * Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - return $r; - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataTicketInventory.php b/legacy/classes/data/dataTicketInventory.php deleted file mode 100644 index 36efe6c..0000000 --- a/legacy/classes/data/dataTicketInventory.php +++ /dev/null @@ -1,683 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTicketInventory.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataTickets class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTickets,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataTicketInventory extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.ticket_inventory'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Ticket ID - 'ticket' => array( - 'field' => 'ticket', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Ticket'], - 'use' => 'nid' - ), - - // Member ID - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'use' => 'lged' - ), - - // Member Name - 'member_view' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket Name Display - 'ticket_view' => array( - 'field' => 'ticket', - 'as' => 'ticket_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket ID - 'ticket_id' => array( - 'field' => 'ticket', - 'as' => 'ticket_id', - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Date - 'ticket_date' => array( - 'field' => 'ticket_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'lgnid' - ), - - // Ticket time - 'ticket_time' => array( - 'field' => 'ticket_time', - 'as' => false, - 'type' => 'time', -// 'format' => 'm/d/Y', -// 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now -// 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'lgnidu' - ), - - // Ticket Unlimited Quantity - 'unlimited_quant' => array( - 'field' => 'ticket', - 'as' => 'unlimited_quant', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'unlimited_quant', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket is Cart Sticky - 'cart_sticky' => array( - 'field' => 'ticket', - 'as' => 'cart_sticky', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'cart_sticky', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Quantity Allotted - 'quant' => array( - 'field' => 'quant', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Available - 'available' => array( - 'field' => 'available', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Available - 'sold' => array( - 'field' => 'sold', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // On Hold - 'on_hold' => array( - 'field' => 'id', - 'as' => 'on_hold', - 'type' => 'pointer', - 'p_table' => 'eventmgt.inven_hold', - 'p_field' => 'quant', - 'p_id' => 'inventory', - 'p_where' => " - hold_type = ".$this->config->hold_types->ticket." AND - expire_time > '".date('r')."' AND - inventory = T.id", - 'p_sum' => true, - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'lg' - ), - - // Active - 'active' => array( - 'field' => 'active', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Ticket sort order - 'ticket_sort' => array( - 'field' => 'ticket', - 'as' => 'ticket_sort', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'sort', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Section ID - retrieval only - 'section' => array( - 'field' => 'ticket', - 'as' => 'section', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'section', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'g' - ) - - - ); - } - - - /** - * Get Ticket Inventory - * - * @return object containing array as sub-objects - */ - function getTicketInventoryList($ticketID = false, $where = false, $dateKey = false) - { - - // If ticket ID is -1, then don't use ticket ID in search. - if ($ticketID == -1) { - - $ticketID = false; - - // If a ticket ID is specified - } elseif ($ticketID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If there's a new ticket code submitted then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have a ticket id - This should not be a problem - - } - - // If we have a ticket id, use that for inventory selection - $ticketWhere = 'true '; - if ($ticketID) { - $ticketWhere = "T.ticket = $ticketID "; - } - - // Check for Where clause supplied - if ($where) { - $where = "AND $where "; - } - - // Get list of Inventory - $invData = $this->getList($ticketWhere.$where, 'ticket_date'); - - // Convert to array with timestamp or ID as index - $inventoryData = array(); - if ($invData != false) { - foreach ($invData as $i) { - - // If the inventory item has a date and we're getting inventory for a specific ticketID - if (trim($i['ticket_date']['date']) != '' && $ticketID) { - - // Use ticket timestamp for index - $inventoryData[$i['ticket_date']['timestamp']] = $i; - - // Otherwise just use inventory ID (it's a non-date specific ticket) - } else { - $inventoryData[$i['id']] = $i; - } - } - } - - return $inventoryData; - } - - /** - * Get Ticket Inventory Calendar Data - * - * @return object containing array as sub-objects - */ - function getTicketInventoryCalendarData() - { - - // Is there a new Ticket code selected? - if (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - // Get peformance ID from ticket - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; - $Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - $ticketDetail = $Tickets->getTicketDetail(); - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $ticketDetail['performance_id']; - - // Get performance data to get start and end date for the performance - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - $performanceDetail = $Performances->getPerformanceDetail(); - - $invData = $this->getTicketInventoryList(false, "ticket_date is not null"); - - // If this ticket is date specific by inventory - // If not, there's only one inventory item, so we don't build a calendar - if ($ticketDetail['date_specific']['value']) { - - $start = $ticketDetail['start_date']['timestamp']; - $end = $ticketDetail['end_date']['timestamp']; - - /* - * Build output organized as calendar months - */ - - // Create calendars for the months covered by the performance - $calData = array(); - $startMonth = strtotime(date('m/1/Y', $start)); - $endMonth = strtotime(date('m/1/Y', $end)); - - // For each month of the performance - $newInventoryAdded = false; - for ($month = $startMonth; $month <= $endMonth; $month = strtotime(date('m/d/Y',$month).' +1 Month')) { - - $offset = date('w', $month); // Number of days start of month is offset from Sunday - $monthDays = date('t', $month); // Number of days in the month - - $calData[$month] = array( - 'month' => date('F', $month), - 'year' => date('Y', $month) - ); - - // For each week of the month - for ($week = 1; $week <= 6; $week++) { - - $weekUsed = false; - - // For each day of the week - for ($day = 1; $day <= 7; $day++) { - - $cellNumb = ($week-1) * 7 + $day; // Calendar cell number - 6 week rows = 42 cells - - // If this is a real date cell, then add the date info and any inventory data - $dateData = array('isDate' => false); - if ($cellNumb > $offset && ($cellNumb-$offset) <= $monthDays) { - - $date = $cellNumb - $offset; // Day of the month - $dateTime = strtotime(date('m/d/Y', $month)." + ".($date-1)." Days"); // Timestamp for this date - - $dow = date('w', $dateTime); - - // Create base cell data - $dateData = array( - 'isDate' => true, - 'time' => $dateTime, - 'dom' => date('j', $dateTime), - 'date' => date('m/d/Y',$dateTime), - 'selectable' => ($dateTime >= $start && $dateTime <= $end && $ticketDetail['days_of_week']['bitmap'][$dow]['default']), - 'selected' => false - ); - - - if ($ticketDetail['days_of_week']['bitmap'][$dow]['default']) { - - - $weekUsed = true; - - // Check if there's no inventory for this date and there should be - if (($dateTime >= $start && $dateTime <= $end) && !isset($invData[$dateTime])) { - - // Create a new inventory item - $quant = $ticketDetail['quant']; - $time = trim($ticketDetail['ticket_time']['time']); - $dateText = date('m/d/Y', $dateTime); - - $sql = " - INSERT INTO eventmgt.ticket_inventory - (ticket, quant, available, ticket_date, ticket_time, sold, active) - VALUES - ($ticketID, $quant, $quant, '$dateText', '$time', 0, true) - ;"; - $this->dbh->exec($sql); - $newInventoryAdded = true; - - } - - } - - // If there's data for this date, add that to the cell data - if (isset($invData[$dateTime])) { - - $dateData = array_merge($dateData, $invData[$dateTime]); - unset($dateData['ticket_date']); // Don't need this here - unset($dateData['ticket_name']); // Don't need this here - - } - - } - $calData[$month]['weeks'][$week]['weekUsed'] = $weekUsed; - $calData[$month]['weeks'][$week]['days'][$cellNumb] = $dateData; - - } - } - } - - // If new inventory was added, go back and reload all the data again - if ($newInventoryAdded) { - $calData = $this->getTicketInventoryCalendarData(); - } - - } else { - - // If not date specific, we'll just pass on the current inventory data item - $calData = $invData; - } - - return $calData; - } - - - /** - * Get Ticket Inventory Detail - * - * @return array - */ - function getTicketInventoryDetail($ticketInventoryID = false, $extended = false) - { - - // If an ID was supplied - if ($ticketInventoryID > 0) { - - $_SESSION[GLM_EVENT_SESSION]['TicketInventory'] = $ticketInventoryID; - - // Otherwise is there a new Ticket code submitted? - } elseif (($ticketInventoryID = filter_input(INPUT_GET, 'TicketInventoryID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['TicketInventory'] = $ticketInventoryID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['TicketInventory'])) { - - // Otherwise, get the ticket ID from the session - $ticketInventoryID = $_SESSION[GLM_EVENT_SESSION]['TicketInventory']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - $detail = $this->getEntry($ticketInventoryID); - - // If $extended, then get detail on Section and Entrance - if ($extended) { - - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSections.php'; - $Sections = new EventManagementDataSections($this->dbh, $this->config); - $Sections->optionIncludeSelectListData = false; - $sectionDetail = $Sections->getSectionDetail($detail['section']); - - } - - return $detail; - - } - - - /** - * Edit Ticket Inventory - * - * @return array - */ - function editTicketInventory() - { - - if (($ticketInventoryID = filter_input(INPUT_GET, 'TicketInventoryID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['TicketInventory'] = $ticketInventoryID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['TicketInventory'])) { - - // Otherwise, get the ticket ID from the session - $ticketInventoryID = $_SESSION[GLM_EVENT_SESSION]['TicketInventory']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - $ticketDetail = $this->editEntry($ticketInventoryID); - - return $ticketInventoryDetail; - - } - - /** - * Check for other field related issues - * - * This function must be here because it's called from a function - * in dataAbstract. Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - return $r; - } - - /** - * Update Ticket - * - * @return array - */ - function updateTicketInventory() - { - - // Removing "active" field to keep inventory update from messing with active flag - $saveActive = $this->fields['active']; - unset($this->fields['active']); - - if (($ticketInventoryID = filter_input(INPUT_GET, 'TicketInventoryID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['TicketInventory'] = $ticketInventoryID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['TicketInventory'])) { - - // Otherwise, get the ticket ID from the session - $ticketInventoryID = $_SESSION[GLM_EVENT_SESSION]['TicketInventory']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - // Check if there's existing inventory data - - - // Try to update this data - $r = $this->updateEntry($ticketInventoryID); - - // Restore "active" field - $this->fields['active'] = $saveActive; - - return $r; - - } - - - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataTicketPackages.php b/legacy/classes/data/dataTicketPackages.php deleted file mode 100644 index dfb3f44..0000000 --- a/legacy/classes/data/dataTicketPackages.php +++ /dev/null @@ -1,347 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTicketPackage.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataTicketPackage class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTickets,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataTicketPackages extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.ticket_package'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Pointer to ticket that is acting as a package container - 'ticket_package' => array( - 'field' => 'package', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Pointer to ticket that is contained in the package - 'ticket' => array( - 'field' => 'ticket', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Quantity - 'quant' => array( - 'field' => 'quant', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'use' => 'a' - ), - - // Separate Voucher Flag - 'separate_voucher' => array( - 'field' => 'separate_voucher', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'use' => 'a' - ), - - // Package Name - 'package_name' => array( - 'field' => 'package', - 'as' => 'package_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'title', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Member Name - 'member_name' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Performance Name - 'performance_name' => array( - 'field' => 'performance', - 'as' => 'performance_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.performance', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket Title - 'ticket_title' => array( - 'field' => 'ticket', - 'as' => 'title', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'title', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket Active - 'active' => array( - 'field' => 'ticket', - 'as' => 'active', - 'type' => 'pointer', - 'p_table' => 'eventmgt.ticket', - 'p_field' => 'active', - 'p_id' => 'id', - 'p_static' => true, - 'required' => false, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Display Order (sort) - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 999, - 'use' => 'a' - ) - - - ); - } - - /** - * Get Package Tickets list - * - * - * @return object containing array as sub-objects - */ - public function getPackageList($where) - { - - // Get the package contents - $packageData = $this->getList($where); - if (count($packageData) == 0) { - return false; - } - - // Build output array with package ticket as key - $outData = array(); - if ($packageData && count($packageData) > 0) { - foreach ($packageData as $p) { - $outData[$p['ticket']] = $p; - } - } - return $outData; - - } - - /** - * Update package tickets list - * - * Expects request input "selected_ticket_quant[id]" array. - */ - public function updatePackageTicketsList($packageID = false) - { - // Check for good package ID - $pID = $packageID - 0; - if ($pID <= 0) { - return false; - } - - // Try to retrieve package to make sure it exists and is a package - $sql = " - SELECT id - FROM eventmgt.ticket - WHERE id = $pID - AND ticket_type = 20 - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $packageData = $stmt->fetchAll(PDO::FETCH_ASSOC); - if (count($packageData) != 1) { - return false; - } - - // Query to delete all for selected package - $sql = " - BEGIN; - DELETE FROM eventmgt.ticket_package - WHERE package = $packageID; - "; - - // Now add in any tickets in request - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; - $Tickets = new EventManagementDataTickets($this->dbh, $this->config); - $newTickets = $_REQUEST['selected_ticket_quant']; - - if ($newTickets) { - - foreach ($newTickets as $k=>$v) { - - // Get ticket data - $ticketData = $Tickets->getEntry($k); - if (is_array($ticketData)) { - - // Check for separate vouchers - $separateVoucher = 'false'; - if (isset($_REQUEST['selected_ticket_separatevoucher'][$k])) { - $separateVoucher = 'true'; - } - - $sql .= " - INSERT INTO eventmgt.ticket_package - (package, ticket, member, performance, quant, sort, separate_voucher) - VALUES ($packageID, $k, ".$ticketData['member'].", ".$ticketData['performance_id'].", $v, 99, $separateVoucher) - ;"; - } - - } - } - $sql .= "COMMIT;"; - $this->dbh->exec($sql); - - return $this->getPackageList("package = $packageID"); - - } - - /** - * Clear package tickets list - */ - public function clearPackageTicketsList($packageID = false) - { - - // Check for good package ID - $pID = $packageID - 0; - if ($pID <= 0) { - return false; - } - - $sql = " - DELETE FROM eventmgt.ticket_package - WHERE package = $packageID; - "; - $this->dbh->exec($sql); - - return; - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataTickets.php b/legacy/classes/data/dataTickets.php deleted file mode 100644 index 1a5a3b8..0000000 --- a/legacy/classes/data/dataTickets.php +++ /dev/null @@ -1,923 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTickets.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataTickets class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataTickets,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementDataTickets extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.ticket'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Admin Only Flag - 'admin_only' => array( - 'field' => 'admin_only', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Ticket Type - 'ticket_type' => array( - 'field' => 'ticket_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->ticket_type->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 10, - 'use' => 'a' - ), - - // Member ID for adding tickets - 'member' => array( - 'field' => 'member', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Member'], - 'use' => 'a' - ), - - // Member Name display - 'member_view' => array( - 'field' => 'member', - 'as' => 'member_name', - 'type' => 'pointer', - 'p_table' => 'eventmgt.member', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_static' => true, - 'required' => true, - 'unique' => false, - 'default' => false, - 'view_only' => true, - 'use' => 'gleu' - ), - - // Ticket Name (internal use) - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Active - 'active' => array( - 'field' => 'active', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Ticket Title (for display to users) - 'title' => array( - 'field' => 'title', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Performance - 'performance' => array( - 'field' => 'performance', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.performance', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_where' => 'member = '.$_SESSION[GLM_EVENT_SESSION]['Member'], - 'required' => true, - 'unique' => false, - 'default' => $_SESSION[GLM_EVENT_SESSION]['Performance'], - 'use' => 'nideu' - ), - - // Performance_view - 'performance_view' => array( - 'field' => 'performance', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.performance', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Performance ID - 'performance_id' => array( - 'field' => 'performance', - 'as' => 'performance_id', - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Section - 'section' => array( - 'field' => 'section', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.section', - 'p_field' => 'name', - 'p_id' => 'id', - 'p_where' => 'member = '.$_SESSION[GLM_EVENT_SESSION]['Member'], - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'nideu' - ), - - // Section View - 'section_view' => array( - 'field' => 'section', - 'as' => false, - 'type' => 'pointer', - 'p_table' => 'eventmgt.section', - 'p_field' => 'name', - 'p_id' => 'id', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Section ID - 'section_id' => array( - 'field' => 'section', - 'as' => 'section_id', - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Available for Sale Start Date - 'for_sale_start_date' => array( - 'field' => 'for_sale_start_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y').' -1 year'), // Earliest is now less 1 year - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Available for Sale End Date - 'for_sale_end_date' => array( - 'field' => 'for_sale_end_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y').' -1 year'), // Earliest is now less 1 year - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Date Specific - use single or multiple inventory - 'date_specific' => array( - 'field' => 'date_specific', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Days of the week to create default inventory - multi-pick - 'days_of_week' => array( - 'field' => 'days_of_week', - 'as' => false, - 'type' => 'bitmap', - 'bitmap' => $this->config->days->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 0, // Note that this is a bitmap of card indexes - 'use' => 'a' - ), - - // Start Date - 'start_date' => array( - 'field' => 'start_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // End Date - 'end_date' => array( - 'field' => 'end_date', - 'as' => false, - 'type' => 'date', - 'format' => 'm/d/Y', - 'minValue' => strtotime('1/1/'.date('Y')), // Earliest is now - 'maxValue' => strtotime('12/31/'.date('Y').' +3 years'), // This year plus 3 - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Time Specific - 'time_specific' => array( - 'field' => 'time_specific', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Ticket Time - 'ticket_time' => array( - 'field' => 'ticket_time', - 'as' => false, - 'type' => 'time', - 'required' => true, - 'unique' => false, - 'default' => '12:00 PM', - 'use' => 'a' - ), - - // Ticket Timestamp - 'ticket_timestamp' => array( - 'field' => 'ticket_time', - 'as' => 'ticket_timestamp', - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'gl' - ), - - // Unlimited Use - 'unlimited_use' => array( - 'field' => 'unlimited_use', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Number of uses - 'uses' => array( - 'field' => 'uses', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 1, - 'use' => 'a' - ), - - // Unlimited Quantity - 'unlimited_quant' => array( - 'field' => 'unlimited_quant', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => true, - 'use' => 'a' - ), - - // Quantity - Number of these tickets in the section - 'quant' => array( - 'field' => 'quant', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 1, - 'use' => 'lgnieud' - ), - - // Price - 'price' => array( - 'field' => 'price', - 'as' => false, - 'type' => 'money', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Consignment Type - 'consignment_type' => array( - 'field' => 'consignment_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->ticket_consignment_type->toArray(), - 'required' => false, - 'unique' => false, - 'default' => 1, - 'use' => 'a' - ), - - // Cart Sticky (Always displayed on cart - even with no quant) - 'cart_sticky' => array( - 'field' => 'cart_sticky', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a', - 'callback' => function ($r) { - $r['status'] = false; - return $r; - } - ), - - // Show ticket on Start Page - 'show_on_start' => array( - 'field' => 'show_on_start', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Add-on Selection Required - 'addon_required' => array( - 'field' => 'addon_required', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Price - 'price_numb' => array( - 'field' => 'price', - 'as' => 'price_numb', - 'type' => 'float', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'lg' - ), - - // Description - 'descr' => array( - 'field' => 'descr', - 'as' => false, - 'type' => 'text', - 'filter' => FILTER_SANITIZE_MAGIC_QUOTES, - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Image - 'image' => array( - 'field' => 'image', - 'as' => false, - 'type' => 'image', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Voucher Text - 'voucher_text' => array( - 'field' => 'voucher_text', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Voucher LeftEnd Text - overrides other text for that area if set - 'voucher_leftend_text' => array( - 'field' => 'voucher_leftend_text', - 'as' => false, - 'type' => 'text', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Voucher Type - 'voucher_type' => array( - 'field' => 'voucher_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->ticket_voucher_type->toArray(), - 'required' => true, - 'unique' => false, - 'default' => 1, - 'use' => 'a' - ), - - // Display Order (sort) - 'sort' => array( - 'field' => 'sort', - 'as' => false, - 'type' => 'integer', - 'required' => false, - 'unique' => false, - 'default' => 999, - 'use' => 'a' - ) - - - ); - } - - /** - * Check for other field related issues - * - * Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - // Check that Sticky is not used with date-specific inventory - if ($r['fieldData']['date_specific']['value'] && $r['fieldData']['cart_sticky']['value']) { - $r['status'] = false; - $r['fieldFail']['cart_sticky'] = 'Sticky may not be used when "Specified Dates" is checked.'; - $r['fieldFail']['date_specific'] = 'Specified dates may not be used when "Sticky" is checked.'; - } - - return $r; - } - - /** - * Get Tickets list - * - * @param integer $memberID Specifies tickets for a Member ID - * @param integer $performanceID Specifies tickets for a Performance ID - * @param integer $sectionID Specifies tickets for a Section ID - * @param string $listType Type of list to generate - * "norm" Standard list output with detail - * 'all' List all and ignore member, performance, section ID - * 'packageSelect' List package selection with only ID, Name, Member, Performance, Section, active - * Optional specify $notTicketID to not include the current ticket by ID - * Sorts by Member, Performance, Section, then Ticket - * - * @return object containing array as sub-objects - */ - function getTicketsList($memberID = false, $performanceID = false, $sectionID = false, $listType = false, $activeOnly = false, $where = false, $includeAdminOnly = false, $notTicketID = false, $packages = true) - { - // Get member ID - But don't use it if performance or section IDs are supplied. - if ($memberID == false && !$performanceID && !$sectionID) { - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - } - - // Get performance ID - if ($performanceID == false) { - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - } - - // Get section ID - if ($sectionID == false) { - $sectionID = $_SESSION[GLM_EVENT_SESSION]['Section']; - } - - // Get URI search type - if (!$listType && isset($_REQUEST['listType'])) { - $listType = $_REQUEST['listType']; - } - - // Build query Where clause - if ($where == false) { - $where = 'true'; - } - - // Check for active only request - if ($activeOnly) { - $where .= ' AND T.active'; - } - - // Check if adminUser - if (!$includeAdminOnly) { - $where .= ' AND NOT T.admin_only'; - } - - // Check if packages aren't enabled - if (!$packages) { - $where .= ' AND T.ticket_type != 20'; - } - - $fieldsSave = false; - - switch ($listType) { - - case 'packageSelect': - - // Save current field list - $fieldsSave = $this->fields; - $this->fields = array( - 'id' => $this->fields['id'], - 'name' => $this->fields['name'], - 'title' => $this->fields['title'], - 'member_name' => $this->fields['member_view'], - 'performance_view' => $this->fields['performance_view'], - 'section_view' => $this->fields['section_view'], - 'active' => $this->fields['active'] - ); - - $where = ' - T.ticket_type != 20 - AND T.addon_required = false - '.($notTicketID ? ' AND T.id != '.$notTicketID : '').' - '; - if ($memberID) { - $where .= " AND ( T.member = $memberID OR T.consignment_type > 1)"; - } else { - $where .= 'AND T.consignment_type > 1'; - } - - $sort = ''; - - break; - - case 'norm': - default: - if ($memberID) { - $where .= " AND T.member = $memberID"; - } - if ($performanceID) { - $where .= " AND T.performance = $performanceID"; - } - if ($sectionID) { - $where .= " AND T.section = $sectionID"; - } - $sort = 'sort, name'; - break; - - case 'all': - $sort = 'sort, name'; - break; - - } - - // Get list of Tickets - $ticketsList = $this->getList($where, 'sort, name'); - - if ($fieldsSave != false) { - $this->fields = $fieldsSave; - } - - // If type packageSelect - if ($listType == 'packageSelect') { - - // Sort by member, performance, section, ticket names. - function packageSelectSort($a, $b) { - if ($a['member_name'] == $b['member_name'] && $a['performance'] == $b['performance'] && $a['section'] == $b['section'] && $a['title'] == $b['title'] ) { - return 0; - } - if ($a['member_name'] < $b['member_name']) { return -1; } - if ($a['member_name'] > $b['member_name']) { return 1; } - if ($a['performance'] < $b['performance']) { return -1; } - if ($a['performance'] > $b['performance']) { return 1; } - if ($a['section'] < $b['section']) {return -1;} - if ($a['section'] > $b['section']) {return 1;} - if ($a['title'] < $b['title']) {return -1;} - return 1; - } - uasort($ticketsList, 'packageSelectSort'); - - // Save names, Remove subsequent member, performance, section until change - $memberName = ''; - $performanceName = ''; - $sectionName = ''; - while (list($k, $v) = each($ticketsList)) { - - // Also provide active as Yes/No - $ticketsList[$k]['active_name'] = ($v['active'] ? 'Yes' : 'No'); - - // Save names for adding to selected list - $ticketsList[$k]['member_save'] = $v['member_name']; - $ticketsList[$k]['performance_save'] = $v['performance']; - $ticketsList[$k]['section_save'] = $v['section']; - - // Remove duplicate names for ordered picklist - if ($v['member_name'] != $memberName) { - $memberName = $v['member_name']; - $performanceName = ''; - $sectionName = ''; - } else { - $ticketsList[$k]['member_name'] = ''; - } - if ($v['performance'] != $performanceName) { - $performanceName = $v['performance']; - $sectionName = ''; - } else { - $ticketsList[$k]['performance'] = ''; - } - if ($v['section'] != $sectionName) { - $sectionName = $v['section']; - } else { - $ticketsList[$k]['performance'] = ''; - } - - } - - } - - return $ticketsList; - } - - /** - * Get Ticket Detail - * - * @return array - */ - function getTicketDetail($ticketID = false) - { - - // If a ticket has been specified - if ($ticketID != false) { - - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - // Otherwise if there's a ticket ID in the request - } elseif (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // There's a - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - $ticketDetail = $this->getEntry($ticketID); - - return $ticketDetail; - - } - - /** - * Edit Ticket - * - * @return array - */ - function editTicket() - { - - if (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - $ticketDetail = $this->editEntry($ticketID); - - return $ticketDetail; - - } - - /** - * Update Ticket - * - * @return array - */ - function updateTicket() - { - - if (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have a ticket id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($ticketID); - - return $r; - - } - - /** - * Add New Ticket - * - * @return array - */ - function newTicket() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert Ticket - * - * @return array - */ - function insertTicket() - { - - $r = $this->insertEntry(); - - // If succesful then set current ticket to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $r['insertedID']; - } - - return $r; - - } - - /** - * Delete Ticket - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function ticketDelete($confirm = false) - { - - // Is there a new ticket code selected? - if (($ticketID = filter_input(INPUT_GET, 'TicketID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = $ticketID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - - // Otherwise, get the ticket ID from the session - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - - } else { - - // Otherwise, we don't have an ticket id - return false; - - } - - $ticketDetail = $this->deleteEntry($ticketID, $confirm); - - return $ticketDetail; - - } - - -} - - - - -?> \ No newline at end of file diff --git a/legacy/classes/data/dataVoucherCoupons.php b/legacy/classes/data/dataVoucherCoupons.php deleted file mode 100644 index a4f0850..0000000 --- a/legacy/classes/data/dataVoucherCoupons.php +++ /dev/null @@ -1,472 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataVoucherCoupons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once DATA_ABSTRACT; - -/** - * EventManagementDataVoucherCoupons class - * - * PHP version 5 - * - * @category Data - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: dataVoucherCoupons,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ -class EventManagementDataVoucherCoupons extends DataAbstract -{ - /** - * Tables - * - * @var $ini - * @access public - */ - public $table = 'eventmgt.voucher_coupons'; - - /** - * Field definitions - * - * 'type' is type of field as defined by the application - * text Regular text field - * pointer Pointer to an entry in another table - * 'filters' is the filter name for a particular filter ID in PHP filter functions - * See PHP filter_id() - * - * 'use' is when to use the field - * l = List - * g = Get - * n = New - * i = Insert - * e = Edit - * u = Update - * d = Delete - * a = All - * - * @var $ini - * @access public - */ - public $fields = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - parent::__construct($dbh, $config); - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'lged' - ), - - // Voucher Coupon Name - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Active - 'active' => array( - 'field' => 'active', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => true, - 'use' => 'a' - ), - - // Coupon Type - 'coupon_type' => array( - 'field' => 'coupon_type', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->coupon_type->toArray(), - 'list_keytype' => 'int', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Coupon Position - 'coupon_position' => array( - 'field' => 'coupon_position', - 'as' => false, - 'type' => 'list', - 'list' => $this->config->coupon_position->toArray(), - 'list_keytype' => 'int', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Display From Date - 'display_from' => array( - 'field' => 'display_from', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => time(), - 'use' => 'a' - ), - - // Display To Date - 'display_to' => array( - 'field' => 'display_to', - 'as' => false, - 'type' => 'date', - 'required' => true, - 'unique' => false, - 'default' => strtotime('12/31/'.date('Y').' +4 years'), - 'use' => 'a' - ), - - // Stretch to Fit - 'stretch_to_fit' => array( - 'field' => 'stretch_to_fit', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Image Padding - 'padding' => array( - 'field' => 'padding', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ), - - // Show Border - 'show_border' => array( - 'field' => 'show_border', - 'as' => false, - 'type' => 'checkbox', - 'required' => false, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Coupon Image - 'coupon_image' => array( - 'field' => 'coupon_image', - 'as' => false, - 'type' => 'image', - 'required' => true, - 'unique' => false, - 'default' => false, - 'use' => 'a' - ), - - // Maximum Display Count (-1 = unlimited) - 'max_display_count' => array( - 'field' => 'max_display_count', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => -1, - 'use' => 'a' - ), - - // Display Count - 'display_count' => array( - 'field' => 'display_count', - 'as' => false, - 'type' => 'integer', - 'required' => true, - 'unique' => false, - 'default' => 0, - 'use' => 'a' - ) - - ); - } - - /** - * Check for other field related issues - * - * Simply return $r if there's nothing to check. - * - * @return array - */ - function checkOther($r) - { - parent::checkOther($r); - - return $r; - } - - - /** - * Get Voucher Coupon list - * - * @return object containing array as sub-objects - */ - function getVoucherCouponList($where = '') - { - - // Build query Where clause - if ($where == '') { - $where = 'true'; - } - - // Get list of Voucher Coupons - $voucherCouponsList = $this->getList($where, 'name'); - - return $voucherCouponsList; - } - - /** - * Get Voucher Coupon Detail - * - * @return array - */ - function getVoucherCouponDetail($voucherCouponID = false) - { - - // If a voucher coupon has been specified - if ($voucherCouponID != false) { - - $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'] = $voucherCouponID; - - // Otherwise if there's a voucher coupon ID in the request - } elseif (($voucherCouponID = filter_input(INPUT_GET, 'VoucherCouponID', FILTER_SANITIZE_NUMBER_INT))) { - - // There's a Voucher Coupon submitted, so save that - $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'] = $voucherCouponID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'])) { - - // Otherwise, get the voucher coupon ID from the session - $voucherCouponID = $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon']; - - } else { - - // Otherwise, we don't have a voucher coupon id - return false; - - } - - $voucherCouponDetail = $this->getEntry($voucherCouponID); - - return $voucherCouponDetail; - - } - - /** - * Edit Voucher Coupon - * - * @return array - */ - function editVoucherCoupon() - { - - if (($voucherCouponID = filter_input(INPUT_GET, 'VoucherCouponID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'] = $voucherCouponID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'])) { - - // Otherwise, get the voucher coupon ID from the session - $voucherCouponID = $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon']; - - } else { - - // Otherwise, we don't have a voucher coupon id - return false; - - } - - $voucherCouponDetail = $this->editEntry($voucherCouponID); - - return $voucherCouponDetail; - - } - - /** - * Update Voucher Coupon - * - * @return array - */ - function updateVoucherCoupon() - { - - if (($voucherCouponID = filter_input(INPUT_GET, 'VoucherCouponID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'] = $voucherCouponID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'])) { - - // Otherwise, get the voucher coupon ID from the session - $voucherCouponID = $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon']; - - } else { - - // Otherwise, we don't have a voucher coupon id - return false; - - } - - // Try to update this data - $r = $this->updateEntry($voucherCouponID); - - return $r; - - } - - /** - * Add New Voucher Coupon - * - * @return array - */ - function newVoucherCoupon() - { - - $r = $this->newEntry(); - - return $r; - - } - - /** - * Insert Voucher Coupon - * - * @return array - */ - function insertVoucherCoupon() - { - - $r = $this->insertEntry(); - - // If succesful then set current voucher coupone to the one just inserted. - if ($r['status']) { - $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'] = $r['insertedID']; - } - - return $r; - - } - - /** - * Delete Voucher Coupon - * - * @param $confirm bool False to ask if user wants to delete and true to actually delete - * - * @return array - */ - function voucherCouponDelete($confirm = false) - { - - // Is there a new voucher coupon code selected? - if (($voucherCouponID = filter_input(INPUT_GET, 'VoucherCouponID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'] = $voucherCouponID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['VoucherCoupon'])) { - - // Otherwise, get the voucher coupon ID from the session - $voucherCouponID = $_SESSION[GLM_EVENT_SESSION]['VoucherCoupon']; - - } else { - - // Otherwise, we don't have an voucher coupon id - return false; - - } - - $voucherCouponDetail = $this->deleteEntry($voucherCouponID, $confirm); - - return $voucherCouponDetail; - - } - - /** - * Get Voucher Coupon List for Display - * - * @param $date string Date to use for selection (usually today unless testing) - * - * @return array - */ - function getCouponsForDisplay($date = false) - { - - $where = ''; - - // If no date (time) has been supplied - if (!$date) { - $date = date('m/d/Y', time()); - } - $where = "T.active AND '$date' >= T.display_from AND '$date' <= T.display_to"; - - $coupons = $this->getVoucherCouponList($where); - - if (!is_array($coupons) || count($coupons) == 0) { - return false; - } - - // Convert to array organized by location - $cr = array(); - foreach ($coupons as $c) { - $cr[$c['coupon_position']['value']][] = $c; - } - - // Shuffle order of coupons in each location (randomize) - foreach ($cr as $k => $v) { - shuffle($cr[$k]); - } - - return $cr; - - } - -} - - - - -?> \ No newline at end of file diff --git a/legacy/configs/EventManagement.ini b/legacy/configs/EventManagement.ini deleted file mode 100644 index d35e1e1..0000000 --- a/legacy/configs/EventManagement.ini +++ /dev/null @@ -1,196 +0,0 @@ -; EventManagement Application ini file - -[production] - -; Event Management V3 - -; The page id in the toolbox that is the entry page for Event management - Generally set for each server -application_page = 19 ;Page ID for this application -application_url = "order-tickets-19" ;Optional URL segment for application - -members_only_page = 37 ;Page ID for members only area -members_only_url = "members-only-area" ;Optional URL segment for members only area - -option.member_db_integrated = false ;Use Standard Member DB: true = Use standard Member DB, false = Use Separate Member DB -option.events = false -option.accommodations = false ;Enable Reservations for members (not event housing) -option.tickets = true ;Enable Ticket Sales - option.tickets_select_max = 50 ; Maximum ticket quantity that can be selected at a time -option.packages = false ;Enable Packages -option.teams = false ;Enable Team housing features -option.registrations = false ;Enable Convention Registrations -option.select_images = false ;Display venue, event, and other images on the selection pages - other than maps and such -option.cart_images = false ;Display venue, event, and other images on the cart page -option.checkout_images = false ;Display venue, event, and other images on the checkout page -option.cart_promotions = true ;Permit promoting other performances on cart page - takes user to other page to select tickets. -option.users_access_all_members = true ;Member contact users can have access to all members data -option.ask_for_likely_date = true ;Ask user for a likely date they would use for non-date-specific tickets (in cart) -option.show_location_blocks = true ;Whether cart blocks for multiple locations should be used to set them apart. Generally on if selling for multiple locations. -option.checkout_testing = false ;Dissables clearing of cart and storing of purchase to permit repeat checkout submissions - Enable only in custom sections at bottom of this file. -option.confirmation_voucher = 'attached' ;How to handle voucher with confirmation E-Mail: Off, 'link', 'attached' - -jQueryLoaded = true ;Say whether jQuery is already loaded by the site -jQueryUiLoaded = false ;Say whether jQueryUI is already loaded by the site - -ticket_hold_time = 60 ;Time in minutes to hold tickets in a cart -session_timeout = 60 ;Time in minutes before session times out -admin_session_timeout = 1560 ;Time in minutes before admin session times out - -; Front-End Appearance Settings -default_front_interface = "TicketsFoundation" -custom_css = false ;Should look for /css/EventManangement.css in customer site -voucher_design = "Generic" ;Design file to use for vouchers - See /models/vouchers directory -site_has_foundation = true ;Site already loads foundation - blocks loading in ticketing front-end header - -; Voucher Options -; Company information -option.voucher.show_company_contact = off ;Show company contact data on Voucher -option.voucher.show_company_name = true ; Company Name -option.voucher.show_company_addr = false ; Company Address -option.voucher.show_company_citystate = false ; Company City & state -option.voucher.show_company_phone = true ; Company Phone -; Venue/Location information -option.voucher.show_venue_contact = true ;Show venue/location contact data on Voucher -option.voucher.show_venue_name = true ; Name -option.voucher.show_venue_addr = false ; Address -option.voucher.show_venue_citystate = true ; City & state -option.voucher.show_venue_phone = true ; Phone - -; Admin Appearance Settings -default_admin_interface = "tickets" - -; Ticket Selection Process Options -option.ticket_selection.start_at_cart = true ;Start with shopping cart - Used with cart-sticky items. -option.ticket_selection.show_tickets_on_start_page = true ;Should we show the tickets on the selection start page or just venues/performances -option.ticket_selection.force_section = false ;Always show section selection even if there's only one -option.ticket_selection.include_options_in_ticket_list = true ;Include ticket options in ticket selection list (date, quant, etc) -option.ticket_selection.select_entrance_on_consignment = true ;If selling a ticket on consignment and the user has to select a venu to purchase the - ; ticket from, if entrances are listed for a venu, use entrances for selection rather than - ; just venue. -option.ticket_selection.show_cart_sticky_items = true ;Enable/disable cart sticky items - -; Image Styles -image_style.default = "tbs1" -image_style.large = "ticketsLarge" -image_style.medium = "ticketsMedium" -image_style.small = "ticketsSmall" -image_style.thumb = "ticketsThumb" - -; Terms used to refer to events/conventions -term.event.norm = "event" -term.event.cap = "Event" -term.event.plur = "events" -term.event.plur_cap = "Events" - -; Terms used to refer to a housing Member/Property/Hotel -term.prop.norm = "location" -term.prop.cap = "Location" -term.prop.plur = "locations" -term.prop.plur_cap = "Locations" - -; Terms used to refer to contacts -term.contact.norm = "contact" -term.contact.cap = "Contact" -term.contact.plur = "contacts" -term.contact.plur_cap = "Contacts" - -; Terms used to refer to scan/claim locations -term.claim_location.norm = "claim location" -term.claim_location.cap = "Claim Location" -term.claim_location.plur = "claim locations" -term.claim_location.plur_cap = "Claim Locations" - -; Terms used to refer to a housing unit -term.unit.norm = "room" -term.unit.cap = "Room" -term.unit.plur = "rooms" -term.unit.plur_cap = "Rooms" - -; Terms used to refer to an entrance -term.entrance.norm = "dock" -term.entrance.cap = "Dock" -term.entrance.plur = "docks" -term.entrance.plur_cap = "Docks" - -; Terms used to refer to a section -term.section.norm = "section" -term.section.cap = "Section" -term.section.plur = "sections" -term.section.plur_cap = "Sections" - -; Terms used to refer to a performance -term.performance.norm = "category" -term.performance.cap = "Category" -term.performance.plur = "categories" -term.performance.plur_cap = "Categories" - -; Terms used to refer to a ticket -term.ticket.norm = "item" -term.ticket.cap = "Item" -term.ticket.plur = "items" -term.ticket.plur_cap = "Items" - -; Terms used to refer to an order -term.order.norm = "order" -term.order.cap = "Order" -term.order.plur = "orders" -term.order.plur_cap = "Orders" - -; Terms used to refer to a voucher -term.voucher.norm = "boarding pass" -term.voucher.cap = "Boarding Pass" -term.voucher.plur = "boarding passes" -term.voucher.plur_cap = "Boarding Passes" - -; Terms used to refer to a promotion -term.promo.norm = "promo code" -term.promo.cap = "Promo Code" -term.promo.plur = "promo codes" -term.promo.plur_cap = "Promo Codes" - -; Terms used for front-end shop navigation buttons -;term.nav.show_selected = "Show Cart" -term.nav.show_selected = "Cart" -term.nav.select = "Select" -;term.nav.select_more = "Select More" -term.nav.select_more = "Shop" -;term.nav.select_more_of_these = "Select More of These" -term.nav.select_more_of_these = "More" -term.nav.add_to_cart = "Add to Cart" -term.nav.checkout = "Proceed to Checkout" -term.nav.purchase = "Click to Purchase Selected Items" -term.nav.print_vouchers = "Print Boarding Passes" -term.nav.delete_from_cart = "Delete these items from your cart" - -; Prompts used for shop checkout fields -text.cart.checkout.first_name = "First Name" -text.cart.checkout.last_name = "Last Name" -text.cart.checkout.address = "Address" -text.cart.checkout.city = "City" -text.cart.checkout.state = "State/Province" -text.cart.checkout.country = "Country" -text.cart.checkout.zip = "ZIP/Postal Code" -text.cart.checkout.phone = "Phone" -text.cart.checkout.email = "E-Mail Address" -text.cart.checkout.email_again = "Enter E-Mail Address Again" -text.cart.checkout.ok_to_send = "OK to Send E-Mail?" -text.cart.checkout.special_req = "" ; If blank, don't use -text.cart.checkout.activities_offers = "Please send information on activities and offers." - -; Other text used in the front end -text.cart.select_assignment_location = "Please select the dock you are going to depart from." -text.cart.select_likely_date = "Please select your likely departure date." ;For non-date-specific tickets - -; development server configuration data inherits from production and -; overrides values as necessary -[development : production] - -; chuck's server configuration data inherits from development -; and overrides values as necessary -[chuck : development] -option.checkout_testing = false ;Dissables clearing of cart and storing of purchase to permit repeat checkout submissions. - -; steve's server configuration data inherits from development -; and overrides values as necessary -[steve : development] - diff --git a/legacy/configs/common.ini b/legacy/configs/common.ini deleted file mode 100644 index 5ee2a8c..0000000 --- a/legacy/configs/common.ini +++ /dev/null @@ -1,795 +0,0 @@ -; Configuration File for Event Management System - V3 -; -; This file contains common configuration for all sites using this Event Management -; System on this server. Each site also has local configuration for this application -; in a config/applications/EventManagement.ini file in the site. -; -; Custom configurations for development and developer configuration at bottom of file. - -[common] - -applicationName = "Event Management" -applicationVersion = "EventManagement/V3" -dataAbstractLocation = "Database/V0" -pdfAbstractLocation = "PDF/V0" -paymentProcessorsLocation = "PaymentProcessors/V0" -imageServerAbstractLocation = "ImageServer/V0" -internalReportingAddress = "cscott@gaslightmedia.com" - -orderVerificationSecret = "GLMOrder2secreT" - -; -; ********** NEED TO VERIFY EVERYTHING BELOW ************** -; - -; Base URL/paths for front-end of this application -url.members = CURRENT_BASE_URL "members-only-area/?page_id=122" -path.front_end = BASE_PATH "" -path.admin = BASE_PATH "admin/Event_Housing/" -path.common = "/var/www/server/CommonApps/" - -; Admin Interface Selection -default_admin_interface = "tickets" -admin_interface.selectable = false; -admin_interface.tickets = "tickets" -admin_interface_type.tickets = "flexy" ;Options are "flexy" and "smarty" (smarty not working yet) - -; Front End Interface Selection -; default_front_interface (set in customer configuration) -front_interface.selectable = false; - -; Front End Interfaces -; "tickets" -front_interface.tickets = "tickets" -front_interface_type.tickets = "flexy" ;Options are "flexy" and "smarty" (smarty not working yet) -; "TicketsFoundation" -front_interface.TicketsFoundation = "TicketsFoundation" -front_interface_type.TicketsFoundation = "flexy" ;Options are "flexy" and "smarty" (smarty not working yet) -; "FoundationStandAlone" - Used for foundation with tickets when Foundation is not loaded for the site -front_interface.FoundationStandAlone = "TicketsFoundation" -front_interface_type.FoundationStandAlone = "flexy" ;Options are "flexy" and "smarty" (smarty not working yet) - -; Set Database Date Style - uncomment desired style -;misc.datestyle = "SET DATESTYLE TO 'ISO';" ;ISO example: 1997-12-17 07:37:16-08';\n" -misc.datestyle = "SET DATESTYLE TO 'SQL';" ;SQL example: 12/17/1997 07:37:16.00 PST';\n" -;misc.datestyle = "SET DATESTYLE TO 'Postgres';" ;Postgres example: Wed Dec 17 07:37:16 1997 PST';\n" -;misc.datestyle = "SET DATESTYLE TO 'European';" ;European example: 17/12/1997 15:37:16.00 MET';\n" -;misc.datestyle = "SET DATESTYLE TO 'US';" ;US example: 12/17/1997 07:37:16.00 PST';\n" -;misc.datestyle = "SET DATESTYLE TO 'German';" ;German example: 17.12.1997 07:37:16.00 PST';\n" - -; Standard arrays - -; Member Types -member_type.1 = "Standard" -member_type.2 = "Standard + Sells other's items" -member_type.3 = "Vendor of items only sold through others" -member_type.10 = "Other - neither vendor nor sales" - -; Ticket consignment types -ticket_consignment_type.1 = "Not sold by other locations" -ticket_consignment_type.2 = "Available for sale by other locations" -ticket_consignment_type.3 = "Sold only by other locations" - -; Ticket voucher types - Note types < 80 are tickets, > 80 are things sold -ticket_voucher_type.1 = "Standard Voucher/Ticket with Barcode" -ticket_voucher_type.11 = "Voucher/Ticket for Pickup - no Barcode" -ticket_voucher_type.12 = "Voucher/Ticket to be mailed Mailed - no Barcode" -ticket_voucher_type.81 = "Object Sold (i.e. books) to be claimed - with Barcode" -ticket_voucher_type.82 = "Object Sold (i.e. books) to be mailed - no Barcode" - -; Ticket Types -ticket_type.10 = 'Standard' -ticket_type.20 = 'Package' - -; Ticket Add-On Types -ticket_add_on_type.1 = 'Checkbox' -ticket_add_on_type.2 = 'Quantity' - -; Promo Ticket Types -promo_ticket_type.1 = '$ Amount' -promo_ticket_type.2 = 'Percentage' - -; Permissions -permissions.10 = "Full Venue Access" -permissions.20 = "Ticket Orders and Claims" -permissions.30 = "Ticket Claims Only" -permissions.99 = "No Access" - -; Permissions References -permissions_numb.full = 10 -permissions_numb.orders_and_claims = 20 -permissions_numb.claims = 30 -permissions_numb.none = 99 - -; Pending cart hold types -hold_types.reservation = 1 -hold_types.ticket = 2 - -; Claim Tracking Types by Name -claim_tracking_types_numb.claim = 1 -claim_tracking_types_numb.clear = 2 - -; Claim Tracking Types -claim_tracking_types.1 = "Claimed" -claim_tracking_types.2 = "Claim Cleared" - -; Processing Methods -proc_method.1 = merchant ;Merchant processes cards -proc_method.2 = processed ;Processed by a card processor - -; Card Processors by number -ccard_processor.0 = "(none - select processor)" -ccard_processor.3 = "No Payment Processing at Checkout" -ccard_processor.99 = "Card Processing Test" -ccard_processor.1 = "Authorize.net" -ccard_processor.2 = "Merchant Solutions" - -; Card Processors by name -ccard_processor_numb.none = 0 -ccard_processor_numb.authorize_net = 1 -ccard_processor_numb.merchant_solutions = 2 -ccard_processor_numb.no_payment = 3 -ccard_processor_numb.test = 99 - -; Card processing mode options -cc_mode.1 = "Local Transaction Approval Test" -cc_mode.2 = "Local Transaction Decline Test" -cc_mode.3 = "On-Line Transaction Test" -cc_mode.0 = "Production Mode" - -; PayPal processing mode options -paypal_mode.3 = "On-Line Transaction Test" -paypal_mode.0 = "Production Mode" - -; Processing Status -proc_status.new = 0 -proc_status.descr.0 = "New Registration Record" -proc_status.unpaid = 1 -proc_status.descr.1 = "Not Paid" -proc_status.cc_pend = 2 -proc_status.descr.2 = "Credit Card Pending" -proc_status.cc_paid = 3 -proc_status.descr.3 = "Paid by Credit Card" -proc_status.cc_decl = 4 -proc_status.descr.4 = "Credit Card Declined" -proc_status.check_pend = 5 -proc_status.descr.5 = "Check Pending" -proc_status.check_paid = 6 -proc_status.descr.6 = "Paid by Check" -proc_status.comp = 7 -proc_status.descr.7 = "Complimentary" -proc_status.failed = 98 -proc_status.descr.98 = "Submission Failed" -proc_status.canceled = 99 -proc_status.descr.99 = "Canceled" - -; Payment Types -pay_types.1 = "Credit Card" -pay_types.2 = "Check" -pay_types.3 = "Direct" -pay_types.4 = "PayPal" - -; Credit Cards - numbers are an exponent of 2 that represent the bit position -ccard.0 = "Visa" -ccard.1 = "MasterCard" -ccard.2 = "American Express" -ccard.3 = "Discover" -ccard.4 = "Diners Club" - -; Credit Card validation strings (regular expression) -ccverify.0 = "^4.{15}$|^4.{12}$" -ccverify.1 = "^5[1-5].{14}$" -ccverify.2 = "^3[47].{13}$" -ccverify.3 = "^6011.{12}$" -ccverify.4 = "^30[0-5].{11}$|^3[68].{12}$" - -; Confirmation Methods -conf_methods.1 = "US Mail" -conf_methods.2 = "E-Mail" - -; Reference Types -reference_type.misc = 0 -reference_type.event = 1 -reference_type.member = 2 -reference_type.state = 3 -reference_type.team = 4 - -; Voucher Check Character Secret -voucher_check_secret = "emVoucherCheck1" - -; Reference Type Numbers -reference_type_numb.0 = "Misc" -reference_type_numb.1 = "Event" -reference_type_numb.2 = "Member/Venue" -reference_type_numb.3 = "State Rep" -reference_type_numb.4 = "Team" - -; Fee Method -fee_method.fixed_stay = 1 -fee_method.fixed_accom = 2 -fee_method.fixed_accomnight = 3 -fee_method.percent_stay = 10 - -; Fee Method Numbers -fee_method_numb.1 = "Per Reservation" -fee_method_numb.2 = "Per Room" -fee_method_numb.3 = "Per Night" -fee_method_numb.10 = "Percent of Room Rate" - -; Member/Venue Amenities -; Static amenitities set system-wide -; Only 10 fields in member records for these at this time -; Needs to be replaced with managed amenities list -memb_amen.1 = "Air-Conditioning" -memb_amen.2 = "Barrier Free" -memb_amen.3 = "Coffee Pot" -memb_amen.4 = "Hair Dryer" -memb_amen.5 = "Interior Corridor" -memb_amen.6 = "Microwave" -memb_amen.7 = "Refrigerator" -;memb_amen.8 = "Shopping nearby" -;memb_amen.9 = "Indoor pool" -;memb_amen.10 = "Outdoor pool" -;memb_amen.? = "Sauna" -;memb_amen.? = "Whirlpool" -;memb_amen.? = "Valet/Charge Parking" -;memb_amen.? = "Self-operated coin laundry" -;memb_amen.? = "Free parking" -;memb_amen.? = "Fitness area" -;memb_amen.? = "Room service" -;memb_amen.? = "Conference/Meeting facilities" -;memb_amen.? = "Restaurant nearby" -;memb_amen.? = "Restaurant on site" -;memb_amen.? = "Barrier free guest rooms available" -;memb_amen.? = "Pets" -;memb_amen.? = "Golf nearby" - -; Accommodatation Amenitities -; NOT USED AT THIS TIME -;accom_amen.1 = "Cable TV" -;accom_amen.2 = "Movies in Room" -;accom_amen.3 = "Barrier Free Access" -;accom_amen.4 = "Smoke Free Room" -;accom_amen.5 = "Jacuzzi in Room" -;accom_amen.6 = "Iron and Ironing Board" -;accom_amen.7 = "Coffee Pot in Room" -;accom_amen.8 = "Refrigerator in Room" -;accom_amen.9 = "Microwave in Room" -;accom_amen.10 = "Safe" -;accom_amen.11 = "Hair Dryer" - -; Accommodation Room Categories -room_category.0 = "n/a" -room_category.1 = "Bed" -room_category.2 = "Room" -room_category.3 = "Suite" - -; Accommodation Room Types -room_types.0 = "n/a" -room_types.1 = "Main" -room_types.2 = "Bedroom" -room_types.3 = "Kitchen" -room_types.4 = "Living Room" - -; Accommodation Bath Types -bath_types.0 = "None" -bath_types.1 = "Full" -bath_types.2 = "Half" -bath_types.3 = "Sink" - -; Voucher Coupon Types -coupon_type.0 = "Image" -; coupon_type.1 = "PDF" -; coupon_type.2 = "Text" - -; Days of the week - numbers are an exponent of 2 that represent the bit position -days.0 = "Sunday" -days.1 = "Monday" -days.2 = "Tuesday" -days.3 = "Wednesday" -days.4 = "Thursday" -days.5 = "Friday" -days.6 = "Saturday" - -; States -states.AL = "Alabama" -states.AK = "Alaska" -states.AB = "Alberta" -states.AZ = "Arizona" -states.AR = "Arkansas" -states.BC = "British Columbia" -states.CA = "California" -states.CO = "Colorado" -states.CT = "Connecticut" -states.DE = "Delaware" -states.DC = "District of Columbia" -states.FL = "Florida" -states.GA = "Georgia" -states.GU = "Guam" -states.HI = "Hawaii" -states.ID = "Idaho" -states.IL = "Illinois" -states.IN = "Indiana" -states.IA = "Iowa" -states.KS = "Kansas" -states.KY = "Kentucky" -states.LA = "Louisiana" -states.ME = "Maine" -states.MB = "Manitoba" -states.MD = "Maryland" -states.MA = "Massachusetts" -states.MI = "Michigan" -states.MN = "Minnesota" -states.MS = "Mississppi" -states.MO = "Missouri" -states.MT = "Montana" -states.NE = "Nebraska" -states.NV = "Nevada" -states.NB = "New Brunswick" -states.NF = "Newfoundland" -states.NH = "New Hampshire" -states.NJ = "New Jersey" -states.NM = "New Mexico" -states.NY = "New York" -states.NC = "North Carolina" -states.ND = "North Dakota" -states.NT = "Northwest Territories" -states.NS = "Nova Scotia" -states.OH = "Ohio" -states.OK = "Oklahoma" -states.ON = "Ontario" -states.OR = "Oregon" -states.PA = "Pennsylvania" -states.PE = "Prince Edward Island" -states.PR = "Puerto Rico" -states.QC = "Quebec" -states.RI = "Rhode Island" -states.SK = "Saskatchewan" -states.SC = "South Carolina" -states.SD = "South Dakota" -states.TN = "Tennessee" -states.TX = "Texas" -states.UT = "Utah" -states.VT = "Vermont" -states.VI = "Virgin Islands" -states.VA = "Virginia" -states.WA = "Washington" -states.WV = "West Virginia" -states.WI = "Wisconsin" -states.WY = "Wyoming" -states.YT = "Yukon" - -; Countries -countries.US = "United States" -countries.CA = "Canada" -countries.AF = "Afghanistan" -countries.AX = "Land Islands" -countries.AL = "Albania" -countries.DZ = "Algeria" -countries.AS = "American Samoa" -countries.AD = "Andorra" -countries.AO = "Angola" -countries.AI = "Anguilla" -countries.AQ = "Antarctica" -countries.AG = "Antigua and Barbuda" -countries.AR = "Argentina" -countries.AM = "Armenia" -countries.AW = "Aruba" -countries.AU = "Australia" -countries.AT = "Austria" -countries.AZ = "Azerbaijan" -countries.BS = "Bahamas" -countries.BH = "Bahrain" -countries.BD = "Bangladesh" -countries.BB = "Barbados" -countries.BY = "Belarus" -countries.BE = "Belgium" -countries.BZ = "Belize" -countries.BJ = "Benin" -countries.BM = "Bermuda" -countries.BT = "Bhutan" -countries.BO = "Bolivia" -countries.BA = "Bosnia and Herzegovina" -countries.BW = "Botswana" -countries.BV = "Bouvet Island" -countries.BR = "Brazil" -countries.IO = "British Indian Ocean Territory" -countries.BN = "Brunei Darussalam" -countries.BG = "Bulgaria" -countries.BF = "Burkina Faso" -countries.BI = "Burundi" -countries.KH = "Cambodia" -countries.CM = "Cameroon" -countries.CV = "Cape Verde" -countries.KY = "Cayman Islands" -countries.CF = "Central African Republic" -countries.TD = "Chad" -countries.CL = "Chile" -countries.CN = "China" -countries.CX = "Christmas Island" -countries.CC = "Cocos (Keeling) Islands" -countries.CO = "Colombia" -countries.KM = "Comoros" -countries.CG = "Congo" -countries.CD = "Congo, the Democratic Rep. of" -countries.CK = "Cook Islands" -countries.CR = "Costa Rica" -countries.CI = "Cote D'Ivoire" -countries.HR = "Croatia" -countries.CU = "Cuba" -countries.CY = "Cyprus" -countries.CZ = "Czech Republic" -countries.DK = "Denmark" -countries.DJ = "Djibouti" -countries.DM = "Dominica" -countries.DO = "Dominican Republic" -countries.EC = "Ecuador" -countries.EG = "Egypt" -countries.SV = "El Salvador" -countries.GQ = "Equatorial Guinea" -countries.ER = "Eritrea" -countries.EE = "Estonia" -countries.ET = "Ethiopia" -countries.FK = "Falkland Islands (Malvinas)" -countries.FO = "Faroe Islands" -countries.FJ = "Fiji" -countries.FI = "Finland" -countries.FR = "France" -countries.GF = "French Guiana" -countries.PF = "French Polynesia" -countries.TF = "French Southern Territories" -countries.GA = "Gabon" -countries.GM = "Gambia" -countries.GE = "Georgia" -countries.DE = "Germany" -countries.GH = "Ghana" -countries.GI = "Gibraltar" -countries.GR = "Greece" -countries.GL = "Greenland" -countries.GD = "Grenada" -countries.GP = "Guadeloupe" -countries.GU = "Guam" -countries.GT = "Guatemala" -countries.GN = "Guinea" -countries.GW = "Guinea-Bissau" -countries.GY = "Guyana" -countries.HT = "Haiti" -countries.HM = "Heard Island, McDonald Islands" -countries.VA = "Holy see (Vatican City State)" -countries.HN = "Honduras" -countries.HK = "Hong Kong" -countries.HU = "Hungary" -countries.IS = "Iceland" -countries.IN = "India" -countries.ID = "Indonesia" -countries.IR = "Iran, Islamic Republic of" -countries.IQ = "Iraq" -countries.IE = "Ireland" -countries.IL = "Israel" -countries.IT = "Italy" -countries.JM = "Jamaica" -countries.JP = "Japan" -countries.JO = "Jordan" -countries.KZ = "Kazakhstan" -countries.KE = "Kenya" -countries.KI = "Kiribati" -countries.KP = "Korea, Democratic People's Rep. of" -countries.KR = "Korea, Republic of" -countries.KW = "Kuwait" -countries.KG = "Kyrgyzstan" -countries.LA = "Lao People's Democratic Republic" -countries.LV = "Latvia" -countries.LB = "Lebanon" -countries.LS = "Lesotho" -countries.LR = "Liberia" -countries.LY = "Libyan Arab Jamahiriya" -countries.LI = "Liechtenstein" -countries.LT = "Lithuania" -countries.LU = "Luxembourg" -countries.MO = "Macao" -countries.MK = "Macedonia, the Former Yugoslav Rep." -countries.MG = "Madagascar" -countries.MW = "Malawi" -countries.MY = "Malaysia" -countries.MV = "Maldives" -countries.ML = "Mali" -countries.MT = "Malta" -countries.MH = "Marshall Islands" -countries.MQ = "Martinique" -countries.MR = "Mauritania" -countries.MU = "Mauritius" -countries.YT = "Mayotte" -countries.MX = "Mexico" -countries.FM = "Micronesia, Federated States of" -countries.MD = "Moldova, Republic of" -countries.MC = "Monaco" -countries.MN = "Mongolia" -countries.MS = "Montserrat" -countries.MA = "Morocco" -countries.MZ = "Mozambique" -countries.MM = "Myanmar" -countries.NA = "Namibia" -countries.NR = "Nauru" -countries.NP = "Nepal" -countries.NL = "Netherlands" -countries.AN = "Netherlands Antilles" -countries.NC = "New Caledonia" -countries.NZ = "New Zealand" -countries.NI = "Nicaragua" -countries.NE = "Niger" -countries.NG = "Nigeria" -countries.NU = "Niue" -countries.NF = "Norfolk Island" -countries.MP = "Northern Mariana Islands" -countries.NO = "Norway" -countries.OM = "Oman" -countries.PK = "Pakistan" -countries.PW = "Palau" -countries.PS = "Palestinian Territory, Occupied" -countries.PA = "Panama" -countries.PG = "Papua New Guinea" -countries.PY = "Paraguay" -countries.PE = "Peru" -countries.PH = "Philippines" -countries.PN = "Pitcairn" -countries.PL = "Poland" -countries.PT = "Portugal" -countries.PR = "Puerto Rico" -countries.QA = "Qatar" -countries.RE = "Reunion" -countries.RO = "Romania" -countries.RU = "Russian Federation" -countries.RW = "Rwanda" -countries.SH = "Saint Helena" -countries.KN = "Saint Kitts and Nevis" -countries.LC = "Saint Lucia" -countries.PM = "Saint Pierre and Miquelon" -countries.VC = "Saint Vincent and the Grenadines" -countries.WS = "Samoa" -countries.SM = "San Marino" -countries.ST = "Sao Tome and Principe" -countries.SA = "Saudi Arabia" -countries.SN = "Senegal" -countries.CS = "Serbia and Montenegro" -countries.SC = "Seychelles" -countries.SL = "Sierra Leone" -countries.SG = "Singapore" -countries.SK = "Slovakia" -countries.SI = "Slovenia" -countries.SB = "Solomon Islands" -countries.SO = "Somalia" -countries.ZA = "South Africa" -countries.GS = "South Georgia, South Sandwich Islands" -countries.ES = "Spain" -countries.LK = "Sri Lanka" -countries.SD = "Sudan" -countries.SR = "Suriname" -countries.SJ = "Svalbard and Jan Mayen" -countries.SZ = "Swaziland" -countries.SE = "Sweden" -countries.CH = "Switzerland" -countries.SY = "Syrian Arab Republic" -countries.TW = "Taiwan, Province of China" -countries.TJ = "Tajikistan" -countries.TZ = "Tanzania, United Republic of" -countries.TH = "Thailand" -countries.TL = "Timor-Leste" -countries.TG = "Togo" -countries.TK = "Tokelau" -countries.TO = "Tonga" -countries.TT = "Trinidad and Tobago" -countries.TN = "Tunisia" -countries.TR = "Turkey" -countries.TM = "Turkmenistan" -countries.TC = "Turks and Caicos Islands" -countries.TV = "Tuvalu" -countries.UG = "Uganda" -countries.UA = "Ukraine" -countries.AE = "United Arab Emirates" -countries.GB = "United Kingdom" -countries.UM = "United States minor outlying islands" -countries.UY = "Uruguay" -countries.UZ = "Uzbekistan" -countries.VU = "Vanuatu" -countries.VE = "Venezuela" -countries.VN = "Viet Nam" -countries.VG = "Virgin Islands, British" -countries.VI = "Virgin Islands, U.S." -countries.WF = "Wallis and Futuna" -countries.EH = "Western Sahara" -countries.YE = "Yemen" -countries.ZM = "Zambia" -countries.ZW = "Zimbabwe" - -; Standard color names and codes -color.800000 = 'maroon' -color.8B0000 = 'darkred' -color.FF0000 = 'red' -color.FFB6C1 = 'lightpink' -color.DC143C = 'crimson' -color.DB7093 = 'palevioletred' -color.FF69B4 = 'hotpink' -color.FF1493 = 'deeppink' -color.C71585 = 'mediumvioletred' -color.800080 = 'purple' -color.8B008B = 'darkmagenta' -color.DA70D6 = 'orchid' -color.D8BFD8 = 'thistle' -color.DDA0DD = 'plum' -color.EE82EE = 'violet' -color.FF00FF = 'fuchsia' -color.FF00FF = 'magenta' -color.BA55D3 = 'mediumorchid' -color.9400D3 = 'darkviolet' -color.9932CC = 'darkorchid' -color.8A2BE2 = 'blueviolet' -color.4B0082 = 'indigo' -color.9370DB = 'mediumpurple' -color.6A5ACD = 'slateblue' -color.7B68EE = 'mediumslateblue' -color.00008B = 'darkblue' -color.05367D = 'mackinawblue' -color.0000CD = 'mediumblue' -color.0000FF = 'blue' -color.000080 = 'navy' -color.191970 = 'midnightblue' -color.483D8B = 'darkslateblue' -color.4169E1 = 'royalblue' -color.6495ED = 'cornflowerblue' -color.B0C4DE = 'lightsteelblue' -color.F0F8FF = 'aliceblue' -color.F8F8FF = 'ghostwhite' -color.E6E6FA = 'lavender' -color.1E90FF = 'dodgerblue' -color.4682B4 = 'steelblue' -color.00BFFF = 'deepskyblue' -color.708090 = 'slategray' -color.778899 = 'lightslategray' -color.87CEFA = 'lightskyblue' -color.87CEEB = 'skyblue' -color.ADD8E6 = 'lightblue' -color.008080 = 'teal' -color.008B8B = 'darkcyan' -color.00CED1 = 'darkturquoise' -color.00FFFF = 'aqua' -color.48D1CC = 'mediumturquoise' -color.5F9EA0 = 'cadetblue' -color.AFEEEE = 'paleturquoise' -color.E0FFFF = 'lightcyan' -color.F0FFFF = 'azure' -color.20B2AA = 'lightseagreen' -color.40E0D0 = 'turquoise' -color.B0E0E6 = 'powderblue' -color.2F4F4F = 'darkslategray' -color.7FFFD4 = 'aquamarine' -color.00FA9A = 'mediumspringgreen' -color.66CDAA = 'mediumaquamarine' -color.00FF7F = 'springgreen' -color.3CB371 = 'mediumseagreen' -color.2E8B57 = 'seagreen' -color.32CD32 = 'limegreen' -color.006400 = 'darkgreen' -color.008000 = 'green' -color.00FF00 = 'lime' -color.228B22 = 'forestgreen' -color.8FBC8F = 'darkseagreen' -color.90EE90 = 'lightgreen' -color.98FB98 = 'palegreen' -color.F5FFFA = 'mintcream' -color.F0FFF0 = 'honeydew' -color.7FFF00 = 'chartreuse' -color.7CFC00 = 'lawngreen' -color.6B8E23 = 'olivedrab' -color.556B2F = 'darkolivegreen' -color.9ACD32 = 'yellowgreen' -color.ADFF2F = 'greenyellow' -color.F5F5DC = 'beige' -color.FAF0E6 = 'linen' -color.FAFAD2 = 'lightgoldenrodyellow' -color.808000 = 'olive' -color.FFFF00 = 'yellow' -color.FFFFE0 = 'lightyellow' -color.FFFFF0 = 'ivory' -color.BDB76B = 'darkkhaki' -color.F0E68C = 'khaki' -color.EEE8AA = 'palegoldenrod' -color.F5DEB3 = 'wheat' -color.FFD700 = 'gold' -color.FFFACD = 'lemonchiffon' -color.FFEFD5 = 'papayawhip' -color.B8860B = 'darkgoldenrod' -color.DAA520 = 'goldenrod' -color.FAEBD7 = 'antiquewhite' -color.FFF8DC = 'cornsilk' -color.FDF5E6 = 'oldlace' -color.FFE4B5 = 'moccasin' -color.FFDEAD = 'navajowhite' -color.FFA500 = 'orange' -color.FFE4C4 = 'bisque' -color.D2B48C = 'tan' -color.FF8C00 = 'darkorange' -color.DEB887 = 'burlywood' -color.8B4513 = 'saddlebrown' -color.F4A460 = 'sandybrown' -color.FFEBCD = 'blanchedalmond' -color.FFF0F5 = 'lavenderblush' -color.FFF5EE = 'seashell' -color.FFFAF0 = 'floralwhite' -color.FFFAFA = 'snow' -color.CD853F = 'peru' -color.FFDAB9 = 'peachpuff' -color.D2691E = 'chocolate' -color.A0522D = 'sienna' -color.FFA07A = 'lightsalmon' -color.FF7F50 = 'coral' -color.E9967A = 'darksalmon' -color.FFE4E1 = 'mistyrose' -color.FF4500 = 'orangered' -color.FA8072 = 'salmon' -color.FF6347 = 'tomato' -color.BC8F8F = 'rosybrown' -color.FFC0CB = 'pink' -color.CD5C5C = 'indianred' -color.F08080 = 'lightcoral' -color.A52A2A = 'brown' -color.B22222 = 'firebrick' -color.000000 = 'black' -color.696969 = 'dimgray' -color.808080 = 'gray' -color.A9A9A9 = 'darkgray' -color.C0C0C0 = 'silver' -color.D3D3D3 = 'lightgrey' -color.DCDCDC = 'gainsboro' -color.F5F5F5 = 'whitesmoke' -color.FFFFFF = 'white' - -[production : common] -; Debugging and Testing parameters -option.development = false ;Tells templates that this is a production server -option.admin_debug = false ;If true causes system to dump diagnostic data to a separate window -option.admin_debug_size = 800 ;Width in pixels of front debug window -option.front_debug = false ;If true causes system to dump diagnostic data to a separate window -option.front_debug_size = 800 ;Width in pixels of front debug window -option.preview = true ;Use "preview=1" in links to support preview feature -option.checkout_pre_fill = false ;Use for testing, prefills checkout data for convenience -debug.level = 0 ;Debug level - 0=off -debug.view_parameters = false ;Display all View tags and information -debug.housing_query = false ;Display main housing query -debug.pricing = false ;Detailed information on pricing and cost calculations -debug.checkout = false ;Display checkout processing steps and data -debug.mail = false ;Display mail rather than send it -debug.glmpdf = false ;Display calibration grids in PDFs - -[development : common] -; Debugging and Testing parameters -option.development = true ;Tells templates that this is a development server -option.admin_debug = false ;If true causes system to dump diagnostic data to a separate window -option.admin_debug_size = 800 ;Width in pixels of front debug window -option.front_debug = false ;If true causes system to dump diagnostic data to a separate window -option.front_debug_size = 800 ;Width in pixels of front debug window -option.preview = true ;Use "preview=1" in links to support preview feature -option.checkout_pre_fill = false ;Use for testing, prefills checkout data for convenience -debug.level = 0 ;Debug level - 0=off -debug.view_parameters = false ;Display all View tags and information -debug.housing_query = false ;Display main housing query -debug.pricing = false ;Detailed information on pricing and cost calculations -debug.checkout = false ;Display checkout processing steps and data -debug.mail = false ;Display mail rather than send it -debug.glmpdf = false ;Display calibration grids in PDFs - -[chuck : common] -; Debugging and Testing parameters -option.development = true ;Tells templates that this is a development server -option.admin_debug = true ;If true causes system to dump diagnostic data to a separate window -option.admin_debug_size = 800 ;Width in pixels of front debug window -option.front_debug = true ;If true causes system to dump diagnostic data to a separate window -option.front_debug_size = 800 ;Width in pixels of front debug window -option.preview = false ;Use "preview=1" in links to support preview feature -option.checkout_pre_fill = true ;Use for testing, prefills checkout data for convenience -debug.level = 1 ;Debug level - 0=off, 1=Show Function Calls -debug.view_parameters = false ;Display all View tags and information -debug.housing_query = false ;Display main housing query -debug.pricing = false ;Detailed information on pricing and cost calculations -debug.checkout = false ;Display checkout processing steps and data -debug.mail = true ;Display mail rather than send it -debug.glmpdf = false ;Display calibration grids in PDFs diff --git a/legacy/controllers/AdminController.php b/legacy/controllers/AdminController.php deleted file mode 100644 index 5a85dc7..0000000 --- a/legacy/controllers/AdminController.php +++ /dev/null @@ -1,1051 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: EventManagement.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -/* - * Need to explain all this - */ -class EventManagementPage -{ - - public $level; - - function setUserLevel($level) - { - $this->level = $level; - } - - function checkPermission($userPermissionLevel) - { - if ($userPermissionLevel >= $this->level) { - return true; - } - return false; - } - -} - - -/** - * EventManagementAdminIndexController class - * - * Event Management System - Admin main index - * - * PHP version 5 - * - * @category Reservations_Front_End - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: EventManagement.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ -class EventManagementAdminIndexController -{ - - /** - * Debug Information - * @var $adminDebug - * @access public - */ - private $adminDebug = ''; - private $adminDebugMenu = ''; - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - private $applicationConfig; - private $serverConfig; - private $siteConfig; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $isa; - public $imageServer; - /** - * Reason for any problems that come up - * @var unknown - * @access public - */ - public $reason = array(); - /** - * Current Action - * Default is set to SelectConv - * @var $Action - * @access public - */ - public $Action = 'SelectConv'; - /** - * Template to use for output - * @var unknown - * @access public - */ - public $flexyOptions; - public $template; - public $page; - /** - * User Level - * @var unknown - * @access public - */ - public $userLevel = false; - /** - * User Interface - * @var unknown - * @access public - */ - public $interface = false; - public $userInterface = false; - public $userInterfaces = false; - public $userInterfacesSelectable = false; - - public $customFeatures = false; - public $userMemberID = false; - public $memberName = false; - public $userMemberVenueName = false; - public $MemberUser = false; - public $MemberUserValid = false; - public $AdminUser = false; - public $tabList = false; - public $blockTab = false; - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - public function __construct($applicationConfig, $serverConfig, $siteConfig) - { - - // Save config data and build a common config object - $this->applicationConfig = $applicationConfig; - $this->serverConfig = $serverConfig; - $this->siteConfig = $siteConfig; - $this->buildIntegratedConfig(); - - // Setup some required defines for this application - $this->setupDefines(); - - // Create database connection - $this->dbh = Toolkit_Database::getInstance(); - - // Set debug file name that includes remote address to keep users separate - if ($this->config->option->admin_debug) { - define('DEBUG_DATA_FILENAME', '/tmp/EventManagement.'.$_SERVER['REMOTE_ADDR'].'.debug.html'); - } - - // If there's no custom front-end, then disable custom features (i.e. Misc menu in admin) - $this->customFeatures = false; - if ($this->config->custom_prefix != '') { - $this->customFeatures = true; - } - - // Start Session - $this->startSession(); - - // Get requested action - $this->getRequestedAction(); - - // Check for a member user - $this->checkMemberUser(); - - // Check if there's a request to reset all selected items - $this->checkResetSelected(); - - // User interface selection - $this->userInterfaceSelection(); - - // Track selected tabs so they aren't repeated in the user interface - $this->trackTabs(); - - // Setup page and template configurations and add some standard page data - $this->setupTemplate(); - - // Setup URLs and Locations for templates - $this->setupURLs(); - - // Add start of request debug data - $this->startOfRequestDebug(); - - // Perform requested action and add this to debug - $this->performAction(); - - // Display Output - $this->displayOutput(); - - // Output debug information if that's enabled - $this->displayDebug(); - - } - - /** - * Assemble all required config data into $this->config - * - * @return void - */ - private function buildIntegratedConfig() - { - - // Set common apps base location - define('COMMON_APP_BASE', '/var/www/server/CommonApps/'); - - // Get customer's config for this application and Merge in customer's main application.ini - $this->config = new Zend_Config_Ini( - BASE_PATH.'config/applications/EventManagement.ini', - strtolower($_ENV['GLM_HOST_ID']), - array('allowModifications' => true) - ); - $this->config->merge($this->applicationConfig->event_management); - $this->config->owner = $this->siteConfig->owner; - $this->config->file_server = $this->serverConfig->file_server; - - // Set location for this application - define('EVENT_MANAGEMENT_APP_BASE', COMMON_APP_BASE.$this->config->version.'/'); - - // Get common config data for this application and merge in site specific config - $EMConfig = new Zend_Config_Ini( - EVENT_MANAGEMENT_APP_BASE.'configs/common.ini', - strtolower($_ENV['GLM_HOST_ID']), - array('allowModifications' => true) - ); - $this->config->merge($EMConfig); - - } - - /** - * Set system defines - * - * @return void - */ - private function setupDefines() - { - - // Set datestyle string for DB results - define('DATE_STYLE_STRING', $this->config->misc->datestyle ); - - // Set common apps base location - define('DATA_ABSTRACT', COMMON_APP_BASE.'CommonAbstracts/'.$this->config->dataAbstractLocation.'/DataAbstract.php'); - define('PDF_ABSTRACT', COMMON_APP_BASE.'CommonAbstracts/'.$this->config->pdfAbstractLocation.'/GlmPdf.php'); - define('IMAGE_SERVER_ABSTRACT', COMMON_APP_BASE.'CommonAbstracts/'.$this->config->imageServerAbstractLocation.'/Server.php'); - - // Also set a defined parameter for access to the File/Image Server - define('IMAGE_SERVER_PREFIX', $this->config->file_server->secure.$this->config->file_server->owner_id.'/'); - - } - - /** - * Start Session - * - * @return object containing array as sub-objects - */ - function startSession($force = false) - { - // If we haven't started sessions yet - if (!isset($_SESSION)) { - session_start(); - } - - // Use "session_reset=true" in link to force a reset - if ($_REQUEST['session_reset'] == 'true') { - $force = true; - } - - // Set a different session name if the user is coming from the front end as an ADMIN_LOGIN_USER - if (defined('MEMBER_USER') && MEMBER_USER) { - define('GLM_EVENT_SESSION', 'GLM_EVENT_MGT_LOGIN_USER'); - } else { - define('GLM_EVENT_SESSION', 'GLM_EVENT_MGT_ADMIN'); - - // Define MEMBER_USER as false so we don't have to keep checking if it's defined - define('MEMBER_USER', false); - } - - // If the session timeout has past then reset session - if ($_SESSION[GLM_EVENT_SESSION]['timeOut'] < time()) { - $force = true; - - // Only notify the user if the session has timed out in the last hour - if (time() - $_SESSION[GLM_EVENT_SESSION]['timeOut'] < 60*60 ) { - $this->reason[] = 'Your user session has timed out due to inactivity.'; - } - } - - // If requested or not yet set, create a clean session array - if ($force || !isset($_SESSION[GLM_EVENT_SESSION])) { - - // But save certain things - $this->interface = $_SESSION[GLM_EVENT_SESSION]['Interface']; - if ($_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $userMember = $_SESSION[GLM_EVENT_SESSION]['Member']; - $userID = $_SESSION[GLM_EVENT_SESSION]['MemberUser']; - $userLevel = $_SESSION[GLM_EVENT_SESSION]['MemberUserLevel']; - } else { - $userID = false; - $userLevel = $this->config->permissions_numb->none; - } - - // If full reset then set user interface back to default - if ($force) { - $this->interface = $this->config->default_admin_interface; - } - - // create GLM_HOUSING session with all parameters false - $_SESSION[GLM_EVENT_SESSION] = array( - 'timeOut' => false, - 'Event' => false, - 'Member' => $userMember, - 'Accom' => false, - 'Inven' => false, - 'Team' => false, - 'Booking' => false, - 'Reservation' => false, - 'State' => false, - 'Division' => false, - 'Contact' => false, - 'Entrance' => false, - 'Section' => false, - 'Performance' => false, - 'Promo' => false, - 'Ticket' => false, - 'TicketInventory' => false, - 'Interface' => $this->interface, - 'TabsSelected' => false, - 'Order' => false, - 'MemberUser' => $userID, - 'MemberUserLevel' => $userLevel, - 'VoucherCoupon' => false - ); - - } - - // Reset session timeout to current time plus timeout length in minutes - $_SESSION[GLM_EVENT_SESSION]['timeOut'] = strtotime('now +'.$this->config->admin_session_timeout.' minutes'); - - $this->addDebug('startSession()', 'Session timeout at: '.date('r', $_SESSION[GLM_EVENT_SESSION]['timeOut']).' ('.$_SESSION[GLM_EVENT_SESSION]['timeOut'].')'); - - } - - /** - * Get requested action - * - * @return void - */ - private function getRequestedAction() - { - - // Try both GET and POST - if (!($this->Action = filter_input(INPUT_GET, 'Action', FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_HIGH)) && - !($this->Action = filter_input(INPUT_POST, 'Action', FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_HIGH)) - ) { - // No Action provided, so doing default - $this->Action = 'Index_index'; - } - - } - - /** - * Check for member user - * - * @return void - */ - private function checkMemberUser() - { - - // Start with assumption that we don't have a valid member user - $this->MemberUserValid = false; - - // Override for debug window - if ($this->Action == "Debug_start" || $this->Action == "Debug_update") { - $this->MemberUser = false; - $this->AdminUser = true; - } - - // Check if this is a member logout. If so, send user back to front-end. - if ($_REQUEST['EMlogout'] == 'true') { - $_SESSION[GLM_EVENT_SESSION]['MemberUser'] = false; - $_SESSION[GLM_EVENT_SESSION]['MemberUserLevel'] = 0; - - echo ' - '; - } - - // If this is a member user, and we're not processing a debug request - if (MEMBER_USER && $this->Action != "Debug_start" && $this->Action != "Debug_update") { - - // Check if we aren't getting a login request and we already have a member user login - if ($this->Action != "User_login" && $_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - - // Check the current user level - $sql = " - SELECT C.id, C.user_rights, C.active, C.affiliation, C.fname, C.lname, M.name - FROM eventmgt.res_contact C, eventmgt.member M - WHERE C.id = ".$_SESSION[GLM_EVENT_SESSION]['MemberUser']." - AND M.id = C.affiliation - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $contact = $stmt->fetch(PDO::FETCH_ASSOC); - - // If the contact has been deleted, is marked inactive, or had their rights changed - if ($contact == false || !$contact['active'] || $contact['user_rights'] != $_SESSION[GLM_EVENT_SESSION]['MemberUserLevel']) { - - // Send the user back to login - $_SESSION[GLM_EVENT_SESSION]['MemberUser'] = false; - $reason = - "Your session is being reset. This can happen for one of the following reasons. " - ."Your permissions have changed, " - ."your user account has been marked inactive, " - ."your user account has been deleted, " - ."or there has been an unexpected system error."; - echo ' - - '; - exit; - - } - - // Otherwise we must not have a current login - } else { - - // Assume we're not going to get logged in and we're going to send them back - $this->Action = 'User_login'; - - $email = filter_input(INPUT_POST, 'email', FILTER_SANITIZE_EMAIL); - $password = filter_input(INPUT_POST, 'password', FILTER_SANITIZE_STRING); - - // Check if we have email and password supplied - if ($email != '' && $password != '') { - - $loginFail = false; - - // Crypt password - $pwCrypt = crypt($password); - - // Check contact table for user with the supplied E-Mail address - $sql = " - SELECT C.id, C.password, C.user_rights, C.active, C.contact_type, C.affiliation, C.fname, C.lname, M.name - FROM eventmgt.res_contact C, eventmgt.member M - WHERE (C.email = '$email' OR C.login_id = '$email') - AND M.id = C.affiliation - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $contact = $stmt->fetch(PDO::FETCH_ASSOC); - - // If we found a contact with this E-Mail address that's active - if ($contact != false && $contact['active'] && $contact['contact_type'] == 2) { - - // Does the crypt match? - if (crypt($password, $contact['password']) == $contact['password']) { - - // Yep, so send user to the admin home - $this->Action = 'Index_index'; - - // And save the user login info - $_SESSION[GLM_EVENT_SESSION]['Member'] = $contact['affiliation']; - $_SESSION[GLM_EVENT_SESSION]['MemberUser'] = $contact['id']; - $_SESSION[GLM_EVENT_SESSION]['MemberUserLevel'] = $contact['user_rights']; - - } else { - $loginFail = true; - } - - } else { - $loginFail = true; - } - - if ($loginFail) { - $this->reason[] = 'You did not supply a valid E-Mail address or Log in ID and password.'; - } - - } - - } // Don't have member user login - - } else { - if ($this->Action != "Debug_start" && $this->Action != "Debug_update") { - // The user is not a MemberUser, so must be an admin user - Give full permissions - $_SESSION[GLM_EVENT_SESSION]['MemberUser'] = false; - $_SESSION[GLM_EVENT_SESSION]['MemberUserLevel'] = 0; - } - } - - // This stuffs the current user level into the EventManagementPage class parameter - if ($_SESSION[GLM_EVENT_SESSION]['MemberUserLevel'] > 0) { - $this->userMemberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - $this->memberName = $contact['fname']." ".$contact['lname']; - $this->userMemberVenueName = $contact['name']; - } else { - $this->userMemberID = false; - $this->memberName = ''; - $this->userMemberVenueName = ''; - } - - } - - - /** - * Check if selected items reset has been requested - * - * @return void - */ - private function checkResetSelected() - { - - // If requested, reset all selected items in the session - This is done with all main tabs - if ($_REQUEST['resetSelected'] == 'true') { - - $_SESSION[GLM_EVENT_SESSION]['Event'] = false; - if (!$_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $_SESSION[GLM_EVENT_SESSION]['Member'] = false; - } - $_SESSION[GLM_EVENT_SESSION]['Accom'] = false; - $_SESSION[GLM_EVENT_SESSION]['Team'] = false; - $_SESSION[GLM_EVENT_SESSION]['Booking'] = false; - $_SESSION[GLM_EVENT_SESSION]['Reservation'] = false; - $_SESSION[GLM_EVENT_SESSION]['State'] = false; - $_SESSION[GLM_EVENT_SESSION]['Division'] = false; - $_SESSION[GLM_EVENT_SESSION]['Contact'] = false; - $_SESSION[GLM_EVENT_SESSION]['Section'] = false; - $_SESSION[GLM_EVENT_SESSION]['Performance'] = false; - $_SESSION[GLM_EVENT_SESSION]['Ticket'] = false; - $_SESSION[GLM_EVENT_SESSION]['TicketInventory'] = false; - $_SESSION[GLM_EVENT_SESSION]['Order'] = false; - - } - - } - - /** - * User Interface selection (template dir) - * - * @return void - */ - private function userInterfaceSelection() - { - - // Is there a request for a specific interface - if (isset($_REQUEST['interface']) && - in_array($_REQUEST['interface'], $this->config->admin_interface->toArray()) - ) { - $this->interface = $_REQUEST['interface']; - // Oherwise, do we have an interface selection in the user session? - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Interface']) && $_SESSION[GLM_EVENT_SESSION]['Interface'] != '') { - $this->interface = $_SESSION[GLM_EVENT_SESSION]['Interface']; - // If neither, then use default user interface. - } else { - $this->interface = $this->config->default_admin_interface; - } - - // Update session and page to show selected user interface - $_SESSION[GLM_EVENT_SESSION]['Interface'] = $this->interface; - $this->userInterface = $this->interface; - - // Provide list of user interfaces to page - $interfaces = $this->config->admin_interface->toArray(); - $userInterfaces = array(); - foreach ($interfaces as $i) { - $userInterfaces[] = array( - 'directory' => $i, - 'name' => $i, - 'selected' => ($i == $this->interface) - ); - } - - // If there's more than 1 user interface then tell the template to display user interface selection - $this->userInterfacesSelectable = ($this->config->admin_interface->selectable && count($interfaces) > 1); - $this->userInterfaces = $this->bindArrayToObject($userInterfaces); - - } - - /** - * Track tabs that are selected - * - * This is to keep from displaying another tab in a - * lower layer that's already been displayed. - * - * @return void - */ - private function trackTabs() - { - - // If tab list is provided - if (isset($_REQUEST['tabList'])) { - $this->tabList = $_REQUEST['tabList']; - } else { - $this->tabList = ''; - } - if ($this->tabList != '') { - $this->tabList .= ','; - } - $this->tabList .= $this->Action; - - $blockTab = array(); - $nt = explode(',', $this->tabList); - foreach ($nt as $t) { - $blockTab[$t] = true; - } - $this->blockTab = $this->bindArrayToObject($blockTab); - - } - - /** - * Set template configuration - * - * @return void - */ - private function setupTemplate() - { - // Test if there is a local templates directory for the Web site - if (is_dir(BASE_PATH.'admin/EventManagement/templates')) { - $templatesDir = BASE_PATH.'admin/EventManagement/templates/admin/'; - } else { - // Otherwise use the templates in this app - $templatesDir = EVENT_MANAGEMENT_APP_BASE.'views/admin/'; - } - - // Setup Template and Page - $this->flexyOptions = array( - 'templateDir' => $templatesDir, - 'compileDir' => BASE_PATH.'/templates/compiled', - 'forceCompile' => false, - 'flexyIgnore' => true, - 'allowPHP' => true, - 'debug' => false - ); - $this->template = new HTML_Template_Flexy($this->flexyOptions); - $this->page = new EventManagementPage(); - - // Add some standard page data - $this->page->startScript = ' - '; - } - - } - - } - - /** - * Get all general search lists - Events, Members, etc - * - * @return object containing array as sub-objects - */ - function getSearchLists() - { - // Get full list of events - $sql = "SELECT id, name, event_code, active, end_date < 'now' AS expired, team_event - FROM eventmgt.event - ORDER BY name;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventsList = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Get full list of members - $sql = "SELECT id, name FROM eventmgt.member ORDER BY name;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $membersList = $stmt->fetchAll(PDO::FETCH_ASSOC); - - while( list($key, $val) = each( $membersList ) ) { - $membersList[$key]['name'] = addslashes($val['name']); - } - - // Get full list of Teams - $sql = "SELECT id, name FROM eventmgt.team ORDER BY name;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $teamsList = $stmt->fetchAll(PDO::FETCH_ASSOC); - - while( list($key, $val) = each( $teamsList ) ) { - $teamsList[$key]['name'] = addslashes($val['name']); - } - - $searchLists = array( - 'events' => $eventsList, - 'teamList' => $teamsList, - 'members' => $membersList - ); - - if ($this->config->option->admin_debug) { - $this->adminDebug .= "

EventManagement.php: getSearchLists()

".print_r($searchLists,1)."

"; - } - - return $searchLists; - } - - /** - * Format a number as money - * - * @param $value Value to format - * @param $option Options that control output - * NOPREFIX stops the "$" prefix - * - * @return none - * @access public - */ - private function money($value, $option = "") - { - - if ($option == "NOPREFIX") - $prefix = ""; - else - $prefix = "$"; - - // Do value sanity check - - if (!is_numeric($value)) - return ($prefix."0.00"); - - return ($prefix.number_format($value, 2, ".", ",")); - } - - -} - -// Start Event Management Admin - Pass the site's global application config data -$eh = new EventManagementAdminIndexController($GLOBALS['applicationConfig'], $GLOBALS['serverConfig'], $GLOBALS['siteConfig']); - -// If this is an admin user initial entry or if this is an admin user login -if (!(defined('SHOW_IN_SITE') && SHOW_IN_SITE)) { - exit; -} - - - -?> diff --git a/legacy/controllers/FrontController.php b/legacy/controllers/FrontController.php deleted file mode 100644 index ce90908..0000000 --- a/legacy/controllers/FrontController.php +++ /dev/null @@ -1,904 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: FrontController.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -/* - -Custom Index file - {GLM} is replaced with a template include file that calls the selected template. - -If custom index - - base_url is /index.phtml - directly calls front-end controller - - Controller determines action and calls proper include file for that action - returns selected template file and data - - Controller - sets page->template parameter - calls custom index template - Template uses page-template parameter to include the target template. - -else - base_url is specified static page -end - -*/ - -/** - * EventManagementFrontIndexController class - * - * Event Management System - Front end main index - * - * PHP version 5 - * - * @category Reservations_Front_End - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: FrontController.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ -class EventManagementIndexController -{ - - /** - * Front End Support - * @var $frontDebug - * @access public - */ - public $support = false; - /** - * Debug Information - * @var $frontDebug - * @access public - */ - public $frontDebug = ''; - private $frontDebugMenu = ''; - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $isa; - public $imageServer; - /** - * Reason for any problems that come up - * @var unknown - * @access public - */ - public $reason = array(); - /** - * Have Cart - * @var $haveCart - * @access public - */ - public $haveCart = false; - /** - * Current Action - * Default is set to SelectConv - * @var $Action - * @access public - */ - public $Action = ''; - /** - * Template to use for output - * @var unknown - * @access public - */ - public $flexyOptions; - public $template; - private $page; - private $smarty; - /** - * User Interface - * @var unknown - * @access public - */ - private $userInterface = false; - private $interfaceType = false; - private $userInterfaces = false; - private $userInterfacesSelectable = false; - public $memberUser = false; - - private $resetSession = false; - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - public function __construct($applicationConfig, $serverConfig, $siteConfig) - { - - // Save config data and build a common config object - $this->applicationConfig = $applicationConfig; - $this->serverConfig = $serverConfig; - $this->siteConfig = $siteConfig; - $this->buildIntegratedConfig(); - - // Setup some required defines for this application - $this->setupDefines(); - - // Create database connection - $this->dbh = Toolkit_Database::getInstance(); - - // Set debug file name - if ($this->config->option->front_debug) { - define('DEBUG_DATA_FILENAME', '/tmp/EventManagement.'.$_SERVER['REMOTE_ADDR'].'.debug.html'); - } - - // Provide front-end support class - require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; - $this->support = new EventManagementFrontSupport($this->dbh, $this->config); - - // start this user session - $this->startSession(); - - // User interface selection - $this->userInterfaceSelection(); - - // Setup page and template configurations and add some standard page data - $this->setupTemplate(); - - // Perform requested action and add this to debug - $this->performAction(); - - // Display Output - $this->displayOutput(); - - // Check if we need to clear the session - if ($this->resetSession) { - $this->startSession(true); - } - - // Output debug information if that's enabled - $this->displayDebug(); - - // If this is a debug output page then stop here. - if (substr($this->Action,0,6) == 'Debug_') { - exit; - } - - } // _constructor - - /** - * Assemble all required config data into $this->config - * - * @return void - */ - private function buildIntegratedConfig() - { - - // Set common apps base location - define('COMMON_APP_BASE', '/var/www/server/CommonApps/'); - - // Get customer's config for this application and Merge in customer's main application.ini - $this->config = new Zend_Config_Ini( - BASE_PATH.'config/applications/EventManagement.ini', - strtolower($_ENV['GLM_HOST_ID']), - array('allowModifications' => true) - ); - $this->config->merge($this->applicationConfig->event_management); - $this->config->owner = $this->siteConfig->owner; - $this->config->file_server = $this->serverConfig->file_server; - - // Set location for this application - define('EVENT_MANAGEMENT_APP_BASE', COMMON_APP_BASE.$this->config->version.'/'); - - // Get common configuration for this application - $EMconfig = new Zend_Config_Ini( - EVENT_MANAGEMENT_APP_BASE.'configs/common.ini', - strtolower($_ENV['GLM_HOST_ID']), - array('allowModifications' => true) - ); - $this->config->merge($EMconfig); - - } - - /** - * Set system defines - * - * @return void - */ - private function setupDefines() - { - // Set datestyle string for DB results - define('DATE_STYLE_STRING', $this->config->misc->datestyle ); - - // Set common apps base location - define('DATA_ABSTRACT', COMMON_APP_BASE.'CommonAbstracts/'.$this->config->dataAbstractLocation.'/DataAbstract.php'); - define('PDF_ABSTRACT', COMMON_APP_BASE.'CommonAbstracts/'.$this->config->pdfAbstractLocation.'/GlmPdf.php'); - define('IMAGE_SERVER_ABSTRACT', COMMON_APP_BASE.'CommonAbstracts/'.$this->config->imageServerAbstractLocation.'/Server.php'); - - define('GLM_EVENT_SESSION', 'GLM_EVENT_MGT_FRONT'); - - // Also set a defined parameter for access to the File/Image Server - define('IMAGE_SERVER_PREFIX', $this->config->file_server->secure.$this->config->file_server->owner_id.'/'); - - // Set base script - If there's an application URL defined, use that, otherwise use page ID - $baseApplicationScript = ($this->config->application_url != '' ? - CURRENT_BASE_URL.$this->config->application_url.'/?x=1' : - CURRENT_BASE_URL.'index.php?catid='.$this->config->application_page - ); - define('BASE_APPLICATION_SCRIPT', $baseApplicationScript); - - // Set base URL - $baseApplicationUrl = ($this->config->application_page == 0 ? - $baseScript : - CURRENT_BASE_URL.'common/EventManagement/' - ); - define('BASE_APPLICATION_URL', $baseApplicationUrl); - - } - - /** - * Destroy Event Management Front-end Session - * - * @return object containing array as sub-objects - */ - function destroySession() - { - unset($_SESSION[GLM_EVENT_SESSION]); - return; - } - - /** - * Start Session - * - * @return object containing array as sub-objects - */ - function startSession($force = false) - { - - // If we haven't started sessions yet - if (!isset($_SESSION)) { - session_start(); - } - - // Use "session_reset=true" in link to force a reset - if ($_REQUEST['session_reset'] == 'true') { - $force = true; - } - - // If the session timeout has past then reset session - if ($_SESSION[GLM_EVENT_SESSION]['timeOut'] < time()) { - - $force = true; - - // Only notify the user if the session has timed out in the last hour - if (time() - $_SESSION[GLM_EVENT_SESSION]['timeOut'] < 60*60 ) { - $this->reason[] = 'Your user session has timed out due to inactivity and your cart has been cleared.'; - } - - // If adding items to cart, continue to do that, if not, reset Action - if ($_REQUEST['Action'] != 'Shop_cart' || $_REQUEST['cart'] != 'add') { - $this->Action = 'Shop_start'; - } - - } - - // If requested or not yet set, create a clean GLM_HOUSING session array - if ($force || !isset($_SESSION[GLM_EVENT_SESSION])) { - - // But save interface - $this->userInterface = $_SESSION[GLM_EVENT_SESSION]['Interface']; - - // If full reset then clear this also - if ($force) { - $this->userInterface = false; - } - - // create GLM_HOUSING session with all parameters false - $_SESSION[GLM_EVENT_SESSION] = array( - 'SessionID' => md5(($_SERVER["REMOTE_ADDR"].'-'.time())), - 'PseudoRand' => false, - 'permitInactive' => $this->permitInactive, - 'timeOut' => false, - 'Event' => false, - 'Member' => false, - 'Accom' => false, - 'Inven' => false, - 'Team' => false, - 'Booking' => false, - 'Reservation' => false, - 'State' => false, - 'Division' => false, - 'Contact' => false, - 'Entrance' => false, - 'Section' => false, - 'Performance' => false, - 'Ticket' => false, - 'TicketInventory' => false, - 'Interface' => $this->userInterface, - 'Search' => false, - 'Cart' => false, - 'CartIndex' => 0, - 'OptServCart' => false, - 'TicketCart' => false, - 'ContactInput' => false, - 'TicketPayments' => false, - 'AdminUser' => false - ); - - // Initialze Cart - $this->clearCart(); - - $this->addDebug("startSession()", 'Session Reset', false); - - } - - // Reset session timeout to current time plus timeout length in minutes - $_SESSION[GLM_EVENT_SESSION]['timeOut'] = strtotime('now +'.$this->config->session_timeout.' minutes'); - - // Now let's check for an admin login user who might have more privileges than a normal front-end user - if (isset($_REQUEST['adminUserCheck']) && $_REQUEST['adminUserCheck'] != '') { - -/* Temporarily bypassed due to issues with office computer Check Failures. - // Check admin user ID and check string - $check = md5($this->config->orderVerificationSecret.$_SERVER['REMOTE_ADDR'].date('m/d/Y')); - if ($_REQUEST['adminUserCheck'] != $check) { - echo "Check failure:"; - exit; - } -*/ - - $_SESSION[GLM_EVENT_SESSION]['AdminUser'] = true; - } - - $this->addDebug('startSession()', 'Session timeout at: '.date('r', $_SESSION[GLM_EVENT_SESSION]['timeOut']).' ('.$_SESSION[GLM_EVENT_SESSION]['timeOut'].')'); - - - } - - /** - * User Interface selection (template dir) - * - * @return void - */ - private function userInterfaceSelection() - { - - // Is there a request for a specific interface - if (isset($_REQUEST['interface']) && - in_array($_REQUEST['interface'], $this->config->front_interface->toArray()) - ) { - $this->userInterface = $_REQUEST['interface']; - // Oherwise, do we have an interface selection in the user session? - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Interface']) && $_SESSION[GLM_EVENT_SESSION]['Interface'] != '') { - $this->userInterface = $_SESSION[GLM_EVENT_SESSION]['Interface']; - // If neither, then use default user interface. - } else { - $this->userInterface = $this->config->default_front_interface; - } - - // Update session with current user interface - $_SESSION[GLM_EVENT_SESSION]['Interface'] = $this->userInterface; - - // Get interface type (flexy or smarty) - $this->interfaceType = $this->config->front_interface_type->{$this->userInterface}; - - // Provide list of user interfaces to page - $interfaces = $this->config->front_interface->toArray(); - $userInterfaces = array(); - foreach ($interfaces as $i) { - $userInterfaces[] = array( - 'directory' => $i, - 'name' => $i, - 'selected' => ($i == $interface) - ); - } - - // If there's more than 1 user interface then tell the template to display user interface selection - $this->userInterfacesSelectable = ($this->config->front_interface->selectable && count($interfaces) > 1); - $this->userInterfaces = $this->bindArrayToObject($userInterfaces); - - $this->addDebug("userInterfaceSelection()", $this->userInterface.' (template engine: '.$this->interfaceType.')', false); - - } - - /** - * Set template configuration - * - * @return void - */ - private function setupTemplate() - { - - // Test if there is a local templates directory for the Web site - if (is_dir(BASE_PATH.'admin/EventManagement/templates')) { - $templatesDir = BASE_PATH.'admin/EventManagement/templates/front/'; - } else { - // Otherwise use the templates in this app - $templatesDir = EVENT_MANAGEMENT_APP_BASE.'views/front/'; - } - - switch ($this->interfaceType) { - - case 'smarty': - - // Load Smarty class and create instance - require(COMMON_APP_BASE.'Smarty/3.1/Smarty.class.php'); - $this->smarty = new Smarty(); - - // Setup required Smarty paths - $this->smarty->setTemplateDir($templatesDir); - $this->smarty->setCompileDir(BASE_PATH.'/smarty/templates_c'); - $this->smarty->setCacheDir(BASE_PATH.'/smarty/cache'); - $this->smarty->setConfigDir(BASE_PATH.'/smarty/configs'); - - break; - - case 'flexy': - // Setup Template and Page - $this->flexyOptions = array( - 'templateDir' => $templatesDir, - 'compileDir' => BASE_PATH.'/templates/compiled', - 'forceCompile' => false, - 'flexyIgnore' => true, - 'allowPHP' => true, - 'debug' => false - ); - $this->template = new HTML_Template_Flexy($this->flexyOptions); - $this->page = new stdClass(); - - break; - } - - // Get misc system configuration data for use below - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/misc.php'; - $Misc = new EventManagementAdminMisc($this->dbh, $this->config); - $miscConfigDetail = $Misc->getEntry(1); - - // Get some standard page data - $this->templateAssign( - array( - - 'owner' => $this->bindArrayToObject($this->config->owner->toArray()), - - 'startScript' => ' - '; - - } - - } - - /* - * Assign parameters to the template - * - * @param array Array of arrays with parameter name, value pairs - * or - * @param text parameter name - * @param {whatever} parameter value - * - * @return void - */ - private function templateAssign($params, $value = false) - { - - // If this is a single assignment - if ($value != false) { - - switch ($this->interfaceType) { - case 'smarty': - $this->smarty->assign($param, $value); - break; - case 'flexy': - $this->page->{$params} = $value; - break; - } - - // Otherwise it's an array of parameter/value pairs - } else { - - while (list($key, $value) = each($params)) { - - switch ($this->interfaceType) { - case 'smarty': - $this->smarty->assign($key, $value); - break; - case 'flexy': - $this->page->{$key} = $value; - break; - } - - } - - } - - } - - /** - * If debug for mail turned on, display E-Mail messages rather than send them - * - * @access public - */ - public function debug_mail( $to, $subject, $message, $headers = '', $parameters = '' ) - { - if( $this->config->debug->mail ) - { - $mailDebug = '

- - - - - - - -
MAIL DEBUG
Recipient(s): '.$to.'
Subject: '.$subject.'
Headers:
'.$headers.'
Parameters:
'.$parameters.'
Message Content:
'.$message.'
-

- '; - - // If front-debug is enabled, display in debug window - if ($this->config->option->front_debug) { - $this->addDebug('Email Message', $subject, $mailDebug, true); - } else { - // Otherwise display in-line. - echo $mailDebug; - } - - return( true ); - } else { - return( mail( $to, $subject, $message, $headers, $parameters ) ); - } - } - - - - -} // EventManagementIndexController - -// Start Event Management Front-End - Pass the site's global application config data -//$eh = new EventManagementIndexController($applicationConfig, $serverConfig); -//exit; - -?> diff --git a/legacy/data/DatabaseModificationsForTicketing.sql b/legacy/data/DatabaseModificationsForTicketing.sql deleted file mode 100644 index ef23f25..0000000 --- a/legacy/data/DatabaseModificationsForTicketing.sql +++ /dev/null @@ -1,39 +0,0 @@ -alter table eventmgt.ticket add column show_on_start boolean; -update eventmgt.ticket set show_on_start = true; - - - - - - - - - - - - - -alter table eventmgt.res_member rename to member; -alter table eventmgt.member add column descr text; -alter table eventmgt.member add column lat float; -alter table eventmgt.member add column lon float; -alter table eventmgt.member add column addr1 text; -alter table eventmgt.member add column addr2 text; -alter table eventmgt.member add column city text; -alter table eventmgt.member add column state text; -alter table eventmgt.member add column zip text; -alter table eventmgt.member add column country text; -alter table eventmgt.member add column cards_accepted int; -alter table eventmgt.member add column payment_gateway int; -alter table eventmgt.member add column image text; -alter table eventmgt.member add column ticket_sec_map text; -alter table eventmgt.member add column ticket_spec_req boolean; -alter table eventmgt.member add column ticket_policy text; - -alter table eventmgt.event add column parking_image text; -alter table eventmgt.event add column parking_descr text; - -alter table eventmgt.accommodation add column accom_type smallint; -alter table eventmgt.accommodation add column section smallint; - -Add eventmgt.ticket table \ No newline at end of file diff --git a/legacy/data/EventManagement.sql b/legacy/data/EventManagement.sql deleted file mode 100644 index 6e11f39..0000000 --- a/legacy/data/EventManagement.sql +++ /dev/null @@ -1,1182 +0,0 @@ -CREATE SCHEMA eventmgt; - -ALTER SCHEMA eventmgt OWNER TO postgres; -GRANT ALL ON SCHEMA eventmgt TO nobody; - -CREATE TABLE eventmgt.misc -( - id integer, - intro_text text, - section_text text, - ticket_text text, - ticket_opt_text text, - cart_text text, - checkout_text text, - success_text text, - tracking text, - opt_field_1_name text, - opt_field_2_name text, - opt_field_3_name text, - central_payment smallint -); - -ALTER TABLE eventmgt.misc OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.misc FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.misc FROM postgres; -GRANT ALL ON TABLE eventmgt.misc TO postgres; -GRANT ALL ON TABLE eventmgt.misc TO nobody; - -INSERT INTO eventmgt.misc - (id, intro_text, section_text, ticket_text, ticket_opt_text, cart_text, checkout_text, success_text, central_payment) - VALUES - (1, 'Intro text', 'Section selection text', 'Ticket selection text', 'Ticket option selection text', 'Cart text', 'Checkout text', 'Checkout success text', 0); - - -CREATE TABLE eventmgt.fees -( -id SERIAL, -affiliation_type smallint, -owner smallint, -fee_method smallint, -room_specific bool, -name text, -fee_amount float, -taxable bool, -itemize bool, -event_specific bool, -event smallint, -optional_service bool, -service_quant bool, -service_max_quant smallint, -descr text -); - -ALTER TABLE eventmgt.fees OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.fees FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.fees FROM postgres; -GRANT ALL ON TABLE eventmgt.fees TO postgres; -GRANT ALL ON TABLE eventmgt.fees TO nobody; -GRANT ALL ON TABLE eventmgt.fees_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.fees_id_seq TO nobody; - -CREATE INDEX fees_id_index ON eventmgt.fees ( id ); -CREATE INDEX fees_owner_index ON eventmgt.fees ( owner ); - -CREATE TABLE eventmgt.division - ( - id SERIAL, - event integer, - name text, - descr text, - notes text - ); - -ALTER TABLE eventmgt.division OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.division FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.division FROM postgres; -GRANT ALL ON TABLE eventmgt.division TO postgres; -GRANT ALL ON TABLE eventmgt.division TO nobody; -GRANT ALL ON TABLE eventmgt.division_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.division_id_seq TO nobody; - -CREATE INDEX division_id_index ON eventmgt.division ( id ); -CREATE INDEX division_event_index ON eventmgt.division ( event ); - -CREATE TABLE eventmgt.state_rep - ( - id SERIAL, - event integer, - code text, - password text, - descr text, - notes text - ); - -ALTER TABLE eventmgt.state_rep OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.state_rep FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.state_rep FROM postgres; -GRANT ALL ON TABLE eventmgt.state_rep TO postgres; -GRANT ALL ON TABLE eventmgt.state_rep TO nobody; -GRANT ALL ON TABLE eventmgt.state_rep_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.state_rep_id_seq TO nobody; - -CREATE INDEX state_rep_id_index ON eventmgt.state_rep ( id ); -CREATE INDEX state_rep_event_index ON eventmgt.state_rep ( event ); - - -CREATE TABLE eventmgt.room_block - ( - id SERIAL, - event integer, - state_rep integer, - team integer, - member integer, - block_name integer - ); - -ALTER TABLE eventmgt.room_block OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.room_block FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.room_block FROM postgres; -GRANT ALL ON TABLE eventmgt.room_block TO postgres; -GRANT ALL ON TABLE eventmgt.room_block TO nobody; -GRANT ALL ON TABLE eventmgt.room_block_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.room_block_id_seq TO nobody; - -CREATE INDEX room_block_id_index ON eventmgt.room_block ( id ); -CREATE INDEX room_block_event_index ON eventmgt.room_block ( event ); -CREATE INDEX room_block_state_rep_index ON eventmgt.room_block ( state_rep ); -CREATE INDEX room_block_team_index ON eventmgt.room_block ( team ); -CREATE INDEX room_block_member_index ON eventmgt.room_block ( member ); - - -CREATE TABLE eventmgt.room_block_seg - ( - id SERIAL, - block integer, - event integer, - accommodation integer, - allocated smallint, - available smallint - ); - -ALTER TABLE eventmgt.room_block_seg OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.room_block_seg FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.room_block_seg FROM postgres; -GRANT ALL ON TABLE eventmgt.room_block_seg TO postgres; -GRANT ALL ON TABLE eventmgt.room_block_seg TO nobody; -GRANT ALL ON TABLE eventmgt.room_block_seg_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.room_block_seg_id_seq TO nobody; - -CREATE INDEX room_block_seg_id_index ON eventmgt.room_block_seg ( id ); -CREATE INDEX room_block_seg_block_index ON eventmgt.room_block_seg ( block ); -CREATE INDEX room_block_seg_event_index ON eventmgt.room_block_seg ( event ); -CREATE INDEX room_block_seg_accommodation_index ON eventmgt.room_block_seg ( accommodation ); - - -CREATE TABLE eventmgt.team - ( - id SERIAL, - event integer, - division integer, - state integer, - name text, - team_code text, - participants smallint, - room_block integer, - notes text - ); - -ALTER TABLE eventmgt.team OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.team FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.team FROM postgres; -GRANT ALL ON TABLE eventmgt.team TO postgres; -GRANT ALL ON TABLE eventmgt.team TO nobody; -GRANT ALL ON TABLE eventmgt.team_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.team_id_seq TO nobody; - -CREATE INDEX team_id_index ON eventmgt.team ( id ); -CREATE INDEX team_code_index ON eventmgt.team ( team_code ); -CREATE INDEX team_event_index ON eventmgt.team ( event ); - - -CREATE TABLE eventmgt.team_roster - ( - id SERIAL, - team integer, - lname text, - fname text, - pos text, - notes text - ); - -ALTER TABLE eventmgt.team_roster OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.team_roster FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.team_roster FROM postgres; -GRANT ALL ON TABLE eventmgt.team_roster TO postgres; -GRANT ALL ON TABLE eventmgt.team_roster TO nobody; -GRANT ALL ON TABLE eventmgt.team_roster_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.team_roster_id_seq TO nobody; - -CREATE INDEX team_roster_id_index ON eventmgt.team_roster ( id ); -CREATE INDEX team_roster_team_index ON eventmgt.team_roster ( team ); - - - -CREATE TABLE eventmgt.team_property - ( - id SERIAL, - team integer, - property integer, - event integer, - start date, - stop date - ); - -ALTER TABLE eventmgt.team_property OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.team_property FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.team_property FROM postgres; -GRANT ALL ON TABLE eventmgt.team_property TO postgres; -GRANT ALL ON TABLE eventmgt.team_property TO nobody; -GRANT ALL ON TABLE eventmgt.team_property_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.team_property_id_seq TO nobody; - -CREATE INDEX team_property_id_index ON eventmgt.team_property ( id ); -CREATE INDEX team_property_team_id_index ON eventmgt.team_property ( team ); -CREATE INDEX team_property_property_id_index ON eventmgt.team_property ( property ); -CREATE INDEX team_property_event_id_index ON eventmgt.team_property ( event ); - - -CREATE TABLE eventmgt.accommodation - ( - id SERIAL, - member integer, - name text, - title text, - category smallint, - descr text, - image text, - quant integer, - occupants smallint, - maxoccupants smallint, - sort smallint - ); - -ALTER TABLE eventmgt.accommodation OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.accommodation FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.accommodation FROM postgres; -GRANT ALL ON TABLE eventmgt.accommodation TO postgres; -GRANT ALL ON TABLE eventmgt.accommodation TO nobody; -GRANT ALL ON TABLE eventmgt.accommodation_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.accommodation_id_seq TO nobody; - -CREATE INDEX accommodation_id_index ON eventmgt.accommodation (id); -CREATE INDEX accommodation_member_index ON eventmgt.accommodation (member); - -CREATE TABLE eventmgt.entrance - ( - id SERIAL, - member integer, - name text, - addr1 text, - addr2 text, - city text, - state text, - country text, - zip text, - phone text, - lat float, - lon float, - descr text, - image text, - color text, - notes text, - sort smallint - ); - -ALTER TABLE eventmgt.entrance OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.entrance FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.entrance FROM postgres; -GRANT ALL ON TABLE eventmgt.entrance TO postgres; -GRANT ALL ON TABLE eventmgt.entrance TO nobody; -GRANT ALL ON TABLE eventmgt.entrance_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.entrance_id_seq TO nobody; - -CREATE INDEX entrance_id_index ON eventmgt.entrance (id); -CREATE INDEX entrance_member_index ON eventmgt.entrance (member); -CREATE INDEX entrance_sort_index ON eventmgt.entrance (sort); - -CREATE TABLE eventmgt.section - ( - id SERIAL, - member integer, - name text, - descr text, - image text, - entrance integer, - notes text, - sort smallint - ); - -ALTER TABLE eventmgt.section OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.section FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.section FROM postgres; -GRANT ALL ON TABLE eventmgt.section TO postgres; -GRANT ALL ON TABLE eventmgt.section TO nobody; -GRANT ALL ON TABLE eventmgt.section_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.section_id_seq TO nobody; - -CREATE INDEX section_id_index ON eventmgt.section (id); -CREATE INDEX section_member_index ON eventmgt.section (member); -CREATE INDEX section_sort_index ON eventmgt.section (sort); - -CREATE TABLE eventmgt.performance - ( - id SERIAL, - member smallint, - name text, - active boolean, - admin_only boolean, - descr text, - short_descr text, - start_date date, - end_date date, - purch_leadtime smallint, - image text, - policy text, - voucher_text text, - conf_text text, - notes text, - promote_in_cart boolean, - sort smallint - ); - -ALTER TABLE eventmgt.performance OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.performance FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.performance FROM postgres; -GRANT ALL ON TABLE eventmgt.performance TO postgres; -GRANT ALL ON TABLE eventmgt.performance TO nobody; -GRANT ALL ON TABLE eventmgt.performance_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.performance_id_seq TO nobody; - -CREATE INDEX performance_id_index ON eventmgt.performance (id); -CREATE INDEX performance_member_index ON eventmgt.performance (member); -CREATE INDEX performance_sort_index ON eventmgt.performance (sort); - -CREATE TABLE eventmgt.ticket - ( - id SERIAL, - active boolean, - admin_only boolean, - ticket_type integer, - member integer, - name text, - title text, - section smallint, - date_specific boolean, - days_of_week integer, - start_date date, - end_date date, - time_specific boolean, - ticket_time time, - unlimited_use boolean, - uses smallint, - performance smallint, - unlimited_quant boolean, - quant integer, - consignment_type smallint, - cart_sticky boolean, - show_on_start boolean, - price float, - descr text, - image text, - voucher_text text, - voucher_type integer, - sort smallint - ); - -ALTER TABLE eventmgt.ticket OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket TO postgres; -GRANT ALL ON TABLE eventmgt.ticket TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_id_seq TO nobody; - -CREATE INDEX ticket_id_index ON eventmgt.ticket (id); -CREATE INDEX ticket_member_index ON eventmgt.ticket (member); -CREATE INDEX ticket_section_index ON eventmgt.ticket (section); - -CREATE TABLE eventmgt.ticket_package - ( - id SERIAL, - package integer, - ticket integer, - member integer, - performance integer, - quant integer, - sort smallint - ); - -ALTER TABLE eventmgt.ticket_package OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_package FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_package FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_package TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_package TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_package_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_package_id_seq TO nobody; - -CREATE INDEX ticket_package_id_index ON eventmgt.ticket_package (id); -CREATE INDEX ticket_package_package_index ON eventmgt.ticket_package (package); -CREATE INDEX ticket_package_ticket_index ON eventmgt.ticket_package (ticket); - -CREATE TABLE eventmgt.member_scans_for - ( - id SERIAL, - member integer, - scans_for integer - ); - -ALTER TABLE eventmgt.member_scans_for OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.member_scans_for FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.member_scans_for FROM postgres; -GRANT ALL ON TABLE eventmgt.member_scans_for TO postgres; -GRANT ALL ON TABLE eventmgt.member_scans_for TO nobody; -GRANT ALL ON TABLE eventmgt.member_scans_for_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.member_scans_for_id_seq TO nobody; - -CREATE INDEX member_scans_for_id_index ON eventmgt.member_scans_for (id); -CREATE INDEX member_scans_for_member_index ON eventmgt.member_scans_for (member); -CREATE INDEX member_scans_for_scans_for_index ON eventmgt.member_scans_for (scans_for); - - -CREATE TABLE eventmgt.ticket_inventory - ( - id SERIAL, - ticket integer, - member integer, - quant integer, - available integer, - sold integer, - ticket_date date, - ticket_time time, - active boolean - ); - -ALTER TABLE eventmgt.ticket_inventory OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_inventory FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_inventory FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_inventory TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_inventory TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_inventory_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_inventory_id_seq TO nobody; - -CREATE INDEX ticket_inventory_id_index ON eventmgt.ticket_inventory (id); -CREATE INDEX ticket_inventory_ticket_index ON eventmgt.ticket_inventory (ticket); -CREATE INDEX ticket_inventory_member_index ON eventmgt.ticket_inventory (member); -CREATE INDEX ticket_inventory_date_index ON eventmgt.ticket_inventory (ticket_date); - -CREATE TABLE eventmgt.ticket_add_on - ( - id SERIAL, - ticket integer, - name text, - descr text, - add_on_type integer, - max_quant integer, - unit_name text, - unit_cost float - ); - -ALTER TABLE eventmgt.ticket_add_on OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_add_on FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_add_on FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_add_on TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_add_on TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_add_on_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_add_on_id_seq TO nobody; - -CREATE INDEX ticket_add_on_id_index ON eventmgt.ticket_add_on (id); -CREATE INDEX ticket_add_on_ticket_index ON eventmgt.ticket_add_on (ticket); - -CREATE TABLE eventmgt.promo_code - ( - id SERIAL, - name text, - long_name text, - descr text, - start_date date, - end_date date, - notes text - ); - -ALTER TABLE eventmgt.promo_code OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.promo_code FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.promo_code FROM postgres; -GRANT ALL ON TABLE eventmgt.promo_code TO postgres; -GRANT ALL ON TABLE eventmgt.promo_code TO nobody; -GRANT ALL ON TABLE eventmgt.promo_code_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.promo_code_id_seq TO nobody; - -CREATE INDEX promo_code_id_index ON eventmgt.promo_code (id); -CREATE INDEX promo_code_start_date_index ON eventmgt.promo_code (start_date); -CREATE INDEX promo_code_end_date_index ON eventmgt.promo_code (end_date); - -CREATE TABLE eventmgt.promo_ticket - ( - id SERIAL, - promo integer, - ticket integer, - promo_type integer, - amount float, - notes text - ); - -ALTER TABLE eventmgt.promo_ticket OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.promo_ticket FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.promo_ticket FROM postgres; -GRANT ALL ON TABLE eventmgt.promo_ticket TO postgres; -GRANT ALL ON TABLE eventmgt.promo_ticket TO nobody; -GRANT ALL ON TABLE eventmgt.promo_ticket_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.promo_ticket_id_seq TO nobody; - -CREATE INDEX promo_ticket_id_index ON eventmgt.promo_ticket (id); -CREATE INDEX promo_ticket_ticket_index ON eventmgt.promo_ticket (ticket); - -CREATE TABLE eventmgt.room_detail - ( - id SERIAL, - member integer, - accommodation integer, - occupants smallint, - room_type smallint, - bath_type smallint, - pullout_beds smallint, - single_beds smallint, - double_beds smallint, - queen_beds smallint, - king_beds smallint, - tv bool, - fridge bool, - safe bool, - descr text, - image text, - sort smallint - ); - -ALTER TABLE eventmgt.room_detail OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.room_detail FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.room_detail FROM postgres; -GRANT ALL ON TABLE eventmgt.room_detail TO postgres; -GRANT ALL ON TABLE eventmgt.room_detail TO nobody; -GRANT ALL ON TABLE eventmgt.room_detail_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.room_detail_id_seq TO nobody; - -CREATE INDEX room_detail_id_index ON eventmgt.room_detail (id); -CREATE INDEX room_detail_member_index ON eventmgt.room_detail (member); -CREATE INDEX room_detail_accom_index ON eventmgt.room_detail (accommodation); - - -CREATE TABLE eventmgt.res_contact - ( - id SERIAL, - contact_type int, - affiliation int, - fname text, - lname text, - org text, - addr1 text, - addr2 text, - city text, - state text, - country text, - zip text, - org_url text, - office_phone text, - mobile_phone text, - alt_phone text, - fax text, - email text, - login_id text, - alt_email text, - image text, - notes text, - create_date date, - active bool, - password text, - user_rights int - ); - -ALTER TABLE eventmgt.res_contact OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.res_contact FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.res_contact FROM postgres; -GRANT ALL ON TABLE eventmgt.res_contact TO postgres; -GRANT ALL ON TABLE eventmgt.res_contact TO nobody; -GRANT ALL ON TABLE eventmgt.res_contact_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.res_contact_id_seq TO nobody; - -CREATE INDEX res_contact_id_index ON eventmgt.res_contact (id); -CREATE INDEX res_contact_affiliation_index ON eventmgt.res_contact (affiliation); -CREATE INDEX res_contact_city_index ON eventmgt.res_contact (city); -CREATE INDEX res_contact_email_index ON eventmgt.res_contact (email); -CREATE INDEX res_contact_fname_index ON eventmgt.res_contact (fname); -CREATE INDEX res_contact_lname_index ON eventmgt.res_contact (lname); -CREATE INDEX res_contact_zip_index ON eventmgt.res_contact (zip); -CREATE INDEX res_contact_login_id_index ON eventmgt.res_contact (login_id); - - -CREATE TABLE eventmgt.event - ( - id SERIAL, - name text, - event_code text, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - descr text, - event_dates text, - active bool, - image text, - team_event bool, - days smallint, - start_date date, - end_date date, - cutoff_date date, - req_stay bool, - req_stay_arrive date, - req_stay_depart date, - req_stay_notice text, - open_res_date date, - conf_hours integer, - inven_hold_time integer, - sort smallint, - lat float, - lon float, - multiple_rooms bool, - max_rooms smallint, - cart_text text, - res_policy text, - can_policy text, - pmt_policy text, - res_msg text, - conf_msg text, - reserve_by_code bool, - central_payment bool, - central_payment_email text, - host_property smallint, - parking_image text, - parking_descr text - ); - -ALTER TABLE eventmgt.event OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.event FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.event FROM postgres; -GRANT ALL ON TABLE eventmgt.event TO postgres; -GRANT ALL ON TABLE eventmgt.event TO nobody; -GRANT ALL ON TABLE eventmgt.event_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.event_id_seq TO nobody; - -CREATE INDEX event_id_index ON eventmgt.event ( id ); -CREATE INDEX event_sort_index ON eventmgt.event ( sort ); - - -CREATE TABLE eventmgt.event_prop_dist - ( - id SERIAL, - event integer, - event_lat float, - event_lon float, - member integer, - memb_lat float, - memb_lon float, - summary text, - start_addr text, - end_addr text, - distance text, - duration text - ); - -ALTER TABLE eventmgt.event_prop_dist OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.event_prop_dist FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.event_prop_dist FROM postgres; -GRANT ALL ON TABLE eventmgt.event_prop_dist TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop_dist TO nobody; -GRANT ALL ON TABLE eventmgt.event_prop_dist_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop_dist_id_seq TO nobody; - -CREATE INDEX event_prop_event_index ON eventmgt.event_prop_dist (event); -CREATE INDEX event_prop_member_index ON eventmgt.event_prop_dist (member); - - -CREATE TABLE eventmgt.inventory - ( - id SERIAL, - date date, - member integer, - accommodation integer, - event integer, - assigned smallint, - available smallint, - rate float, - add_person float, - room_block text, - res_policy text, - can_policy text, - min_nights integer, - descr text - ); - -ALTER TABLE eventmgt.inventory OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.inventory FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.inventory FROM postgres; -GRANT ALL ON TABLE eventmgt.inventory TO postgres; -GRANT ALL ON TABLE eventmgt.inventory TO nobody; -GRANT ALL ON TABLE eventmgt.inventory_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.inventory_id_seq TO nobody; - -CREATE INDEX inventory_id_index ON eventmgt.inventory ( id ); -CREATE INDEX inventory_date_index ON eventmgt.inventory ( date ); -CREATE INDEX inventory_member_index ON eventmgt.inventory ( member ); -CREATE INDEX inventory_accom_index ON eventmgt.inventory ( accommodation ); - - -CREATE TABLE eventmgt.inven_hold - ( - id SERIAL, - hold_type integer, - inventory integer, - quant integer, - expire_time timestamp, - session_id text - ); - -ALTER TABLE eventmgt.inven_hold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.inven_hold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.inven_hold FROM postgres; -GRANT ALL ON TABLE eventmgt.inven_hold TO postgres; -GRANT ALL ON TABLE eventmgt.inven_hold TO nobody; -GRANT ALL ON TABLE eventmgt.inven_hold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.inven_hold_id_seq TO nobody; - -CREATE INDEX inven_hold_inventory_index ON eventmgt.inven_hold (inventory); -CREATE INDEX inven_hold_session_id_index ON eventmgt.inven_hold (session_id); - - -CREATE TABLE eventmgt.member - ( - id SERIAL, - member_type smallint, - name text, - descr text, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - lat float, - lon float, - active boolean, - cards_accepted smallint, - payment_gateway smallint, - gateway_par1 text, - gateway_par2 text, - gateway_par3 text, - gateway_par4 boolean, - gateway_par5 text, - paypal boolean, - paypal_client_id text, - paypal_secret text, - paypal_mode smallint, - image text, - parking_map text, - ticket_sec_map text, - ticket_spec_req boolean, - ticket_policy text, - intro_text text, - checkout_email text, - phone text, - email text, - proc_email text, - proc_email2 text, - checkout_notify boolean, - check_in time, - check_out time, - def_res_pol text, - def_can_pol text, - notes text, - amen_1 boolean, - amen_2 boolean, - amen_3 boolean, - amen_4 boolean, - amen_5 boolean, - amen_6 boolean, - amen_7 boolean, - amen_8 boolean, - amen_9 boolean, - amen_10 boolean, - def_ticket_pol text, - sort integer, - checkout_opt_1 text, - checkout_opt_2 text, - checkout_opt_3 text - ); - -ALTER TABLE eventmgt.member OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.member FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.member FROM postgres; -GRANT ALL ON TABLE eventmgt.member TO postgres; -GRANT ALL ON TABLE eventmgt.member TO nobody; -GRANT ALL ON TABLE eventmgt.member_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.member_id_seq TO nobody; - -CREATE INDEX member_id_index ON eventmgt.member ( id ); - -CREATE TABLE eventmgt.amenities - ( - id SERIAL, - affiliation_type smallint, - owner smallint, - name text, - quant int, - descr text - ); - -ALTER TABLE eventmgt.amenities OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.amenities FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.amenities FROM postgres; -GRANT ALL ON TABLE eventmgt.amenities TO postgres; -GRANT ALL ON TABLE eventmgt.amenities TO nobody; -GRANT ALL ON TABLE eventmgt.amenities_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.amenities_id_seq TO nobody; - -CREATE INDEX amenities_id_index ON eventmgt.amenities ( id ); -CREATE INDEX amenities_owner_index ON eventmgt.amenities ( owner ); - - -CREATE TABLE eventmgt.event_prop - ( - id SERIAL, - event integer, - property integer - ); - -ALTER TABLE eventmgt.event_prop OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.event_prop FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.event_prop FROM postgres; -GRANT ALL ON TABLE eventmgt.event_prop TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop TO nobody; -GRANT ALL ON TABLE eventmgt.event_prop_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop_id_seq TO nobody; - -CREATE INDEX event_prop_event_id_index ON eventmgt.event_prop ( event ); -CREATE INDEX event_prop_property_id_index ON eventmgt.event_prop ( property ); - -CREATE TABLE eventmgt.reservation - ( - id SERIAL, - user_trace_info text, - fname text, - lname text, - org text, - team_id smallint, - state_rep smallint, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - phone text, - email text, - email_ok bool, - date_entered date, - arrive_date date, - nights smallint, - rooms smallint, - adults smallint, - team smallint, - member integer, - accommodation int, - room_block integer, - arrival text, - event smallint, - event_name text, - event_start date, - event_end date, - payby smallint, - cctype text, - ccnumber text, - expire text, - ccname text, - cccode text, - hotel_price float, - taxes float, - grand_total float, - confirmation smallint, - confirmed bool, - declined bool, - conf_numb text, - date_confirmed date, - conf_by text, - conf_message text, - special_needs text, - notes text, - res_detail text, - summary text - ); - -ALTER TABLE eventmgt.reservation OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.reservation FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.reservation FROM postgres; -GRANT ALL ON TABLE eventmgt.reservation TO postgres; -GRANT ALL ON TABLE eventmgt.reservation TO nobody; -GRANT ALL ON TABLE eventmgt.reservation_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.reservation_id_seq TO nobody; - -CREATE INDEX reservation_id_index ON eventmgt.reservation ( id ); -CREATE INDEX reservation_lname_index ON eventmgt.reservation ( lname ); -CREATE INDEX reservation_fname_index ON eventmgt.reservation ( fname ); -CREATE INDEX reservation_email_index ON eventmgt.reservation ( email ); -CREATE INDEX reservation_arrive_index ON eventmgt.reservation ( arrive_date ); - - -CREATE TABLE eventmgt.ticket_order - ( - id SERIAL, - user_trace_info text, - active boolean, - fname text, - lname text, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - phone text, - email text, - email_ok bool, - opt_field_1_name text, - opt_field_1 text, - opt_field_2_name text, - opt_field_2 text, - opt_field_3_name text, - opt_field_3 text, - purchase_date date, - member integer, - cctype text, - ccnumber text, - expire text, - ccname text, - ccconf text, - charge_total float, - special_needs text, - notes text, - session_id text - ); - -ALTER TABLE eventmgt.ticket_order OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_order FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_order FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_order TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_order TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_order_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_order_id_seq TO nobody; - -CREATE INDEX ticket_order_id_index ON eventmgt.ticket_order ( id ); -CREATE INDEX ticket_order_lname_index ON eventmgt.ticket_order ( lname ); -CREATE INDEX ticket_order_fname_index ON eventmgt.ticket_order ( fname ); -CREATE INDEX ticket_order_email_index ON eventmgt.ticket_order ( email ); -CREATE INDEX ticket_order_purchase_date_index ON eventmgt.ticket_order ( purchase_date ); -CREATE INDEX ticket_order_member_index ON eventmgt.ticket_order ( member ); -CREATE INDEX ticket_order_session_id_index ON eventmgt.ticket_order ( session_id ); - - -CREATE TABLE eventmgt.ticket_sold - ( - id SERIAL, - ticket_order integer, - member integer, - member_name text, - assigned boolean, - assigned_from integer, - assigned_from_name text, - performance smallint, - performance_name text, - entrance smallint, - entrance_name text, - entrance_color text, - section smallint, - section_name text, - ticket integer, - ticket_name text, - is_package boolean, - package_sold_id text, - ticket_package integer, - package_name text, - date_specific boolean, - ticket_date date, - time_specific boolean, - ticket_time time, - start_date date, - end_date date, - likely_date date, - price_paid float, - policies text, - unlimited_use boolean, - numb_uses smallint, - numb_claimed smallint, - time_claimed timestamp, - voucher_type smallint, - voucher_text text, - session_id text - ); - -ALTER TABLE eventmgt.ticket_sold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_sold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_sold FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_sold TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_sold TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_sold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_sold_id_seq TO nobody; - -CREATE INDEX ticket_sold_id_index ON eventmgt.ticket_sold ( id ); -CREATE INDEX ticket_sold_ticket_order_index ON eventmgt.ticket_sold ( ticket_order ); -CREATE INDEX ticket_sold_member_index ON eventmgt.ticket_sold ( member ); -CREATE INDEX ticket_sold_assigned_from_index ON eventmgt.ticket_sold ( assigned_from ); -CREATE INDEX ticket_sold_performance_index ON eventmgt.ticket_sold ( performance ); -CREATE INDEX ticket_sold_ticket_index ON eventmgt.ticket_sold ( ticket ); -CREATE INDEX ticket_sold_ticket_date_index ON eventmgt.ticket_sold ( ticket_date ); -CREATE INDEX ticket_sold_likely_date_index ON eventmgt.ticket_sold ( likely_date ); -CREATE INDEX ticket_sold_time_claimed_index ON eventmgt.ticket_sold ( time_claimed ); -CREATE INDEX ticket_sold_session_id_index ON eventmgt.ticket_sold ( session_id ); -CREATE INDEX ticket_sold_package_sold_id_index ON eventmgt.ticket_sold ( package_sold_id ); -CREATE INDEX ticket_sold_ticket_package_index ON eventmgt.ticket_sold ( ticket_package ); - -CREATE TABLE eventmgt.add_on_sold - ( - id SERIAL, - ticket_order integer, - ticket_sold integer, - add_on_name text, - add_on_type integer, - add_on_type_name text, - unit_name text, - unit_price float, - quant integer, - price_paid float, - session_id text - ); - -ALTER TABLE eventmgt.add_on_sold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.add_on_sold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.add_on_sold FROM postgres; -GRANT ALL ON TABLE eventmgt.add_on_sold TO postgres; -GRANT ALL ON TABLE eventmgt.add_on_sold TO nobody; -GRANT ALL ON TABLE eventmgt.add_on_sold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.add_on_sold_id_seq TO nobody; - -CREATE INDEX add_on_sold_id_index ON eventmgt.add_on_sold ( id ); -CREATE INDEX add_on_sold_ticket_order_index ON eventmgt.add_on_sold ( ticket_order ); -CREATE INDEX add_on_sold_ticket_sold_index ON eventmgt.add_on_sold ( ticket_sold ); -CREATE INDEX add_on_sold_session_id_index ON eventmgt.add_on_sold ( session_id ); - -CREATE TABLE eventmgt.promo_sold - ( - id SERIAL, - ticket_order integer, - ticket_sold integer, - promo integer, - promo_name text, - promo_type integer, - promo_type_name text, - amount float, - session_id text - ); - -ALTER TABLE eventmgt.promo_sold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.promo_sold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.promo_sold FROM postgres; -GRANT ALL ON TABLE eventmgt.promo_sold TO postgres; -GRANT ALL ON TABLE eventmgt.promo_sold TO nobody; -GRANT ALL ON TABLE eventmgt.promo_sold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.promo_sold_id_seq TO nobody; - -CREATE INDEX promo_sold_id_index ON eventmgt.promo_sold ( id ); -CREATE INDEX promo_sold_ticket_order_index ON eventmgt.promo_sold ( ticket_order ); -CREATE INDEX promo_sold_ticket_sold_index ON eventmgt.promo_sold ( ticket_sold ); -CREATE INDEX promo_sold_promo_index ON eventmgt.promo_sold ( promo ); -CREATE INDEX promo_sold_session_id_index ON eventmgt.promo_sold ( session_id ); - - -CREATE TABLE eventmgt.ticket_claim_tracking - ( - id SERIAL, - ticket_order integer, - ticket_sold integer, - time_of_action timestamp, - action_type smallint, - quant smallint, - scan_user integer, - scan_name text, - attendance smallint, - attendee_name text, - attendee_notes text - ); - -ALTER TABLE eventmgt.ticket_claim_tracking OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_claim_tracking FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_claim_tracking FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking_id_seq TO nobody; - -CREATE INDEX ticket_claim_tracking_id_index ON eventmgt.ticket_claim_tracking ( id ); -CREATE INDEX ticket_claim_tracking_order_index ON eventmgt.ticket_claim_tracking ( ticket_order ); -CREATE INDEX ticket_claim_tracking_sold_index ON eventmgt.ticket_claim_tracking ( ticket_sold ); -CREATE INDEX ticket_claim_tracking_scan_user_index ON eventmgt.ticket_claim_tracking ( scan_user ); - - -CREATE TABLE eventmgt.attendance - ( - id SERIAL, - member smallint, - name text, - notes text, - attendance_date timestamp, - entrance_start_time timestamp, - entrance_end_time timestamp, - perf_start_time timestamp, - perf_end_time timestamp - ); - -ALTER TABLE eventmgt.attendance OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.attendance FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.attendance FROM postgres; -GRANT ALL ON TABLE eventmgt.attendance TO postgres; -GRANT ALL ON TABLE eventmgt.attendance TO nobody; -GRANT ALL ON TABLE eventmgt.attendance_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.attendance_id_seq TO nobody; - -CREATE INDEX attendance_id_index ON eventmgt.attendance ( id ); -CREATE INDEX attendance_lmember_index ON eventmgt.attendance ( member ); -CREATE INDEX attendance_performance_index ON eventmgt.attendance ( performance ); -CREATE INDEX attendance_attendance_date_index ON eventmgt.attendance ( attendance_date ); -CREATE INDEX attendance_entrance_start_time_index ON eventmgt.attendance ( entrance_start_time ); -CREATE INDEX attendance_perf_start_time_index ON eventmgt.attendance ( perf_start_time ); - - -CREATE TABLE eventmgt.voucher_coupons - ( - id SERIAL, - name text, - active boolean, - display_from timestamp, - display_to timestamp, - coupon_type smallint, - coupon_image text, - coupon_position smallint, - stretch_to_fit boolean, - padding integer, - show_border boolean, - max_display_count smallint, - display_count integer, - notes text - ); - -ALTER TABLE eventmgt.voucher_coupons OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.voucher_coupons FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.voucher_coupons FROM postgres; -GRANT ALL ON TABLE eventmgt.voucher_coupons TO postgres; -GRANT ALL ON TABLE eventmgt.voucher_coupons TO nobody; -GRANT ALL ON TABLE eventmgt.voucher_coupons_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.voucher_coupons_id_seq TO nobody; - -CREATE INDEX voucher_coupons_id_index ON eventmgt.voucher_coupons ( id ); -CREATE INDEX voucher_coupons_from_index ON eventmgt.voucher_coupons ( display_from ); -CREATE INDEX voucher_coupons_to_index ON eventmgt.voucher_coupons ( display_to ); - diff --git a/legacy/data/EventManagement.sql~ b/legacy/data/EventManagement.sql~ deleted file mode 100755 index 51d6b11..0000000 --- a/legacy/data/EventManagement.sql~ +++ /dev/null @@ -1,1084 +0,0 @@ -CREATE SCHEMA eventmgt; - -ALTER SCHEMA eventmgt OWNER TO postgres; -GRANT ALL ON SCHEMA eventmgt TO nobody; - -CREATE TABLE eventmgt.misc -( - id integer, - intro_text text, - section_text text, - ticket_text text, - ticket_opt_text text, - cart_text text, - checkout_text text, - success_text text, - tracking text, - opt_field_1_name text, - opt_field_2_name text, - opt_field_3_name text -); - -ALTER TABLE eventmgt.misc OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.misc FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.misc FROM postgres; -GRANT ALL ON TABLE eventmgt.misc TO postgres; -GRANT ALL ON TABLE eventmgt.misc TO nobody; - -INSERT INTO eventmgt.misc - (id, intro_text, section_text, ticket_text, ticket_opt_text, cart_text, checkout_text, success_text) - VALUES - (1, 'Intro text', 'Section selection text', 'Ticket selection text', 'Ticket option selection text', 'Cart text', 'Checkout text', 'Checkout success text'); - - -CREATE TABLE eventmgt.fees -( -id SERIAL, -affiliation_type smallint, -owner smallint, -fee_method smallint, -room_specific bool, -name text, -fee_amount float, -taxable bool, -itemize bool, -event_specific bool, -event smallint, -optional_service bool, -service_quant bool, -service_max_quant smallint, -descr text -); - -ALTER TABLE eventmgt.fees OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.fees FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.fees FROM postgres; -GRANT ALL ON TABLE eventmgt.fees TO postgres; -GRANT ALL ON TABLE eventmgt.fees TO nobody; -GRANT ALL ON TABLE eventmgt.fees_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.fees_id_seq TO nobody; - -CREATE INDEX fees_id_index ON eventmgt.fees ( id ); -CREATE INDEX fees_owner_index ON eventmgt.fees ( owner ); - -CREATE TABLE eventmgt.division - ( - id SERIAL, - event integer, - name text, - descr text, - notes text - ); - -ALTER TABLE eventmgt.division OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.division FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.division FROM postgres; -GRANT ALL ON TABLE eventmgt.division TO postgres; -GRANT ALL ON TABLE eventmgt.division TO nobody; -GRANT ALL ON TABLE eventmgt.division_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.division_id_seq TO nobody; - -CREATE INDEX division_id_index ON eventmgt.division ( id ); -CREATE INDEX division_event_index ON eventmgt.division ( event ); - -CREATE TABLE eventmgt.state_rep - ( - id SERIAL, - event integer, - code text, - password text, - descr text, - notes text - ); - -ALTER TABLE eventmgt.state_rep OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.state_rep FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.state_rep FROM postgres; -GRANT ALL ON TABLE eventmgt.state_rep TO postgres; -GRANT ALL ON TABLE eventmgt.state_rep TO nobody; -GRANT ALL ON TABLE eventmgt.state_rep_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.state_rep_id_seq TO nobody; - -CREATE INDEX state_rep_id_index ON eventmgt.state_rep ( id ); -CREATE INDEX state_rep_event_index ON eventmgt.state_rep ( event ); - - -CREATE TABLE eventmgt.room_block - ( - id SERIAL, - event integer, - state_rep integer, - team integer, - member integer, - block_name integer - ); - -ALTER TABLE eventmgt.room_block OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.room_block FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.room_block FROM postgres; -GRANT ALL ON TABLE eventmgt.room_block TO postgres; -GRANT ALL ON TABLE eventmgt.room_block TO nobody; -GRANT ALL ON TABLE eventmgt.room_block_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.room_block_id_seq TO nobody; - -CREATE INDEX room_block_id_index ON eventmgt.room_block ( id ); -CREATE INDEX room_block_event_index ON eventmgt.room_block ( event ); -CREATE INDEX room_block_state_rep_index ON eventmgt.room_block ( state_rep ); -CREATE INDEX room_block_team_index ON eventmgt.room_block ( team ); -CREATE INDEX room_block_member_index ON eventmgt.room_block ( member ); - - -CREATE TABLE eventmgt.room_block_seg - ( - id SERIAL, - block integer, - event integer, - accommodation integer, - allocated smallint, - available smallint - ); - -ALTER TABLE eventmgt.room_block_seg OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.room_block_seg FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.room_block_seg FROM postgres; -GRANT ALL ON TABLE eventmgt.room_block_seg TO postgres; -GRANT ALL ON TABLE eventmgt.room_block_seg TO nobody; -GRANT ALL ON TABLE eventmgt.room_block_seg_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.room_block_seg_id_seq TO nobody; - -CREATE INDEX room_block_seg_id_index ON eventmgt.room_block_seg ( id ); -CREATE INDEX room_block_seg_block_index ON eventmgt.room_block_seg ( block ); -CREATE INDEX room_block_seg_event_index ON eventmgt.room_block_seg ( event ); -CREATE INDEX room_block_seg_accommodation_index ON eventmgt.room_block_seg ( accommodation ); - - -CREATE TABLE eventmgt.team - ( - id SERIAL, - event integer, - division integer, - state integer, - name text, - team_code text, - participants smallint, - room_block integer, - notes text - ); - -ALTER TABLE eventmgt.team OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.team FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.team FROM postgres; -GRANT ALL ON TABLE eventmgt.team TO postgres; -GRANT ALL ON TABLE eventmgt.team TO nobody; -GRANT ALL ON TABLE eventmgt.team_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.team_id_seq TO nobody; - -CREATE INDEX team_id_index ON eventmgt.team ( id ); -CREATE INDEX team_code_index ON eventmgt.team ( team_code ); -CREATE INDEX team_event_index ON eventmgt.team ( event ); - - -CREATE TABLE eventmgt.team_roster - ( - id SERIAL, - team integer, - lname text, - fname text, - pos text, - notes text - ); - -ALTER TABLE eventmgt.team_roster OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.team_roster FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.team_roster FROM postgres; -GRANT ALL ON TABLE eventmgt.team_roster TO postgres; -GRANT ALL ON TABLE eventmgt.team_roster TO nobody; -GRANT ALL ON TABLE eventmgt.team_roster_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.team_roster_id_seq TO nobody; - -CREATE INDEX team_roster_id_index ON eventmgt.team_roster ( id ); -CREATE INDEX team_roster_team_index ON eventmgt.team_roster ( team ); - - - -CREATE TABLE eventmgt.team_property - ( - id SERIAL, - team integer, - property integer, - event integer, - start date, - stop date - ); - -ALTER TABLE eventmgt.team_property OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.team_property FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.team_property FROM postgres; -GRANT ALL ON TABLE eventmgt.team_property TO postgres; -GRANT ALL ON TABLE eventmgt.team_property TO nobody; -GRANT ALL ON TABLE eventmgt.team_property_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.team_property_id_seq TO nobody; - -CREATE INDEX team_property_id_index ON eventmgt.team_property ( id ); -CREATE INDEX team_property_team_id_index ON eventmgt.team_property ( team ); -CREATE INDEX team_property_property_id_index ON eventmgt.team_property ( property ); -CREATE INDEX team_property_event_id_index ON eventmgt.team_property ( event ); - - -CREATE TABLE eventmgt.accommodation - ( - id SERIAL, - member integer, - name text, - title text, - category smallint, - descr text, - image text, - quant integer, - occupants smallint, - maxoccupants smallint, - sort smallint - ); - -ALTER TABLE eventmgt.accommodation OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.accommodation FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.accommodation FROM postgres; -GRANT ALL ON TABLE eventmgt.accommodation TO postgres; -GRANT ALL ON TABLE eventmgt.accommodation TO nobody; -GRANT ALL ON TABLE eventmgt.accommodation_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.accommodation_id_seq TO nobody; - -CREATE INDEX accommodation_id_index ON eventmgt.accommodation (id); -CREATE INDEX accommodation_member_index ON eventmgt.accommodation (member); - -CREATE TABLE eventmgt.entrance - ( - id SERIAL, - member integer, - name text, - addr1 text, - addr2 text, - city text, - state text, - country text, - zip text, - phone text, - lat float, - lon float, - descr text, - image text, - color text, - notes text, - sort smallint - ); - -ALTER TABLE eventmgt.entrance OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.entrance FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.entrance FROM postgres; -GRANT ALL ON TABLE eventmgt.entrance TO postgres; -GRANT ALL ON TABLE eventmgt.entrance TO nobody; -GRANT ALL ON TABLE eventmgt.entrance_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.entrance_id_seq TO nobody; - -CREATE INDEX entrance_id_index ON eventmgt.entrance (id); -CREATE INDEX entrance_member_index ON eventmgt.entrance (member); -CREATE INDEX entrance_sort_index ON eventmgt.entrance (sort); - -CREATE TABLE eventmgt.section - ( - id SERIAL, - member integer, - name text, - descr text, - image text, - entrance integer, - notes text, - sort smallint - ); - -ALTER TABLE eventmgt.section OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.section FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.section FROM postgres; -GRANT ALL ON TABLE eventmgt.section TO postgres; -GRANT ALL ON TABLE eventmgt.section TO nobody; -GRANT ALL ON TABLE eventmgt.section_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.section_id_seq TO nobody; - -CREATE INDEX section_id_index ON eventmgt.section (id); -CREATE INDEX section_member_index ON eventmgt.section (member); -CREATE INDEX section_sort_index ON eventmgt.section (sort); - -CREATE TABLE eventmgt.performance - ( - id SERIAL, - member smallint, - name text, - active boolean, - descr text, - short_descr text, - start_date date, - end_date date, - purch_leadtime smallint, - image text, - policy text, - voucher_text text, - conf_text text, - notes text, - promote_in_cart boolean, - sort smallint - ); - -ALTER TABLE eventmgt.performance OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.performance FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.performance FROM postgres; -GRANT ALL ON TABLE eventmgt.performance TO postgres; -GRANT ALL ON TABLE eventmgt.performance TO nobody; -GRANT ALL ON TABLE eventmgt.performance_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.performance_id_seq TO nobody; - -CREATE INDEX performance_id_index ON eventmgt.performance (id); -CREATE INDEX performance_member_index ON eventmgt.performance (member); -CREATE INDEX performance_sort_index ON eventmgt.performance (sort); - -CREATE TABLE eventmgt.ticket - ( - id SERIAL, - active boolean, - member integer, - name text, - title text, - section smallint, - date_specific boolean, - days_of_week integer, - start_date date, - end_date date, - time_specific boolean, - ticket_time time, - unlimited_use boolean, - uses smallint, - performance smallint, - unlimited_quant boolean, - quant integer, - consignment_type smallint, - cart_sticky boolean, - price float, - descr text, - image text, - voucher_text text, - voucher_type integer, - sort smallint - ); - -ALTER TABLE eventmgt.ticket OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket TO postgres; -GRANT ALL ON TABLE eventmgt.ticket TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_id_seq TO nobody; - -CREATE INDEX ticket_id_index ON eventmgt.ticket (id); -CREATE INDEX ticket_member_index ON eventmgt.ticket (member); -CREATE INDEX ticket_section_index ON eventmgt.ticket (section); - -CREATE TABLE eventmgt.ticket_inventory - ( - id SERIAL, - ticket integer, - member integer, - quant integer, - available integer, - sold integer, - ticket_date date, - ticket_time time, - active boolean - ); - -ALTER TABLE eventmgt.ticket_inventory OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_inventory FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_inventory FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_inventory TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_inventory TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_inventory_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_inventory_id_seq TO nobody; - -CREATE INDEX ticket_inventory_id_index ON eventmgt.ticket_inventory (id); -CREATE INDEX ticket_inventory_ticket_index ON eventmgt.ticket_inventory (ticket); -CREATE INDEX ticket_inventory_member_index ON eventmgt.ticket_inventory (member); -CREATE INDEX ticket_inventory_date_index ON eventmgt.ticket_inventory (ticket_date); - -CREATE TABLE eventmgt.ticket_add_on - ( - id SERIAL, - ticket integer, - name text, - descr text, - add_on_type integer, - max_quant integer, - unit_name text, - unit_cost float - ); - -ALTER TABLE eventmgt.ticket_add_on OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_add_on FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_add_on FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_add_on TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_add_on TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_add_on_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_add_on_id_seq TO nobody; - -CREATE INDEX ticket_add_on_id_index ON eventmgt.ticket_add_on (id); -CREATE INDEX ticket_add_on_ticket_index ON eventmgt.ticket_add_on (ticket); - -CREATE TABLE eventmgt.promo_code - ( - id SERIAL, - name text, - long_name text, - descr text, - start_date date, - end_date date, - notes text - ); - -ALTER TABLE eventmgt.promo_code OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.promo_code FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.promo_code FROM postgres; -GRANT ALL ON TABLE eventmgt.promo_code TO postgres; -GRANT ALL ON TABLE eventmgt.promo_code TO nobody; -GRANT ALL ON TABLE eventmgt.promo_code_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.promo_code_id_seq TO nobody; - -CREATE INDEX promo_code_id_index ON eventmgt.promo_code (id); -CREATE INDEX promo_code_start_date_index ON eventmgt.promo_code (start_date); -CREATE INDEX promo_code_end_date_index ON eventmgt.promo_code (end_date); - -CREATE TABLE eventmgt.promo_ticket - ( - id SERIAL, - promo integer, - ticket integer, - promo_type integer, - amount float, - notes text - ); - -ALTER TABLE eventmgt.promo_ticket OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.promo_ticket FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.promo_ticket FROM postgres; -GRANT ALL ON TABLE eventmgt.promo_ticket TO postgres; -GRANT ALL ON TABLE eventmgt.promo_ticket TO nobody; -GRANT ALL ON TABLE eventmgt.promo_ticket_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.promo_ticket_id_seq TO nobody; - -CREATE INDEX promo_ticket_id_index ON eventmgt.promo_ticket (id); -CREATE INDEX promo_ticket_ticket_index ON eventmgt.promo_ticket (ticket); - -CREATE TABLE eventmgt.room_detail - ( - id SERIAL, - member integer, - accommodation integer, - occupants smallint, - room_type smallint, - bath_type smallint, - pullout_beds smallint, - single_beds smallint, - double_beds smallint, - queen_beds smallint, - king_beds smallint, - tv bool, - fridge bool, - safe bool, - descr text, - image text, - sort smallint - ); - -ALTER TABLE eventmgt.room_detail OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.room_detail FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.room_detail FROM postgres; -GRANT ALL ON TABLE eventmgt.room_detail TO postgres; -GRANT ALL ON TABLE eventmgt.room_detail TO nobody; -GRANT ALL ON TABLE eventmgt.room_detail_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.room_detail_id_seq TO nobody; - -CREATE INDEX room_detail_id_index ON eventmgt.room_detail (id); -CREATE INDEX room_detail_member_index ON eventmgt.room_detail (member); -CREATE INDEX room_detail_accom_index ON eventmgt.room_detail (accommodation); - - -CREATE TABLE eventmgt.res_contact - ( - id SERIAL, - contact_type int, - affiliation int, - fname text, - lname text, - org text, - addr1 text, - addr2 text, - city text, - state text, - country text, - zip text, - org_url text, - office_phone text, - mobile_phone text, - alt_phone text, - fax text, - email text, - login_id text, - alt_email text, - image text, - notes text, - create_date date, - active bool, - password text, - user_rights int - ); - -ALTER TABLE eventmgt.res_contact OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.res_contact FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.res_contact FROM postgres; -GRANT ALL ON TABLE eventmgt.res_contact TO postgres; -GRANT ALL ON TABLE eventmgt.res_contact TO nobody; -GRANT ALL ON TABLE eventmgt.res_contact_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.res_contact_id_seq TO nobody; - -CREATE INDEX res_contact_id_index ON eventmgt.res_contact (id); -CREATE INDEX res_contact_affiliation_index ON eventmgt.res_contact (affiliation); -CREATE INDEX res_contact_city_index ON eventmgt.res_contact (city); -CREATE INDEX res_contact_email_index ON eventmgt.res_contact (email); -CREATE INDEX res_contact_fname_index ON eventmgt.res_contact (fname); -CREATE INDEX res_contact_lname_index ON eventmgt.res_contact (lname); -CREATE INDEX res_contact_zip_index ON eventmgt.res_contact (zip); -CREATE INDEX res_contact_login_id_index ON eventmgt.res_contact (login_id); - - -CREATE TABLE eventmgt.event - ( - id SERIAL, - name text, - event_code text, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - descr text, - event_dates text, - active bool, - image text, - team_event bool, - days smallint, - start_date date, - end_date date, - cutoff_date date, - req_stay bool, - req_stay_arrive date, - req_stay_depart date, - req_stay_notice text, - open_res_date date, - conf_hours integer, - inven_hold_time integer, - sort smallint, - lat float, - lon float, - multiple_rooms bool, - max_rooms smallint, - cart_text text, - res_policy text, - can_policy text, - pmt_policy text, - res_msg text, - conf_msg text, - reserve_by_code bool, - central_payment bool, - central_payment_email text, - host_property smallint, - parking_image text, - parking_descr text - ); - -ALTER TABLE eventmgt.event OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.event FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.event FROM postgres; -GRANT ALL ON TABLE eventmgt.event TO postgres; -GRANT ALL ON TABLE eventmgt.event TO nobody; -GRANT ALL ON TABLE eventmgt.event_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.event_id_seq TO nobody; - -CREATE INDEX event_id_index ON eventmgt.event ( id ); -CREATE INDEX event_sort_index ON eventmgt.event ( sort ); - - -CREATE TABLE eventmgt.event_prop_dist - ( - id SERIAL, - event integer, - event_lat float, - event_lon float, - member integer, - memb_lat float, - memb_lon float, - summary text, - start_addr text, - end_addr text, - distance text, - duration text - ); - -ALTER TABLE eventmgt.event_prop_dist OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.event_prop_dist FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.event_prop_dist FROM postgres; -GRANT ALL ON TABLE eventmgt.event_prop_dist TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop_dist TO nobody; -GRANT ALL ON TABLE eventmgt.event_prop_dist_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop_dist_id_seq TO nobody; - -CREATE INDEX event_prop_event_index ON eventmgt.event_prop_dist (event); -CREATE INDEX event_prop_member_index ON eventmgt.event_prop_dist (member); - - -CREATE TABLE eventmgt.inventory - ( - id SERIAL, - date date, - member integer, - accommodation integer, - event integer, - assigned smallint, - available smallint, - rate float, - add_person float, - room_block text, - res_policy text, - can_policy text, - min_nights integer, - descr text - ); - -ALTER TABLE eventmgt.inventory OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.inventory FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.inventory FROM postgres; -GRANT ALL ON TABLE eventmgt.inventory TO postgres; -GRANT ALL ON TABLE eventmgt.inventory TO nobody; -GRANT ALL ON TABLE eventmgt.inventory_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.inventory_id_seq TO nobody; - -CREATE INDEX inventory_id_index ON eventmgt.inventory ( id ); -CREATE INDEX inventory_date_index ON eventmgt.inventory ( date ); -CREATE INDEX inventory_member_index ON eventmgt.inventory ( member ); -CREATE INDEX inventory_accom_index ON eventmgt.inventory ( accommodation ); - - -CREATE TABLE eventmgt.inven_hold - ( - id SERIAL, - hold_type integer, - inventory integer, - quant integer, - expire_time timestamp, - session_id text - ); - -ALTER TABLE eventmgt.inven_hold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.inven_hold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.inven_hold FROM postgres; -GRANT ALL ON TABLE eventmgt.inven_hold TO postgres; -GRANT ALL ON TABLE eventmgt.inven_hold TO nobody; -GRANT ALL ON TABLE eventmgt.inven_hold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.inven_hold_id_seq TO nobody; - -CREATE INDEX inven_hold_inventory_index ON eventmgt.inven_hold (inventory); -CREATE INDEX inven_hold_session_id_index ON eventmgt.inven_hold (session_id); - - -CREATE TABLE eventmgt.member - ( - id SERIAL, - member_type smallint, - name text, - descr text, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - lat float, - lon float, - active boolean, - cards_accepted smallint, - payment_gateway smallint, - gateway_par1 text, - gateway_par2 text, - gateway_par3 text, - gateway_par4 boolean, - gateway_par5 text, - paypal boolean, - paypal_client_id text, - paypal_secret text, - paypal_mode smallint, - image text, - parking_map text, - ticket_sec_map text, - ticket_spec_req boolean, - ticket_policy text, - intro_text text, - checkout_email text, - phone text, - email text, - proc_email text, - proc_email2 text, - checkout_notify boolean, - check_in time, - check_out time, - def_res_pol text, - def_can_pol text, - notes text, - amen_1 boolean, - amen_2 boolean, - amen_3 boolean, - amen_4 boolean, - amen_5 boolean, - amen_6 boolean, - amen_7 boolean, - amen_8 boolean, - amen_9 boolean, - amen_10 boolean, - def_ticket_pol text, - sort integer, - checkout_opt_1 text, - checkout_opt_2 text, - checkout_opt_3 text - ); - -ALTER TABLE eventmgt.member OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.member FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.member FROM postgres; -GRANT ALL ON TABLE eventmgt.member TO postgres; -GRANT ALL ON TABLE eventmgt.member TO nobody; -GRANT ALL ON TABLE eventmgt.member_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.member_id_seq TO nobody; - -CREATE INDEX member_id_index ON eventmgt.member ( id ); - -CREATE TABLE eventmgt.member_scan_location - ( - id SERIAL, - member integer, - name text, - descr text - ); - -ALTER TABLE eventmgt.member_scan_location OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.member_scan_location FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.member_scan_location FROM postgres; -GRANT ALL ON TABLE eventmgt.member_scan_location TO postgres; -GRANT ALL ON TABLE eventmgt.member_scan_location TO nobody; -GRANT ALL ON TABLE eventmgt.member_scan_location_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.member_scan_location_id_seq TO nobody; - -CREATE INDEX member_scan_location_id_index ON eventmgt.member_scan_location ( id ); -CREATE INDEX member_scan_location_member_index ON eventmgt.member_scan_location ( member ); - -CREATE TABLE eventmgt.amenities - ( - id SERIAL, - affiliation_type smallint, - owner smallint, - name text, - quant int, - descr text - ); - -ALTER TABLE eventmgt.amenities OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.amenities FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.amenities FROM postgres; -GRANT ALL ON TABLE eventmgt.amenities TO postgres; -GRANT ALL ON TABLE eventmgt.amenities TO nobody; -GRANT ALL ON TABLE eventmgt.amenities_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.amenities_id_seq TO nobody; - -CREATE INDEX amenities_id_index ON eventmgt.amenities ( id ); -CREATE INDEX amenities_owner_index ON eventmgt.amenities ( owner ); - - -CREATE TABLE eventmgt.event_prop - ( - id SERIAL, - event integer, - property integer - ); - -ALTER TABLE eventmgt.event_prop OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.event_prop FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.event_prop FROM postgres; -GRANT ALL ON TABLE eventmgt.event_prop TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop TO nobody; -GRANT ALL ON TABLE eventmgt.event_prop_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.event_prop_id_seq TO nobody; - -CREATE INDEX event_prop_event_id_index ON eventmgt.event_prop ( event ); -CREATE INDEX event_prop_property_id_index ON eventmgt.event_prop ( property ); - -CREATE TABLE eventmgt.reservation - ( - id SERIAL, - user_trace_info text, - fname text, - lname text, - org text, - team_id smallint, - state_rep smallint, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - phone text, - email text, - email_ok bool, - date_entered date, - arrive_date date, - nights smallint, - rooms smallint, - adults smallint, - team smallint, - member integer, - accommodation int, - room_block integer, - arrival text, - event smallint, - event_name text, - event_start date, - event_end date, - payby smallint, - cctype text, - ccnumber text, - expire text, - ccname text, - cccode text, - hotel_price float, - taxes float, - grand_total float, - confirmation smallint, - confirmed bool, - declined bool, - conf_numb text, - date_confirmed date, - conf_by text, - conf_message text, - special_needs text, - notes text, - res_detail text, - summary text - ); - -ALTER TABLE eventmgt.reservation OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.reservation FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.reservation FROM postgres; -GRANT ALL ON TABLE eventmgt.reservation TO postgres; -GRANT ALL ON TABLE eventmgt.reservation TO nobody; -GRANT ALL ON TABLE eventmgt.reservation_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.reservation_id_seq TO nobody; - -CREATE INDEX reservation_id_index ON eventmgt.reservation ( id ); -CREATE INDEX reservation_lname_index ON eventmgt.reservation ( lname ); -CREATE INDEX reservation_fname_index ON eventmgt.reservation ( fname ); -CREATE INDEX reservation_email_index ON eventmgt.reservation ( email ); -CREATE INDEX reservation_arrive_index ON eventmgt.reservation ( arrive_date ); - - -CREATE TABLE eventmgt.ticket_order - ( - id SERIAL, - user_trace_info text, - active boolean, - fname text, - lname text, - addr1 text, - addr2 text, - city text, - state text, - zip text, - country text, - phone text, - email text, - email_ok bool, - opt_field_1_name text, - opt_field_1 text, - opt_field_2_name text, - opt_field_2 text, - opt_field_3_name text, - opt_field_3 text, - purchase_date date, - member integer, - cctype text, - ccnumber text, - expire text, - ccname text, - ccconf text, - charge_total float, - special_needs text, - notes text, - session_id text - ); - -ALTER TABLE eventmgt.ticket_order OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_order FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_order FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_order TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_order TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_order_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_order_id_seq TO nobody; - -CREATE INDEX ticket_order_id_index ON eventmgt.ticket_order ( id ); -CREATE INDEX ticket_order_lname_index ON eventmgt.ticket_order ( lname ); -CREATE INDEX ticket_order_fname_index ON eventmgt.ticket_order ( fname ); -CREATE INDEX ticket_order_email_index ON eventmgt.ticket_order ( email ); -CREATE INDEX ticket_order_purchase_date_index ON eventmgt.ticket_order ( purchase_date ); -CREATE INDEX ticket_order_member_index ON eventmgt.ticket_order ( member ); -CREATE INDEX ticket_order_session_id_index ON eventmgt.ticket_order ( session_id ); - - -CREATE TABLE eventmgt.ticket_sold - ( - id SERIAL, - ticket_order integer, - member integer, - member_name text, - assigned boolean, - assigned_from integer, - assigned_from_name text, - performance smallint, - performance_name text, - entrance smallint, - entrance_name text, - entrance_color text, - section smallint, - section_name text, - ticket integer, - ticket_name text, - date_specific boolean, - ticket_date date, - time_specific boolean, - ticket_time time, - start_date date, - end_date date, - likely_date date, - price_paid float, - policies text, - unlimited_use boolean, - numb_uses smallint, - numb_claimed smallint, - time_claimed timestamp, - voucher_type smallint, - voucher_text text, - session_id text - ); - -ALTER TABLE eventmgt.ticket_sold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_sold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_sold FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_sold TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_sold TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_sold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_sold_id_seq TO nobody; - -CREATE INDEX ticket_sold_id_index ON eventmgt.ticket_sold ( id ); -CREATE INDEX ticket_sold_ticket_order_index ON eventmgt.ticket_sold ( ticket_order ); -CREATE INDEX ticket_sold_member_index ON eventmgt.ticket_sold ( member ); -CREATE INDEX ticket_sold_assigned_from_index ON eventmgt.ticket_sold ( assigned_from ); -CREATE INDEX ticket_sold_performance_index ON eventmgt.ticket_sold ( performance ); -CREATE INDEX ticket_sold_ticket_index ON eventmgt.ticket_sold ( ticket ); -CREATE INDEX ticket_sold_ticket_date_index ON eventmgt.ticket_sold ( ticket_date ); -CREATE INDEX ticket_sold_likely_date_index ON eventmgt.ticket_sold ( likely_date ); -CREATE INDEX ticket_sold_time_claimed_index ON eventmgt.ticket_sold ( time_claimed ); -CREATE INDEX ticket_sold_session_id_index ON eventmgt.ticket_sold ( session_id ); - -CREATE TABLE eventmgt.add_on_sold - ( - id SERIAL, - ticket_order integer, - ticket_sold integer, - add_on_name text, - add_on_type integer, - add_on_type_name text, - unit_name text, - unit_price float, - quant integer, - price_paid float, - session_id text - ); - -ALTER TABLE eventmgt.add_on_sold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.add_on_sold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.add_on_sold FROM postgres; -GRANT ALL ON TABLE eventmgt.add_on_sold TO postgres; -GRANT ALL ON TABLE eventmgt.add_on_sold TO nobody; -GRANT ALL ON TABLE eventmgt.add_on_sold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.add_on_sold_id_seq TO nobody; - -CREATE INDEX add_on_sold_id_index ON eventmgt.add_on_sold ( id ); -CREATE INDEX add_on_sold_ticket_order_index ON eventmgt.add_on_sold ( ticket_order ); -CREATE INDEX add_on_sold_ticket_sold_index ON eventmgt.add_on_sold ( ticket_sold ); -CREATE INDEX add_on_sold_session_id_index ON eventmgt.add_on_sold ( session_id ); - -CREATE TABLE eventmgt.promo_sold - ( - id SERIAL, - ticket_order integer, - ticket_sold integer, - promo integer, - promo_name text, - promo_type integer, - promo_type_name text, - amount float, - session_id text - ); - -ALTER TABLE eventmgt.promo_sold OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.promo_sold FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.promo_sold FROM postgres; -GRANT ALL ON TABLE eventmgt.promo_sold TO postgres; -GRANT ALL ON TABLE eventmgt.promo_sold TO nobody; -GRANT ALL ON TABLE eventmgt.promo_sold_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.promo_sold_id_seq TO nobody; - -CREATE INDEX promo_sold_id_index ON eventmgt.promo_sold ( id ); -CREATE INDEX promo_sold_ticket_order_index ON eventmgt.promo_sold ( ticket_order ); -CREATE INDEX promo_sold_ticket_sold_index ON eventmgt.promo_sold ( ticket_sold ); -CREATE INDEX promo_sold_promo_index ON eventmgt.promo_sold ( promo ); -CREATE INDEX promo_sold_session_id_index ON eventmgt.promo_sold ( session_id ); - - -CREATE TABLE eventmgt.ticket_claim_tracking - ( - id SERIAL, - ticket_order integer, - ticket_sold integer, - time_of_action timestamp, - action_type smallint, - quant smallint, - scan_user integer, - scan_name text - ); - -ALTER TABLE eventmgt.ticket_claim_tracking OWNER TO postgres; -REVOKE ALL ON TABLE eventmgt.ticket_claim_tracking FROM PUBLIC; -REVOKE ALL ON TABLE eventmgt.ticket_claim_tracking FROM postgres; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking TO nobody; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking_id_seq TO postgres; -GRANT ALL ON TABLE eventmgt.ticket_claim_tracking_id_seq TO nobody; - -CREATE INDEX ticket_claim_tracking_id_index ON eventmgt.ticket_claim_tracking ( id ); -CREATE INDEX ticket_claim_tracking_order_index ON eventmgt.ticket_claim_tracking ( ticket_order ); -CREATE INDEX ticket_claim_tracking_sold_index ON eventmgt.ticket_claim_tracking ( ticket_sold ); -CREATE INDEX ticket_claim_tracking_scan_user_index ON eventmgt.ticket_claim_tracking ( scan_user ); - diff --git a/legacy/docs/Current_Deployment_Notes.txt b/legacy/docs/Current_Deployment_Notes.txt deleted file mode 100644 index e0017e7..0000000 --- a/legacy/docs/Current_Deployment_Notes.txt +++ /dev/null @@ -1,641 +0,0 @@ -Current Deployment Notes -======================== - - -NEW CHANGES - - DATABASE CHANGES - ---------------- - - ALTER TABLE eventmgt.ticket ADD COLUMN show_on_start BOOLEAN; - - - CREATE TABLE eventmgt.voucher_coupons - ( - id SERIAL, - name text, - active boolean, - display_from timestamp, - display_to timestamp, - coupon_type smallint, - coupon_image text, - coupon_position smallint, - stretch_to_fit boolean, - padding integer, - show_border boolean, - max_display_count smallint, - display_count integer, - notes text - ); - - ALTER TABLE eventmgt.voucher_coupons OWNER TO postgres; - REVOKE ALL ON TABLE eventmgt.voucher_coupons FROM PUBLIC; - REVOKE ALL ON TABLE eventmgt.voucher_coupons FROM postgres; - GRANT ALL ON TABLE eventmgt.voucher_coupons TO postgres; - GRANT ALL ON TABLE eventmgt.voucher_coupons TO nobody; - GRANT ALL ON TABLE eventmgt.voucher_coupons_id_seq TO postgres; - GRANT ALL ON TABLE eventmgt.voucher_coupons_id_seq TO nobody; - - CREATE INDEX voucher_coupons_id_index ON eventmgt.voucher_coupons ( id ); - CREATE INDEX voucher_coupons_from_index ON eventmgt.voucher_coupons ( display_from ); - CREATE INDEX voucher_coupons_to_index ON eventmgt.voucher_coupons ( display_to ); - - - - ALTER TABLE eventmgt.ticket_sold ADD COLUMN package_name text; - update eventmgt.ticket_sold set package_name = ''; - ALTER TABLE eventmgt.ticket_sold ADD COLUMN is_package boolean; - update eventmgt.ticket_sold SET is_package = false; - - ALTER TABLE eventmgt.ticket_sold ADD COLUMN package_sold_id text; - - CREATE INDEX ticket_sold_package_sold_id_index ON eventmgt.ticket_sold ( package_sold_id ); - CREATE INDEX ticket_sold_ticket_package_index ON eventmgt.ticket_sold ( ticket_package ); - - CREATE TABLE eventmgt.attendance - ( - id SERIAL, - member smallint, - name text, - notes text, - attendance_date timestamp, - entrance_start_time timestamp, - entrance_end_time timestamp, - perf_start_time timestamp, - perf_end_time timestamp - ); - - ALTER TABLE eventmgt.attendance OWNER TO postgres; - REVOKE ALL ON TABLE eventmgt.attendance FROM PUBLIC; - REVOKE ALL ON TABLE eventmgt.attendance FROM postgres; - GRANT ALL ON TABLE eventmgt.attendance TO postgres; - GRANT ALL ON TABLE eventmgt.attendance TO nobody; - GRANT ALL ON TABLE eventmgt.attendance_id_seq TO postgres; - GRANT ALL ON TABLE eventmgt.attendance_id_seq TO nobody; - - CREATE INDEX attendance_id_index ON eventmgt.attendance ( id ); - CREATE INDEX attendance_lmember_index ON eventmgt.attendance ( member ); - CREATE INDEX attendance_attendance_date_index ON eventmgt.attendance ( attendance_date ); - CREATE INDEX attendance_entrance_start_time_index ON eventmgt.attendance ( entrance_start_time ); - CREATE INDEX attendance_perf_start_time_index ON eventmgt.attendance ( perf_start_time ); - - ALTER TABLE eventmgt.ticket_claim_tracking ADD COLUMN attendance smallint; - ALTER TABLE eventmgt.ticket_claim_tracking ADD COLUMN attendee_name text; - ALTER TABLE eventmgt.ticket_claim_tracking ADD COLUMN attendee_notes text; - CREATE INDEX ticket_claim_tracking_attendance_index ON eventmgt.ticket_claim_tracking ( attendance ); - UPDATE eventmgt.ticket_claim_tracking SET attendance = 0, attendee_name = '', attendee_notes = ''; - - CREATE TABLE eventmgt.member_scans_for - ( - id SERIAL, - member integer, - scans_for integer - ); - - ALTER TABLE eventmgt.member_scans_for OWNER TO postgres; - REVOKE ALL ON TABLE eventmgt.member_scans_for FROM PUBLIC; - REVOKE ALL ON TABLE eventmgt.member_scans_for FROM postgres; - GRANT ALL ON TABLE eventmgt.member_scans_for TO postgres; - GRANT ALL ON TABLE eventmgt.member_scans_for TO nobody; - GRANT ALL ON TABLE eventmgt.member_scans_for_id_seq TO postgres; - GRANT ALL ON TABLE eventmgt.member_scans_for_id_seq TO nobody; - - CREATE INDEX member_scans_for_id_index ON eventmgt.member_scans_for (id); - CREATE INDEX member_scans_for_member_index ON eventmgt.member_scans_for (member); - CREATE INDEX member_scans_for_scans_for_index ON eventmgt.member_scans_for (scans_for); - - - - - CONFIG CHANGES - -------------- - - ; Terms used to refer to an attendance - term.attendance.norm = "attendance" - term.attendance.cap = "Attendance" - term.attendance.plur = "attendance" - term.attendance.plur_cap = "Attendance" - - ; Terms used to refer to an attendee - term.attendee.norm = "attendee" - term.attendee.cap = "Attendee" - term.attendee.plur = "attendees" - term.attendee.plur_cap = "Attendees" - - ; Terms used to refer to an attendance log - term.attendance_log.norm = "attendance log" - term.attendance_log.cap = "Attendance Log" - term.attendance_log.plur = "attendance logs" - term.attendance_log.plur_cap = "Attendance Logs" - - ; Terms used to refer to entering (attendance) - term.attendance_entering.norm = "entering" - term.attendance_entering.cap = "Entering" - term.attendance_entering.plur = "entering" - term.attendance_entering.plur_cap = "Entering" - - ; Terms used to refer to Coupons (advertisements) for vouchers - term.coupon.norm = "voucher coupon" - term.coupon.cap = "Voucher Coupon" - term.coupon.plur = "voucher coupons" - term.coupon.plur_cap = "Voucher Coupons" - - - -------------END OF NEW CHANGES NOTES------------------------------------ - -Mackinaw Lakeshore Development (Mackinaw City) -Username: hydrojet955 -Password: Mc33BoAt -Current API Login ID: 6AkBG3xJ7HB -Current Transaction Key: 6tJ5BxaB4X4f37JE - -Star Line Mackinac Island Passenger Service Inc. (St Ignace) -Username: hydrojet956 -Password: Mc34BoAt -Current API Login ID: 3Wazxf7G5u97 -Current Transaction Key: 3TW7f7Z28p5m4x9Y - - -Database Update Notes ---------------------- - - - -Temporary Notes from Notepad ----------------------------- - -Jodie Things and other thing I've noticed - -* Include contact permission options to enable access to all locations data - -* Fix problems with Likely date not being validated - DONE - -* Check on correct "From:" E-Mail address for confirmation messages. - -* Agree to policies on checkout page not staying as what was selected when checkout fails. - -* Session ID or something not going to Authorize.net for use as an order ID. - -* Inventory may not be being created when a ticket is created. - -Longer term Jodie Things - -* One credit card checkout form - -* Need to consider limits on report results. - -To do - -* Can't use Add-ons for children in sunset cruises - -* Promo Codes not working on checkout - Check again - DONE - -* Make sure promo codes respect time ranges - DONE - -* Add "Code Recognized" indication to cart - -* Check if we should be storing ID of Add-on in add_on_sold table. - -* Make Checkout Results look like current checkout page for tables. - DONE - -* make likely date = ticket date if fixed date - -* may be issue with selection on "Ticket Select" page (cruises) when there's unlimited quantity and the underlying quant field is 0 or null. - -* Flag to permit voucher scanning by contact from any location - -* Ticket claim tracking - -* Check if login user can check/claim tickets at all locations - May need to make this a configuration option per customer. - Use option to suppress location name at top of page. - - - -Done - -* checkout now storing add-ons correctly - -* Vouchers now showing add-ons correctly - -* Sticky items showing up when category is active = false - - - - - -Current modifications to complete for Star Line ------------------------------------------------ - -QUESTIONS - - Are the dates on promo codes the date of purchase or the date of use? - ANSWER: Date of sale. - -Vouchers: - - * Specified color per dock for voucher and for display when scanning vouchers. - Not always displaying correctly - Check - DONE - If not an assignment, the Section must specify an entrance and entrance must have color. - - * 90 deg Rotated text not displaying in the correct position and moves as text changes. - DONE - Needed to use "left" for $align in glmpdfPlaceText() then "position=center" in the optlist. - - * Summary of items purchased and totals on voucher cover page - DONE - - * Policies per location for display on cover sheet of voucher. - DONE - - * Simple (limited) text per category (performance) for display on bottom of voucher. - DONE - - * Provide for blocking of printing Voucher Barcode if card will be printed and mailed. Note on voucher. - DONE - NEED TO TEST WITH PURCHASE - - * Properly show add-ons - DONE - -Voucher related functionality: - - * Ability to show just barcode for a specific voucher for possible scanning from a phone. - NOT DOING AT THIS TIME - - * Ability of customers to enter a voucher number (and check code) to view order and re-print vouchers and display barcode for phone scanning. - NOT DOING AT THIS TIME - - * Check on auto-scaling image on Voucher - - * Check fonts on Dev53 used by Vouchers - -Front-End General: - - * Removed number of "uses" from display on Front-end. Relying on descriptions to say how the tickets will be used. - DONE - - * Fixed improper reference to ticket.ticket_name when should have been ticket.ticket_title for use on front-end. - DONE - - * Test in Chrome and other browsers - - * Test in mobile widths - - * Check sort order of all output - DONE - for everything we're showing for Star Line - - * Make sure that all available data can be displayed. (descriptions, images, etc). Set configurable options (in config/applications/EventManagement.ini) to turn those on/off. - DONE - - * Sale of "group" tickets, like 2 Adults and 2 Children, should be on one voucher (which they are now). Need to confirm with Star Line. - DONE - Must be this way as they are group tickets. - - * Look for "Check if we're receiving an array of new additions" in front/classes/support.php and check on this. - - * Make sure add-ons work on ticketSelect page. - - * Check that all new information is passed all the way through to orders - -Cart Page: - - * Check on ordering of categories. They don't seem to follow the sort order field in the database. - DONE - - * Have "nights" selection for valet parking display right away when user selects quantity for valet parking. - DONE - Decided to show it all the time for now. - - * Have resubmit updates try to return to the same page scroll position. - DONE - - * Check on not showing Dock selection or likely departure date unless they're needed. This is interfering with ordering things that don't need them. - DONE - - * Consider adding a notice overlay when the first thing is selected that needs dock and date selection to instruct user that they need to enter that information. - - * Remove the "reprint a previous order" thing from the top of the page. - DONE - - * Added short descriptions to Categories. In cart use short description instead of normal when less than 600 wide. - DONE - -Checkout page: - - * Make checkout page items lists look like Cart page - DONE - But might need to check what's store - - * Make checkout prompt fields configurable in customer config file. - DONE - - * Add a few optional/configurable text fields for checkout - DONE - - * Fixed Special Requests field showing when not requested - DONE - - * Fixed improper reference to ticket.ticket_name when should have been ticket.ticket_title for use on front-end. - DONE - - * Fixed missing info for ticket orders. - DONE - - * Check storage of promotions with purchase - - * Check storage of Add-Ons with purchase - DONE - -Admin: - - * Admin Login and improved colored claim scan results indications - DONE - - * Test in Chrome and other browsers - - * See if can do better with consignment type text - less confusing - DONE - Might want to move text for these things to customer config - - * Add time override to inventory - Default to that set in the ticket - Added to inventory edit - Need to use that time throughout the rest of admin and front-end - SUSPENDED FOR NOW - - * Fix issues with small and large list switching and alignment of columns when selecting large/small or resizing window. - DONE - - * Redisplay lists when something is added deleted or edited. - Need to add feature to know where the list is so it can be updated. - Working on this.... - - * Low-level front-end admin access. - DONE - - * Background color on scan of voucher to show Pass/No Pass status. - DONE - - * Inventory calendars not showing all dates at times - - * Add link from a performance to permit purchasing from admin even if performance or ticket is not active. - Added flag to ticket to permit active boolean, but need to Respect in front-end. - - * Add any needed reporting for promotions - - * Add any needed reporting for Add-Ons - - * Consider copying default ticket time into inventory so that a specific inventory item can have the time of the event adjusted. - Only do this if there's time available for the change. - - * Consider adding a "Category" parameter to performances to permit categorizing performances. (This would mean changing how we use these terms for Star Line.) - -Not-categorized: - -* May need to consider non-date-related items such as purchased physical items (books, etc) - Don't show likely departure date in cart for these. - -* Consider adding year/season to all ticket data and establishing a "seasonal" option that lets admin select a year/season to work with. - -* Check Member Ticket Policy - Does not seem to be in detail or edit. - -* Agree to policies on checkout needs to be in red - required. - -* Need to complete tracking of multiple claims for tickets that can be claimed more than once. - Database seems to be setup, but need to add tracking and display in ticket sold display - -* Need to add code to handle editing of tickets sold. - -* Check on adding entrance to ticket. May not always be able to use "Entrance" from section - i.e. Sunset Cruises. - DONE - may need some work later to make this more universal - -* Check on doing a pop-up message when checkout completed instructing users to print tickets or retain order and voucher numbers. - -* Voucher cover page - Web address - Phone Numbers - Maps??? Or do the appropriate map with each voucher. - -* Set a date range for creating inventory in ticket edit - This should be used as the date range when building inventory - It should be the dates checked when checking if inventory needs to be added or turned off - It should default to the date range specified in the event - DONE - But not defaulting to performance dates - -* Need to handle Valet Parking - Valet parking is charged per night. - Consider this a ticket "Add-On" item - Select 1 or multiple for an add-on item (yes/no or quantity) - Optional Price per add-on - Include field to say what this is (i.e "Per Night", or "Each") - Should show on line below primary line for ticket. - - Ticket Add-On - - * create table ticket_add_on - name - description - type (single (option), selected quantity, - other - perhaps packaging of other tickets) - see "ticket_add_on_type" in config - max quantity if quantity related - unit name - unit amount - - * Add admin management of add-ons for a specific ticket - - * Add handling of add-ons when selecting tickets and in cart and checkout - - * Add handling of add-ons in reporting. - - Added to admin but not done on front-end - -* Promo Code - Entry of Promo Code text - Each promo code has list of tickets it applies to - Each promo code provides either percentage or $ amount - - promo_code - id SERIAL, - name text, - descr text, - start_date date, - end_date date, - notes text - - promo_ticket - - id SERIAL, - ticket text, - promo_type integer, - amount float, - notes text - - -* Check on entrance display in Section selection page. - -Completed - -* Toggle list size button for lists in admin. - DONE - -* Need to add time specific, # of uses, and number of claims to ticket sold data - DONE - -* For vouchers "Round Trip Ticket", "Retain this ticket for your return trip. - Now configurable text per ticket or event - DONE - -* Forget session button when running on Development server - Added to bottom of all pages if running on a development server - DONE - -* Add better "Please Wait" thingy. - Added pop-up/overlay for pages needing this. - DONE - -* Departure date for non-date-specific tickets - Added likely departure date to cart and likely date to checkout - Need to add to ticket order information also - DONE - -* Remove "Each" from cart and checkout tables - DONE - -* Add second doc (location) handling for St. Ignace - Added "Entrance" feature to ticketing system and termed this as "Docks" for Star Line - Still need to get this printing on summaries and vouchers - DONE - -* Checkout contact information "Please send information ..." should default to checked. - DONE - -* "Print Vouchers" to "Print Boarding Passes" ??? - Changed terms used for "Voucher" to "Boarding Pass" - DONE - -* Enable browser menus on the voucher window so people can print. - Enabled menus and added window.print() to script - DONE - -------- - - - -* Create new optional Purchase process for Star Line - See "Streamlined Ticketing for Star Line.odg" - - Venues need "type" - type 1 Standard Location/venue - Can sell items - type 2 Standard Location/venue + Sell through other venues - Can sell items - Can offer items for sale by other locations - Must flag items to be sold this way - Other vendors must be approved by this vendor to sell their stuff - Items must be flagged as sellable by others - (may want to have specific ticket negotiations) - type 3 Non-sales vendor, tickets only sold by type 1 or 2 locations/venues on this system - Does not sell items - Items of Type 3 are available for sale by type 2 - - Ticket need flag that permits them to be sold by other vendors - - Need flag for ticket that causes it to always be shown on cart - even with 0 quantity. - - Ticket sold needs pointer to vendor who sold the ticket/item (in addition to the point to the member who's tickets they are) - -* Try to sort cart by ticket sort order - -* Set global terms - location: Departing From - (Consider adding categories of events) - Event: Category ??? - Section: Section - Ticket: Item - Inventory: Inventory - -* Get info on Motorola hand scanners for Jerry - May need 8 to 10 - Most WiFi but some Cell. - http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Bar+Code+Scanning# - - Possible options - Prices approx - - Simple for use with computer - $108 (Amazon) http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Bar+Code+Scanning/General+Purpose+Scanners/LI2208 - $380 (Amazon) http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Bar+Code+Scanning/General+Purpose+Scanners/LI4278 - - Wireless - http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Mobile+Computers/Handheld+Computers/MT2000+Series+Handheld+Mobile+Terminals_US-EN - http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Mobile+Computers/Handheld+Computers/MC55A0 - http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Bar+Code+Scanning/Rugged+Scanners/MT2000+Series+Handheld+Mobile+Terminals_US-EN - - Ruggedized Mobile Computer - http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Mobile+Computers/Handheld+Computers/MC3100_US-EN - - Cell Capable - http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Mobile+Computers/Handheld+Computers/TC55#specs_tab - http://www.motorolasolutions.com/US-EN/Business+Product+and+Services/Mobile+Computers/Handheld+Computers/MC67 - - -* Create Venue - Event - Section - Ticket - Inventory summary with flags for issues in Admin area - Expandable sections might be good - -* Update reports to work correctly with all new changes - -* Add Month and Day of Week enable/dissable for inventory edit page - * Consider being able to highlight date cells and do bulk edit with them. - -* Update Help file and enable context sensitive admin help - - - -Issues to check on ------------------- - -* Make sure default inventory is created when tickets are created. - -* Make sure that tickets are not presented on the front-end unless there's inventory - -* Make sure that non-date-specific inventory is handled correctly - * Inventory edit updates quantities properly - * Front-end and reports use correct numbers - -* Make sure we're using the right name/title for tickets and other things (internal vs user terms) - -* Check on content of stored purchase summary - -* Check that credit card type and name on cart are stored in order detail - -* Make sure that multiple claims per ticket is working correctly and showing on back-end correctly - - - - - - -OLD INFO - MAY NOT BE RELEVANT ANYMORE - -* Change any fees of type 11 or 12 that are in use to type 10 -* Check to make sure Toolkit/EventManagement/config.ini has updated fee definitions - -; Fee Method -fee_method.fixed_stay = 1 -fee_method.fixed_accom = 2 -fee_method.fixed_accomnight = 3 -fee_method.percent_stay = 10 - -; Fee Method Numbers - admin -fee_method_numb.1 = "Per Reservation - Fixed Fee" -fee_method_numb.2 = "Per Room - Fixed Fee" -fee_method_numb.3 = "Per Night - Fixed Fee" -fee_method_numb.10 = "% of Room Rate" - -; Fee Method Numbers - Front End -fee_method_numb_fe.1 = "Per Reservation" -fee_method_numb_fe.2 = "Per Room" -fee_method_numb_fe.3 = "Per Night" -fee_method_numb_fe.10 = "Per Room" - - -alter table convention add column central_payment boolean; -alter table convention add column central_payment_email text; -alter table convention add column host_property smallint; -update convention set central_payment = 'f', central_payment_email = '', host_property = 0; diff --git a/legacy/docs/Delete_Event.sql b/legacy/docs/Delete_Event.sql deleted file mode 100755 index 1ec7fea..0000000 --- a/legacy/docs/Delete_Event.sql +++ /dev/null @@ -1,21 +0,0 @@ - --- Find event ID -SELECT id, name, conv_code, start_date, end_date FROM convention; - - --- Replace {CONV ID} with desired event id -DELETE FROM team_roster WHERE team IN (SELECT id FROM team WHERE conv = {CONV ID}); -DELETE FROM team_property WHERE conv = {CONV ID}; -DELETE FROM team_property WHERE conv = {CONV ID}; -DELETE FROM state_rep WHERE conv = {CONV ID}; -DELETE FROM division WHERE conv = {CONV ID}; -DELETE FROM room_block WHERE conv = {CONV ID}; -DELETE FROM room_block_seg WHERE conv = {CONV ID}; -DELETE FROM inven_hold WHERE inventory IN (SELECT id FROM inventory WHERE conv = {CONV ID}); -DELETE FROM inventory WHERE conv = {CONV ID}; -DELETE FROM reservation WHERE conv = {CONV ID}; -DELETE FROM fees WHERE affiliation_type = 1 AND owner = {CONV ID}; -DELETE FROM conv_prop_dist WHERE convention = {CONV ID}; -DELETE FROM event_prop WHERE event = {CONV ID}; -DELETE FROM convention WHERE id = {CONV ID}; - diff --git a/legacy/docs/Development_Notes.txt b/legacy/docs/Development_Notes.txt deleted file mode 100644 index 47d4be3..0000000 --- a/legacy/docs/Development_Notes.txt +++ /dev/null @@ -1,513 +0,0 @@ -Current Work ------------- - -Notes regarding modifications to Ticketing to support ferry services - -Things to update ----------- -SQL and database changes required for current updates - -alter table eventmgt.ticket add column unlimited_quant boolean; -update eventmgt.ticket set unlimited_quant = false; -alter table eventmgt.misc drop column return_url; -alter table eventmgt.misc add column intro_text text; -alter table eventmgt.misc add column ticket_text text; -alter table eventmgt.misc add column ticket_opt_text text; -alter table eventmgt.misc add column cart_text text; -alter table eventmgt.misc add column checkout_text text; -alter table eventmgt.misc add column success_text text; -update eventmgt.misc set - intro_text = 'Intro text', - ticket_text = 'Ticket selection text', - ticket_opt_text = 'Ticket option selection text', - cart_text = 'Cart text', - checkout_text = 'Checkout text', - success_text = 'Checkout success text'; - -Above needed for current devdb copy - -alter table eventmgt.ticket add column section_specific boolean; -alter table eventmgt.ticket add column time_specific boolean; -alter table eventmgt.ticket add column date_specific boolean; -alter table eventmgt.ticket add column unlimited_use boolean; -alter table eventmgt.ticket add column start_date date; -alter table eventmgt.ticket add column end_date date; -alter table eventmgt.ticket add column uses smallint; -update eventmgt.ticket set - section_specific = true, - time_specific = true, - date_specific = true, - unlimited_use = false, - start_date = null, - end_date = null, - uses = 1; - - - -How to add a new main tab item to admin ---------------------------------------- - -* Edit view index.html and add a new tab where desired. -* Set "emTabId" for that tab to the desired model and action (i.e. Attendees_list} -* Create a matching directory under both... - models/admin/actions/{model} - views/admin/tickets/{model} -* Add action include files in models/admin/actions/{model}. Typically these are... - add.inc, confirmDelete.inc, delete,inc, detail.inc, edit.inc, insert.inc, list.inc, selected.inc, update.inc -* Add view files in views/admin/tickets/{model}. Typically these are... - added.html, deleted,html, detail.html, edit.html, list.html - - - - -Update CommonAbstracts-PDF-V0 -------------- - -High priority for Starline - -* Check on creating tickets for an event needing to select the venu -* Check on permitting selection of both date specific and non date specific tickets for the same event -* Options to set defaults for checkboxes when creating tickets - -* Options for tickets - * No Section - * No time - * Non-date specific - * Active for specified range of dates for non-date specific tickets - * Multiple scans/uses for a single ticket - Specified number - * Unlimited scans/uses for ticket - * Unlimited inventory -* Track Scan time, location, user when claiming tickets - -* Convert to Smarty Templates -* Create admin/log-in user ticket sales interface -* If a single venue, default to that venue when creating tickets and other things -* Recommend other tickets/sales on ticket selection -* Packaging - * Purchase multiple tickets as one item -* Pre-sales to other sales agents - * Create agents to sell (use contacts with specified permissions) - * Track sales agent / means of sale for each ticket sold - Add "sold_by" field to ticket_sold table -* Add filters to lists - * Active/inactive - * Venue - * Section - * Date range for ticket orders - - -* Check on support for portable bar-code readers with audible/light/display confirmation. - BarcodesInc, Chicago 1-800-351-9962 - * Hand held, weather proof, bar-code, WiFi, optional link to cell phone/service, display/audio for confirmation/info - - - - - -Things to check on - -* Checkout permitted with no cart contents if re-displaying checkout -* on checkout fail (field not filled in) says "This venue does not have a payment method configured. Please call this venue to purchase tickets." -* Need ability to display prototype of all E-Mail messages sent. Optionally all forms. - - - - -* Need to split and verify application.ini file into common app and user configuration files. - -* Moving schema from reservations to eventmgt -* Moving table convention to table event -* Moving fields that point to event (convention) to event -* Move ..._APP_BASE to THIS_APP_BASE as appropriate - - - - - -FROM V2 - Much still needs to be implemented - -Notes from 2/1/2013 - -Do something to deal with someone double selecting the same available inventory into their cart. -Cart should check for actual maximums available or we can implement the selected inventory hold. - -Check all property fees to see if any type 1 or type 10 are set as "Fee is selectable per room": - -For event fees, per room % of room rate seems to be superfluous. - -May need to check for per Reservation optional fee that's not per room on accommodations selection page. - ----- - - - -DB updates - alter table convention add column central_payment boolean; - alter table convention add column central_payment_email text; - alter table convention add column host_property smallint; - update convention set central_payment = 'f', central_payment_email = '', host_property = 0; - - -In procees - Central Payment - Admin work - * central_payment Flag - * central_payment_email Who gets bills - Request credit card Flag - Show prices to guests Flag - ??? Billing/payment reconciliation to members ??? - Front-end - Request credit card if set - Send reservation to Prop - Send billing to central billing - Members Area - Look through to find things that might need to be fixed up - ??? payment reconciliation to members ??? - Host Property - Admin - * Work completed - Front End - Need to display host propert at top of lists - Highlight background? - - - - - -General Development Notes - -alter table - -Fees Matrix - - Available with - Applied at level Event Property - Per Reservation - Fixed Fee - - Optional Off Property Yes Yes - Optional On Property Yes Yes - Selectable per room Accommodation No No - - Per Room - Fixed Fee - - Optional Off Property Yes Yes - Optional On Property Yes Yes - Selectable per room Accommodation No Yes - - Per Night - Fixed Fee - - Optional Off Property Yes Yes - Optional On Property Yes Yes - Selectable per room Accommodation No Yes - - % of Room Rate - - Optional Off Property Yes Yes - Optional On Property Yes Yes - Selectable per room Accommodation No Yes - - -Misc Notes ----------- - -Pending database updates for live servers ------------------------------------------ - -For geo mapping address -/* -include this link -http://maps.googleapis.com/maps/api/js?sensor=true - -// For the Event Map -// Create a jquery dialog with #map-dialog -$('#map-dialog').dialog({ -height: 480, -width: 520, -modal: true, -autoOpen: false -}); -$("#map-it").click(function(e){ -e.preventDefault(); -$("#map-dialog").dialog('open'); -GLM_GeoMap.initialize(); -}); - -

-*/ - -Site Status ------------ - - Server Site Version Notes - dev52 Development V1, V2 - dev53 Development (pending) - ws0 app.gaslightmedia.com V1, V2 - ws3 app.gaslightmedia.com V1, V2 - www.discoverkalamazoo.com V2 - - -Task List ---------- - -GENERAL - -** Check for International Address Support - DONE - -** Add fields for E-Mail addresses to event (general contact, internal contact, from address) - Can we use Discover Kalamazoo in the from line and GeneralInfo@DiscoverKalamazoo.com as the email address? - Jodie - -** Ability to select an event that is charged to a central entity rather than to each attendee - -** Check owner name salutation line in confirmation e-mails. - -** Event ID as access to event registrations - DONE - -** Host property selection in event - -** Display of date/rates when rates are inconsistent for a stay - -* Purge any previous customer info or links from system (greatlakesbay) - -* Need to change calendar.phtml pop-up to all JAVAscript using a layer at some point. - -* Add "conv" field to inven_hold table to make it easier to identify by event. - -ADMIN AREA - -** Add Team filter and output sorting options to Reservations report - -* Add check for inventory that doesn't match the evnet dates when the dates for an event are changed. - Add check for this whenever the event is selected and prominantly warn the user. - Make sure that inventory associated with an event is displayed even if it's outside the date range for the event. - Add warning to inventory that is outside the date range for an event when listing/viewing that inventory. - -* Need to have system check to make sure inventory is in a rational date frame for the event. If the event date - changes, it needs to still be able to display what inventory is in there (which it seems to have a problem with) - and needs to warn the admin user that the inventory needs to be change. Consider adding code such that if the - event start date changes that all inventory slides the same number of days. - -* Add Division to reservation reports - -* Add Division to Events->Reservations list and detail - -* Check fees/taxes detail output to make sure $ & % are displayed correctly for selected type. - -* Add date for earliest possible reservation used to block reservations prior to a certain date. - -* Reservations report - Add table ordered by State Rep, Team - ***DONE*** Add filter for State Rep - -* Add map drag-drop capability for Lat/Lon input and refining positions. - Ask Steve for his code. - -* Check on styles properly loading for printed reports - -* Set table headers to not scroll in admin areas - -* Add property search field for Inventory list summary screen - -* Add delete functions to dataAbstract.php and appropriate admin areas - ***DONE*** Contacts - Events - Event Fees & Taxes - State Reps - Divisions - Teams - ***DONE*** Inventory ( this is done in inventory edit - now checking for room blocks first ) - Properties - Property Fees & Taxes - Property Accommodations - -* Reports - Complete basic reports - ***DONE*** Room block Reports - Room Requests - Reservations - Finance - -* Help - complete help texts and Quickhelp popups - -* When inventory is added, see if it's easy to have the inventory summary at the top scroll to the selected property - -* Build default teams using "Division" names when a division or State rep is added - -* Add ability to include sort links at top of tables - -* Add demographics info to reports - -* Auto-generate default "access codes" (currently "Team code") to produce rational password style string - {word}{nnn}{word} kind of password - -* Auto-generate team records when state-division is added - -* Check for and fix "&" in Room Block Report - -RESERVATIONS FRONT-END - -* System does not handle the situation where all of the inventory for an event is well outside the date range of the event. - (See similar issue for admin area above). If this happens it should not break but rather show no properties available. - -* Accommodations image problem - -* Add support for Fee/Tax guest optional items and optional quantities. - -* Check for earliest possible reservation date and display that instead of link to event on event selection page if it's not time to reserve yet. - -* Room Blocks Front-end lists, include fees/taxes in property detail pages just below room-blocks list. - -* Move fees/taxes on property detail page, to just below accommodation selection - Move "Add Selected Accommodation" button to bottom of list. - -* Mage sure "Must arrive by" and "Must not depart before" dates are displayed correctly and that default arrive/depart search dates are correct. - -* Add "Must arrive by" and "Must not depart before" dates to Event Selection screen - -* Keep pending reservations selections (on hold) from being reserved by others - -* Need to deal with checkout problem where there might be more than one room block that matches the same accommodation and team. - Currently not able to distribute consumption of rooms between multiple room blocks where the conv, state, team, and accomodation all match. - -* Make sure reservations respect - req_stay_arrive - req_stay_depart dates - ***DONE*** open_res_date - cutoff_date - -* Setup default and custom E-Mail message templates (by event) for sending to visitor on making the reservation. (file in this directory) - -* Check "OK to send" setting. Make sure it's respected on checkout - -* Check cart to make sure that there is availability for all cart entries - Currently only checking each separately - Consider combining same accommodation to make one entry - -* Add check-in and check-out times to conf E-Mail to visitors - -* On property profile (unit selection) page add the following: - Room Amenitites - Distance from Event - Consider moving number of rooms, credit card data to right had side as in main site - Make sure all appropriate data displayed in main site member profile pages is displayed - Consider moving description to below room list to minimize scrolling - Consider making profile page and property selection page similar - -* Check to make sure any session timeout is handled properly. - -* Reservations submitted E-Mail messages need to be customizable by event. - -* E-Mail sent when submitting reservation should include driving directions - -* Fix arrive_date stored with reservation request - -* Add storage of fees summary into reservations request then fix reservations reports to use that data - -MEMBERS FRONT-END - -* Fix problem with editing reservation dates and such. - Note that line with "calc_unit_totals()" call has been commented out. - -* Complete processing of accommodation quantity and date changes when updating a reservation. - Check again for availability - Rebuild summary - Note changes in Notes field. - -* Fix "fudged" min and max reservations available dates for modifying reservations - Should be based on actual availability for each accommodation - -* Create "print" option for printing out reservation detail for a selected reservation. - -* Change to appearance similar to back-end tables - -* Add copy of policies to reservation confirmation E-Mail - -* When declining reservations do not send E-Mail to visitor, only send E-Mail to event contacts (King Comm.) - -* Check reservations daily(hourly?) and send warning notices of unconfirmed reservations (see conf_hours) to members and summary to event contacts. - -* Confirmation E-Mail messages need to be customizable by event. - Need to be able to say whether credit card will be charged upon reservation or at checkin. - -* Change conf message to HTML and use view file - -* Driving directions link on Confirmation E-Mail - -* Ability to edit reservations dates - When storing, update all inventory and room block availability numbers - Recalculate all charges, fess, and totals - Update reservation record with new data - Add to notes for this reservations record how it was modified - -STATE-REP ROOM BLOCK SUMMARY - - - -OTHER NOTES ON USE - -Info on sending test message to properties for a specific event ---------------------------------------------------------------- -* Enter front-end reservations as a team or regular visitor. -* Select accommodations for a single property -* Proceed to checkout -* Under "Billing Information" in the "First Name" field enter "Event Test Property Message" -* Fill out rest of information and submit - You may use the 0011001100110011 pseudo creadit card number -* System will produce a single test message to the "cscott@gaslightmedia.com" address for testing this mode -* To have the test message sent to all properties associated with the selected event enter "Production Mode" in the "Last Name" field. -* Messages will contain - - "John Doe" information for the billed party - - Will be addressed to each property - - Will NOT contain any of the credit card information submitted - - Will contain the exact selected reservations summary and totals selected in the cart - - Will NOT clear the cart or create an actual reservation - - -PHASE 2 WORK - -* Property defines cut-off date for reservations if not defined in Event - - - - -How to delete an entire event ------------------------------ - -Delete data in this order - -Table Link to Link field ------------------------ --------------- ------------------------------------------- - SELECT id, name, conv_code, start_date, end_date FROM convention; -team_roster team team = {team for specified event} - DELETE FROM team_roster WHERE team IN (SELECT id FROM team WHERE conv = {CONV ID}); -team_property convention conv = {convention} - DELETE FROM team_property WHERE conv = {CONV ID}; -team convention conv = {convention} - DELETE FROM team_property WHERE conv = {CONV ID}; -state_rep convention conv = {convention} - DELETE FROM state_rep WHERE conv = {CONV ID}; -division convention conv = {convention} - DELETE FROM division WHERE conv = {CONV ID}; -room_block convention conv = {convention} - DELETE FROM room_block WHERE conv = {CONV ID}; -room_block_seg convention conv = {convention} - DELETE FROM room_block_seg WHERE conv = {CONV ID}; -inven_hold inventory inventory = {inv for specified event} - DELETE FROM inven_hold WHERE inventory IN (SELECT id FROM inventory WHERE conv = {CONV ID}); -inventory convention conv = {convention} - DELETE FROM inventory WHERE conv = {CONV ID}; -res_contact ??? -reservation convention conv = {convention} - DELETE FROM reservation WHERE conv = {CONV ID}; -fees convention affiliation_type = 1, owner = {convention} - DELETE FROM fees WHERE affiliation_type = 1 AND owner = {CONV ID}; -conv_prop_dist convention convention = {convention} - DELETE FROM conv_prop_dist WHERE convention = {CONV ID}; -event_prop convention event = {convention} - DELETE FROM event_prop WHERE event = {CONV ID}; -convention - DELETE FROM convention WHERE id = {CONV ID}; - - diff --git a/legacy/docs/Field Specifications b/legacy/docs/Field Specifications deleted file mode 100755 index 05784ab..0000000 --- a/legacy/docs/Field Specifications +++ /dev/null @@ -1,271 +0,0 @@ -Field Definitions Specification - -Fields are specified using an array of field specification arrays. - -Sample: - - $this->fields = array( - - // Record ID - 'id' => array( - 'field' => 'id', - 'as' => false, - 'type' => 'integer', - 'filter' => 'int', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ), - - // Name of event - 'name' => array( - 'field' => 'name', - 'as' => false, - 'type' => 'text', - 'filter' => 'string', - 'required' => true, - 'unique' => true, - 'default' => false, - 'use' => 'a' - ) - - ); - - -The index for fields must be unique, but three may be multiple entries for a -single field ('field') in the database table. - - -Field Specifications: - -(array index) The array index is only used to permit multiple entries for the - same database field. This permits including the field several - times so it can be processed differently based on the operation - being performed or can be displayed multiple time but each in a - different way. - -'field' Name of field in database table - -'as' Name to use for this field for all operations other than for talking - with the database. Doing this keeps any possible multiple instances - of use of a single database field separate. (see array index above) - - If this is not specified, then the actual database field name is - used for these purposes. - - -'type' Type of field - Possible field types are... - - 'integer', - 'float', - 'money', - 'percent', - 'pointer', - 'list', - 'bitmap', like list but permits multi-pick - 'text', - 'checkbox', - 'email', - 'date', - 'time', - 'phone', - 'image', - 'latitude', Data is an array of (dir,deg,min,sec); - 'longitude' " " " - "dir" is - for West and South - -'filter' Optional filter - See PHP filter_input() "filter" parameter. - Currently only for type "text" - FILTER_SANITIZE_FULL_SPECIAL_CHARS does not seem to be defined at this time. - -'filter_options' Optional filter options - See PHP filter_input() "options" parameter. - Currently only for type "text" - -'required' If set and true, field data must be supplied - -'unique' If set and true, must be a unique value - -'default' If set and true use this value as the default for input fields. - Dates/times are expected to be timestamps - There is no default image capability - -'use' Character(s) that indicate which operations to use this field with. - - l = Listing records - g = Get - Displaying a record - n = Setup input for a new record - i = Insert new record - e = Edit an existing record - u = Update an edited record - d = Ask for verification of deletion of a record - c = Confirm delete and delete record. - a = All above operations - -'minValue' Minimum acceptable value (numeric) - Dates are specified as timestamp - -'maxValue' Maximum acceptable value (numeric) - Dates are specified as timestamp - -'p_table' Table to get related data from for pointer types - -'p_field' Field to get related data from for field types - -'p_id' name of ID field in related data table - -'p_where' Additional WHERE clause for getting possible values from related table. - -'p_from' Additional FROM tables for getting possible values from related table. - See example in dataMembers.php - -'p_blank' If set or true provide a "blank" option for pointer input - -'p_sort' Optional ORDER BY sort clause (i.e. "name, age DESC") - May not be functional yet. - -'p_orderby' Optional "ORDER BY" clause for results from table pointed to by pointer - -'p_autoadd' Option to permit the addition of a new entry using a text input field - -'p_sum' If true causes a numeric sum of all returned values from the target table/column - -'p_static' A static pointer that does not do a lookup for a list of values, only a single value reference - -'output_type' Optional type to use for output. Useful with pointers. - -'latlon_type' Optional specification for lat/lon output (DMS, DM, or D) - -'view_only' View only field, do not check for input or store, only provide data from record. - -'list' Required with field type 'list' - includes simple array where... - array key is value for option - array value is name for option - -'bitmap' Required with field type 'bitmap' - includes array of (position, name) for each option - array key is a value indicating the bit position (i.e. 1, 2, 3, 4) starting with 1 rather than 0 (it will be converted) - array value is the name for the option - -'list_keytype' Type of key field (default is 'text') - 'text' A Text key - expects a text field in the database - 'int' An Integer key - expects a numeric field in the database - -'output_format' Optional output format specification as would be used in printf() - Use only the actual format and not the type identifier (i.e. "02.2" rather than "%f02.2") - -'no_stripslashes' Don't strip slashes when recalling this field from the database. - -'quicktip' Text description of this field and its use. - - -Data specification for various types ------------------------------------- - -Type 'list' - - Return data - - array( - 'list' => array( - array('name' => {name}, 'value' => {value}, 'default' => {true if default or selected}, - .... - ), - 'value' => {value of selected option}, - 'name' => {name of selected option} - ) - -Type 'bitmap' - - Return data - - array( - 'bitmap' => array( - array('name' => {name}, 'value' => {value}, 'default' => {true if default or selected}, - .... - ), - 'value' => {value of selected option}, - 'names' => array( {simple list of names of selected options} ) - ) - -Type 'date' - - Input data fields - - When using single input text field, input field is name of field - - When using separate M, D, Y picklist or input fields - - '{field}_month' - '{field}_day' - '{field}_year' - - Return data - - array( - 'date' => {text date}, - 'timestamp' => {timestamp}, - 'date_list' => array( - 'month' => {picklist array}, - 'day' => {picklist array}, - 'year' => {picklist array} - ), - ) - -Type 'time' - - Input data fields - - When using single input text field, input field is name of field - - When using separate H, M picklist or input fields - - '{field}_hour' - '{field}_min' - '{field}_ampm' - - - Return data - - array( - 'time' => {text time}, - 'time_list' => array( - 'hour' => {picklist array}, - 'min' => {picklist array}, - 'ampm' => {picklist array} - ), - ) - - -Types 'latitude' & 'longitude' - - Return data - - array( - 'dir' => {direction: -1 = S or W, +1 = N or E}, - 'dir_list' => array( - array('name' => 'N', 'value' => 1, 'default' => {true if default or selected}), - array('name' => 'S', 'value' => -1, 'default' => {true if default or selected}) - ), - 'deg' => {degrees}, - 'min' => {minutes}, - 'sec' => {seconds} - ) - - -Type 'image' - - Input fields - - '{field}_delete' Name of checkbox field to delete image - '{field}_new' Name of file input field to save new image - - -Type 'picklist' - - Parameters for {picklist array} - - 'name' Name to use for this option - 'value' Value to return when this option is selected - 'default' True if this option is currently selected - - - diff --git a/legacy/docs/Install.txt b/legacy/docs/Install.txt deleted file mode 100755 index 254f460..0000000 --- a/legacy/docs/Install.txt +++ /dev/null @@ -1,226 +0,0 @@ -Install Instructions - -* This version of Event Management is a New Common App so it's in /var/www/server/CommonApps/EventManagement_V? - -* Add the following files/directories if they don't already exist - - /common Directory containing symbolic links to a "web" directory in a common application - If creating directory, set svn:ignore for all files below that directory. - - /admin/EventManagement Directory containing a file to kick off EventManagement admin functions - /config/applications Directory containing ini files for specific applications - -* Add the following symbolic links in the Web site /common directory - - ln -s /var/www/server/CommonApps/EventManagement_V{version}/web EventManagement - ln -s /var/www/server/CommonApps/Public Public - touch Only_symbolic_links_in_this_directory-do_not_add_to_repository - -* Copy the contents of the docs/admin/EventManagement directory to /admin/EventManagement - -* Copy the contents of docs/config/applications directory to /config/applications - -* Check if the contents of docs/Barcode already exist in "/usr/share/fonts/truetype/barcode". - If not, copy docs/Barcode to /usr/share/fonts/truetype/barcode - -* Edit site's /config/application.ini. - - Make sure the following is near the top of the file - - ; CommonApps configuration - commonApps.base_path = "/var/www/server/CommonApps/" - - Remove any any old configuration for EventManagement and add the following - - ; Turn the events management application On or Off - event_management.application = On - event_management.version = "EventManagement_V3" - -* Make sure site loads jquery - -* Create a Toolbox page for the EventManagement front-end and note catid - -* Create a Toolbox page for the EventManagement Member's login and note catid - -* Add eventmgt schema to database - data/EventManagement.sql - -* Edit /admin/nav.phtml and add the following - - if (defined('EVENT_MANAGEMENT') && EVENT_MANAGEMENT) { - $nav['Event Management'] = BASE_URL.'admin/EventManagement/EventManagement.php'; - } - -* Edit /config/applications/EventManagement.ini and set at least - - "home_page", "members_only_page" with ID's for pages created above - -* Make sure there's not reference to a "reservations" schema in /Toolkit/Database.php - -* Create file in /static directory for the front-end catid with the following... - - commonApps->base_path.$GLOBALS['applicationConfig']->event_management->version.'/controllers/FrontController.php'; - $html = new EventManagementIndexController($GLOBALS['applicationConfig'], $GLOBALS['serverConfig'], $GLOBALS['siteConfig']); - ?> - -* Create file in /static directory for the admin login catid with the following... - - event_management->version.'/controllers/AdminController.php'; - ?> - -* Check to make sure site has owner information in the config/site.ini file. - - ; Web Site Owner Information - for use by certain applications - owner.name = "Gaslight Media" - owner.short_name = "GLM" - owner.address1 = "120 E. Lake St." - owner.address2 = False - owner.city = "Petoskey" - owner.state = "MI" - owner.zip = "49770" - owner.country = "US" - owner.phone = "231-487-0692" - owner.toll_free = False - - -HEREHERHRHERHERHE - - - -// **************** below is OLD *********************** - -* Add the contents of the documentation/config/application.ini file to /config/application.ini - -* Add a page for the Event Reservations front-end and note the catid - -* Add a page for the members only area Event Housing and note the catid - -* Update the following files to include the necessary references to Event Management - For old sites without ini files and schemas use replacements in Old sites below. - - /setup.phtml - - /** - * Site has Event Management - */ - define('EVENT_MANAGEMENT', $applicationConfig->event_management->application); - define('EVENT_MANAGEMENT_HOME_PAGE', $applicationConfig->event_management->home_page); - define('EVENT_MANAGEMENT_MEMBERS_PAGE', $applicationConfig->event_management->members_only_page); - - -; Turn the events management application On or Off -event_management.application = On -event_management.common_apps = "/var/www/server/CommonApps/" -event_management.base_path = "/var/www/server/CommonApps/EventManagement_V3/" -; The page id in the toolbox that is the entry page for Event management - Generally set for each server -event_management.home_page = 130 -event_management.members_only_page = 131 - - - ; Turn the events management application On or Off - event_management.application = On - ; The page id in the toolbox that is the entry page for Event management - Generally set for each server - event_management.home_page = 239 - event_management.members_only_page = 240 - - ************ NOT NEEDED ANY MORE ************ - /Toolkit/Database.php in _setSearchPath() function - *** Only if site already has schemas!!! *** - - if (defined('EVENT_MANAGEMENT') && EVENT_MANAGEMENT) { - // define event management search path - $stmt->bindValue(':schema', 'reservations', PDO::PARAM_STR); - $stmt->execute(); - } - ********************************************* - - /admin/nav.phtml - - if (defined('EVENT_MANAGEMENT') && EVENT_MANAGEMENT) { - $nav['Event Management'] = 'admin/EventManagement/EventManagement.php'; - } - - /static/{front-end-page} - - - - /static/{member-admin-page} - - - -* Fix member login problem with some sites. - - /memberdb/index.php -- Move logout before auth start - - $memberAuth =& new Toolkit_Members_Auth($root, 'DB', array(), '', false); - $memberAuth->setIdle(); - if (isset($_GET['logout']) || isset($_POST['doLogin'])) { - $memberAuth->logout(); - } - $memberAuth->start(); - - /memberdb/classes/class_user.inc -- Add user name to logout button. - - $out .= '
  • User:  '.$_SESSION['_authsession']['username'].'
    Log Out
  • '; - - -* Old sites that don't have ini files and schemas - - /setup.phtml - - /** - * Site has Event Management - */ - define('EVENT_MANAGEMENT', true); - define('EVENT_MANAGEMENT_HOME_PAGE', 0); - define('EVENT_MANAGEMENT_MEMBERS_PAGE', 0); - define('EVENT_MANAGEMENT_LEGACY_SITE', true); - - - /static/{front-end-page} - - prepare($sql); - $stmt->execute(); - - $html = new Toolkit_EventManagement_EventManagement($dbh); - - ?> - -* Edit /Toolkit/EventManagement/config.ini to set the customer's information - -* Add page catid for all pages that should be secure to "$securePagesArray = array(12,33);" in setup.phtml - -* Optionally to have a seprate style for this site copy Legacy/styles.css to virtual server directory /Toolkit/EventManagement/styles.css - - - - \ No newline at end of file diff --git a/legacy/docs/ProgramFlow.txt b/legacy/docs/ProgramFlow.txt deleted file mode 100755 index 51a96b1..0000000 --- a/legacy/docs/ProgramFlow.txt +++ /dev/null @@ -1,83 +0,0 @@ -Event Management - -NEED TO UPDATE FOR VERSION 3 - - -Notes: - -* If there is an /admin/EventManagement/templates directory, the application will look for - templates there. Otherwise it will use the standard set in {app}/Common/EventManagement_V2/admin/templates - - -General Program Flow and Class Organization -------------------------------------------- - -Directories & Components - -Toolkit/EventManangement - - Contains all setup, configuration, and libraries for application - -Toolkit/EventManagement/data - - Contains all Libraries for access to data - - dataAbstract.php - - Abstract class for all access to data - - Methods for processing input and output for all standard field types - Method to build queries from field specification tables - Methods for all standard data operations - - getStats() Get record counts of various types - getList() Get list of records for a particular table - getEntry() Get record detail for an entry in a table - newEntry() Prepare data to ask for detail for a new table entry - insertEntry() Add new detail entry to table - editEntry() Prepare data for edit of entry - updateEntry() Update data for an entry - deleteEntry() Prepare data for confirmation to delete and entry - deleteConfirmEntry() Delete an entry if confirmed - - data{app}.php - i.e. dataEvents.php, dataMembers.php, ... - - Data support class for a specific application - such as handing event data or member data - - Field definitions and specifications for a particular table or related group of tables - Methods for handling data from these tables for various types of operations. - i.e. Stats, List, ... - Whenever possible, these methods should try to use methods in the abstract class - to support these operations. - Methods for handling operations unique to this specific application. - - -admin/EventManagement - - Contains code specific to the admin section for this applicaiton. - Whenever possible this code should use the classes in the "Toolkit/EventManagement/Data" - directory to support the admin actions. - -admin/EventManagement/EventManagement.php - - Main code section for the admin section - -admin/Eventmanagement/classes - - Contains all class libraries for performing data retrieval and storage. - Whenever possible should use the "data" classes in "Toolkit/EventManagement/data" for - data storage and retrieval by calling the "data{app}.php" base classes. - - - - -Admin - - /admin/nav.phtml - /admin/EventManagement/EventManagement.php - /setup.phtml - /Toolkit/EventManagement/config.ini - /admin/EventManagement/classes/{} - where {} = events.php, ... - /Toolkit/EventManagement/data/data{} - where {} is same as above - /Toolkit/EventManagment/data/dataAbstract.php - diff --git a/legacy/docs/Sites_Using.txt b/legacy/docs/Sites_Using.txt deleted file mode 100755 index e7b1db5..0000000 --- a/legacy/docs/Sites_Using.txt +++ /dev/null @@ -1,6 +0,0 @@ -Sites_Using.txt ---------------- - -File depreciated - -See: CommonApps/EventManagement/V3/Notes/Sites_Using.txt \ No newline at end of file diff --git a/legacy/docs/Streamlined Ticketing for Star Line.odg b/legacy/docs/Streamlined Ticketing for Star Line.odg deleted file mode 100755 index 085cd94..0000000 Binary files a/legacy/docs/Streamlined Ticketing for Star Line.odg and /dev/null differ diff --git a/legacy/docs/Testing Notes.txt b/legacy/docs/Testing Notes.txt deleted file mode 100755 index 321b96f..0000000 --- a/legacy/docs/Testing Notes.txt +++ /dev/null @@ -1,12 +0,0 @@ -Testing Notes - -Checkout Test options - -This parameter is required for any test option below - Last name: GLM TEST ONLY - -Do not store the reservation result - First name: GLM DO NOT STORE - -Do not clear the cart cookie - Address (line 1): GLM DO NOT CLEAR diff --git a/legacy/docs/Toolkit/EventManagement/EventManagement.php b/legacy/docs/Toolkit/EventManagement/EventManagement.php deleted file mode 100644 index b23162e..0000000 --- a/legacy/docs/Toolkit/EventManagement/EventManagement.php +++ /dev/null @@ -1,19 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: EventManagement.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://housing.gaslightmedia.com/admin/ - */ - -echo "NEED TO FIGURE THIS OUT ..."; exit; -require_once GLM_APP_BASE.'Common/EventManagement_V2/Legacy/EventManagement.php'; - -?> \ No newline at end of file diff --git a/legacy/docs/Toolkit/EventManagement/MembersEventManagement.php b/legacy/docs/Toolkit/EventManagement/MembersEventManagement.php deleted file mode 100644 index f833df0..0000000 --- a/legacy/docs/Toolkit/EventManagement/MembersEventManagement.php +++ /dev/null @@ -1,57 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: EventManagement.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://housing.gaslightmedia.com/admin/ - */ - - -// Check for an old site that doesn't have a proper autoloader or $dbh defined. -if (defined('EVENT_MANAGEMENT_LEGACY_SITE')) { - - /* DEPRECIATED ALERT */ - echo ' -

    Depreciated: EVENT_MANAGEMENT_LEGACY_SITE

    -

    See: CommonApps/EventManagement_V?/admin/EventManagement.php

    - '; - $backtrace = debug_backtrace(); - echo 'Processes back-trace: (in return order)
    - - - '; - foreach($backtrace as $b) { - echo ' - - '; - } - echo '
    FileLineFunctionClass
    '.$b['file'].''.$b['line'].''.$b['function'].''.$b['class'].'
    '; - exit; - /* END DEPRECIATED ALERT */ - - $dbh = Toolkit_Database::getInstance(); - $sql = "set search_path = reservations,public;"; - $stmt = $dbh->prepare($sql); - $stmt->execute(); - - set_include_path(get_include_path().':'.GLM_APP_BASE.'glmPEAR'); - set_include_path(get_include_path().':'.GLM_APP_BASE.'glmZend/1.10.2/library'); - set_include_path(get_include_path().':'.GLM_APP_BASE.'glmZend/1.10.2/library/Zend/Config'); - set_include_path(get_include_path().':'.GLM_APP_BASE.'Common/EventManagement_V2/Legacy/classes'); - include_once('Ini.php'); - - require_once GLM_APP_BASE.'Common/EventManagement_V2/Legacy/classes/GeoCalculations.php'; - require_once(GLM_APP_BASE.'Common/EventManagement_V2/Legacy/EventManagement.php'); -} - -echo "NEED TO FIGURE THIS OUT..."; exit; -require_once GLM_APP_BASE.'Common/EventManagement_V2/Legacy/Members/index.phtml'; - -?> \ No newline at end of file diff --git a/legacy/docs/Toolkit/EventManagement/NOT_SURE_ABOUT_THIS_STUFF_MIGHT_NOT_BE_USED b/legacy/docs/Toolkit/EventManagement/NOT_SURE_ABOUT_THIS_STUFF_MIGHT_NOT_BE_USED deleted file mode 100755 index e69de29..0000000 diff --git a/legacy/docs/VenueAdminGuide.odt b/legacy/docs/VenueAdminGuide.odt deleted file mode 100755 index 954d31a..0000000 Binary files a/legacy/docs/VenueAdminGuide.odt and /dev/null differ diff --git a/legacy/docs/admin/EventManagement/EventManagement.php b/legacy/docs/admin/EventManagement/EventManagement.php deleted file mode 100755 index c655301..0000000 --- a/legacy/docs/admin/EventManagement/EventManagement.php +++ /dev/null @@ -1,19 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: EventManagement.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once '../../setup.phtml'; -require_once $applicationConfig->commonApps->base_path.$applicationConfig->event_management->version.'/controllers/AdminController.php'; - -?> \ No newline at end of file diff --git a/legacy/docs/barcode/FRE3OF9X.TTF b/legacy/docs/barcode/FRE3OF9X.TTF deleted file mode 100644 index 1223b01..0000000 Binary files a/legacy/docs/barcode/FRE3OF9X.TTF and /dev/null differ diff --git a/legacy/docs/barcode/FREE3OF9.TTF b/legacy/docs/barcode/FREE3OF9.TTF deleted file mode 100644 index 513afef..0000000 Binary files a/legacy/docs/barcode/FREE3OF9.TTF and /dev/null differ diff --git a/legacy/docs/barcode/FREE3OF9.TXT b/legacy/docs/barcode/FREE3OF9.TXT deleted file mode 100644 index 0112dea..0000000 --- a/legacy/docs/barcode/FREE3OF9.TXT +++ /dev/null @@ -1,71 +0,0 @@ ------BEGIN PGP SIGNED MESSAGE----- -Hash: SHA1 - -Font: Free 3 of 9 Barcode (free3of9.ttf) -Created By: Matthew Welch -E-Mail: daffy-duck@worldnet.att.net -Web Address: http://home.att.net/~daffy-duck - (PGP public key available here) - -Free 3 of 9, like all of my fonts, is free. You can use it for most -personal or business uses you'd like, and I ask for no money. I -would, however, like to hear from you. If you use my fonts for -something please send me a postcard or e-mail letting me know how -you used it. Send me a copy if you can or let me know where I can -find your work. - -You may use this font for graphical or printed work, but you may not -sell it or include it in a collection of fonts (on CD or otherwise) -being sold. You can redistribute this font as long as you charge -nothing to receive it. If you redistribute it include this text file -with it as is (without modifications). - -If you use this font for commercial purposes please credit me in -at least some little way. - -About the font: - -Can you believe there are people who would charge you for a barcode -font like this? It took very little time to make this so I thought -I'd donate it to the world. It is suitable for scanning even at -fairly small point sizes (with a laser printer). I have tested -printed copies of this font with a couple different scanners and it -worked perfectly. - -This is 3 of 9 (sometimes called "code 39"), a widely used barcode -standard that includes capital letters, numbers, and several symbols. -This is not the barcode for UPC's (universal price codes) found on -products at the store. However, most kinds of barcode scanners will -recognize 3 of 9 just fine. - -To create a valid 3 of 9 barcode you have to begin and end it with -a special character. Scanners look for this character to know -where to start and stop reading the barcode. It is represented in -this font with the '*' character. So, to create a barcode for the -text "ABC123" you have to type out "*ABC123*". Note that barcode -readers will not include the *'s in the text they return. They will -just give you the "ABC123". - -Two versions of 3 of 9 are included. The font called "Free 3 of 9" is -the basic 3 of 9 standard. It includes letters and these symbols: $ % -+ - . and /. The font called "Free 3 of 9 Extended" covers the -extended 3 of 9 standard. It includes all the ASCII characters. - -Special note to MS Word users: There is a default setting in Word -that changes text surrounded by *'s into bold text. This setting must -be disabled for these fonts to work, otherwise the * characters that -are necessary for the barcode to scan properly will be lost and the -thickness of the bars will be altered. I have a copy of Word '97. The -setting might be found in a different place in other versions but -this is how I disabled it. From the Tools menu open the AutoCorrect -dialog box. On the AutoFormat tab uncheck the box for "*Bold* and -_underline_" - - ------BEGIN PGP SIGNATURE----- -Version: PGPfreeware 6.5.8 for non-commercial use - -iQA/AwUBOmY8/uEM8BJ4ZA+2EQLSDgCgqHT1WtBW34v7JAQr4+1zCzUaeGgAn2uu -stjL0d7RVR5C5p2zpks371e9 -=jqNv ------END PGP SIGNATURE----- diff --git a/legacy/docs/config.ini.SAMPLE b/legacy/docs/config.ini.SAMPLE deleted file mode 100755 index d49e692..0000000 --- a/legacy/docs/config.ini.SAMPLE +++ /dev/null @@ -1,664 +0,0 @@ -; -; Travel Information System -; -[common] - -applicationName = "Event Housing" - -; -; *** General Configuration for Event Housing System *** -; - -; Base URL/paths for front-end of this application -url.front_end = CURRENT_BASE_URL "/Toolkit/Event_Housing-" EVENT_HOUSING_HOME_PAGE "/" -url.admin = CURRENT_BASE_URL "/admin/Event_Housing/" -path.front_end = BASE_PATH "/Toolkit/Event_Housing/" -path.admin = BASE_PATH "/admin/Event_Housing" - -; Interface Selection -default_admin_interface = "panels" -admin_interface.panels = "panels" - - -; Basic Customer Information -customer.name = "Great Lakes Bay" -customer.long_name = "Great Lakes Bay Regional Convention & Visitiors Bureau" -customer.phone = "989-752-7164" -customer.fax = "" -customer.toll_free = "800-444-9979" -customer.address = "515 N. Washington Ave., Third Floor" -customer.city = "Saginaw" -customer.state = "MI" -customer.zip = "48607" -customer.email = "cscott@gaslightmedia.com" -customer.internal_email = "cscott@gaslightmedia.com" -customer.from_email = "cscott@gaslightmedia.com" -customer.letter_closing = "Sincerely," - - -customer.assistance_info = " -If you need assistance within the administration area or have questions, please contact:
    -Gaslight Media Web Site Support Services at 231-487-0692 or -E-Mail us at info@gaslightmedia.com -" - -; General Travel Information System Options -option.member_db = "Integrated" ;Use Standard Member DB: Integrated = Use standard Member DB, Separate = Use Separate Member DB -option.conventions = true -option.reservations = false ;Enable Reservations for members (not event housing) -option.tickets = false ;Enable Ticket Sales -option.packages = false ;Enable Packages -option.housing = true ;Enable Event housing -option.registrations = false ;Enable Convention Registrations -option.tours = false ;Enable Tour Package Data -option.reservations = false ;Enable regular reservations -option.secret = "GLMTravelSecret" ;Secret Key used to create un-predictable values -option.admin_help = true ;Enable online help for member admin area -option.email_style = "text" ;Email to customer style = 'text', 'html', 'both', 'pdf', ... -option.promotions = false -option.member_edit = false -option.member_assistance = "For assistance call Great Lakes Bay Regional Convention & Visitiors Bureau at 989-752-7164." - -; Misc options -misc.letter_closing = "Sincerely," - -; Set Database Date Style - uncomment desired style -;misc.datestyle = "SET DATESTYLE TO 'ISO';" ;ISO example: 1997-12-17 07:37:16-08';\n" -misc.datestyle = "SET DATESTYLE TO 'SQL';" ;SQL example: 12/17/1997 07:37:16.00 PST';\n" -;misc.datestyle = "SET DATESTYLE TO 'Postgres';" ;Postgres example: Wed Dec 17 07:37:16 1997 PST';\n" -;misc.datestyle = "SET DATESTYLE TO 'European';" ;European example: 17/12/1997 15:37:16.00 MET';\n" -;misc.datestyle = "SET DATESTYLE TO 'US';" ;US example: 12/17/1997 07:37:16.00 PST';\n" -;misc.datestyle = "SET DATESTYLE TO 'German';" ;German example: 17.12.1997 07:37:16.00 PST';\n" - -; -; Event Housing specific parameters -; -housing.system_title = "Gaslight Media - Event Housing" -housing.select_method = "List" ;Method of selecting Conventions, "Pick" - Picklist, "List" - Detailed list -housing.sort_order = "Distance" ;Member list sort order ("Alpha", "Distance", "PseudoRandom", etc) -housing.hold_timeout = 10 ;Hold time in minutes for accommodations in process of being booked -housing.require_member_ccards = true ;Members must offer credit cards to make properties available for booking -housing.proc_method = "authorize" ;Cards processed by authorize.net (see proc_method below) -housing.inventory = true ;Enable Convention Housing Inventory -housing.golf = false ;Enable Convention Golf - -; Terms used to refer to events/conventions -housing.terms.event.norm = "event" -housing.terms.event.cap = "Event" -housing.terms.event.plur = "events" -housing.terms.event.plur_cap = "Events" - -; Terms used to refer to a housing Property/Hotel -housing.terms.prop.norm = "property" -housing.terms.prop.cap = "Property" -housing.terms.prop.plur = "properties" -housing.terms.prop.plur_cap = "Properties" - -; Terms used to refer to a housing unit -housing.terms.unit.norm = "accommodation" -housing.terms.unit.cap = "Accommodation" -housing.terms.unit.plur = "accommodations" -housing.terms.unit.plur_cap = "Accommodations" - -; -; General Reservations specific parameters -; -reservations.promotions = false ;Enable reservations promotions -reservations.hotel = true ;Hotel/Motel reservations -reservations.campground = false ;Campground reservations -reservations.bedandbreakfast = false ;Bed/Breakfast reservations -reservations.condo = false ;Condo/Home reservations -reservations.marina = false ;Marina reservations -reservations.max_days = 15 ;Maximum number of reservation days -reservations.max_rooms = 30 ;Maximum number of rooms reserveable at once - -; Calendar parameters -calendar.months_before = 2 -calendar.months_after = 24 -calendar.links_before = 1 -calendar.links_after = 1 - - -; -; Other misc site related setttings -; - -; Image information -image_server = "is0.gaslightmedia.com" -image_user = "greatlakesbayregion" -image_style.1 = "memberPhotos" -image_style.2 = "tbs1" -image_style.3 = "pgs2" - -; -; *** End of General Configuration for Event Housing System *** -; - -; Standard arrays - -; Processing Methods -proc_method.1 = merchant ;Merchant processes cards -proc_method.2 = authorize ;Processed by Authorize.net - -; Processing Status -proc_status.new = 0 -proc_status.descr.0 = "New Registration Record" -proc_status.unpaid = 1 -proc_status.descr.1 = "Not Paid" -proc_status.cc_pend = 2 -proc_status.descr.2 = "Credit Card Pending" -proc_status.cc_paid = 3 -proc_status.descr.3 = "Paid by Credit Card" -proc_status.cc_decl = 4 -proc_status.descr.4 = "Credit Card Declined" -proc_status.check_pend = 5 -proc_status.descr.5 = "Check Pending" -proc_status.check_paid = 6 -proc_status.descr.6 = "Paid by Check" -proc_status.comp = 7 -proc_status.descr.7 = "Complimentary" -proc_status.failed = 98 -proc_status.descr.98 = "Submission Failed" -proc_status.canceled = 99 -proc_status.descr.99 = "Canceled" - -; Payment Types -pay_types.1 = "Credit Card" -pay_types.2 = "Check" -pay_types.3 = "Direct" - -; Confirmation Methods -conf_methods.1 = "US Mail" -conf_methods.2 = "E-Mail" - -; Reference Types -reference_type.misc = 0 -reference_type.event = 1 -reference_type.property = 2 -reference_type.state = 3 -reference_type.team = 4 - -; Reference Type Numbers -reference_type_numb.0 = "Misc" -reference_type_numb.1 = "Event" -reference_type_numb.2 = "Property" -reference_type_numb.3 = "State Rep" -reference_type_numb.4 = "Team" - -; Fee Method -fee_method.fixed_stay = 1 -fee_method.fixed_accom = 2 -fee_method.fixed_accomnight = 3 -fee_method.percent_stay = 10 - -; Fee Method Numbers -fee_method_numb.1 = "Amount per Reservation" -fee_method_numb.2 = "Amount per Accommodation" -fee_method_numb.3 = "Amount per Accommodation/Night" -fee_method_numb.10 = "Percent of Room Rate" - -; Member/Property Amenities -; Static amenitities set system-wide -; Only 10 fields in member records for these at this time -; Needs to be replaced with managed amenities list -memb_amen.1 = "Air-Conditioning" -memb_amen.2 = "Barrier Free" -memb_amen.3 = "Coffee Pot" -memb_amen.4 = "Hair Dryer" -memb_amen.5 = "Interior Corridor" -memb_amen.6 = "Microwave" -memb_amen.7 = "Refrigerator" -;memb_amen.8 = "Shopping nearby" -;memb_amen.9 = "Indoor pool" -;memb_amen.10 = "Outdoor pool" -;memb_amen.? = "Sauna" -;memb_amen.? = "Whirlpool" -;memb_amen.? = "Valet/Charge Parking" -;memb_amen.? = "Self-operated coin laundry" -;memb_amen.? = "Free parking" -;memb_amen.? = "Fitness area" -;memb_amen.? = "Room service" -;memb_amen.? = "Conference/Meeting facilities" -;memb_amen.? = "Restaurant nearby" -;memb_amen.? = "Restaurant on site" -;memb_amen.? = "Barrier free guest rooms available" -;memb_amen.? = "Pets" -;memb_amen.? = "Golf nearby" - -; Accommodatation Amenitities -; NOT USED AT THIS TIME -;accom_amen.1 = "Cable TV" -;accom_amen.2 = "Movies in Room" -;accom_amen.3 = "Barrier Free Access" -;accom_amen.4 = "Smoke Free Room" -;accom_amen.5 = "Jacuzzi in Room" -;accom_amen.6 = "Iron and Ironing Board" -;accom_amen.7 = "Coffee Pot in Room" -;accom_amen.8 = "Refrigerator in Room" -;accom_amen.9 = "Microwave in Room" -;accom_amen.10 = "Safe" -;accom_amen.11 = "Hair Dryer" - -; Accommodation Room Categories -room_category.0 = "n/a" -room_category.1 = "Bed" -room_category.2 = "Room" -room_category.3 = "Suite" - -; Accommodation Room Types -room_types.0 = "n/a" -room_types.1 = "Main" -room_types.2 = "Bedroom" -room_types.3 = "Kitchen" -room_types.4 = "Living Room" - -; Accommodation Bath Types -bath_types.0 = "None" -bath_types.1 = "Full" -bath_types.2 = "Half" -bath_types.3 = "Sink" - -; States -states.AL = "Alabama" -states.AK = "Alaska" -states.AB = "Alberta" -states.AZ = "Arizona" -states.AR = "Arkansas" -states.BC = "British Columbia" -states.CA = "California" -states.CO = "Colorado" -states.CT = "Connecticut" -states.DE = "Delaware" -states.DC = "District of Columbia" -states.FL = "Florida" -states.GA = "Georgia" -states.GU = "Guam" -states.HI = "Hawaii" -states.ID = "Idaho" -states.IL = "Illinois" -states.IN = "Indiana" -states.IA = "Iowa" -states.KS = "Kansas" -states.KY = "Kentucky" -states.LA = "Louisiana" -states.ME = "Maine" -states.MB = "Manitoba" -states.MD = "Maryland" -states.MA = "Massachusetts" -states.MI = "Michigan" -states.MN = "Minnesota" -states.MS = "Mississppi" -states.MO = "Missouri" -states.MT = "Montana" -states.NE = "Nebraska" -states.NV = "Nevada" -states.NB = "New Brunswick" -states.NF = "Newfoundland" -states.NH = "New Hampshire" -states.NJ = "New Jersey" -states.NM = "New Mexico" -states.NY = "New York" -states.NC = "North Carolina" -states.ND = "North Dakota" -states.NT = "Northwest Territories" -states.NS = "Nova Scotia" -states.OH = "Ohio" -states.OK = "Oklahoma" -states.ON = "Ontario" -states.OR = "Oregon" -states.PA = "Pennsylvania" -states.PE = "Prince Edward Island" -states.PR = "Puerto Rico" -states.QC = "Quebec" -states.RI = "Rhode Island" -states.SK = "Saskatchewan" -states.SC = "South Carolina" -states.SD = "South Dakota" -states.TN = "Tennessee" -states.TX = "Texas" -states.UT = "Utah" -states.VT = "Vermont" -states.VI = "Virgin Islands" -states.VA = "Virginia" -states.WA = "Washington" -states.WV = "West Virginia" -states.WI = "Wisconsin" -states.WY = "Wyoming" -states.YT = "Yukon" - -; Countries -countries.US = "United States" -countries.CA = "Canada" -countries.AF = "Afghanistan" -countries.AX = "Land Islands" -countries.AL = "Albania" -countries.DZ = "Algeria" -countries.AS = "American Samoa" -countries.AD = "Andorra" -countries.AO = "Angola" -countries.AI = "Anguilla" -countries.AQ = "Antarctica" -countries.AG = "Antigua and Barbuda" -countries.AR = "Argentina" -countries.AM = "Armenia" -countries.AW = "Aruba" -countries.AU = "Australia" -countries.AT = "Austria" -countries.AZ = "Azerbaijan" -countries.BS = "Bahamas" -countries.BH = "Bahrain" -countries.BD = "Bangladesh" -countries.BB = "Barbados" -countries.BY = "Belarus" -countries.BE = "Belgium" -countries.BZ = "Belize" -countries.BJ = "Benin" -countries.BM = "Bermuda" -countries.BT = "Bhutan" -countries.BO = "Bolivia" -countries.BA = "Bosnia and Herzegovina" -countries.BW = "Botswana" -countries.BV = "Bouvet Island" -countries.BR = "Brazil" -countries.IO = "British Indian Ocean Territory" -countries.BN = "Brunei Darussalam" -countries.BG = "Bulgaria" -countries.BF = "Burkina Faso" -countries.BI = "Burundi" -countries.KH = "Cambodia" -countries.CM = "Cameroon" -countries.CV = "Cape Verde" -countries.KY = "Cayman Islands" -countries.CF = "Central African Republic" -countries.TD = "Chad" -countries.CL = "Chile" -countries.CN = "China" -countries.CX = "Christmas Island" -countries.CC = "Cocos (Keeling) Islands" -countries.CO = "Colombia" -countries.KM = "Comoros" -countries.CG = "Congo" -countries.CD = "Congo, the Democratic Rep. of" -countries.CK = "Cook Islands" -countries.CR = "Costa Rica" -countries.CI = "Cote D'Ivoire" -countries.HR = "Croatia" -countries.CU = "Cuba" -countries.CY = "Cyprus" -countries.CZ = "Czech Republic" -countries.DK = "Denmark" -countries.DJ = "Djibouti" -countries.DM = "Dominica" -countries.DO = "Dominican Republic" -countries.EC = "Ecuador" -countries.EG = "Egypt" -countries.SV = "El Salvador" -countries.GQ = "Equatorial Guinea" -countries.ER = "Eritrea" -countries.EE = "Estonia" -countries.ET = "Ethiopia" -countries.FK = "Falkland Islands (Malvinas)" -countries.FO = "Faroe Islands" -countries.FJ = "Fiji" -countries.FI = "Finland" -countries.FR = "France" -countries.GF = "French Guiana" -countries.PF = "French Polynesia" -countries.TF = "French Southern Territories" -countries.GA = "Gabon" -countries.GM = "Gambia" -countries.GE = "Georgia" -countries.DE = "Germany" -countries.GH = "Ghana" -countries.GI = "Gibraltar" -countries.GR = "Greece" -countries.GL = "Greenland" -countries.GD = "Grenada" -countries.GP = "Guadeloupe" -countries.GU = "Guam" -countries.GT = "Guatemala" -countries.GN = "Guinea" -countries.GW = "Guinea-Bissau" -countries.GY = "Guyana" -countries.HT = "Haiti" -countries.HM = "Heard Island, McDonald Islands" -countries.VA = "Holy see (Vatican City State)" -countries.HN = "Honduras" -countries.HK = "Hong Kong" -countries.HU = "Hungary" -countries.IS = "Iceland" -countries.IN = "India" -countries.ID = "Indonesia" -countries.IR = "Iran, Islamic Republic of" -countries.IQ = "Iraq" -countries.IE = "Ireland" -countries.IL = "Israel" -countries.IT = "Italy" -countries.JM = "Jamaica" -countries.JP = "Japan" -countries.JO = "Jordan" -countries.KZ = "Kazakhstan" -countries.KE = "Kenya" -countries.KI = "Kiribati" -countries.KP = "Korea, Democratic People's Rep. of" -countries.KR = "Korea, Republic of" -countries.KW = "Kuwait" -countries.KG = "Kyrgyzstan" -countries.LA = "Lao People's Democratic Republic" -countries.LV = "Latvia" -countries.LB = "Lebanon" -countries.LS = "Lesotho" -countries.LR = "Liberia" -countries.LY = "Libyan Arab Jamahiriya" -countries.LI = "Liechtenstein" -countries.LT = "Lithuania" -countries.LU = "Luxembourg" -countries.MO = "Macao" -countries.MK = "Macedonia, the Former Yugoslav Rep." -countries.MG = "Madagascar" -countries.MW = "Malawi" -countries.MY = "Malaysia" -countries.MV = "Maldives" -countries.ML = "Mali" -countries.MT = "Malta" -countries.MH = "Marshall Islands" -countries.MQ = "Martinique" -countries.MR = "Mauritania" -countries.MU = "Mauritius" -countries.YT = "Mayotte" -countries.MX = "Mexico" -countries.FM = "Micronesia, Federated States of" -countries.MD = "Moldova, Republic of" -countries.MC = "Monaco" -countries.MN = "Mongolia" -countries.MS = "Montserrat" -countries.MA = "Morocco" -countries.MZ = "Mozambique" -countries.MM = "Myanmar" -countries.NA = "Namibia" -countries.NR = "Nauru" -countries.NP = "Nepal" -countries.NL = "Netherlands" -countries.AN = "Netherlands Antilles" -countries.NC = "New Caledonia" -countries.NZ = "New Zealand" -countries.NI = "Nicaragua" -countries.NE = "Niger" -countries.NG = "Nigeria" -countries.NU = "Niue" -countries.NF = "Norfolk Island" -countries.MP = "Northern Mariana Islands" -countries.NO = "Norway" -countries.OM = "Oman" -countries.PK = "Pakistan" -countries.PW = "Palau" -countries.PS = "Palestinian Territory, Occupied" -countries.PA = "Panama" -countries.PG = "Papua New Guinea" -countries.PY = "Paraguay" -countries.PE = "Peru" -countries.PH = "Philippines" -countries.PN = "Pitcairn" -countries.PL = "Poland" -countries.PT = "Portugal" -countries.PR = "Puerto Rico" -countries.QA = "Qatar" -countries.RE = "Reunion" -countries.RO = "Romania" -countries.RU = "Russian Federation" -countries.RW = "Rwanda" -countries.SH = "Saint Helena" -countries.KN = "Saint Kitts and Nevis" -countries.LC = "Saint Lucia" -countries.PM = "Saint Pierre and Miquelon" -countries.VC = "Saint Vincent and the Grenadines" -countries.WS = "Samoa" -countries.SM = "San Marino" -countries.ST = "Sao Tome and Principe" -countries.SA = "Saudi Arabia" -countries.SN = "Senegal" -countries.CS = "Serbia and Montenegro" -countries.SC = "Seychelles" -countries.SL = "Sierra Leone" -countries.SG = "Singapore" -countries.SK = "Slovakia" -countries.SI = "Slovenia" -countries.SB = "Solomon Islands" -countries.SO = "Somalia" -countries.ZA = "South Africa" -countries.GS = "South Georgia, South Sandwich Islands" -countries.ES = "Spain" -countries.LK = "Sri Lanka" -countries.SD = "Sudan" -countries.SR = "Suriname" -countries.SJ = "Svalbard and Jan Mayen" -countries.SZ = "Swaziland" -countries.SE = "Sweden" -countries.CH = "Switzerland" -countries.SY = "Syrian Arab Republic" -countries.TW = "Taiwan, Province of China" -countries.TJ = "Tajikistan" -countries.TZ = "Tanzania, United Republic of" -countries.TH = "Thailand" -countries.TL = "Timor-Leste" -countries.TG = "Togo" -countries.TK = "Tokelau" -countries.TO = "Tonga" -countries.TT = "Trinidad and Tobago" -countries.TN = "Tunisia" -countries.TR = "Turkey" -countries.TM = "Turkmenistan" -countries.TC = "Turks and Caicos Islands" -countries.TV = "Tuvalu" -countries.UG = "Uganda" -countries.UA = "Ukraine" -countries.AE = "United Arab Emirates" -countries.GB = "United Kingdom" -countries.UM = "United States minor outlying islands" -countries.UY = "Uruguay" -countries.UZ = "Uzbekistan" -countries.VU = "Vanuatu" -countries.VE = "Venezuela" -countries.VN = "Viet Nam" -countries.VG = "Virgin Islands, British" -countries.VI = "Virgin Islands, U.S." -countries.WF = "Wallis and Futuna" -countries.EH = "Western Sahara" -countries.YE = "Yemen" -countries.ZM = "Zambia" -countries.ZW = "Zimbabwe" - -;HTML Area -htmlarea.enabled = true -htmlarea.setup_delay = 1000 -htmlarea.start_delay = 500 -htmlarea.plugs = " - editor.registerPlugin(CharacterMap); - editor.registerPlugin(ContextMenu); - editor.registerPlugin(ListType); - editor.registerPlugin(TableOperations); -" -htmlarea.toolbar = " - config.toolbar = - [ - [ - "fontname", - "fontsize", - "formatblock", - "space", - "bold", - "italic", - "underline", - "strikethrough", - "separator", - "subscript", - "superscript", - "separator", - "copy", - "cut", - "paste", - "space", - "undo", - "redo" - ], - [ - "justifyleft", - "justifycenter", - "justifyright", - "justifyfull", - "separator", - "lefttoright", - "righttoleft", - "separator", - "ListType", - "insertorderedlist", - "insertunorderedlist", - "separator", - "outdent", - "indent", - "separator", - "forecolor", - "hilitecolor", - "separator", - "inserthorizontalrule", - "createlink", - "inserttable", - "htmlmode", - "separator", - "popupeditor" - ] - ]; -" - -[production : common] -; Debugging and Testing parameters -option.preview = false ;Use "preview=1" in links to support preview feature -debug.level = 0 ;Debug level - 0=off -debug.view_parameters = false ;Display all View tags and information -debug.housing_query = false ;Display main housing query -debug.pricing = false ;Detailed information on pricing and cost calculations -debug.checkout = false ;Display checkout processing steps and data -debug.mail = false ;Display mail rather than send it -url.app = "app.gaslightmedia.com/" - -[development : common] -; Debugging and Testing parameters -option.preview = true ;Use "preview=1" in links to support preview feature -debug.level = 0 ;Debug level - 0=off -debug.view_parameters = false ;Display all View tags and information -debug.housing_query = false ;Display main housing query -debug.pricing = false ;Detailed information on pricing and cost calculations -debug.checkout = false ;Display checkout processing steps and data -debug.mail = faLse ;Display mail rather than send it -url.app = "dev52.gaslightmedia.com/app.gaslightmedia.com/" - -[chuck : common] -; Debugging and Testing parameters -option.preview = true ;Use "preview=1" in links to support preview feature -debug.level = 0 ;Debug level - 0=off, 1=Show Function Calls -debug.view_parameters = true ;Display all View tags and information -debug.housing_query = false ;Display main housing query -debug.pricing = false ;Detailed information on pricing and cost calculations -debug.checkout = true ;Display checkout processing steps and data -debug.mail = false ;Display mail rather than send it -url.app = "192.168.44.3/app.gaslightmedia.com/" diff --git a/legacy/docs/config/applications/EventManagement.ini b/legacy/docs/config/applications/EventManagement.ini deleted file mode 100644 index 7ef5dd1..0000000 --- a/legacy/docs/config/applications/EventManagement.ini +++ /dev/null @@ -1,227 +0,0 @@ -; EventManagement Application ini file - -[production] - -; Event Management V3 - -; The page id in the toolbox that is the entry page for Event management - Generally set for each server -application_page = 121 ;Page ID for this application -application_url = "order-tickets-online-6" ;Optional URL segment for application - -members_only_page = 122 ;Page ID for members only area -members_only_url = "members-only-area" ;Optional URL segment for members only area - -option.member_db_integrated = false ;Use Standard Member DB: true = Use standard Member DB, false = Use Separate Member DB -option.events = false -option.accommodations = false ;Enable Reservations for members (not event housing) -option.tickets = true ;Enable Ticket Sales - option.tickets_select_max = 50 ; Maximum ticket quantity that can be selected at a time -option.packages = false ;Enable Packages -option.teams = false ;Enable Team housing features -option.registrations = false ;Enable Convention Registrations -option.select_images = false ;Display venue, event, and other images on the selection pages - other than maps and such -option.cart_images = false ;Display venue, event, and other images on the cart page -option.cart_images = false ;Display venue, event, and other images on the cart page -option.checkout_images = false ;Display venue, event, and other images on the checkout page -option.cart_promotions = true ;Permit promoting other performances on cart page -option.users_access_all_members = true ;Member contact users can have access to all members data -option.ask_for_likely_date = false ;Ask user for a likely date they would use for non-date-specific tickets (in cart) -option.confirmation_voucher = 'link' ;How to handle voucher with confirmation E-Mail: Off, 'link', 'attached' - -jQueryLoaded = true ;Say whether jQuery is already loaded by the site -jQueryUiLoaded = true ;Say whether jQueryUI is already loaded by the site - -ticket_hold_time = 60 ;Time in minutes to hold tickets in a cart -session_timeout = 60 ;Time in minutes before session times out -admin_session_timeout = 1560 ;Time in minutes before admin session times out - -; Front-End Appearance Settings -default_front_interface = "tickets" -custom_css = false ;Should look for /css/EventManangement.css in customer site -voucher_design = "Generic" ;Design file to use for vouchers - See /models/vouchers directory -site_has_foundation = true ;Site already loads foundation - blocks loading in ticketing front-end header - -; Admin Appearance Settings -default_admin_interface = "tickets" - -; Ticket Selection Process Options -option.ticket_selection.start_at_cart = true ;Start with shopping cart - Used with cart-sticky items. -option.ticket_selection.show_tickets_on_start_page = true ;Should we show the tickets on the selection start page or just venues/performances -option.ticket_selection.force_section = false ;Always show section selection even if there's only one -option.ticket_selection.include_options_in_ticket_list = true ;Include ticket options in ticket selection list (date, quant, etc) -option.ticket_selection.select_entrance_on_consignment = true ;If selling a ticket on consignment and the user has to select a venu to purchase the - ; ticket from, if entrances are listed for a venu, use entrances for selection rather than - ; just venue. -option.ticket_selection.show_cart_sticky_items = true ;Enable/disable cart sticky items - -; Image Styles -image_style.default = "tbs1" -image_style.large = "ticketsLarge" -image_style.medium = "ticketsMedium" -image_style.small = "ticketsSmall" -image_style.thumb = "ticketsThumb" - -; Terms used to refer to events/conventions -term.event.norm = "event" -term.event.cap = "Event" -term.event.plur = "events" -term.event.plur_cap = "Events" - -; Terms used to refer to a housing Member/Property/Hotel -term.prop.norm = "location" -term.prop.cap = "Location" -term.prop.plur = "locations" -term.prop.plur_cap = "Locations" - -; Terms used to refer to contacts -term.contact.norm = "contact" -term.contact.cap = "Contact" -term.contact.plur = "contacts" -term.contact.plur_cap = "Contacts" - -; Terms used to refer to scan/claim locations -term.claim_location.norm = "claim location" -term.claim_location.cap = "Claim Location" -term.claim_location.plur = "claim locations" -term.claim_location.plur_cap = "Claim Locations" - -; Terms used to refer to a housing unit -term.unit.norm = "room" -term.unit.cap = "Room" -term.unit.plur = "rooms" -term.unit.plur_cap = "Rooms" - -; Terms used to refer to an entrance -term.entrance.norm = "dock" -term.entrance.cap = "Dock" -term.entrance.plur = "docks" -term.entrance.plur_cap = "Docks" - -; Terms used to refer to a section -term.section.norm = "section" -term.section.cap = "Section" -term.section.plur = "sections" -term.section.plur_cap = "Sections" - -; Terms used to refer to a performance -term.performance.norm = "category" -term.performance.cap = "Category" -term.performance.plur = "categories" -term.performance.plur_cap = "Categories" - -; Terms used to refer to a ticket -term.ticket.norm = "item" -term.ticket.cap = "Item" -term.ticket.plur = "items" -term.ticket.plur_cap = "Items" - -; Terms used to refer to an order -term.order.norm = "order" -term.order.cap = "Order" -term.order.plur = "orders" -term.order.plur_cap = "Orders" - -; Terms used to refer to a voucher -term.voucher.norm = "boarding pass" -term.voucher.cap = "Boarding Pass" -term.voucher.plur = "boarding passes" -term.voucher.plur_cap = "Boarding Passes" - -; Terms used to refer to a promotion -term.promo.norm = "promo code" -term.promo.cap = "Promo Code" -term.promo.plur = "promo codes" -term.promo.plur_cap = "Promo Codes" - -; Terms used to refer to an attendance -term.attendance.norm = "attendance" -term.attendance.cap = "Attendance" -term.attendance.plur = "attendance" -term.attendance.plur_cap = "Attendance" - -; Terms used to refer to an attendee -term.attendee.norm = "attendee" -term.attendee.cap = "Attendee" -term.attendee.plur = "attendees" -term.attendee.plur_cap = "Attendees" - -; Terms used to refer to an attendace log -term.attendance_log.norm = "attendance log" -term.attendance_log.cap = "Attendance Log" -term.attendance_log.plur = "attendance logs" -term.attendance_log.plur_cap = "Attendance Logs" - -; Terms used to refer to entering (attendance) -term.attendance_entering.norm = "entering" -term.attendance_entering.cap = "Entering" -term.attendance_entering.plur = "entering" -term.attendance_entering.plur_cap = "Entering" - -; Terms used to refer to the start of a performance (event) -term.performance_start.norm = "start of performance" -term.performance_start.cap = "Start of Performance" -term.performance_start.plur = "start of performances" -term.performance_start.plur_cap = "Start of Performances" - -; Terms used to refer to the end of a performance (event) -term.performance_end.norm = "end of performance" -term.performance_end.cap = "End of Performance" -term.performance_end.plur = "end of performances" -term.performance_end.plur_cap = "End of Performances" - -; Terms used to refer to Coupons (advertisements) for vouchers -term.coupon.norm = "voucher coupon" -term.coupon.cap = "Voucher Coupon" -term.coupon.plur = "voucher coupons" -term.coupon.plur_cap = "Voucher Coupons" - -; Terms used for front-end shop navigation buttons -;term.nav.show_selected = "Show Cart" -term.nav.show_selected = "Cart" -term.nav.select = "Select" -;term.nav.select_more = "Select More" -term.nav.select_more = "Shop" -;term.nav.select_more_of_these = "Select More of These" -term.nav.select_more_of_these = "More" -term.nav.add_to_cart = "Add to Cart" -term.nav.checkout = "Proceed to Checkout" -term.nav.purchase = "Click to Purchase Selected Items" -term.nav.print_vouchers = "Print Vouchers" -term.nav.delete_from_cart = "Delete these items from your cart" - -; Prompts used for shop checkout fields -text.cart.checkout.first_name = "First Name" -text.cart.checkout.last_name = "Last Name" -text.cart.checkout.address = "Address" -text.cart.checkout.city = "City" -text.cart.checkout.state = "State/Province" -text.cart.checkout.country = "Country" -text.cart.checkout.zip = "ZIP/Postal Code" -text.cart.checkout.phone = "Phone" -text.cart.checkout.email = "E-Mail Address" -text.cart.checkout.email_again = "Enter E-Mail Address Again" -text.cart.checkout.ok_to_send = "OK to Send E-Mail?" -text.cart.checkout.special_req = "" ; If blank, don't use -text.cart.checkout.activities_offers = "Please send information on activities and offers." - -; Other text used in the front end -text.cart.select_assignment_location = "Please select the dock you are going to depart from." -text.cart.select_likely_date = "Please select your likely departure date." ;For non-date-specific tickets - -; development server configuration data inherits from production and -; overrides values as necessary -[development : production] - -; chuck's server configuration data inherits from development -; and overrides values as necessary -[chuck : development] - - -; john's server configuration data inherits from development -; and overrides values as necessary -[john : development] - -; steve's server configuration data inherits from development -; and overrides values as necessary -[steve : development] - diff --git a/legacy/help.html b/legacy/help.html deleted file mode 100755 index af07d38..0000000 --- a/legacy/help.html +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - - -
    -

    Gaslight Media
    Event Management System

    -
    - -
    - - -

    General Description

    -

    - General description of system goes here. -

    - - -
    System Structure -

    - Discussion about system structure. -

    -
    - - -
    Non-Team Events -

    - Discussion about Non-Team Events. -

    -
    - - -
    Team Events -

    - Discussion about Team Events. -

    -
    - -
    -
    - - -

    Common Proceedures

    -

    - General description of common proceedures goes here. -

    - - -
    System Setup -

    - Discussion about setting up system information. -

    -
    - -
    - - - \ No newline at end of file diff --git a/legacy/index.html b/legacy/index.html deleted file mode 100755 index 2f069ce..0000000 --- a/legacy/index.html +++ /dev/null @@ -1,17 +0,0 @@ -
    -
    -
    This is the report area....
    -

    - some stuff goes here -

    -
    -
    - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - }); - - \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/add.inc b/legacy/models/admin/actions/Accommodation/add.inc deleted file mode 100755 index 746f00c..0000000 --- a/legacy/models/admin/actions/Accommodation/add.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -$r = $Accoms->newAccom(); - -$this->page->accomDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewAccom = true; - -$this->templateFile = 'Accommodation/EditAccommodation.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/addRoom.inc b/legacy/models/admin/actions/Accommodation/addRoom.inc deleted file mode 100755 index c5c9d1a..0000000 --- a/legacy/models/admin/actions/Accommodation/addRoom.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -$r = $Rooms->newRoom(); - -$this->page->roomDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewRoom = true; - -$this->templateFile = 'Accommodation/EditRoom.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/detail.inc b/legacy/models/admin/actions/Accommodation/detail.inc deleted file mode 100755 index b8f20cf..0000000 --- a/legacy/models/admin/actions/Accommodation/detail.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -// Get Accommodation detail -$accomDetail = $Accoms->getAccomDetail(); -$this->page->accomDetail = $this->bindArrayToObject($accomDetail); - -// Get Rooms list -$roomsList = $Rooms->getRoomsList(); -$this->page->roomsList = $this->bindArrayToObject($roomsList); - -$this->templateFile = 'Accommodation/AccommodationDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/edit.inc b/legacy/models/admin/actions/Accommodation/edit.inc deleted file mode 100755 index 91b903d..0000000 --- a/legacy/models/admin/actions/Accommodation/edit.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -$accomDetail = $Accoms->editAccom(); -$this->page->accomDetail = $this->bindArrayToObject($accomDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($accomDetail); - -$this->page->editingAccom = true; - -$this->templateFile = 'Accommodation/EditAccommodation.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/editRoom.inc b/legacy/models/admin/actions/Accommodation/editRoom.inc deleted file mode 100755 index f891690..0000000 --- a/legacy/models/admin/actions/Accommodation/editRoom.inc +++ /dev/null @@ -1,29 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -$roomDetail = $Rooms->editRoom(); -$this->page->roomDetail = $this->bindArrayToObject($roomDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($roomDetail); - -$this->templateFile = 'Accommodation/EditRoom.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/insert.inc b/legacy/models/admin/actions/Accommodation/insert.inc deleted file mode 100755 index 00b86b3..0000000 --- a/legacy/models/admin/actions/Accommodation/insert.inc +++ /dev/null @@ -1,40 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -// Process new record -$r = $Accoms->insertAccom(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->accomDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewAccom = true; - $this->templateFile = 'Accommodation/EditAccommodation.html'; -} else { - $this->templateFile = 'Accommodation/AccommodationDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/insertRoom.inc b/legacy/models/admin/actions/Accommodation/insertRoom.inc deleted file mode 100755 index 43095d0..0000000 --- a/legacy/models/admin/actions/Accommodation/insertRoom.inc +++ /dev/null @@ -1,50 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -// Process new record -$r = $Rooms->insertRoom(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->roomDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewRoom = true; - $this->templateFile = 'Accommodation/EditRoom.html'; -} else { - - // Get Accommodation detail - $accomDetail = $Accoms->getAccomDetail(); - $this->page->accomDetail = $this->bindArrayToObject($accomDetail); - - // Get Rooms list - $roomsList = $Rooms->getRoomsList(); - $this->page->roomsList = $this->bindArrayToObject($roomsList); - - $this->templateFile = 'Accommodation/AccommodationDetail.html'; - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/list.inc b/legacy/models/admin/actions/Accommodation/list.inc deleted file mode 100755 index 1581bdf..0000000 --- a/legacy/models/admin/actions/Accommodation/list.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -// Get members stats -$accomsStats = $Accoms->getAccomsStats(); -$this->page->accomsStats = $this->bindArrayToObject($accomsStats); - -// Get accommodations list -$accoms = $Accoms->getAccomsList(); -$this->page->accomsList = $this->bindArrayToObject($accoms); - -$this->templateFile = 'Accommodation/AccommodationsList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/update.inc b/legacy/models/admin/actions/Accommodation/update.inc deleted file mode 100755 index 4f8c52f..0000000 --- a/legacy/models/admin/actions/Accommodation/update.inc +++ /dev/null @@ -1,44 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -// Process new record -$r = $Accoms->updateAccom(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->accomDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$accomDetail = $Accoms->getAccomDetail(); -$this->page->storedDetail = $this->bindArrayToObject($accomDetail); - -// If invalid submission -if (!$status) { - $this->page->editingAccom = true; - $this->templateFile = 'Accommodation/EditAccommodation.html'; -} else { - $this->templateFile = 'Accommodation/AccommodationDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Accommodation/updateRoom.inc b/legacy/models/admin/actions/Accommodation/updateRoom.inc deleted file mode 100755 index 03fa6ee..0000000 --- a/legacy/models/admin/actions/Accommodation/updateRoom.inc +++ /dev/null @@ -1,52 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/rooms.php'; -$Rooms = new EventManagementAdminRooms($this->dbh, $this->config); - - -// Process new record -$r = $Rooms->updateRoom(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->roomDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$accomDetail = $Rooms->getRoomDetail(); -$this->page->storedDetail = $this->bindArrayToObject($roomDetail); - -// If invalid submission -if (!$status) { - $this->templateFile = 'Accommodation/EditRoom.html'; -} else { - - // Get Accommodation detail - $accomDetail = $Accoms->getAccomDetail(); - $this->page->accomDetail = $this->bindArrayToObject($accomDetail); - - // Get Rooms list - $roomsList = $Rooms->getRoomsList(); - $this->page->roomsList = $this->bindArrayToObject($roomsList); - - $this->templateFile = 'Accommodation/AccommodationDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Addon/add.inc b/legacy/models/admin/actions/Addon/add.inc deleted file mode 100755 index 3ee71ed..0000000 --- a/legacy/models/admin/actions/Addon/add.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: add.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -$r = $Addons->newAddon(); - -$this->page->addonDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -$this->page->addingNewAddon = true; - -$this->templateFile = 'Addon/edit.html'; - -$this->addDebug("Addon/add.inc", 'Array: $r', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Addon/confirmDelete.inc b/legacy/models/admin/actions/Addon/confirmDelete.inc deleted file mode 100755 index 6287d71..0000000 --- a/legacy/models/admin/actions/Addon/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: confirmDelete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -$addonDetail = $Addons->addonDelete(true); -$this->page->addonDetail = $this->bindArrayToObject($addonDetail); - -$this->templateFile = 'Addon/detail.html'; - -$this->addDebug("Addon/confirmDelete.inc", 'Section Confirm Delete', print_r($addonDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Addon/delete.inc b/legacy/models/admin/actions/Addon/delete.inc deleted file mode 100755 index 591e1c2..0000000 --- a/legacy/models/admin/actions/Addon/delete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: delete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -$addonDetail = $Addons->addonDelete(false); -$this->page->addonDetail = $this->bindArrayToObject($addonDetail); - -$this->templateFile = 'Addon/delete.html'; - -$this->addDebug("Addon/delete.inc", 'Array: $addonDetail', print_r($addonDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Addon/detail.inc b/legacy/models/admin/actions/Addon/detail.inc deleted file mode 100755 index c7f2dab..0000000 --- a/legacy/models/admin/actions/Addon/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -// Get Add-on detail -$addonDetail = $Addons->getAddonDetail(); -$this->page->addonDetail = $this->bindArrayToObject($addonDetail); - -$this->templateFile = 'Addon/detail.html'; - -$this->addDebug("Addon/detail.inc", 'Array: $addonDetail', print_r($addonDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Addon/edit.inc b/legacy/models/admin/actions/Addon/edit.inc deleted file mode 100755 index 1a7a220..0000000 --- a/legacy/models/admin/actions/Addon/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: edit.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -$addonDetail = $Addons->editAddon(); -$this->page->addonDetail = $this->bindArrayToObject($addonDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($addonDetail); - -$this->page->editingAddon = true; - -$this->templateFile = 'Addon/edit.html'; - -$this->addDebug("Addon/edit.inc", 'Array: $addonDetail', print_r($addonDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Addon/insert.inc b/legacy/models/admin/actions/Addon/insert.inc deleted file mode 100755 index 05197cf..0000000 --- a/legacy/models/admin/actions/Addon/insert.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: insert.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -// Process new record -$r = $Addons->insertAddon(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->addonDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewAddon = true; - $this->templateFile = 'Addon/edit.html'; -} else { - - $addonID = $r['fieldData']['id']; - - $this->templateFile = 'Addon/selected.html'; -} - -$this->addDebug("Addon/insert.inc", 'Array: $r', print_r($r,1)); - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Addon/list.inc b/legacy/models/admin/actions/Addon/list.inc deleted file mode 100755 index 00344fa..0000000 --- a/legacy/models/admin/actions/Addon/list.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: list.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -// Get Add-On stats -$addonStats = $Addons->getAddonsStats(); -$this->page->addonsStats = $this->bindArrayToObject($addonsStats); - -// Get Add-Ons list -$addons = $Addons->getAddonsList($id, false, false, $type); -$this->page->addons = $this->bindArrayToObject($addons); - -$this->templateFile = 'Addon/list.html'; - -$this->addDebug("Addon/list.inc", 'Array: $addons', print_r($addons,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Addon/selected.inc b/legacy/models/admin/actions/Addon/selected.inc deleted file mode 100755 index 9ed2194..0000000 --- a/legacy/models/admin/actions/Addon/selected.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -$addonDetail = $Addons->getAddonDetail(); -$this->page->addonDetail = $this->bindArrayToObject($addonDetail); - -$this->templateFile = 'Addon/selected.html'; - -$this->addDebug("Addon/selected.inc", 'Addon Detail', print_r($addonDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Addon/update.inc b/legacy/models/admin/actions/Addon/update.inc deleted file mode 100755 index c71cb20..0000000 --- a/legacy/models/admin/actions/Addon/update.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: update.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/addons.php'; -$Addons = new EventManagementAdminAddons($this->dbh, $this->config); - -// Process new record -$r = $Addons->updateAddon(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->addonDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$addonDetail = $Addons->getAddonDetail(); -$this->page->storedDetail = $this->bindArrayToObject($addonDetail); - -// If invalid submission -if (!$status) { - $this->page->editingAddon = true; - $this->templateFile = 'Addon/edit.html'; -} else { - $this->templateFile = 'Addon/detail.html'; -} - -$this->addDebug("Addon/update.inc", 'Array: $r', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Attendance/add.inc b/legacy/models/admin/actions/Attendance/add.inc deleted file mode 100755 index 931e2b1..0000000 --- a/legacy/models/admin/actions/Attendance/add.inc +++ /dev/null @@ -1,36 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: attendance.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get a list of members to select from -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); -$members = $Members->getMembersList('all'); - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -$r = $Attendance->newEntry(); - -$this->page->memberDetail = $this->bindArrayToObject($member); -$this->page->attendanceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -$this->page->addingNewAttendance = true; - -$this->templateFile = 'Attendance/edit.html'; - -$this->addDebug("Attendance/add.inc", 'Array: $r', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Attendance/confirmDelete.inc b/legacy/models/admin/actions/Attendance/confirmDelete.inc deleted file mode 100755 index 5ff1e57..0000000 --- a/legacy/models/admin/actions/Attendance/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: confirmDelete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -$attendanceDetail = $Attendance->attendanceDelete(true); -$this->page->attendanceDetail = $this->bindArrayToObject($attendanceDetail); - -$this->templateFile = 'Attendance/detail.html'; - -$this->addDebug("Attendance/confirmDelete.inc", 'Section Confirm Delete', print_r($attendanceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Attendance/delete.inc b/legacy/models/admin/actions/Attendance/delete.inc deleted file mode 100755 index a23f36c..0000000 --- a/legacy/models/admin/actions/Attendance/delete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: delete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -$attendanceDetail = $Attendances->attendanceDelete(false); -$this->page->attendanceDetail = $this->bindArrayToObject($attendanceDetail); - -$this->templateFile = 'Attendance/delete.html'; - -$this->addDebug("Attendance/delete.inc", 'Array: $attendanceDetail', print_r($attendanceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Attendance/detail.inc b/legacy/models/admin/actions/Attendance/detail.inc deleted file mode 100644 index 29676d8..0000000 --- a/legacy/models/admin/actions/Attendance/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendances.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -// Get Attendance detail -$attendanceDetail = $Attendance->getAttendanceDetail(); -$this->page->attendanceDetail = $this->bindArrayToObject($attendanceDetail); - -$this->templateFile = 'Attendance/detail.html'; - -$this->addDebug("Attendance/detail.inc", 'Array: $attendanceDetail', print_r($attendanceDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Attendance/edit.inc b/legacy/models/admin/actions/Attendance/edit.inc deleted file mode 100755 index a3c9656..0000000 --- a/legacy/models/admin/actions/Attendance/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: edit.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -$attendanceDetail = $Attendance->editAttendance(); -$this->page->attendanceDetail = $this->bindArrayToObject($attendanceDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->attendanceDetail = $this->bindArrayToObject($attendanceDetail); - -$this->page->editingAttendance = true; - -$this->templateFile = 'Attendance/edit.html'; - -$this->addDebug("Attendance/edit.inc", 'Array: $attendanceDetail', print_r($attendanceDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Attendance/insert.inc b/legacy/models/admin/actions/Attendance/insert.inc deleted file mode 100755 index 82270a1..0000000 --- a/legacy/models/admin/actions/Attendance/insert.inc +++ /dev/null @@ -1,45 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: insert.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -var_dump($_REQUEST); - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -// Process new record -$r = $Attendance->insertEntry(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->attendanceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewAttendance = true; - $this->templateFile = 'Attendance/edit.html'; -} else { - - $attendanceID = $r['fieldData']['id']; - - $this->templateFile = 'Attendance/selected.html'; -} - -$this->addDebug("Attendance/insert.inc", 'Array: $r', print_r($r,1)); - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Attendance/list.inc b/legacy/models/admin/actions/Attendance/list.inc deleted file mode 100755 index 21069f8..0000000 --- a/legacy/models/admin/actions/Attendance/list.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: list.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -// Get Attendance stats -$attendanceStats = $Attendance->getAttendanceStats(); -$this->page->attendanceStats = $this->bindArrayToObject($attendanceStats); - -// Get Attendance list -$attendanceList = $Attendance->getList(); -$this->page->attendance = $this->bindArrayToObject($attendanceList); - -$this->templateFile = 'Attendance/list.html'; - -$this->addDebug("Attendance/list.inc", 'Array: $attendanceList', print_r($attendanceList, 1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Attendance/selected.inc b/legacy/models/admin/actions/Attendance/selected.inc deleted file mode 100755 index 8b87cb9..0000000 --- a/legacy/models/admin/actions/Attendance/selected.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -$attendanceDetail = $Attendance->getAttendanceDetail(); -$this->page->attendanceDetail = $this->bindArrayToObject($attendanceDetail); - -$this->templateFile = 'Attendance/selected.html'; - -$this->addDebug("Attendance/selected.inc", 'Attendance Detail', print_r($attendanceDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Attendance/update.inc b/legacy/models/admin/actions/Attendance/update.inc deleted file mode 100755 index 41d41a9..0000000 --- a/legacy/models/admin/actions/Attendance/update.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: update.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/attendance.php'; -$Attendance = new EventManagementAdminAttendance($this->dbh, $this->config); - -// Process new record -$r = $Attendance->updateAttendance(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->attendanceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$attendanceDetail = $Attendance->getAttendanceDetail(); -$this->page->storedDetail = $this->bindArrayToObject($AttendanceDetail); - -// If invalid submission -if (!$status) { - $this->page->editingAttendance = true; - $this->templateFile = 'Attendance/edit.html'; - $this->addDebug("Attendance/update.inc", 'Array: $r', print_r($r,1)); -} else { - // $this->templateFile = 'Attendance/detail.html'; - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/Attendance/detail.inc'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Block/detail.inc b/legacy/models/admin/actions/Block/detail.inc deleted file mode 100755 index 60bf2d5..0000000 --- a/legacy/models/admin/actions/Block/detail.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/blocks.php'; -$Blocks = new EventManagementAdminBlocks($this->dbh, $this->config); - - -// Get Room Blocks Detail for a selected Event and member (must have an event selected) -$detail = $Blocks->getBlocksDetail(); -$this->page->blocksDetail = $this->bindArrayToObject($detail); -$this->page->AND = '&&'; // a hack to get this into some javascript - -$this->templateFile = 'Block/BlocksDetail.html'; - -?> - diff --git a/legacy/models/admin/actions/Block/show.inc b/legacy/models/admin/actions/Block/show.inc deleted file mode 100755 index 66275ad..0000000 --- a/legacy/models/admin/actions/Block/show.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/blocks.php'; -$Blocks = new EventManagementAdminBlocks($this->dbh, $this->config); - - -$roomBlocks = $Blocks->getRoomBlocks(); - -if ($roomBlocks['blocks'] != false) { - $this->page->blocksList = $this->bindArrayToObject($roomBlocks['blocks']); -} -$this->page->statesList = $this->bindArrayToObject($roomBlocks['states']); - -// echo "
    ".print_r($roomBlocks,1)."
    "; -$this->templateFile = 'Block/BlocksList.html'; - -?> - diff --git a/legacy/models/admin/actions/Block/summary.inc b/legacy/models/admin/actions/Block/summary.inc deleted file mode 100755 index 1c961ed..0000000 --- a/legacy/models/admin/actions/Block/summary.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/blocks.php'; -$Blocks = new EventManagementAdminBlocks($this->dbh, $this->config); - - -// Get Room Blocks Summary for a selected Event (must have an event selected) -$summary = $Blocks->getBlocksSummary(); -$this->page->blocksSummary = $this->bindArrayToObject($summary); - -$this->templateFile = 'Block/BlocksSummary.html'; - -?> - diff --git a/legacy/models/admin/actions/Block/updateBlocks.inc b/legacy/models/admin/actions/Block/updateBlocks.inc deleted file mode 100755 index 13485c5..0000000 --- a/legacy/models/admin/actions/Block/updateBlocks.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/blocks.php'; -$Blocks = new EventManagementAdminBlocks($this->dbh, $this->config); - - -$roomBlocks = $Blocks->saveRoomBlocks(); - -$this->templateFile = 'Block/UpdateBlocksAssignment.html'; - -?> - diff --git a/legacy/models/admin/actions/Block/updateDetail.inc b/legacy/models/admin/actions/Block/updateDetail.inc deleted file mode 100755 index c0dafcd..0000000 --- a/legacy/models/admin/actions/Block/updateDetail.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/blocks.php'; -$Blocks = new EventManagementAdminBlocks($this->dbh, $this->config); - - -$r = $Blocks->updateBlocksDetail(); -$this->page->blocksStatus = $r; - -$this->templateFile = 'Block/UpdateBlocksDetail.html'; - -?> - diff --git a/legacy/models/admin/actions/Booking/add.inc b/legacy/models/admin/actions/Booking/add.inc deleted file mode 100755 index f9c6982..0000000 --- a/legacy/models/admin/actions/Booking/add.inc +++ /dev/null @@ -1,92 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/bookings.php'; -$Bookings = new EventManagementAdminBookings($this->dbh, $this->config); - - -if ($_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - require '../classes/events.php'; - $Events = new EventManagementAdminEvents($this->dbh, $this->config); - $eventDetail = $Events->getEntry($_SESSION[GLM_EVENT_SESSION]['Event']); - $this->page->eventName = $eventDetail['name']; - $this->page->eventID = $eventDetail['id']; - $this->page->haveEvent = true; -} else { - $this->page->haveEvent = false; -} - -if ($_SESSION[GLM_EVENT_SESSION]['Team'] != false) { - require '../classes/teams.php'; - $Teams = new EventManagementAdminTeams($this->dbh, $this->config); - $teamDetail = $Teams->getEntry($_SESSION[GLM_EVENT_SESSION]['Team']); - $this->page->teamName = $teamDetail['name']; - $this->page->teamID = $teamDetail['id']; - $this->page->haveTeam = true; -} else { - $this->page->haveTeam = false; -} - -// If we have what we need - Get the list of members with inventory for the event -if ($this->page->haveEvent && $this->page->haveTeam) { - - // Get properties that have inventory for this event - $sql = " - SELECT id, name - FROM eventmgt.member - WHERE id IN - ( - SELECT DISTINCT member - FROM eventmgt.inventory - WHERE event_code = '".$eventDetail['event_code']."' - ) - ORDER BY name; - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $memberList = $stmt->fetchAll(PDO::FETCH_ASSOC); - - $this->page->memberList = $this->bindArrayToObject($memberList); - -} - -// Get list of bookings for an event - -// Check for Booking Delete -if (isset($_REQUEST['del'])) { - $del = ($_REQUEST['del'] - 0); - if ($del > 0) { - $sql = "DELETE - FROM eventmgt.team_property - WHERE id = $del - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - } -} - -// Get bookings stats -$bookingsStats = $Bookings->getBookingsStats(); -$this->page->bookingsStats = $this->bindArrayToObject($bookingsStats); - -// Get bookings list -$bookings = $Bookings->getBookingsList(); -$this->page->bookingsList = $this->bindArrayToObject($bookings); - -$this->templateFile = 'Booking/BookingsList.html'; - - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Booking/detail.inc b/legacy/models/admin/actions/Booking/detail.inc deleted file mode 100755 index 91c5b5d..0000000 --- a/legacy/models/admin/actions/Booking/detail.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/bookings.php'; -$Bookings = new EventManagementAdminBookings($this->dbh, $this->config); - - -$bookingDetail = $Bookings->getBookingDetail(); -$this->page->bookingDetail = $this->bindArrayToObject($bookingDetail); - -$this->templateFile = 'Booking/BookingDetail.html'; - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Booking/insert.inc b/legacy/models/admin/actions/Booking/insert.inc deleted file mode 100755 index 8ad281e..0000000 --- a/legacy/models/admin/actions/Booking/insert.inc +++ /dev/null @@ -1,146 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/bookings.php'; -$Bookings = new EventManagementAdminBookings($this->dbh, $this->config); - - -if ($_SESSION[GLM_EVENT_SESSION]['Event'] != false) { - require '../classes/events.php'; - $Events = new EventManagementAdminEvents($this->dbh, $this->config); - $eventDetail = $Events->getEntry($_SESSION[GLM_EVENT_SESSION]['Event']); - $this->page->eventName = $eventDetail['name']; - $this->page->eventID = $eventDetail['id']; - $this->page->haveEvent = true; -} else { - $this->page->haveEvent = false; -} - -if ($_SESSION[GLM_EVENT_SESSION]['Team'] != false) { - require '../classes/teams.php'; - $Teams = new EventManagementAdminTeams($this->dbh, $this->config); - $teamDetail = $Teams->getEntry($_SESSION[GLM_EVENT_SESSION]['Team']); - $this->page->teamName = $teamDetail['name']; - $this->page->teamID = $teamDetail['id']; - $this->page->haveTeam = true; -} else { - $this->page->haveTeam = false; -} - -// If we have what we need - Get the list of members with inventory for the event -if ($this->page->haveEvent && $this->page->haveTeam) { - - // Get properties that have inventory for this event - $sql = " - SELECT id, name - FROM eventmgt.member - WHERE id IN - ( - SELECT DISTINCT member - FROM eventmgt.inventory - WHERE event_code = '".$eventDetail['event_code']."' - ) - ORDER BY name; - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $memberList = $stmt->fetchAll(PDO::FETCH_ASSOC); - - $this->page->memberList = $this->bindArrayToObject($memberList); - -} - -// Insert a booking - -$insertSuccess = true; - -// Check for good Event, Team, and property data, must be id numbers -$eventID = ($_REQUEST['eventID'] - 0); -$teamID = ($_REQUEST['teamID'] - 0); -$propID = ($_REQUEST['propID'] - 0); - -if ($eventID == 0 || $teamID == 0 || $propID == 0) { - $insertSuccess = false; -} -// Check for good dates - Must between now and start of event -$startDate = strtotime($_REQUEST['startDate']); -$endDate = strtotime($_REQUEST['endDate']); - -if ($startDate < strtotime(date('m/d/Y'))) { - $this->page->startFail = true; - $insertSuccess = false; -} - -if ($endDate > strtotime($eventDetail['start_date'])) { - $this->page->endFail = true; - $insertSuccess = false; -} - -if ($startDate > $endDate) { - $this->page->datesFail = true; - $insertSuccess = false; -} - -// If we're Ok to this point, then try to add this booking to the database -if ($insertSuccess) { - $startDate = date('m/d/Y', $startDate); - $endDate = date('m/d/Y', $endDate); - - $sql = " - INSERT INTO eventmgt.team_property - (team, property, event, start, stop) - VALUES - ( - $teamID, $propID, $eventID, '$startDate', '$endDate' - ); - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - // NEED TO TEST FOR SUCCESS HERE -} - - -// If it failed, then try again -if ($insertSuccess == false) { - $this->page->addingNewBooking = true; - $this->templateFile = 'Booking/EditBooking.html'; -} else { - - // Check for Booking Delete - if (isset($_REQUEST['del'])) { - $del = ($_REQUEST['del'] - 0); - if ($del > 0) { - $sql = "DELETE - FROM eventmgt.team_property - WHERE id = $del - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - } - } - - // Get bookings stats - $bookingsStats = $Bookings->getBookingsStats(); - $this->page->bookingsStats = $this->bindArrayToObject($bookingsStats); - - // Get bookings list - $bookings = $Bookings->getBookingsList(); - $this->page->bookingsList = $this->bindArrayToObject($bookings); - - $this->templateFile = 'Booking/BookingsList.html'; - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Booking/list.inc b/legacy/models/admin/actions/Booking/list.inc deleted file mode 100755 index 8042df2..0000000 --- a/legacy/models/admin/actions/Booking/list.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/bookings.php'; -$Bookings = new EventManagementAdminBookings($this->dbh, $this->config); - - -// Check for Booking Delete -if (isset($_REQUEST['del'])) { - $del = ($_REQUEST['del'] - 0); - if ($del > 0) { - $sql = "DELETE - FROM eventmgt.team_property - WHERE id = $del - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - } -} - -// Get bookings stats -$bookingsStats = $Bookings->getBookingsStats(); -$this->page->bookingsStats = $this->bindArrayToObject($bookingsStats); - -// Get bookings list -$bookings = $Bookings->getBookingsList(); -$this->page->bookingsList = $this->bindArrayToObject($bookings); - -$this->templateFile = 'Booking/BookingsList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Contact/add.inc b/legacy/models/admin/actions/Contact/add.inc deleted file mode 100755 index e11091a..0000000 --- a/legacy/models/admin/actions/Contact/add.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -// Get base data and fields -$r = $Contacts->newContact(); - -$this->page->contactDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewContact = true; - -$this->templateFile = 'Contact/edit.html'; - -$this->addDebug("Contact/add.inc", 'Contact Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Contact/confirmDelete.inc b/legacy/models/admin/actions/Contact/confirmDelete.inc deleted file mode 100755 index 46eb6e4..0000000 --- a/legacy/models/admin/actions/Contact/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -$contactDetail = $Contacts->contactDelete(true); -$this->page->contactDetail = $this->bindArrayToObject($contactDetail); - -$this->templateFile = 'Contact/detail.html'; - -$this->addDebug("Contact/confirmDelete.inc", 'Contact Confirm Delete', print_r($contactDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Contact/delete.inc b/legacy/models/admin/actions/Contact/delete.inc deleted file mode 100755 index 442a862..0000000 --- a/legacy/models/admin/actions/Contact/delete.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -$contactDetail = $Contacts->contactDelete(false); -$this->page->contactDetail = $this->bindArrayToObject($contactDetail); - -$this->templateFile = 'Contact/delete.html'; - -$this->addDebug("Contact/delete.inc", 'Contact Delete', print_r($contactDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Contact/detail.inc b/legacy/models/admin/actions/Contact/detail.inc deleted file mode 100755 index b736e4d..0000000 --- a/legacy/models/admin/actions/Contact/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -$contactDetail = $Contacts->getContactDetail(); -$this->page->contactDetail = $this->bindArrayToObject($contactDetail); - -$this->templateFile = 'Contact/detail.html'; - -$this->addDebug("Contact/detail.inc", 'Contact Detail', print_r($contactDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Contact/edit.inc b/legacy/models/admin/actions/Contact/edit.inc deleted file mode 100755 index 03d7252..0000000 --- a/legacy/models/admin/actions/Contact/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -$contactDetail = $Contacts->editContact(); -$this->page->contactDetail = $this->bindArrayToObject($contactDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($contactDetail); - -$this->page->editingContact = true; -$this->templateFile = 'Contact/edit.html'; - -$this->addDebug("Contact/edit.inc", 'Contact Edit', print_r($contactDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Contact/insert.inc b/legacy/models/admin/actions/Contact/insert.inc deleted file mode 100755 index 799d8c2..0000000 --- a/legacy/models/admin/actions/Contact/insert.inc +++ /dev/null @@ -1,40 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -// Process new record -$r = $Contacts->insertContact(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->contactDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewContact = true; - $this->templateFile = 'Contact/edit.html'; -} else { - $this->templateFile = 'Contact/detail.html'; -} - -$this->addDebug("Contact/insert.inc", 'Contact Insert', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Contact/list.inc b/legacy/models/admin/actions/Contact/list.inc deleted file mode 100755 index 2f97688..0000000 --- a/legacy/models/admin/actions/Contact/list.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -// Get contacts stats -$contactsStats = $Contacts->getContactsStats(); -$this->page->contactsStats = $this->bindArrayToObject($contactsStats); - -$contactList = $Contacts->getContacts(); -$this->page->contactList = $this->bindArrayToObject($contactList); - -$this->templateFile = 'Contact/list.html'; - -$this->addDebug("Contact/list.inc", 'Contact List', print_r($contactList,1)); - -?> - diff --git a/legacy/models/admin/actions/Contact/update.inc b/legacy/models/admin/actions/Contact/update.inc deleted file mode 100755 index ea7ec3f..0000000 --- a/legacy/models/admin/actions/Contact/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Process new record -$r = $Contacts->updateContact(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->contactDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->editingContact = true; - $this->templateFile = 'Contact/edit.html'; -} else { - // If valid - $this->templateFile = 'Contact/detail.html'; -} - -$this->addDebug("Contact/add.inc", 'Contact Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Debug/start.inc b/legacy/models/admin/actions/Debug/start.inc deleted file mode 100755 index d07c4fc..0000000 --- a/legacy/models/admin/actions/Debug/start.inc +++ /dev/null @@ -1,19 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->page->debugStartupTime = date('m/d/Y H:i:s'); -$this->templateFile = 'Debug/index.html'; - -?> - diff --git a/legacy/models/admin/actions/Debug/update.inc b/legacy/models/admin/actions/Debug/update.inc deleted file mode 100755 index 6a7e9e6..0000000 --- a/legacy/models/admin/actions/Debug/update.inc +++ /dev/null @@ -1,29 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->page->debugUpdateTime = date('m/d/Y H:i:s'); - -// If there's nothing to send, then don't -if (!file_exists(DEBUG_DATA_FILENAME)) { - exit; -} - -// Otherwise, send the current debug data -$this->page->debugData = file_get_contents(DEBUG_DATA_FILENAME); -unlink(DEBUG_DATA_FILENAME); - -$this->templateFile = 'Debug/index.html'; - -?> - diff --git a/legacy/models/admin/actions/Division/add.inc b/legacy/models/admin/actions/Division/add.inc deleted file mode 100755 index 47f2f2d..0000000 --- a/legacy/models/admin/actions/Division/add.inc +++ /dev/null @@ -1,28 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/divisions.php'; -$Divisions = new EventManagementAdminDivisions($this->dbh, $this->config); - - -$r = $Divisions->newDivision(); - -$this->page->divisionDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewDivision = true; - -$this->templateFile = 'Division/EditDivision.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Division/detail.inc b/legacy/models/admin/actions/Division/detail.inc deleted file mode 100755 index adfff7f..0000000 --- a/legacy/models/admin/actions/Division/detail.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/divisions.php'; -$Divisions = new EventManagementAdminDivisions($this->dbh, $this->config); - - -$divisionDetail = $Divisions->getDivisionDetail(); -$this->page->divisionDetail = $this->bindArrayToObject($divisionDetail); - -$this->templateFile = 'Division/DivisionDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Division/edit.inc b/legacy/models/admin/actions/Division/edit.inc deleted file mode 100755 index e0d9ee0..0000000 --- a/legacy/models/admin/actions/Division/edit.inc +++ /dev/null @@ -1,29 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/divisions.php'; -$Divisions = new EventManagementAdminDivisions($this->dbh, $this->config); - - -$divisionDetail = $Divisions->editDivision(); -$this->page->divisionDetail = $this->bindArrayToObject($divisionDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($divisionDetail); - -$this->page->editingDivision = true; - -$this->templateFile = 'Division/EditDivision.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Division/insert.inc b/legacy/models/admin/actions/Division/insert.inc deleted file mode 100755 index 0e095a1..0000000 --- a/legacy/models/admin/actions/Division/insert.inc +++ /dev/null @@ -1,38 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/divisions.php'; -$Divisions = new EventManagementAdminDivisions($this->dbh, $this->config); - - -// Process new record -$r = $Divisions->insertDivision(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->divisionDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewDivision = true; - $this->templateFile = 'Division/EditDivision.html'; -} else { - $this->templateFile = 'Division/DivisionDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Division/list.inc b/legacy/models/admin/actions/Division/list.inc deleted file mode 100755 index 69d4558..0000000 --- a/legacy/models/admin/actions/Division/list.inc +++ /dev/null @@ -1,29 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/divisions.php'; -$Divisions = new EventManagementAdminDivisions($this->dbh, $this->config); - - -// Get divisions stats -$divisionsStats = $Divisions->getDivisionsStats(); -$this->page->divisionsStats = $this->bindArrayToObject($divisionsStats); - -// Get divisions list -$divisions = $Divisions->getDivisionsList(); -$this->page->divisionsList = $this->bindArrayToObject($divisions); - -$this->templateFile = 'Division/DivisionsList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Division/update.inc b/legacy/models/admin/actions/Division/update.inc deleted file mode 100755 index 2b60b25..0000000 --- a/legacy/models/admin/actions/Division/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/divisions.php'; -$Divisions = new EventManagementAdminDivisions($this->dbh, $this->config); - - -// Process new record -$r = $Divisions->updateDivision(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->divisionDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$divisionDetail = $Divisions->getDivisionDetail(); -$this->page->storedDetail = $this->bindArrayToObject($divisionDetail); - -// If invalid submission -if (!$status) { - $this->page->editingDivision = true; - $this->templateFile = 'Division/EditDivision.html'; -} else { - $this->templateFile = 'Division/DivisionDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Entrance/add.inc b/legacy/models/admin/actions/Entrance/add.inc deleted file mode 100755 index 2e9f2aa..0000000 --- a/legacy/models/admin/actions/Entrance/add.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: add.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - -// Get base data and fields -$r = $Entrances->newEntrance(); - -$this->page->entranceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewEntrance = true; - -$this->templateFile = 'Entrance/edit.html'; - -$this->addDebug("Entrance/add.inc", 'Entrance Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Entrance/confirmDelete.inc b/legacy/models/admin/actions/Entrance/confirmDelete.inc deleted file mode 100755 index 0d03d4a..0000000 --- a/legacy/models/admin/actions/Entrance/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - -$entranceDetail = $Entrances->entranceDelete(true); -$this->page->entranceDetail = $this->bindArrayToObject($entranceDetail); - -$this->templateFile = 'Entrance/detail.html'; - -$this->addDebug("Entrance/confirmDelete.inc", 'Entrance Confirm Delete', print_r($entranceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Entrance/delete.inc b/legacy/models/admin/actions/Entrance/delete.inc deleted file mode 100755 index 6855bcc..0000000 --- a/legacy/models/admin/actions/Entrance/delete.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: entrance.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - - -$entranceDetail = $Entrances->entranceDelete(false); -$this->page->entranceDetail = $this->bindArrayToObject($entranceDetail); - -$this->templateFile = 'Entrance/delete.html'; - -$this->addDebug("Entrance/delete.inc", 'Entrance Delete', print_r($entranceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Entrance/detail.inc b/legacy/models/admin/actions/Entrance/detail.inc deleted file mode 100755 index bbba59b..0000000 --- a/legacy/models/admin/actions/Entrance/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - -$entranceDetail = $Entrances->getEntranceDetail(); -$this->page->entranceDetail = $this->bindArrayToObject($entranceDetail); - -$this->templateFile = 'Entrance/detail.html'; - -$this->addDebug("Entrance/detail.inc", 'Entrance Detail', print_r($entranceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Entrance/edit.inc b/legacy/models/admin/actions/Entrance/edit.inc deleted file mode 100755 index c469fc9..0000000 --- a/legacy/models/admin/actions/Entrance/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - -$entranceDetail = $Entrances->editEntrance(); -$this->page->entranceDetail = $this->bindArrayToObject($entranceDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($entranceDetail); - -$this->page->editingEntrance = true; -$this->templateFile = 'Entrance/edit.html'; - -$this->addDebug("Entrance/edit.inc", 'Entrance Edit', print_r($entranceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Entrance/insert.inc b/legacy/models/admin/actions/Entrance/insert.inc deleted file mode 100755 index e924552..0000000 --- a/legacy/models/admin/actions/Entrance/insert.inc +++ /dev/null @@ -1,40 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - -// Process new record -$r = $Entrances->insertEntrance(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->entranceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewEntrance = true; - $this->templateFile = 'Entrance/edit.html'; -} else { - $this->templateFile = 'Entrance/detail.html'; -} - -$this->addDebug("Entrance/insert.inc", 'Entrance Insert', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Entrance/list.inc b/legacy/models/admin/actions/Entrance/list.inc deleted file mode 100755 index 80d9e0f..0000000 --- a/legacy/models/admin/actions/Entrance/list.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - -$entranceList = $Entrances->getEntrancesList(); - -$this->page->entranceList = $this->bindArrayToObject($entranceList); - -$this->templateFile = 'Entrance/list.html'; - -$this->addDebug("Entrance/list.inc", 'Entrance List', 'Array: $entranceList

    '.print_r($entranceList,1)); - -?> - diff --git a/legacy/models/admin/actions/Entrance/update.inc b/legacy/models/admin/actions/Entrance/update.inc deleted file mode 100755 index a02a0ed..0000000 --- a/legacy/models/admin/actions/Entrance/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; -$Entrances = new EventManagementAdminEntrances($this->dbh, $this->config); - - -// Process new record -$r = $Entrances->updateEntrance(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->entranceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->editingEntrance = true; - $this->templateFile = 'Entrance/edit.html'; -} else { - // If valid - $this->templateFile = 'Entrance/detail.html'; -} - -$this->addDebug("Entrance/add.inc", 'Entrance Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Event/add.inc b/legacy/models/admin/actions/Event/add.inc deleted file mode 100755 index 01cba62..0000000 --- a/legacy/models/admin/actions/Event/add.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/events.php'; -$Events = new EventManagementAdminEvents($this->dbh, $this->config); - - -// Check Event Code -$r = $Events->newEntry(); - -$this->page->eventDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewEvent = true; - -$this->templateFile = 'Event/EditEvent.html'; - -?> - diff --git a/legacy/models/admin/actions/Event/detail.inc b/legacy/models/admin/actions/Event/detail.inc deleted file mode 100755 index f07d78e..0000000 --- a/legacy/models/admin/actions/Event/detail.inc +++ /dev/null @@ -1,32 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/events.php'; -$Events = new EventManagementAdminEvents($this->dbh, $this->config); - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Get detail for an event -$eventDetail = $Events->getEventDetail(); -$this->page->eventDetail = $this->bindArrayToObject($eventDetail); - -// Get contacts for this event -$eventContacts = $Contacts->getContacts('event'); -$this->page->contactsList = $this->bindArrayToObject($eventContacts['contact_list']); - -$this->templateFile = 'Event/EventDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Event/edit.inc b/legacy/models/admin/actions/Event/edit.inc deleted file mode 100755 index 825bce9..0000000 --- a/legacy/models/admin/actions/Event/edit.inc +++ /dev/null @@ -1,32 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/events.php'; -$Events = new EventManagementAdminEvents($this->dbh, $this->config); - - -// Check Event Code -$eventDetail = $Events->editEvent(); -$this->page->eventDetail = $this->bindArrayToObject($eventDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($eventDetail); - -$this->page->editingEvent = true; - -$this->templateFile = 'Event/EditEvent.html'; - - -?> - diff --git a/legacy/models/admin/actions/Event/insert.inc b/legacy/models/admin/actions/Event/insert.inc deleted file mode 100755 index a2b04b4..0000000 --- a/legacy/models/admin/actions/Event/insert.inc +++ /dev/null @@ -1,39 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/events.php'; -$Events = new EventManagementAdminEvents($this->dbh, $this->config); - - -// Process new record -$r = $Events->insertEvent(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->eventDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewEvent = true; - $this->templateFile = 'Event/EditEvent.html'; -} else { - $this->templateFile = 'Event/EventDetail.html'; -} - -?> - diff --git a/legacy/models/admin/actions/Event/list.inc b/legacy/models/admin/actions/Event/list.inc deleted file mode 100755 index c392da9..0000000 --- a/legacy/models/admin/actions/Event/list.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/events.php'; -$Events = new EventManagementAdminEvents($this->dbh, $this->config); - - -// Get events stats -$eventsStats = $Events->getEventsStats(); -$this->page->eventsStats = $this->bindArrayToObject($eventsStats); - -// Get list of events -$eventsList = $Events->getEventsList(); -$this->page->eventsList = $this->bindArrayToObject($eventsList); - -$this->templateFile = 'Event/EventsList.html'; - -?> - diff --git a/legacy/models/admin/actions/Event/stats.inc b/legacy/models/admin/actions/Event/stats.inc deleted file mode 100755 index a58cf42..0000000 --- a/legacy/models/admin/actions/Event/stats.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/events.php'; -$Events = new EventManagementAdminEvents($this->dbh, $this->config); - - -// Get events stats -$eventsStats = $Events->getEventsStats(); -$this->page->eventsStats = $this->bindArrayToObject($eventsStats); - -$this->templateFile = 'Event/stats.html'; - -?> - diff --git a/legacy/models/admin/actions/Event/update.inc b/legacy/models/admin/actions/Event/update.inc deleted file mode 100755 index 8cf0cc5..0000000 --- a/legacy/models/admin/actions/Event/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/events.php'; -$Events = new EventManagementAdminEvents($this->dbh, $this->config); - -// Process new record -$r = $Events->updateEvent(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->eventDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$eventDetail = $Events->getEventDetail(); -$this->page->storedDetail = $this->bindArrayToObject($eventDetail); - -// If invalid submission -if (!$status) { - $this->page->editingEvent = true; - $this->templateFile = 'Event/EditEvent.html'; -} else { - $this->templateFile = 'Event/EventDetail.html'; -} - -?> - diff --git a/legacy/models/admin/actions/EventFee/add.inc b/legacy/models/admin/actions/EventFee/add.inc deleted file mode 100755 index 9d1a4ed..0000000 --- a/legacy/models/admin/actions/EventFee/add.inc +++ /dev/null @@ -1,28 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -$r = $EventFees->newFee(); - -$this->page->feeDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewFee = true; - -$this->templateFile = 'EventFee/EditEventFee.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/EventFee/confirmDelete.inc b/legacy/models/admin/actions/EventFee/confirmDelete.inc deleted file mode 100755 index 5920e41..0000000 --- a/legacy/models/admin/actions/EventFee/confirmDelete.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -$feeDetail = $EventFees->feeDelete(true); -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -$this->templateFile = 'EventFee/EventFeeDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/EventFee/delete.inc b/legacy/models/admin/actions/EventFee/delete.inc deleted file mode 100755 index 64198a0..0000000 --- a/legacy/models/admin/actions/EventFee/delete.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -$feeDetail = $EventFees->feeDelete(false); -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -$this->templateFile = 'EventFee/EventFeeDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/EventFee/detail.inc b/legacy/models/admin/actions/EventFee/detail.inc deleted file mode 100755 index 49482e8..0000000 --- a/legacy/models/admin/actions/EventFee/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -$feeDetail = $EventFees->getFeeDetail(); -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -$this->templateFile = 'EventFee/EventFeeDetail.html'; - -$this->addDebug("EventFee/detail.inc", 'Fee Detail', print_r($feeDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/EventFee/edit.inc b/legacy/models/admin/actions/EventFee/edit.inc deleted file mode 100755 index 67d64dc..0000000 --- a/legacy/models/admin/actions/EventFee/edit.inc +++ /dev/null @@ -1,32 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -// Check Event Fee Code -$feeDetail = $EventFees->editFee(); -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($feeDetail); - -$this->page->editingFee = true; - -$this->templateFile = 'EventFee/EditEventFee.html'; - -$this->addDebug("EventFee/edit.inc", 'Fee Detail', print_r($feeDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/EventFee/insert.inc b/legacy/models/admin/actions/EventFee/insert.inc deleted file mode 100755 index a139b0e..0000000 --- a/legacy/models/admin/actions/EventFee/insert.inc +++ /dev/null @@ -1,38 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -// Process new record -$r = $EventFees->insertFee(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->feeDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewFee = true; - $this->templateFile = 'EventFee/EditEventFee.html'; -} else { - $this->templateFile = 'EventFee/EventFeeDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/EventFee/list.inc b/legacy/models/admin/actions/EventFee/list.inc deleted file mode 100755 index 486e2ef..0000000 --- a/legacy/models/admin/actions/EventFee/list.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -// Get event fees stats -$feesStats = $EventFees->getEventFeesStats(); -$this->page->feesStats = $this->bindArrayToObject($feesStats); - -// Get Event Fees list -$feesList = $EventFees->getFees('event'); -$this->page->feesList = $this->bindArrayToObject($feesList); - -$this->templateFile = 'EventFee/EventFeesList.html'; - -$this->addDebug("EventFee/list.inc", 'Event Fees List', print_r($feesStats,1).'

     

    '.print_r(feesList,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/EventFee/update.inc b/legacy/models/admin/actions/EventFee/update.inc deleted file mode 100755 index 1a23a37..0000000 --- a/legacy/models/admin/actions/EventFee/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: eventFee.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/eventFees.php'; -$EventFees = new EventManagementAdminEventFees($this->dbh, $this->config); - - -// Process new record -$r = $EventFees->updateFee(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->feeDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$feeDetail = $EventFees->getFeeDetail(); -$this->page->storedDetail = $this->bindArrayToObject($feeDetail); - -// If invalid submission -if (!$status) { - $this->page->editingFee = true; - $this->templateFile = 'EventFee/EditEventFee.html'; -} else { - $this->templateFile = 'EventFee/EventFeeDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Help/index.inc b/legacy/models/admin/actions/Help/index.inc deleted file mode 100755 index 43f2fd1..0000000 --- a/legacy/models/admin/actions/Help/index.inc +++ /dev/null @@ -1,18 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: index.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->templateFile = "Help/index.html"; - -?> - diff --git a/legacy/models/admin/actions/Index/index.inc b/legacy/models/admin/actions/Index/index.inc deleted file mode 100755 index 09d2f62..0000000 --- a/legacy/models/admin/actions/Index/index.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Reset Session -$this->startSession(true); - -// If user level is 20 or above, then start with ticket claims loaded. -$this->page->startWithClaims = 0; -if ($this->page->level >= 20) { - $this->page->startWithClaims = 1; -} - -$this->templateFile = "index.html"; - -?> - diff --git a/legacy/models/admin/actions/Index/welcome.inc b/legacy/models/admin/actions/Index/welcome.inc deleted file mode 100755 index b99344b..0000000 --- a/legacy/models/admin/actions/Index/welcome.inc +++ /dev/null @@ -1,18 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->templateFile = "Welcome/index.html"; - -?> - diff --git a/legacy/models/admin/actions/Member/add.inc b/legacy/models/admin/actions/Member/add.inc deleted file mode 100755 index fc3e1bc..0000000 --- a/legacy/models/admin/actions/Member/add.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -// Check Member Code -$r = $Members->newEntry(); - -$this->page->memberDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewMember = true; - -$this->templateFile = 'Member/edit.html'; - -$this->addDebug("Member/add.inc", 'Member Add', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/confirmDelete.inc b/legacy/models/admin/actions/Member/confirmDelete.inc deleted file mode 100755 index 5ac4dbf..0000000 --- a/legacy/models/admin/actions/Member/confirmDelete.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -$memberDetail = $Members->memberDelete(true); -$this->page->memberDetail = $this->bindArrayToObject($memberDetail); - -$this->page->memberDeleted = true; - -$this->templateFile = 'Member/detail.html'; - -$this->addDebug("Member/delete.inc", 'Member Delete', print_r($memberDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/delete.inc b/legacy/models/admin/actions/Member/delete.inc deleted file mode 100755 index a68027b..0000000 --- a/legacy/models/admin/actions/Member/delete.inc +++ /dev/null @@ -1,32 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -// Check Member Code -$memberDetail = $Members->getMemberDetail(); - -$this->page->memberDetail = $this->bindArrayToObject($memberDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($memberDetail); - -$this->page->editingMember = true; - -$this->templateFile = 'Member/delete.html'; - -$this->addDebug("Member/delete.inc", 'Member Delete', print_r($memberDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/detail.inc b/legacy/models/admin/actions/Member/detail.inc deleted file mode 100644 index ab9dcd6..0000000 --- a/legacy/models/admin/actions/Member/detail.inc +++ /dev/null @@ -1,48 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -$memberDetail = $Members->getMemberDetail(); -$memberID = $memberDetail['id']; - -// Also get list of members this member scans for -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMemberScansFor.php'; -$MemberScansFor = new EventManagementDataMemberScansFor($this->dbh, $this->config); -$memberScansFor = $MemberScansFor->getMemberScansForList($memberID); -if (is_array($memberScansFor) && count($memberScansFor) > 0) { - $this->page->haveMemberScansFor = true; - $this->page->memberScansFor = $this->bindArrayToObject($memberScansFor); -} else { - $this->page->haveMemberScansFor = false; -} - -if ($memberDetail != false) { - // Also need to add static amenity names - $amen_array = $this->config->memb_amen->toArray(); - while( list($key, $val) = each( $amen_array ) ) { - $memberDetail['amen_'.$key]['displayName'] = $val; - } - - $this->page->memberDetail = $this->bindArrayToObject($memberDetail); -} else { - $this->page->memberNotFound = true; -} - -$this->templateFile = 'Member/detail.html'; - -$this->addDebug("Member/detail.inc", 'Members Detail', print_r($memberDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/edit.inc b/legacy/models/admin/actions/Member/edit.inc deleted file mode 100644 index 0b6cbc8..0000000 --- a/legacy/models/admin/actions/Member/edit.inc +++ /dev/null @@ -1,59 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); -/* -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; -$Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$memberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); -*/ - -// Check Member Code -$memberDetail = $Members->editMember(); -$memberID = $memberDetail['id']; - -// Also need to add static amenity names -$amen_array = $this->config->memb_amen->toArray(); -while( list($key, $val) = each( $amen_array ) ) { - $memberDetail['amen_'.$key]['displayName'] = $val; -} -$this->page->memberDetail = $this->bindArrayToObject($memberDetail); - -// Also get list of members this member scans for -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMemberScansFor.php'; -$MemberScansFor = new EventManagementDataMemberScansFor($this->dbh, $this->config); -$memberScansFor = $MemberScansFor->getMemberScansForList($memberID); -$this->page->memberScansFor = $this->bindArrayToObject($memberScansFor); - -// And get full list of members (except this member) to use for Member Scans For select list -$sql = "SELECT id, name FROM eventmgt.member WHERE active AND id != $memberID;"; -$stmt = $this->dbh->prepare($sql); -$stmt->execute(); -$memberList = $stmt->fetchAll(PDO::FETCH_ASSOC); -$this->page->memberList = $this->bindArrayToObject($memberList); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -//$this->page->storedDetail = $this->bindArrayToObject($memberDetail); - -$this->page->editingMember = true; - -$this->templateFile = 'Member/edit.html'; - -$this->addDebug("Member/edit.inc", 'Array: $memberDetail', print_r($memberDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/index.inc b/legacy/models/admin/actions/Member/index.inc deleted file mode 100755 index 08cc7b4..0000000 --- a/legacy/models/admin/actions/Member/index.inc +++ /dev/null @@ -1,17 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->templateFile = 'Member/index.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/insert.inc b/legacy/models/admin/actions/Member/insert.inc deleted file mode 100755 index db28550..0000000 --- a/legacy/models/admin/actions/Member/insert.inc +++ /dev/null @@ -1,41 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -// Process new record -$r = $Members->insertMember(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->memberDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -$_SESSION[GLM_EVENT_SESSION]['Member'] = $r['fieldData']['id']; - -// If invalid submission -if (!$status) { - $this->page->addingNewMember = true; - $this->templateFile = 'Member/edit.html'; -} else { - $this->templateFile = 'Member/selected.html'; -} - -$this->addDebug("Member/insert.inc", 'Members Insert', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/list.inc b/legacy/models/admin/actions/Member/list.inc deleted file mode 100644 index 9f5370a..0000000 --- a/legacy/models/admin/actions/Member/list.inc +++ /dev/null @@ -1,35 +0,0 @@ - - - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -// Get members list -$members = $Members->getMembersList('all'); - -$this->page->membersList = $this->bindArrayToObject($members); - -// Check if we also need to display a member detail (list redisplay on member update). -$this->page->displayMember = false; -if (isset($_REQUEST['memberID']) && ($_REQUEST['memberID']-0) > 0) { - $this->page->displayMember = ($_REQUEST['memberID']-0); -} - -$this->templateFile = 'Member/list.html'; - -$this->addDebug("Member/list.inc", 'Member List', print_r($members,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/selected.inc b/legacy/models/admin/actions/Member/selected.inc deleted file mode 100755 index 0fc654a..0000000 --- a/legacy/models/admin/actions/Member/selected.inc +++ /dev/null @@ -1,100 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -$memberDetail = $Members->getMemberDetail(); - -// Also need to add static amenity names -$amen_array = $this->config->memb_amen->toArray(); -while( list($key, $val) = each( $amen_array ) ) { - $memberDetail['amen_'.$key]['displayName'] = $val; -} -$this->page->memberDetail = $this->bindArrayToObject($memberDetail); - -$_SESSION[GLM_EVENT_SESSION]['Member'] = $memberDetail['id']; - -// Get other stats and clear all flags -$memberStats = array( - 'contact' => $Contacts->getMemberContactsStats(), - 'flags' => false, - 'flag' => false -); - -// Check contact status -if ($memberStats['contact'] == 0) { - $memberStats['flags']['noContacts'] = true; - $memberStats['flag'] = true; -} - -// Check accommodation status -if ($this->config->option->accommodations) { - - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/accommodations.php'; - $Accoms = new EventManagementAdminAccoms($this->dbh, $this->config); - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/inventory.php'; - $Inventory = new EventManagementAdminInventory($this->dbh, $this->config); - - $memberStats['accom'] = $Accoms->getMemberAccomsStats(); - $memberStats['inven'] = $Inventory->getMemberInvenStats(); - if ($memberStats['accom'] == 0) { - $memberStats['flags']['noAccoms'] = true; - $memberStats['flag'] = true; - } - if ($memberStats['inven'] == 0) { - $memberStats['flags']['noInven'] = true; - $memberStats['flag'] = true; - } -}; - -// Check ticket status -if ($this->config->option->tickets) { - - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; - $Sections = new EventManagementAdminSections($this->dbh, $this->config); - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; - $Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - - $memberStats['section'] = $Sections->getMemberSectionsStats(); - $memberStats['performance'] = $Performances->getMemberPerformancesStats(); - $memberStats['ticket'] = $Tickets->getMemberTicketsStats(); - - if ($memberStats['section'] == 0) { - $memberStats['flags']['noSections'] = true; - $memberStats['flag'] = true; - } - if ($memberStats['performance'] == 0) { - $memberStats['flags']['noPerformances'] = true; - $memberStats['flag'] = true; - } - if ($memberStats['ticket'] == 0) { - $memberStats['flags']['noTickets'] = true; - $memberStats['flag'] = true; - } - -} - -$this->page->memberStats = $this->bindArrayToObject($memberStats); - -$this->templateFile = 'Member/selected.html'; - -$this->addDebug("Member/selected.inc", 'Member Detail', print_r($memberDetail,1)); -$this->addDebug("Member/selected.inc", 'Member Stats', print_r($memberStats,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/stats.inc b/legacy/models/admin/actions/Member/stats.inc deleted file mode 100755 index 62f0d13..0000000 --- a/legacy/models/admin/actions/Member/stats.inc +++ /dev/null @@ -1,32 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -// Check for new mebers whenever we get here - only called if integrated database -if ($this->config->option->member_db_integrated) { - $Members->checkNewMembers(); -} - -// Get members stats -$membersStats = $Members->getMembersStats(); - -$this->page->membersStats = $this->bindArrayToObject($membersStats); - -$this->templateFile = 'Member/stats.html'; - -$this->addDebug("Member/stats.inc", 'Array: $memberStats', print_r($membersStats,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Member/update.inc b/legacy/models/admin/actions/Member/update.inc deleted file mode 100644 index 67b77f8..0000000 --- a/legacy/models/admin/actions/Member/update.inc +++ /dev/null @@ -1,56 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); - -// Process new record -$r = $Members->updateMember(); - -// Also need to add static amenity names -$amen_array = $this->config->memb_amen->toArray(); -while( list($key, $val) = each( $amen_array ) ) { - $r['fieldData']['amen_'.$key]['displayName'] = $val; -} - -// Also update list of members this member scans for -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMemberScansFor.php'; -$MemberScansFor = new EventManagementDataMemberScansFor($this->dbh, $this->config); -$memberScansFor = $MemberScansFor->updateMemberScansForList($r['fieldData']['id']); -$this->page->memberScansFor = $this->bindArrayToObject($memberScansFor); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->memberDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$memberDetail = $Members->getMemberDetail(); -$this->page->storedDetail = $this->bindArrayToObject($memberDetail); - -// If invalid submission -if (!$status) { - $this->page->editingMember = true; - $this->templateFile = 'Member/edit.html'; -} else { - // $this->templateFile = 'Member/detail.html'; - $this->templateFile = 'Member/redisplayList.html'; -} - -$this->addDebug("Member/update.inc", 'Member Update', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberAmenities/add.inc b/legacy/models/admin/actions/MemberAmenities/add.inc deleted file mode 100755 index 01fcd3d..0000000 --- a/legacy/models/admin/actions/MemberAmenities/add.inc +++ /dev/null @@ -1,28 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberAmenities.php'; -$MemberAmenities = new EventManagementAdminMemberAmenities($this->dbh, $this->config); - - -$r = $MemberAmenities->newAmenity(); - -$this->page->amenityDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewAmenity = true; - -$this->templateFile = 'Amenity/EditMemberAmenity.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberAmenities/detail.inc b/legacy/models/admin/actions/MemberAmenities/detail.inc deleted file mode 100755 index 0b23262..0000000 --- a/legacy/models/admin/actions/MemberAmenities/detail.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberAmenities.php'; -$MemberAmenities = new EventManagementAdminMemberAmenities($this->dbh, $this->config); - - -$amenityDetail = $MemberAmenities->getAmenityDetail(); - -$this->page->amenityDetail = $this->bindArrayToObject($amenityDetail); - -$this->templateFile = 'Amenity/MemberAmenityDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberAmenities/edit.inc b/legacy/models/admin/actions/MemberAmenities/edit.inc deleted file mode 100755 index 1234c8b..0000000 --- a/legacy/models/admin/actions/MemberAmenities/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberAmenities.php'; -$MemberAmenities = new EventManagementAdminMemberAmenities($this->dbh, $this->config); - - -// Check Member Amenity Code -$amenityDetail = $MemberAmenities->editAmenity(); -$this->page->amenityDetail = $this->bindArrayToObject($amenityDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($memberAmenityDetail); - -$this->page->editingAmenity = true; - -$this->templateFile = 'Amenity/EditMemberAmenity.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberAmenities/insert.inc b/legacy/models/admin/actions/MemberAmenities/insert.inc deleted file mode 100755 index 23d21fa..0000000 --- a/legacy/models/admin/actions/MemberAmenities/insert.inc +++ /dev/null @@ -1,38 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberAmenities.php'; -$MemberAmenities = new EventManagementAdminMemberAmenities($this->dbh, $this->config); - - -// Process new record -$r = $MemberAmenities->insertAmenity(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->amenityDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewAmenity = true; - $this->templateFile = 'Amenity/EditMemberAmenity.html'; -} else { - $this->templateFile = 'Amenity/MemberAmenityDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberAmenities/list.inc b/legacy/models/admin/actions/MemberAmenities/list.inc deleted file mode 100755 index 9c80b1c..0000000 --- a/legacy/models/admin/actions/MemberAmenities/list.inc +++ /dev/null @@ -1,29 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberAmenities.php'; -$MemberAmenities = new EventManagementAdminMemberAmenities($this->dbh, $this->config); - - -// Get member amenities stats -$amenitiesStats = $MemberAmenities->getMemberAmenitiesStats(); -$this->page->amenitiesStats = $this->bindArrayToObject($amenitiesStats); - -// Get Member Amenities list -$amenitiesList = $MemberAmenities->getAmenities('member'); -$this->page->amenitiesList = $this->bindArrayToObject($amenitiesList); - -$this->templateFile = 'Amenity/MemberAmenitiesList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberAmenities/update.inc b/legacy/models/admin/actions/MemberAmenities/update.inc deleted file mode 100755 index 20d7e04..0000000 --- a/legacy/models/admin/actions/MemberAmenities/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberAmenities.php'; -$MemberAmenities = new EventManagementAdminMemberAmenities($this->dbh, $this->config); - - -// Process new record -$r = $MemberAmenities->updateAmenity(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->amenityDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$amenityDetail = $MemberAmenities->getAmenityDetail(); -$this->page->storedDetail = $this->bindArrayToObject($amenityDetail); - -// If invalid submission -if (!$status) { - $this->page->editingAmenity = true; - $this->templateFile = 'Amenity/EditMemberAmenity.html'; -} else { - $this->templateFile = 'Amenity/MemberAmenityDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/add.inc b/legacy/models/admin/actions/MemberFee/add.inc deleted file mode 100755 index 16a9387..0000000 --- a/legacy/models/admin/actions/MemberFee/add.inc +++ /dev/null @@ -1,34 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -$r = $MemberFees->newFee(); - -// check for selected event to use for default for specific event -$e = $_SESSION[GLM_EVENT_SESSION]['Event']; -if ($e && isset($r['fieldData']['event']['pick_list'][$e])) { - $r['fieldData']['event']['pick_list'][$e]['default'] = true; -} - -$this->page->feeDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewFee = true; - -$this->templateFile = 'MemberFee/EditMemberFee.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/confirmDelete.inc b/legacy/models/admin/actions/MemberFee/confirmDelete.inc deleted file mode 100755 index 18122a4..0000000 --- a/legacy/models/admin/actions/MemberFee/confirmDelete.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -$feeDetail = $MemberFees->feeDelete(true); -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -$this->templateFile = 'MemberFee/MemberFeeDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/delete.inc b/legacy/models/admin/actions/MemberFee/delete.inc deleted file mode 100755 index bf2f2b4..0000000 --- a/legacy/models/admin/actions/MemberFee/delete.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -$feeDetail = $MemberFees->feeDelete(false); -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -$this->templateFile = 'MemberFee/MemberFeeDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/detail.inc b/legacy/models/admin/actions/MemberFee/detail.inc deleted file mode 100755 index 5c3b4b6..0000000 --- a/legacy/models/admin/actions/MemberFee/detail.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -$feeDetail = $MemberFees->getFeeDetail(); - -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -$this->templateFile = 'MemberFee/MemberFeeDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/edit.inc b/legacy/models/admin/actions/MemberFee/edit.inc deleted file mode 100755 index ebe2a40..0000000 --- a/legacy/models/admin/actions/MemberFee/edit.inc +++ /dev/null @@ -1,37 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -// Check Member Fee Code -$feeDetail = $MemberFees->editFee(); - -// check for selected event to use for default for specific event -$e = $_SESSION[GLM_EVENT_SESSION]['Event']; -if ($e && isset($feeDetail['fieldData']['event']['pick_list'][$e])) { - $feeDetail['fieldData']['event']['pick_list'][$e]['default'] = true; -} - -$this->page->feeDetail = $this->bindArrayToObject($feeDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($memberFeeDetail); - -$this->page->editingFee = true; - -$this->templateFile = 'MemberFee/EditMemberFee.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/insert.inc b/legacy/models/admin/actions/MemberFee/insert.inc deleted file mode 100755 index 486164d..0000000 --- a/legacy/models/admin/actions/MemberFee/insert.inc +++ /dev/null @@ -1,38 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -// Process new record -$r = $MemberFees->insertFee(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->feeDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewFee = true; - $this->templateFile = 'MemberFee/EditMemberFee.html'; -} else { - $this->templateFile = 'MemberFee/MemberFeeDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/list.inc b/legacy/models/admin/actions/MemberFee/list.inc deleted file mode 100755 index e8d70a4..0000000 --- a/legacy/models/admin/actions/MemberFee/list.inc +++ /dev/null @@ -1,29 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -// Get member fees stats -$feesStats = $MemberFees->getMemberFeesStats(); -$this->page->feesStats = $this->bindArrayToObject($feesStats); - -// Get Member Fees list -$feesList = $MemberFees->getFees('member'); -$this->page->feesList = $this->bindArrayToObject($feesList); - -$this->templateFile = 'MemberFee/MemberFeesList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/MemberFee/update.inc b/legacy/models/admin/actions/MemberFee/update.inc deleted file mode 100755 index 426266b..0000000 --- a/legacy/models/admin/actions/MemberFee/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/memberFees.php'; -$MemberFees = new EventManagementAdminMemberFees($this->dbh, $this->config); - - -// Process new record -$r = $MemberFees->updateFee(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->feeDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$feeDetail = $MemberFees->getFeeDetail(); -$this->page->storedDetail = $this->bindArrayToObject($feeDetail); - -// If invalid submission -if (!$status) { - $this->page->editingFee = true; - $this->templateFile = 'MemberFee/EditMemberFee.html'; -} else { - $this->templateFile = 'MemberFee/MemberFeeDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Misc/blank.inc b/legacy/models/admin/actions/Misc/blank.inc deleted file mode 100755 index 7c58511..0000000 --- a/legacy/models/admin/actions/Misc/blank.inc +++ /dev/null @@ -1,18 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: index.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->templateFile = 'Misc/blank.html'; - - -?> diff --git a/legacy/models/admin/actions/Misc/configDetail.inc b/legacy/models/admin/actions/Misc/configDetail.inc deleted file mode 100755 index 355be0c..0000000 --- a/legacy/models/admin/actions/Misc/configDetail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/misc.php'; -$Misc = new EventManagementAdminMisc($this->dbh, $this->config); - -$miscConfigDetail = $Misc->getEntry(1); - -$this->page->miscConfigDetail = $this->bindArrayToObject($miscConfigDetail); - -$this->templateFile = 'Misc/configDetail.html'; - -$this->addDebug("Misc/configDetail.inc", 'Misc Config Detail', print_r($miscConfigDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Misc/configEdit.inc b/legacy/models/admin/actions/Misc/configEdit.inc deleted file mode 100755 index e296159..0000000 --- a/legacy/models/admin/actions/Misc/configEdit.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: configEdit.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/misc.php'; -$Misc = new EventManagementAdminMisc($this->dbh, $this->config); - -$miscConfigDetail = $Misc->editEntry(1); - -$this->page->miscConfigDetail = $this->bindArrayToObject($miscConfigDetail); -$this->templateFile = 'Misc/configEdit.html'; - -$this->addDebug("Misc/configEdit.inc", 'Array: $miscConfigDetail', print_r($miscConfigDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Misc/configUpdate.inc b/legacy/models/admin/actions/Misc/configUpdate.inc deleted file mode 100755 index 0bc4b5e..0000000 --- a/legacy/models/admin/actions/Misc/configUpdate.inc +++ /dev/null @@ -1,38 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: configUpdate.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/misc.php'; -$Misc = new EventManagementAdminMisc($this->dbh, $this->config); - -// Process new record -$r = $Misc->updateEntry(1); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->miscConfigDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->templateFile = 'Misc/configEdit.html'; -} else { - $this->templateFile = 'Misc/configDetail.html'; -} - -$this->addDebug("Misc/configUpdate.inc", 'Misc Config Detail', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Misc/index.inc b/legacy/models/admin/actions/Misc/index.inc deleted file mode 100755 index 9f62687..0000000 --- a/legacy/models/admin/actions/Misc/index.inc +++ /dev/null @@ -1,18 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: index.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->templateFile = 'Misc/index.html'; - - -?> diff --git a/legacy/models/admin/actions/Misc/upload.inc b/legacy/models/admin/actions/Misc/upload.inc deleted file mode 100755 index 0dbee19..0000000 --- a/legacy/models/admin/actions/Misc/upload.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: upload.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$filepath = EVENT_MANAGEMENT_APP_BASE.'web/custom/'.$this->config->custom_prefix.'/'; - -// Get last file upload times -$indexTime = filemtime($filepath.'index.html'); -$stylesTime = filemtime($filepath.'styles.css'); -$this->page->indexTime = date('m/d/Y h:i:s A', $indexTime); -$this->page->stylesTime = date('m/d/Y h:i:s A', $stylesTime); - -$this->templateFile = 'Misc/upload.html'; - - -?> diff --git a/legacy/models/admin/actions/Misc/uploadIndex.inc b/legacy/models/admin/actions/Misc/uploadIndex.inc deleted file mode 100755 index 6fee2e0..0000000 --- a/legacy/models/admin/actions/Misc/uploadIndex.inc +++ /dev/null @@ -1,80 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: uploadIndex.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->page->doingIndex = true; -$filepath = EVENT_MANAGEMENT_APP_BASE.'web/custom/'.$this->config->custom_prefix.'/'; - -if (isset($_REQUEST['RevertIndex'])) { - - // Try to copy the previous file back in as the active file. - if (!copy($filepath.'SavedOriginals/index.html', $filepath.'index.html')) { - $this->reason[] = 'Sorry, we were unable restore the previous file.'; - - // Otherwise it's a successful upload - } else { - - $this->page->indexFileRestored = true; - - } - - -} else { - - // Check that it's a text/html file - if (!isset($_FILES['index'])) { - $this->reason[] = 'You did not supply a file.'; - - // Check if it's the right type - } elseif ($_FILES['index']['type'] != 'text/html') { - $this->reason[] = 'The file you supplied is not of type "text/html".'; - - // Read the file into a parameter - } elseif (!($f = file_get_contents($_FILES['index']['tmp_name']))) { - $this->reason[] = 'Unable to read the file provided.'; - - // Make sure there's no flexy or PHP elements in the file - } elseif (preg_match('~reason[] = 'The file you provided has PHP or Flexy Template components that are not permitted.'; - - // Replace the {GLM} tag with a flexy include that will insert content - } elseif (($f = str_replace('{GLM}', '', $f)) == '') { - $this->reason[] = 'Unable to parse the supplied file to prepare it for use.'; - - // Save the file to the destination folder - } elseif (!file_put_contents($filepath.'index.html.NEW', $f)) { - $this->reason[] = 'Unable to store prepared file.'; - - // Try to save off a copy of the current file - } elseif (!copy($filepath.'index.html', $filepath.'SavedOriginals/index.html')) { - $this->reason[] = 'Sorry, we were unable to save the current file as a backup so are not going to put the new one in.'; - - // Try to unlink old file then rename NEW file to index.html - } elseif ( - !unlink($filepath.'index.html') || - !rename($filepath.'index.html.NEW', $filepath.'index.html') - ) { - $this->reason[] = 'There was a problem moving the supplied file into live use. Please check the site and call immediately if there is a problem.'; - - // Otherwise it's a successful upload - } else { - - $this->page->indexFileUploaded = true; - - } - -} - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/Misc/upload.inc'; - -?> diff --git a/legacy/models/admin/actions/Misc/uploadStylesheet.inc b/legacy/models/admin/actions/Misc/uploadStylesheet.inc deleted file mode 100755 index e284661..0000000 --- a/legacy/models/admin/actions/Misc/uploadStylesheet.inc +++ /dev/null @@ -1,69 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: uploadStylesheet.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->page->doingStylesheet = true; -$filepath = EVENT_MANAGEMENT_APP_BASE.'web/custom/'.$this->config->custom_prefix.'/'; - -if (isset($_REQUEST['RevertStylesheet'])) { - - // Try to copy the previous file back in as the active file. - if (!copy($filepath.'SavedOriginals/styles.css', $filepath.'styles.css')) { - $this->reason[] = 'Sorry, we were unable restore the previous file.'; - - // Otherwise it's a successful upload - } else { - - $this->page->stylesheetFileRestored = true; - - } - - -} else { - - // Check that it's a text/html file - if (!isset($_FILES['stylesheet'])) { - $this->reason[] = 'You did not supply a file.'; - - // Check if it's the right type - } elseif ($_FILES['stylesheet']['type'] != 'text/css') { - $this->reason[] = 'The file you supplied is not of type "text/html".'; - - // check that the size is reasonable - } elseif ($_FILES['stylesheet']['size'] < 10) { - $this->reason[] = 'There doesn\'t seem to be much in this file.'; - - // Make sure the file gets copied to the destination folder - } elseif (!copy($_FILES['stylesheet']['tmp_name'], $filepath.'styles.css.NEW')) { - $this->reason[] = 'Sorry, we were unable to copy the file you supplied to the destination folder.'; - - // Try to save off a copy of the current file - } elseif (!copy($filepath.'styles.css', $filepath.'SavedOriginals/styles.css')) { - $this->reason[] = 'Sorry, we were unable to save the current file as a backup so are not going to put the new one in.'; - - // Try to unlink old file then rename NEW file to styles.css - } elseif (!unlink($filepath.'styles.css') || !rename($filepath.'styles.css.NEW', $filepath.'styles.css')) { - $this->reason[] = 'There was a problem moving the supplied file into live use. Please check the site and call immediately if there is a problem.'; - - // Otherwise it's a successful upload - } else { - - $this->page->stylesheetFileUploaded = true; - - } - -} - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/Misc/upload.inc'; - -?> diff --git a/legacy/models/admin/actions/Order/detail.inc b/legacy/models/admin/actions/Order/detail.inc deleted file mode 100755 index 936757b..0000000 --- a/legacy/models/admin/actions/Order/detail.inc +++ /dev/null @@ -1,34 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); - -// If this is a member user then make sure they only list their own member performances -$type = false; -$id = false; -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser'] && !$this->config->option->users_access_all_members) { - $type = 'member'; - $id = $this->page->userMemberID; -} - -// Get Order detail -$orderDetail = $Orders->getOrderDetail(false, $id); -$this->page->orderDetail = $this->bindArrayToObject($orderDetail); - -$this->templateFile = 'Order/detail.html'; - -$this->addDebug("Order/detail.inc", 'Array: $orderDetail', print_r($orderDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Order/edit.inc b/legacy/models/admin/actions/Order/edit.inc deleted file mode 100755 index 01e78a6..0000000 --- a/legacy/models/admin/actions/Order/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: edit.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); - -$orderDetail = $Orders->editOrder(); -$this->page->orderDetail = $this->bindArrayToObject($orderDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($orderDetail); - -$this->page->editingOrder = true; - -$this->templateFile = 'Order/edit.html'; - -$this->addDebug("Order/edit.inc", 'Array: $orderDetail', print_r($orderDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Order/list.inc b/legacy/models/admin/actions/Order/list.inc deleted file mode 100755 index 66e2379..0000000 --- a/legacy/models/admin/actions/Order/list.inc +++ /dev/null @@ -1,35 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: list.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); - -// If this is a member user then make sure they only list their own member performances -$type = false; -$id = false; -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $type = 'member'; - $id = $this->page->userMemberID; -} - -$orderList = $Orders->getOrdersList($id, false, false, $type); - -$this->page->orderList = $this->bindArrayToObject($orderList); - -$this->templateFile = 'Order/list.html'; - -$this->addDebug("Order/list.inc", 'Order List', 'Array: $orderList

    '.print_r($orderList,1)); - -?> - diff --git a/legacy/models/admin/actions/Order/printVoucher.inc b/legacy/models/admin/actions/Order/printVoucher.inc deleted file mode 100644 index e7d6a09..0000000 --- a/legacy/models/admin/actions/Order/printVoucher.inc +++ /dev/null @@ -1,50 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: printVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get Order Detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); -$orderDetail = $Orders->getOrderDetail(); - -// Get Ticket Sold (voucher) detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sold.php'; -$Sold = new EventManagementAdminSold($this->dbh, $this->config); -$type = false; -$id = false; -/* -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $type = 'member'; - $id = $this->page->userMemberID; -} -*/ -$soldList = $Sold->getSoldList($orderDetail['id'], false); - -// Get Venue Detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); -$memberDetail = $Members->getMemberDetail($orderDetail['member']); - -// Load voucher design code as per the "voucher_design" config parameter in the site's config/applications/EventManagement.ini file -if (is_file(EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucher.php')) { - require_once EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucher.php'; - $pdf = new PdfVoucher($orderDetail, $soldList, $memberDetail, $this->dbh, $this->config); -} else { - echo "SYSTEM ERROR: Site is not configured with a valid voucher design file."; - exit; -} - -// There's nothing to do from here. Output should go direct to browser. -exit; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Order/printVoucherMobile.inc b/legacy/models/admin/actions/Order/printVoucherMobile.inc deleted file mode 100755 index 00543ed..0000000 --- a/legacy/models/admin/actions/Order/printVoucherMobile.inc +++ /dev/null @@ -1,48 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: printVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get Order Detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); -$orderDetail = $Orders->getOrderDetail(); - -// Get Ticket Sold (voucher) detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sold.php'; -$Sold = new EventManagementAdminSold($this->dbh, $this->config); -$type = false; -$id = false; -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $type = 'member'; - $id = $this->page->userMemberID; -} -$soldList = $Sold->getSoldList(false, $id); - -// Get Venue Detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); -$memberDetail = $Members->getMemberDetail($orderDetail['member']); - -// Load voucher design code as per the "voucher_design" config parameter in the site's config/applications/EventManagement.ini file -if (is_file(EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucherMobile.php')) { - require_once EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucherMobile.php'; - $pdf = new PdfVoucher($orderDetail, $soldList, $memberDetail, $this->dbh, $this->config); -} else { - echo "SYSTEM ERROR: Site is not configured with a valid voucher design file."; - exit; -} - -// There's nothing to do from here. Output should go direct to browser. -exit; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Order/selected.inc b/legacy/models/admin/actions/Order/selected.inc deleted file mode 100755 index c79dd2d..0000000 --- a/legacy/models/admin/actions/Order/selected.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); - -$orderDetail = $Orders->getOrderDetail(); -$this->page->orderDetail = $this->bindArrayToObject($orderDetail); - -$this->templateFile = 'Order/selected.html'; - -$this->addDebug("Order/selected.inc", 'Order Detail', print_r($orderDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Order/update.inc b/legacy/models/admin/actions/Order/update.inc deleted file mode 100755 index 0304536..0000000 --- a/legacy/models/admin/actions/Order/update.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: update.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); - -// Process new record -$r = $Orders->updateOrder(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->orderDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$orderDetail = $Orders->getOrderDetail(); -$this->page->storedDetail = $this->bindArrayToObject($orderDetail); - -// If invalid submission -if (!$status) { - $this->page->editingOrder = true; - $this->templateFile = 'Order/edit.html'; -} else { - $this->templateFile = 'Order/detail.html'; -} - -$this->addDebug("Order/update.inc", 'Array: $r', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Performance/add.inc b/legacy/models/admin/actions/Performance/add.inc deleted file mode 100755 index eab9ba2..0000000 --- a/legacy/models/admin/actions/Performance/add.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: add.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - -// Get base data and fields -$r = $Performances->newPerformance(); - -$this->page->performanceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewPerformance = true; - -$this->templateFile = 'Performance/edit.html'; - -$this->addDebug("Performance/add.inc", 'Performance Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/confirmDelete.inc b/legacy/models/admin/actions/Performance/confirmDelete.inc deleted file mode 100755 index db150b1..0000000 --- a/legacy/models/admin/actions/Performance/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: confirmDelete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - -$performanceDetail = $Performances->performanceDelete(true); -$this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - -$this->templateFile = 'Performance/detail.html'; - -$this->addDebug("Performance/confirmDelete.inc", 'Performance Confirm Delete', print_r($performanceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/delete.inc b/legacy/models/admin/actions/Performance/delete.inc deleted file mode 100755 index 18ad6e9..0000000 --- a/legacy/models/admin/actions/Performance/delete.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: performance.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - - -$performanceDetail = $Performances->performanceDelete(false); -$this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - -$this->templateFile = 'Performance/delete.html'; - -$this->addDebug("Performance/delete.inc", 'Performance Delete', print_r($performanceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/detail.inc b/legacy/models/admin/actions/Performance/detail.inc deleted file mode 100755 index 4267af9..0000000 --- a/legacy/models/admin/actions/Performance/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - -$performanceDetail = $Performances->getPerformanceDetail(); -$this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - -$this->templateFile = 'Performance/detail.html'; - -$this->addDebug("Performance/detail.inc", 'Performance Detail', print_r($performanceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/edit.inc b/legacy/models/admin/actions/Performance/edit.inc deleted file mode 100755 index f410e10..0000000 --- a/legacy/models/admin/actions/Performance/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - -$performanceDetail = $Performances->editPerformance(); -$this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($performanceDetail); - -$this->page->editingPerformance = true; -$this->templateFile = 'Performance/edit.html'; - -$this->addDebug("Performance/edit.inc", 'Performance Edit', print_r($performanceDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/insert.inc b/legacy/models/admin/actions/Performance/insert.inc deleted file mode 100755 index 59b3642..0000000 --- a/legacy/models/admin/actions/Performance/insert.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - -// Process new record -$r = $Performances->insertPerformance(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->performanceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -$_SESSION[GLM_EVENT_SESSION]['Performance'] = $r['fieldData']['id']; - -// If invalid submission -if (!$status) { - $this->page->addingNewPerformance = true; - $this->templateFile = 'Performance/edit.html'; -} else { - $this->templateFile = 'Performance/selected.html'; -} - -$this->addDebug("Performance/insert.inc", 'Performance Insert', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/list.inc b/legacy/models/admin/actions/Performance/list.inc deleted file mode 100644 index dddb4f8..0000000 --- a/legacy/models/admin/actions/Performance/list.inc +++ /dev/null @@ -1,45 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - -// If this is a member user then make sure they only list their own member performances -$type = false; -$id = false; - -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $type = 'member'; - $id = $this->page->userMemberID; -} elseif ($_SESSION[GLM_EVENT_SESSION]['Member'] != false) { - $type = 'member'; - $id = $_SESSION[GLM_EVENT_SESSION]['Member']; -} - -$performanceList = $Performances->getPerformancesList($type, $id, true); - -$this->page->performanceList = $this->bindArrayToObject($performanceList); - -// Check if we also need to display a performance detail (list redisplay on performance update). -$this->page->displayPerformance = false; -if (isset($_REQUEST['performanceID']) && ($_REQUEST['performanceID']-0) > 0) { - $this->page->displayPerformance = ($_REQUEST['performanceID']-0); -} - -$this->templateFile = 'Performance/list.html'; - -$this->addDebug("Performance/list.inc", 'Performance List', 'Array: $performanceList

    '.print_r($performanceList,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/selected.inc b/legacy/models/admin/actions/Performance/selected.inc deleted file mode 100755 index a9df432..0000000 --- a/legacy/models/admin/actions/Performance/selected.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Members = new EventManagementAdminPerformances($this->dbh, $this->config); - -$performanceDetail = $Members->getPerformanceDetail(); - -$this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - -$this->templateFile = 'Performance/selected.html'; - -$this->addDebug("Performance/selected.inc", 'Performance Detail', print_r($performanceDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Performance/summary.inc b/legacy/models/admin/actions/Performance/summary.inc deleted file mode 100755 index 725859b..0000000 --- a/legacy/models/admin/actions/Performance/summary.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - -if ($_REQUEST['performanceID']) { - $id = $this->page->performanceID; -} - -$performanceSummary = $Performances->getPerformanceInventorySummary($id); - -$this->page->performanceSummary = $this->bindArrayToObject($performanceSummary); - -$this->templateFile = 'Performance/summary.html'; - -$this->addDebug("Performance/summary.inc", 'Performance Summary', 'Array: $performanceSummary

    '.print_r($performanceSummary,1)); - -?> - diff --git a/legacy/models/admin/actions/Performance/update.inc b/legacy/models/admin/actions/Performance/update.inc deleted file mode 100755 index 03c65ff..0000000 --- a/legacy/models/admin/actions/Performance/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; -$Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - - -// Process new record -$r = $Performances->updatePerformance(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->performanceDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->editingPerformance = true; - $this->templateFile = 'Performance/edit.html'; -} else { -// $this->templateFile = 'Performance/detail.html'; - $this->templateFile = 'Performance/redisplayList.html'; -} - -$this->addDebug("Performance/add.inc", 'Performance Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Promo/add.inc b/legacy/models/admin/actions/Promo/add.inc deleted file mode 100755 index fe0a740..0000000 --- a/legacy/models/admin/actions/Promo/add.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: add.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -$r = $Promos->newPromo(); - -$this->page->promoDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -$this->page->addingNewPromo = true; - -$this->templateFile = 'Promo/edit.html'; - -$this->addDebug("Promo/add.inc", 'Array: $r', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Promo/confirmDelete.inc b/legacy/models/admin/actions/Promo/confirmDelete.inc deleted file mode 100755 index aaccd6b..0000000 --- a/legacy/models/admin/actions/Promo/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: confirmDelete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -$promoDetail = $Promos->promoDelete(true); -$this->page->promoDetail = $this->bindArrayToObject($promoDetail); - -$this->templateFile = 'Promo/detail.html'; - -$this->addDebug("Promo/confirmDelete.inc", 'Section Confirm Delete', print_r($promoDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Promo/delete.inc b/legacy/models/admin/actions/Promo/delete.inc deleted file mode 100755 index 8ed6cf0..0000000 --- a/legacy/models/admin/actions/Promo/delete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: delete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -$promoDetail = $Promos->promoDelete(false); -$this->page->promoDetail = $this->bindArrayToObject($promoDetail); - -$this->templateFile = 'Promo/delete.html'; - -$this->addDebug("Promo/delete.inc", 'Array: $promoDetail', print_r($promoDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Promo/detail.inc b/legacy/models/admin/actions/Promo/detail.inc deleted file mode 100644 index 7275321..0000000 --- a/legacy/models/admin/actions/Promo/detail.inc +++ /dev/null @@ -1,80 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -// Get Promotions detail -$promoDetail = $Promos->getPromoDetail(); -$this->page->promoDetail = $this->bindArrayToObject($promoDetail); - -// Get list of tickets that can be used for adding a promotion ticket -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); -$where = "T.start_date < '".$promoDetail['end_date']['date']."' AND T.end_date > '".$promoDetail['start_date']['date']; -$tList = $Tickets->getTicketsList(false, false, false, false, false); -// Trim contents of ticketsList to just what's needed -$ticketsList = array(); -if (is_array($tList) && count($tList) > 0) { - foreach ($tList as $t) { - $ticketsList[$t['id']] = array( - 'id' => $t['id'], - 'name' => $t['name'], - 'performance' => $t['performance'] - ); - } - $this->page->ticketsList = $this->bindArrayToObject($ticketsList); -} - -// echo "

    ".print_r($ticketsList,1)."
    "; - -// Get list of Promotion Ticket Types -$pTTypes = $this->config->promo_ticket_type->toArray(); -$promoTicketTypes = array(); -while (list($k, $v) = each($pTTypes)) { - $promoTicketTypes[$k] = array( - 'id' => $k, - 'name' => $v - ); -} -$this->page->promoTicketTypes = $this->bindArrayToObject($promoTicketTypes); - -// Get Promotion Tickets for the currently selected promotion -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promoTickets.php'; -$PromoTickets = new EventManagementAdminPromoTickets($this->dbh, $this->config); -$promoTicketsList = $PromoTickets->processPromoTicketsList($promoDetail['id']); -$this->page->promoTicketsList = $this->bindArrayToObject($promoTicketsList); - -// Total sales -$numbTotal = 0; -$valTotal = 0; -if ($promoTicketsList) { - foreach($promoTicketsList as $ptl) { - $numbTotal += $ptl['numberSold']; - $valTotal += $ptl['valueSold']; - } -} -$dollarsTotal = $this->money($valTotal); -$this->page->numberTotal = $numbTotal; -$this->page->valueTotal = $valTotal; -$this->page->dollarsTotal = $dollarsTotal; - -$this->templateFile = 'Promo/detail.html'; - -$this->addDebug("Promo/detail.inc", 'Array: $promoDetail', print_r($promoDetail,1)); -$this->addDebug("Promo/detail.inc", 'Array: $promoTicketsList', print_r($promoTicketsList,1)); -$this->addDebug("Promo/detail.inc", 'Array: $promoTicketTypes', print_r($promoTicketTypes,1)); -$this->addDebug("Promo/detail.inc", 'Array: $ticketsList', print_r($ticketsList,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Promo/edit.inc b/legacy/models/admin/actions/Promo/edit.inc deleted file mode 100755 index ece6bb5..0000000 --- a/legacy/models/admin/actions/Promo/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: edit.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -$promoDetail = $Promos->editPromo(); -$this->page->promoDetail = $this->bindArrayToObject($promoDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->promoDetail = $this->bindArrayToObject($promoDetail); - -$this->page->editingPromo = true; - -$this->templateFile = 'Promo/edit.html'; - -$this->addDebug("Promo/edit.inc", 'Array: $promoDetail', print_r($promoDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Promo/insert.inc b/legacy/models/admin/actions/Promo/insert.inc deleted file mode 100755 index f90b9d9..0000000 --- a/legacy/models/admin/actions/Promo/insert.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: insert.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -// Process new record -$r = $Promos->insertPromo(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->promoDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewPromo = true; - $this->templateFile = 'Promo/edit.html'; -} else { - - $promoID = $r['fieldData']['id']; - - $this->templateFile = 'Promo/selected.html'; -} - -$this->addDebug("Promo/insert.inc", 'Array: $r', print_r($r,1)); - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Promo/list.inc b/legacy/models/admin/actions/Promo/list.inc deleted file mode 100755 index ac2435a..0000000 --- a/legacy/models/admin/actions/Promo/list.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: list.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -// Get Promotions stats -$promoStats = $Promos->getPromosStats(); -$this->page->promosStats = $this->bindArrayToObject($promosStats); - -// Get Promotions list -$promosList = $Promos->getPromosList(); -$this->page->promos = $this->bindArrayToObject($promosList); - -$this->templateFile = 'Promo/list.html'; - -$this->addDebug("Promo/list.inc", 'Array: $promosList', print_r($promosList, 1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Promo/selected.inc b/legacy/models/admin/actions/Promo/selected.inc deleted file mode 100755 index e705592..0000000 --- a/legacy/models/admin/actions/Promo/selected.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -$promoDetail = $Promos->getPromoDetail(); -$this->page->promoDetail = $this->bindArrayToObject($promoDetail); - -$this->templateFile = 'Promo/selected.html'; - -$this->addDebug("Promo/selected.inc", 'Promo Detail', print_r($promoDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Promo/update.inc b/legacy/models/admin/actions/Promo/update.inc deleted file mode 100755 index a7e4e45..0000000 --- a/legacy/models/admin/actions/Promo/update.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: update.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; -$Promos = new EventManagementAdminPromos($this->dbh, $this->config); - -// Process new record -$r = $Promos->updatePromo(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->promoDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$promoDetail = $Promos->getPromoDetail(); -$this->page->storedDetail = $this->bindArrayToObject($promoDetail); - -// If invalid submission -if (!$status) { - $this->page->editingPromo = true; - $this->templateFile = 'Promo/edit.html'; - $this->addDebug("Promo/update.inc", 'Array: $r', print_r($r,1)); -} else { - // $this->templateFile = 'Promo/detail.html'; - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/Promo/detail.inc'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Report/index.inc b/legacy/models/admin/actions/Report/index.inc deleted file mode 100755 index 1100b0c..0000000 --- a/legacy/models/admin/actions/Report/index.inc +++ /dev/null @@ -1,18 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: report.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->templateFile = 'Report/index.html'; - - -?> diff --git a/legacy/models/admin/actions/Report/member.inc b/legacy/models/admin/actions/Report/member.inc deleted file mode 100755 index a6a07c6..0000000 --- a/legacy/models/admin/actions/Report/member.inc +++ /dev/null @@ -1,176 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: member.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->optionIncludeSelectListData = false; - -// If this is an initial entry, display report selection form -if (!isset($_REQUEST['memberReport'])) { - - // Get a list of members - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; - $Members = new EventManagementAdminMembers($this->dbh, $this->config); - $members = $Members->getMembersList('all'); - $this->page->membersList = $this->bindArrayToObject($members); - - // Setup min and max dates for date selection - $minDate = date('m/d/Y', strtotime(date('m/d/Y').' -5 years')); - $maxDate = date('m/d/Y', strtotime(date('m/d/Y').' +5 years')); - $this->page->minDate = $minDate; - $this->page->maxDate = $maxDate; - - $this->templateFile = 'Report/memberReportSelection.html'; - -// Otherwise we have a report request -} else { - - $reportNote = 'Report Selection: '; - $reportSpacer = ''; - - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; - $Members = new EventManagementAdminMembers($this->dbh, $this->config); - - // Check if inactive selected - if ($_REQUEST['inactive'] == 'on') { - $where = 'true'; - $reportNote .= $reportSpacer."Active and Inactive"; - $reportSpacer = ", "; - } else { - $where = 'active'; - $reportNote .= $reportSpacer."Active only"; - $reportSpacer = ", "; - } - - // Check for selected member/venue - if ($_REQUEST['memberID'] > 0 ) { - $where .= ' AND id = '.$_REQUEST['memberID']; - $reportNote .= $reportSpacer.'Specific Venues'; - $reportSpacer = ", "; - } - - // Create date range for ticket sales stats if specified - $dateWhere = ''; - switch ($_REQUEST['dateRange']) { - case 'thisMonth': - $start = date('m/1/Y', time()); - $end = date('m/d/Y', strtotime(date('m/1/Y', time()).' +1 month -1 day')); - $dateWhere = "AND I.ticket_date BETWEEN '$start' AND '$end'"; - $reportNote .= $reportSpacer."This month only"; - $reportSpacer = ", "; - break; - case 'lastMonth': - $start = date('m/1/Y', strtotime(date('m/1/Y', time()).' -1 month')); - $end = date('m/d/Y', strtotime(date('m/1/Y', time()).' -1 day')); - $dateWhere = "AND I.ticket_date BETWEEN '$start' AND '$end'"; - $reportNote .= $reportSpacer."Last month only"; - $reportSpacer = ", "; - break; - case 'thisYear': - $start = date('1/1/Y', time()); - $end = date('m/d/Y', strtotime(date('1/1/Y', time()).' +1 year -1 day')); - $dateWhere = "AND I.ticket_date BETWEEN '$start' AND '$end'"; - $reportNote .= $reportSpacer."This year only"; - $reportSpacer = ", "; - break; - case 'lastYear': - $start = date('1/1/Y', strtotime(date('1/1/Y', time()).' -1 year')); - $end = date('m/d/Y', strtotime(date('1/1/Y', time()).' -1 day')); - $dateWhere = "AND I.ticket_date BETWEEN '$start' AND '$end'"; - $reportNote .= $reportSpacer."Last year only"; - $reportSpacer = ", "; - break; - case 'specified': - if ($_REQUEST['start_date'] != '' && $_REQUEST['end_date'] != '') { - $dateWhere = " AND I.ticket_date BETWEEN '".$_REQUEST['start_date']."' AND '".$_REQUEST['end_date']."'"; - $reportNote .= $reportSpacer.'Between '.$_REQUEST['start_date'].' and '.$_REQUEST['end_date']; - $reportSpacer = ', '; - } - break; - case 'all': - default: - } - - $membersList = $Members->getList($where, 'name'); - - $totals = array( - 'sections' => 0, - 'events' => 0, - 'tickets' => 0, - 'inventory' => 0, - 'sold' => 0, - 'price' => 0 - ); - if (is_array($membersList) && count($membersList) > 0) { - - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; - $Sections = new EventManagementAdminSections($this->dbh, $this->config); - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; - $Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/ticketInventory.php'; - $Inventory = new EventManagementAdminTicketInventory($this->dbh, $this->config); - - // Get summary of member stats - reset($membersList); - while (list($k, $v) = each($membersList)) { - $membersList[$k]['sectionStats'] = $Sections->getMemberSectionsStats($v['id']); - $totals['sections'] += $membersList[$k]['sectionStats']; - $membersList[$k]['performanceStats'] = $Performances->getMemberPerformancesStats($v['id']); - $totals['events'] += $membersList[$k]['performanceStats']; - $membersList[$k]['ticketStats'] = $Tickets->getMemberTicketsStats($v['id']); - $totals['tickets'] += $membersList[$k]['ticketStats']; - $membersList[$k]['ticketSalesStats'] = $Inventory->getMemberTicketInventorySalesStats($v['id'], $dateWhere); - $totals['inventory'] += $membersList[$k]['ticketSalesStats']['totalquant']; - $totals['sold'] += $membersList[$k]['ticketSalesStats']['totalsold']; - $totals['price'] += $membersList[$k]['ticketSalesStats']['totalprice']; - $membersList[$k]['ticketSalesStats']['totalMoney'] = $this->money($membersList[$k]['ticketSalesStats']['totalprice']); - } - $totals['price'] = $this->money($totals['price']); - - } - - $this->page->membersList = $this->bindArrayToObject($membersList); - $this->page->totals = $this->bindArrayToObject($totals); - $this->page->reportNote = $reportNote; - $this->page->reportDate = date('m/d/Y'); - $this->page->reportTime = date('h:m:s A'); - - // Check for output type - $this->page->printOutput = false; - $this->templateFile = 'Report/member.html'; - switch ($_REQUEST['outputType']) { - case 'html': - break; - case 'print': - $this->page->printOutput = true; - break; - case 'csv': - $this->template->compile($this->interface.'/Report/memberCSV.html'); - $csvOut = $this->template->bufferedOutputObject($this->page); - $len = strlen( $csvOut ); - header( "Content-type: application/octet-stream" ); - header( "Content-Length: $len" ); - header( "Content-Disposition: attachment; filename=report.csv" ); - echo $csvOut; - exit; - break; - } - - $this->addDebug("Report/member.inc", 'Member List', print_r($membersList,1)); - -} - - - -?> diff --git a/legacy/models/admin/actions/Report/orders.inc b/legacy/models/admin/actions/Report/orders.inc deleted file mode 100644 index 109807b..0000000 --- a/legacy/models/admin/actions/Report/orders.inc +++ /dev/null @@ -1,280 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: orders.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->optionIncludeSelectListData = false; -$this->page->users_access_all_members = $this->config->option->users_access_all_members; -$this->page->location_all_option = true; - -// If this is an initial entry, display report selection form -if (!isset($_REQUEST['ordersReport'])) { - - // Check if this is a log-in user to determine what access they have - Need at least "Ticket Orders & Claims" - $where = 'true'; - if ($_SESSION[GLM_EVENT_SESSION]['MemberUser'] && $_SESSION[GLM_EVENT_SESSION]['MemberUserLevel'] <= $this->config->permissions_numb->orders_and_claims) { - - // Setup where clause starting with the user member - $m = $_SESSION[GLM_EVENT_SESSION]['Member']; - $where = "id IN ($m"; - - // Get list of any members this user can scan for - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMemberScansFor.php'; - $MemberScansFor = new EventManagementDataMemberScansFor($this->dbh, $this->config); - $scansFor = $MemberScansFor->getMemberScansForList($m); - - if ($scansFor && count($scansFor) > 0) { - foreach($scansFor as $s) { - $where .= ','.$s['scans_for']; - } - } - - $where .= ')'; - - $this->page->location_all_option = false; - - } - - // Get a list of members - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; - $Members = new EventManagementAdminMembers($this->dbh, $this->config); - $members = $Members->getMembersList('all', $where); - - $mList = array(); - if (is_array($members) && count($members) > 0) { - - // Get a list of performances - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - // If access is permitted to all members by users in this site - if ($this->config->option->users_access_all_members) { - $performanceList = $Performances->getPerformancesList($type, false); - } else { - $performanceList = $Performances->getPerformancesList($type, $id); - } - - // Create simple list of members and their performances - reset($members); - while (list($k, $v) = each($members)) { - $mList[$v['id']] = array( - 'id' => $v['id'], - 'name' => $v['name'], - 'performance' => array() - ); - } - - } - - $this->page->mList = $this->bindArrayToObject($mList); - - // Setup min and max dates for date selection - $minDate = date('m/d/Y', strtotime(date('m/d/Y').' -5 years')); - $maxDate = date('m/d/Y', strtotime(date('m/d/Y').' +5 years')); - $this->page->minDate = $minDate; - $this->page->maxDate = $maxDate; - - $this->templateFile = 'Report/ordersReportSelection.html'; - - $this->addDebug("Report/ordersReportSelection.inc", 'Member & Property List', 'Array: $mList

    '.print_r($mList,1)); - -// Otherwise we have a report request -} else { - - $where = 'true'; - $reportNote = 'Report Selection: '; - $reportSpacer = ''; - - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; - $Orders = new EventManagementAdminOrders($this->dbh, $this->config); - - // Check for selected Venue - if ($_REQUEST['memberID'] > 0) { - $where .= ' AND member = '.$_REQUEST['memberID']; - $reportNote .= $reportSpacer.'Selected venue'; - $reportSpacer = ', '; - } - - // Check for inactive venues - if ($_REQUEST['inactive'] != 'on') { - $where .= ' AND member in (SELECT id FROM eventmgt.member WHERE active)'; - $reportNote .= $reportSpacer.'Active venues only'; - $reportSpacer = ', '; - } else { - $reportNote .= $reportSpacer.'Including inactive venues'; - $reportSpacer = ', '; - } - - // Check Purchase Date Range - switch($_REQUEST['dateType']) { - case 'sold': - if ($_REQUEST['start_date'] != '' && $_REQUEST['end_date'] != '') { - $where .= " AND purchase_date BETWEEN '".$_REQUEST['start_date']."' AND '".$_REQUEST['end_date']."'"; - $reportNote .= $reportSpacer.'Sold between '.$_REQUEST['start_date'].' and '.$_REQUEST['end_date']; - $reportSpacer = ', '; - } elseif ($_REQUEST['start_date'] != '' && $_REQUEST['end_date'] == '') { - $where .= " AND purchase_date = '".$_REQUEST['start_date']."'"; - $reportNote .= $reportSpacer.'Sold on '.$_REQUEST['start_date']; - $reportSpacer = ', '; - } - break; - case 'all': - default: - break; - } - - // Check Ticket or Likely Date Range - switch($_REQUEST['ticketDateType']) { - -// select count(id) from ticket_sold where (date_specific and ticket_date > '1/1/2014') OR (not date_specific and likely_date > '1/1/2015'); - case 'ticketDate': - if ($_REQUEST['outputType'] == 'csv') { - $sDate = filter_input(INPUT_GET, 'ticket_start_date', FILTER_SANITIZE_STRING); - $eDate = filter_input(INPUT_GET, 'ticket_end_date', FILTER_SANITIZE_STRING); - } else { - $sDate = filter_input(INPUT_POST, 'ticket_start_date', FILTER_SANITIZE_STRING); - $eDate = filter_input(INPUT_POST, 'ticket_end_date', FILTER_SANITIZE_STRING); - } - - if (trim($eDate) == '') { - $eDate = $sDate; - } - if ($sDate != '') { - $where .= " AND ( - SELECT count(id) FROM eventmgt.ticket_sold WHERE ticket_order = T.id - AND ( - (date_specific AND ticket_date BETWEEN '$sDate' AND '$eDate') - OR (NOT date_specific AND likely_date BETWEEN '$sDate' AND '$eDate') - ) - ) > 0"; - $reportNote .= $reportSpacer.'Ticket Date or Likely Date between '.$sDate.' and '.$eDate; - $reportSpacer = ', '; - } - break; - case 'all': - default: - break; - } - - // Check if only doing E-Mail OK on - if ($_REQUEST['emailOK'] == 'on') { - $where .= ' AND email_ok'; - } - - // Check for other fields - $orderID = $_REQUEST['orderID'] - 0; - if ($orderID) { - $where .= " AND id = $orderID"; - } - $lname = filter_input(INPUT_POST, 'lname', FILTER_SANITIZE_STRING); - if ($lname != '') { - $where .= " AND lname ILIKE '$lname%'"; - } - $fname = filter_input(INPUT_POST, 'fname', FILTER_SANITIZE_STRING); - if ($fname != '') { - $where .= " AND fname ILIKE '$fname%'"; - } - $city = filter_input(INPUT_POST, 'city', FILTER_SANITIZE_STRING); - if ($city != '') { - $where .= " AND city ILIKE '$city%'"; - } - $state = filter_input(INPUT_POST, 'state', FILTER_SANITIZE_STRING); - if ($state != '') { - $where .= " AND state = '$state'"; - } - $zip = filter_input(INPUT_POST, 'zip', FILTER_SANITIZE_STRING); - if ($zip != '') { - $where .= " AND zip = '$zip'"; - } - $phone = filter_input(INPUT_POST, 'phone', FILTER_SANITIZE_STRING); - if ($phone != '') { - $where .= " AND phone ILIKE '$phone%'"; - } - - // Order By - $orderBy = ''; - switch($_REQUEST['sortType']) { - case 'id': - $orderBy = 'id'; - break; - case 'date': - $orderBy = 'purchase_date, lname, fname'; - break; - case 'name': - $orderBy = 'lname, fname'; - break; - case 'location': - $orderBy = 'country, state, city, lname, fname'; - break; - case 'venue_date': - $orderBy = 'member_name, purchase_date, lname, fname'; - break; - case 'venue_name': - $orderBy = 'member_name, lname, fname'; - break; - } - - // Get list of selected orders - $ordersList = $Orders->getList($where, $orderBy); - - // Build totals - if ($ordersList != false && count($ordersList) > 0) { - reset($ordersList); - $orders = 0; - $total = 0; - foreach ($ordersList as &$ord) { - $orders++; - $total += $ord['charge_numb']; - } - } - -//var_dump($ordersList);exit; - - $this->page->ordersList = $this->bindArrayToObject($ordersList); - $this->page->reportNote = $reportNote; - $this->page->reportDate = date('m/d/Y'); - $this->page->reportTime = date('h:m:s A'); - - $this->page->numbOrders = $orders; - $this->page->totalCharges = $total; - $this->page->averageOrder = $this->money(($orders > 0 ? $total/$orders : 0)); - $this->page->totalChargesMoney = $this->money($total); - - // Check for output type - $this->page->printOutput = false; - switch ($_REQUEST['outputType']) { - case 'html': - break; - case 'print': - $this->page->printOutput = true; - break; - case 'csv': - $this->template->compile($this->interface.'/Report/ordersCSV.html'); - $csvOut = $this->template->bufferedOutputObject($this->page); - $len = strlen( $csvOut ); - header( "Content-type: application/octet-stream" ); - header( "Content-Length: $len" ); - header( "Content-Disposition: attachment; filename=report.csv" ); - echo $csvOut; - exit; - break; - } - - $this->templateFile = 'Report/orders.html'; - - $this->addDebug("Report/orders.inc", 'Orders List', print_r($ordersList,1)); - - -} - - - -?> diff --git a/legacy/models/admin/actions/Report/promo.inc b/legacy/models/admin/actions/Report/promo.inc deleted file mode 100644 index c1f7b20..0000000 --- a/legacy/models/admin/actions/Report/promo.inc +++ /dev/null @@ -1,293 +0,0 @@ - - * @release SVN: $Id: ticket.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->optionIncludeSelectListData = false; -$errorMsg = ''; - -// If this is an initial entry, display report selection form -if (!isset($_REQUEST['promoReport'])) { - - // Get a list of Promo Codes - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/promos.php'; - $Promos = new EventManagementAdminPromos($this->dbh, $this->config); - $promos = $Promos->getPromosList('all'); - $this->page->promos = $this->bindArrayToObject($promos); - - $this->templateFile = 'Report/promoReportSelection.html'; - - $this->addDebug("Report/promoReportSelection.inc", 'Promo Code Lists', 'Array: $mList

    '.print_r($promos,1)); - -// Otherwise we have a report request -} else { - - // Build selection - $where = ''; - $reportNote = ''; - $reportSpacer = ''; - $from = ''; - - // Check for selected Promo - if ($_REQUEST['promoID'] > 0) { - $where .= ' AND S.promo = '.$_REQUEST['promoID']; - $reportNote .= $reportSpacer.'Specified Promotion'; - $reportSpacer = ', '; - $selectionProblem = false; - } - - // Check Date Range - $dateFrom = $_REQUEST['start_date']; - $dateTo = $_REQUEST['end_date']; - $dateRange = "between $dateFrom and $dateTo"; - if ($dateTo == '') { - $dateTo = $dateFrom; - $dateRange = "on $dateFrom"; - } - switch($_REQUEST['dateType']) { - case 'sold': - if ($dateFrom != '' && $dateTo != '') { - $where .= "\nAND K.purchase_date BETWEEN '$dateFrom' AND '$dateTo'"; - $reportNote .= $reportSpacer."Sold $dateRange"; - $reportSpacer = ', '; - } - break; - case 'ticket': - if ($dateFrom != '' && $dateTo != '') { - $where .= "\nAND S.ticket_date BETWEEN '$dateFrom' AND '$dateTo'"; - $reportNote .= $reportSpacer."Ticket dates $dateRange"; - $reportSpacer = ', '; - } - break; - case 'claimed': - if ($dateFrom != '' && $dateTo != '') { - $where .= " - AND ( - SELECT count(id) - FROM eventmgt.ticket_claim_tracking - WHERE ticket_sold = S.id - AND time_of_action BETWEEN '$dateFrom' AND '$dateTo' - ) > 0 - "; - $reportNote .= $reportSpacer."Ticket dates $dateRange"; - $reportSpacer = ', '; - } - break; - case 'all': - default: - break; - } - - // Check for valid report type - $reportType = $_REQUEST['reportType']; - if ($reportType == 'detail' && $_REQUEST['promoID'] == 0) { - $errorMsg .= "Detail reports are only available when selecting a specific promo code.
    "; - } else { - - // Check report type - default to summary - $detailSelect = ''; - switch ($_REQUEST['reportType']) { - - case 'detail': - - // Get Data - $sql = "SELECT S.promo, COUNT(S.amount), SUM(S.amount), T.performance_name, T.ticket_name, - S.promo_name, S.amount, C.long_name, K.fname, K.lname, K.city, K.purchase_date - FROM eventmgt.promo_sold S, eventmgt.promo_code C, eventmgt.ticket_sold T, eventmgt.ticket_order K - WHERE T.id = S.ticket_sold - AND K.id = S.ticket_order - AND C.id = S.promo - $where - GROUP BY C.long_name, S.promo, S.amount, S.promo_name, T.performance_name, T.ticket_name, S.amount, - K.fname, K.lname, K.city, K.purchase_date - ORDER BY C.long_name, T.performance_name, T.ticket_name - ;"; - - $this->templateFile = 'Report/promoSummary.html'; - break; - - default: - case 'summary': - - // Get Data - $sql = "SELECT S.promo, COUNT(S.amount), SUM(S.amount), T.performance_name, T.ticket_name, - S.promo_name, S.amount, C.long_name - FROM eventmgt.promo_sold S, eventmgt.promo_code C, eventmgt.ticket_sold T - WHERE T.id = S.ticket_sold - AND C.id = S.promo - $where - GROUP BY C.long_name, S.promo, S.amount, S.promo_name, T.performance_name, T.ticket_name, S.amount - ORDER BY C.long_name, T.performance_name, T.ticket_name - ;"; - - $this->templateFile = 'Report/promoSummary.html'; - break; - } - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $promos = $stmt->fetchAll(PDO::FETCH_ASSOC); - - $totalEntries = 0; - $totalCount = 0; - $totalDiscount = 0; - $currentPromo = false; - $currentPerformance = false; - $currentItem = false; - - // Build totals and process fields - if ( is_array($promos) ) { - - while (list ($key, $val) = each ($promos)) { - - // Change all discount values to positive - $promos[$key]['amountMoney'] = number_format($val['amount']*-1,2); - $promos[$key]['sumMoney'] = number_format($val['sum']*-1,2); - - // Add this promo to the grand totals - $totalEntries++; - $totalCount += $promos[$key]['count']; - $totalDiscount += abs($promos[$key]['sum']); - - // If this is the same promo, don't display promo names again - if ($currentPromo == $val['promo_name']) { - $promos[$key]['promo_name'] = ''; - $promos[$key]['long_name'] = ''; - } else { - $currentPromo = $val['promo_name']; - $currentPerformance = false; - $currentItem = false; - } - - // If this is the same Performance - if ($currentPerformance == $val['performance_name']) { - $promos[$key]['performance_name'] = ''; - } else { - $currentPerformance = $val['performance_name']; - $currentItem = false; - } - - // If this is the same Item - if ($currentItem == $val['ticket_name']) { - $promos[$key]['ticket_name'] = ''; - } else { - $currentItem = $val['ticket_name']; - } - - } - - // Provide totals and detail to template - $this->page->totalEntries = $totalEntries; - $this->page->totalCount = $totalCount; - $this->page->totalDiscount = number_format($totalDiscount,2); - $this->page->havePromoList = true; - $this->page->promoList = $this->bindArrayToObject($promos); - - } - - - } // valid request - -// echo "

    ".print_r($promos,1)."
    "; - -/* - // Get data - $sql = " - SELECT S.id, S.member, S.member_name, S.performance, S.performance_name, S.section, S.section_name, - S.ticket_order, S.ticket, S.ticket_date, S.ticket_time, S.price_paid, S.time_claimed, - T.unlimited_quant, T.quant, T.name AS ticket_name, - M.active, - R.purchase_date, - $detailSelect - ( - SELECT sum(quant) - FROM eventmgt.ticket_claim_tracking - WHERE ticket_sold = S.id - ) as claimed - FROM eventmgt.ticket_sold S, eventmgt.ticket T, eventmgt.member M, eventmgt.ticket_order R - WHERE T.id = S.ticket - AND M.id = S.member - AND R.id = S.ticket_order - $where - ORDER BY member_name, performance_name, section_name, ticket_name - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $sales = $stmt->fetchAll(PDO::FETCH_ASSOC); -*/ - -/* - $this->page->salesList = $this->bindArrayToObject($out); - $this->page->totalQuant = $totalQuant; - $this->page->totalSold = $totalSold; - if ($totalQuant > 0) { - $this->page->percentSold = number_format(($totalSold/$totalQuant)*100,2); - } else { - $this->page->percentSold = '0'; - } - $this->page->totalClaimed = $totalClaimed; - if ($totalSold > 0) { - $this->page->percentClaimed = number_format(($totalClaimed/$totalSold)*100,2); - } else { - $this->page->percentClaimed = '0'; - } - $this->page->totalPromos = $totalPromos; - $this->page->totalPromosMoney = $this->money($totalPromos); - $this->page->totalPrice = $totalPrice; - $this->page->totalMoney = $this->money($totalPrice); -*/ - - if ($reportNote != '') { - $reportNote = 'Report Selection: '.$reportNote; - } else { - $reportNote = false; - } - $this->page->reportNote = $reportNote; - $this->page->reportDate = date('m/d/Y'); - $this->page->reportTime = date('h:m:s A'); - - // Get Output type - $outputType = $_REQUEST['outputType']; - - $this->page->errorMsg = $errorMsg; - if ($errorMsg != '') { - $outputType = 'error'; - } - - // Check for output type - $this->page->printOutput = false; - switch ($outputType) { - case 'error'; - $this->templateFile = 'Report/error.html'; - case 'html': - break; - case 'print': - $this->page->printOutput = true; - break; - case 'csv': - $this->template->compile($this->interface.$templateFileCSV); - $csvOut = $this->template->bufferedOutputObject($this->page); - $len = strlen( $csvOut ); - header( "Content-type: application/octet-stream" ); - header( "Content-Length: $len" ); - header( "Content-Disposition: attachment; filename=report.csv" ); - echo $csvOut; - exit; - break; - } - - $this->addDebug("Report/sales.inc", 'Sales Report', 'Array: $a

    '.print_r($a,1)); - -} - - - -?> diff --git a/legacy/models/admin/actions/Report/sales.inc b/legacy/models/admin/actions/Report/sales.inc deleted file mode 100644 index a6ae308..0000000 --- a/legacy/models/admin/actions/Report/sales.inc +++ /dev/null @@ -1,721 +0,0 @@ - - * @release SVN: $Id: ticket.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->optionIncludeSelectListData = false; - -// If this is an initial entry, display report selection form -if (!isset($_REQUEST['salesReport'])) { - - // Get a list of members - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; - $Members = new EventManagementAdminMembers($this->dbh, $this->config); - $members = $Members->getMembersList('all'); - - $mList = array(); - - if (is_array($members) && count($members) > 0) { - - // Get a list of performances - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - $performanceList = $Performances->getPerformancesList($type, $id); - - // Create simple list of members and their performances - reset($members); - while (list($k, $v) = each($members)) { - $mList[$v['id']] = array( - 'id' => $v['id'], - 'name' => $v['name'], - 'performance' => array() - ); - } - - reset($performanceList); - while (list($k, $v) = each($performanceList)) { - $mList[$v['member_id']]['performance'][$v['id']] = array( - 'id' => $v['id'], - 'name' => $v['name'] - ); - } - - } - - $this->page->mList = $this->bindArrayToObject($mList); - - // Setup min and max dates for date selection - $minDate = date('m/d/Y', strtotime(date('m/d/Y').' -5 years')); - $maxDate = date('m/d/Y', strtotime(date('m/d/Y').' +5 years')); - $this->page->minDate = $minDate; - $this->page->maxDate = $maxDate; - - $this->templateFile = 'Report/salesReportSelection.html'; - - $this->addDebug("Report/salesReportSelection.inc", 'Member & Property List', 'Array: $mList

    '.print_r($mList,1)); - -// Otherwise we have a report request -} else { - - // Build selection - $where = ''; - $reportNote = 'Report Selection: '; - $reportSpacer = ''; - - // Check report type - default to summary - $detailSelect = ''; - switch ($_REQUEST['reportType']) { - case 'detail': - $reportType = 'detail'; - $detailSelect = 'R.id AS order_id, R.fname, R.lname, R.addr1, R.addr2, R.city, R.state, R.zip, R.country, R.phone,'; - $templateFile = 'Report/salesDetail.html'; - $templateFileCSV = '/Report/salesDetailCSV.html'; - break; - case 'packageTicket': - $reportType = 'summary'; - $reportOption = 'packageTickets'; - $templateFile = 'Report/salesPackageTickets.html'; - $templateFileCSV = '/Report/salesPackageTicketsCSV.html'; - break; - default: - case 'summary': - $reportType = 'summary'; - $templateFile = 'Report/sales.html'; - $templateFileCSV = '/Report/salesCSV.html'; - break; - } - - // Check for selected Venue - if ($_REQUEST['memberID'] > 0) { - $where .= ' AND S.member = '.$_REQUEST['memberID']; - $reportNote .= $reportSpacer.'Selected venue'; - $reportSpacer = ', '; - } - - // Check for selected Performance - if ($_REQUEST['performanceID'] > 0) { - $where .= ' AND S.performance = '.$_REQUEST['performanceID']; - $reportNote .= $reportSpacer.'Selected performance'; - $reportSpacer = ', '; - } - - // Check for inactive venues - if ($_REQUEST['inactive'] != 'on') { - $where .= ' AND M.active = true'; - $reportNote .= $reportSpacer.'Active venues only'; - $reportSpacer = ', '; - } else { - $reportNote .= $reportSpacer.'Including inactive venues'; - $reportSpacer = ', '; - } - - // Check Date Range - $dateFrom = $_REQUEST['start_date']; - $dateTo = $_REQUEST['end_date']; - $dateRange = "between $dateFrom and $dateTo"; - if ($dateTo == '') { - $dateTo = $dateFrom; - $dateRange = "on $dateFrom"; - } - switch($_REQUEST['dateType']) { - case 'sold': - if ($dateFrom != '' && $dateTo != '') { - $where .= "\nAND R.purchase_date BETWEEN '$dateFrom' AND '$dateTo'"; - $reportNote .= $reportSpacer."Sold $dateRange"; - $reportSpacer = ', '; - } - break; - case 'ticket': - if ($dateFrom != '' && $dateTo != '') { - $where .= "\nAND S.ticket_date BETWEEN '$dateFrom' AND '$dateTo'"; - $reportNote .= $reportSpacer."Ticket dates $dateRange"; - $reportSpacer = ', '; - } - break; - case 'claimed': - if ($dateFrom != '' && $dateTo != '') { - $where .= " - AND ( - SELECT count(id) - FROM eventmgt.ticket_claim_tracking - WHERE ticket_sold = S.id - AND time_of_action BETWEEN '$dateFrom' AND '$dateTo' - ) > 0 - "; - $reportNote .= $reportSpacer."Ticket dates $dateRange"; - $reportSpacer = ', '; - } - break; - case 'all': - default: - break; - } - - // Check for claimed only - if ($_REQUEST['claimed'] == 'on') { - $where .= " - AND ( - SELECT count(id) - FROM eventmgt.ticket_claim_tracking - WHERE ticket_sold = S.id - ) > 0 - "; - $reportNote .= $reportSpacer.'Claimed tickets only'; - $reportSpacer = ', '; - } - - // Check for whether we should report only on package tickets - $packageWhere = " AND (S.ticket_package IS NULL OR S.ticket_package < 1)"; - $priceSelect = " S.price_paid"; - if ($reportOption == "packageTickets") { - $packageWhere = " AND S.ticket_package > 0"; - $priceSelect = " (SELECT price FROM eventmgt.ticket WHERE id = S.ticket) AS price_paid"; - $reportNote .= $reportSpacer.'Package Tickets Only'; - } - - - // Fix Promo_Sold amount data ******************* REMOVE ONCE STORING OF PROMO_SOLD AMOUNT IS FIXED ***************************** -/* - $sql = " - UPDATE eventmgt.promo_sold - SET amount = eventmgt.promo_ticket.amount * -1 - FROM eventmgt.promo_ticket, eventmgt.ticket_sold - WHERE eventmgt.ticket_sold.id = eventmgt.promo_sold.ticket_sold - AND eventmgt.promo_ticket.ticket = eventmgt.ticket_sold.ticket - AND eventmgt.promo_ticket.promo = eventmgt.promo_sold.promo - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); -*/ - - // Get data - Note that tickets sold as part of a package have a ticket_package ID but don't have $s sold values. These are excluded from the results. - $sql = " - SELECT S.id, S.member, S.member_name, S.performance, S.performance_name, S.section, S.section_name, - S.ticket_order, S.ticket, S.ticket_date, S.ticket_time, $priceSelect, S.time_claimed, - T.unlimited_quant, T.quant, T.name AS ticket_name, - M.active, - R.purchase_date, - $detailSelect - ( - SELECT sum(quant) - FROM eventmgt.ticket_claim_tracking - WHERE ticket_sold = S.id - ) as claimed - FROM eventmgt.ticket_sold S, eventmgt.ticket T, eventmgt.member M, eventmgt.ticket_order R - WHERE T.id = S.ticket - AND M.id = S.member - AND R.id = S.ticket_order - $packageWhere - $where - ORDER BY member_name, performance_name, section_name, ticket_name - ;"; -// echo "

    ".print_r($sql,1)."
    "; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $sales = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Compile output array and totals - $totalQuant = 0; - $totalSold = 0; - $totalClaimed = 0; - $totalPromos = 0; - $totalPrice = 0; - $a = array(); - - // Array used for quantity control - $ticDate = array(); - - // Values to check if we're still on the same entity - $membLast = false; - $perfLast = false; - $sectLast = false; - $tickLast = false; - $dateLast = false; - - // Scan results and build interim report array - reset($sales); - - foreach ($sales as &$s) { - - // Need to determine if we're doing blank rather than number for unlimited quant - $q = ''; - if (!$s['unlimited_quant']) { - $q = 0; - } - - // If member hasn't been created - if (!isset($a[$s['member']])) { - $a[$s['member']] = array( - 'id' => $s['member'], - 'name' => $s['member_name'], - 'quant' => $q, - 'sold' => 0, - 'claimed' => 0, - 'price' => 0, - 'money' => 0, - 'performance' => array() - ); - } - $memb = &$a[$s['member']]; - - // If performance hasn't been created - if (!isset($memb['performance'][$s['performance']])) { - $memb['performance'][$s['performance']] = array( - 'id' => $s['performance'], - 'name' => $s['performance_name'], - 'quant' => $q, - 'sold' => 0, - 'claimed' => 0, - 'price' => 0, - 'money' => 0, - 'section' => array() - ); - } - $perf = &$memb['performance'][$s['performance']]; - - // If section hasn't been created - if (!isset($perf['section'][$s['section']])) { - $perf['section'][$s['section']] = array( - 'id' => $s['section'], - 'name' => $s['section_name'], - 'quant' => $q, - 'sold' => 0, - 'claimed' => 0, - 'price' => 0, - 'money' => 0, - 'ticket' => array() - ); - } - $sect = &$perf['section'][$s['section']]; - - // If ticket hasn't been created - if (!isset($sect['ticket'][$s['ticket']])) { - $sect['ticket'][$s['ticket']] = array( - 'id' => $s['ticket'], - 'name' => $s['ticket_name'], - 'quant' => $q, - 'sold' => 0, - 'claimed' => 0, - 'price' => 0, - 'money' => 0, - 'add_on' => array(), - 'date' => array() - ); - } - $tick = &$sect['ticket'][$s['ticket']]; - - // If date hasn't been created - if (!isset($tick['date'][$s['ticket_date']])) { - $tick['date'][$s['ticket_date']] = array( - 'date' => $s['ticket_date'], - 'quant' => $q, - 'sold' => 0, - 'claimed' => 0, - 'price' => 0, - 'money' => 0, - 'time' => array() - ); - } - $date = &$tick['date'][$s['ticket_date']]; - - // If time hasn't been created - if (!isset($date['time'][$s['ticket_time']])) { - - if ($s['ticket_time'] == '12:00:00') { - $timeString = ''; - } else { - $t = explode(':', $s['ticket_time']); - $ampm = 'AM'; - $hour = ($t[0] - 0); - if ($hour > 11) { - $ampm = 'PM'; - } else { - } - if ($hour > 12) { - $hour -= 12; - } - $timeString = sprintf('%2d:%02d %s', $hour, $min, $ampm); - } - - $date['time'][$s['ticket_time']] = array( - 'time' => $timeString, - 'quant' => $q, - 'sold' => 0, - 'claimed' => 0, - 'promo' => 0, - 'promo_money' => 0, - 'price' => 0, - 'money' => 0, - 'detail' => array() - ); - - } - $time = &$date['time'][$s['ticket_time']]; - - // Check for Add-ons for this tickets - $sql = " - SELECT add_on_name, add_on_type, add_on_type_name, unit_price, quant, price_paid - FROM eventmgt.add_on_sold - WHERE ticket_sold = ".$s['id']." - ORDER BY add_on_name - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $addOns = $stmt->fetchAll(PDO::FETCH_ASSOC); - if (count($addOns) > 0) { - foreach ($addOns as $addOn) { - - // *** NEED TO MOVE THIS TO USING Add-On ID rather than name when that's added to the record. - if (!isset($tick['add_on'][$addOn['add_on_name']])) { - $tick['add_on'][$addOn['add_on_name']] = array( - 'name' => $addOn['add_on_name'], - 'type' => $addOn['add_on_type'], - 'quant' => $addOn['quant'], - 'price' => $addOn['price_paid'], - 'money' => $this->money($addOn['price_paid']) - ); - } else { - $tick['add_on'][$addOn['add_on_name']]['quant'] += $addOn['quant']; - $tick['add_on'][$addOn['add_on_name']]['price'] += $addOn['price_paid']; - $tick['add_on'][$addOn['add_on_name']]['money'] = $this->money($tick['add_on'][$addOn['add_on_name']]['price']); - } - - // Add to total price - $totalPrice += $addOn['price_paid']; - - } - } - - // Check for any promotion - $sql = " - SELECT amount - FROM eventmgt.promo_sold - WHERE ticket_sold = ".$s['id']." - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $promos = $stmt->fetchAll(PDO::FETCH_ASSOC); - $promoAmount = 0; - if (count($promos) > 0) { - foreach ($promos as $promo) { - $promoAmount += $promo['amount']; - } - } - - // Determine if unlimited quantity available and don't display quant if so. - if (!$s['unlimited_quant']) { - - // Only add to quantity if this date for this ticket hasn't been added yet - $ticDateTime = $s['ticket'].'-'.$s['ticket_date'].'-'.$s['ticket_time']; - if (!isset( $ticDate[$ticDateTime])) { - - // Mark that we've already added quants for this date and time - $ticDate[$ticDateTime] = true; - - // Add quantities for this date and time only for this occurrance - $q = $s['quant']; - $memb['quant'] += $q; - $perf['quant'] += $q; - $sect['quant'] += $q; - $tick['quant'] += $q; - $date['quant'] += $q; - $time['quant'] += $q; - $totalQuant += $q; - - } - - } - - // Add this ticket sold - $memb['sold']++; - $perf['sold']++; - $perf['price'] += $s['price_paid']; - $sect['sold']++; - $sect['price'] += $s['price_paid']; - $tick['sold']++; - $tick['price'] += $s['price_paid']; - $date['sold']++; - $date['price'] += $s['price_paid']; - $time['sold']++; - $time['price'] += $s['price_paid'] + $promoAmount; - $time['promo'] += $promoAmount; - $totalSold++; - $totalPromos += $promoAmount; - $totalPrice += $s['price_paid'] + $promoAmount; - - if ($s['claimed'] != '') { - $memb['memb_claimed'] += $s['claimed']; - $perf['perf_claimed'] += $s['claimed']; - $sect['sect_claimed'] += $s['claimed']; - $tick['tick_claimed'] += $s['claimed']; - $date['date_claimed'] += $s['claimed']; - $time['time_claimed'] += $s['claimed']; - $totalClaimed++; - } - - // Check if we're doing a detail report - if ($reportType == 'detail') { - $time['detail'][] = array( - 'order_id' => $s['order_id'], - 'voucher_id' => $s['id'], - 'fname' => $s['fname'], - 'lname' => $s['lname'], - 'addr1' => $s['addr1'], - 'addr2' => $s['addr2'], - 'city' => $s['city'], - 'state' => $s['state'], - 'zip' => $s['zip'], - 'country' => $s['country'], - 'phone' => $s['phone'] - ); - } - - } - - // Convert report array to individual lines - $out = array(); - reset($a); - foreach ($a as &$m) { - $line = array( - 'memb_id' => $m['id'], - 'memb_name' => $m['name'], - 'memb_quant' => $m['quant'], - 'memb_sold' => $m['sold'], - 'memb_claimed' => $m['memb_claimed'], - 'memb_price' => $m['price'], - 'memb_money' => $this->money($m['price']) - ); - foreach ($m['performance'] as &$p ) { - $line = array_merge($line, array( - 'perf_id' => $p['id'], - 'perf_name' => $p['name'], - 'perf_quant' => $p['quant'], - 'perf_sold' => $p['sold'], - 'perf_claimed' => $p['perf_claimed'], - 'perf_price' => $p['price'], - 'perf_money' => $this->money($p['price']) - )); - foreach ($p['section'] as &$s) { - $line = array_merge($line, array( - 'sect_id' => $s['id'], - 'sect_name' => $s['name'], - 'sect_quant' => $s['quant'], - 'sect_sold' => $s['sold'], - 'sect_claimed' => $s['sect_claimed'], - 'sect_price' => $s['price'], - 'sect_money' => $this->money($s['price']) - )); - foreach ($s['ticket'] as &$t) { - $line = array_merge($line, array( - 'tick_id' => $t['id'], - 'tick_name' => $t['name'], - 'tick_quant' => $t['quant'], - 'tick_sold' => $t['sold'], - 'tick_claimed' => $t['tick_claimed'], - 'tick_price' => $t['price'], - 'tick_money' => $this->money($t['price']) - )); - - // Sort dates - usort($t['date'], function($a, $b) { - return strcmp(strtotime($a['date']), strtotime($b['date'])); - }); - - foreach ($t['date'] as &$d) { - $line = array_merge($line, array( - 'date_date' => $d['date'], - 'date_quant' => $d['quant'], - 'date_sold' => $d['sold'], - 'date_claimed' => $d['date_claimed'], - 'date_price' => $d['price'], - 'date_money' => $this->money($d['price']) - )); - - // Sort times - usort($d['time'], function($a, $b) { - return strcmp($a['time'], $b['time']); - }); - - foreach ($d['time'] as &$i) { - $line = array_merge($line, array( - 'time_time' => $i['time'], - 'time_quant' => $i['quant'], - 'time_sold' => $i['sold'], - 'time_claimed' => $i['time_claimed'], - 'time_price' => $i['price'], - 'time_money' => ($i['price']!=0 ? $this->money($i['price']) : ''), - 'time_promo' => $i['promo'], - 'time_promo_money' => ($i['promo']!=0 ? $this->money($i['promo']) : '') - )); - - $out[] = $line; - - - // Initialize line data - $line = array( - 'memb_id' => '', - 'memb_name' => '', - 'memb_quant' => '', - 'memb_sold' => '', - 'memb_claimed' => '', - 'memb_price' => '', - 'memb_money' => '', - 'perf_id' => '', - 'perf_name' => '', - 'perf_quant' => '', - 'perf_sold' => '', - 'perf_claimed' => '', - 'perf_price' => '', - 'perf_money' => '', - 'sect_id' => '', - 'sect_name' => '', - 'sect_quant' => '', - 'sect_sold' => '', - 'sect_claimed' => '', - 'sect_price' => '', - 'sect_money' => '', - 'tick_id' => '', - 'tick_name' => '', - 'tick_quant' => '', - 'tick_sold' => '', - 'tick_claimed' => '', - 'tick_price' => '', - 'tick_money' => '', - 'addon_name' => '', - 'addon_quant' => '', - 'addon_sold' => '', - 'addon_claimed' => '', - 'addon_price' => '', - 'addon_money' => '', - 'date_id' => '', - 'date_name' => '', - 'date_quant' => '', - 'date_sold' => '', - 'date_claimed' => '', - 'date_price' => '', - 'date_money' => '', - 'order_id' => '', - 'order_fname' => '', - 'order_lname' => '', - 'order_addr1' => '', - 'order_addr2' => '', - 'order_city' => '', - 'order_state' => '', - 'order_zip' => '', - 'order_country' => '', - 'order_phone' => '' - ); - - - // If Detail report then output individual ticket customer data - if ($reportType == 'detail') { - - $orderID = ''; - foreach ($i['detail'] as $detail) { - - // Don't replicate order ID if it's the same for multiple lines - if ($orderID == $detail['order_id']) { - $detail['order_id'] = ''; - } else { - $orderID = $detail['order_id']; - } - - $out[] = array_merge($line, array( - 'order_id' => $detail['order_id'], - 'order_voucher_id' => $detail['voucher_id'], - 'order_fname' => $detail['fname'], - 'order_lname' => $detail['lname'], - 'order_addr1' => $detail['addr1'], - 'order_addr2' => $detail['addr2'], - 'order_city' => $detail['city'], - 'order_state' => $detail['state'], - 'order_zip' => $detail['zip'], - 'order_country' => $detail['country'], - 'order_phone' => $detail['phone'] - )); - - } - - } - - } - } - - foreach ($t['add_on'] as $addOn) { - $line = array( - 'addon_id' => 0, // Not using yet - 'addon_name' => $addOn['name'], - 'addon_sold' => $addOn['quant'], - 'time_claimed' => '', - 'time_price' => $addOn['price'], - 'time_money' => $addOn['money'] - ); - $out[] = $line; - } - - - } - } - } - } - - $this->page->salesList = $this->bindArrayToObject($out); - $this->page->totalQuant = $totalQuant; - $this->page->totalSold = $totalSold; - if ($totalQuant > 0) { - $this->page->percentSold = number_format(($totalSold/$totalQuant)*100,2); - } else { - $this->page->percentSold = '0'; - } - $this->page->totalClaimed = $totalClaimed; - if ($totalSold > 0) { - $this->page->percentClaimed = number_format(($totalClaimed/$totalSold)*100,2); - } else { - $this->page->percentClaimed = '0'; - } - $this->page->totalPromos = $totalPromos; - $this->page->totalPromosMoney = $this->money($totalPromos); - $this->page->totalPrice = $totalPrice; - $this->page->totalMoney = $this->money($totalPrice); - $this->page->reportNote = $reportNote; - $this->page->reportDate = date('m/d/Y'); - $this->page->reportTime = date('h:m:s A'); - - $this->templateFile = $templateFile; - - // Check for output type - $this->page->printOutput = false; - switch ($_REQUEST['outputType']) { - case 'html': - break; - case 'print': - $this->page->printOutput = true; - break; - case 'csv': - $this->template->compile($this->interface.$templateFileCSV); - $csvOut = $this->template->bufferedOutputObject($this->page); - $len = strlen( $csvOut ); - header( "Content-type: application/octet-stream" ); - header( "Content-Length: $len" ); - header( "Content-Disposition: attachment; filename=report.csv" ); - echo $csvOut; - exit; - break; - } - - $this->addDebug("Report/sales.inc", 'Sales Report', 'Array: $a

    '.print_r($a,1)); - -} - - - -?> diff --git a/legacy/models/admin/actions/Reservation/detail.inc b/legacy/models/admin/actions/Reservation/detail.inc deleted file mode 100755 index 51244c5..0000000 --- a/legacy/models/admin/actions/Reservation/detail.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/reservations.php'; -$Reservations = new EventManagementAdminReservations($this->dbh, $this->config); - - -$resDetail = $Reservations->getReservationDetail(); - -$this->page->resDetail = $this->bindArrayToObject($resDetail); -$this->templateFile = 'Reservation/ReservationDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Reservation/edit.inc b/legacy/models/admin/actions/Reservation/edit.inc deleted file mode 100755 index 2f4f6e0..0000000 --- a/legacy/models/admin/actions/Reservation/edit.inc +++ /dev/null @@ -1,20 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/reservations.php'; -$Reservations = new EventManagementAdminReservations($this->dbh, $this->config); - -// Nothing here yet - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Reservation/list.inc b/legacy/models/admin/actions/Reservation/list.inc deleted file mode 100755 index e8884a7..0000000 --- a/legacy/models/admin/actions/Reservation/list.inc +++ /dev/null @@ -1,53 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/reservations.php'; -$Reservations = new EventManagementAdminReservations($this->dbh, $this->config); - - -// Get reservations stats -$resStats = $Reservations->getReservationsStats(); -$this->page->resStats = $this->bindArrayToObject($resStats); - -// Use a more limited list of fields for this, not enough memory for large list. -$fields = array( - $Reservations->fields['id'], - $Reservations->fields['fname'], - $Reservations->fields['lname'], - $Reservations->fields['org'], - $Reservations->fields['conv'], - $Reservations->fields['event'], - $Reservations->fields['team'], - $Reservations->fields['state_rep'], - $Reservations->fields['state_rep_code'], - $Reservations->fields['member'], - $Reservations->fields['member_id'], - $Reservations->fields['city'], - $Reservations->fields['state'], - $Reservations->fields['country'], - $Reservations->fields['date_entered'], - $Reservations->fields['rooms'], - $Reservations->fields['grand_total'], - $Reservations->fields['confirmed'], - $Reservations->fields['declined'] -); -$Reservations->fields = $fields; - -// Get reserations list -$res = $Reservations->getReservationsList(); -$this->page->resList = $this->bindArrayToObject($res); - -$this->templateFile = 'Reservation/ReservationsList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Reservation/update.inc b/legacy/models/admin/actions/Reservation/update.inc deleted file mode 100755 index 0318836..0000000 --- a/legacy/models/admin/actions/Reservation/update.inc +++ /dev/null @@ -1,20 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/reservations.php'; -$Reservations = new EventManagementAdminReservations($this->dbh, $this->config); - -// Nothing here yet - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Section/add.inc b/legacy/models/admin/actions/Section/add.inc deleted file mode 100755 index f5c4282..0000000 --- a/legacy/models/admin/actions/Section/add.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: add.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - -// Get base data and fields -$r = $Sections->newSection(); - -$this->page->sectionDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewSection = true; - -$this->templateFile = 'Section/edit.html'; - -$this->addDebug("Section/add.inc", 'Section Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Section/confirmDelete.inc b/legacy/models/admin/actions/Section/confirmDelete.inc deleted file mode 100755 index a3db0e2..0000000 --- a/legacy/models/admin/actions/Section/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - -$sectionDetail = $Sections->sectionDelete(true); -$this->page->sectionDetail = $this->bindArrayToObject($sectionDetail); - -$this->templateFile = 'Section/detail.html'; - -$this->addDebug("Section/confirmDelete.inc", 'Section Confirm Delete', print_r($sectionDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Section/delete.inc b/legacy/models/admin/actions/Section/delete.inc deleted file mode 100755 index 6db2a67..0000000 --- a/legacy/models/admin/actions/Section/delete.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: section.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - - -$sectionDetail = $Sections->sectionDelete(false); -$this->page->sectionDetail = $this->bindArrayToObject($sectionDetail); - -$this->templateFile = 'Section/delete.html'; - -$this->addDebug("Section/delete.inc", 'Section Delete', print_r($sectionDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Section/detail.inc b/legacy/models/admin/actions/Section/detail.inc deleted file mode 100755 index 9c62904..0000000 --- a/legacy/models/admin/actions/Section/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - -$sectionDetail = $Sections->getSectionDetail(); -$this->page->sectionDetail = $this->bindArrayToObject($sectionDetail); - -$this->templateFile = 'Section/detail.html'; - -$this->addDebug("Section/detail.inc", 'Section Detail', print_r($sectionDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Section/edit.inc b/legacy/models/admin/actions/Section/edit.inc deleted file mode 100755 index 8c4934a..0000000 --- a/legacy/models/admin/actions/Section/edit.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - -$sectionDetail = $Sections->editSection(); -$this->page->sectionDetail = $this->bindArrayToObject($sectionDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($sectionDetail); - -$this->page->editingSection = true; -$this->templateFile = 'Section/edit.html'; - -$this->addDebug("Section/edit.inc", 'Section Edit', print_r($sectionDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Section/insert.inc b/legacy/models/admin/actions/Section/insert.inc deleted file mode 100755 index a14c442..0000000 --- a/legacy/models/admin/actions/Section/insert.inc +++ /dev/null @@ -1,40 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - -// Process new record -$r = $Sections->insertSection(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->sectionDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewSection = true; - $this->templateFile = 'Section/edit.html'; -} else { - $this->templateFile = 'Section/detail.html'; -} - -$this->addDebug("Section/insert.inc", 'Section Insert', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Section/list.inc b/legacy/models/admin/actions/Section/list.inc deleted file mode 100755 index 0dbc9fd..0000000 --- a/legacy/models/admin/actions/Section/list.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - -$sectionList = $Sections->getSectionsList(); - -$this->page->sectionList = $this->bindArrayToObject($sectionList); - -$this->templateFile = 'Section/list.html'; - -$this->addDebug("Section/list.inc", 'Section List', 'Array: $sectionList

    '.print_r($sectionList,1)); - -?> - diff --git a/legacy/models/admin/actions/Section/update.inc b/legacy/models/admin/actions/Section/update.inc deleted file mode 100755 index 426636a..0000000 --- a/legacy/models/admin/actions/Section/update.inc +++ /dev/null @@ -1,42 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sections.php'; -$Sections = new EventManagementAdminSections($this->dbh, $this->config); - - -// Process new record -$r = $Sections->updateSection(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->sectionDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->editingSection = true; - $this->templateFile = 'Section/edit.html'; -} else { - // If valid - $this->templateFile = 'Section/detail.html'; -} - -$this->addDebug("Section/add.inc", 'Section Add', print_r($r,1)); - -?> - diff --git a/legacy/models/admin/actions/Sold/claim.inc b/legacy/models/admin/actions/Sold/claim.inc deleted file mode 100755 index f7451b4..0000000 --- a/legacy/models/admin/actions/Sold/claim.inc +++ /dev/null @@ -1,24 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Check if we got an orderID here -$this->page->orderID = 0; -if (isset($_REQUEST['orderID'])) { - $orderID = ($_REQUEST['orderID'] -0); - $this->page->orderID = $orderID; -} - -$this->templateFile = 'Sold/claim.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Sold/claimVoucher.inc b/legacy/models/admin/actions/Sold/claimVoucher.inc deleted file mode 100644 index 26d5faa..0000000 --- a/legacy/models/admin/actions/Sold/claimVoucher.inc +++ /dev/null @@ -1,44 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: claimVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get ticket inventory ID and desired status -$voucherID = ($_REQUEST['VoucherID'] - 0); - -// Do sanity check on ID -if ($voucherID > 0) { - - // Get current claims information, if there is one - $sql = "SELECT time_claimed FROM eventmgt.ticket_sold WHERE id = $voucherID;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $voucher = $stmt->fetch(PDO::FETCH_ASSOC); - - if (!$voucher) { - - // Voucher Not Found - - } else { - - // Has not been claimed, so mark it and return time only - $sql = "UPDATE eventmgt.ticket_sold SET numb_claimed = numb_uses WHERE id = $voucherID OR package_sold_id = (SELECT package_sold_id FROM eventmgt.ticket_sold where id = $voucherID);"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - } - -} - -include EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/Sold/detail.inc'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Sold/detail.inc b/legacy/models/admin/actions/Sold/detail.inc deleted file mode 100644 index 086d513..0000000 --- a/legacy/models/admin/actions/Sold/detail.inc +++ /dev/null @@ -1,315 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->page->markedAsClaimed = false; -$this->page->alreadyClaimedAlert = false; -$packageClaimOK = true; -$problem = array(); - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sold.php'; -$Sold = new EventManagementAdminSold($this->dbh, $this->config); - -// If this is a member user then make sure they only list their own member performances -$userType = false; -$userID = false; -$scanName = 'Admin'; -$userMemberID = false; -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $userType = 'member'; - $userID = $_SESSION[GLM_EVENT_SESSION]['MemberUser']; - $userMemberID = $_SESSION[GLM_EVENT_SESSION]['Member']; // This is the ID of the member!!! -} - -// If we have a logged in user, then check if the user's member also scans for other members -$scansFor = false; -if ($userMemberID != false) { - - // Get the user information - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataContacts.php'; - $Contact = new EventManagementDataContacts($this->dbh, $this->config); - $userInfo = $Contact->getContactDetail($userID); - - $scanName = ''; - if ($userInfo['org'] != '') { - $scanName = $userInfo['org'].': '; - } - $scanName .= $userInfo['lname'].', '.$userInfo['fname']; - - // Also get list of members this member scans for - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMemberScansFor.php'; - $MemberScansFor = new EventManagementDataMemberScansFor($this->dbh, $this->config); - $msf = $MemberScansFor->getMemberScansForList($userMemberID); - - // If member scans for others, build a simple array of those member IDs - if (is_array($msf) && count($msf) > 0) { - $scansFor = array(); - foreach ($msf as $m) { - $scansFor[] = $m['scans_for']; - } - } -} - -// Get sold ticket detail -$soldDetail = $Sold->getSoldDetail(); - -// If we don't have ticket detail -if (!$soldDetail) { - - $packageTickets = false; - $soldDetail = false; - $problem[] = 'Not found!'; - -// We have ticket detail -} else { - - // Check if a package voucher has been scanned - $this->page->isPackage = false; - if ($soldDetail['is_package']['value']) { - - $this->page->isPackage = true; - - // Check if this is an admin (not logged in) user - Not permitted to scan packages - if (!$userID && $_REQUEST['doClaim'] == 'true') { - - $packageTickets = false; - $soldDetail = false; - $problem[] = 'Admin users may not scan a package ticket voucher.
    - Package ticket vouchers may only be scanned by a valid logged-in user (contact).
    - Use "Order #:" entry to retrieve voucher status.'; - - // The user is a valid logged in user - } else { - - if ($userID) { - // Build member WHERE clause - $memberWhere = " AND member = $userMemberID"; - if ($scansFor != false) { - - // User member scans for other members (locations), so add them into the WHERE clause. - $memberWhere = "AND (member = $userMemberID"; - - foreach($scansFor as $sf) { - $memberWhere .= " OR member = $sf"; - } - - $memberWhere .= ')'; - } - } - - // Get list of tickets in the package for this location - Hopefully only 1 - $sql = " - SELECT * - FROM eventmgt.ticket_sold - WHERE package_sold_id = '".$soldDetail['package_sold_id']."' - AND id != ".$soldDetail['id']." - $memberWhere - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $packageTickets = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // If we have package tickets for this location - if (is_array($packageTickets) && count($packageTickets) > 0) { - - // If we're trying to claim this ticket use - if ($_REQUEST['doClaim'] == 'true') { - - // Check if there's more than one ticket - should not be the case - if (count($packageTickets) > 1) { - - $problem[] = 'More than one package item for this location was found for the scanned voucher.
    - There may only be one item per location contained in a package. Please check the - package configuration.'; - - // Only one ticket for this location in the package - OK to claim - } else { - - // For each ticket in the package at this location - foreach ($packageTickets as $pt) { - - // Check if it's not unlimited and already been claimed the max times - if (!$pt['unlimited_use'] && ($pt['numb_uses'] - $pt['numb_claimed']) <= 0 ) { - $packageClaimOK = false; - $this->page->alreadyClaimedAlert = true; - } - - } - - // If we can claim these tickets - if ($packageClaimOK) { - - reset($packageTickets); - while (list($key, $val) = each($packageTickets)) { - - // Update ticket_sold to indicate one claim of voucher - $sql = " - UPDATE eventmgt.ticket_sold - SET numb_claimed = ( numb_claimed + 1 ) - WHERE id = ".$val['id']."; - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - // Also update our local copy - $packageTickets[$key]['numb_claimed'] += 1; - - // Store claim tracking - $sql = " - INSERT INTO eventmgt.ticket_claim_tracking - ( ticket_order, ticket_sold, time_of_action, action_type, quant, scan_user, scan_name ) - VALUES - ( - ".$val['ticket_order'].", - ".$val['id'].", - 'now', - ".$this->config->claim_tracking_types_numb->claim.", - 1, - $userID, - '".addslashes($scanName)."' - ); - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - } - - $this->page->markedAsClaimed = true; - - } // OK to claim ticket - - } // Only one ticket for this location in the package - OK to claim - - } // Claiming package ticket at this time - - } // Have package tickets for this location - - } // Have a valid logged in user - - // Otherwise not scanning a package - } else { - - /* - * Check if user can scan this ticket, must be one of ... - * 1) No user logged in - admins can scan for any non-package - * 2) User logged in belongs to the ticket member - * 3) User logged in belongs to the member that scans for the ticket member - */ - if ( $userMemberID == false || - $soldDetail['member'] == $userMemberID || - (is_array($scansFor) && (in_array($soldDetail['member'], $scansFor) || in_array($soldDetail['assigned_from'], $scansFor))) ) { - - // If we're not trying to claim this ticket use - if ($_REQUEST['doClaim'] != 'true') { - - // Do nothing here. We're just going to display the voucher data - - // Check if the ticket is not unlimited and has already been claimed the max times - } elseif (!$soldDetail['unlimited_use']['value'] && ($soldDetail['numb_uses'] - $soldDetail['numb_claimed']) <= 0 ) { - - // Ticket has already been claimed. - $this->page->alreadyClaimedAlert = true; - - // Otherwise add a claim for this voucher - } else { - - // Update ticket_sold to indicate one claim of voucher - $sql = " - - UPDATE eventmgt.ticket_sold - SET numb_claimed = ( numb_claimed + 1 ) - WHERE id = ".$soldDetail['id']."; - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - // Store claim tracking - $sql = " - INSERT INTO eventmgt.ticket_claim_tracking - ( ticket_order, ticket_sold, time_of_action, action_type, quant, scan_user, scan_name ) - VALUES - ( - ".$soldDetail['ticket_order'].", - ".$soldDetail['id'].", - 'now', - ".$this->config->claim_tracking_types_numb->claim.", - 1, - ".($userID?$userID:'null').", - '".addslashes($scanName)."' - ); - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - // Reload voucher data - $soldDetail = $Sold->getSoldDetail(false, $id); - - $this->page->markedAsClaimed = true; - - } - - - // User is not permitted to scan the ticket - } else { - $packageTickets = false; - $soldDetail = false; - $problem[] = 'The scanned ticket may not be used at the current location.'; - } - - - } - -} // have ticket detail - -// And one last thing. To add some data to package tickets -if (is_array($packageTickets) && count($packageTickets) > 0) { - - reset($packageTickets); - - // For each ticket in the package at this location - while (list($key, $val) = each($packageTickets)) { - - $packageTickets[$key]['fullyClaimedAlert'] = false; - $remaining = ($val['numb_uses'] - $val['numb_claimed']); - $packageTickets[$key]['remaining'] = $remaining; - - if (!$val['unlimited_use'] && $remaining <= 0 ) { - $packageTickets[$key]['fullyClaimedAlert'] = true; - } - - } - - $this->page->packageDetail = $this->bindArrayToObject($packageTickets); - -} - -// Check for main sold detail number of claimes expired -$remaining = ($soldDetail['numb_uses'] - $soldDetail['numb_claimed']); -if (is_array($soldDetail) && $soldDetail['unlimited_use']['value'] == '' && $remaining <= 0 ) { - $soldDetail['fullyClaimedAlert'] = true; -} - -$this->page->soldDetail = $this->bindArrayToObject($soldDetail); -$this->templateFile = 'Sold/detail.html'; - -if (count($problem) > 0) { - $this->page->problem = $this->bindArrayToObject($problem); - $this->page->haveProblem = true; -} else { - $this->page->problem = false; - $this->page->haveProblem = false; -} - -$this->addDebug("Sold/detail.inc", 'Array: $soldDetail', print_r($soldDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Sold/fixPackages.inc b/legacy/models/admin/actions/Sold/fixPackages.inc deleted file mode 100755 index 24ed05e..0000000 --- a/legacy/models/admin/actions/Sold/fixPackages.inc +++ /dev/null @@ -1,170 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: fixPackages.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - - -/* - * This method is build to add the missing package detail for - * package tickets sold that did not have the ticket_sold records - * added for each of the package destinations. This is not - * for normal use. - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; -$TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); - -// Get all sold packages that do not have ticket_sold entries for the individual destinations -$sql = " - SELECT ticket_sold.* - FROM eventmgt.ticket_sold, eventmgt.ticket - WHERE ticket.id = ticket_sold.ticket - AND ticket.ticket_type = 20 - AND package_sold_id IS null - ORDER BY ticket_sold.id - LIMIT 100 -;"; -$stmt = $this->dbh->prepare($sql); -$stmt->execute(); -$soldList = $stmt->fetchAll(PDO::FETCH_ASSOC); - -echo "

    Loaded ".count($soldList)." package sales that need to be fixed.

    "; - -// For each package ticket sold that needs to be fixed -foreach ($soldList as $s) { - - $pSale = $s['id']; - $p = $s['ticket']; - - // get the package contents - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); - $packageData = $TicketPackages->getPackageList("package = ".$s['ticket']); - - echo "Processing package sale # $pSale - Session ID = ".$s['session_id']."
    "; - - // for each item in the package - reset ($packageData); - foreach ($packageData as $t) { - - // Get information on this package ticket - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; - $Tickets = new EventManagementDataTickets($this->dbh, $this->config); - $pt = $Tickets->getTicketDetail($t['ticket']); - - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSections.php'; - $Sections = new EventManagementDataSections($this->dbh, $this->config); - $ps = $Sections->getSectionDetail($pt['section_id']); - - // Get Entrance information for this ticket's section - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataEntrances.php'; - $Entrances = new EventManagementDataEntrances($this->dbh, $this->config); - $pe = $Entrances->getEntranceDetail($ps['entrance']); - - $sql = " - INSERT INTO eventmgt.ticket_sold - ( - ticket_order, - member, - member_name, - assigned, - assigned_from, - assigned_from_name, - performance, - performance_name, - entrance, - entrance_name, - entrance_color, - section, - section_name, - ticket, - ticket_name, - is_package, - package_sold_id, - ticket_package, - package_name, - date_specific, - ticket_date, - time_specific, - ticket_time, - start_date, - end_date, - likely_date, - price_paid, - voucher_type, - voucher_text, - policies, - unlimited_use, - numb_uses, - numb_claimed, - time_claimed, - session_id - ) - VALUES - ( - ".$s['ticket_order'].", - ".$pt['member'].", - '".$pt['member_name']."', - false, - NULL, - '', - ".$pt['performance_id'].", - '".$pt['performance']."', - ".(!empty($pt['section_id']) ? $pt['section_id'] : 'NULL').", - '".$pe['name']."', - '".$pe['color']['name']."', - ".$ps['id'].", - '".$ps['name']."', - ".$pt['id'].", - '".$pt['title']."', - false, - '".$s['session_id']."-$pSale', - ".$s['ticket'].", - '".$packageData['title']."', - false, - NULL, - false, - '".$pt['ticket_timestamp']."', - ".(!empty($pt['start_date']['date']) ? "'".$pt['start_date']['date']."'" : 'NULL').", - ".(!empty($pt['end_date']['date']) ? "'".$pt['end_date']['date']."'" : 'NULL').", - NULL, - 0, - ".$pt['voucher_type']['value'].", - '".$pt['voucher_text']."', - '', - ".($pt['unlimited_use']['value'] ? 'true' : 'false').", - ".$pt['uses'].", - 0, - null, - '".$s['session_id']."' - ); - "; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - } - - // Now update the package ticket entry - $sql = " - UPDATE eventmgt.ticket_sold - SET package_sold_id = '".$s['session_id']."-$pSale', - is_package = true - WHERE id = $pSale - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - -} -exit; - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Sold/list.inc b/legacy/models/admin/actions/Sold/list.inc deleted file mode 100644 index f2d8cc6..0000000 --- a/legacy/models/admin/actions/Sold/list.inc +++ /dev/null @@ -1,35 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: list.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sold.php'; -$Sold = new EventManagementAdminSold($this->dbh, $this->config); - -// If this is a member user then make sure they only list their own member performances -$type = false; -$id = false; -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser'] && !$this->config->option->users_access_all_members) { - $type = 'member'; - $id = $this->page->userMemberID; -} - -$soldList = $Sold->getSoldList(false, $id); - -$this->page->soldList = $this->bindArrayToObject($soldList); - -$this->templateFile = 'Sold/list.html'; - -$this->addDebug("Sold/list.inc", 'Sold List', 'Array: $soldList

    '.print_r($soldList,1)); - -?> - diff --git a/legacy/models/admin/actions/Sold/resetVoucher.inc b/legacy/models/admin/actions/Sold/resetVoucher.inc deleted file mode 100644 index af7512c..0000000 --- a/legacy/models/admin/actions/Sold/resetVoucher.inc +++ /dev/null @@ -1,45 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: resetVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get ticket inventory ID and desired status -$voucherID = ($_REQUEST['VoucherID'] - 0); - -// Do sanity check on ID -if ($voucherID > 0) { - - // Get current claim time, if there is one - $sql = "SELECT time_claimed FROM eventmgt.ticket_sold WHERE id = $voucherID;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $voucher = $stmt->fetch(PDO::FETCH_ASSOC); - - if (!$voucher) { - - // Voucher Not Found - - } else { - - // Has not been claimed, so clear it - $sql = "UPDATE eventmgt.ticket_sold SET numb_claimed = 0 WHERE id = $voucherID OR package_sold_id = (SELECT package_sold_id FROM eventmgt.ticket_sold where id = $voucherID);"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - - } - -} - -include EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/Sold/detail.inc'; - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Sold/selected.inc b/legacy/models/admin/actions/Sold/selected.inc deleted file mode 100755 index b44de8c..0000000 --- a/legacy/models/admin/actions/Sold/selected.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sold.php'; -$Sold = new EventManagementAdminSold($this->dbh, $this->config); - -$soldDetail = $Sold->getSoldDetail(); -$this->page->soldDetail = $this->bindArrayToObject($soldDetail); - -$this->templateFile = 'Sold/selected.html'; - -$this->addDebug("Sold/selected.inc", 'Sold Ticket Detail', print_r($soldDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/State/add.inc b/legacy/models/admin/actions/State/add.inc deleted file mode 100755 index 27e826a..0000000 --- a/legacy/models/admin/actions/State/add.inc +++ /dev/null @@ -1,36 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/states.php'; -$States = new EventManagementAdminStates($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Generate a random access code for the new team -require '../classes/EasyPassword.php'; -$ep = new EasyPassword(); -$passwd = $ep->generateEasyPassword(); - -$r = $States->newState(); -$r['fieldData']['password'] = $code; - -$this->page->stateDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewState = true; - -$this->templateFile = 'State/EditState.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/State/detail.inc b/legacy/models/admin/actions/State/detail.inc deleted file mode 100755 index df70e19..0000000 --- a/legacy/models/admin/actions/State/detail.inc +++ /dev/null @@ -1,36 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/states.php'; -$States = new EventManagementAdminStates($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -$stateDetail = $States->getStateDetail(); -$this->page->stateDetail = $this->bindArrayToObject($stateDetail); - -// Get contacts for this event -$eventContacts = $Contacts->getContacts('state'); -$this->page->contactsList = $this->bindArrayToObject($eventContacts['contact_list']); - -// Get room blocks and teams for this state rep -require '../classes/blocks.php'; -$Blocks = new EventManagementAdminBlocks($this->dbh, $this->config); -$roomBlocks = $Blocks->getRoomBlocks(false, true, true, $stateDetail['id']); -$this->page->roomBlocks = $this->bindArrayToObject($roomBlocks); - -$this->templateFile = 'State/StateDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/State/edit.inc b/legacy/models/admin/actions/State/edit.inc deleted file mode 100755 index 7c714a8..0000000 --- a/legacy/models/admin/actions/State/edit.inc +++ /dev/null @@ -1,44 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/states.php'; -$States = new EventManagementAdminStates($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Check State Code -$stateDetail = $States->editState(); - -// If no password has been set, then suggest one -if (trim($stateDetail['password']) == '') { - - // Generate a random access code for the new team - require '../classes/EasyPassword.php'; - $ep = new EasyPassword(); - $passwd = $ep->generateEasyPassword(); - $stateDetail['password'] = $passwd; - -} - -$this->page->stateDetail = $this->bindArrayToObject($stateDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($stateDetail); - -$this->page->editingState = true; - -$this->templateFile = 'State/EditState.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/State/insert.inc b/legacy/models/admin/actions/State/insert.inc deleted file mode 100755 index a3ac97c..0000000 --- a/legacy/models/admin/actions/State/insert.inc +++ /dev/null @@ -1,40 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/states.php'; -$States = new EventManagementAdminStates($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Process new record -$r = $States->insertState(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->stateDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewState = true; - $this->templateFile = 'State/EditState.html'; -} else { - $this->templateFile = 'State/StateDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/State/list.inc b/legacy/models/admin/actions/State/list.inc deleted file mode 100755 index d9704bd..0000000 --- a/legacy/models/admin/actions/State/list.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/states.php'; -$States = new EventManagementAdminStates($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Get state reps stats -$statesStats = $States->getStatesStats(); -$this->page->statesStats = $this->bindArrayToObject($statesStats); - -// Get state reps list -$states = $States->getStatesList(); -$this->page->statesList = $this->bindArrayToObject($states); - -$this->templateFile = 'State/StatesList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/State/update.inc b/legacy/models/admin/actions/State/update.inc deleted file mode 100755 index 435a243..0000000 --- a/legacy/models/admin/actions/State/update.inc +++ /dev/null @@ -1,44 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/states.php'; -$States = new EventManagementAdminStates($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Process new record -$r = $States->updateState(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->stateDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$stateDetail = $States->getStateDetail(); -$this->page->storedDetail = $this->bindArrayToObject($stateDetail); - -// If invalid submission -if (!$status) { - $this->page->editingState = true; - $this->templateFile = 'State/EditState.html'; -} else { - $this->templateFile = 'State/StateDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/add.inc b/legacy/models/admin/actions/Team/add.inc deleted file mode 100755 index 914be17..0000000 --- a/legacy/models/admin/actions/Team/add.inc +++ /dev/null @@ -1,35 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - -// Generate a random access code for the new team -require GLM_APP_BASE.'Common/'.$this->config->applicationVersion.'/classes/EasyPassword.php'; -$ep = new EasyPassword(); -$code = $ep->generateEasyPassword(); - -$r = $Teams->newTeam(); -$r['fieldData']['team_code'] = $code; - -$this->page->teamDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->addingNewTeam = true; - -$this->templateFile = 'Team/EditTeam.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/detail.inc b/legacy/models/admin/actions/Team/detail.inc deleted file mode 100755 index f32ae07..0000000 --- a/legacy/models/admin/actions/Team/detail.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -$r = $Teams->getTeamDetail(); -$this->page->teamDetail = $this->bindArrayToObject($r['teamDetail']); -$this->page->teamRoster = $this->bindArrayToObject($r['teamRoster']); - -// Get contacts for this event -$eventContacts = $Contacts->getContacts('team'); -$this->page->contactsList = $this->bindArrayToObject($eventContacts['contact_list']); - -$this->templateFile = 'Team/TeamDetail.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/edit.inc b/legacy/models/admin/actions/Team/edit.inc deleted file mode 100755 index 6a35d48..0000000 --- a/legacy/models/admin/actions/Team/edit.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -$teamDetail = $Teams->editTeam(); -$this->page->teamDetail = $this->bindArrayToObject($teamDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($teamDetail); - -$this->page->editingTeam = true; - -$this->templateFile = 'Team/EditTeam.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/editRoster.inc b/legacy/models/admin/actions/Team/editRoster.inc deleted file mode 100755 index 7a436ca..0000000 --- a/legacy/models/admin/actions/Team/editRoster.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); - - -$r = $Teams->editTeamRoster(); - -$this->page->teamDetail = $this->bindArrayToObject($r['teamDetail']); -$this->page->teamRoster = $this->bindArrayToObject($r['teamRoster']); - -$this->templateFile = 'Team/EditTeamRoster.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/insert.inc b/legacy/models/admin/actions/Team/insert.inc deleted file mode 100755 index 431c94b..0000000 --- a/legacy/models/admin/actions/Team/insert.inc +++ /dev/null @@ -1,40 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Process new record -$r = $Teams->insertTeam(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->teamDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewTeam = true; - $this->templateFile = 'Team/EditTeam.html'; -} else { - $this->templateFile = 'Team/TeamDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/list.inc b/legacy/models/admin/actions/Team/list.inc deleted file mode 100755 index fdd88b4..0000000 --- a/legacy/models/admin/actions/Team/list.inc +++ /dev/null @@ -1,54 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Check for teams that don't have access codes and assign one to them -require GLM_APP_BASE.'CommonApps/'.$this->config->applicationVersion.'/classes/EasyPassword.php'; -$ep = new EasyPassword(); - -$sql = " - SELECT id - FROM eventmgt.team - WHERE team_code IS NULL - OR team_code = ''; - "; -$stmt = $this->dbh->prepare($sql); -$stmt->execute(); -$teams = $stmt->fetchAll(PDO::FETCH_ASSOC); -$sql = ''; -if (count($teams) > 0) { - foreach ($teams as $t) { - $code = $ep->generateEasyPassword(); - $sql = "UPDATE team SET team_code = '$code' WHERE id = ".$t['id'].";\n"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - } -} - -// Get teams stats -$teamsStats = $Teams->getTeamsStats(); -$this->page->teamsStats = $this->bindArrayToObject($teamsStats); - -// Get teams list -$teams = $Teams->getTeamsList(); -$this->page->teamsList = $this->bindArrayToObject($teams); - -$this->templateFile = 'Team/TeamsList.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/update.inc b/legacy/models/admin/actions/Team/update.inc deleted file mode 100755 index f6b2df1..0000000 --- a/legacy/models/admin/actions/Team/update.inc +++ /dev/null @@ -1,45 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/contacts.php'; -$Contacts = new EventManagementAdminContacts($this->dbh, $this->config); - - -// Process new record -$r = $Teams->updateTeam(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->teamDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$r = $Teams->getTeamDetail(); -$this->page->storedDetail = $this->bindArrayToObject($r['teamDetail']); -$this->page->teamRoster = $this->bindArrayToObject($r['teamRoster']); - -// If invalid submission -if (!$status) { - $this->page->editingTeam = true; - $this->templateFile = 'Team/EditTeam.html'; -} else { - $this->templateFile = 'Team/TeamDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Team/updateRoster.inc b/legacy/models/admin/actions/Team/updateRoster.inc deleted file mode 100755 index 47b1f45..0000000 --- a/legacy/models/admin/actions/Team/updateRoster.inc +++ /dev/null @@ -1,32 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/teams.php'; -$Teams = new EventManagementAdminTeams($this->dbh, $this->config); - - -$r = $Teams->updateTeamRoster(); - -$this->page->teamDetail = $this->bindArrayToObject($r['teamDetail']); -$this->page->teamRoster = $this->bindArrayToObject($r['teamRoster']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$r['status']) { - $this->templateFile = 'Team/EditTeamRoster.html'; -} else { - $this->templateFile = 'Team/TeamDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/add.inc b/legacy/models/admin/actions/Ticket/add.inc deleted file mode 100644 index a20665b..0000000 --- a/legacy/models/admin/actions/Ticket/add.inc +++ /dev/null @@ -1,58 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: add.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Check if we need to ask for a member/venue first -//if (!$_SESSION[GLM_EVENT_SESSION]['Member']) { -$memberID = ($_REQUEST['memberID'] - 0); -if ($memberID == 0) { - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; - $Members = new EventManagementAdminMembers($this->dbh, $this->config); - $members = $Members->getMembersList('all'); - - // Check if there's only one member and if so don't bother asking - if (count($members) == 1) { - $_SESSION[GLM_EVENT_SESSION]['Member'] = $members[0]['id']; - } else { - - $this->page->membersList = $this->bindArrayToObject($members); - $this->templateFile = 'Ticket/addGetMember.html'; - return; - } - -} else { - $_SESSION[GLM_EVENT_SESSION]['Member'] = $memberID; - - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; - $Members = new EventManagementAdminMembers($this->dbh, $this->config); - $member = $Members->getEntry($memberID); - -} - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -$r = $Tickets->newTicket(); - -$this->page->memberDetail = $this->bindArrayToObject($member); -$this->page->ticketDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -$this->page->addingNewTicket = true; - -$this->templateFile = 'Ticket/edit.html'; - -$this->addDebug("Ticket/add.inc", 'Array: $r', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/confirmDelete.inc b/legacy/models/admin/actions/Ticket/confirmDelete.inc deleted file mode 100755 index b8e5c10..0000000 --- a/legacy/models/admin/actions/Ticket/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: confirmDelete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -$ticketDetail = $Tickets->ticketDelete(true); -$this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - -$this->templateFile = 'Ticket/detail.html'; - -$this->addDebug("Ticket/confirmDelete.inc", 'Section Confirm Delete', print_r($ticketDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Ticket/delete.inc b/legacy/models/admin/actions/Ticket/delete.inc deleted file mode 100755 index 4258d52..0000000 --- a/legacy/models/admin/actions/Ticket/delete.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: delete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - - -$ticketDetail = $Tickets->ticketDelete(false); -$this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - -$this->templateFile = 'Ticket/delete.html'; - -$this->addDebug("Ticket/delete.inc", 'Array: $ticketDetail', print_r($ticketDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/Ticket/detail.inc b/legacy/models/admin/actions/Ticket/detail.inc deleted file mode 100644 index 38244c7..0000000 --- a/legacy/models/admin/actions/Ticket/detail.inc +++ /dev/null @@ -1,47 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -// Get Ticket detail -$ticketDetail = $Tickets->getTicketDetail(); -$this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - -// If it's a package, get the package contents -$this->page->isPackage = false; -if ($this->config->option->packages && $ticketDetail['ticket_type']['value'] == 20) { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); - $packageData = $TicketPackages->getPackageList("package = ".$ticketDetail['id']); - $this->page->isPackage = true; -} -$this->page->ticketPackage = $this->bindArrayToObject($packageData); - -$_SESSION[GLM_EVENT_SESSION]['Member'] = $ticketDetail['member']; - -// Also get Ticket inventory Stats - and check if none exist for this ticket -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/ticketInventory.php'; -$ticketInventory = new EventManagementAdminTicketInventory($this->dbh, $this->config); -$ticketInventoryStats = $ticketInventory->getTicketTicketInventoryStats(); -$this->page->noTicketInventory = true; -if ($ticketInventoryStats > 0) { - $this->page->noTicketInventory = false; -} - -$this->templateFile = 'Ticket/detail.html'; - -$this->addDebug("Ticket/detail.inc", 'Array: $ticketDetail', print_r($ticketDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/edit.inc b/legacy/models/admin/actions/Ticket/edit.inc deleted file mode 100644 index 9e168f8..0000000 --- a/legacy/models/admin/actions/Ticket/edit.inc +++ /dev/null @@ -1,46 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: edit.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -$ticketDetail = $Tickets->editTicket(); -$this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($ticketDetail); - -// We need a full list of other tickets to use for selecting tickets in a package -$ticketsList = $Tickets->getTicketsList($ticketDetail['member'], false, false, 'packageSelect', false, false, false, $ticketDetail['id']); -$this->page->ticketsList = $this->bindArrayToObject($ticketsList); - -// var_dump($ticketsList); - -// Also get a list of any tickets that are included in the package -$this->page->isPackage = false; -if ($ticketDetail['ticket_type']['value'] == 20) { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); - $packageData = $TicketPackages->getPackageList("T.package = ".$ticketDetail['id']); - $this->page->ticketPackage = $this->bindArrayToObject($packageData); - $this->page->isPackage = true; -} - -$this->page->editingTicket = true; - -$this->templateFile = 'Ticket/edit.html'; - -$this->addDebug("Ticket/edit.inc", 'Array: $ticketDetail', print_r($ticketDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/insert.inc b/legacy/models/admin/actions/Ticket/insert.inc deleted file mode 100755 index c90ab95..0000000 --- a/legacy/models/admin/actions/Ticket/insert.inc +++ /dev/null @@ -1,63 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: insert.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -// Process new record -$r = $Tickets->insertTicket(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->ticketDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewTicket = true; - $this->templateFile = 'Ticket/edit.html'; -} else { - - $ticketID = $r['fieldData']['id']; - // Also get Ticket inventory Stats - and check if none exist for this ticket - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/ticketInventory.php'; - $TicketInventory = new EventManagementAdminTicketInventory($this->dbh, $this->config); - $ticketInventoryStats = $TicketInventory->getTicketTicketInventoryStats($ticketID); - - $this->page->noTicketInventory = true; - if ($ticketInventoryStats > 0) { - $this->page->noTicketInventory = false; - } else { - - // Try to create default ticket inventory - $TicketInventory->generateDefaultTicketInventory(); - - // Get inventory stats again - $ticketInventoryStats = $TicketInventory->getTicketTicketInventoryStats($ticketDetail['id']); - - if ($ticketInventoryStats > 0) { - $this->page->noTicketInventory = false; - } - } - - $this->templateFile = 'Ticket/selected.html'; -} - -$this->addDebug("Ticket/insert.inc", 'Array: $r', print_r($r,1)); - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/inventory.inc b/legacy/models/admin/actions/Ticket/inventory.inc deleted file mode 100755 index c4d4657..0000000 --- a/legacy/models/admin/actions/Ticket/inventory.inc +++ /dev/null @@ -1,59 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: inventory.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/ticketInventory.php'; -$TicketInventory = new EventManagementAdminTicketInventory($this->dbh, $this->config); - -// Check if a CreateInventory request has been received -if (!$_REQUEST['CreateInventory'] == 'true') { - - $res = $TicketInventory->generateDefaultTicketInventory(); - - // If there's a failure, then report that - if (!$res) { - $this->page->ticketCreateInventoryFail = true; - } - -} - -// Get Ticket detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); -$ticketDetail = $Tickets->getTicketDetail(); -$this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - -$this->addDebug("Ticket/inventory.inc", 'Array: $ticketDetail', print_r($ticketDetail,1)); - -// If ticket is date specific -if ($ticketDetail['date_specific']['value']) { - - // Get Ticket Inventory as calendar data - $ticketCalendar = $TicketInventory->getTicketInventoryCalendarData(); - $this->page->ticketCalendar = $this->bindArrayToObject($ticketCalendar); - $this->addDebug("Ticket/inventory.inc", 'Array: $ticketCalendar', print_r($ticketCalendar,1)); - - $this->templateFile = 'Ticket/inventory.html'; - -} else { - - // Ticket is not date specific, so not using a calendar - $inventoryData = $TicketInventory->getTicketInventoryList(false, "ticket_date is null"); - $this->page->inventoryData = $this->bindArrayToObject($inventoryData); - $this->addDebug("Ticket/inventory.inc", 'Array: $inventoryData', print_r($inventoryData,1)); - $this->templateFile = 'Ticket/inventoryNoCalendar.html'; - -} - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/inventoryUpdate.inc b/legacy/models/admin/actions/Ticket/inventoryUpdate.inc deleted file mode 100755 index b04fb1b..0000000 --- a/legacy/models/admin/actions/Ticket/inventoryUpdate.inc +++ /dev/null @@ -1,36 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: inventoryUpdate.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/ticketInventory.php'; -$TicketInventory = new EventManagementAdminTicketInventory($this->dbh, $this->config); - -// Process new record -$r = $TicketInventory->updateTicketInventory(); - -// If inventory is not date specific, simply redisplay form -if (isset($_REQUEST['dateSpecific'])) { - - // Redisplay form - $this->page->inventoryUpdated = true; - include(EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/Ticket/inventory.inc'); - -} else { - - $this->templateFile = false; // No response expected - - $this->addDebug("Ticket/inventoryUpdate.inc", 'Array: $r', print_r($r,1)); - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/list.inc b/legacy/models/admin/actions/Ticket/list.inc deleted file mode 100644 index 425dbf7..0000000 --- a/legacy/models/admin/actions/Ticket/list.inc +++ /dev/null @@ -1,46 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: list.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -// Get Tickets stats -$ticketsStats = $Tickets->getTicketsStats(); -$this->page->ticketsStats = $this->bindArrayToObject($ticketsStats); - -// If this is a member user then make sure they only list their own member tickets -$type = false; -$id = false; -if ($_SESSION[GLM_EVENT_SESSION]['MemberUser']) { - $type = 'member'; - $id = $this->page->userMemberID; - // Also specify current memberID for other uses - $this->page->memberID = $id; - -// Otherwise if we already have a member selected they pass that for other uses -} elseif ($_SESSION[GLM_EVENT_SESSION]['Member'] != false) { - $this->page->memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; -} else { - $this->page->memberID = false; -} - -// Get tickets list -$tickets = $Tickets->getTicketsList($id, false, false, $type, false, false, true); -$this->page->tickets = $this->bindArrayToObject($tickets); - -$this->templateFile = 'Ticket/list.html'; - -$this->addDebug("Ticket/list.inc", 'Array: $tickets', print_r($tickets,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/printSampleVoucher.inc b/legacy/models/admin/actions/Ticket/printSampleVoucher.inc deleted file mode 100644 index dbf0b11..0000000 --- a/legacy/models/admin/actions/Ticket/printSampleVoucher.inc +++ /dev/null @@ -1,145 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: printSampleVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get supplied ticket ID to use for test -$testTicket = $_REQUEST['testTicket'] - 0; - -// Check for Coupon Test only -$couponTest = false; -if (isset($_REQUEST['testCoupons']) && $_REQUEST['testCoupons'] == 'true') { - $couponTest = true; -} - -// Get Ticket Detail -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; -$Tickets = new EventManagementDataTickets($this->dbh, $this->config); -$Tickets->optionIncludeSelectListData = false; -$ticketDetail = $Tickets->getTicketDetail($testTicket); - -// Get Section Detail -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSections.php'; -$Sections = new EventManagementDataSections($this->dbh, $this->config); -$Sections->optionIncludeSelectListData = false; -$sectionDetail = $Sections->getSectionDetail($ticketDetail['section_id']); - -// Get Member Detail -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMembers.php'; -$Members = new EventManagementDataMembers($this->dbh, $this->config); -$Members->optionIncludeSelectListData = false; -$memberDetail = $Members->getMemberDetail($ticketDetail['member']); - -// Get Performance Detail -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPerformances.php'; -$Performances = new EventManagementDataPerformances($this->dbh, $this->config); -$Performances->optionIncludeSelectListData = false; -$performanceDetail = $Performances->getPerformanceDetail($ticketDetail['performance_id']); - -// Sample Order Detail -$orderDetail = array( - 'id' => 12345678, - 'user_trace_info' => $_SERVER["REMOTE_ADDR"]." - ".date("m/d/Y H:i:s"), - 'fname' => 'John', - 'lname' => 'Smith', - 'addr1' => '120 E. Lake St.', - 'addr2' => 'Apt 123', - 'city' => 'Petoskey', - 'state' => 'MI', - 'country' => 'US', - 'zip' => '49770', - 'phone' => '231-487-0692', - 'email' => 'info@gaslightmedia.com', - 'email_ok' => true, - 'purchase_date' => date('m/d/Y'), - 'member' => $memberDetail['id'], - 'member_name' => $memberDetail['name'], - 'cctype' => 'VISA', - 'ccnumber' => '0011001100110011', - 'expire' => '01/19', - 'ccname' => 'JOHN SMITH', - 'ccconf' => '12312', - 'charge_numb' => 123.45, - 'charge_total' => '$123.45', - 'special_needs' => 'No special needs', - 'notes' => '' -); - -// Sample Tickets Sold List -$soldList = array( - 0 => array( - 'id' => 12345678, - 'ticket_order' => 11223344, - 'member' => $memberDetail['id'], - 'member_name' => $memberDetail['name'], - 'performance' => $performanceDetail['id'], - 'performance_name' => $performanceDetail['name'], - 'entrance' => 123, - 'entrance_name' => 'Test Entrance', - 'entrance_color' => '#FFB6C1', - 'section' => $sectionDetail['name'], - 'ticket' => $testTicket, - 'ticket_name' => $ticketDetail['title'], - 'date_specific' => $ticketDetail['date_specific'], - 'ticket_date' => array( - 'date' => ($ticketDetail['date_specific'] ? date('m/d/Y') : 'Use any date') - ), - 'ticket_time' => array( - 'time' => ($ticketDetail['time_specific'] ? '12:00 PM' : 'Use any time') - ), - 'start_date' => array('date' => $ticketDetail['start_date']), - 'end_date' => array('date' => $ticketDetail['end_date']['date']), - 'likely_date' => array('date' => '06/13/14'), - 'price_paid' => $this->money($ticketDetail['price']), - 'time_claimed' => false - ), - 1 => array( - 'id' => 12345679, - 'ticket_order' => 11223345, - 'member' => $memberDetail['id'], - 'member_name' => $memberDetail['name'], - 'performance' => $performanceDetail['id'], - 'performance_name' => $performanceDetail['name'], - 'entrance' => 123, - 'entrance_name' => 'Test Entrance', - 'entrance_color' => '#FFB6C1', - 'section' => $sectionDetail['name'], - 'ticket' => $testTicket, - 'ticket_name' => $ticketDetail['title'], - 'date_specific' => $ticketDetail['date_specific'], - 'ticket_date' => array( - 'date' => ($ticketDetail['date_specific'] ? date('m/d/Y') : 'Use any date') - ), - 'ticket_time' => array( - 'time' => ($ticketDetail['time_specific'] ? '12:00 PM' : 'Use any time') - ), - 'start_date' => array('date' => $ticketDetail['start_date']), - 'end_date' => array('date' => $ticketDetail['end_date']['date']), - 'likely_date' => array('date' => '06/13/14'), - 'price_paid' => $this->money($ticketDetail['price']), - 'time_claimed' => date('m/d/Y h:i:s A') - ), -); - -// Load voucher design code as per the "voucher_design" config parameter in the site's config/applications/EventManagement.ini file -if (is_file(EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucher.php')) { - require_once EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucher.php'; - $pdf = new PdfVoucher($orderDetail, $soldList, $memberDetail, $this->dbh, $this->config, $couponTest); -} else { - echo "SYSTEM ERROR: Site is not configured with a valid voucher design file."; - exit; -} - -// There's nothing to do from here. Output should go direct to browser. -exit; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/selected.inc b/legacy/models/admin/actions/Ticket/selected.inc deleted file mode 100644 index 28f4ad6..0000000 --- a/legacy/models/admin/actions/Ticket/selected.inc +++ /dev/null @@ -1,50 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -$ticketDetail = $Tickets->getTicketDetail(); -$this->page->ticketPackage = ($ticketDetail['ticket_type']['value']==20); -$this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - -$_SESSION[GLM_EVENT_SESSION]['Performance'] = $ticketDetail['performance_id']; - -// Also get Ticket inventory Stats - and check if none exist for this ticket -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/ticketInventory.php'; -$TicketInventory = new EventManagementAdminTicketInventory($this->dbh, $this->config); -$ticketInventoryStats = $TicketInventory->getTicketTicketInventoryStats($ticketDetail['id']); - -// Check if we have inventory or need to create it -$this->page->noTicketInventory = true; -if ($ticketInventoryStats > 0) { - $this->page->noTicketInventory = false; -} else { - - // Try to create default ticket inventory - $TicketInventory->generateDefaultTicketInventory(); - - // Get inventory stats again - $ticketInventoryStats = $TicketInventory->getTicketTicketInventoryStats($ticketDetail['id']); - - if ($ticketInventoryStats > 0) { - $this->page->noTicketInventory = false; - } -} - -$this->templateFile = 'Ticket/selected.html'; - -$this->addDebug("Ticket/selected.inc", 'Ticket Detail', print_r($ticketDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/setActive.inc b/legacy/models/admin/actions/Ticket/setActive.inc deleted file mode 100755 index 956f028..0000000 --- a/legacy/models/admin/actions/Ticket/setActive.inc +++ /dev/null @@ -1,28 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: setActive.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get ticket inventory ID and desired status -$ticketInventoryID = ($_REQUEST['TicketInventoryID'] - 0); -$ticketInventoryStatus = ($_REQUEST['TicketInventoryStatus'] - 0); // 0 if false, 1 if true -if ($ticketInventoryID > 0 && $ticketInventoryStatus > -1 && $ticketInventoryStatus < 2) { - $active = ($ticketInventoryStatus == 1 ? 'true' : 'false'); - $sql = "UPDATE eventmgt.ticket_inventory SET active = $active WHERE id = $ticketInventoryID;"; - $this->dbh->exec($sql); -} - -$this->templateFile = false; // No response expected - -$this->addDebug("Ticket/setActive.inc", "ID: $ticketInventoryID, Set active to: $active
    "); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/Ticket/update.inc b/legacy/models/admin/actions/Ticket/update.inc deleted file mode 100644 index 12c7f5e..0000000 --- a/legacy/models/admin/actions/Ticket/update.inc +++ /dev/null @@ -1,56 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: update.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -// Process new record -$r = $Tickets->updateTicket(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->ticketDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// Get currently stored data for fields that are display only -$ticketDetail = $Tickets->getTicketDetail(); -$this->page->storedDetail = $this->bindArrayToObject($ticketDetail); - -// Check for changes in selected package tickets -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; -$TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); -$this->page->isPackage = false; -if ($ticketDetail['ticket_type']['value'] == 20) { - $packageData = $TicketPackages->updatePackageTicketsList($ticketDetail['id']); - $this->page->isPackage = true; - $this->page->ticketPackage = $this->bindArrayToObject($packageData); -// Otherwise make sure there's no package tickets -} else { - $TicketPackages->clearPackageTicketsList($ticketDetail['id']); -} - -// If invalid submission -if (!$status) { - $this->page->editingTicket = true; - $this->templateFile = 'Ticket/edit.html'; -} else { - $this->templateFile = 'Ticket/detail.html'; -} - -$this->addDebug("Ticket/update.inc", 'Array: $r', print_r($r,1)); - -?> diff --git a/legacy/models/admin/actions/User/login.inc b/legacy/models/admin/actions/User/login.inc deleted file mode 100755 index 362fc44..0000000 --- a/legacy/models/admin/actions/User/login.inc +++ /dev/null @@ -1,17 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: login.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->templateFile = 'User/loginForm.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/add.inc b/legacy/models/admin/actions/VoucherCoupon/add.inc deleted file mode 100755 index 11e6573..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/add.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: add.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -$r = $VoucherCoupons->newVoucherCoupon(); - -$this->page->voucherCouponDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -$this->page->addingNewVoucherCoupon = true; - -$this->templateFile = 'VoucherCoupon/edit.html'; - -$this->addDebug("VoucherCoupon/add.inc", 'Array: $r', print_r($r,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/confirmDelete.inc b/legacy/models/admin/actions/VoucherCoupon/confirmDelete.inc deleted file mode 100755 index b8b7deb..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/confirmDelete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: confirmDelete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -$voucherCouponDetail = $VoucherCoupons->voucherCouponDelete(true); -$this->page->voucherCouponDetail = $this->bindArrayToObject($voucherCouponDetail); - -$this->templateFile = 'VoucherCoupon/detail.html'; - -$this->addDebug("VoucherCoupon/confirmDelete.inc", 'Section Confirm Delete', print_r($voucherCouponDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/VoucherCoupon/delete.inc b/legacy/models/admin/actions/VoucherCoupon/delete.inc deleted file mode 100755 index 44811c3..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/delete.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: delete.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -$voucherCouponDetail = $VoucherCoupons->voucherCouponDelete(false); -$this->page->voucherCouponDetail = $this->bindArrayToObject($voucherCouponDetail); - -$this->templateFile = 'VoucherCoupon/delete.html'; - -$this->addDebug("VoucherCoupon/delete.inc", 'Array: $$voucherCouponDetail', print_r($voucherCouponDetail,1)); - -?> - diff --git a/legacy/models/admin/actions/VoucherCoupon/detail.inc b/legacy/models/admin/actions/VoucherCoupon/detail.inc deleted file mode 100644 index 9724e8e..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/detail.inc +++ /dev/null @@ -1,26 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: detail.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -// Get Voucher Coupon detail -$voucherCouponDetail = $VoucherCoupons->getVoucherCouponDetail(); -$this->page->voucherCouponDetail = $this->bindArrayToObject($voucherCouponDetail); - -$this->templateFile = 'VoucherCoupon/detail.html'; - -$this->addDebug("VoucherCoupon/detail.inc", 'Array: $voucherCouponDetail', print_r($voucherCouponDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/edit.inc b/legacy/models/admin/actions/VoucherCoupon/edit.inc deleted file mode 100755 index f036c3a..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/edit.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: edit.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -$voucherCouponDetail = $VoucherCoupons->editVoucherCoupon(); -$this->page->voucherCouponDetail = $this->bindArrayToObject($voucherCouponDetail); - -$this->page->editingVoucherCoupon = true; - -$this->templateFile = 'VoucherCoupon/edit.html'; - -$this->addDebug("VoucherDetail/edit.inc", 'Array: $voucherCouponDetail', print_r($voucherCouponDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/insert.inc b/legacy/models/admin/actions/VoucherCoupon/insert.inc deleted file mode 100755 index 6509fe9..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/insert.inc +++ /dev/null @@ -1,43 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: insert.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -// Process new record -$r = $VoucherCoupons->insertVoucherCoupon(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->voucherCouponDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->addingNewVoucherCoupon = true; - $this->templateFile = 'VoucherCoupon/edit.html'; -} else { - - $voucherCouponID = $r['fieldData']['id']; - - $this->templateFile = 'VoucherCoupon/selected.html'; -} - -$this->addDebug("VoucherCoupon/insert.inc", 'Array: $r', print_r($r,1)); - - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/list.inc b/legacy/models/admin/actions/VoucherCoupon/list.inc deleted file mode 100755 index f2e2414..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/list.inc +++ /dev/null @@ -1,30 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: list.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -// Get Voucher Coupon stats -$voucherCouponStats = $VoucherCoupons->getVoucherCouponsStats(); -$this->page->voucherCouponStats = $this->bindArrayToObject($voucherCouponStats); - -// Get Voucher Coupons list -$voucherCouponsList = $VoucherCoupons->getVoucherCouponList(); -$this->page->voucherCoupons = $this->bindArrayToObject($voucherCouponsList); - -$this->templateFile = 'VoucherCoupon/list.html'; - -$this->addDebug("VoucherCoupon/list.inc", 'Array: $voucherCouponsList', print_r($voucherCouponsList, 1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/selected.inc b/legacy/models/admin/actions/VoucherCoupon/selected.inc deleted file mode 100755 index a303ff0..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/selected.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -$voucherCouponDetail = $VoucherCoupons->getVoucherCouponDetail(); -$this->page->voucherCouponDetail = $this->bindArrayToObject($voucherCouponDetail); - -$this->templateFile = 'VoucherCoupon/selected.html'; - -$this->addDebug("VoucherCoupon/selected.inc", 'Voucher Coupon Detail', print_r($voucherCouponDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/test.inc b/legacy/models/admin/actions/VoucherCoupon/test.inc deleted file mode 100755 index e1a5dc8..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/test.inc +++ /dev/null @@ -1,25 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: test.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -$voucherCouponDetail = $VoucherCoupons->newVoucherCoupon(); -$this->page->voucherCouponDetail = $this->bindArrayToObject($voucherCouponDetail); - -$this->templateFile = 'VoucherCoupon/test.html'; - -$this->addDebug("VoucherDetail/test.inc", 'Array: $voucherCouponDetail', print_r($voucherCouponDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/VoucherCoupon/update.inc b/legacy/models/admin/actions/VoucherCoupon/update.inc deleted file mode 100755 index defc044..0000000 --- a/legacy/models/admin/actions/VoucherCoupon/update.inc +++ /dev/null @@ -1,38 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: update.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/voucherCoupons.php'; -$VoucherCoupons = new EventManagementAdminVoucherCoupons($this->dbh, $this->config); - -// Process new record -$r = $VoucherCoupons->updateVoucherCoupon(); - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->voucherCouponDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - -// If invalid submission -if (!$status) { - $this->page->editingVoucherCoupon = true; - $this->templateFile = 'VoucherCoupon/edit.html'; - $this->addDebug("VoucherCoupon/update.inc", 'Array: $r', print_r($r,1)); -} else { - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/actions/VoucherCoupon/detail.inc'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/inventory/add.inc b/legacy/models/admin/actions/inventory/add.inc deleted file mode 100755 index 1907907..0000000 --- a/legacy/models/admin/actions/inventory/add.inc +++ /dev/null @@ -1,40 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/inventory.php'; -$Inventory = new EventManagementAdminInventory($this->dbh, $this->config); - - -// Check for member ID supplied and force to a number -$this->page->defMember = false; -if (isset($_REQUEST['member'])) { - $this->page->defMember = ($_REQUEST['member'] - 0); -} - -$r = $Inventory->addInven(); - -if (isset($r['reason'])) { - $this->reason = array_merge($this->reason, $r['reason']); -} - -$this->page->invenDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->membAccom = $this->bindArrayToObject($r['membAccom']); - -$this->page->addingNewInven = true; - -$this->templateFile = 'Inventory/EditInventory.html'; - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/inventory/detail.inc b/legacy/models/admin/actions/inventory/detail.inc deleted file mode 100755 index af25856..0000000 --- a/legacy/models/admin/actions/inventory/detail.inc +++ /dev/null @@ -1,27 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/inventory.php'; -$Inventory = new EventManagementAdminInventory($this->dbh, $this->config); - - -// Get inventory itme detail -$invenDetail = $Inventory->getInvenDetail(); -$this->page->invenDetail = $this->bindArrayToObject($invenDetail); - -$this->templateFile = 'Inventory/InventoryDetail.html'; - -$this->addDebug("Inventory/detail.inc", 'Inventory Detail', print_r($invenDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/inventory/edit.inc b/legacy/models/admin/actions/inventory/edit.inc deleted file mode 100755 index 055f28c..0000000 --- a/legacy/models/admin/actions/inventory/edit.inc +++ /dev/null @@ -1,31 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/inventory.php'; -$Inventory = new EventManagementAdminInventory($this->dbh, $this->config); - - -$invenDetail = $Inventory->editInven(); -$this->page->invenDetail = $this->bindArrayToObject($invenDetail); - -// We need this to mimic stored detail for edit templates that show this on entry to edit -$this->page->storedDetail = $this->bindArrayToObject($invenDetail); - -$this->page->editingInven = true; - -$this->templateFile = 'Inventory/EditInventory.html'; - -$this->addDebug("Inventory/edit.inc", 'Edit Inventory', print_r($invenDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/inventory/insert.inc b/legacy/models/admin/actions/inventory/insert.inc deleted file mode 100755 index 4452cee..0000000 --- a/legacy/models/admin/actions/inventory/insert.inc +++ /dev/null @@ -1,48 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/inventory.php'; -$Inventory = new EventManagementAdminInventory($this->dbh, $this->config); - - -// Process new record -$r = $Inventory->insertInven(); - -if (isset($r['reason'])) { - $this->reason = array_merge($this->reason, $r['reason']); -} - -// Get success status, false = fail -$status = $r['status']; -$this->page->formFail = !$status; - -$this->page->invenDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); -$this->page->membSelected = $this->bindArrayToObject($r['membSelected']); -$this->page->membAccom = $this->bindArrayToObject($r['membAccom']); -// $this->page->lt = '<'; // needed to avoid breaking javascript - -// If invalid submission -if (!$status) { - $this->page->addingNewInven = true; - $this->templateFile = 'Inventory/EditInventory.html'; -} else { - // Inventory added, so display data on the last inventory item stored. - $invenDetail = $Inventory->getInvenDetail($r['insertedID']); - $this->page->invenDetail = $this->bindArrayToObject($invenDetail); - $this->templateFile = 'Inventory/InventoryDetail.html'; -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/inventory/list.inc b/legacy/models/admin/actions/inventory/list.inc deleted file mode 100755 index 05e6bc1..0000000 --- a/legacy/models/admin/actions/inventory/list.inc +++ /dev/null @@ -1,68 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/inventory.php'; -$Inventory = new EventManagementAdminInventory($this->dbh, $this->config); - - -// Get inventory stats -$invenStats = $Inventory->getInvenStats(); -$this->page->invenStats = $this->bindArrayToObject($invenStats); - -// Get inventory list -$i = $Inventory->getInvenList(); -$inventory = $i['inventory']; - -// If there's member results, then sort them -if (is_array($i['sum'])) { - // Sort members under each event listed - function sortByMember($a, $b) - { - if ($a['name'] > $b['name']) { - return 1; - } elseif ($b['name'] > $a['name']) { - return -1; - } - return 0; - } - while (list($k, $v) = each($i['sum'])) { - uasort($v['memb'], 'sortByMember'); - $i['sum'][$k] = $v; - } -} - -$this->page->inventoryList = $this->bindArrayToObject($inventory); -$this->page->dates = $this->bindArrayToObject($i['dates']); -if ($i['have_sum']) { - $this->page->summary = $this->bindArrayToObject($i['sum']); -} - -$this->page->have_summary = $i['have_sum']; - -$d = getdate($i['firstDate']); - -$this->page->firstInventoryDay = $d['mday']; -$this->page->firstInventoryMonth = $d['mon'] - 1; -$this->page->firstInventoryYear = $d['year']; - -if ($i['type'] == 'Summary') { - $this->templateFile = 'Inventory/InventoryListSummary.html'; -} else { - $this->page->memberName = $i['inventory'][0]['member']; - $this->templateFile = 'Inventory/InventoryListCalendar.html'; -} - -$this->addDebug("Inventory/list.inc", 'Inventory List', print_r($i,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/inventory/selected.inc b/legacy/models/admin/actions/inventory/selected.inc deleted file mode 100755 index e2fbd3e..0000000 --- a/legacy/models/admin/actions/inventory/selected.inc +++ /dev/null @@ -1,49 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: selected.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; -$Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - -$ticketDetail = $Tickets->getTicketDetail(); -$this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - -$_SESSION[GLM_EVENT_SESSION]['Performance'] = $ticketDetail['performance_id']; - -// Also get Ticket inventory Stats - and check if none exist for this ticket -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/ticketInventory.php'; -$TicketInventory = new EventManagementAdminTicketInventory($this->dbh, $this->config); -$ticketInventoryStats = $TicketInventory->getTicketTicketInventoryStats($ticketDetail['id']); - -// Check if we have inventory or need to create it -$this->page->noTicketInventory = true; -if ($ticketInventoryStats > 0) { - $this->page->noTicketInventory = false; -} else { - - // Try to create default ticket inventory - $TicketInventory->generateDefaultTicketInventory(); - - // Get inventory stats again - $ticketInventoryStats = $TicketInventory->getTicketTicketInventoryStats($ticketDetail['id']); - - if ($ticketInventoryStats > 0) { - $this->page->noTicketInventory = false; - } -} - -$this->templateFile = 'Ticket/selected.html'; - -$this->addDebug("Ticket/selected.inc", 'Ticket Detail', print_r($ticketDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/actions/inventory/update.inc b/legacy/models/admin/actions/inventory/update.inc deleted file mode 100755 index f7e6cd0..0000000 --- a/legacy/models/admin/actions/inventory/update.inc +++ /dev/null @@ -1,50 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/inventory.php'; -$Inventory = new EventManagementAdminInventory($this->dbh, $this->config); - - -// Process new record -$r = $Inventory->updateInven(); - -// Get success status and reasons and save to add after getInvenDetail() below -$status = $r['status']; -$reason = $r['reason']; -$this->page->formFail = !$status; - -$this->page->invenDetail = $this->bindArrayToObject($r['fieldData']); -$this->page->fieldRequired = $this->bindArrayToObject($r['fieldRequired']); -$this->page->fieldFail = $this->bindArrayToObject($r['fieldFail']); - - -// If invalid submission -if (!$status) { - $this->reason = $r['reason']; - $this->page->storedDetail = $this->bindArrayToObject($r); - $this->page->editingInven = true; - $this->templateFile = 'Inventory/EditInventory.html'; - -} else { - - // Get currently stored data for fields that are display only - $invenDetail = $Inventory->getInvenDetail(); - $this->page->storedDetail = $this->bindArrayToObject($invenDetail); - $this->templateFile = 'Inventory/InventoryDetail.html'; - -} - -$this->addDebug("Inventory/update.inc", 'Update Inventory', print_r($feeDetail,1)); - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/accommodations.php b/legacy/models/admin/classes/accommodations.php deleted file mode 100644 index 8aea93c..0000000 --- a/legacy/models/admin/classes/accommodations.php +++ /dev/null @@ -1,80 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/accommodations.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataAccoms.php'; - -/** - * EventManagementAdminAccoms class - * - * Event Management and Reservations System - Admin Code - Accommodations section - * - * PHP version 5 - * - * @category Event Management Admin Accommodations - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/accommodations.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link http://www.gaslightmedia.com/admin/EventManagement - */ -class EventManagementAdminAccoms extends EventManagementDataAccoms -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - /** - * Get Accommodations Stats - * - * @return object containing array as sub-objects - */ - function getMemberAccomsStats() - { - // Get member ID from session - if available get stats for member - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - return $this->getStats("member = $memberID"); - } - return 0; - } - function getAccomsStats() - { - $accomsStats = array( - 'all' => $this->getStats(), - 'member' => $this->getMemberAccomsStats() - ); - - return $accomsStats; - } - - -} - -?> - diff --git a/legacy/models/admin/classes/addons.php b/legacy/models/admin/classes/addons.php deleted file mode 100755 index d37d165..0000000 --- a/legacy/models/admin/classes/addons.php +++ /dev/null @@ -1,81 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/addons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataAddons.php'; - -/** - * EventManagementAdminAddons class - * - * Event Management and Reservations System - Admin Code - Add-Ons section - * - * PHP version 5 - * - * @category Event Management Admin Add-Ons - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/addons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminAddons extends EventManagementDataAddons -{ - /** - * Configuration information object - * @var $config - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $data - * @access public - */ - public $data; - - /** - * Get Add-Ons Stats - * - * @return object containing array as sub-objects - */ - function getTicketAddonsStats($ticketID = false) - { - // Get ticket ID from session - if available get stats for ticket Add-ons - if ($ticketID || ($ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket'])) { - return $this->getStats("ticket = $ticketID"); - } - return 0; - } - function getAddonStats() - { - $addonStats = array( - 'all' => $this->getStats(), - 'ticket' => $this->getTicketAddonStats() - ); - - return $addonStats; - } - - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/addonsSold.php b/legacy/models/admin/classes/addonsSold.php deleted file mode 100755 index 1dd1073..0000000 --- a/legacy/models/admin/classes/addonsSold.php +++ /dev/null @@ -1,57 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/addonsSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataAddonSold.php'; - -/** - * EventManagementAdminAddonsSold class - * - * Event Management and Reservations System - Admin Code - Sold Ticket add-ons - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/addonsSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementAdminAddonsSold extends EventManagementDataAddonSold -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/attendance.php b/legacy/models/admin/classes/attendance.php deleted file mode 100755 index 1d92d3d..0000000 --- a/legacy/models/admin/classes/attendance.php +++ /dev/null @@ -1,70 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/addons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataAttendance.php'; - -/** - * EventManagementAdminAttendance class - * - * Event Management and Reservations System - Admin Code - Attendance section - * - * PHP version 5 - * - * @category Event Management Admin Attendance - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/attendance.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminAttendance extends EventManagementDataAttendance -{ - /** - * Configuration information object - * @var $config - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $data - * @access public - */ - public $data; - - /** - * Get Attendance Stats - * - * @return object containing array as sub-objects - */ - function getAttendanceStats($performanceID = false) - { - // Get performance ID from session - if ($performanceID || ($performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance'])) { - return $this->getStats("performance = $performanceID"); - } - return 0; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/blocks.php b/legacy/models/admin/classes/blocks.php deleted file mode 100755 index f5f36d0..0000000 --- a/legacy/models/admin/classes/blocks.php +++ /dev/null @@ -1,1025 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/blocks.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -/** - * EventManagementAdminBookings class - * - * Event Management and Reservations System - Admin Code - Bookings section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/bookings.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - * - * NOTE: This class does not currently have a DataBlocks class to extend - * because we don't seem to want the lower-level data definitions for this class. - */ -class EventManagementAdminBlocks -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - function __construct($dbh, $config) - { - - $this->dbh = $dbh; - $this->config = $config; - - } - - /** - * Get Blocks Summary - * - * @return object containing array as sub-objects - */ - function getBlocksSummary($event = false, $sort = true) - { - - // Check for valid Event - if ($event) { - $eventID = $event; - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - // Get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - // Otherwise, we don't have a member id - return false; - } - - // Need to make sure this is a team event - Don't do blocks for a non-team event! - $sql = "SELECT team_event FROM eventmgt.event WHERE id = $eventID"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $event = $stmt->fetch(PDO::FETCH_ASSOC); - if (!$event['team_event']) { - return false; - } - - // Get list of Members (properties) along with blocks and inventory stats - $sql = " - SELECT R.id AS memb_id, - R.name AS memb_name, - M.street AS addr, - M.lat, - M.lon, - C.city_name AS city, - A.id AS accom_id, - A.name AS accom_name, - I.assigned AS rooms, - ( SELECT COUNT(B.id) FROM eventmgt.room_block B WHERE B.member = R.id AND B.conv = $eventID ) AS room_blocks, - COALESCE (S.block, 0) AS block_numb, - COALESCE (S.allocated, 0) AS allocated, - ( SELECT COUNT(B.block_name) FROM eventmgt.room_block B WHERE B.member = R.id AND b.conv = $eventID ) AS block_count - FROM eventmgt.member R, - member.member M, - inventory I, - city C, - accommodation A - LEFT OUTER JOIN room_block_seg S ON (S.accommodation = A.id AND S.conv = $eventID) - WHERE I.member = R.id - AND A.member = R.id - AND I.accommodation = A.id - AND I.conv = $eventID - AND M.member_id = R.id - AND C.city_id = M.city_id - GROUP BY R.id, A.id, I.assigned, R.name, M.street, M.lat, M.lon, C.city_name, A.name, S.block, S.allocated - ORDER BY R.name, A.id - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $memb_data = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // If there's no results then fail - if (!$memb_data) { - return false; - } - - // Add distances to the member data and sort by distance - if(class_exists('EventManagementGeoCalculations') != true) { - require '../../classes/GeoCalculations.php'; - } - $Geo = new EventManagementGeoCalculations($this->dbh); - $memb_data = $Geo->getMemberEventDistance( $eventID, $memb_data, 'lat', 'lon', 'distance', 'duration', 'memb_id', $sort); - - // Compile summary from list - $r = array(); - foreach ($memb_data as $m) { - - // If member entry has not been created - if (!isset($r[$m['memb_id']])) { - - $r[$m['memb_id']] = array( - 'id' => $m['memb_id'], - 'name' => addslashes($m['memb_name']), - 'distance' => $m['distance'], - 'street' => $m['addr'], - 'city' => $m['city'], - 'blocks' => $m['room_blocks'], - 'rooms' => 0, - 'allocated' => 0, - 'unallocated' => 0, - 'all_allocated' => false, - 'alert' => false, - 'accom' => array() - ); - } - - // If accommodation entry has not been created - if (!isset($r[$m['memb_id']]['accom'][$m['accom_id']])) { - - // Add this accomodation - $r[$m['memb_id']]['accom'][$m['accom_id']] = array( - 'id' => $m['accom_id'], - 'name' => $m['accom_name'], - 'rooms' => $m['rooms'], - 'allocated' => 0, - 'all_allocated' => false, - 'alert' => false - ); - - $r[$m['memb_id']]['rooms'] += $m['rooms']; - $r[$m['memb_id']]['unallocated'] += $m['rooms']; - - } - // tally assingments and allocation for this member - $r[$m['memb_id']]['allocated'] += $m['allocated']; - $r[$m['memb_id']]['unallocated'] -= $m['allocated']; - if ($r[$m['memb_id']]['unallocated'] <= 0) { - $r[$m['memb_id']]['all_allocated'] = true; - } - - // Check for mixed inventory levels across dates for this accommodation - if ($r[$m['memb_id']]['accom'][$m['accom_id']]['rooms'] != $m['rooms']) { - // Oops! We have multiple results for the same accommodation with different assigned inventory levels. - // This means we don't have the same amount of inventory assigned for all of the dates - // User must check inventory for this accommodation for this event - $r[$m['memb_id']]['accom'][$m['accom_id']]['alert'] = true; - $r[$m['memb_id']]['alert'] = true; - } - - // Insert allocated data for this block - $r[$m['memb_id']]['accom'][$m['accom_id']]['allocated'] += $m['allocated']; - if ($r[$m['memb_id']]['accom'][$m['accom_id']]['rooms'] - $r[$m['memb_id']]['accom'][$m['accom_id']]['allocated'] <= 0) { - $r[$m['memb_id']]['accom'][$m['accom_id']]['all_allocated'] = true; - } - - } - - // echo "getBlocksSummary()

    ".print_r($r,1)."
    "; - return $r; - - - } - - /** - * Get Blocks Detail and Management Screen - * - * @return object containing array as sub-objects - */ - function getBlocksDetail() - { - // Check for valid Event - if (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - // Get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - // Otherwise, we don't have a member id - return false; - } - - // Need to make sure this is a team event - Don't do blocks for a non-team event! - $sql = "SELECT team_event FROM eventmgt.event WHERE id = $eventID"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $event = $stmt->fetch(PDO::FETCH_ASSOC); - if (!$event['team_event']) { - return false; - } - - // Get the specified Member - if (!($membID = filter_input(INPUT_GET, 'MemberID', FILTER_SANITIZE_NUMBER_INT))) { - return false; - } - $sql = "SELECT name FROM eventmgt.member WHERE id = $membID"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $memberData = $stmt->fetch(PDO::FETCH_ASSOC); - - // Get inventory data for this member for this event - $sql = " - SELECT DISTINCT(I.assigned) AS rooms, - A.id AS accom_id, - A.name AS accom_name, - a.sort - FROM eventmgt.inventory I, eventmgt.accommodation A - WHERE I.member = $membID - AND I.conv = $eventID - AND A.id = I.accommodation - ORDER BY A.sort - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $accom_data = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Build accommodation type array and short version array to use for building block data - $accoms = array(); - $a_array = array(); - $a_count = 1; - foreach ($accom_data as $a) { - - // Check for duplicate accommodation type - indicates inconsistent quantities - if (isset($a_array[$a['accom_id']])) { - $accoms[$a['accom_id']]['alert'] = true; - } - - $accoms[$a['accom_id']] = array( - 'accom_numb' => $a_count, - 'id' => $a['accom_id'], - 'name' => $a['accom_name'], - 'rooms' => $a['rooms'], - 'alert' => false - ); - - $a_array[$a['accom_id']] = array( - 'accom_numb' => $a_count, - 'id' => false, - 'allocated' => 0, - 'accom_id' => $a['accom_id'], - ); - - $a_count++; - - } - - // Get all related block data - $sql = " - SELECT R.id AS block_id, - R.block_name AS block_name, - R.state_rep AS state_rep, - coalesce((SELECT code FROM eventmgt.state_rep P WHERE P.id = R.state_rep), '') AS state_code, - R.team AS team, - S.id AS seg_id, - S.accommodation AS accom_id, - S.allocated AS allocated - FROM eventmgt.room_block R, eventmgt.room_block_seg S - WHERE R.member = $membID - AND R.conv = $eventID - AND S.block = R.id - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $block_segs = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Build list of blocks with assignments - $blocks = array(); - $blockCounter = 1; - foreach ($block_segs as $s) { - - // If the block hasn't been created yet - if (!isset($blocks[$s['block_id']])) { - $blocks[$s['block_id']] = array( - 'block_numb' => $blockCounter++, - 'id' => $s['block_id'], - 'name' => $s['block_name'], - 'segments' => $a_array, - 'assigned' => $s['state_code'] - ); - } - - // Add this segment to the block - $blocks[$s['block_id']]['segments'][$s['accom_id']] = array( - 'accom_numb' => $accoms[$s['accom_id']]['accom_numb'], - 'id' => $s['seg_id'], - 'allocated' => $s['allocated'], - 'accom_id' => $s['accom_id'] - ); - - } - - $r = array( - 'memberID' => $membID, - 'memberName' => $memberData['name'], - 'accomData' => $accoms, - 'blockData' => $blocks, - 'lineLength' => (count($accoms)+1), - 'numbAccoms' => count($accoms), - 'nextBlock' => $blockCounter, - 'nextBlock2' => ($blockCounter +1) - ); - - $this->addDebug("classes/blocks.inc", 'getBlocksDetail()', print_r($r,1)); - - return $r; - - } - - /** - * Update Blocks Detail and Management Screen - * - * @return object containing array as sub-objects - */ - function updateBlocksDetail() - { - // Assume everything works fine - $status = true; - - // Check for valid Event - if (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - // Get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - // Otherwise, we don't have a member id - return false; - } - - // Need to make sure this is a team event - Don't do blocks for a non-team event! - $sql = "SELECT team_event FROM eventmgt.event WHERE id = $eventID"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $event = $stmt->fetch(PDO::FETCH_ASSOC); - if (!$event['team_event']) { - return false; - } - - // Get the specified Member - if (!($membID = filter_input(INPUT_POST, 'MemberID', FILTER_SANITIZE_NUMBER_INT))) { - return false; - } - - // Get accomodation/inventory data for this member for this event - $sql = " - SELECT DISTINCT(I.assigned) AS rooms, - A.id AS accom_id, - A.name AS accom_name, - a.sort - FROM eventmgt.inventory I, eventmgt.accommodation A - WHERE I.member = $membID - AND I.conv = $eventID - AND A.id = I.accommodation - ORDER BY A.sort - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $accom_data = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Build accommodation type array - $accoms = array(); - $a_array = array(); - $a_count = 1; - foreach ($accom_data as $a) { - - // Check for duplicate accommodation type - indicates inconsistent quantities - if (isset($a_array[$a['accom_id']])) { - $accoms[$a['accom_id']]['alert'] = true; - } - - $accoms[$a_count] = array( - 'accom_numb' => $a_count, - 'id' => $a['accom_id'], - 'name' => $a['accom_name'], - 'rooms' => $a['rooms'], - 'alert' => false - ); - - $a_count++; - - } - - // Get existing room block data for this event/member - $sql = " - SELECT * - FROM eventmgt.room_block - WHERE conv = $eventID - AND member = $membID - ORDER BY id - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $block_data = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // For each block submitted - $blocks = array(); - $block = 1; - while (isset($_REQUEST['seg_'.$block.'_1'])) { - - // Create an entry for this block - $blocks[$block] = array( - 'numb' => $block, - 'block_id' => false, - 'sql' => false, - 'segs' => array() - ); - - // For each accommodation - for ($accom=1 ; $accom<$a_count ; $accom++) { - - // Create an entry for this accom - $blocks[$block]['segs'][$accom] = array( - 'numb' => $accom, - 'seg_id' => false, - 'sql' => false, - 'new_block' => false, - 'quant' => 0 - ); - - // Check if there was an existing entry - if ( isset($_REQUEST['current_'.$block.'_'.$accom]) && - ($current = filter_input(INPUT_POST, 'current_'.$block.'_'.$accom, FILTER_SANITIZE_STRING, FILTER_FLAG_NO_ENCODE_QUOTES))) { - $x = explode(',', $current); - $blocks[$block]['block_id'] = $x[0]; - $blocks[$block]['segs'][$accom]['seg_id'] = $x[1]; - } - - // Get inventory quantity for this segment - if (($quant = filter_input(INPUT_POST, 'seg_'.$block.'_'.$accom, FILTER_SANITIZE_NUMBER_INT))) { - $blocks[$block]['segs'][$accom]['quant'] = $quant; - } - - } - - $block++; - } - - // Get some data on the existing blocks - $sql = "SELECT MAX(state_rep) AS max_rep, - MAX(team) AS max_team, - MAX(block_name) AS max_name - FROM eventmgt.room_block - WHERE conv = $eventID - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $block_stats = $stmt->fetch(PDO::FETCH_ASSOC); - $next_block_name = $block_stats['max_name'] + 1; - - // We should now have all the block and segment data so start building queries to update - for each block - $sql = array(); - foreach ($blocks as $b) { - - $block_total = 0; // Total number of rooms for this block - - // For each block segment - foreach ($b['segs'] as $s) { - - // Add the number of rooms in this segment to the block total - $block_total += $s['quant']; - - // If the segment is already in the database - update it - if ($s['seg_id']) { - - // If the segment now 0 then delete it - if ($s['quant'] == false || $s['quant'] == 0) { - $blocks[$b['numb']]['segs'][$s['numb']]['sql'] = "DELETE FROM eventmgt.room_block_seg WHERE id = ".$s['seg_id'].";"; - - // Otherwise we're going to update it - } else { - $blocks[$b['numb']]['segs'][$s['numb']]['sql'] = "UPDATE room_block_seg SET allocated = ".$s['quant'].", available = ".$s['quant']." WHERE id = ".$s['seg_id'].";"; - } - - // Othewise it's a new segment and it's not 0 add it - } elseif ($s['quant'] != false && $s['quant'] > 0) { - - // If we already have a block ID, use the block number - if ($blocks[$b['numb']]['block_id'] != false) { - $bval = $blocks[$b['numb']]['block_id']; - - // Otherwise we'll be adding the block so use the last sequence value for the block ID - } else { - $bval = "currval('room_block_id_seq')"; - } - - // Create the block segement insert query - $blocks[$b['numb']]['segs'][$s['numb']]['sql'] = " - INSERT INTO eventmgt.room_block_seg - (block, conv, accommodation, allocated, available) - VALUES - ($bval, $eventID, ".$accoms[$s['numb']]['id'].", ".$s['quant'].", ".$s['quant'].") - ;"; - } - - } - - // If block is empty - if ($block_total == 0) { - - // If the block existed, then delete it - if ($b['block_id'] != false) { - $blocks[$b['numb']]['sql'] = "DELETE FROM eventmgt.room_block WHERE id = ".$b['block_id'].";"; - } - - // Otherwise if this is a new block - } elseif ($b['block_id'] == false) { - $blocks[$b['numb']]['sql'] = " - INSERT INTO eventmgt.room_block - (conv, member, state_rep, team, block_name) - VALUES - ($eventID, $membID, 0, 0, ".$next_block_name++.") - ;"; - $blocks[$b['numb']]['new_block'] = true; - - } // Note that we don't have to update the block record if it's going to stay - - } - - // Now try to run the queries - reset($blocks); - try { - $this->dbh->beginTransaction(); - - // For each block - foreach ($blocks as $b) { - - // if there's a query - if ($b['sql'] != false) { - $this->dbh->exec($b['sql']); - } - - // for each segment - foreach ($b['segs'] as $s) { - - // if there's a query - if ($s['sql'] != false) { - $this->dbh->exec($s['sql']); - } - } - } - - $this->dbh->commit(); - - } catch (Exception $e) { - $this->dbh->rollBack(); - $status = false; - } - - // If there are no blocks assigned to state reps or teams yet it's OK to renumber - // Otherwise we're just going to add numbers - $renumber = false; - if ($block_stats['max_rep'] + $block_stats['max_team'] == 0) { - $renumber = true; - } - - // Get all blocks in the proper member order then in the order of their creation - $sql = "SELECT B.id, B.block_name, - M.member_id AS memb_id, M.member_name, M.lat, M.lon - FROM eventmgt.room_block B, members.member M - WHERE B.conv = $eventID - AND M.member_id = B.member - ORDER BY M.member_id, B.id - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $blocks = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // If we have some room blocks - if (count($blocks) > 0) { - - // Add distances to the member data and sort by distance - require '../../classes/GeoCalculations.php'; - $Geo = new EventManagementGeoCalculations($this->dbh); - $blocks = $Geo->getMemberEventDistance( $eventID, $blocks, 'lat', 'lon', 'distance', 'duration', 'memb_id', true); - - // Renumber all blocks according to the current order - if we're allowed to renumber at this time - $block = 1; - if ($renumber) { - - try { - $this->dbh->beginTransaction(); - foreach ($blocks as $b) { - $this->dbh->exec("UPDATE room_block SET block_name = ".$block++." WHERE id = ".$b['id'].";"); - } - $this->dbh->commit(); - } catch (Exception $e) { - $this->dbh->rollBack(); - } - - } - - } - - // echo "updateBlocksDetail()
    ".print_r($blocks,1)."
    "; - return $status; - - } - - /** - * Get Room Blocks - * - * If summary is true, then also put all the data under the properties - * so all blocks show under the property as well. - * - * @return object containing array as sub-objects - */ - function getRoomBlocks($event = false, $sort = true, $summary = false, $state = false, $team = false, $property = false) - { - - // Make sure we have an event selected (shouldn't happen that we don't) - if ($event) { - $eventID = $event; - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - // Get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - // Otherwise, we don't have a member id - return false; - } - - // Get all State Reps for this event - $where = ''; - if ($state) { - $where = "AND id = $state"; - }; - if ($property) { - $where .= " AND id IN ( - SELECT DISTINCT state_rep FROM eventmgt.room_block - WHERE member = $property - )"; - } - - $sql = "SELECT id, code - FROM eventmgt.state_rep - WHERE conv = $eventID - $where - ORDER BY code;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $states_data = $stmt->fetchAll(PDO::FETCH_ASSOC); - $statesList = array(); - foreach ($states_data as $s) { - $statesList[$s['id']] = array( - 'id' => $s['id'], - 'code' => $s['code'] - ); - } - - // Get all Teams for this event and add under state reps array - $where = ''; - if ($state) { - $where .= " AND T.state = $state"; - }; - if ($team) { - $where .= " AND T.id = $team"; - }; - if ($property) { - $where .= " AND T.room_block IN ( - SELECT DISTINCT id FROM eventmgt.room_block - WHERE member = $property - )"; - } - - $sql = "SELECT T.id, T.name, T.team_code, T.state, D.name AS division - FROM eventmgt.team T, eventmgt.division D - WHERE T.conv = $eventID - AND D.id = T.division - $where - ORDER BY T.name;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $teams_data = $stmt->fetchAll(PDO::FETCH_ASSOC); - foreach ($teams_data as $t) { - $statesList[$t['state']]['teams'][$t['id']] = array( - 'id' => $t['id'], - 'name' => $t['name'], - 'team_code' => $t['team_code'] - ); - } - - // Get all existing Room Blocks for this event - $where = ''; - if ($state) { - $where .= " AND B.state_rep = $state"; - }; - if ($team) { - $where .= " AND B.team = $team"; - }; - if ($property) { - $where .= " AND R.id = $property"; - } - - - $sql = "SELECT B.id as block_id, - B.block_name, - B.state_rep, - B.team, - B.member AS memb_id, - R.name AS memb_name, - M.street AS street, - M.lat, - M.lon, - C.city_name AS city, - A.name AS accom_name, - S.allocated AS quant, - S.available AS available - FROM eventmgt.room_block B, eventmgt.member R, members.member M, members.city C, eventmgt.room_block_seg S, eventmgt.accommodation A - WHERE B.conv = $eventID - AND R.id = B.member - AND S.block = B.id - AND A.id = S.accommodation - AND C.city_id = M.city_id - AND M.member_id = R.id - $where - ORDER BY M.member_id, B.block_name, A.name;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $blocks_data = $stmt->fetchAll(PDO::FETCH_ASSOC); - - // Add distances to the member data and sort by distance - if(class_exists('EventManagementGeoCalculations') != true) { - require '../../classes/GeoCalculations.php'; - } - $Geo = new EventManagementGeoCalculations($this->dbh); - $blocks_data = $Geo->getMemberEventDistance( $eventID, $blocks_data, 'lat', 'lon', 'distance', 'duration', 'memb_id', $sort); - - if (!is_array($blocks_data) || count($blocks_data) == 0) { - return false; - } - reset($blocks_data); - - // Build room blocks list - $blocksList = array(); - foreach ($blocks_data as $b) { - - // If the Property (member) hasn't been added to the array yet - if (!isset($blocksList[$b['memb_id']])) { - $blocksList[$b['memb_id']] = array( - 'memb_id' => $b['memb_id'], - 'memb_name' => $b['memb_name'], - 'distance' => $b['distance'], - 'street' => $b['street'], - 'city' => $b['city'] - ); - } - - // Get assignement summary if assigned - $assigned = false; - $assigned_to_state = ''; - $assigned_to_team = ''; - if ($b['state_rep'] > 0) { - $assigned_to_state = $statesList[$b['state_rep']]['code']; - } - if ($b['team'] > 0 ) { - $assigned_to_team = $statesList[$b['state_rep']]['teams'][$b['team']]['name']; - $team_code = $statesList[$b['state_rep']]['teams'][$b['team']]['team_code']; - } - - // Build block info array - $block = array ( - 'block_id' => $b['block_id'], - 'block_name' => $b['block_name'], - 'memb_name' => $b['memb_name'], - 'memb_id' => $b['memb_id'], - 'accom_info' => - ''.$b['memb_name']."
    " - .$b['quant'].": ".$b['accom_name']."
    ", - 'accoms' => array($b['accom_name'] => array( - 'accom_name' => $b['accom_name'], 'quant' => $b['quant'], 'available' => $b['available'] - )), - 'accom_quant' => $b['quant'], - 'assigned' => $assigned, - 'assigned_to_state' => $assigned_to_state, - 'assigned_to_team' => $assigned_to_team, - 'team_code' => $team_code - ); - - // If block as been assigned to a team - if ($b['team'] > 0) { - - if (!isset($statesList[$b['state_rep']]['teams'][$b['team']]['blocks'][$b['block_id']])) { - $statesList[$b['state_rep']]['teams'][$b['team']]['blocks'][$b['block_id']] = $block; - } else { - $statesList[$b['state_rep']]['teams'][$b['team']]['blocks'][$b['block_id']]['accom_info'] .= $b['quant'].": ".$b['accom_name']."
    "; - $statesList[$b['state_rep']]['teams'][$b['team']]['blocks'][$b['block_id']]['accoms'][$b['accom_name']] = array( - 'accom_name' => $b['accom_name'], 'quant' => $b['quant'], 'available' => $b['available'] - ); - // Update sort of accoms array to keep it alphabetical - ksort($statesList[$b['state_rep']]['teams'][$b['team']]['blocks'][$b['block_id']]['accoms']); - } - - // Otherwise it must just be assigned to a state rep so far - } elseif ($b['state_rep'] > 0) { - - if (!isset($statesList[$b['state_rep']]['blocks'][$b['block_id']])) { - $statesList[$b['state_rep']]['blocks'][$b['block_id']] = $block; - } else { - $statesList[$b['state_rep']]['blocks'][$b['block_id']]['accom_info'] .= $b['quant'].": ".$b['accom_name']."
    "; - $statesList[$b['state_rep']]['blocks'][$b['block_id']]['accoms'][$b['accom_name']] = array( - 'accom_name' => $b['accom_name'], 'quant' => $b['quant'], 'available' => $b['available'] - ); - - ksort($statesList[$b['state_rep']]['blocks'][$b['block_id']]['accoms']); - } - - } - - // If the block is not assigned to either a state or team, or if we're running in summary mode, include under property. - if (($b['team'] == 0 && $b['state_rep'] == 0) || $summary) { - - if (!isset($blocksList[$b[memb_id]]['blocks'][$b['block_id']])) { - $blocksList[$b[memb_id]]['blocks'][$b['block_id']] = $block; - } else { - $blocksList[$b[memb_id]]['blocks'][$b['block_id']]['accom_info'] .= $b['quant'].": ".$b['accom_name']."
    "; - $blocksList[$b[memb_id]]['blocks'][$b['block_id']]['accoms'][$b['accom_name']] = array( - 'accom_name' => $b['accom_name'], 'quant' => $b['quant'], 'available' => $b['available'] - ); - // Update sort of accoms array to keep it alphabetical - ksort($blocksList[$b[memb_id]]['blocks'][$b['block_id']]['accoms']); - } - - } - - } - - // Check if there's no blocksList yet - if (count($blocksList) == 0) { - $blocksList = false; - } - - // Function to Sort all blocks by block_name (number) - function blockCmp($a, $b) { - - $aval = $a['block_name']; - $bval = $b['block_name']; - - if ($val == $bval) { - return 0; - } - return ($aval < $bval) ? -1 : 1; - } - - // Sort unasigned blocks - reset ($blocksList); - while (list($k, $v) = each($blocksList)) { - if (is_array($v['blocks'])) { - uasort($blocksList[$k]['blocks'], 'blockCmp'); - } - } - - // Sort blocks assigned to states or teams - reset ($statesList); - while (list($k, $v) = each($statesList)) { - - // Check for and sort any blocks not assigned to teams - if (is_array($v['blocks'])) { - uasort($statesList[$k]['blocks'], 'blockCmp'); - } - - // Check for any teams - if (is_array($v['teams'])) { - while (list($tk, $tv) = each($v['teams'])) { - if (is_array($tv['blocks'])) { - uasort($statesList[$k]['teams'][$tk]['blocks'], 'blockCmp'); - } - } - } - } - - // Sort accommodation types - - $r = array( - 'blocks' => $blocksList, - 'states' => $statesList - ); - - // echo "
    ".htmlentities(print_r($r,1))."
    "; - return $r; - } - - /** - * Save Room Blocks - * - * @return object containing array as sub-objects - */ - function saveRoomBlocks() - { - - // Make sure we have an event selected (shouldn't happen that we don't) - if (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - // Get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - } else { - // Otherwise, we don't have a member id - return false; - } - - // Get room block drop list - $dropList = $_REQUEST['blocks']; - - // Separate into separate move requests - $drops = explode(',', $dropList); - - $sql = array(); - - // For each block moved - foreach ($drops as $d) { - - // separate the block id from the destination - $x = explode('|', $d); - $block = $x[0]; - - // separate the destination id from the type - $y = explode('_', $x[1]); - - // Set any state and team assignments for this block - $state = 'null'; - $team = 'null'; - switch ($y[0]) { - - case 'state': - - $state = ($y[1] - 0); - - if ($y[2] == 'team') { - $team = ($y[3] - 0); - } - - break; - - case 'member': - // If moved back to member, then there's no assignment - break; - - } - - if ($state == 0) { - $state = 'null'; - } - if ($team == 0) { - $team = 'null'; - - } - - $sql[] = " - UPDATE room_block - SET state_rep = $state, - team = $team - WHERE conv = $eventID - AND block_name = $block; - "; - } - - if (count($sql) > 0) { - try { - $this->dbh->beginTransaction(); - foreach ($sql as $s) { - $this->dbh->exec($s); - } - $this->dbh->commit(); - } catch (Exception $e) { - $this->dbh->rollBack(); - } - - } - - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/bookings.php b/legacy/models/admin/classes/bookings.php deleted file mode 100755 index c85c779..0000000 --- a/legacy/models/admin/classes/bookings.php +++ /dev/null @@ -1,102 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/bookings.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataBookings.php'; - -/** - * EventManagementAdminBookings class - * - * Event Management and Reservations System - Admin Code - Bookings section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/bookings.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminBookings extends EventManagementDataBookings -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Members Stats - * - * @return object containing array as sub-objects - */ - function getBookingsStats() - { - $bookingsStats = array( - 'all' => $this->getStats(), - 'event' => 0, - 'member' => 0, - 'team' => 0 - ); - - // Get event ID from session - if available get stats for bookings listed with this event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - $bookingsStats['event'] = $this->getStats(" - conv = $eventID - "); - } - - // Get member ID from session - if available get stats for bookings for this member - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - $bookingsStats['member'] = $this->getStats(" - property = $memberID - "); - } - - // Get team ID from session - if available get stats for bookings listed with this team - if (($teamID = $_SESSION[GLM_EVENT_SESSION]['Team'])) { - $bookingsStats['team'] = $this->getStats(" - team = $teamID - "); - } - - return $bookingsStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/contacts.php b/legacy/models/admin/classes/contacts.php deleted file mode 100755 index 422cd1f..0000000 --- a/legacy/models/admin/classes/contacts.php +++ /dev/null @@ -1,122 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/contacts.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataContacts.php'; - -/** - * EventManagementAdminContacts class - * - * Event Management and Reservations System - Admin Code - Contacts section - * - * PHP version 5 - * - * @category Event Management Admin Contacts - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/contacts.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminContacts extends EventManagementDataContacts -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - - /** - * Get Contacts Stats - * - * @return object containing array as sub-objects - */ - function getEventContactsStats() - { - // Check for selected Event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - return $this->getStats(" - contact_type = ".$this->config->reference_type->event." - AND affiliation = $eventID - "); - } - return 0; - } - function getMemberContactsStats() - { - // Check for selected Member - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - return $this->getStats(" - contact_type = ".$this->config->reference_type->member." - AND affiliation = $memberID - "); - } - return 0; - } - function getStateContactsStats() - { - // Check for selected State Rep - if (($stateID = $_SESSION[GLM_EVENT_SESSION]['State'])) { - return $this->getStats(" - contact_type = ".$this->config->reference_type->state." - AND affiliation = $stateID - "); - } - return 0; - } - function getTeamContactsStats() - { - - // Check for selected Team - if (($teamID = $_SESSION[GLM_EVENT_SESSION]['Team'])) { - return $this->getStats(" - contact_type = ".$this->config->reference_type->team." - AND affiliation = $teamID - "); - } - return 0; - } - function getContactsStats() - { - - $contactsStats = array( - 'all' => $this->getStats(), - 'event' => $this->getEventContactsStats(), - 'member' => $this->getMemberContactsStats(), - 'state' => $this->getStateContactsStats(), - 'team' => $this->getTeamContactsStats() - ); - - return $contactsStats; - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/dataList.php b/legacy/models/admin/classes/dataList.php deleted file mode 100755 index 1719cbd..0000000 --- a/legacy/models/admin/classes/dataList.php +++ /dev/null @@ -1,188 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -/** - * EventManagementAdminEvents class - * - * Event Management and Reservations System - Admin Code - Events section - * - * PHP version 5 - * - * @category Event Management Admin Events - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminEvents -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - /** - * Constructor - * - * @param object $d database connection - * - * @return void - * @access public - */ - public function __construct($dbh, $config) - { - $this->dbh = $dbh; - $this->config = $config; - } - - - /** - * Get Events Stats - * - * @return object containing array as sub-objects - */ - function getEventsStats() - { - - // Get list of all available Events - $sql = "SELECT ( SELECT count(id) FROM eventmgt.event WHERE active ) AS active, - ( SELECT count(id) FROM eventmgt.event WHERE NOT active ) AS inactive - ;"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventsStats = $stmt->fetch(PDO::FETCH_ASSOC); - - return $eventsStats; - } - - /** - * Get Events list - * - * @param string type of events list - * - * @return object containing array as sub-objects - */ - function getEventsList() - { - - // Get any specified event listing option - default to active - $option = 'active'; - if (($eventsListOption = filter_input(INPUT_GET, 'EventsListOption', FILTER_SANITIZE_STRING))) { - $option = $eventsListOption; - } - - // Clear Session Event Selection - $_SESSION[GLM_EVENT_SESSION]['Event'] = false; - - // Select type of list - $where = ''; - switch ($option) { - case 'all': - $where = 'true'; - break; - case 'active': - $where = "active AND end_date > 'now'"; - break; - case 'inactive': - $where = "NOT active AND end_date > 'now'"; - break; - case 'expired': - $where = "active AND end_date < 'now'"; - break; - case 'archived': - $where = "NOT active AND end_date < 'now'"; - break; - default: - echo "Option not set"; - break; - } - - // Get list of all available Events - $sql = "SELECT id, name, event_code, start_date, end_date, cutoff_date - FROM eventmgt.event - WHERE $where - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventsList = $stmt->fetchAll(PDO::FETCH_ASSOC); - - if (count($eventsList) == 0) - return false; - return $eventsList; - } - - /** - * Get Event Detail - * - * Returns an array of event detail data for an event. - * - * @param array $array of values to convert - * - * @return object containing array as sub-objects - */ - function getEventDetail() - { - // Is there a new event code selected? - if (($eventID = filter_input(INPUT_GET, 'EventID', FILTER_SANITIZE_NUMBER_INT))) { - - // If so then add it to the session - $_SESSION[GLM_EVENT_SESSION]['Event'] = $eventID; - - } elseif (isset($_SESSION[GLM_EVENT_SESSION]['Event'])) { - - // Otherwise, get the event ID from the session - $eventID = $_SESSION[GLM_EVENT_SESSION]['Event']; - - } else { - - // Otherwise, we don't have an event id - return false; - - } - - $sql = "SELECT * - FROM eventmgt.event - WHERE id = '$eventID';"; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventDetail = $stmt->fetch(PDO::FETCH_ASSOC); - - return $eventDetail; - } - - - -} - -?> - diff --git a/legacy/models/admin/classes/divisions.php b/legacy/models/admin/classes/divisions.php deleted file mode 100755 index f88d22e..0000000 --- a/legacy/models/admin/classes/divisions.php +++ /dev/null @@ -1,87 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/divisions.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataDivisions.php'; - -/** - * EventManagementAdminDivisions class - * - * Event Management and Reservations System - Admin Code - Divisions section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/divisions.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminDivisions extends EventManagementDataDivisions -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get State Divisions - * - * @return object containing array as sub-objects - */ - function getDivisionsStats() - { - $divisionsStats = array( - 'all' => $this->getStats(), - 'event' => 0, - 'state' => 0 - ); - - // Get event ID from session - if available get stats for teams listed with this event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - $divisionsStats['event'] = $this->getStats(" - conv = $eventID - "); - } - - return $divisionsStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/entrances.php b/legacy/models/admin/classes/entrances.php deleted file mode 100755 index a863ca6..0000000 --- a/legacy/models/admin/classes/entrances.php +++ /dev/null @@ -1,81 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/entrances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataEntrances.php'; - -/** - * EventManagementAdminContacts class - * - * Event Management and Reservations System - Admin Code - Entrances section - * - * PHP version 5 - * - * @category Event Management Admin Entrances - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/entrances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminEntrances extends EventManagementDataEntrances -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * Get Entrances Stats - * - * @return object containing array as sub-objects - */ - function getMemberEntrancesStats($memberID = false) - { - // Get member ID from session - if available get stats for member - if ($memberID || ($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - return $this->getStats("member = $memberID"); - } - return 0; - } - function getEntrancesStats() - { - $entrancesStats = array( - 'all' => $this->getStats(), - 'member' => $this->getMemberEntrancesStats() - ); - - return $entrancesStats; - } - - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/eventFees.php b/legacy/models/admin/classes/eventFees.php deleted file mode 100755 index 0218d87..0000000 --- a/legacy/models/admin/classes/eventFees.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/eventFees.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataFees.php'; - -/** - * EventManagementAdminStates class - * - * Event Management and Reservations System - Admin Code - Event Fees Section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/eventFees.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminEventFees extends EventManagementDataFees -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Event Fees Stats - * - * @return object containing array as sub-objects - */ - function getEventFeesStats() - { - $eventFeesStats = array( - 'all' => $this->getStats(), - 'event' => 0 - ); - - // Get event ID from session - if available get stats for teams listed with this event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - $eventFeesStats['event'] = $this->getStats(" - owner = $eventID - "); - } - - return $eventFeesStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/eventReport.php b/legacy/models/admin/classes/eventReport.php deleted file mode 100755 index a091d24..0000000 --- a/legacy/models/admin/classes/eventReport.php +++ /dev/null @@ -1,206 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/eventReport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/Reports/dataEventReport.php'; - -/** - * EventManagementAdminEvents class - * - * Event Management and Reservations System - Admin Code - Event Report section - * - * PHP version 5 - * - * @category Event Management Admin Events - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminEventReport extends EventManagementDataEventReport -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - function __construct($dbh, $config) - { - parent::__construct($dbh, $config); - } - - /** - * Get Report Request Form - * - * @return object containing array as sub-objects - */ - function getForm() - { - - $reportData = array( - 'status' => true, - 'reason' => array(), - 'form' => array() - ); - - $reportData['form'] = $this->newControls(); - - return $reportData; - } - - /** - * Process Report - * - * @return object containing array as sub-objects - */ - function getReport() - { - - $reportData = array( - 'status' => true, - 'output' => false, - 'reason' => array(), - 'report' => array() - ); - - /* - * Try to process report form request - */ - $request = $this->processInputData(); - if (!$request['status']) { - $reportData['status'] = false; - - if ($request['fieldFail']['event_name']) { - $reportData['reason'][] = 'An event was not selected'; - } - - if ($request['fieldFail']['output_type']) { - $reportData['reason'][] = 'An output type was not selected'; - } - - } - - // Get selections - $r = $request['fieldData']; - $event = $r['event_name']['in']; - $statistics = $r['statistics_section']['value']; - $contacts = $r['contacts_section']['value']; - $housing = $r['housing_section']['value']; - $housing_available_only = $r['housing_available_only']['value']; - $housing_summary_only = $r['housing_summary_only']['value']; - $reservations = $r['reservations_section']['value']; - $reservations_summary_only = $r['reservations_summary_only']['value']; - $reportData['output'] = $r['output_type']['value']; - - // If the request is valid - Produce the report - if ($reportData['status']) { - - /* - * Get report data - */ - - // Get Event data - $sql = "SELECT * FROM eventmgt.event WHERE id = $event;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['event'] = $eventData; - - // Get Statistics - $reportData['report']['doingStatistics'] = $statistics; - if ($statistics) { - // Not built yet - } - - // Get Contacts - $reportData['report']['doingContacts'] = $contacts; - if ($contacts) { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataContacts.php'; - $Contacts = new EventManagementDataContacts($this->dbh, $this->config); - $where = "T.contact_type = ".$this->config->reference_type->event." AND affiliation = $event"; - $contactsList = $Contacts->getList($where); - $reportData['report']['contacts'] = $contactsList; - } - - // Get Housing and Inventory - - $reportData['report']['doingHousing'] = $housing; - $reportData['report']['showAllInventoryDataDetail'] = !$housing_available_only; - $reportData['report']['showHousingDetail'] = !$housing_summary_only; - if ($housing) { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataInventory.php'; - $Inventory = new EventManagementDataInventory($this->dbh, $this->config); - $inventoryList = $Inventory->getInvenList('event', $event); - - // Sort inventory by summary - function sortByMember($a, $b) - { - if ($a['name'] > $b['name']) { - return 1; - } elseif ($b['name'] > $a['name']) { - return -1; - } - return 0; - } - while (list($k, $v) = each($inventoryList['sum'])) { - uasort($v['memb'], 'sortByMember'); - $inventoryList['sum'][$k] = $v; - } - - $reportData['report']['housing'] = $inventoryList; - } - - // Get Reservations - Use existing report class for reservations - $reportData['report']['doingReservations'] = $reservations; - $reportData['report']['showReservationsDetail'] = !$reservations_summary_only; - if ($reservations) { - require 'reservationReport.php'; - $Reservations = new EventManagementAdminReservationReport($this->dbh, $this->config); - $reservationsList = $Reservations->getReport($event); - $reportData['report']['reservations'] = $reservationsList['report']; - } - - } - - return $reportData; - } - - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/events.php b/legacy/models/admin/classes/events.php deleted file mode 100755 index 2fa7625..0000000 --- a/legacy/models/admin/classes/events.php +++ /dev/null @@ -1,153 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataEvents.php'; - -/** - * EventManagementAdminEvents class - * - * Event Management and Reservations System - Admin Code - Events section - * - * PHP version 5 - * - * @category Event Management Admin Events - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminEvents extends EventManagementDataEvents -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Events Stats - * - * @return object containing array as sub-objects - */ - function getEventsStats() - { - $eventsStats = array( - 'all' => $this->getStats(), - 'active' => $this->getStats('active'), - 'inactive' => $this->getStats('NOT active'), - 'expired' => $this->getStats("active AND end_date < 'now'"), - 'archived' => $this->getStats("NOT active AND end_date < 'now'"), - 'member' => 0, - 'team' => 0 - ); - - // Get member ID from session - if available get stats for events for this member - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - $eventsStats['member'] = $this->getStats(" - id IN ( - SELECT DISTINCT event - FROM eventmgt.inventory - WHERE member = $memberID - ) - "); -/* Trying to not use event_prop table for this - $eventsStats['member'] = $this->getStats(" - id IN ( - SELECT DISTINCT event - FROM eventmgt.event_prop - WHERE property = $memberID - ) - "); -*/ - } - - // Get team ID from session - if available get stats for bookings listed with this team - if (($teamID = $_SESSION[GLM_EVENT_SESSION]['Team'])) { - $bookingsStats['team'] = $this->getStats(" - id IN ( - SELECT DISTINCT event - FROM eventmgt.team_property - WHERE team = $teamID - ) - "); - } - - return $eventsStats; - } - - /** - * Get Member Events - * - * @return object containing array as sub-objects - */ - function getMemberEvents() - { - // Get member ID - if (isset($_SESSION[GLM_EVENT_SESSION]['Member'])) { - // Get the event ID from the session - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - } else { - // Otherwise, we don't have a member id - return false; - } - - // Only look for events for the specified property - $where = "T.id IN ( - SELECT DISTINCT event - FROM eventmgt.inventory - WHERE member = $memberID - )"; -/* Trying to not use event_prop table for this - $where = "T.id IN ( - SELECT event - FROM eventmgt.event_prop - WHERE property = $memberID - )"; -*/ - $memberEvents = $this->getEventsList($where); - - if (count($memberEvents) == 0) { - return false; - } - - return $memberEvents; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/inventory.php b/legacy/models/admin/classes/inventory.php deleted file mode 100755 index dddc77a..0000000 --- a/legacy/models/admin/classes/inventory.php +++ /dev/null @@ -1,124 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/invetory.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataInventory.php'; - -/** - * EventManagementAdminInventory class - * - * Event Management and Reservations System - Admin Code - Inventory section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/inventory.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminInventory extends EventManagementDataInventory -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Inventory Stats - * - * @return object containing array as sub-objects - */ - function getEventInvenStats() - { - // Get event ID from session - if available get stats for event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - return $this->getStats("conv = $eventID"); - } - return 0; - } - function getMemberInvenStats() - { - // Get member ID from session - if available get stats for member - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - return $this->getStats("member = $memberID"); - } - return 0; - } - function getAccomInvenStats() - { - // Get accommodation ID from session - if available get stats for accommodation - if (($accomID = $_SESSION[GLM_EVENT_SESSION]['Accom'])) { - return $this->getStats("accommodation = $accomID"); - } - return 0; - } - function getTeamInvenStats() - { - // Get team ID from session - if available get stats for team - if (($teamID = $_SESSION[GLM_EVENT_SESSION]['Team'])) { - return $this->getStats(" - id in - ( - SELECT I.id - FROM eventmgt.inventory I, eventmgt.team_property TP - WHERE TP.team = $teamID - AND I.member = TP.property - AND I.date between TP.start AND TP.stop - ) - "); - } - return 0; - } - function getInvenStats() - { - $invenStats = array( - 'all' => $this->getStats(), - 'event' => $this->getEventInvenStats(), - 'member' => $this->getMemberInvenStats(), - 'accom' => $this->getAccomInvenStats(), - 'team' => $this->getTeamInvenStats() - ); - return $invenStats; - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/memberAmenities.php b/legacy/models/admin/classes/memberAmenities.php deleted file mode 100755 index 201a22d..0000000 --- a/legacy/models/admin/classes/memberAmenities.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/memberAmenities.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataAmenities.php'; - -/** - * EventManagementAdminStates class - * - * Event Management and Reservations System - Admin Code - Member Amenities Section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/memberAmenities.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminMemberAmenities extends EventManagementDataAmenities -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Member Amenities Stats - * - * @return object containing array as sub-objects - */ - function getMemberAmenitiesStats() - { - $memberAmenitiesStats = array( - 'all' => $this->getStats(), - 'member' => 0 - ); - - // Get member ID from session - if available get stats - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - $memberAmenitiesStats['member'] = $this->getStats(" - owner = $memberID - "); - } - - return $memberAmenitiesStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/memberFees.php b/legacy/models/admin/classes/memberFees.php deleted file mode 100755 index d1f43a8..0000000 --- a/legacy/models/admin/classes/memberFees.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/memberFees.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataFees.php'; - -/** - * EventManagementAdminStates class - * - * Event Management and Reservations System - Admin Code - Member Fees Section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/memberFees.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminMemberFees extends EventManagementDataFees -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Member Fees Stats - * - * @return object containing array as sub-objects - */ - function getMemberFeesStats() - { - $memberFeesStats = array( - 'all' => $this->getStats(), - 'member' => 0 - ); - - // Get member ID from session - if available get stats - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - $memberFeesStats['member'] = $this->getStats(" - owner = $memberID - "); - } - - return $memberFeesStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/members.php b/legacy/models/admin/classes/members.php deleted file mode 100755 index 1605604..0000000 --- a/legacy/models/admin/classes/members.php +++ /dev/null @@ -1,198 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/members.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMembers.php'; - -/** - * EventManagementAdminMembers class - * - * Event Management and Reservations System - Admin Code - Members section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/members.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminMembers extends EventManagementDataMembers -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Members Stats - * - * @return object containing array as sub-objects - */ - function getMembersStats() - { - // Basic member stats - $membersStats = array( - 'all' => $this->getStats() // Count of all members - ); - - // Get event ID from session - if available get stats for members listed with this event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - $membersStats['event'] = $this->getStats(" - id in - ( - SELECT DISTINCT(member) - FROM eventmgt.inventory - WHERE conv = $eventID - ) - "); - } else { - // Otherwise if no event number is 0 - $membersStats['event'] = 0; - } - - // If doing accommodations - get accommodation stats - if ($this->config->option->accommodations) { - $membersStats['accom'] = $this->getStats(" - id in - ( - SELECT DISTINCT member - FROM eventmgt.accommodation - ) - "); - } - - // If doing tickets - get ticket stats - if ($this->config->option->tickets) { - $membersStats['ticket'] = $this->getStats(" - id in - ( - SELECT DISTINCT member - FROM eventmgt.ticket - ) - "); - }; - - // determine if there's any status flags we should set - $membersStats['flags'] = false; - $membersStats['flag'] = false; - if ($membersStats['all'] == 0) { - $membersStats['flags']['noMembers'] = true; - $membersStats['flag'] = true; - } - if ($this->config->option->accommodations && $membersStats['accom'] == 0) { - $membersStats['flags']['noMemberAccoms'] = true; - $membersStats['flag'] = true; - } - if ($this->config->option->tickets && $membersStats['ticket'] == 0) { - $membersStats['flags']['noMemberTickets'] = true; - $membersStats['flag'] = true; - } - if ($this->config->option->events && $membersStats['event'] == 0) { - $membersStats['flags']['noMemberEvents'] = true; - $membersStats['flag'] = true; - } - - return $membersStats; - } - - function checkNewMembers() - { - // This function should not be called if it's not an integrated database - if ($this->config->option->member_db_integrated == false) { - return false; - } - - // Check that referenced members also have an entry in the res_member table - $sql = "SELECT member_id, member_name - FROM members.member - WHERE member_id IN - ( - SELECT member_id - FROM members.member_category - WHERE category_id IN - ( - SELECT category_id - FROM members.category - WHERE accommodations - ) - ) - AND member_id NOT IN - ( - SELECT id - FROM eventmgt.member - ); - "; - - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $members = $stmt->fetchAll(PDO::FETCH_ASSOC); - - $r['reason'] = array(); - $sql = array(); - if ($members && count($members) > 0 ) { - foreach ($members as $memb ) { - // Add an entry in the res_member table - $sql[] = " - INSERT INTO eventmgt.member - (id, name) - VALUES - (".$memb['member_id'].", '".addslashes($memb['member_name'])."'); - "; - } - - try { - $this->dbh->beginTransaction(); - foreach ($sql as $s) { - $this->dbh->exec($s); - } - $this->dbh->commit(); - } catch (Exception $e) { - $this->dbh->rollBack(); - $r['status'] = false; - $r['reason'][] = 'Unable to store new properties for unknown reason. '; - } - - } - - return $r; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/misc.php b/legacy/models/admin/classes/misc.php deleted file mode 100755 index 37c7131..0000000 --- a/legacy/models/admin/classes/misc.php +++ /dev/null @@ -1,58 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/misc.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMisc.php'; - -/** - * EventManagementAdminSold class - * - * Event Management and Reservations System - Admin Code - Misc - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/misc.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementAdminMisc extends EventManagementDataMisc -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/orders.php b/legacy/models/admin/classes/orders.php deleted file mode 100755 index d0e1fa7..0000000 --- a/legacy/models/admin/classes/orders.php +++ /dev/null @@ -1,58 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/orders.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataOrders.php'; - -/** - * EventManagementAdminOrders class - * - * Event Management and Reservations System - Admin Code - Contacts ticket - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/orders.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementAdminOrders extends EventManagementDataOrders -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/performances.php b/legacy/models/admin/classes/performances.php deleted file mode 100755 index 7a3683c..0000000 --- a/legacy/models/admin/classes/performances.php +++ /dev/null @@ -1,79 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/performances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPerformances.php'; - -/** - * EventManagementAdminContacts class - * - * Event Management and Reservations System - Admin Code - Performances Section - * - * PHP version 5 - * - * @category Event Management Admin Performances - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/performances.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminPerformances extends EventManagementDataPerformances -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * Get Performances Stats - * - * @return object containing array as sub-objects - */ - function getMemberPerformancesStats($memberID = false) - { - // Get member ID from session - if available get stats for member - if ($memberID || ($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - return $this->getStats("member = $memberID AND active"); - } - return 0; - } - function getPerformancesStats() - { - $performancesStats = array( - 'all' => $this->getStats(), - 'member' => $this->getMemberPerformancesStats() - ); - - return $performancesStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/promoTickets.php b/legacy/models/admin/classes/promoTickets.php deleted file mode 100755 index 9a0b827..0000000 --- a/legacy/models/admin/classes/promoTickets.php +++ /dev/null @@ -1,126 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/promoTickets.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPromoTickets.php'; - -/** - * EventManagementAdminPromoTickets class - * - * Event Management and Reservations System - Admin Code - Promotion Tickets section - * - * PHP version 5 - * - * @category Event Management Admin Add-Ons - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/promoTickets.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminPromoTickets extends EventManagementDataPromoTickets -{ - /** - * Configuration information object - * @var $config - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $data - * @access public - */ - public $data; - - /** - * Get Promos Stats - * - * @return object containing array as sub-objects - */ - function getPromoTicketsStats() - { - return $this->getStats(); - } - - /** - * Process Promomotion Tickets and return list - * - * @return object containing array as sub-objects - */ - function processPromoTicketsList($promoID) - { - - // Check for promotion tickets update - if (isset($_REQUEST['Option']) && $_REQUEST['Option'] = 'update_promoTickets') { - - // Process all promotion ticket requests - $sql = ''; - if (isset($_REQUEST['type']) && count($_REQUEST['type']) > 0) { - while (list($k, $v) = each($_REQUEST['type'])) { - - // If this is a new addition - if ($k == 0 && ($_REQUEST['ticket'][$k]-0) > 0 && ($_REQUEST['amount'][$k]-0) > 0) { - $sql .= "INSERT INTO eventmgt.promo_ticket - (promo, ticket, promo_type, amount, notes) - VALUES - ( - $promoID, - ".($_REQUEST['ticket'][$k]-0).", - ".($_REQUEST['type'][$k]-0).", - ".($_REQUEST['amount'][$k]-0.0).", - '".addslashes($_REQUEST['notes'][$k])."' - ); - "; - - // If it's a delete request - } elseif (isset($_REQUEST['delete'][$k])) { - $sql .= "DELETE FROM eventmgt.promo_ticket WHERE id = $k; - "; - - // Otherwise update it - } else { - $sql .= "UPDATE eventmgt.promo_ticket SET - amount = ".($_REQUEST['amount'][$k]-0.0).", - notes = '".addslashes($_REQUEST['notes'][$k])."' - WHERE id = $k; - "; - } - - } - if ($sql != '') { - $this->dbh->exec($sql); - } - - } - - } - - // Get updated list of promotion tickets - $promoTicketsList = $this->getPromoTicketsList($promoID); - - return $promoTicketsList; - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/promos.php b/legacy/models/admin/classes/promos.php deleted file mode 100755 index 034e6f3..0000000 --- a/legacy/models/admin/classes/promos.php +++ /dev/null @@ -1,68 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/promos.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPromos.php'; - -/** - * EventManagementAdminPromos class - * - * Event Management and Reservations System - Admin Code - Promotionss section - * - * PHP version 5 - * - * @category Event Management Admin Add-Ons - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/promos.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminPromos extends EventManagementDataPromos -{ - /** - * Configuration information object - * @var $config - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $data - * @access public - */ - public $data; - - /** - * Get Promos Stats - * - * @return object containing array as sub-objects - */ - function getPromosStats() - { - return $this->getStats(); - - return 0; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/promosSold.php b/legacy/models/admin/classes/promosSold.php deleted file mode 100755 index 9d18aec..0000000 --- a/legacy/models/admin/classes/promosSold.php +++ /dev/null @@ -1,57 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/promosSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPromoSold.php'; - -/** - * EventManagementAdminPromosSold class - * - * Event Management and Reservations System - Admin Code - Sold Ticket promos - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/promosSold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementAdminPromosSold extends EventManagementDataPromoSold -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/reservationReport.php b/legacy/models/admin/classes/reservationReport.php deleted file mode 100755 index 1712904..0000000 --- a/legacy/models/admin/classes/reservationReport.php +++ /dev/null @@ -1,343 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/reservationReporteport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/Reports/dataReservationReport.php'; - -/** - * EventManagementAdminEvents class - * - * Event Management and Reservations System - Admin Code - Reservation Report section - * - * PHP version 5 - * - * @category Event Management Admin Events - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminReservationReport extends EventManagementDataReservationReport -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - function __construct($dbh, $config) - { - parent::__construct($dbh, $config); - } - - /** - * Get Report Request Form - * - * @return object containing array as sub-objects - */ - function getForm() - { - - $reportData = array( - 'status' => true, - 'reason' => array(), - 'form' => array() - ); - - $reportData['form'] = $this->newControls(); - - $this->addDebug("classes/reservationReport.inc", 'getForm()', print_r($reportData,1)); - - return $reportData; - } - - /** - * Process Report - * - * @return object containing array as sub-objects - */ - function getReport($setEvent = false, $setState = false) - { - - $reportData = array( - 'status' => true, - 'output' => false, - 'reason' => array(), - 'report' => array() - ); - - // If no specific event and state rep is requested, then process input for selections - if ($setState == false) { - - /* - * Try to process report form request - */ - $request = $this->processInputData(); - if (!$request['status']) { - $reportData['status'] = false; - - if ($request['fieldFail']['event_name']) { - $reportData['reason'][] = 'An event was not selected'; - } - - if ($request['fieldFail']['output_type']) { - $reportData['reason'][] = 'An output type was not selected'; - } - - } - $r = $request['fieldData']; - - - /* - * Get report data - */ - // Check for specified event - if ($setEvent) { - $event = $setEvent; - } else { - $event = $request['fieldData']['event_name']['in']; - } - - $state = ($r['state_rep']['in'] != '0' ? $r['state_rep']['in'] : false); - $team = ($r['team_code']['in'] != '0' ? $r['team_code']['in'] : false); - $property = ($r['prop_name']['in'] != '0' ? $r['prop_name']['in'] : false); - $status = $r['status']['value']; - $where = ''; - - // Make Reservation Report Request Data available to template - $reportData['report']['event'] = false; - if ($event > 0) { - - // Get Event data - $sql = "SELECT * FROM eventmgt.event WHERE id = $event;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['event'] = $eventData; - - $where = "conv = $event"; - - } - - // Check for State Rep filter - if ($state > 0) { - $where .= ($where!=''?' AND ':'')." T.state_rep = $state"; - } - - // If a team has been selected, filter by that. - if ($team) { - $where .= ($where!=''?' AND ':'')." T.team_id = $team"; - } - - // If a property has been selected, filter by that. - if ($property) { - $where .= ($where!=''?' AND ':'')." T.member = $property"; - } - - // Select by status - switch ($status) { - case 'pending': - $where .= ($where!=''?' AND ':'')." NOT T.confirmed AND NOT T.declined"; - break; - case 'confirmed': - $where .= ($where!=''?' AND ':'')." T.confirmed AND NOT T.declined"; - break; - case 'declined': - $where .= ($where!=''?' AND ':'')." T.declined"; - break; - case 'all': - default: - break; - } - - } else { - - // There's been a specific request - $event = $setEvent; - $state = $setState; - $team = false; - $where = " T.state_rep = $state"; - - } - - - // If a State Rep is selected filter by that - if ($state) { - - // Build query where clause to filter for any requested state - $where .= ($where!=''?' AND ':'')." T.team_id IN (SELECT team.id FROM eventmgt.team WHERE state = $state)"; - - // Also get state information - $sql = "SELECT * FROM eventmgt.state_rep WHERE id = $state;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $stateData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['state'] = $stateData; - - } - - // If a team has been selected, filter by that. - if ($team) { - - $where .= ($where!=''?' AND ':'')." T.team_id = $team"; - - // Also get team information - $sql = "SELECT * FROM eventmgt.team WHERE id = $team;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $teamData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['team'] = $teamData; - } - - // If a property has been selected, filter by that. - if ($property) { - - $where .= ($where!=''?' AND ':'')." T.member = $property"; - - // Also get team information - $sql = "SELECT * FROM eventmgt.member WHERE id = $property;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $propertyData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['property'] = $propertyData; - } - - // Get Event Reservations - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataReservations.php'; - $Reservations = new EventManagementDataReservations($this->dbh, $this->config); - $reservationsList = $Reservations->getList($where); - - // Build totals - $numb_res = 0; - $total_hotel = 0; - $total_taxes = 0; - $total_fees = 0; - $grand_total = 0; - if (is_array($reservationsList) && count($reservationsList) > 0) { - reset($reservationsList); - while (list($k, $v) = each($reservationsList)) { - $reservationsList[$k]['detail'] = unserialize($v['res_detail']); - $taxes = 0; - $fees = 0; - // Make sure we decoded the res_detail (there's been some problems with that) - if($reservationsList[$k]['detail']) { - - $x = $reservationsList[$k]['detail']['propFees']; - foreach ($x as $f) { - $fees += $f['fee_calculated']; - } - -/* This doesn't seem to work. Need to revisit this when done with Kalamazoo Fee structure - $x = $reservationsList[$k]['detail']['propAccom']; - foreach ($x as $accom) { - // In case we get the values with leading "$" - if($accom['accom_fees_taxable'][0] == '$') { - $accom['accom_fees_taxable'] = substr($accom['accom_fees_non_taxable'],1); - } - if($accom['accom_fees_non_taxable'][0] == '$') { - $accom['accom_fees_non_taxable'] = substr($accom['accom_fees_non_taxable'],1); - } - // Now add the taxes and fees - $taxes += ($accom['accom_fees_taxable']-0); - $fees += ($accom['accom_fees_non_taxable']-0); - - } -*/ - - $numb_res++; - $total_taxes += $taxes; - $total_fees += $fees; - $reservationsList[$k]['taxes'] = $this->money($taxes); - $reservationsList[$k]['fees'] = $this->money($fees); - $reservationsList[$k]['taxes_and_fees'] = $this->money($taxes + $fees); - $total_hotel += $v['hotel_price_numb']; - $grand_total += $v['grand_total_numb']; - } else { - // We get here if the res_detail field doesn't unserialize or if there's nothing in the field. - // Had a problem with this originally due to corruption of the serialized data by using stripslashes(). Don't do that! - echo "System Error: Unable to decode reservation detail for reservation # ".$v['id']." - Please contact Gaslight Media.
    "; - } - } - } - - $reportData['report']['reservations'] = $reservationsList; - $reportData['output'] = $r['output_type']['value']; - - $reportData['report']['totals'] = array( - 'numb_reservations' => $numb_res, - 'hotel' => $this->money($total_hotel), - 'taxes' => $this->money($total_taxes), - 'fees' => $this->money($total_fees), - 'taxes_and_fees' => $this->money($total_taxes + $total_fees), - 'grand_total' => $this->money($grand_total) - ); - - $this->addDebug("classes/reservationReport.inc", 'getReport', print_r($reportData,1)); - - return $reportData; - } - - - /** - * Format a number as money - * - * @param $value Value to format - * @param $option Options that control output - * NOPREFIX stops the "$" prefix - * - * @return none - * @access public - */ - public function money($value, $option = "") - { - - if ($option == "NOPREFIX") - $prefix = ""; - else - $prefix = "$"; - - // Do value sanity check - - if (!is_numeric($value)) - return ($prefix."0.00"); - - return ($prefix.number_format($value, 2, ".", ",")); - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/reservations.php b/legacy/models/admin/classes/reservations.php deleted file mode 100755 index 80f5525..0000000 --- a/legacy/models/admin/classes/reservations.php +++ /dev/null @@ -1,103 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/reservations.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataReservations.php'; - -/** - * EventManagementAdminReservations class - * - * Event Management and Reservations System - Admin Code - Reservations section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/reservations.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminReservations extends EventManagementDataReservations -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Reservations Stats - * - * @return object containing array as sub-objects - */ - function getReservationsStats() - { - $resStats = array( - 'all' => $this->getStats(), - 'event' => 0, - 'member' => 0, - 'accom' => 0, - 'team' => 0 - ); - - // Get stats for selected event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - $resStats['event'] = $this->getStats("conv = $eventID"); - } - - // Get stats for selected member - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - $resStats['member'] = $this->getStats("member = $memberID"); - } - - // Get stats for selected accommodation - if (($accomID = $_SESSION[GLM_EVENT_SESSION]['Accom'])) { - $resStats['accom'] = $this->getStats("accommodation = $accomID"); - } - - // Get stats for selected team - if (($teamID = $_SESSION[GLM_EVENT_SESSION]['Team'])) { - $resStats['event'] = $this->getStats("team = $teamID"); - } - - // var_dump($resStats); - return $resStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/roomBlockReport.php b/legacy/models/admin/classes/roomBlockReport.php deleted file mode 100755 index 174a2ff..0000000 --- a/legacy/models/admin/classes/roomBlockReport.php +++ /dev/null @@ -1,240 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/roomBlockReporteport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/Reports/dataRoomBlockReport.php'; - -/** - * EventManagementAdminEvents class - * - * Event Management and Reservations System - Admin Code - Reservation Report section - * - * PHP version 5 - * - * @category Event Management Admin Events - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminRoomBlockReport extends EventManagementDataRoomBlockReport -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - function __construct($dbh, $config) - { - parent::__construct($dbh, $config); - } - - /** - * Get Report Request Form - * - * @return object containing array as sub-objects - */ - function getForm() - { - - $reportData = array( - 'status' => true, - 'reason' => array(), - 'form' => array() - ); - - $reportData['form'] = $this->newControls(); - - $this->addDebug("classes/roomBlockReport.inc", 'getForm()', print_r($reportData,1)); - - return $reportData; - } - - /** - * Process Report - * - * @return object containing array as sub-objects - */ - function getReport($setEvent = false, $setState = false) - { - - $reportData = array( - 'status' => true, - 'reason' => array(), - 'report' => array() - ); - - // If no specific event and state rep is requested, then process input for selections - if ($setState == false) { - - /* - * Try to process report form request - */ - $request = $this->processInputData(); - if (!$request['status']) { - $reportData['status'] = false; - - if ($request['fieldFail']['event_name']) { - $reportData['reason'][] = 'An event was not selected'; - } - - if ($request['fieldFail']['output_type']) { - $reportData['reason'][] = 'An output type was not selected'; - } - - } - - /* - * Get report data - */ - $r = $request['fieldData']; - $event = $r['event_name']['in']; - $state = ($r['state_rep']['in'] != '0' ? $r['state_rep']['in'] : false); - $team = ($r['team_code']['in'] != '0' ? $r['team_code']['in'] : false); - $property = ($r['prop_name']['in'] != '0' ? $r['prop_name']['in'] : false); - $reportData['report']['doingProperties'] = $r['property_section']['value']; - $reportData['report']['doingAssigned'] = $r['assigned_section']['value']; - $reportData['report']['doingOptionAssigned'] = $r['option_assigned']['value']; - $reportData['output'] = $r['output_type']['value']; - - } else { - - // There's been a specific request - $event = $setEvent; - $state = $setState; - - $team = false; - $property = false; - $reportData['report']['doingProperties'] = true; - $reportData['report']['doingAssigned'] = true; - $reportData['report']['doingOptionAssigned'] = false; - $reportData['output'] = 'html'; - - } - - // If the request is valid - Produce the report - if ($reportData['status']) { - - // Get Event data - $sql = "SELECT * FROM eventmgt.event WHERE id = $event;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['event'] = $eventData; - - // Get State data - $reportData['report']['state'] = false; - if ($state) { - $sql = "SELECT * FROM eventmgt.state_rep WHERE id = $state;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $stateData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['state'] = $stateData; - } - - // Get Team data - $reportData['report']['team'] = false; - if ($team) { - $sql = "SELECT * FROM eventmgt.team WHERE id = $team;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $teamData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['team'] = $teamData; - } - - // Get Property data - $reportData['report']['property'] = false; - if ($property) { - $sql = "SELECT * FROM eventmgt.member WHERE id = $property;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $propertyData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['property'] = $propertyData; - } - - // Get Event Room Blocks - - require 'blocks.php'; - $Blocks = new EventManagementAdminBlocks($this->dbh, $this->config); - // Get room block list sorted and in summary mode (see function for explanation) - $blocksList = $Blocks->getRoomBlocks($event, true, true, $state, $team, $property); - $reportData['report']['roomBlocks'] = $blocksList; - - // Check for results - if (!is_array($blocksList) || count($blocksList) == 0) { - $reportData['status'] = false; - $reportData['reason'][] = 'No data was returned for this report.'; - } - - } - - $this->addDebug("classes/roomBlockReport.inc", 'getReport()', print_r($reportData,1)); - - return $reportData; - } - - - /** - * Format a number as money - * - * @param $value Value to format - * @param $option Options that control output - * NOPREFIX stops the "$" prefix - * - * @return none - * @access public - */ - public function money($value, $option = "") - { - - if ($option == "NOPREFIX") - $prefix = ""; - else - $prefix = "$"; - - // Do value sanity check - - if (!is_numeric($value)) - return ($prefix."0.00"); - - return ($prefix.number_format($value, 2, ".", ",")); - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/roomRequestReport.php b/legacy/models/admin/classes/roomRequestReport.php deleted file mode 100755 index 2bdb02c..0000000 --- a/legacy/models/admin/classes/roomRequestReport.php +++ /dev/null @@ -1,383 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/roomRequestReporteport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/Reports/dataRoomRequestReport.php'; - -/** - * EventManagementAdminEvents class - * - * Event Management and Reservations System - Admin Code - Room Request Report section - * - * PHP version 5 - * - * @category Event Management Admin Events - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/events.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminRoomRequestReport extends EventManagementDataRoomRequestReport -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - function __construct($dbh, $config) - { - parent::__construct($dbh, $config); - } - - /** - * Get Report Request Form - * - * @return object containing array as sub-objects - */ - function getForm() - { - - $reportData = array( - 'status' => true, - 'reason' => array(), - 'form' => array() - ); - - $reportData['form'] = $this->newControls(); - - $this->addDebug("classes/roomRequestReport.inc", 'getForm()', print_r($reportData,1)); - - return $reportData; - } - - /** - * Process Report - * - * @return object containing array as sub-objects - */ - function getReport($setEvent = false) - { - - $reportData = array( - 'status' => true, - 'output' => false, - 'reason' => array(), - 'report' => array() - ); - - /* - * Try to process report form request - */ - $request = $this->processInputData(); - if (!$request['status']) { - $reportData['status'] = false; - - if ($request['fieldFail']['event_name']) { - $reportData['reason'][] = 'An event was not selected'; - } - - if ($request['fieldFail']['output_type']) { - $reportData['reason'][] = 'An output type was not selected'; - } - - } - $r = $request['fieldData']; - - // Check for specified event - if ($setEvent) { - $event = $setEvent; - } else { - $event = $request['fieldData']['event_name']['in']; - } - - /* - * Get report data - */ - $state = ($r['state_rep']['in'] != '0' ? $r['state_rep']['in'] : false); - $team = ($r['team_code']['in'] != '0' ? $r['team_code']['in'] : false); - $property = ($r['prop_name']['in'] != '0' ? $r['prop_name']['in'] : false); - $reportData['report']['doingAvailable'] = false; - $reportData['report']['doingPending'] = $r['pending_select']['value']; - $reportData['report']['doingConfirmed'] = $r['confirmed_select']['value']; - $reportData['report']['doingDeclined'] = $r['declined_select']['value']; - $where = ''; - - // If an event is selected, get that data - $reportData['report']['event'] = false; - if ($event > 0) { - - // Get Event data - $sql = "SELECT * FROM eventmgt.event WHERE id = $event;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $eventData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['event'] = $eventData; - - $where = "conv = $event"; - - } else { - // No event selected, so show for all events that haven't ended yet - $where = ($where!=''?' AND ':'')."T.conv_end > 'now'"; - } - - // If a State Rep is selected filter by that - if ($state) { - - // Build query where clause to filter for any requested state - $where .= ($where!=''?' AND ':'')." T.team_id IN (SELECT team.id FROM eventmgt.team WHERE state = $state)"; - - // Also get state information - $sql = "SELECT * FROM eventmgt.state_rep WHERE id = $state;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $stateData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['state'] = $stateData; - - } - - // If a team has been selected, filter by that. - if ($team) { - - $where .= ($where!=''?' AND ':'')." T.team_id = $team"; - - // Also get team information - $sql = "SELECT * FROM eventmgt.team WHERE id = $team;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $teamData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['team'] = $teamData; - - // Also check if availability requested. - $reportData['report']['doingAvailable'] = $r['available_select']['value']; - // If doingAvailable, override Pending, Confirmed, Declined - if ($reportData['report']['doingAvailable']) { - $reportData['report']['doingPending'] = true; - $reportData['report']['doingConfirmed'] = true; - $reportData['report']['doingDeclined'] = false; - } - - } - - // If a property has been selected, filter by that. - if ($property) { - - $where .= ($where!=''?' AND ':'')." T.member = $property"; - - // Also get team information - $sql = "SELECT * FROM eventmgt.member WHERE id = $property;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $propertyData = $stmt->fetch(PDO::FETCH_ASSOC); - $reportData['report']['property'] = $propertyData; - } - - // Get Event Reservations - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataReservations.php'; - $Reservations = new EventManagementDataReservations($this->dbh, $this->config); - $reservationsList = $Reservations->getList($where); - - // Build totals - $numb_res = 0; - $total_hotel = 0; - $total_taxes = 0; - $total_fees = 0; - $grand_total = 0; - $grand_total_rooms = 0; - - // Reorganize reservations data as room report and collect totals - if (is_array($reservationsList) && count($reservationsList) > 0) { - - reset($reservationsList); - $roomRequests = array(); - while (list($k, $v) = each($reservationsList)) { - - // Check if request matches filters - $show = false; - if ($reportData['report']['doingPending'] && !$v['confirmed']['value'] && !$v['declined']['value']) { - $show = true; - } - if ($reportData['report']['doingConfirmed'] && $v['confirmed']['value']) { - $show = true; - } - if ($reportData['report']['doingDeclined'] && $v['declined']['value']) { - $show = true; - } - - if ($show) { - - // Extract detail in case we need it - $v['detail'] = unserialize($v['res_detail']); - - // Put fees into results - NEED TO FIX AND GET FROM DATABASE - $fees = 25; - $reportData['report']['reservations'][$k]['fees'] = '$25.00'; - - // Add to totals - $numb_res++; - $total_hotel += $v['hotel_price_numb']; - $total_taxes += $v['taxes_numb']; - $total_fees += $fees; - $grand_total += $v['grand_total_numb']; - - // If property hasn't been created yet, do it now - // $propId = $v['detail']['propId']; - $propId = $v['member_id']; - if (!isset($roomRequests[$propId])) { - $roomRequests[$propId] = array( - 'propName' => $v['detail']['propName'], - 'propCity' => $v['detail']['propCity'], - 'propState' => $v['detail']['propState'], - 'propPhone' => $v['detail']['propPhone'], - 'propRoomsTotal' => 0, - 'accoms' => array() - ); - } - - // For each accommodation with this reservation - if ($v['detail']['propAccom']) { - foreach ($v['detail']['propAccom'] as $accom) { - - // If accommodation hasn't been created yet, do it now - if (!isset($roomRequests[$propId]['accoms'][$accom['accomId']])) { - $roomRequests[$propId]['accoms'][$accom['accomId']] = array( - 'accomTitle' => $accom['accomTitle'], - 'accomRoomsTotal' => 0, - 'roomRequests' => array() - ); - - // Get assigned and available for this accommodation/team (from room_block_seg). - $sql = "SELECT B.block_name, S.id, S.allocated, S.available - FROM eventmgt.room_block B, eventmgt.room_block_seg S, eventmgt.team T - WHERE B.state_rep = ".$v['state_rep']." - AND T.name = '".$v['org']."' - AND B.team = T.id - AND S.block = B.id - AND S.accommodation = ".$accom['accomId'].";"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $blockData = $stmt->fetch(PDO::FETCH_ASSOC); - - $roomRequests[$propId]['accoms'][$accom['accomId']]['blockName'] = $blockData['block_name']; - $roomRequests[$propId]['accoms'][$accom['accomId']]['blockAssigned'] = $blockData['allocated']; - $roomRequests[$propId]['accoms'][$accom['accomId']]['blockAvailable'] = $blockData['available']; - $roomRequests[$propId]['accoms'][$accom['accomId']]['blockAvailableActual'] = $blockData['allocated'];; - } - - // Add this accommodation request - $grand_total_rooms += $accom['accomQuant']; - $roomRequests[$propId]['propRoomsTotal'] += $accom['accomQuant']; - $roomRequests[$propId]['accoms'][$accom['accomId']]['accomRoomsTotal'] += $accom['accomQuant']; - $roomRequests[$propId]['accoms'][$accom['accomId']]['blockAvailableActual'] -= $accom['accomQuant']; - $roomRequests[$propId]['accoms'][$accom['accomId']]['roomRequests'][] = array( - 'org' => trim($v['org']), - 'fname' => $v['fname'], - 'lname' => $v['lname'], - 'city' => $v['city'], - 'state' => $v['state'], - 'phone' => $v['phone'], - 'dateRequested' => $v['date_entered']['date'], - 'confirmed' => $v['confirmed']['value'], - 'dateConfirmed' => $v['date_confirmed']['date'], - 'confirmedBy' => $v['conf_by'], - 'declined' => $v['declined']['value'], - 'accomQuant' => $accom['accomQuant'], - 'arriveDate' => $accom['accomArrive'], - 'departDate' => $accom['accomDepart'], - 'nights' => $accom['accom_nights'] - ); - - } // each accom - } else { -// echo "Problem retrieving reservation detail for: ".$v['lname'].", ".$v['fname'].", res # $propId
    "; - } - } // if show - - } // each reservation - -//echo "
    ".print_r($roomRequests,1)."
    "; - - } -//echo "
    ".print_r($reservationsList,1)."
    "; - - $reportData['report']['roomRequests'] = $roomRequests; - $reportData['output'] = $r['output_type']['value']; - - $reportData['report']['totals'] = array( - 'numb_reservations' => $numb_res, - 'hotel' => $this->money($total_hotel), - 'taxes' => $this->money($total_taxes), - 'fees' => $this->money($total_fees), - 'grand_total' => $this->money($grand_total), - 'grand_total_rooms' => $grand_total_rooms - ); - - $this->addDebug("classes/roomRequestReport.inc", 'getReport()', print_r($reportData,1)); - - return $reportData; - } - - - /** - * Format a number as money - * - * @param $value Value to format - * @param $option Options that control output - * NOPREFIX stops the "$" prefix - * - * @return none - * @access public - */ - public function money($value, $option = "") - { - - if ($option == "NOPREFIX") - $prefix = ""; - else - $prefix = "$"; - - // Do value sanity check - - if (!is_numeric($value)) - return ($prefix."0.00"); - - return ($prefix.number_format($value, 2, ".", ",")); - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/rooms.php b/legacy/models/admin/classes/rooms.php deleted file mode 100755 index cfd0427..0000000 --- a/legacy/models/admin/classes/rooms.php +++ /dev/null @@ -1,68 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/rooms.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataRooms.php'; - -/** - * EventManagementAdminRooms class - * - * Event Management and Reservations System - Admin Code - Accommodations section - * - * PHP version 5 - * - * @category Event Management Admin Accommodations - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/rooms.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminRooms extends EventManagementDataRooms -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - /** - * Get Rooms Stats - * - * @return object containing array as sub-objects - */ - function getRoomsStats() - { - return false; - } - - -} - -?> - diff --git a/legacy/models/admin/classes/sections.php b/legacy/models/admin/classes/sections.php deleted file mode 100755 index bf3acc5..0000000 --- a/legacy/models/admin/classes/sections.php +++ /dev/null @@ -1,81 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/sections.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSections.php'; - -/** - * EventManagementAdminContacts class - * - * Event Management and Reservations System - Admin Code - Contacts section - * - * PHP version 5 - * - * @category Event Management Admin Sections - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/sections.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminSections extends EventManagementDataSections -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - /** - * Get Sectionss Stats - * - * @return object containing array as sub-objects - */ - function getMemberSectionsStats($memberID = false) - { - // Get member ID from session - if available get stats for member - if ($memberID || ($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - return $this->getStats("member = $memberID"); - } - return 0; - } - function getSectionsStats() - { - $sectionsStats = array( - 'all' => $this->getStats(), - 'member' => $this->getMemberSectionsStats() - ); - - return $sectionsStats; - } - - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/sold.php b/legacy/models/admin/classes/sold.php deleted file mode 100755 index 9fbdb71..0000000 --- a/legacy/models/admin/classes/sold.php +++ /dev/null @@ -1,58 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/sold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSold.php'; - -/** - * EventManagementAdminSold class - * - * Event Management and Reservations System - Admin Code - Sold Tickets - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/sold.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementAdminSold extends EventManagementDataSold -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/states.php b/legacy/models/admin/classes/states.php deleted file mode 100755 index 1952d46..0000000 --- a/legacy/models/admin/classes/states.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/states.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataStates.php'; - -/** - * EventManagementAdminStates class - * - * Event Management and Reservations System - Admin Code - States section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/states.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminStates extends EventManagementDataStates -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get State Reps Stats - * - * @return object containing array as sub-objects - */ - function getStatesStats() - { - $statesStats = array( - 'all' => $this->getStats(), - 'event' => 0 - ); - - // Get event ID from session - if available get stats for teams listed with this event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - $statesStats['event'] = $this->getStats(" - conv = $eventID - "); - } - - return $statesStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/teams.php b/legacy/models/admin/classes/teams.php deleted file mode 100755 index 6c988f5..0000000 --- a/legacy/models/admin/classes/teams.php +++ /dev/null @@ -1,98 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/teams.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTeams.php'; - -/** - * EventManagementAdminTeams class - * - * Event Management and Reservations System - Admin Code - Teams section - * - * PHP version 5 - * - * @category Event Management Admin Members - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/teams.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminTeams extends EventManagementDataTeams -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - public $data; - - /** - * File/Image server adapter - * @var $isa - * @var $imageServer - * @access public - */ - - - /** - * Get Members Stats - * - * @return object containing array as sub-objects - */ - function getTeamsStats() - { - $teamsStats = array( - 'all' => $this->getStats(), - 'member' => 0, - 'event' => 0 - ); - - // Get member ID from session - if available get stats for teams with booking for this member - if (($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - $teamsStats['member'] = $this->getStats(" - id in ( - SELECT team - FROM eventmgt.team_property - WHERE property = $memberID - ) - "); - } - - // Get event ID from session - if available get stats for teams listed with this event - if (($eventID = $_SESSION[GLM_EVENT_SESSION]['Event'])) { - $teamsStats['event'] = $this->getStats(" - conv = $eventID - "); - } - - return $teamsStats; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/ticketInventory.php b/legacy/models/admin/classes/ticketInventory.php deleted file mode 100755 index 20ca4df..0000000 --- a/legacy/models/admin/classes/ticketInventory.php +++ /dev/null @@ -1,231 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/ticketInventory.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketInventory.php'; - -/** - * EventManagementAdminContacts class - * - * Event Management and Reservations System - Admin Code - Contacts ticket - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/tickets.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementAdminTicketInventory extends EventManagementDataTicketInventory -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - - /** - * Get Tickets Stats - * - * @return object containing array as sub-objects - */ - function getTicketTicketInventoryStats($ticketID = false) - { - if ($ticketID == false) { - $ticketID = $_SESSION[GLM_EVENT_SESSION]['Ticket']; - } - if (($ticketID)) { - return $this->getStats("ticket = $ticketID"); - } - return 0; - } - function getPerformanceTicketInventoryStats($performanceID = false) - { - if ($performanceID == false) { - $performanceID = $_SESSION[GLM_EVENT_SESSION]['Performance']; - } - if (($performanceID)) { - return $this->getStats("ticket in (SELECT id FROM eventmgt.ticket WHERE performance = $performanceID)"); - } - return 0; - } - function getMemberTicketInventoryStats($memberID = false) - { - - if ($memberID == false) { - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - } - // Get member ID from session - if available get stats for member - if (($memberID)) { - return $this->getStats("member = $memberID"); - } - return 0; - } - function getMemberTicketInventorySalesStats($memberID = false, $where = '') - { - if ($memberID == false) { - $memberID = $_SESSION[GLM_EVENT_SESSION]['Member']; - } - // Get member ID from session - if available get stats for member - if (($memberID)) { - $sql = " - SELECT - ( - SELECT COALESCE(SUM(I.quant),0) - FROM eventmgt.ticket_inventory I - WHERE I.ticket IN ( SELECT id FROM eventmgt.ticket WHERE member = $memberID ) - $where - ) AS totalQuant, - ( - SELECT COALESCE(SUM(I.sold),0) - FROM eventmgt.ticket_inventory I - WHERE I.ticket IN ( SELECT id FROM eventmgt.ticket WHERE member = $memberID ) - $where - ) AS totalSold, - ( - SELECT COALESCE(SUM(I.sold * T.price),0) - FROM eventmgt.ticket_inventory I, eventmgt.ticket T - WHERE I.ticket IN ( SELECT id FROM eventmgt.ticket WHERE member = $memberID ) - $where - AND T.id = I.ticket - ) AS totalPrice - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $s = $stmt->fetch(PDO::FETCH_ASSOC); - - return $s; - } - return 0; - } - function getTicketInventoryStats() - { - $ticketInventoryStats = array( - 'all' => $this->getStats(), - 'member' => $this->getMemberTicketInventoryStats(), - 'performance' => $this->getPerformanceTicketInventoryStats(), - 'ticket' => $this->getTicketTicketInventoryStats(), - ); - - return $ticketsInventoryStats; - } - - /** - * Generate Default Ticket Inventory - * - * @return object containing array as sub-objects - */ - function generateDefaultTicketInventory($ticketID = false) - { - - // If no ticket ID supplied, check session - if (!$ticketID) { - $ticketID = ($_SESSION[GLM_EVENT_SESSION]['Ticket'] - 0); - } - - // If we have a ticket ID - if ($ticketID) { - - // Get ticket information - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/tickets.php'; - $Tickets = new EventManagementAdminTickets($this->dbh, $this->config); - $ticketDetail = $Tickets->getTicketDetail(); - if (!$ticketDetail) { - return false; - } - - // Get Performance Information - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $ticketDetail['performance_id']; - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($this->dbh, $this->config); - $performanceDetail = $Performances->getPerformanceDetail(); - if (!$performanceDetail) { - return false; - } - - // Check for existing ticket inventory - Don't generate default inventory if there's some already there - $inventoryStats = $this->getTicketTicketInventoryStats(); - if ($inventoryStats > 0) { - return false; - } - - // Collect needed data - $ticket = $ticketDetail['id']; - $member = $ticketDetail['member']; - $quant = $ticketDetail['quant']; - $time = 'null'; - if ($ticketDetail['time_specific']['value']) { - $time = "'".trim($ticketDetail['ticket_time']['time'])."'"; - } - $start = $ticketDetail['start_date']['timestamp']; - $end = $ticketDetail['end_date']['timestamp']; - - // If not date specific, create a single inventory item with a null date - if (!$ticketDetail['date_specific']['value']) { - - $sql = "INSERT INTO eventmgt.ticket_inventory - (ticket, member, quant, available, ticket_date, ticket_time, sold, active) - values - ($ticket, $member, $quant, $quant, null, $time, 0, true);\n"; - - } else { - - // For each day of the performance - $sql = ''; - for ($date = $start; $date <= $end; $date = strtotime(date('m/d/Y', $date).' +1 day')) { - $dateText = date('m/d/Y', $date); - - // Check day of week settings and create inventory accordingly - $dow = date('w', $date); - if ($ticketDetail['days_of_week']['bitmap'][$dow]['default']) { - $sql .= "INSERT INTO eventmgt.ticket_inventory - (ticket, member, quant, available, ticket_date, ticket_time, sold, active) - values - ($ticket, $member, $quant, $quant, '$dateText', $time, 0, true);\n"; - } - - } - } - - if ($sql != '') { - $this->dbh->exec($sql); - } - - return true; - } - - return false; - - } -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/tickets.php b/legacy/models/admin/classes/tickets.php deleted file mode 100755 index 7cc2380..0000000 --- a/legacy/models/admin/classes/tickets.php +++ /dev/null @@ -1,82 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/tickets.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; - -/** - * EventManagementAdminContacts class - * - * Event Management and Reservations System - Admin Code - Contacts ticket - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/tickets.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementAdminTickets extends EventManagementDataTickets -{ - /** - * Configuration information object - * @var $ini - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $dbh - * @access public - */ - public $data; - - - /** - * Get Tickets Stats - * - * @return object containing array as sub-objects - */ - function getMemberTicketsStats($memberID = false) - { - // Get member ID from session - if available get stats for member - if ($memberID || ($memberID = $_SESSION[GLM_EVENT_SESSION]['Member'])) { - return $this->getStats("member = $memberID"); - } - return 0; - } - function getTicketsStats() - { - $ticketsStats = array( - 'all' => $this->getStats(), - 'member' => $this->getMemberTicketsStats() - ); - - return $ticketsStats; - } - - -} - -?> \ No newline at end of file diff --git a/legacy/models/admin/classes/voucherCoupons.php b/legacy/models/admin/classes/voucherCoupons.php deleted file mode 100755 index 727b0d6..0000000 --- a/legacy/models/admin/classes/voucherCoupons.php +++ /dev/null @@ -1,68 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/voucherCoupons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataVoucherCoupons.php'; - -/** - * EventManagementAdminVoucherCoupons class - * - * Event Management and Reservations System - Admin Code - Voucher Coupons section - * - * PHP version 5 - * - * @category Event Management Admin Voucher Coupons - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/voucherCoupons.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ -class EventManagementAdminVoucherCoupons extends EventManagementDataVoucherCoupons -{ - /** - * Configuration information object - * @var $config - * @access public - */ - public $config; - /** - * Database Object - * @var $dbh - * @access public - */ - public $dbh; - /** - * Data Definitions Object - * @var $data - * @access public - */ - public $data; - - /** - * Get Voucher Coupons Stats - * - * @return object containing array as sub-objects - */ - function getVoucherCouponsStats() - { - return $this->getStats(); - - return 0; - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/front/actions/Debug/start.inc b/legacy/models/front/actions/Debug/start.inc deleted file mode 100755 index d07c4fc..0000000 --- a/legacy/models/front/actions/Debug/start.inc +++ /dev/null @@ -1,19 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->page->debugStartupTime = date('m/d/Y H:i:s'); -$this->templateFile = 'Debug/index.html'; - -?> - diff --git a/legacy/models/front/actions/Debug/update.inc b/legacy/models/front/actions/Debug/update.inc deleted file mode 100755 index 6a7e9e6..0000000 --- a/legacy/models/front/actions/Debug/update.inc +++ /dev/null @@ -1,29 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -$this->page->debugUpdateTime = date('m/d/Y H:i:s'); - -// If there's nothing to send, then don't -if (!file_exists(DEBUG_DATA_FILENAME)) { - exit; -} - -// Otherwise, send the current debug data -$this->page->debugData = file_get_contents(DEBUG_DATA_FILENAME); -unlink(DEBUG_DATA_FILENAME); - -$this->templateFile = 'Debug/index.html'; - -?> - diff --git a/legacy/models/front/actions/Index/index.inc b/legacy/models/front/actions/Index/index.inc deleted file mode 100755 index bbd56e5..0000000 --- a/legacy/models/front/actions/Index/index.inc +++ /dev/null @@ -1,21 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: event.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Reset Session -$this->startSession(true); - -$this->templateFile = "index.html"; - -?> - diff --git a/legacy/models/front/actions/Shop/PayPal.inc b/legacy/models/front/actions/Shop/PayPal.inc deleted file mode 100755 index a571bef..0000000 --- a/legacy/models/front/actions/Shop/PayPal.inc +++ /dev/null @@ -1,110 +0,0 @@ -dbh, $this->config); -$cart = $Support->checkCart(); -$this->addDebug("Shop/checkoutSubmit.inc", 'Array: $cart', print_r($cart['cartData'],1)); - -// Get selected cart data -$memberID = ($_REQUEST['memberID']-0); -$cartEntry = $cart['cartData'][$memberID]; - -// If we can't find the correct cart entry -if (!is_array($cartEntry)) { - - $this->templateFile = "Shop/PayPalFail.html"; - - // We have the correct cart entry -} else { - - // Prepare for purchase authorization request with PayPal REST API - $account = array( - 'clientID' => $cartEntry['paypal_client_id'], - 'secret' => $cartEntry['paypal_secret'], - 'test' => $cartEntry['paypal_mode']['value'], - 'returnURL' => $this->page->baseURL."?Action=Shop_PayPalApproved&memberID=$memberID", - 'cancelURL' => $this->page->baseURL."?Action=Shop_PayPalCanceled&memberID=$memberID", - ); - $payment = array( - 'name' => $cartEntry['name'], - 'charge' => $cartEntry['totalPrice_numb'], - 'invoice' => '', - 'description' => $config->term->event->cap.' Tickets', - 'items' => array( - ) - ); - $contact = array(); - - // Build items array from cart data - $items = array(); - // For each date of tickets - foreach ($cartEntry['dates'] as $d) { - - // For each Performance - foreach ($d['performances'] as $p) { - - // For each Section - foreach ($p['sections'] as $s) { - - // For each ticket - foreach ($s['tickets'] as $t) { - - // Add this cart selection - $payment['items'][] = array( - 'quantity' => $t['selected'], - 'name' => $p['name'].", ".$d['date'].", ".$s['name'].", ".$t['name'], - 'price' => $t['price_numb'], - 'sku' => $t['invID'] - ); - - } - - } - - } - - } - - - // Create the PayPal object (note no previous access object) - $PayPal = new PayPalPaymentGateway($account, false, false); - - // Was there an error? - if (!$PayPal->status) { - echo "Received an error: ".$PayPal->error; - exit; - } - - // Try to enter Payment - $PayPal->processPayment($payment, $contact); - - // Was there an error? - if (!$PayPal->status) { - echo "Received an error: ".$PayPal->error; - exit; - } - - // Store access information - $_SESSION[GLM_EVENT_MGT_FRONT]['PayPal'][$memberID] = array( - 'account' => $account, - 'access' => $PayPal->access, - 'trans' => $PayPal->trans, - 'cart' => $cartEntry - ); - - // Show user link to PayPal for them to approve payment - // Note that uses a target to create a new window/tab - // Use browser redirect 302 to send user to PayPal. - // This is proper way to do so according to the API documentation. - header('Location: '.$PayPal->trans->urls->approval_url->href); - exit; - -} - -?> \ No newline at end of file diff --git a/legacy/models/front/actions/Shop/PayPalApproved.inc b/legacy/models/front/actions/Shop/PayPalApproved.inc deleted file mode 100755 index 866fb8e..0000000 --- a/legacy/models/front/actions/Shop/PayPalApproved.inc +++ /dev/null @@ -1,96 +0,0 @@ -dbh, $this->config); -$cart = $Support->checkCart(); -$this->addDebug("Shop/checkoutSubmit.inc", 'Array: $cart', print_r($cart['cartData'],1)); - -// Get selected cart data -$memberID = ($_REQUEST['memberID']-0); -$cartEntry = $cart['cartData'][$memberID]; - -// If we can't find the correct cart entry -if (!is_array($cartEntry)) { - - $this->templateFile = "Shop/PayPalFail.html"; - -// We have the correct cart entry -} else { - - // Prepare to execute payment with PayPal REST API - $account = array( - 'clientID' => $cartEntry['gateway_par1'], - 'secret' => $cartEntry['gateway_par2'], - 'test' => $cartEntry['gateway_par3']['value'], - 'returnURL' => $this->page->baseURL."?Action=Shop_PayPalApproved&memberID=$memberID", - 'cancelURL' => $this->page->baseURL."?Action=Shop_PayPalCanceled&memberID=$memberID", - ); - - // Save Payer ID - $_SESSION[GLM_EVENT_MGT_FRONT]['PayPal'][$memberID]['payerID'] = $_REQUEST['PayerID']; // NEED TO FILTER THIS FOR PRODUCTION - - // Create PayPal object with existing access object from the session - $PayPal = new PayPalPaymentGateway( - $_SESSION[GLM_EVENT_MGT_FRONT]['PayPal'][$memberID]['account'], - $_SESSION[GLM_EVENT_MGT_FRONT]['PayPal'][$memberID]['access'], - $_SESSION[GLM_EVENT_MGT_FRONT]['PayPal'][$memberID]['trans'] - ); - - // Execute the PayPal payment - $payerID = $_REQUEST['PayerID']; - $r = $PayPal->executePayment($payerID); - - // Check if payment executed correctly - if ($r['status']) { - - $payment = array( - 'id' => $memberID, - 'status' => true, - 'type' => 'pp', - 'statusText' => $r['statusText'], - 'authCode' => '', - 'description' => $r['description'], - 'newApproval' => false, - 'spec_req' => '', - 'approved' => true, - 'cctype' => array('name' => 'PayPal'), - 'ccname' => array('value' => $r['payerName']), - 'ccexp' => array('value' => ''), - 'ccnumb' => '', - 'orderID' => '' - ); -var_dump($payment); - - // Store order - $cart = $_SESSION[GLM_EVENT_MGT_FRONT]['PayPal'][$memberID]['cart']; - $contact = $_SESSION[GLM_EVENT_MGT_FRONT]['ContactInput']; - - require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/checkoutSupport.php'; - $CheckoutSupport = new EventManagementFrontCheckoutSupport($this->dbh, $this->config, $Support); -var_dump($contact); - $orderID = $CheckoutSupport->storePurchase($cart, $contact, $payment); -echo "Order ID = $orderID

    "; - - // Need to send E-Mail to customer - - - - $this->templateFile = "Shop/PayPalApproved.html"; - - - // Otherwise the payment didn't execute correctly - } else { - - $this->templateFile = "Shop/PayPalFail.html"; - - } - -} - -?> \ No newline at end of file diff --git a/legacy/models/front/actions/Shop/additionalInfo.inc b/legacy/models/front/actions/Shop/additionalInfo.inc deleted file mode 100755 index 348b5b5..0000000 --- a/legacy/models/front/actions/Shop/additionalInfo.inc +++ /dev/null @@ -1,177 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: cart.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// If this is a home page ticket selection, save default member -if (isset($_REQUEST['locationSelect'])) { - $_SESSION['GLM_EVENT_MGT_FRONT']['Member'] = ($_REQUEST['locationSelect']-0); -} - -// Load the front-end support class -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -// If cart sticky is enables -if ($this->config->option->ticket_selection->show_cart_sticky_items) { - - // Get list of cart sticky items - Items that always display in the cart even if there's no quant selected - $cartSticky = $Support->getCartStickyInventory(); - - // Default all current cart entries to sticky = false (will be updated if they're sticky) - while (list($k, $v) = each($cartSticky)) { - $cartSticky[$k]['sticky'] = false; - } - -} - -// Check if there's any promo codes -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPromos.php'; -$Promos = new EventManagementDataPromos($this->dbh, $this->config); -$promoList = $Promos->getList(); -$this->page->havePromoCodes = false; -if (is_array($promoList) && count($promoList) > 0) { - $this->page->havePromoCodes = true; -} - -// Check for Promo Code Selection -if (isset($_REQUEST['cart']) && $_REQUEST['cart'] == 'promo_code') { - $promo_code = filter_input(INPUT_GET, 'promo_code', FILTER_SANITIZE_STRING); - $_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode'] = $promo_code; - -} elseif (isset($_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode'])) { - $promo_code = $_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode']; -} - -// Check if we're getting a selection of assignment to a member/location -if ($_REQUEST['cart'] == 'update_assignment') { - - // If we don't have an assignment session array, start one - if (!isset($_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'])) { - $_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'] = array(); - } - - // Add/update this assignment - $_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'][($_REQUEST['member_assigned']-0)] = ($_REQUEST['assigned_to']-0); - - // Also check if we need to handle entrance assignment - unset($_SESSION['GLM_EVENT_MGT_FRONT']['AssignmentEntrance'][($_REQUEST['member_assigned']-0)]); - if ($this->config->option->ticket_selection->select_entrance_on_consignment && - isset($_REQUEST['entrance_assigned']) && ($_REQUEST['entrance_assigned']-0) > 0 ) { - // Add/update entrance assignment - $_SESSION['GLM_EVENT_MGT_FRONT']['AssignmentEntrance'][($_REQUEST['member_assigned']-0)] = ($_REQUEST['entrance_assigned']-0); - } - -} - -// Check if we're getting selection of a likely departure date -if ($_REQUEST['cart'] == 'update_likelyDate') { - - // If we don't have a likely date array, start one - if (!isset($_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'])) { - $_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'] = array(); - } - - // Validate likely date and store if it's sane - $likelyDate = date('m/d/Y', strtotime($_REQUEST['likely_date'])); - if ($likelyDate != '12/31/1969') { - $_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'][($_REQUEST['member']-0)] = $likelyDate; - } else { - $_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'][($_REQUEST['member']-0)] = ''; - } - -} - -// If cart sticky items is enabled and we have any cart sticky items -$haveCartStickyItems = false; -if ($this->config->option->ticket_selection->show_cart_sticky_items && $cartSticky) { - - $haveCartStickyItems = true; - - $this->addDebug("Shop/cart.inc", 'Array: $cartSticky', print_r($cartSticky,1)); - - // Make sure cart sticky inventory is in cart - foreach ($cartSticky as $c) { - - // Check if there's no cart entry for this cart sticky item - if (!isset($_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'][$c['id']])) { - - // Add to cart - $_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'][$c['id']] = array( - 'invenID' => $c['id'], - 'member' => $c['member'], - 'assigned' => false, - 'quant' => 0 - ); - } - - // Mark entry as Sticky - $_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'][$c['id']]['sticky'] = true; - - } - -} - -// Check if there's been anything added to the cart and get cart contents -$cart = $Support->checkCart(); - -// If we're already locked into checkout, go there -if ($cart['forceCheckoutPhase']) { - $this->reason[] = 'You have partially paid for your purchases. We have returned you to checkout to complete your purchase.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; -} - -// If there's no cart contents, make sure there's no cart array. -if (!$cart['cartHasContents']) { - $_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'] = false; -} - -// If we're doing cart promotions, get any performances with promote_on_cart set -if ($this->config->option->cart_promotions) { - $cartPromotions = $Support->getCartPromotions(); - if ($cartPromotions) { - $this->page->cartPromotions = $this->bindArrayToObject($cartPromotions); - } -} - -//var_dump($this->page->cartPromotions); - -// Check if we received a vertical scroll position -$vertScroll = 0; -if ($_REQUEST['vertScroll']) { - $vertScroll = ($_REQUEST['vertScroll']-0); -} -$this->page->vertScroll = $vertScroll; - -// Otherwise we're OK to continue showing the cart -$this->page->promoCode = $promo_code; -$this->page->blockCheckout = $cart['blockCheckout']; -$this->page->blockCheckoutNonAssignment = $cart['blockCheckoutNonAssignment']; -$this->page->haveCartStickyItems = $haveCartStickyItems; -$this->page->cartHasContents = $cart['cartHasContents']; -$this->page->cartHasOneVenueOnly = $cart['cartHasOneVenueOnly']; -$this->page->cart = $this->bindArrayToObject($cart['cartDataReorganized']); // Use reorganized cart -$this->page->totals = $this->bindArrayToObject($cart['totals']); -$this->reason = array_merge($this->reason, $cart['reason']); - -if ($cart['blockCheckoutNonAssignment']) { - $this->templateFile = "Shop/cart.html"; -} else { - $this->templateFile = "Shop/additionalInfo.html"; -} - -$this->addDebug("Shop/cart.inc", 'Array: $totals', print_r($cart['totals'],1)); -$this->addDebug("Shop/cart.inc", 'Array: $cart', print_r($rCart,1)); - -?> - diff --git a/legacy/models/front/actions/Shop/cart.inc b/legacy/models/front/actions/Shop/cart.inc deleted file mode 100644 index 1dc131b..0000000 --- a/legacy/models/front/actions/Shop/cart.inc +++ /dev/null @@ -1,202 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: cart.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// If this is a home page ticket selection, save default member -if (isset($_REQUEST['locationSelect'])) { - $_SESSION['GLM_EVENT_MGT_FRONT']['Member'] = ($_REQUEST['locationSelect']-0); -} - -// Load the front-end support class -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -// If cart sticky is enables -if ($this->config->option->ticket_selection->show_cart_sticky_items) { - - // Get list of cart sticky items - Items that always display in the cart even if there's no quant selected - $cartSticky = $Support->getCartStickyInventory(); - - // Default all current cart entries to sticky = false (will be updated if they're sticky) - while (list($k, $v) = each($cartSticky)) { - $cartSticky[$k]['sticky'] = false; - } - -} - -// Check if there's any promo codes -require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPromos.php'; -$Promos = new EventManagementDataPromos($this->dbh, $this->config); -$promoList = $Promos->getList(); -$this->page->havePromoCodes = false; -if (is_array($promoList) && count($promoList) > 0) { - $this->page->havePromoCodes = true; -} - -// Check for Promo Code Selection -if (isset($_REQUEST['cart']) && $_REQUEST['cart'] == 'promo_code') { - $promo_code = filter_input(INPUT_GET, 'promo_code', FILTER_SANITIZE_STRING); - $_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode'] = $promo_code; -} elseif (isset($_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode'])) { - $promo_code = $_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode']; -} - -// Check if we're getting a selection of assignment to a member/location -if ($_REQUEST['cart'] == 'update_assignment') { - - // If we don't have an assignment session array, start one - if (!isset($_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'])) { - $_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'] = array(); - } - - // Add/update this assignment - $_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'][($_REQUEST['member_assigned']-0)] = ($_REQUEST['assigned_to']-0); - - // Also check if we need to handle entrance assignment - unset($_SESSION['GLM_EVENT_MGT_FRONT']['AssignmentEntrance'][($_REQUEST['member_assigned']-0)]); - if ($this->config->option->ticket_selection->select_entrance_on_consignment && - isset($_REQUEST['entrance_assigned']) && ($_REQUEST['entrance_assigned']-0) > 0 ) { - // Add/update entrance assignment - $_SESSION['GLM_EVENT_MGT_FRONT']['AssignmentEntrance'][($_REQUEST['member_assigned']-0)] = ($_REQUEST['entrance_assigned']-0); - } - -} - -// Check if we're getting selection of a likely departure date -if ($_REQUEST['cart'] == 'update_likelyDate') { - - // If we don't have a likely date array, start one - if (!isset($_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'])) { - $_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'] = array(); - } - - // Validate likely date and store if it's sane - $likelyDate = date('m/d/Y', strtotime($_REQUEST['likely_date'])); - if ($likelyDate != '12/31/1969') { - $_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'][($_REQUEST['member']-0)] = $likelyDate; - } else { - $_SESSION['GLM_EVENT_MGT_FRONT']['LikelyDate'][($_REQUEST['member']-0)] = ''; - } - -} - -// If cart sticky items is enabled and we have any cart sticky items -$haveCartStickyItems = false; -if ($this->config->option->ticket_selection->show_cart_sticky_items && $cartSticky) { - - $haveCartStickyItems = true; - - $this->addDebug("Shop/cart.inc", 'Array: $cartSticky', print_r($cartSticky,1)); - - // Make sure cart sticky inventory is in cart - foreach ($cartSticky as $c) { - - // Check if there's no cart entry for this cart sticky item - if (!isset($_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'][$c['id']])) { - - // Add to cart - $_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'][$c['id']] = array( - 'invenID' => $c['id'], - 'member' => $c['member'], - 'assigned' => false, - 'quant' => 0 - ); - } - - // Mark entry as Sticky - $_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'][$c['id']]['sticky'] = true; - - } - -} - -// Check if there's been anything added to the cart and get cart contents -$cart = $Support->checkCart(); -; -// If we're already locked into checkout, go there -if ($cart['forceCheckoutPhase']) { - $this->reason[] = 'You have partially paid for your purchases. We have returned you to checkout to complete your purchase.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; -} - -// If there's no cart contents, make sure there's no cart array. -if (!$cart['cartHasContents'] || count($cart['cartDataReorganized']) == 0) { - $_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'] = false; - - $cart['cartHasContents'] = false; -// Otherwise check that we're not mixing no-payment location with other locations -$this->page->blockCheckoutMixedPayment = false; -} else { - - $paid = false; - $nonpaid = false; - - // For each venu in the cart - foreach ($cart['cartDataReorganized'] as $c) { - - // Check for mix of credit card and manual payment - if ($c['payment_gateway']['value'] == 3) { - $nonpaid = true; - } else { - $paid = true; - } - - } - - // If there's a mix, warn the user and don't permit checkout. - if ($paid && $nonpaid) { - $this->reason[] = 'Mixing of credit card purchases and manual payment is not supported at this time.'; - $this->page->blockCheckoutMixedPayment = true; - } - -} - - -// If we're doing cart promotions, get any performances with promote_on_cart set -if ($this->config->option->cart_promotions) { - $cartPromotions = $Support->getCartPromotions(); - if ($cartPromotions) { - $this->page->cartPromotions = $this->bindArrayToObject($cartPromotions); - } -} - -//var_dump($this->page->cartPromotions); - -// Check if we received a vertical scroll position -$vertScroll = 0; -if ($_REQUEST['vertScroll']) { - $vertScroll = ($_REQUEST['vertScroll']-0); -} -$this->page->vertScroll = $vertScroll; - -// Otherwise we're OK to continue showing the cart -$this->page->promoCode = $promo_code; -$this->page->blockCheckout = $cart['blockCheckout']; -$this->page->blockCheckoutNonAssignment = $cart['blockCheckoutNonAssignment']; -$this->page->doingAdditionalInfo = $cart['doingAdditionalInfo']; -$this->page->haveCartStickyItems = $haveCartStickyItems; -$this->page->cartHasContents = $cart['cartHasContents']; -$this->page->cartHasOneVenueOnly = $cart['cartHasOneVenueOnly']; -$this->page->cart = $this->bindArrayToObject($cart['cartDataReorganized']); // Use reorganized cart -$this->page->totals = $this->bindArrayToObject($cart['totals']); -$this->reason = array_merge($this->reason, $cart['reason']); -$this->page->reason = $this->bindArrayToObject($this->reason); - -$this->templateFile = "Shop/cart.html"; - -$this->addDebug("Shop/cart.inc", 'Array: $totals', print_r($cart['totals'],1)); -$this->addDebug("Shop/cart.inc", 'Array: $cart', print_r($rCart,1)); - -?> - diff --git a/legacy/models/front/actions/Shop/checkout.inc b/legacy/models/front/actions/Shop/checkout.inc deleted file mode 100644 index 60fe307..0000000 --- a/legacy/models/front/actions/Shop/checkout.inc +++ /dev/null @@ -1,203 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: checkout.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Select the front-end support class -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/checkoutSupport.php'; -$CheckoutSupport = new EventManagementFrontCheckoutSupport($this->dbh, $this->config, $Support); - -// Clear any 0 quantity items from cart - This purges any 0 quant sticky items before trying to checkout -if (is_array($_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart']) && count($_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart']) > 0) { - foreach ($_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'] as $c) { - if ($c['quant'] == 0) { - unset($_SESSION['GLM_EVENT_MGT_FRONT']['TicketCart'][$c['invenID']]); - } - } -} - -// Check if we're coming back from checkoutSubmit.inc and already have cart data -if (isset($checkoutCart)) { - $cart = $checkoutCart; -} else { - // Check if there's been anything added to the cart and get cart contents (say we're doing checkout) - $cart = $Support->checkCart(true); -} - -if (!$cart['cartHasContents']) { - $this->reason[] = 'Your cart is currently empty.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/cart.inc'; - return; -} -$this->page->cartHasContents = true; - -// Check if there been partial payment and we're in a forced checkout phase - no cart changes or additions -$this->page->forceCheckoutPhase = $cart['forceCheckoutPhase']; - -// Get a clear input value array and place payment data under each venue in $cart -if (!isset($checkoutReturnFlag) || $checkoutReturnFlag == false ) { - $formData = $CheckoutSupport->checkoutInit($cart['cartData']); -} - -// Is there central payment? -if ($formData['centralPayment']) { - - // Just a shortcut to the member data - $cpMemb = $formData['centralPayment']['membData']; - - $cp = array( - 'havePayPal' => false, - 'haveCreditCards' => false, - 'havePaymentMethod' => false, - 'haveMultiplePaymentMethods' => false, - 'paymentForm' => $formData['payment'] - ); - - // Check credit card payment setup for venu - if ( - $cpMemb['payment_gateway']['value'] > 0 // Have processor selected - && count($cpMemb['cards_accepted']['names']) > 0 // Have credit cards selected - ) { - - // Check for any needed gateway authentication information - $haveAuth = false; - switch($cpMemb['payment_gateway']['value']) { - case $this->config->ccard_processor_numb->authorize_net: - if ($cpMemb['gateway_par1'] != '' && $cpMemb['gateway_par2'] != '') { - $haveAuth = true; - } - break; - case $this->config->ccard_processor_numb->merchant_solutions: - if ($cpMemb['gateway_par1'] != '' && $cpMemb['gateway_par2'] != '') { - $haveAuth = true; - } - break; - case $this->config->ccard_processor_numb->test: - $haveAuth = true; - break; - } - - if ($haveAuth) { - - // Have good credit card gateway, have cards, have authentication - $cp['haveCreditCards'] = true; - $cp['havePaymentMethod'] = true; - } - } - - // Check if we have PayPal authentication data - if ( - $cpMemb['paypal']['value'] && - $cpMemb['paypal_client_id'] != '' && - $cpMemb['paypal_secret'] != '' - ){ - $cp['havePayPal'] = true; - $cp['havePaymentMethod'] = true; - - } - - // Check if we have multiple payment methods for this member - if ($cp['haveCreditCards'] && $cp['havePayPal']) { - $cp['haveMultiplePaymentMethods'] = true; - } - - $formData['centralPayment'] = array_merge($formData['centralPayment'], $cp); - -} else { - - // Not doing Central Payment - - if (is_array($formData['payment'])) { - - foreach ($formData['payment'] as $p) { - - // set shortcut to cart member/venue - $cm = &$cart['cartDataReorganized'][$p['id']]; - - // Add payment information - $cm['paymentForm'] = $p; - - // Also check for valid payment methods - $cm['havePayPal'] = false; - $cm['haveCreditCards'] = false; - $cm['havePaymentMethod'] = false; - $cm['haveMultiplePaymentMethods'] = false; - if ( - $cm['payment_gateway']['value'] > 0 // Have processor selected - && count($cm['cards_accepted']['names']) > 0 // Have credit cards selected - ) { - // Check for any needed gateway authentication information - $haveAuth = false; - switch($cm['payment_gateway']['value']) { - case $this->config->ccard_processor_numb->authorize_net: - if ($cm['gateway_par1'] != '' && $cm['gateway_par2'] != '') { - $haveAuth = true; - } - break; - case $this->config->ccard_processor_numb->merchant_solutions: - if ($cm['gateway_par1'] != '' && $cm['gateway_par2'] != '') { - $haveAuth = true; - } - break; - case $this->config->ccard_processor_numb->test: - $haveAuth = true; - break; - } - - if ($haveAuth) { - // Have good credit card gateway, have cards, have authentication - $cm['haveCreditCards'] = true; - $cm['havePaymentMethod'] = true; - } - } - - // Check if we have PayPal authentication data - if ( - $cm['paypal']['value'] && - $cm['paypal_client_id'] != '' && - $cm['paypal_secret'] != '' - ) { - $cm['havePayPal'] = true; - $cm['havePaymentMethod'] = true; - - } - - // Check if we have multiple payment methods for this member - if ($cm['haveCreditCards'] && $cm['havePayPal']) { - $cm['haveMultiplePaymentMethods'] = true; - } - - } - } -} - -unset($formData['payment']); - -// Otherwise we're OK to continue showing the cart -$this->page->promoCode = $_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode']; -$this->page->cartHasContents = $cart['cartHasContents']; -$this->page->cart = $this->bindArrayToObject($cart['cartDataReorganized']); -$this->page->cartHasOneVenueOnly = $cart['cartHasOneVenueOnly']; -$this->page->cartRequiresPayment = $cart['cartRequiresPayment']; -$this->page->totals = $this->bindArrayToObject($cart['totals']); -$this->page->formData = $this->bindArrayToObject($formData); // Blank form data for cleared fields -$this->reason = array_merge($this->reason, $cart['reason']); - -$this->templateFile = "Shop/checkout.html"; - -$this->addDebug("Shop/checkout.inc", 'Array: $totals', print_r($cart['totals'],1)); -$this->addDebug("Shop/checkout.inc", 'Array: $cart', print_r($cart['cartData'],1)); -$this->addDebug("Shop/checkout.inc", 'Array: $formData', print_r($formData,1)); -?> - diff --git a/legacy/models/front/actions/Shop/checkoutSubmit.inc b/legacy/models/front/actions/Shop/checkoutSubmit.inc deleted file mode 100644 index 634b140..0000000 --- a/legacy/models/front/actions/Shop/checkoutSubmit.inc +++ /dev/null @@ -1,302 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: checkout.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Select the front-end support class -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -/* - * Start by checking the cart and getting cart contents - */ -$cart = $Support->checkCart(true); - -// Assume we don't have to return to checkout -$checkoutReturnFlag = false; - -// Need this before we put together the E-Mail summaries -$this->page->promoCode = $_SESSION['GLM_EVENT_MGT_FRONT']['PromoCode']; - -// Check if there hasn't been a complete checkout yet. -if (!$cart['checkoutComplete']) { - - // Check for empty cart - if (!$cart['cartHasContents']) { - $this->reason[] = 'Your cart is currently empty.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/cart.inc'; - return; - } - - // If there's a problem with the cart, send the user back to the cart page - if ($cart['status'] == false) { - $this->reason = array_merge($this->reason, $cart['reason']); - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; - } - - /* - * Check the submitted input for required and valid fields - */ - - // Load checkout support class - require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/checkoutSupport.php'; - $CheckoutSupport = new EventManagementFrontCheckoutSupport($this->dbh, $this->config, $Support); - - // Check submitted input to see if we have everything we need from the user - // Supply that data to the page and place payment data under each venue - $formData = $CheckoutSupport->checkoutInput($cart['cartDataReorganized']); - - if ($formData != false) { - - - // If we didn't receive all needed input, display checkout form again - if (!$formData['status']) { - $checkoutReturnFlag = true; - $this->reason = array_merge($this->reason, $formData['reason']); - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; - } - - // If we have Central Payment - if ($formData['centralPayment']) { - - $membID = $formData['centralPayment']['membData']['id']; - - // Check if reorganized cart data doesn't have central billing member. - if (!isset($cart['cartDataReorganized'][$membID])) { - - // Didn't have it, so add the venue data now - $cart['cartDataReorganized'][$membID] = $formData['centralPayment']['membData']; - - // Also flag that it's member data without any performances selected - $cart['cartDataReorganized'][$membID]['centralPaymentOnly'] = true; - } else { - $cart['cartDataReorganized'][$membID]['centralPaymentOnly'] = false; - } - - // Mark the central billing member cart entry - $cart['cartDataReorganized'][$membID]['isCentralPaymentMember'] = true; - - } - - // Provide all cart and payment data back to the page for display - $this->page->formData = $this->bindArrayToObject($formData); - - /* - * Try to process all payments - Supply our cart information and all user submitted information - */ - $paymentResult = $CheckoutSupport->checkoutProcessPayments($cart['cartDataReorganized'], $formData); - - // Inject payment results into cartData array and session data - foreach($paymentResult['payments'] as $r) { - - // Create MD5 Check for access to order - Keeps people from tampering with ID # in URL line. - $r['orderVerification'] = md5($r['orderID'].$this->config->orderVerificationSecret); - - // Place payment result under reorganized cart data for output - $cart['cartDataReorganized'][$r['id']]['paymentResult'] = $r; - - // If this is a newly completed payment - Send all appropriate notices for this order - if ($r['newApproval']) { - - // Get customer confirmation E-Mail - $sql = " - SELECT name, email, proc_email, proc_email2, checkout_email, checkout_notify - FROM eventmgt.member - WHERE id = ".$r['id']." - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $membData = $stmt->fetch(PDO::FETCH_ASSOC); - - // Get any confirmation E-Mail content from Performances (only one per performance type) - $confTextArray = array(); - if (count($cart['cartDataReorganized'][$r['id']]['performances']) > 0) { - foreach($cart['cartDataReorganized'][$r['id']]['performances'] as $p) { - - // If there's confirmation text for this performance, add it with index of the performance ID - if (trim($p['conf_text']) != '') { - $confTextArray[$p['id']] = trim($p['conf_text']); - } - - } - } - - // If there's any confirmation text from performances, compile it all into one string. - $confText = ''; - if (count($confTextArray) > 0) { - foreach($confTextArray as $ct) { - $confText .= "

    $ct

    \n"; - } - } - - $checkoutEmail = $membData['checkout_email']; - - // If we have confirmation E-Mail header text then include that - // Otherwise it will be blank and we'll just send summary - if ($checkoutEmail != '') { - - // Merge order data into E-Mail - $tags = array( - '{first-name}', - '{last-name}', - '{address-line-1}', - '{address-line-2}', - '{city}', - '{state}', - '{zip}', - '{country}', - '{'.$this->config->term->performance->norm.'-text}' - ); - $vals = array( - $formData['contact']['fname']['value'], - $formData['contact']['lname']['value'], - $formData['contact']['addr1']['value'], - $formData['contact']['addr2']['value'], - $formData['contact']['city']['value'], - $formData['contact']['state']['value'], - $formData['contact']['zip']['value'], - $formData['contact']['country']['value'], - $confText - ); - - $checkoutEmail = str_replace($tags, $vals, $checkoutEmail); - - } - - // Create Purchase Summary - $templateFile = "Shop/paymentSummary.html"; - $this->page->cartEntry = $this->bindArrayToObject($cart['cartDataReorganized'][$r['id']]); - - $this->template->compile($this->userInterface.'/'.$templateFile); - $html_summary = $this->template->bufferedOutputObject($this->page); - unset($this->page->cartEntry); - - // Try to send E-Mail to customer - $email_content = "--ContentBoundry\n" - ."Content-Type: text/plain; charset=\"US-ASCII\"\n" - ."\n" - ."This message may only be read using an HTML enabled E-Mail client." - ."\n" - ."--ContentBoundry\n" - ."Content-Type: text/html; charset=\"US-ASCII\"\n" - ."\n" - .$checkoutEmail - ."\n" - .$html_summary - ."\n" - ."--ContentBoundry--\n" - ."\n"; - - $emailAddress = $formData['contact']['email']['value']; - if (!empty($emailAddress)) { - $this->debug_mail( - $emailAddress, - $membData['name'].' Purchase Confirmation', - $email_content, - "From: ".$membData['name']." <".$membData['email'].">" - ."\nMime-Version: 1.0\nContent-Type: multipart/alternative; boundary=ContentBoundry\n" - ); - } - - // If notifying member/venue - if ($membData['checkout_notify']) { - - // Build processing E-Mail addresses - $procEmail = $membData['proc_email']; - if ($membData['proc_email2'] != '') { - if ($procEmail != '') { - $procEmail .= ','; - } - $procEmail .= $membData['proc_email2']; - } - - // If we have a processing E-Mail address - if ($procEmail != '') { - - // Send E-Mail to member/venue - $email_content = "--ContentBoundry\n" - ."Content-Type: text/plain; charset=\"US-ASCII\"\n" - ."\n" - ."This message may only be read using an HTML enabled E-Mail client." - ."\n" - ."--ContentBoundry\n" - ."Content-Type: text/html; charset=\"US-ASCII\"\n" - ."\n" - ."The following purchase has been made for your Venue." - ."\n" - .$html_summary - ."\n" - ."--ContentBoundry--\n" - ."\n"; - $this->debug_mail( - $procEmail, - $membData['name'].' Purchase Notification', - $email_content, - "From: ".$membData['name']." <".$membData['email'].">" - ."\nMime-Version: 1.0\nContent-Type: multipart/alternative; boundary=ContentBoundry\n" - ); - - } // Have processing E-Mail address - - } // Doing notification to member/venue - - // Clear new approval flag so we don't send notices again - If not checkout testing enabled - if (!$this->config->option->checkout_testing) { - $cart['cartDataReorganized'][$r['id']]['paymentResult']['newApproval'] = false; - } else { - // When doing checkout testing, add full SQL transaction to debug for each payment result - $this->addDebug("SQL Transaction for ".$cart['cartDataReorganized'][$r['id']]['name'], 'SQL Transaction', print_r($r['sqlTransaction'],1)); - } - } - - } // Each payment result - - } - - // Store the current payments data back into the session - If not checkout testing enabled - if (!$this->config->option->checkout_testing) { - $_SESSION[GLM_EVENT_SESSION]['TicketPayments'] = $paymentResult['payments']; - } - - // If there was a problem processing any of the venue payments - return user to checkout page - if (!$paymentResult['status']) { - - $checkoutReturnFlag = true; - $this->reason[] = 'There was a problem processing your request. '; - $checkoutCart = $cart; // Save because it's going to get overwritten by checkout.inc - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; - - } - - -} // If checkout not already complete -$this->page->cartHasContents = $cart['cartHasContents']; -$this->page->cart = $this->bindArrayToObject($cart['cartDataReorganized']); -$this->page->totals = $this->bindArrayToObject($cart['totals']); -$this->page->cartHasOneVenueOnly = $cart['cartHasOneVenueOnly']; -$this->templateFile = "Shop/checkoutSuccess.html"; - -$this->addDebug("Shop/checkoutSubmit.inc", 'Array: $totals', print_r($cart['totals'],1)); -$this->addDebug("Shop/checkoutSubmit.inc", 'Array: $cart', print_r($cart['cartDataReorganized'],1)); -$this->addDebug("Shop/checkoutSubmit.inc", 'Array: $formData', print_r($formData,1)); - -// Destroy session to clear cart - If not doing checkout testing -if (!$this->config->option->checkout_testing) { - $_SESSION[GLM_EVENT_SESSION]['TicketCart'] = false; - $_SESSION[GLM_EVENT_SESSION]['ContactInput'] = false; - $_SESSION[GLM_EVENT_SESSION]['TicketPayments'] = false; -} -?> - diff --git a/legacy/models/front/actions/Shop/printVoucher.inc b/legacy/models/front/actions/Shop/printVoucher.inc deleted file mode 100644 index 7cf3b31..0000000 --- a/legacy/models/front/actions/Shop/printVoucher.inc +++ /dev/null @@ -1,60 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: printVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -// Get Order ID -$orderID = $_REQUEST['OrderID'] - 0; -if ($orderID == 0) { - exit; -} - -// Check Order Verification Code - Prevents people just sticking order numbers into urls to get vouchers -$orderVerify = md5($orderID.$this->config->orderVerificationSecret); -if ($orderVerify != $_REQUEST['orderVerify']) { - // Bad verification code - echo "Voucher Fault Code: 21"; - exit; -} - -// Get Order Detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/orders.php'; -$Orders = new EventManagementAdminOrders($this->dbh, $this->config); -$orderDetail = $Orders->getOrderDetail($orderID); - -// Get Ticket Sold (voucher) detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/sold.php'; -$Sold = new EventManagementAdminSold($this->dbh, $this->config); -$soldList = $Sold->getSoldList($orderID); - -// Get Venue Detail -require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/members.php'; -$Members = new EventManagementAdminMembers($this->dbh, $this->config); -$memberDetail = $Members->getMemberDetail($orderDetail['member']); - -// Load voucher design code as per the "voucher_design" config parameter in the site's config/applications/EventManagement.ini file -if (is_file(EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucher.php')) { - if (isset($_REQUEST['Mobile'])) { - require_once EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucherMobile.php'; - } else { - require_once EVENT_MANAGEMENT_APP_BASE.'models/vouchers/'.$this->config->voucher_design.'/voucher.php'; - } - $pdf = new PdfVoucher($orderDetail, $soldList, $memberDetail, $this->dbh, $this->config); -} else { - echo "SYSTEM ERROR: Site is not configured with a valid voucher design file."; - exit; -} - -// There's nothing to do from here. Output should go direct to browser. -exit; - -?> \ No newline at end of file diff --git a/legacy/models/front/actions/Shop/sectionSelect.inc b/legacy/models/front/actions/Shop/sectionSelect.inc deleted file mode 100644 index b21553a..0000000 --- a/legacy/models/front/actions/Shop/sectionSelect.inc +++ /dev/null @@ -1,83 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: sectionSelect.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -// Check If we're already locked into checkout, if so then go there -$cart = $Support->checkCart(); -if ($cart['forceCheckoutPhase']) { - $this->reason[] = 'You have partially paid for your purchases. We have returned you to checkout to complete your purchase.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; -} - -// If perfID hasn't been past to us, get selected Performance ID from input -if (!isset($perfID)) { - $perfID = ($_REQUEST['PerformanceID'] - 0); -} - -// Do we have a valid performance ID? -if ($perfID == 0) { - $this->reason[] = 'No '.$this->config->term->event->norm.' has been selected.'; -} else { - - // Get detail on selected performance - $performanceDetail = $this->support->getPerformanceData($perfID); - $this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - - $this->addDebug("Shop/sectionSelect.inc", 'Array: $performanceDetail', print_r($performanceDetail,1)); - - // If we can't find the performance - if (!$performanceDetail) { - $this->reason[] = 'We were unable to find the selected '.$this->config->term->event->norm.'.'; - } else { - - // Query to find section IDs for sections that have active ticket inventory for the selected performance - $sql = "T.id in ( - SELECT distinct(K.section) - FROM eventmgt.ticket K, eventmgt.ticket_inventory I - WHERE performance = $perfID - AND I.ticket = K.id - )"; - - // Get Section List for this performance for sections with available tickets - $sectionList = $this->support->getSectionList($false, $sql); - $this->page->sectionList = $this->bindArrayToObject($sectionList); - - $this->addDebug("Shop/sectionSelect.inc", 'Array: $sectionList', print_r($sectionList, 1)); - - // If no sections found for this performance - if (!$sectionList) { - $this->reason[] = 'We were unable to find any '.$this->config->term->section->plur.' for this '.$this->config->term->event->norm.'.'; - } else { - - // if there's only one section, then select it for the user and move on to ticket selection - unless we're forcing section display - if (!$this->config->option->ticket_selection->force_section && count($sectionList) == 1) { - - $this->addDebug("Shop/ticketSelect.inc", '*** Change to new method/view ***'); - - $passSectionID = $sectionList[0]['id']; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/ticketSelect.inc'; - return; - } - - } - } -} - -$this->templateFile = "Shop/sectionSelect.html"; - -?> - diff --git a/legacy/models/front/actions/Shop/start.inc b/legacy/models/front/actions/Shop/start.inc deleted file mode 100644 index 69c5e40..0000000 --- a/legacy/models/front/actions/Shop/start.inc +++ /dev/null @@ -1,126 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: start.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -// Check If we're already locked into checkout, if so then go there -$cart = $Support->checkCart(); -if ($cart['forceCheckoutPhase']) { - $this->reason[] = 'You have partially paid for your purchases. We have returned you to checkout to complete your purchase.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; -} - -// Check if "Start at Cart" option is enabled. Generally used when there's cart-sticky items. -if ($this->config->option->ticket_selection->start_at_cart) { - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/cart.inc'; - return; -} - -$this->templateFile = "Shop/start.html"; - -// Get Members list - all active -$membersList = $Support->getMembersList('active'); - -// if there's no members listed -if (count($membersList) == 0) { - $this->reason[] = 'There are no available '.$this->config->term->prop->plur.'.'; - return; -} - -// Get available performances data for each member and add them to the member data -$havePerformance = false; -$inventory = array(); - -if (is_array($membersList) && count($membersList) > 0) { - - reset($membersList); - - while (list($k, $v) = each($membersList)) { - - // Get list of performances for this member - $performancesList = $Support->getPerformancesList($v[id], 'member_and_active'); - - // If we have performances for this member - if ($performancesList) { - - $havePerformances = true; - - // For each performance, get the ticket data and add it to the array - reset($performancesList); - while (list($k2, $v2) = each($performancesList)) { - - // Get all performance data for this performance - $perfData = $this->support->getAllPerformanceData($v2['id']); - - // if we got any data, add it to the performance - if ($perfData) { - - // Are we supposed to also provide actual ticket selection on this page? - if ($this->config->option->ticket_selection->show_tickets_on_start_page) { - - // Add performance section/ticket data to the performance list - $performancesList[$k2]['oneSectionOnly'] = $perfData['oneSectionOnly']; - $performancesList[$k2]['sections'] = $perfData['sections']; - - // Add inventory to the inventory array - $inventory += $perfData['inventory']; - - } // Option to show tickets on start page - - // If there's no performance data, then drop performance from list - } else { - unset($performancesList[$k2]); - } // have Performance data - - } // for each performance - - // Add all performance data, including tickets, to the member performances - $membersList[$k]['performances'] = $performancesList; - - // Otherwise there's no active performances or tickets - } else { - - // Since there's nothing to display, drop this member. - unset($membersList[$k]); - } - - if ($k && !isset($membersList[$k]['performances'])) { - unset($membersList[$k]); - } - - } -} - -// Pass flag to show tickets on start page from config -$this->page->showTickets = $this->config->option->ticket_selection->show_tickets_on_start_page; - -// Pass members list with performances and optional ticket data to template -$this->page->membersList = $this->bindArrayToObject($membersList); - -// Also supply all ticket inventory as a JSON for the front-end scripts -$this->page->ticketsJSON = json_encode($inventory, (int) JSON_PRETTY_PRINT); - -$this->addDebug("Shop/start.inc", 'Array: $membersList - with Performances', print_r($membersList, 1)); -$this->addDebug("Shop/start.inc", 'Array: $inventory', print_r($inventory, 1)); - -// If we didn't get any performances to select from -if (!$havePerformances) { - $this->reason[] = 'There are no available '.$this->config->term->event->plur.'.'; -} - - -?> - diff --git a/legacy/models/front/actions/Shop/ticketOpt.inc b/legacy/models/front/actions/Shop/ticketOpt.inc deleted file mode 100755 index 5f52efe..0000000 --- a/legacy/models/front/actions/Shop/ticketOpt.inc +++ /dev/null @@ -1,265 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: ticketOpt.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -// Check If we're already locked into checkout, if so then go there -$cart = $Support->checkCart(); -if ($cart['forceCheckoutPhase']) { - $this->reason[] = 'You have partially paid for your purchases. We have returned you to checkout to complete your purchase.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; -} - -// If perfID hasn't been passed to us, get selected Performance ID from input -if (!isset($perfID)) { - $perfID = ($_REQUEST['PerformanceID'] - 0); -} - -// Get selected Performance ID -$perfID = ($_REQUEST['PerformanceID'] - 0); -if ($perfID == 0) { - $this->reason[] = 'No '.$this->config->term->event->norm.' has been selected.'; -} else { - - // Get selected performance data - $performanceDetail = $this->support->getPerformanceData($perfID); - $this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - - $this->addDebug("Shop/ticketOpt.inc", 'Array: $performanceDetail', print_r($performanceDetail,1)); - - // If we can't find the performance - if (!$performanceDetail) { - $this->reason[] = 'We were unable to find the selected '.$this->config->term->event->norm.'.'; - } else { - - // If sectionID hasn't been past to us, get selected Section ID from input - if (!isset($sectionID)) { - $sectionID = ($_REQUEST['SectionID'] - 0); - } - - if ($sectionID == 0) { - $this->reason[] = 'No '.$this->config->term->section->norm.' has been selected.'; - } else { - - // Get selected section data - $sectionDetail = $this->support->getSpecifiedSectionDetail($sectionID); - $this->page->sectionDetail = $this->bindArrayToObject($sectionDetail); - - $this->addDebug("Shop/ticketOpt.inc", 'Array: $sectionDetail', print_r($sectionDetail,1)); - - // If section not found - if (!$sectionDetail) { - $this->reason[] = 'We were unable to find the selected '.$this->config->term->section->plur.'.'; - } else { - - // If ticketID hasn't been past to us, get selected ticket ID from input - if (!isset($ticketID)) { - $ticketID = ($_REQUEST['TicketID'] - 0); - } - - if ($ticketID == 0) { - $this->reason[] = 'No '.$this->config->term->ticket->norm.' has been selected.'; - } else { - - // Get Ticket detail - $ticketDetail = $this->support->getSpecifiedTicketDetail($ticketID); - $this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - - $this->addDebug("Shop/ticketOpt.inc", 'Array: $ticketDetail', print_r($ticketDetail,1)); - - // If ticket not found - if (!$ticketDetail) { - $this->reason[] = 'We were unable to find the selected '.$this->config->term->ticket->plur.'.'; - } else { - - // Get inventory for this ticket - $inventoryList = $this->support->getInventoryList($ticketID, 'T.active', true); - - // If no inventory found for this ticket - if (!$inventoryList) { - $this->reason[] = 'We were unable to find inventory for the selected '.$this->config->term->ticket->norm.'.'; - } else { - - // Determine if any of the dates are too late to buy on-line. - // If no timestamp then it's not a date-specific ticket, so no purchase leadtime issue. - while (list($k, $v) = each($inventoryList)) { - if ($v['ticket_date']['timestamp']) { - $inventoryList[$k]['tooLate'] = (time() > strtotime($k) - ($performanceDetail['purch_leadtime']*3600) ); - } else { - $inventoryList[$k]['tooLate'] = false; - } - } - - // We're now ready to pass the inventory list to the page - $this->page->inventoryList = $this->bindArrayToObject($inventoryList); - - $this->addDebug("Shop/ticketOpt.inc", 'Array: $inventoryList', print_r($inventoryList,1)); - - // Also supply this list as a JSON for the scripts - $this->page->inventoryJSON = json_encode($inventoryList, (int) JSON_PRETTY_PRINT); - $this->addDebug("Shop/ticketOpt.inc", 'JSON: $inventoryJSON', print_r($this->page->inventoryJSON,1)); - - } // Have inventory list - - } // Have ticket detail - - } // Have ticket ID - - } // Have section detail - - } // Have section ID - - } // Have performance detail - -} // Have performance ID - -$this->templateFile = "Shop/ticketOpt.html"; - - -/* - - - -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -// Check If we're already locked into checkout, if so then go there -$cart = $Support->checkCart(); -if ($cart['forceCheckoutPhase']) { - $this->reason[] = 'You have partially paid for your purchases. We have returned you to checkout to complete your purchase.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; -} - - -// Get selected ticket information -$perfID = ($_REQUEST['TicketID'] - 0); -if ($perfID == 0) { - $this->reason[] = 'No '.$this->config->term->ticket->norm.' has been selected.'; -} else { - - // Get Tickets and Inventory Information - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; - $Tickets = new EventManagementDataTickets($this->dbh, $this->config); - $Tickets->optionIncludeSelectListData = false; - $ticketDetail = $Tickets->getTicketDetail($TicketID); - $this->page->ticketDetail = $this->bindArrayToObject($ticketDetail); - - // If we can't find the ticket - if (!$ticketDetail) { - $this->reason[] = 'We were unable to find the selected '.$this->config->term->ticket->norm.' information.'; - } else { - - // Get performance information - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPerformances.php'; - $Performances = new EventManagementDataPerformances($this->dbh, $this->config); - $Performances->optionIncludeSelectListData = false; - $performanceDetail = $Performances->getPerformanceDetail($ticketDetail['performance_id']); - $this->page->performanceDetail = $this->bindArrayToObject($performanceDetail); - - // If we can't find the performance information - if (!$performanceDetail) { - $this->reason[] = 'We were unable to find the selected '.$this->config->term->event->norm.' information.'; - } else { - - - - } - } -} - - -// Check that Venue has a valid payment method setup -$this->page->havePayPal = false; -$this->page->haveCreditCards = false; -$this->page->havePaymentMethod = false; -if ( - $detail['member']['payment_gateway']['value'] > 0 // Have processor selected - && count($detail['member']['cards_accepted']['names']) > 0 // Have credit cards selected -) { - - // Check for any needed gateway authentication information - $haveAuth = false; - switch($detail['member']['payment_gateway']['value']) { - case $this->config->ccard_processor_numb->authorize_net: - if ($detail['member']['gateway_par1'] != '' && $detail['member']['gateway_par2'] != '') { - $haveAuth = true; - } - break; - case $this->config->ccard_processor_numb->merchant_solutions: - if ($detail['member']['gateway_par1'] != '' && $detail['member']['gateway_par2'] != '') { - $haveAuth = true; - } - break; - case $this->config->ccard_processor_numb->test: - $haveAuth = true; - break; - if ($haveAuth) { - // Have good credit card gateway, have cards, have authentication - $this->page->haveCreditCards = true; - $this->page->havePaymentMethod = true; - } -} -if ( - $detail['member']['paypal']['value'] && - $detail['member']['paypal_client_id'] != '' && - $detail['member']['paypal_secret'] != '' -){ - - $this->page->havePayPal = true; - $this->page->havePaymentMethod = true; - -} - -// If there's no possible payment method -if (!$this->page->havePaymentMethod) { - $detail['reason'][] = 'This '.$this->config->term->prop->norm.' has not configured any payment method. - Please call to purchase '.$this->config->term->ticket->plur.'.'; - $this->page->dissableAddToCart = true; -} - -// Check if member is set to active -if (!$detail['member']['active']['value']) { - $detail['reason'][] = 'This venue is not currently available to sell tickets on-line.'; - $this->page->dissableAddToCart = true; -} - -// Check for sections, tickets, and inventory -$mesg = ''; -if (!$detail['haveSections']) { - $mesg .= ' sections?'; -} -if (!$detail['haveTickets']) { - $mesg .= ' tickets?'; -} -if (!$detail['haveInventory']) { - $mesg .= ' inventory?'; -} -if ($mesg != '') { - $detail['reason'][] = 'No '.$this->config->term->ticket->plur.' are available for this '.$this->config->term->event->norm.". ($mesg )"; -} - -$this->reason = array_merge($this->reason, $detail['reason']); -unset($detail['reason']); - -$this->page->detail = $this->bindArrayToObject($detail); - -$this->templateFile = "Shop/ticketOpt.html"; - -// $this->addDebug("Shop/ticketOpt.inc", 'Array: $detail', print_r($detail,1)); - -?> -*/ diff --git a/legacy/models/front/actions/Shop/ticketSelect.inc b/legacy/models/front/actions/Shop/ticketSelect.inc deleted file mode 100644 index de0939a..0000000 --- a/legacy/models/front/actions/Shop/ticketSelect.inc +++ /dev/null @@ -1,77 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: ticketSelect.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once EVENT_MANAGEMENT_APP_BASE.'models/front/classes/support.php'; -$Support = new EventManagementFrontSupport($this->dbh, $this->config); - -// Check If we're already locked into checkout, if so then go there -$cart = $Support->checkCart(); -if ($cart['forceCheckoutPhase']) { - $this->reason[] = 'You have partially paid for your purchases. We have returned you to checkout to complete your purchase.'; - include EVENT_MANAGEMENT_APP_BASE.'models/front/actions/Shop/checkout.inc'; - return; -} - -// Get performance ID that might have been passed to us - otherwise set to 0 -$perfID = 0; -if (isset($_REQUEST['PerformanceID'])) { - $perfID = ($_REQUEST['PerformanceID'] - 0); - if ($perfID > 0) { - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $perfID; - } -} - -// Get section ID that might have been passed to us - otherwise set to 0 -$sectID = 0; -if (isset($passSectionID)) { // Passed by calling method (i.e. sectionSelect.inc) - $sectID = $passSectionID; -} elseif (isset($_REQUEST['SectionID'])) { - $sectID = ($_REQUEST['SectionID'] - 0); -} -if ($sectID > 0) { - $_SESSION[GLM_EVENT_SESSION]['Section'] = $sectID; -} - -// If we don't have a performance ID then fail this step -if ($perfID == 0) { - $this->reason[] = 'No '.$this->config->term->event->norm.' has been selected.'; -} else { - - // Get all performance data including all tickets prepped for use in a JSON for the front-end - $perfData = $this->support->getAllPerformanceData($perfID, $sectID); - - // Save currently selected performance and member (venue) - $_SESSION[GLM_EVENT_SESSION]['Performance'] = $perfID['id']; - $_SESSION[GLM_EVENT_SESSION]['Member'] = $perfID['member_id']; - - // Pass performance detail and section and ticket information to the template - $this->page->oneSectionOnly = $perfData['oneSectionOnly']; - $this->page->performanceDetail = $this->bindArrayToObject($perfData['performanceDetail']); - $this->page->sections = $this->bindArrayToObject($perfData['sections']); - - // Also supply all ticket inventory as a JSON for the front-end scripts - $this->page->ticketsJSON = json_encode($perfData['inventory'], (int) JSON_PRETTY_PRINT); - - $this->addDebug("Shop/ticketSelect.inc", 'Performance Detail', print_r($perfData['performanceDetail'],1)); - $this->addDebug("Shop/ticketSelect.inc", 'Section and Ticket Data', print_r($perfData['sections'],1)); - $this->addDebug("Shop/ticketSelect.inc", 'Ticket Inventory Data', print_r($perfData['inventory'],1)); - $this->addDebug("Shop/ticketSelect.inc", 'JSON: $ticketsJSON', print_r($this->page->ticketsJSON,1)); - -} // Have performance ID - -$this->templateFile = "Shop/ticketSelect.html"; - - -?> - diff --git a/legacy/models/front/classes/checkoutSupport.php b/legacy/models/front/classes/checkoutSupport.php deleted file mode 100644 index 8481520..0000000 --- a/legacy/models/front/classes/checkoutSupport.php +++ /dev/null @@ -1,1721 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/checkoutSupport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -/** - * EventManagementFrontCheckoutSupport class - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/checkoutSupport.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementFrontCheckoutSupport -{ - - /** - * Configuration information object - * @var $ini - * @access public - */ - protected $config; - /** - * Database Object - * @var $dbh - * @access public - */ - protected $dbh; - /** - * Support class object - * @var $Support - * @access public - */ - protected $Support; - /** - * Checkout Data Array - * @var $cd - * @access public - */ - protected $cd; - /** - * Flag to indicate if there's an input problem - * @var $inputFail - * @access public - */ - protected $inputFail = false; - /** - * SQL Transaction for passing back to calling methods when doing debug - * @var $sqlTransaction - * @access public - */ - protected $sqlTransaction = false; - - function __construct($dbh, $config, $Support) - { - - $this->dbh = $dbh; - $this->config = $config; - $this->Support = $Support; - - } - - /* - * Initialize/reset checkout data array - */ - public function checkoutInit($cart) - { - - // Determine if we're running as an admin user for setting "required" for certain fields. - $admin_user_require = !$_SESSION[GLM_EVENT_SESSION]['AdminUser']; - - // If there's not already checkout contact info in the session, start clean - if ($_SESSION[GLM_EVENT_SESSION]['ContactInput'] == false) { - - if ($this->config->option->checkout_pre_fill) { - - $this->cd = array( - 'contact' => array( - 'fname' => array('value' => 'John', 'required' => true, 'problem' => false), - 'lname' => array('value' => 'Smith', 'required' => true, 'problem' => false), - 'addr1' => array('value' => '120 E. Lake St.', 'required' => $admin_user_require, 'problem' => false), - 'addr2' => array('value' => 'Apt 2', 'required' => false, 'problem' => false), - 'city' => array('value' => 'Petoskey', 'required' => $admin_user_require, 'problem' => false), - 'state' => $this->createStatesArray('state', 'MI', $admin_user_require, false), - 'country' => $this->createCountriesArray('country', 'US', $admin_user_require, false), - 'phone' => array('value' => '231-487-0692', 'required' => true, 'problem' => false), - 'zip' => array('value' => '49770', 'required' => $admin_user_require, 'problem' => false), - 'email' => array('value' => 'info@gaslightmedia.com', 'required' => $admin_user_require, 'problem' => false), - 'email2' => array('value' => 'info@gaslightmedia.com', 'required' => $admin_user_require, 'problem' => false), - 'email_ok' => 'on', - 'opt_field_1' => array('value' => '', 'required' => false, 'problem' => false), - 'opt_field_2' => array('value' => '', 'required' => false, 'problem' => false), - 'opt_field_3' => array('value' => '', 'required' => false, 'problem' => false) - ), - 'payment' => array(), - 'status' => false, - 'centralPayment' => false - ); - } else { - - $this->cd = array( - 'contact' => array( - 'fname' => array('value' => '', 'required' => true, 'problem' => false), - 'lname' => array('value' => '', 'required' => true, 'problem' => false), - 'addr1' => array('value' => '', 'required' => $admin_user_require, 'problem' => false), - 'addr2' => array('value' => '', 'required' => false, 'problem' => false), - 'city' => array('value' => '', 'required' => $admin_user_require, 'problem' => false), - 'state' => $this->createStatesArray('state', false, $admin_user_require, false), - 'country' => $this->createCountriesArray('country', false, $admin_user_require, false), - 'phone' => array('value' => '', 'required' => true, 'problem' => false), - 'zip' => array('value' => '', 'required' => $admin_user_require, 'problem' => false), - 'email' => array('value' => '', 'required' => $admin_user_require, 'problem' => false), - 'email2' => array('value' => '', 'required' => $admin_user_require, 'problem' => false), - 'email_ok' => 'on', - 'opt_field_1' => array('value' => '', 'required' => false, 'problem' => false), - 'opt_field_2' => array('value' => '', 'required' => false, 'problem' => false), - 'opt_field_3' => array('value' => '', 'required' => false, 'problem' => false) - ), - 'payment' => array(), - 'status' => false, - 'centralPayment' => false - ); - } - - // Otherwise use the info stored in the session - } else { - - $ci = &$_SESSION[GLM_EVENT_SESSION]['ContactInput']; - - $this->cd = array( - 'contact' => array( - 'fname' => array('value' => $ci['fname'], 'required' => true, 'problem' => false), - 'lname' => array('value' => $ci['lname'], 'required' => true, 'problem' => false), - 'addr1' => array('value' => $ci['addr1'], 'required' => $admin_user_require, 'problem' => false), - 'addr2' => array('value' => $ci['addr2'], 'required' => false, 'problem' => false), - 'city' => array('value' => $ci['city'], 'required' => $admin_user_require, 'problem' => false), - 'state' => $this->createStatesArray('state', $ci['state'], $admin_user_require, false), - 'country' => $this->createCountriesArray('country', $ci['country'], $admin_user_require, false), - 'phone' => array('value' => $ci['phone'], 'required' => true, 'problem' => false), - 'zip' => array('value' => $ci['zip'], 'required' => $admin_user_require, 'problem' => false), - 'email' => array('value' => $ci['email'], 'required' => $admin_user_require, 'problem' => false), - 'email2' => array('value' => $ci['email2'], 'required' => $admin_user_require, 'problem' => false), - 'email_ok' => ($ci['email_ok'] ? 'on' : ''), - 'opt_field_1' => array('value' => $ci['opt_field_1'], 'required' => false, 'problem' => false), - 'opt_field_2' => array('value' => $ci['opt_field_2'], 'required' => false, 'problem' => false), - 'opt_field_3' => array('value' => $ci['opt_field_3'], 'required' => false, 'problem' => false) - - ), - 'payment' => array(), - 'status' => false, - 'centralPayment' => false - ); - - } - - // Check if there's central payment in use - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/misc.php'; - $Misc = new EventManagementAdminMisc($this->dbh, $this->config); - $miscDetail = $Misc->getEntry(1); - if ($miscDetail['central_payment_id']) { - - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMembers.php'; - $Members = new EventManagementDataMembers($this->dbh, $this->config); - $Members->optionIncludeSelectListData = false; - $membData = $Members->getMemberDetail($miscDetail['central_payment_id']); - - $this->cd['centralPayment'] = array( - 'id' => $miscDetail['central_payment_id'], - 'membData' => $membData - ); - - // Build card type array - $cctype = $this->buildCCTypeArray($membData, true, $membData, false, true); - - if ($this->config->option->checkout_pre_fill) { - - // Build expiration date array - $ccexp = $this->buildCCExpArray($required = true, $membData, 2, 2017, true); - - $this->cd['payment'][$membData['id']] = array( - 'id' => $membData['id'], - 'spec_req' => array('value' => 'none', 'required' => false, 'problem' => false), - 'cctype' => $cctype, - 'ccname' => array('value' => 'JOHN SMITH', 'required' => true, 'problem' => false), - 'ccnumb' => array('value' => '0011001100110011', 'required' => true, 'problem' => false), - 'ccexp' => $ccexp, - 'cccode' => array('value' => '123', 'required' => true, 'problem' => false), - ); - - } else { - - // Build expiration date array - $ccexp = $this->buildCCExpArray($required = true, $membData, false, false, true); - - $this->cd['payment'][$membData['id']] = array( - 'id' => $membData['id'], - 'spec_req' => array('value' => '', 'required' => false, 'problem' => false), - 'cctype' => $cctype, - 'ccname' => array('value' => '', 'required' => true, 'problem' => false), - 'ccnumb' => array('value' => '', 'required' => true, 'problem' => false), - 'ccexp' => $ccexp, - 'cccode' => array('value' => '', 'required' => true, 'problem' => false), - ); - - } - - } else { - - // Build payment array for each venue - foreach($cart as $c) { - - // Build card type array - $cctype = $this->buildCCTypeArray($c, true, $c['id'], false, true); - - if ($this->config->option->checkout_pre_fill) { - - // Build expiration date array - $ccexp = $this->buildCCExpArray($required = true, $c['id'], 2, 2017, true); - - $this->cd['payment'][$c['id']] = array( - 'id' => $c['id'], - 'spec_req' => array('value' => 'none', 'required' => false, 'problem' => false), - 'cctype' => $cctype, - 'ccname' => array('value' => 'JOHN SMITH', 'required' => true, 'problem' => false), - 'ccnumb' => array('value' => '0011001100110011', 'required' => true, 'problem' => false), - 'ccexp' => $ccexp, - 'cccode' => array('value' => '123', 'required' => true, 'problem' => false), - ); - - } else { - - // Build expiration date array - $ccexp = $this->buildCCExpArray($required = true, $c['id'], false, false, true); - - $this->cd['payment'][$c['id']] = array( - 'id' => $c['id'], - 'spec_req' => array('value' => '', 'required' => false, 'problem' => false), - 'cctype' => $cctype, - 'ccname' => array('value' => '', 'required' => true, 'problem' => false), - 'ccnumb' => array('value' => '', 'required' => true, 'problem' => false), - 'ccexp' => $ccexp, - 'cccode' => array('value' => '', 'required' => true, 'problem' => false), - ); - - } - } - } - - return $this->cd; - } - - /* - * Get sanitized input data and store results in $this->cd - * - * @param $a Array element to store results - this function creates the entries - * @param $f Name of the parameter - * @param $filter Filter(s) to use - * @param $req Flag indicating if it's a required parameter - * @param $opt Optional filter option to use - * @param $id Optional sub-array id - also used as prefix to parameter - * - */ - private function fieldInput($a, $f, $filter, $req, $opt = false, $id = false) - { - // Setup results - $r = array( - 'value' => false, - 'required' => $req, - 'problem' => '' - ); - - // Check for ID prefix - $fname = $f; - if ($id != false) { - $fname = $id."_".$f; - } - - $in = trim(filter_input(INPUT_POST, $fname, $filter, $opt)); - - // If there's been a filter violation - if ($in === false) { - - // Take what's safe - $r['value'] = filter_input(INPUT_POST, $f, FILTER_SANITIZE_STRING); - - // Mark as bad input - $r['problem'] = 'Input is not valid.'; - $this->inputFail = true; - - // If nothing has been supplied - } elseif ($in === null || $in == '') { - - // There's nothing - $r['value'] = ''; - - // If it's required, then say so - if ($req) { - $r['value'] = ''; - $r['problem'] = 'Required input not provided.'; - $this->inputFail = true; - } - - // Otherwise, the input is valid - } else { - - $r['value'] = $in; - $r['problem'] = false; - - } - - // Store results into destination array - if ($id) { - $this->cd[$a][$id][$f] = $r; - } else { - $this->cd[$a][$f] = $r; - } - - } - - /* - * Collect and validate checkout information - * - * @param $cart Array containing cart information - * - * @return object containing array as sub-objects - */ - public function checkoutInput($cart) - { - - // Determine if we're running as an admin user for setting "required" for certain fields. - $admin_user_require = !$_SESSION[GLM_EVENT_SESSION]['AdminUser']; - - /* - * Initialize Destination Cart Data Array - * Set status to false (indicates fail - set to true later if all is Ok) - * This is where we're going to build the returned data - */ - $this->cd = array( - 'contact' => false, // Where contact information goes - 'payment' => false, // Where payment information goes - 'status' => false, // A status flag - 'centralPayment' => false, // Assume no central payment - 'reason' => array() // Reasons we had problems - ); - - // Set input fail to false - calls below will change this if there's a problem - $this->inputFail = false; - - /* - * Check all of the contact information required for checkout - * The checks below supply the various data to the $this->cd['contact'] array. - */ - $this->fieldInput('contact', 'fname', FILTER_SANITIZE_STRING, true); - $this->fieldInput('contact', 'lname', FILTER_SANITIZE_STRING, true); - $this->fieldInput('contact', 'addr1', FILTER_SANITIZE_STRING, $admin_user_require); - $this->fieldInput('contact', 'addr2', FILTER_SANITIZE_STRING, false); - $this->fieldInput('contact', 'city', FILTER_SANITIZE_STRING, $admin_user_require); - $this->cd['contact']['state'] = $this->createStatesArray('state', false, $admin_user_require); - $this->cd['contact']['country'] = $this->createCountriesArray('country', false, $admin_user_require); - $this->fieldInput('contact', 'zip', FILTER_SANITIZE_STRING, $admin_user_require); - $this->fieldInput('contact', 'phone', FILTER_SANITIZE_STRING, true); - $this->fieldInput('contact', 'email', FILTER_VALIDATE_EMAIL, $admin_user_require); - $this->fieldInput('contact', 'email2', FILTER_VALIDATE_EMAIL, $admin_user_require); - $this->fieldInput('contact', 'opt_field_1', FILTER_SANITIZE_STRING, false); - $this->fieldInput('contact', 'opt_field_2', FILTER_SANITIZE_STRING, false); - $this->fieldInput('contact', 'opt_field_3', FILTER_SANITIZE_STRING, false); - - // Also check the contact E-mail address and that they entered it twice properly - if ($this->cd['contact']['email']['value'] != $this->cd['contact']['email2']['value']) { - $this->cd['contact']['email2']['problem'] = 'Email addresses don\'t match.'; - $this->inputFail = true; - } - - // Say whether the user wanted to be contacted with other offers - $this->cd['contact']['email_ok'] = ($_REQUEST['email_ok'] == 'on'); - - /* - * Store the data values (only) collected so far into the session - * in case we come back to checkout for some reason. - * Only store the values, not all the other status data added to the - * $this->cd['contact'] array. - */ - $ci = &$this->cd['contact']; - $_SESSION[GLM_EVENT_SESSION]['ContactInput'] = array( - 'fname' => $ci['fname']['value'], - 'lname' => $ci['lname']['value'], - 'addr1' => $ci['addr1']['value'], - 'addr2' => $ci['addr2']['value'], - 'city' => $ci['city']['value'], - 'state' => $ci['state']['value'], - 'country' => $ci['country']['value'], - 'zip' => $ci['zip']['value'], - 'phone' => $ci['phone']['value'], - 'email' => $ci['email']['value'], - 'email2' => $ci['email2']['value'], - 'email_ok' => $ci['email_ok'], - 'opt_field_1' => $ci['opt_field_1']['value'], - 'opt_field_2' => $ci['opt_field_2']['value'], - 'opt_field_3' => $ci['opt_field_3']['value'] - ); - - // Check if there's central payment in use (if central payment member id is not 0) - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/misc.php'; - $Misc = new EventManagementAdminMisc($this->dbh, $this->config); - $miscDetail = $Misc->getEntry(1); - $cpId = $miscDetail['central_payment_id']; - - /* - * Build payment array for each venue - Main index in cart data is Venue - * Note that $c['id'] is used as an index into the payment array - * The Payment array is empty when we first get here - before any payments have been processed. - * If one payment was processed in a previous checkout attempt but another wasn't, the - * completed payment should be in here. - */ - $centralPaymentAdded = false; - if (!is_array($cart)) { - return false; - } - foreach ($cart as $c) { - - // Note: $c contains full info for a single venue with all selected cart data for it - - // If this payment doesn't exist yet or has not yet been approved - if ( !isset($_SESSION[GLM_EVENT_SESSION]['TicketPayments'][$c['id']]) || - !$_SESSION[GLM_EVENT_SESSION]['TicketPayments'][$c['id']]['approved']) { - - // Create a payment entry under the current venue in our destination data with the current venue id - $this->cd['payment'][$c['id']] = array( - 'id' => $c['id'], - 'type' => false - ); - - /* - * Set the payment type the user selected for this venue - * We currently only have PayPal and Credit card. Will have to restructure this if we - * ever accept any other types of payments (comp codes, pay at event, ...) - */ - - if ( isset($_REQUEST[$c['id'].'_payTypeSelect']) && $_REQUEST[$c['id'].'_payTypeSelect'] == 'no' ) { - - // Check for any special request for this venue and save it along with Payment information - $this->fieldInput('payment', 'spec_req', FILTER_SANITIZE_STRING, false, false, $c['id']); - - $this->cd['payment'][$c['id']]['type'] = 'no'; - - - } elseif ($_REQUEST[$c['id'].'_payTypeSelect'] == 'pp') { - - // PayPal payment selected - - // Check for any special request for this venue and save it along with Payment information - $this->fieldInput('payment', 'spec_req', FILTER_SANITIZE_STRING, false, false, $c['id']); - - $this->cd['payment'][$c['id']]['type'] = 'pp'; - - } else { - - // If central credit card payment - if ($cpId) { - - if (!$centralPaymentAdded) { - - // Get the central payment venu and setup payment entry - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMembers.php'; - $Members = new EventManagementDataMembers($this->dbh, $this->config); - $Members->optionIncludeSelectListData = false; - $cpMembData = $Members->getMemberDetail($miscDetail['central_payment_id']); - - $this->cd['centralPayment'] = array( - 'id' => $miscDetail['central_payment_id'], - 'membData' => $cpMembData - ); - - // Check for any special request for this venue and save it along with Payment information - $this->fieldInput('payment', 'spec_req', FILTER_SANITIZE_STRING, false, false, $cpId); - - /* - * Set the payment type the user selected for this venue - * We currently only have PayPal and Credit card. Will have to restructure this if we - * ever accept any other types of payments (comp codes, pay at event, ...) - */ - - if ($_REQUEST[$cpId.'_payTypeSelect'] == 'pp') { - - // PayPal payment selected - $this->cd['payment'][$cpId]['type'] = 'pp'; - - } else { - - // Credit Card payment selected - $this->cd['payment'][$cpId]['type'] = 'cc'; - - // Collect and verify submitted credit card information - $this->cd['payment'][$cpId]['cctype'] = $this->buildCCTypeArray($cpMembData, true, $cpId); - $this->fieldInput('payment', 'ccname', FILTER_SANITIZE_STRING, true, false, $cpId); - $this->ccnumbInput('payment', 'ccnumb', $this->cd['payment']['cctype']['value'], true, $cpId); - $this->cd['payment'][$cpId]['ccexp'] = $this->buildCCExpArray($required = true, $cpId); - $this->fieldInput('payment', 'cccode', FILTER_SANITIZE_NUMBER_INT, true, false, $cpId); - - } - - } - - $centralPaymentAdded = true; - - } else { - - // Credit Card payment selected - $this->cd['payment'][$c['id']]['type'] = 'cc'; - - // Collect and verify submitted credit card information - $this->cd['payment'][$c['id']]['cctype'] = $this->buildCCTypeArray($c, true, $c['id']); - $this->fieldInput('payment', 'ccname', FILTER_SANITIZE_STRING, true, false, $c['id']); - $this->ccnumbInput('payment', 'ccnumb', $this->cd['payment'][$c['id']]['cctype']['value'], true, $c['id']); - $this->cd['payment'][$c['id']]['ccexp'] = $this->buildCCExpArray($required = true, $c['id']); - $this->fieldInput('payment', 'cccode', FILTER_SANITIZE_NUMBER_INT, true, false, $c['id']); - } - - } - } - - } - - // If everything is OK, set status to true - if (!$this->inputFail) { - $this->cd['status'] = true; - } else { - // Otherwise let the user know there was a problem - $this->cd['reason'][] = 'Please see fields highlighted in red below.'; - } - - return $this->cd; - } - - /* - * Try to process all payments - * - * Return data from processPayment() calls - * - * $res = array - * status Numeric return status code - * 1 Approved - * 2 Bad data supplied - * 3 Communications failure - * 4 Bad response - * 5 Transaction not valid - * 6 Merchant account problem - * 7 Card declined - * statusText Short name of status - * authCode Authorization code - blank if card not accepted - * description Longer description of result - * - * - * @param $cart Array containing cart information - * @param $contact Array containing contact information - * - * @return object containing array as sub-objects - * - * id ID of cart entry (member ID) - * status True if payment successful - * type Type of transaction ('cc' = Credit Card, 'pp' = PayPal) - * statusText Description of status - * authCode Any Authorization code returned - * description Description of action and result - * newApproval This payment has just been made, not on a previous page submission - * spec_req ? - * approved True if Approved - * cctype Card type name - * ccname Card holder name - * ccexp Expiration date - * ccnumb Card number (may be mudged) - * orderID ID of this order - * - */ - public function checkoutProcessPayments($cart, $formData) - { - - // Array that will take list of all payments - $payments = array(); - - // If Central Payment - $grandTotal = 0; - $allPerf = array(); - if ($formData['centralPayment']) { - foreach ($cart as $c) { - - // If this isn't a no payment location - if ($c['payment_gateway']['value'] != 3) { - - // Build complete payment total - $grandTotal += $c['totalPrice_numb']; - - // Build array of all performances - This will be used to build a single order with all venues - if (count($c['performances']) > 0) { - foreach ($c['performances'] as $perf) { - $allPerf[$perf['id']] = $perf; - } - } - } - - } - } - - // Assume the payment can't be processed - $status = false; - - // Get any previous payment data from the session - // Would be there if payment has already been tried and there was a failure - $ticketPayments = $_SESSION[GLM_EVENT_SESSION]['TicketPayments']; - - // For each venue - reset($cart); - foreach ($cart as $c) { - - // Short form for venue/cart entry ID - $id = $c['id']; - - // If Central Payment then set grand total - if ($formData['centralPayment']) { - $c['totalPrice_numb'] = $grandTotal; - } - - // If not Central Payment or this is not the central payment member (i.e. not consignment) - if (!$formData['centralPayment'] || $formData['centralPayment']['id'] == $c['id'] || $formData['payment'][$id]['type'] == 'no') { - - // Check if payment has been completed for this venue - if (isset($ticketPayments[$id]) && $ticketPayments[$id]['status'] == 1) { - - // If so, then we'll just use that - $payments[$id] = $ticketPayments[$id]; - - // Otheriwse, try to process this payment - } else { - - // If this is a credit card purchase - (note PayPal is processed separately) - switch ($formData['payment'][$id]['type']) { - - // No payment required - case 'no': - - $res = array( - 'type' => 'no', - 'status' => 1, - 'statusText' => 'No Payment', - 'authCode' => '000000', - 'description' => 'No Payment Required', - 'spec_req' => $c['paymentForm']['spec_req']['value'], - 'approved' => true, - 'cctype' => '', - 'ccname' => '', - 'ccexp' => '', - 'ccnumb' => '', - 'newApproval' => true - ); - - $status = true; - - break; - - // Credit Card Payment - case 'cc': - - // Build a more concise array with what we need - $payment = array( - 'gateway' => $c['payment_gateway']['value'], // Payment gateway to use - 'name' => $c['name'], // Name of venue - 'charge' => $c['totalPrice_numb'], // Total charges this venue - 'cctype' => $formData['payment'][$id]['cctype']['name'], // Card Type - 'ccname' => $formData['payment'][$id]['ccname']['value'], // Name on Card - 'ccnumb' => $formData['payment'][$id]['ccnumb']['value'], // Card Number - 'ccexp' => $formData['payment'][$id]['ccexp']['value'], // Expriation Date - 'cccode' => $formData['payment'][$id]['cccode']['value'], // CCV - security code - 'invoice' => $_SESSION[GLM_EVENT_SESSION]['SessionID'] // Invoice # is session ID (or some part thereof) - ); - - // Load selected payment processor and initialize - switch ($payment['gateway']) { - - case $this->config->ccard_processor_numb->no_payment: - - $account = array(); - - // load and initialize - No account data required - require_once COMMON_APP_BASE.'CommonAbstracts/'.$this->config->paymentProcessorsLocation.'/None/no_payment.php'; - $Processor = new NoPaymentGateway(); - - break; - - case $this->config->ccard_processor_numb->authorize_net: - - // Get account data - $account = array( - 'login' => $c['gateway_par1'], - 'key' => $c['gateway_par2'], - 'test' => $c['gateway_par3']['value'], - 'conf' => $c['gateway_par4']['value'], - 'email' => $c['gateway_par5'] - ); - - // load and initialize - require_once COMMON_APP_BASE.'CommonAbstracts/'.$this->config->paymentProcessorsLocation.'/Authorize.Net/AuthorizeNet.php'; - $Processor = new AuthorizeNetPaymentGateway($account); - - break; - - case $this->config->ccard_processor_numb->merchant_solutions: - - // Get account data - $account = array( - 'acctid' => $c['gateway_par1'], - 'merchantpin' => $c['gateway_par2'], - 'test' => $c['gateway_par3']['value'], - 'conf' => $c['gateway_par4']['value'], - 'email' => $c['gateway_par5'] - ); - - // load and initialize - require_once COMMON_APP_BASE.'CommonAbstracts/'.$this->config->paymentProcessorsLocation.'/MerchantSolutions/MerchantSolutions.php'; - $Processor = new MerchantSolutionsPaymentGateway($account); - - break; - - case $this->config->ccard_processor_numb->test: - - $account = array(); - - // load and initialize - No account data required - require_once COMMON_APP_BASE.'CommonAbstracts/'.$this->config->paymentProcessorsLocation.'/Test/Test.php'; - $Processor = new TestPaymentGateway(); - - break; - - } - - // Send payment request to payment processor - Use contact information in session - $res = $Processor->processPayment($payment, $_SESSION[GLM_EVENT_SESSION]['ContactInput']); - - // Assume we don't have a new approval - $res['newApproval'] = false; - - // If payment was successful - update the result with a mudged card number - if ($res['status'] == 1) { - - $status = true; - - $res['spec_req'] = $c['paymentForm']['spec_req']['value']; - $res['approved'] = true; - $res['cctype'] = $payment['cctype']; - $res['ccname'] = $payment['ccname']; - $res['ccexp'] = $payment['ccexp']; - $res['ccnumb'] = '**** **** **** '.substr($payment['ccnumb'], -4); - $res['newApproval'] = true; - - } - - // Add transaction type to result - $res['type'] = 'cc'; - - break; - - } // case payment type - - // If the transaction was successful - if ($status) { - - // If Central Payment, put all performances into this order - if ($formData['centralPayment']) { - $c['performances'] = $allPerf; - } - - // Store the purchase - $orderID = $this->storePurchase($c, $res); - - if ($orderID == false) { - - // Oops, some kind of failure to store purchase. Send Chuck a message - $message = "Event Management System V3\n\n" - ."Failure to store customer purchase - checkoutProcessPayments()\n\n" - ."Contact:\n\n".print_r($contact,1)."\n\n" - ."Cart:\n\n".print_r($c,1)."\n\n" - ."Result:\n\n".print_r($res,1)."\n\n" - ."Payment:\n\n".print_r($payment,1)."\n\n" - ."Gateway Account:\n\n".print_r($account,1)."\n\n"; - mail( - 'cscott@gaslightmedia.com', - 'Event Management V3 Error: Failure to store purchase', - $message, $headers = '', $parameters = '' ); - - } - - $res['orderID'] = $orderID; - - // Add venue id to payment result - $res['id'] = $c['id']; - - // Pass entire SQL Transaction back. If checkout debug isn't enabled this will simply be false; - $res['sqlTransaction'] = $this->sqlTransaction; - - } - - // Add payment information to the payments array - $payments[$c['id']] = $res; - - } // if payment not already processed - - } // if not central payment or member ID is the same as the central payment id - - } // For each venue - - return array( - 'payments' => $payments, - 'status' => $status - ); - - } - - /* - * Attempt to store purchase - * - * @param $c Array of a single venue from the cart - Payment must have been successful - * @return object containing array as sub-objects - */ - public function storePurchase($c, $res) - { -// echo "
    ".print_r($c,1)."
    ";exit; - - // Start transaction array - $transaction = array(); - - // Get contact information from the session - $contact = $_SESSION[GLM_EVENT_SESSION]['ContactInput']; - - // Create unique session ID (extended with Date state to ensure it's unique) - $sid = $_SESSION[GLM_EVENT_SESSION]['SessionID'].'-'.time(); - - // Get optional checkout field prompts to store with order - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/misc.php'; - $Misc = new EventManagementAdminMisc($this->dbh, $this->config); - $miscConfigDetail = $Misc->getEntry(1); - - $user_trace = - $_SERVER["REMOTE_ADDR"]." - " - .date("m/d/Y H:i:s"); - - $pmt = $c['paymentForm']; - $specialNeeds = $res['spec_req']; // **** NEED TO GET THIS INTO CART - - $transaction[] = " - INSERT INTO eventmgt.ticket_order - ( - user_trace_info, - fname, - lname, - addr1, - addr2, - city, - state, - zip, - country, - phone, - email, - email_ok, - opt_field_1_name, - opt_field_1, - opt_field_2_name, - opt_field_2, - opt_field_3_name, - opt_field_3, - purchase_date, - member, - cctype, - ccnumber, - expire, - ccname, - ccconf, - charge_total, - special_needs, - notes, - session_id - ) - VALUES - ( - '$user_trace', - '".$contact['fname']."', - '".$contact['lname']."', - '".$contact['addr1']."', - '".$contact['addr2']."', - '".$contact['city']."', - '".$contact['state']."', - '".$contact['zip']."', - '".$contact['country']."', - '".$contact['phone']."', - '".$contact['email']."', - ".($contact['email_ok'] ? 'true' : 'false').", - '".addslashes($miscConfigDetail['opt_field_1_name'])."', - '".$contact['opt_field_1']['value']."', - '".addslashes($miscConfigDetail['opt_field_2_name'])."', - '".$contact['opt_field_2']['value']."', - '".addslashes($miscConfigDetail['opt_field_3_name'])."', - '".$contact['opt_field_3']['value']."', - 'today', - ".$c['id'].", - '".$res['cctype']."', - '".$res['ccnumb']."', - '".$res['ccexp']."', - '".$res['ccname']."', - '".$res['authCode']."', - ".$c['totalPrice_numb'].", - '".$specialNeeds."', - '', - '".$sid."' - ); - "; - - // For each ticket date - $ticketSequence = 0; - foreach ($c['performances'] as $p) { - - // Do a last validation on likely date - $likelyDate = date('m/d/Y', strtotime($c['likelyDate'])); - if ($likelyDate == '12/31/1969') { - $likelyDate = ''; - } - - // For each performance - foreach ($p['dates'] as $d) { - - // For each Section - foreach ($d['sections'] as $s) { - - // For each ticket type - foreach ($s['tickets'] as $t) { - - // If this ticket is type "package", get package contents for use below. - $isPackageTicket = false; - if ($this->config->option->tickets && $t['ticket_type']['value'] == 20) { - - // get the package contents - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); - $packageData = $TicketPackages->getPackageList("package = ".$t['id']); - $isPackageTicket = true; - - } - - // For each individual ticket - for ($i=1 ; $i<=$t['selected'] ; $i++) { - - // Check for empty date - Non date specific ticket - $tDate = "'".$d['date']."'"; - if ($d['date'] == '') { - $tDate = 'null'; - } - - // Build text with any policies - $policies = ''; - if (!empty($c['def_ticket_policy'])) { - $policies = $this->config->term->prop->cap." ".$this->config->term->ticket->norm - ." policy:\n".$c['def_ticket_policy']."\n\n"; - } - if (!empty($p['policy'])) { - $policies .= $this->config->term->performance->cap - ." policy:\n".$p['policy']."\n\n"; - } - if (!empty($policies)) { - $policies = addslashes($policies); - } - - // Create a unique package sold ID to link the package ticket with the package contents sold ({ticketID}-{sessionID}-{timestamp}) - $packageSoldID = $sid.'-'.++$ticketSequence; - - // If this is not a package, create a ticket_sold record - note that ticket_order number will be updated later - $transaction[] = " - INSERT INTO eventmgt.ticket_sold - ( - ticket_order, - member, - member_name, - assigned, - assigned_from, - assigned_from_name, - performance, - performance_name, - entrance, - entrance_name, - entrance_color, - section, - section_name, - ticket, - ticket_name, - is_package, - package_sold_id, - ticket_package, - package_name, - date_specific, - ticket_date, - time_specific, - ticket_time, - start_date, - end_date, - likely_date, - price_paid, - voucher_type, - voucher_text, - policies, - unlimited_use, - numb_uses, - numb_claimed, - time_claimed, - session_id - ) - VALUES - ( - (SELECT currval('eventmgt.ticket_order_id_seq')), - ".$c['id'].", - '".$c['name']."', - ".($c['assigned'] ? 'true' : 'false').", - ".($c['assigned'] ? $c['assigned_from'] : 'NULL').", - '".($c['assigned'] ? $c['assigned_from_name'] : '')."', - ".$p['id'].", - '".$p['name']."', - ".(!empty($s['entrance']) ? $s['entrance'] : 'NULL').", - '".$s['entranceDetail']['name']."', - '".$s['entranceDetail']['color']['name']."', - ".$s['id'].", - '".$s['name']."', - ".$t['id'].", - '".$t['title']."', - ".($isPackageTicket ? 'true' : 'false').", - '$packageSoldID', - NULL, - '', - ".($t['date_specific']['value'] ? 'true' : 'false').", - $tDate, - ".($t['time_specific']['value'] ? 'true' : 'false').", - '".$t['ticket_timestamp']."', - ".(!empty($t['start_date']['date']) ? "'".$t['start_date']['date']."'" : 'NULL').", - ".(!empty($t['end_date']['date']) ? "'".$t['end_date']['date']."'" : 'NULL').", - ".(!empty($likelyDate) ? "'".$likelyDate."'" : 'NULL').", - ".$t['price_numb'].", - ".$t['voucher_type']['value'].", - '".$t['voucher_text']."', - '$policies', - ".($t['unlimited_use']['value'] ? 'true' : 'false').", - ".$t['uses'].", - 0, - null, - '".$sid."' - ); - "; - - // If this is a package, get package contents and save that as separate tickets sold. - if ($isPackageTicket) { - - reset ($packageData); - foreach ($packageData as $p) { - - // Get information on this package ticket - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; - $Tickets = new EventManagementDataTickets($this->dbh, $this->config); - $pt = $Tickets->getTicketDetail($p['ticket']); - - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSections.php'; - $Sections = new EventManagementDataSections($this->dbh, $this->config); - $ps = $Sections->getSectionDetail($pt['section_id']); - - // Get Entrance information for this ticket's section - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataEntrances.php'; - $Entrances = new EventManagementDataEntrances($this->dbh, $this->config); - $pe = $Entrances->getEntranceDetail($ps['entrance']); - - - $transaction[] = " - INSERT INTO eventmgt.ticket_sold - ( - ticket_order, - member, - member_name, - assigned, - assigned_from, - assigned_from_name, - performance, - performance_name, - entrance, - entrance_name, - entrance_color, - section, - section_name, - ticket, - ticket_name, - is_package, - package_sold_id, - ticket_package, - package_name, - date_specific, - ticket_date, - time_specific, - ticket_time, - start_date, - end_date, - likely_date, - price_paid, - voucher_type, - voucher_text, - policies, - unlimited_use, - numb_uses, - numb_claimed, - time_claimed, - session_id - ) - VALUES - ( - (SELECT currval('eventmgt.ticket_order_id_seq')), - ".$pt['member'].", - '".$pt['member_name']."', - false, - NULL, - '', - ".$pt['performance_id'].", - '".$pt['performance']."', - ".(!empty($pt['section_id']) ? $pt['section_id'] : 'NULL').", - '".$pe['name']."', - '".$pe['color']['name']."', - ".$ps['id'].", - '".$ps['name']."', - ".$pt['id'].", - '".$pt['title']."', - false, - '$packageSoldID', - ".$t['id'].", - '".$t['title']."', - false, - NULL, - false, - '".$pt['ticket_timestamp']."', - ".(!empty($pt['start_date']['date']) ? "'".$pt['start_date']['date']."'" : 'NULL').", - ".(!empty($pt['end_date']['date']) ? "'".$pt['end_date']['date']."'" : 'NULL').", - NULL, - 0, - ".$pt['voucher_type']['value'].", - '".$pt['voucher_text']."', - '', - ".($pt['unlimited_use']['value'] ? 'true' : 'false').", - ".$pt['uses'].", - 0, - null, - '".$sid."' - ); - "; - - - } - - } - - // Check for any add-ons included - if (isset($t['addons']) && count($t['addons']) > 0) { - - // For each add-on for this ticket - foreach ($t['addons'] as $a) { - - // If there's a quantity selected - if ($a['selected'] > 0) { - - $transaction[] = " - INSERT INTO eventmgt.add_on_sold - ( - ticket_order, - ticket_sold, - add_on_name, - add_on_type, - add_on_type_name, - unit_name, - unit_price, - quant, - price_paid, - session_id - ) - VALUES - ( - (SELECT currval('eventmgt.ticket_order_id_seq')), - (SELECT currval('eventmgt.ticket_sold_id_seq')), - '".$a['name']."', - ".$a['add_on_type']['value'].", - '".$a['add_on_type']['nameEsc']."', - '".$a['unit_name']."', - ".$a['unit_cost_numb'].", - ".$a['selected'].", - ".($a['unit_cost_numb'] * $a['selected']).", - '".$sid."' - ); - "; - - } // quant selected - } // each add-on - } // have add-ons - - // Check for any promos included - if (isset($t['promo']) && $t['promo']['credit_numb'] < 0) { - - $transaction[] = " - INSERT INTO eventmgt.promo_sold - ( - ticket_order, - ticket_sold, - promo, - promo_name, - promo_type, - promo_type_name, - amount, - session_id - ) - VALUES - ( - (SELECT currval('eventmgt.ticket_order_id_seq')), - (SELECT currval('eventmgt.ticket_sold_id_seq')), - ".$t['promo']['promo'].", - '".$t['promo']['promo_name']."', - ".$t['promo']['promo_type'].", - '".$t['promo']['promo_type_name']."', - ".$t['promo']['credit_each'].", - '".$sid."' - ); - "; - - } // promo - - } // each individual ticket - - // Update inventory - $availDecr = ''; - if (!$t['unlimited_quant']) { - $availDecr = "available = available - ".$t['selected'].","; - } - $transaction[] = " - UPDATE eventmgt.ticket_inventory - SET $availDecr - sold = sold + ".$t['selected']." - WHERE id = ".$t['invID']." - "; - - } // Each ticket type (inventory ID) - - } // Each section - - } // Each performance - - } // Each ticket date - - // Add SQL to clear holds - $transaction[] = "DELETE FROM eventmgt.inven_hold WHERE session_id = '".$sid."';"; - - // Attempt to process as a transaction - If checkout testing is not enabled. - if (!$this->config->option->checkout_testing) { - try { - $this->dbh->beginTransaction(); - foreach ($transaction as $sql) { - $this->dbh->exec($sql); - } - $this->dbh->commit(); - } catch (Exception $e) { - $this->dbh->rollBack(); - $error_msg = $e->getMessage(); - - $trouble_email .= "Error storing request: $error_msg\n\n".print_r($checkout_sql, 1)."\n\n"; - - $this->debug_mail( - 'cscott@gaslightmedia.com', - 'Event Management V3 - Check-Out SQL Failure', - "Event Management V3 - Check-Out SQL Failure\n\n" - ."Error Msg: ".$error_msg."\n\n" - .print_r($sql,1)."\n\n" - ."Entire Transaction:\n\n".print_r($transaction,1), - '' - ); - - // Say we couldn't store the order - return false; - } - - // Get order numbers and assign to proper cart entries - $sql = " - SELECT id - FROM eventmgt.ticket_order - WHERE session_id = '".$sid."' - AND member = ".$c['id']." - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $order = $stmt->fetch(PDO::FETCH_ASSOC); - - // Say we were able to store the order just fine - return $order['id']; - - } else { - // When checkout testing send the entire transaction to the debug page rather than execute it. - $this->sqlTransaction = $transaction; - } - - } - - /** - * Credit Card Number Input and Validation - * - * @param string $a Array element to store results - this function creates the entries - * @param string $f Name of the parameter - * @param string $cctype Selected card type - * @param string $ccnumb Card Number - * @param bool $req Required field flag - * - * @return array Array containing status and possible message - */ - private function ccnumbInput($a, $f, $cctype, $req, $id) - { - // Check for ID prefix - $fname = $f; - if ($id != false) { - $fname = $id."_".$f; - } - - // Get the card number - $in = preg_replace("/[^0-9.]/", "", trim(filter_input(INPUT_POST, $fname, FILTER_SANITIZE_NUMBER_INT))); - - // Always pass GLM test card number - last digit controls auth response - see classes/paymentProcessors/Test.php - if (substr($in,0,15) == '001100110011001') { - - $match = true; - - // Otherwise we're going to check the card number against the specified card type - } else { - - // Get the matching pattern for the supplied card type - $pattern = $this->config->ccverify->{$cctype}; - - // If we have a pattern then we have a valid card type, so try a match, otherwise it's just false - $match = false; - if ($pattern != '') { - $match = preg_match('/'.$pattern.'/', $in); - } - - } - - // Check the result - if (!$match) { - $problem = 'Card number does not appear to be correct for the selected card type.'; - $this->inputFail = true; - } - - // Setup results - $r = array( - 'value' => $in, - 'required' => $req, - 'problem' => $problem - ); - - // Store results into destination array - if ($id) { - $this->cd[$a][$id][$f] = $r; - } else { - $this->cd[$a][$f] = $r; - } - - } - - /** - * Create credit card type selection array - * - * array( - * 'value' = {selected card name if selected}, - * 'required' = {field is required flag}, - * 'problem' = {Problem description or empty string}, - * 'cccards' = array( - * {month#} => array( - * 'month' => {month#}, - * 'name' => {name of month}, - * 'selected' = {bool} - * ) - * ) - * ) - * - * @param $c Array of credit cards for venue with accepted flags - * @param $required Field is required flag - * @param $venue ID number of venue - * @param $cctype Supplied value of cctype or false if not supplied - * @param $init If set don't expect a value - * - * @return object containing array as sub-objects - */ - private function buildCCTypeArray($c, $required = false, $venue = false, $cctypeVal = false, $init = false) - { - - // Build credit cards accepted array - $cctype = array( - 'value' => '', - 'name' => '', - 'required' => $required, - 'problem' => '', - 'ccards' => array() - ); - - // If card is not specified in the function call, check for input value - if ($cctypeVal == false && isset($_REQUEST[$venue.'_cctype'])) { - $cctypeVal = (string) $_REQUEST[$venue.'_cctype']; - } - - // Scan card types for accepted by venue - foreach ($c['cards_accepted']['bitmap'] as $ca) { - - // If the card is selected for this venue - if ($ca['default']) { - - // Check if this is the selected card - $selected = false; - - // Make sure cctypeVal is not '' since 0 may be a valid card index - if ($cctypeVal != '' && $ca['value'] == $cctypeVal) { - $cctype['value'] = $ca['value']; - $cctype['name'] = $ca['name']; - $selected = true; - } - - // Add it to the array - $cctype['ccards'][$ca['value']] = array( - 'name' => $ca['name'], - 'value' => $ca['value'], - 'selected' => $selected - ); - } - } - - // Check if required value was not supplied - if (!$init && $required && $cctype['value'] === '') { - $cctype['problem'] = 'Required value not supplied'; - $this->inputFail = true; - } - - return $cctype; - - } - - /** - * Create arrays for credit card expiration picks - * - * array( - * 'value' = {text value of expiration if set - i.e. 05/2013}, - * 'required' = {field is required flag}, - * 'problem' = {Problem description or empty string}, - * 'ccmonths' = array( - * {month#} => array( - * 'month' => {month#}, - * 'name' => {name of month}, - * 'selected' = {bool} - * ) - * ), - * 'ccyears' = array( - * {year} => array( - * 'year' => {year - 4 digits}, - * 'selected' => {bool} - * ) - * ) - * - * @return object containing array as sub-objects - */ - private function buildCCExpArray($required = false, $venue = false, $ccmonth = false, $ccyear = false, $init = false) - { - - $monthNames = array( - 1 => 'January', - 2 => 'February', - 3 => 'March', - 4 => 'April', - 5 => 'May', - 6 => 'June', - 7 => 'July', - 8 => 'August', - 9 => 'September', - 10 => 'October', - 11 => 'November', - 12 => 'December' - ); - - $ccexp = array( - 'value' => '', - 'required' => $required, - 'problem' => '', - 'ccmonths' => array(), - 'ccyears' => array() - ); - - // If no month or specified in the function call, check for input values - if ($ccmonth == false && isset($_REQUEST[$venue.'_ccmonth'])) { - $ccmonth = ($_REQUEST[$venue.'_ccmonth'] - 0); - } - if ($ccyear == false && isset($_REQUEST[$venue.'_ccyear'])) { - $ccyear = ($_REQUEST[$venue.'_ccyear'] - 0); - } - - // Build months list - $monthSelected = false; - for ($m=1 ; $m<=12 ; $m++) { - $selected = ($m == $ccmonth); - $ccexp['ccmonths'][$m] = array( - 'month' => $m, - 'name' => $monthNames[$m], - 'selected' => $selected - ); - if ($selected) { - $monthSelected = true; - } - } - - // If the supplied month didn't match anything, make sure it's set to false - if (!$monthSelected) { - $ccmonth = false; - } - - // Build years list - $yearSelected = false; - for ($y=date('Y') ; $y<=date('Y',strtotime('now +10 years')) ; $y++) { - $selected = ($y == $ccyear); - $ccexp['ccyears'][$y] = array( - 'year' => $y, - 'selected' => $selected - ); - if ($selected) { - $yearSelected = true; - } - } - - // If this is an initialization of the field, then no validity checks - if ($init) { - return $ccexp; - } - - // If the supplied year didn't match anything, make sure it's set to false - if (!$yearSelected) { - $ccyear = false; - } - - // If there's a month and year, set the expriation value - if ($ccmonth != false && $ccyear != false) { - $ccexp['value'] = "$ccmonth/$ccyear"; - } - - // Check if required value was not supplied - if (!$init && $required && $ccexp['value'] == '') { - $ccexp['problem'] = 'Required value not supplied'; - $this->inputFail = true; - return $ccexp; - } - - // Check if supplied value is not in the past - $endOfExpMonth = strtotime("$ccmonth/1/$ccyear +1 month -1 day"); - if (time() > $endOfExpMonth) { - $ccexp['problem'] = 'Expiration date has passed.'; - $this->inputFail = true; - return $ccexp; - } - - return $ccexp; - } - - /** - * Build States array for use in pick-lists - * - * @param array $states Array of states - * @param string $selected State code of selected state - * @param boolean $required Is a required parameter - * @param boolean $checkProblem Set to false to prevent triggering problem output on initial setup - * - * @return array Array of states with 'stateID', 'stateName', 'stateSelected' - * @access public - */ - private function createStatesArray($name, $selected = '', $required = false, $checkProblem = true) - { - - $states = $this->config->states->toArray(); - - $value = false; - $problem = ''; - - // If nothing has been provided, check for URI input - if ($selected == '' || $selected == false) { - if (isset($_REQUEST[$name]) && $_REQUEST[$name] != '') { - $selected = $_REQUEST[$name]; - } - } - - $r = array(); - while (list($key, $val) = each($states)) { - $r[$key] = array( - 'stateID' => $key, - 'stateName' => $val, - 'stateSelected' => '' - ); - - if ($key == $selected) { - $r[$key]['stateSelected'] = 'selected'; - $value = $key; - $name = $val; - } - } - - // Check for required - if ($required && $value == false && $checkProblem) { - $problem = 'Required but not selected.'; - $this->inputFail = true; - } - - $r = array( - 'value' => $value, - 'name' => $name, - 'required' => $required, - 'problem' => $problem, - 'states' => $r - ); - - return $r; - } - - /** - * Build Countries array for use in pick-lists - * - * @param array $countries Array of countries - * @param string $selected Country code of selected country - * @param boolean $required Required parameter - * @param boolean $checkProblem Set to false to keep from triggering problem on initial setup - * - * @return array Array of countries with 'countryID', 'countryName', 'countrySelected' - * @access public - */ - private function createCountriesArray($name, $selected = '', $required = false, $checkProblem = true) - { - - $countries = $this->config->countries->toArray(); - - $value = false; - $problem = ''; - - // If nothing has been provided, check for URI input - if ($selected == '' || $selected == false) { - if (isset($_REQUEST[$name]) && $_REQUEST[$name] != '') { - $selected = $_REQUEST[$name]; - } - } - - $r = array(); - while (list($key, $val) = each($countries)) { - $r[$key] = array( - 'countryID' => $key, - 'countryName' => $val, - 'countrySelected' => '' - ); - - if ($key == $selected) { - $r[$key]['countrySelected'] = 'selected'; - $value = $key; - $name = $val; - } - } - - // Check for required - if ($required && $value == false && $checkProblem) { - $problem = 'Required but not selected.'; - $this->inputFail = true; - } - - return array( - 'value' => $value, - 'name' => $name, - 'required' => $required, - 'problem' => $problem, - 'countries' => $r - ); - } - - /** - * If debug for mail turned on, display E-Mail messages rather than send them - * - * @access public - */ - public function debug_mail( $to, $subject, $message, $headers = '', $parameters = '' ) - { - if( $this->config->debug->mail ) - { - echo '

    - - - - - - - -
    MAIL DEBUG
    Recipient(s): '.$to.'
    Subject: '.$subject.'
    Headers:
    '.$headers.'
    Parameters:
    '.$parameters.'
    '.$message.'
    -

    - '; - return( true ); - } else { - return( mail( $to, $subject, $message, $headers, $parameters ) ); - } - } - - - -} - -?> \ No newline at end of file diff --git a/legacy/models/front/classes/support.php b/legacy/models/front/classes/support.php deleted file mode 100644 index 46f2df4..0000000 --- a/legacy/models/front/classes/support.php +++ /dev/null @@ -1,1589 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/support.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -/** - * EventManagementFrontSupport class - * - * Event Management and Reservations System - Admin Code - Contacts ticket - * - * PHP version 5 - * - * @category Event Management Admin Tickets - * @package EventManagement - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: classes/support.php,v 1.0 2011/01/25 19:31:47 cscott Exp $ - * @link <> - */ - -class EventManagementFrontSupport -{ - - /** - * Configuration information object - * @var $ini - * @access public - */ - protected $config; - /** - * Database Object - * @var $dbh - * @access public - */ - protected $dbh; - - function __construct($dbh, $config) - { - - $this->dbh = $dbh; - $this->config = $config; - - } - - /** - * Get list of active members - * - * @return object containing array as sub-objects - */ - public function getMembersList($option = 'all') - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMembers.php'; - $Members = new EventManagementDataMembers($this->dbh, $this->config); - $Members->optionIncludeSelectListData = false; - $membersList = $Members->getMembersList($option); - return $membersList; - } - - /** - * Get list of entrances for a specific member - * - * @return object containing array as sub-objects - */ - public function getEntrancesList($memberID) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataEntrances.php'; - $Entrances = new EventManagementDataEntrances($this->dbh, $this->config); - $Entrances->optionIncludeSelectListData = false; - $entrancesList = $Entrances->getEntrancesList($memberID); - return $entrancesList; - } - - /** - * Get information on a specific entrance - * - * @return object containing array as sub-objects - */ - public function getEntranceData($entranceID) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataEntrances.php'; - $Entrances = new EventManagementDataEntrances($this->dbh, $this->config); - $Entrances->optionIncludeSelectListData = false; - $entranceDetail = $Entrances->getEntranceDetail($entranceID); - return $entranceDetail; - } - - /** - * Get information on a specific venue/member - * - * @return object containing array as sub-objects - */ - public function getMemberData($memberID = false) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataMembers.php'; - $Members = new EventManagementDataMembers($this->dbh, $this->config); - $Members->optionIncludeSelectListData = false; - $memberDetail = $Members->getMemberDetail($memberID); - return $memberDetail; - } - - /** - * Get all information / tickets for a performance - * Organize for ticket selection on front end. - * - * This function returns detail about the performance, - * a list of sections, with a list of tickets under each, - * and a list of ticket inventory by ticket ID. The latter - * is sent to the front-end scripts as a JSON for interactive - * date and quantity selection. - * - * If the optional section ID is not provided, then all sections - * for the performance that have tickets will be included. - * - * @param $perfID integer A required performance ID - * @param $sectionID integer An optional sectionID - * - * @return object containing array of ... - * array( - * 'performanceDetail', - * 'sections', - * 'inventory' - * ); - */ - public function getAllPerformanceData($perfID = 0, $sectionID = 0) - { - - $sections = array(); - $inventory = array(); - $oneSectionOnly = false; - $havePerformanceTickets = false; - - // Check supplied Performance ID - if ($perfID == 0) { - $this->reason[] = 'No '.$this->config->term->event->norm.' has been selected.'; - return false; - } else { - - // Get selected performance data - $performanceDetail = $this->getPerformanceData($perfID); - - // If we can't find the performance - if (!$performanceDetail) { - $this->reason[] = 'We were unable to find the selected '.$this->config->term->event->norm.'.'; - } else { - - // If a specific section is provided, then only do that section - $where = false; - if ($sectionID > 0) { - $where = "T.id = $sectionID"; - } - - // Get sections list for this member - $sectionsList = $this->getSectionList($performanceDetail['member_id'], $where); - - // If there's only one, then note that for the template - if ($sectionsList && count($sectionsList) == 1) { - $oneSectionOnly = true; - } - - // for each of the sections, get the performance data and tickets - foreach ($sectionsList as $section) { - - $sectID = $section['id']; - - // Get selected section data. We'll add this later if there's tickets found - $sectionDetail = $this->getSpecifiedSectionDetail($sectID); - - // Get Ticket List for this performance and in the current section - $ticketList = $this->getSectionTicketList($perfID, $sectID); - - // If no tickets found for this performance and section - if (!$ticketList) { - $this->reason[] = 'We were unable to find any '.$this->config->term->ticket->plur.' for this '.$this->config->term->event->norm.'.'; - } else { - - $havePerformanceTickets = true; - - // Add this section to our sections list - $sections[$sectID] = array(); - $sections[$sectID]['sectionDetail'] = $sectionDetail; - - // Add ticket data to this section - $sections[$sectID]['ticketsData'] = array(); - reset($ticketList); - foreach ($ticketList as $t) { - $sections[$sectID]['ticketsData'][$t['id']] = $t; - } - - // Assemble data for each ticket (date, quant, etc) - $ticketsData = array(); - reset($ticketList); - while (list($k, $v) = each($ticketList)) { - - // Get inventory for this ticket - $inventoryList = $this->getInventoryList($v['id'], 'T.active', true); - - $haveFutureInventory = false; - - // For each inventory item - $invData = array(); - - // If no inventory found for this ticket - if (!$inventoryList) { - - $this->reason[] = 'We were unable to find inventory for the selected '.$this->config->term->ticket->norm.'.'; - } else { - - foreach ($inventoryList as $inv) { - - // Check for bogus inventory - if (($v['date_specific']['value'] == 1 && $inv['ticket_date']['date'] != '') || - ($v['date_specific']['value'] != 1 && $inv['ticket_date']['date'] == '')) { - - $invDate = $inv['ticket_date']['date']; - - // Check if date in the future - if ($inv['ticket_date']['timestamp'] > strtotime('yesterday')) { - $haveFutureInventory = true; - } - - // Trim unwanted data - unset($inv['ticket_name']); - unset($inv['ticket_id']); - - // Determine if any of the dates are too late to buy on-line. - // If no timestamp then it's not a date-specific ticket, so no purchase leadtime issue. - if ($inv['ticket_date']['timestamp']) { - $inv['tooLate'] = (time() > strtotime($k2) - ($performanceDetail['purch_leadtime']*3600) ); - } else { - $inv['tooLate'] = false; - } - - // Check for unlimited quantities - if ($inv['unlimited_quant']) { - $inv['available'] = $this->config->option->tickets_select_max; - } - - $invData[$invDate] = $inv; - - } - } - } - - // Add ticket ID, date specific flag, and inventory list to our inventory array - $inventory[$v['id']] = array( - 'id' => $v['id'], - 'haveFutureInventory' => $haveFutureInventory, - 'dateSpecific' => $v['date_specific']['value'], - 'startDate' => $v['start_date']['date'], - 'endDate' => $v['end_date']['date'], - 'inventory' => $invData - ); - - // Check for ticket add-ons - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataAddons.php'; - $Addons = new EventManagementDataAddons($this->dbh, $this->config); - $ticketAddonsList = $Addons->getAddonsList($v['id']); - if ($ticketAddonsList) { - foreach($ticketAddonsList as $ta) { - $ta['selected'] = 0; - $sections[$sectID]['ticketsData'][$v['id']]['addons'][$ta['id']] = $ta; - } - } - - // Check for package data - if ($this->config->option->packages && $v['ticket_type']['value'] == 20) { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); - $packageData = $TicketPackages->getPackageList("package = ".$v['id']); - $sections[$sectID]['ticketsData'][$v['id']]['packageData'] = $packageData; - } - - // Determine if tickets may or may not be purchased at this time - $mayBuyNow = true; - $tooEarlyToBuy = false; - if ($v['for_sale_start_date']['date'] != null && $v['for_sale_start_date']['date'] != '') { - if (time() < $v['for_sale_start_date']['timestamp']) { - $tooEarlyToBuy = true; - $mayBuyNow = false; - } - } - $tooLateToBuy = false; - if ($v['for_sale_end_date']['date'] != null && $v['for_sale_end_date']['date'] != '') { - if (time() > strtotime($v['for_sale_end_date']['date'].' +1 day')) { - $tooLateToBuy = true; - $mayBuyNow = false; - } - } - $sections[$sectID]['ticketsData'][$v['id']]['mayBuyNow'] = $mayBuyNow; - $sections[$sectID]['ticketsData'][$v['id']]['tooEarlyToBuy'] = $tooEarlyToBuy; - $sections[$sectID]['ticketsData'][$v['id']]['tooLateToBuy'] = $tooLateToBuy; - - } // each ticket - - } // Have tickets - - } // For each section for this member - - } // Have performance data - - } // Have performance ID - - if (!$havePerformanceTickets) { - return false; - } - - // Assemble return data array - $perfData = array( - 'oneSectionOnly' => $oneSectionOnly, // Flag that indicates if we have more than one section listed - 'performanceDetail' => $performanceDetail, // Detail about requested Performance - 'sections' => $sections, // Array of sections with section detail and ticket data - 'inventory' => $inventory // Array of ticket inventory - - ); - - return $perfData; - - } - - - /** - * Get information on a specific performance based on performance selected in URI or session - * - * @return object containing array as sub-objects - */ - public function getPerformancesList($memberID, $listType = 'member') - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPerformances.php'; - $Performances = new EventManagementDataPerformances($this->dbh, $this->config); - $Performances->optionIncludeSelectListData = false; - $performancesList = $Performances->getPerformancesList($listType, $memberID, $_SESSION[GLM_EVENT_SESSION]['AdminUser']); - return $performancesList; - } - - /** - * Get information on a specific performance based on performance selected in URI or session - * - * @return object containing array as sub-objects - */ - public function getPerformanceData($perfID = false) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPerformances.php'; - $Performances = new EventManagementDataPerformances($this->dbh, $this->config); - $Performances->optionIncludeSelectListData = false; - $performanceDetail = $Performances->getPerformanceDetail($perfID); - return $performanceDetail; - } - - /** - * Get information on sections for a member - * - * @var $id ID of member - * @return object containing array as sub-objects - */ - public function getSectionList($memberID = false, $where = false) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSections.php'; - $Sections = new EventManagementDataSections($this->dbh, $this->config); - $Sections->optionIncludeSelectListData = false; - $sectionsList = $Sections->getSectionsList($memberID, $where); - return $sectionsList; - } - - /** - * Get information on a specific section - * - * @var $id ID of section - * @return object containing array as sub-objects - */ - public function getSpecifiedSectionDetail($sectionID = false) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataSections.php'; - $Sections = new EventManagementDataSections($this->dbh, $this->config); - $Sections->optionIncludeSelectListData = false; - $sectionsDetail = $Sections->getSectionDetail($sectionID); - return $sectionsDetail; - } - - /** - * Get section ticket list - * - * @var $id ID of section - * @return object containing array as sub-objects - */ - public function getSectionTicketList($performance, $section) - { - // Get Tickets and Inventory Information - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; - $Tickets = new EventManagementDataTickets($this->dbh, $this->config); - $Tickets->optionIncludeSelectListData = false; - $ticketsList = $Tickets->getTicketsList(false, $performance, $section, false, true, false, $_SESSION[GLM_EVENT_SESSION]['AdminUser'], false, $this->config->option->packages); - - return $ticketsList; - } - - /** - * Get specific ticket detail - * - * @var $id ID of ticket - * @return object containing array as sub-objects - */ - public function getSpecifiedTicketDetail($ticketID = false) - { - // Get Tickets and Inventory Information - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTickets.php'; - $Tickets = new EventManagementDataTickets($this->dbh, $this->config); - $Tickets->optionIncludeSelectListData = false; - $ticketDetail = $Tickets->getTicketDetail($ticketID); - - // Check for ticket add-ons - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataAddons.php'; - $Addons = new EventManagementDataAddons($this->dbh, $this->config); - $Addons->optionIncludeSelectListData = false; - $ticketAddonsList = $Addons->getAddonsList($ticketID); - if ($ticketAddonsList) { - foreach($ticketAddonsList as $ta) { - $ta['selected'] = 0; - $ticketDetail['addons'][$ta['id']] = $ta; - } - } - - return $ticketDetail; - } - - /** - * Get inventory for a ticket - * - * @var $id ID of inventory item - * @return object containing array as sub-objects - */ - public function getInventoryList($ticketID = false, $where = 'T.active', $dateKey = false) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketInventory.php'; - $TicketInventory = new EventManagementDataTicketInventory($this->dbh, $this->config); - $TicketInventory->optionIncludeSelectListData = false; - $inventoryList = $TicketInventory->getTicketInventoryList($ticketID, $where, $dateKey); - return $inventoryList; - } - - /** - * Get specific ticket inventory item information - * Optionally get extended data for section and entrance - * - * @var $id ID of inventory item - * @return object containing array as sub-objects - */ - public function getInventoryDetail($invenID = false, $extended = false) - { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketInventory.php'; - $TicketInventory = new EventManagementDataTicketInventory($this->dbh, $this->config); - $TicketInventory->optionIncludeSelectListData = false; - $inventoryDetail = $TicketInventory->getTicketInventoryDetail($invenID, $extended); - return $inventoryDetail; - } - - /** - * Get list of tickets for a particular promo code - * - * @var $ticketID ID of ticket - * @return object containing array as sub-objects - */ - public function getPromoTicketsList($promoCode) - { - // Get Tickets and Inventory Information - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPromoTickets.php'; - $promoTickets = new EventManagementDataPromoTickets($this->dbh, $this->config); - $promoTickets->optionIncludeSelectListData = false; - - $promoTicketsList = $promoTickets->getPromoTicketsList(false, $promoCode); - - // Use ticket IDs as the index - $pt = array(); - if ($promoTicketsList && count($promoTicketsList) > 0) { - foreach($promoTicketsList as $p) { - $pt[$p['ticket']] = $p; - } - } - - return $pt; - } - - /** - * Format a number as money - * - * @param $value Value to format - * @param $option Options that control output - * NOPREFIX stops the "$" prefix - * - * @return none - * @access public - */ - private function money($value, $option = "") - { - - if ($option == "NOPREFIX") - $prefix = ""; - else - $prefix = "$"; - - // Do value sanity check - - if (!is_numeric($value)) - return ($prefix."0.00"); - - return ($prefix.number_format($value, 2, ".", ",")); - } - - /* - * Get current number held and number available - * Also return if unlimited quantity ticket - * - * @var $id ID of ticket_inventory item - * @return object containing array as sub-objects - */ - private function getInvenStatus($id) - { - - // Check if inventory ID is sane - if (($id-0) == 0) { - return false; - } - - // Get available and held quantities. - $sql = " - SELECT I.available as available, - T.unlimited_quant as unlimited_quant, - ( - SELECT SUM(quant) - FROM eventmgt.inven_hold - WHERE hold_type = ".$this->config->hold_types->ticket." - AND inventory = $id - AND expire_time > 'now' - ) AS held - FROM eventmgt.ticket_inventory I, - eventmgt.ticket T - WHERE I.id = $id - AND T.id = I.ticket - ;"; - $stmt = $this->dbh->prepare($sql); - $stmt->execute(); - $s = $stmt->fetch(PDO::FETCH_ASSOC); - - // Calculated net available - $s['avail_not_held'] = $s['available'] - ($s['held'] - 0); - - // Check if unlimited quant and if so set to maximum selectable - if ($s['unlimited_quant']) { - $s['available'] = $this->config->option->tickets_select_max; - $s['avail_not_held'] = $this->config->option->tickets_select_max; - } - - // Include inventory item ID for reference - $s['invID'] = $id; - - return $s; - } - - /** - * Check for new cart submission and get all cart data - * - * @param cart Array containing status, reasons, and cart contents - * @return object containing array as sub-objects - */ - private function checkCartAdd($d) - { - - // If there's nothing being added - if (!isset($_REQUEST['cart']) || $_REQUEST['cart'] != 'add') { - return $d; - } - - // Check if we received a single item - if (isset($_REQUEST['ticket_inv'])) { - $invItem = ($_REQUEST['ticket_inv']-0); - $addon = ($_REQUEST['addon']-0); - $quant = ($_REQUEST['quant']-0); - - if (($quant-0) > 0) { - - $d = $this->addItemToCart($d, invItem, $addon, quant); - - } - } - - // Check if we're receiving an array of new additions - if (isset($_REQUEST['ticket_inv_array'])) { - - // Key is ticket ID, value is inventory ID - $tickInvArray = $_REQUEST['ticket_inv_array']; - if (is_array($tickInvArray) && count($tickInvArray) > 0) { - while (list($k, $v) = each($tickInvArray)) { - $invItem = $v; - $quant = $_REQUEST['quant'][$k]; - if (($quant-0) > 0) { - $d = $this->addItemToCart($d, $v, 0, $quant); - } - } - } - - // Check for any add-ons - $GLMaddonTicketInvID = $_REQUEST['GLMaddonTicketInvID']; - if (is_array($GLMaddonTicketInvID) && count($GLMaddonTicketInvID) > 0) { - while (list($k2, $v2) = each($GLMaddonTicketInvID)) { - $addon = $_REQUEST['GLMaddonID'][$k2]; - $quant = $_REQUEST['GLMaddonQuant'][$k2]; - if (($quant-0) > 0) { - $d = $this->addItemToCart($d, $v2, $addon, $quant); - } - } - } - } - - // Update cart in session - $_SESSION[GLM_EVENT_SESSION]['TicketCart'] = $d['cart']; - - return $d; - - } - - /** - * Add a ticket to the cart - * - * @param cart Array containing status, reasons, and cart contents - * other parameters to be determined - * @return object containing array as sub-objects - */ - private function addItemToCart($d, $invItem, $addon, $quant) - { - - // Check if request is sane - if ($invItem > 0 && $quant > 0) { - - // If this is an add-on request - if ($addon > 0) { - - // Check if this addon is the same as another entry and merge - if (isset($d['cart'][$invItem]['addons'][$addon])) { - // Add the new quantity - $d['cart'][$invItem]['addons'][$addon]['quant'] += 1; - } else { - $d['cart'][$invItem]['addons'][$addon] = array( - 'id' => $addon, - 'quant' => $quant - ); - } - - return $d; - - } - - // Get current quantity and number held (also clears old entries) - $ticketQuant = $this->getInvenStatus($invItem); - - // If there's not enough available - if (!$ticketQuant['unlimited_quant'] && $quant > $ticketQuant['avail_not_held']) { - $d['reason'][] = 'The quantity requested was greater than number currently available.'; - return $d; - } - - } else { - $d['reason'][] = 'The request to add to the cart was not complete or an unknown error occurred.'; - return $d; - } - - // Check if the new tickets are the same as another entry and merge - if (isset($d['cart'][$invItem])) { - - // Add the new quantity - $d['cart'][$invItem]['quant'] += $quant; - - } else { - - // Get inventory item data - $invenDetail = $this->getInventoryDetail($invItem); - - // Not same as an existing entry, so add it - $d['cart'][$invItem] = array( - 'invenID' => $invItem, - 'member' => $invenDetail['member'], - 'assigned' => false, - 'quant' => $quant - ); - - } - - return $d; - - } - - /** - * Check for cart update - * - * @param cart Array containing status, reasons, and cart contents - * @return object containing array as sub-objects - */ - private function checkCartUpdate($d) - { - - // If the cart's not being updated - if (!isset($_REQUEST['cart']) || $_REQUEST['cart'] != 'update') { - return $d; - } - - // Get updated ticket data - $invItem = ($_REQUEST['ticket_inv']-0); - $addon = ($_REQUEST['addon']-0); - $quant = ($_REQUEST['quant']-0); - - // Check if request isn't sane - if ($invItem == 0) { - $d['reason'][] = 'The request to change a cart quantity was not complete or an unknown error occurred.'; - return $d; - } - - // If this is an add-on update - if ($addon > 0) { - - $d['cart'][$invItem]['addons'][$addon] = array( - 'id' => $addon, - 'quant' => $quant - ); - - // Otherwise it's a regular ticket update - } else { - - // Get current quantity and number held - $ticketQuant = $this->getInvenStatus($invItem); - - // If there's not enough available (for this session, which is why we add the selected quant back in) - if (!$ticketQuant['unlimited_quant'] && $quant > $ticketQuant['avail_not_held'] + $d['cart'][$invItem]['quant']) { - $d['reason'][] = 'The quantity requested was greater than number currently available.'; - return $d; - } - - // If quantity is 0 then delete the entry unless it's a sticky item, otherwise update it - if ($quant == 0 && !$_SESSION[GLM_EVENT_SESSION]['TicketCart'][$invItem]['sticky']) { - unset($d['cart'][$invItem]); - } else { - $d['cart'][$invItem]['quant'] = $quant; - } - - // If there's still a cart entry and it's 0 now - if (isset($d['cart'][$invItem]) && $d['cart'][$invItem]['quant'] == 0) { - - // Set any addons to 0 - if (isset($d['cart'][$invItem]['addons']) && count($d['cart'][$invItem]['addons']) > 0) { - foreach ($d['cart'][$invItem]['addons'] as $a) { - $d['cart'][$invItem]['addons'][$a['id']]['quant'] = 0; - } - } - - } - - } - - // Update cart in session - $_SESSION[GLM_EVENT_SESSION]['TicketCart'] = $d['cart']; - - return $d; - - } - - /** - * Update holds for the provided cart - * - * @param cart Array containing status, reasons, and cart contents - * @return null - */ - private function updateHolds($cart) - { - - // Start by deleting all holds for this session - $sql = " - BEGIN; - DELETE FROM eventmgt.inven_hold - WHERE session_id = '".$_SESSION[GLM_EVENT_SESSION]['SessionID']."' - ;"; - - $expTime = date('r', strtotime('now +'.$this->config->ticket_hold_time.' minutes')); - - // For each cart entry - if ($cart != false) { - - foreach ($cart as $c) { - - // Check if this is a valid cart entry - if (isset($c['invenID']) && count($c['invenID']) > 0) { - - // Recreate hold with updated expire time - $sql .= " - INSERT INTO eventmgt.inven_hold - ( - hold_type, inventory, quant, expire_time, session_id - ) - VALUES - ( - ".$this->config->hold_types->ticket.", - ".$c['invenID'].", - ".$c['quant'].", - '$expTime', - '".$_SESSION[GLM_EVENT_SESSION]['SessionID']."' - ) - ;"; - - } - } - - } - - $sql .= 'COMMIT;'; - $this->dbh->exec($sql); - - } - - /** - * Check cart for new submissions or updates and return current cart data - * - * Structure of cart array in SESSION - * - * array( - * 'cartID' => array( - * 'invenID' => {ID of the eventmgt.ticket_inventory item}, - * 'quant' => {number requested} - * ) - * ) - * - * @return object containing array as sub-objects - */ - public function checkCart($checkout = false) - { - // Housecleaning: Remove all old hold entries - // If they timed out they don't matter anyway, but this cleans up the table - $this->dbh->exec("DELETE FROM eventmgt.inven_hold WHERE expire_time < 'now';"); - - $r = array( - 'status' => false, - 'reason' => array(), - 'cartHasContents' => false, - 'cartRequiresPayment' => true, - 'cart' => $_SESSION[GLM_EVENT_SESSION]['TicketCart'], - 'cartData' => false, - 'cartDataReorganized' => false, - 'blockCheckout' => false, - 'blockCheckoutNonAssignment' => false, - 'doingAdditionalInfo' => false, - 'forceCheckoutPhase' => false, - 'checkoutComplete' => false - ); - - /* - * Check if any credit cards have been charged for any venues. - * If none are charged then we're not checked out but we aren't forcing checkout phase - * If some were charged and others weren't, then we're forcing checkout phase - * If all were charged, then checkout is complete - */ - if ($_SESSION[GLM_EVENT_SESSION]['TicketPayments'] != false) { - - // Check each payment entry to see if any have been charged and any are not - $charged = false; - $notCharged = false; - foreach ($_SESSION[GLM_EVENT_SESSION]['TicketPayments'] as $pmt) { - if ($pmt['approved']) { - $charged = true; - } else { - $notCharged = true; - } - } - - // if all were charged and none not charged - if ($charged && !$notCharged) { - $r['checkoutComplete'] = true; // Checkout complete - } - - // If some were charged and some weren't - if ($charged && $notCharged) { - $r['forceCheckoutPhase'] = true; // Partial checkout so Set forceCheckoutPhase - } - - } - - // Only check for cart additions or updates if forceCheckoutPhase is not set - if (!$r['forceCheckoutPhase']) { - - // Check if anything is being added to the cart - $r = $this->checkCartAdd($r); - - // Check if there's a cart update - $r = $this->checkCartUpdate($r); - - } - - // Update Holds for this cart - $this->updateHolds($r['cart']); - - // We're here so must be successful - $r['status'] = true; - - /* - * We're now going to build an array of cart contents for output with the following structure - * - * [member & assignment], [date], [perfomance], [section], [ticket], [quant & inventory] - */ - $cartData = array(); - - // Check if there's anything in the cart - $cartItemRemoved = false; // To track whether we had to delete an item from the cart for missing data - if ($r['cart'] != false) { - - $totalVenues = 0; - $totalTickets = 0; - $totalNoPayment = 0; - $grandTotalPrice = 0; - $totalPrice = 0; - - // Check to see if there's an active promo code and return ticket info for that code - $promoTicketsList = false; - if (isset($_SESSION[GLM_EVENT_SESSION]['PromoCode']) && $_SESSION[GLM_EVENT_SESSION]['PromoCode'] != '') { - $promoTicketsList = $this->getPromoTicketsList($_SESSION[GLM_EVENT_SESSION]['PromoCode']); - } - - // Get all data associated with this cart entry - foreach ($r['cart'] as $c) { - - // Get inventory record detail and status - $invID = $c['invenID']; - $invDetail = $this->getInventoryDetail($invID); - $invStatus = $this->getInvenStatus($invID); - - // Get Ticket info - $ticketDetail = $this->getSpecifiedTicketDetail($invDetail['ticket_id']); - - $memb = $ticketDetail['member']; - - // Check for assignment - $assignedFrom = false; - $assigned = false; - $assignedEntrance = false; - if ($checkout && isset($_SESSION[GLM_EVENT_SESSION]['Assignment'][$memb])) { - - // Keep track of original ticket member - $assignedFrom = $memb; - - // Set assignment information for this cart entry - $assigned = $_SESSION[GLM_EVENT_SESSION]['Assignment'][$memb]; - - // And save back into session cart - $_SESSION[GLM_EVENT_SESSION]['TicketCart'][$invID]['assigned'] = $assigned; - - // Now set our current member to the assignment - $memb = $assigned; - - // Also get the assigned from member name - $mDet = $this->getMemberData($assignedFrom); - $assignedFromName = $mDet['name']; - unset($mDet); - - // Also now check if there's been an entrance assignment - if (isset($_SESSION[GLM_EVENT_MGT_FRONT]['AssignmentEntrance'][$assignedFrom])) { - $assignedEntrance = $_SESSION[GLM_EVENT_SESSION]['AssignmentEntrance'][$assignedFrom]; - } - - } - - // Get member info - $memberDetail = $this->getMemberData($memb); - - // Get Section info - $sectionDetail = $this->getSpecifiedSectionDetail($ticketDetail['section_id']); - - // Get performance info - $performanceDetail = $this->getPerformanceData($ticketDetail['performance_id']); - - // Make sure we have all needed information - Perhaps something has been deleted - if ($ticketDetail && $memberDetail && $memberDetail['active']['value'] && $sectionDetail && performanceDetail) { - - // If Venue/Member hasn't been added yet - $membID = $memberDetail['id']; - if (!isset($cartData[$membID])) { - - $cartData[$membID] = $memberDetail; - $cartData[$membID]['assigned'] = ($assignedFrom != false); - $cartData[$membID]['assigned_from'] = $assignedFrom; - $cartData[$membID]['assigned_from_name'] = $assignedFromName; - $cartData[$membID]['needLikelyDate'] = false; - $cartData[$membID]['likelyDate'] = false; - $cartData[$membID]['dates'] = array(); - $cartData[$membID]['totalTickets'] = 0; - $cartData[$membID]['totalPrice'] = 0; - $cartData[$membID]['totalPrice_numb'] = 0; - $cartData[$membID]['no_payment'] = false; - - $totalVenues++; - - // Also check for a completed payment for this member - if (isset($_SESSION[GLM_EVENT_SESSION]['TicketPayments'][$membID]) && $_SESSION[GLM_EVENT_SESSION]['TicketPayments'][$membID]['approved']) { - - // Add this payment information to the cart - $cartData[$membID]['paymentResult'] = $_SESSION[GLM_EVENT_SESSION]['TicketPayments'][$membID]; - } - - } - - // Set alias for dates array - $dates = &$cartData[$membID]['dates']; - - // If Date hasn't been added yet - also check for no date (non date-specific) - $date = $invDetail['ticket_date']['date']; - if ($date == '') { - $date = 0; - } - if (!isset($dates[$date])) { - $dates[$date] = array( - 'date' => $date, - 'fullDate' => date('l F j, Y', strtotime($date)), - 'performances' => array(), - 'dateSpecific' => (trim($date) != '' && strtotime($date) > 0) - ); - } - $performances = &$dates[$date]['performances']; - - // If Performance hasn't been added yet - $perfID = $performanceDetail['id']; - if (!isset($performances[$perfID])) { - $performances[$perfID] = $performanceDetail; - $performances[$perfID]['sections'] = array(); - } - $sections = &$performances[$perfID]['sections']; - - // If Section hasn't been added yet - $sectID = $sectionDetail['id']; - if (!isset($sections[$sectID])) { - $sections[$sectID] = $sectionDetail; - $sections[$sectID]['tickets'] = array(); - - // Check if there's been an Entrance Assignment and use that for the entrance data for the section - if ($assignedEntrance) { - $sections[$sectID]['entrance'] = $assignedEntrance; - } - - // If we have an entrance with this section, get the detail - if ($sections[$sectID]['entrance']) { - $sections[$sectID]['entranceDetail'] = $this->getEntranceData($sections[$sectID]['entrance']); - } - - } - $tickets = &$sections[$sectID]['tickets']; - - // If this ticket hasn't been added yet (shouldn't be) - $ticID = $ticketDetail['id']; - if (!isset($tickets[$ticID])) { - - // Add ticket detail to tickets and set other standard parameters - $tickets[$ticID] = array_merge($ticketDetail, $invStatus); - $tickets[$ticID]['selected'] = $c['quant']; - $tickets[$ticID]['show_price'] = true; // False if only price is with add-ons - $tickets[$ticID]['show_accumulated_total'] = false; // Use when add-ons are included - $tickets[$ticID]['show_addons'] = false; // Use when add-ons are included - $tickets[$ticID]['problem'] = false; - - // Calculate base ticket price - $ext = $c['quant'] * $ticketDetail['price_numb']; - - // Do we have any addons for this ticket? - if (count($ticketDetail['addons']) > 0) { - - // For each add-on associated with this ticket - $addons_ext = 0; - foreach ($ticketDetail['addons'] as $a) { - - // If this addon is in the cart - if (isset($c['addons']) && isset($c['addons'][$a['id']])) { - - // Check if no cost is with the ticket, only in the add-on - if ($ext == 0) { - $tickets[$ticID]['show_price'] = false; - } - - // Set the quantity and tally price - $addon_quant = $c['addons'][$a['id']]['quant']; - $tickets[$ticID]['addons'][$a['id']]['selected'] = $addon_quant; - $addon_ext = $addon_quant * $a['unit_cost_numb'] * $c['quant']; - $tickets[$ticID]['addons'][$a['id']]['ext'] = $addon_ext; - $tickets[$ticID]['addons'][$a['id']]['money'] = $this->money($addon_ext); - - // add to total addons for this ticket - $addons_ext += $addon_ext; - - } - } - - // determine what to show for this ticket - $tickets[$ticID]['show_accumulated_total'] = true; - if ($tickets[$ticID]['price_numb'] == 0) { - $tickets[$ticID]['show_price'] = false; - } - - // If we have a ticket quantity, then show the addons - if ($c['quant'] > 0) { - $tickets[$ticID]['show_addons'] = true; - } - - // Add the add-ons price to this ticket extended total - $ext += $addons_ext; - - // Check if add-ons are required for this ticket type - $tickets[$ticID]['required_addon_not_supplied'] = false; - if ($c['quant'] > 0 && $ticketDetail['addon_required']['value'] && $addons_ext == 0) { - $tickets[$ticID]['required_addon_not_supplied'] = true; - $r['reason'][] = $ticketDetail['performance'].' requires selection of at least one associated add-on item!'; - $r['blockCheckout'] = true; - $r['blockCheckoutNonAssignment'] = true; - $tickets[$ticID]['problem'] = true; - $tickets[$ticID]['problemText'] = $ticketDetail['performance'].' requires selection of at least one of the following!'; - } - - } - - // If there's any ticket price > 0 and we have a promo with this ticket and it's within the date range - $promoCredit = 0; - $today = strtotime('today'); - $tomorrow = strtotime('tomorrow'); - if ($ext > 0 && isset($promoTicketsList[$ticID]) && - strtotime($promoTicketsList[$ticID]['promo_start_date']) <= $today && - strtotime($promoTicketsList[$ticID]['promo_end_date']) >= $today - ) { - - // Promo and dates are valid, so credit accordingly - switch($promoTicketsList[$ticID]['promo_type']['value']) { - - // $ amount - case 1: - $credit_each = $promoTicketsList[$ticID]['amount']; - $credit = -1 * $credit_each * $c['quant']; - break; - - // Percentage - case 2: - $credit_each = $ext * ($promoTicketsList[$ticID]['amount']/100); - $credit = -1 * $credit_each * $c['quant']; - break; - } - - // Add to ticket data - $tickets[$ticID]['promo'] = array( - 'promo' => $promoTicketsList[$ticID]['promo'], - 'promo_name' => $promoTicketsList[$ticID]['promo_name'], - 'promo_type' => $promoTicketsList[$ticID]['promo_type']['value'], - 'promo_type_name' => $promoTicketsList[$ticID]['promo_type']['nameEsc'], - 'credit_each' => $credit_each, - 'credit_numb' => $credit, - 'credit' => $this->money($credit) - ); - - // Update extended price for this ticket - $promoCredit += $credit; - - } - - $tickets[$ticID]['extended'] = $this->money($ext); - $tickets[$ticID]['extended_numb'] = $ext; - - // Add to venue totals - $cartData[$membID]['totalTickets'] += $c['quant']; - $cartData[$membID]['totalPrice_numb'] += $ext + $promoCredit; - $cartData[$membID]['totalPrice'] = $this->money($cartData[$membID]['totalPrice_numb']); - - // Add to master totals - $totalTickets += $c['quant']; - $grandTotalPrice += $ext + $promoCredit; - if ($memberDetail['payment_gateway']['value'] != $this->config->ccard_processor_numb->no_payment) { - $totalPrice += $ext + $promoCredit; - - } else { - $totalNoPayment += $ext + $promoCredit; - $cartData[$membID]['no_payment'] = true; - } - - // Calculate max number this session may select - Number not held + quantity this person has selected - $tickets[$ticID]['thisSessionSelectable'] = $invStatus['avail_not_held'] + $c['quant']; - - } else { - $r['reason'][] = 'There has been a cart error: duplicate cart entries!'; - return $r; - } - - // Check if ticket is non-date-specific, and a voucher type < 80 (a ticket kind of thing), and it's sold, then it needs a likely date - if (!$ticketDetail['date_specific']['value'] && $ticketDetail['voucher_type']['value'] < 80 && $c['quant'] > 0) { - - $cartData[$membID]['needLikelyDate'] = true; - - // Also check if a likely date has been submitted - $dateMemb = $cartData[$membID]['assigned_from']; - if (($dateMemb-0) == 0) { - $dateMemb = $membID; - } - if (isset($_SESSION[GLM_EVENT_SESSION]['LikelyDate'][$dateMemb])) { - $cartData[$membID]['likelyDate'] = $_SESSION[GLM_EVENT_SESSION]['LikelyDate'][$dateMemb]; - } - } - - // Check for package data - if ($this->config->option->packages && $ticketDetail['ticket_type']['value'] == 20) { - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($this->dbh, $this->config); - $packageData = $TicketPackages->getPackageList("package = ".$ticID); - $tickets[$ticID]['packageData'] = $packageData; - } - - - - // We apparently don't have all needed data for this cart entry - // Something has been turned off or deleted - } else { - - // Remove this item from the cart - unset($_SESSION[GLM_EVENT_SESSION]['TicketCart'][$invID]); - $cartItemRemoved = true; - - } - - } // each cart entry - - // Reorganize cart so dates are under events rather than the other way around - // [Member & Assignments], [Performance], [Date], [Section], [Ticket] - $rCart = array(); - - // For each venue - $venueCount = 0; - foreach($cartData as $c) { - - // Assign venue information but not dates array - $rCart[$c['id']] = $c; - unset($rCart[$c['id']]['dates']); - - // For each date - foreach($c['dates'] as $d) { - - // For each performance - foreach($d['performances'] as $p) { - - // If performance not added yet, do that now - if (!isset($rCart[$c['id']]['performances'][$p['id']])) { - - // Assign performance information but not sections - $rCart[$c['id']]['performances'][$p['id']] = $p; - unset($rCart[$c['id']]['performances'][$p['id']]['sections']); - - } - - // If Date not added yet, do that now - if (!isset($rCart[$c['id']]['performances'][$p['id']]['dates'][$d['date']])) { - - // Assign date information but not performance array - $rCart[$c['id']]['performances'][$p['id']]['dates'][$d['date']] = $d; - unset($rCart[$c['id']]['performances'][$p['id']]['dates'][$d['date']]['performances']); - - } - - // For each section - foreach($p['sections'] as $s) { - - // If section not added, do that now - if (!isset($rCart[$c['id']]['performances'][$p['id']]['dates'][$d['date']]['sections'][$s['id']])) { - - // Assign section information but not tickets - $rCart[$c['id']]['performances'][$p['id']]['dates'][$d['date']]['sections'][$s['id']] = $s; - unset($rCart[$c['id']]['performances'][$p['id']]['dates'][$d['date']]['sections'][$s['id']]['tickets']); - - } - - // For each ticket - foreach($s['tickets'] as $t) { - - // Assign the ticket - $rCart[$c['id']]['performances'][$p['id']]['dates'][$d['date']]['sections'][$s['id']]['tickets'][$t['id']] = $t; - - } - - } // For each Section - - // Determine if this performance has multiple sections - if (count($p['sections']) == 1) { - $rCart[$c['id']]['performances'][$p['id']]['oneSectionOnly'] = true; - } else { - $rCart[$c['id']]['performances'][$p['id']]['oneSectionOnly'] = false; - } - - } // For each Performance - }// For each Date - } // For each Venue - - // Determine if there's multiple venues in the cart - if (count($cartData) == 1) { - $r['cartHasOneVenueOnly'] = true; - } else { - $r['cartHasOneVenueOnly'] = false; - } - - /* - * Sort everything the way it should be - */ - - // Sort Members - uasort ($rCart, function ($a, $b) { - if ($a['sort'] == $b['sort']) { - return 0; - } - return ($a['sort'] < $b['sort']) ? -1 : 1; - }); - // For each Member - while (list($k1, $v1) = each($rCart)) { - - // Flag all cart entries as not central payment member, will update that in the checkout process. - $rCart[$k1]['isCentralPaymentMember'] = false; - - // Sort Performances - uasort ($rCart[$k1]['performances'], function ($a, $b) { - if ($a['sort'] == $b['sort']) { - return 0; - } - return ($a['sort'] < $b['sort']) ? -1 : 1; - }); - - // For each Performance - while (list($k2, $v2) = each($rCart[$k1]['performances'])) { - // Sort Dates - // Dates - Not doing this yet - - //For each Date - while (list($k3, $v3) = each($rCart[$k1]['performances'][$k2]['dates'])) { - - // Sort Sections - uasort ($rCart[$k1]['performances'][$k2]['dates'][$k3]['sections'], function ($a, $b) { - if ($a['sort'] == $b['sort']) { - return 0; - } - return ($a['sort'] < $b['sort']) ? -1 : 1; - }); - - // For each Section - while (list($k4, $v4) = each($rCart[$k1]['performances'][$k2]['dates'][$k3]['sections'])) { - - // Sort Tickets - uasort ($rCart[$k1]['performances'][$k2]['dates'][$k3]['sections'][$k4]['tickets'], function ($a, $b) { - if ($a['sort'] == $b['sort']) { - return 0; - } - return ($a['sort'] < $b['sort']) ? -1 : 1; - }); - - } // Sections - } // Dates - } // Performances - } // Members - - } // have cart entries - -// echo "

    ".print_r($rCart,1)."
    "; - - // If we're not doing checkout, then also check to see if we need assignment selection info - if (!$checkout && is_array($rCart) && count($rCart) > 0) { - - // Check for ticket assignment for sale by another member - foreach ($rCart as $c) { - - $rCart[$c['id']]['needAssignment'] = false; - $rCart[$c['id']]['haveAssignment'] = false; - - // Check if a type 3 - if ($c['member_type']['value'] == 3) { - $r['doingAdditionalInfo'] = true; - } - - // Check if type 3 and not assigned - if ($c['member_type']['value'] == 3 && (!isset($c['assignedTo']) || $c['assignedTo'] < 1)) { - - // Assume we're going to fail to assign this - unless we don't have anything selected - if ($rCart[$c['id']]['totalPrice_numb'] > 0) { - $rCart[$c['id']]['needAssignment'] = true; - } - - // Get list of members who this can be assigned to - $assignmentMembers = $this->getMembersList('type2'); - - if ($assignmentMembers) { - - // Check session to see if there's been an assignment - $assignedTo = false; - $assignedToEntrance = false; - if (isset($_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'][$c['id']])) { - $assignedTo = $_SESSION['GLM_EVENT_MGT_FRONT']['Assignment'][$c['id']]; - } - if ($this->config->option->ticket_selection->select_entrance_on_consignment && - isset($_SESSION['GLM_EVENT_MGT_FRONT']['AssignmentEntrance'][$c['id']])) { - $assignedToEntrance = $_SESSION['GLM_EVENT_MGT_FRONT']['AssignmentEntrance'][$c['id']]; - } - - // If an assignment hasn't been made, block checkout - if (!$assignedTo && $c['totalTickets'] > 0) { - $r['blockCheckout'] = true; - } - - // If a likely date is needed and not supplied, block checkout - if ($this->config->option->ask_for_likely_date && $c['needLikelyDate'] && empty($c['likelyDate'])) { - $r['blockCheckout'] = true; - } - - // If a likely date is required, even one is supplied - if ($this->config->option->ask_for_likely_date && $c['needLikelyDate']) { - $r['doingAdditionalInfo'] = true; - } - - // Provide list of assignment members for this entry - $a = array(); - foreach ($assignmentMembers as $m) { - - // Add this member to the list - $a[$m['id']] = array( - 'id' => $m['id'], - 'name' => $m['name'], - 'city' => $m['city'], - 'selected' => false, - 'entrances' => false - ); - - // Check if we should also look at entrances - if ($this->config->option->ticket_selection->select_entrance_on_consignment) { - - // Get a list of entrances for this assignment member - $entrancesList = $this->getEntrancesList($m['id']); - if ($entrancesList) { - foreach($entrancesList as $e) { - - $a[$m['id']]['entrances'][$e['id']] = $e; - $a[$m['id']]['entrances'][$e['id']]['selected'] = false; - - // Determine if this entrance has been selected - if ($m['id'] == $assignedTo && $e['id'] == $assignedToEntrance) { - $a[$m['id']]['entrances'][$e['id']]['selected'] = true; - } - - } - - } - - } - - // If this is the assigned member - if ($m['id'] == $assignedTo) { - - // Mark this member as assigned - $a[$m['id']]['selected'] = true; - $rCart[$c['id']]['haveAssignment'] = true; - - } - } - - // Add list to cart entry - $rCart[$c['id']]['assignmentMembers'] = $a; - - } else { - - // We've had an assignment problem, so fail this process - $r['reason'][] = 'There has been a system problem: There are no members to which we can assign unassigned cart items.'; - $r['status'] = false; - - } - } - - // Check if we need either assignment or likely date - $rCart[$c['id']]['needAssignemntOrDate'] = false; - if ($rCart[$c['id']]['needAssignment'] || ($this->conf->ask_for_likely_date && $rCart[$c['id']]['needLikelyDate'])) { - $rCart[$c['id']]['needAssignemntOrDate'] = true; - } - - } // For each cart entry - } - - // If cart items have been removed - note that - if ($cartItemRemoved) { - $r['reason'][] = 'A '.$this->config->term->ticket->norm.' or '.$this->config->term->ticket->plur - .' have been removed from your cart because they have become unavailable for some reason.
    - We appolgize for the incovenience.'; - } - - // If the cart has a total price, then there must be cart contents -// if ($totalPrice + $totalNoPayment > 0) { - if (count($r['cartData']) > 0) { - $r['cartHasContents'] = true; - } - - if ($totalPrice == 0) { - $r['cartRequiresPayment'] = false; - } - - // Return cart output data and indicate success - $r['cartData'] = $cartData; - $r['cartItemRemoved'] = $cartItemRemoved; - $r['cartDataReorganized'] = $rCart; - $r['totals'] = array( - 'venues' => $totalVenues, - 'tickets' => $totalTickets, - 'price_numb' => $totalPrice, - 'price' => $this->money($totalPrice), - 'grand_total_numb' => $grandTotalPrice, - 'grand_total_price' => $this->money($grandTotalPrice) - ); - - return $r; - - } - - /** - * Get Cart Sticky Inventory - * - * Cart-Sticky tickets are tickets that always show in the cart whether there's - * a selected quantity or 0 quantity. This permits a short 2-step process - * for the shop that includes only Cart and Checkout. It can also be used - * to ask users to select something you want them to buy. - * - * This method will look for active cart-sticky tickets and will return - * a list of inventory items and data useable to insert into a session cart. - * - * Cart-Sticky tickets may not be date-specific at this time. They must have - * only one inventory entry. - * - * @return object containing array as sub-objects - */ - public function getCartStickyInventory() - { - - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketInventory.php'; - $TicketInventory = new EventManagementDataTicketInventory($this->dbh, $this->config); - - // Look only for members that are of type 3, are active, and where the performance is active - $where = " - (SELECT cart_sticky FROM eventmgt.ticket WHERE id = T.ticket) - AND (SELECT active FROM eventmgt.performance WHERE id = (SELECT performance FROM eventmgt.ticket WHERE id = T.ticket)) - "; -//T.member IN (SELECT id FROM eventmgt.member WHERE member_type = 3 AND active) -// AND - - // Get sticky inventory for all matching members (-1) - $inv = $TicketInventory->getTicketInventoryList(-1, $where); - - // Order by ticket order field - uasort ($inv , function ($a, $b) { - if ($a['ticket_sort'] == $b['ticket_sort']) { - return 0; - } - return ($a['ticket_sort'] < $b['ticket_sort']) ? -1 : 1; - } - ); - - return $inv; - } - - /** - * Get performances set for promotion on cart page - * - * Returns an array of performances that are set to be promoted on the cart page. - * - * @return object containing array as sub-objects - */ - public function getCartPromotions() - { - - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataPerformances.php'; - $Performances = new EventManagementDataPerformances($this->dbh, $this->config); - $Performances->optionIncludeSelectListData = false; - $performancesList = $Performances->getPerformancesList('cart_promotions'); - return $performancesList; - - } - -} - -?> diff --git a/legacy/models/vouchers/Generic/voucher.php b/legacy/models/vouchers/Generic/voucher.php deleted file mode 100755 index 6f06214..0000000 --- a/legacy/models/vouchers/Generic/voucher.php +++ /dev/null @@ -1,607 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: printVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once PDF_ABSTRACT; -$Pdf = new GlmPdf(); - -/** - * PdfVoucher class - * - * @category PdfVoucher - * @package PDFLib - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @link <> -*/ -class PdfVoucher extends GlmPdf -{ - - public $borderWidth = 1; - public $borderColor = 'black'; - public $pdfCouponInterval = 5; - public $pdfMinCoupons = 3; - public $config; - public $companyContact = false; - public $venueContact = false; - - function __construct($order, $vouchers, $member, $dbh, $config) - { - - $this->config = $config; - - // if debug.glmpdf is set in the configs/common.ini file in the CommonApp directory, do grids on PDFs - define ('GLMPDF_DEBUG', $this->config->debug->glmpdf); - - // The following produces a color test sheet. There is no return from that call. - // $this->glmpdfShowValidColors(); - - // Start with cover page. - $this->glmpdfSetForms( - 1, - array( - 1 => array( 'x' => 0, 'y' => 0, 'xs' => 613, 'ys' => 792 ) - ), - 'US Letter' - ); - - // Start page - $this->glmpdfStart( $this->config->owner->name, "Gaslight Media", "Ticket System Receipt/Vouchers" ); - - if( !$this->glmpdfAddFont( 'barcode', 'barcode/FREE3OF9.TTF' ) ) - { - echo 'ERROR: Unable to add barcode font.

    - Did you place the barcode font provided in docs/BarcodeFonts into - a system fonts directory ("/usr/share/fonts/truetype/Barcode")? - Also check the GLMPDF_PDF_FONT_DIR setting in GlmPdf.php.'; - exit; - } - - // If coupon test is selected, print them all now. -// if( isset($_REQUEST['test_coupons']) ) -// { -// for( $i=1 ; $i<=count($coupons) ; $i++ ) -// $this->printCoupon( $i ); -// -// glmpdf_send_to_browser( '', 'voucher.pdf' ); -// exit; -// } - - // Get images to tmp files - require_once IMAGE_SERVER_ABSTRACT; - $imServer = new ImageServerAbstract(); - - if (trim($member['image']) != '') { - $venueImageFile = $imServer->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$member['image']); - if ($venueImageFile) { - $venueImage = $this->glmpdfOpenImage($venueImageFile); - - // If failure getting the image - if ($venueImage == false) { - $venueImageFile = false; - } - } - } else { - $venueImageFile = false; - } - - if (trim($member['parking_map']) != '') { - $parkingImageFile = $imServer->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$member['parking_map']); - if ($parkingImageFile) { - $parkingImage = $this->glmpdfOpenImage($parkingImageFile); - - // If failure getting the image - if ($parkingImage == false) { - $parkingImageFile = false; - } - } - } else { - $parkingImageFile = false; - } - - if (trim($member['ticket_sec_map']) != '') { - $sectionImageFile = $imServer->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$member['ticket_sec_map']); - if ($sectionImageFile) { - $sectionImage = $this->glmpdfOpenImage($sectionImageFile); - - // If failure getting the image - if ($sectionImage == false) { - $sectionImageFile = false; - } - } - } else { - $sectionImageFile = false; - } - - // Load entrance class - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; - $Entrances = new EventManagementAdminEntrances($dbh, $config); - - // Load performance class - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($dbh, $config); - - // Setup additional information - // Company contact info - if ($config->option->voucher->show_company_contact) { - $companyContact = ''; - $sep = ''; - if ($config->option->voucher->show_company_name) { - $companyContact .= $config->owner->name; - $sep = ' - '; - } - if ($config->option->voucher->show_company_addr && $config->owner->addr1) { - $companyContact .= $sep.$config->owner->addr1; - $sep = ' - '; - if ($config->owner->addr2) { - $companyContact .= ', '.$config->owner->addr2; - } - } - if ($config->option->voucher->show_company_citystate) { - $companyContact .= $sep.$config->owner->city.', '.$config->owner->state; - $sep = ' - '; - } - if ($config->option->voucher->show_company_phone) { - if ($config->owner->toll_free) { - $companyContact .= $sep.$config->owner->toll_free; - } else { - $companyContact .= $sep.$config->owner->phone; - } - } - } - // Venue/Location contact info - $venueContact = false; - if ($config->option->voucher->show_venue_contact) { - $venueContact = ''; - $sep = ''; - if ($config->option->voucher->show_venue_name) { - $venueContact .= $member['name']; - $sep = ' - '; - } - if ($config->option->voucher->show_venue_addr && $member['addr1']) { - $venueContact .= $sep.$member['addr1']; - $sep = ' - '; - if ($member['addr2']) { - $venueContact .= ', '.$member['addr2']; - } - } - if ($config->option->voucher->show_venue_citystate) { - $venueContact .= $sep.$member['city'].', '.$member['state']['name']; - $sep = ' - '; - } - if ($config->option->voucher->show_venue_phone) { - $venueContact .= $sep.$member['phone']; - } - } - - // START VOUCHER PRINTOUT - - $this->glmpdfNextForm(); - - /* Cover Page */ - - // Header - if ($venueImageFile) { - $coverImage = $this->glmpdfOpenImage($venueImageFile); - $this->glmpdfPlaceImage($coverImage, 30, 690, .5, false, 'center', 280, 140); - } - $this->glmpdfSetFont( "Helvetica-Bold", 18.0 ); // Header Text - $this->glmpdfPlaceText( $config->owner->name, 340, 750, "center", 'black', -400 ); - $this->glmpdfSetFont( "Helvetica", 14.0 ); - $this->glmpdfPlaceText( $config->owner->short_name." - ".$member['name'], 340, $this->glmpdfCurrentY-10, "center", 'black', -400 ); - $this->glmpdfPlaceText( $member['addr1'], 340, $this->glmpdfCurrentY, "center", 'black', -400 ); - $this->glmpdfPlaceText( $member['city'].", ".$member['state']['name']." ".$member['zip'], 340, $this->glmpdfCurrentY, "center", 'black', -400 ); - - // Sold To Information - $valCol = 60; - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( $this->config->term->order->cap." ID: ".trim($order['id']), $valCol, 650, "left", 'black' ); - $this->glmpdfPlaceText( trim($order['fname'].' '.$order['lname']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - $this->glmpdfPlaceText( trim($order['addr1']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - if( trim($order['addr2']) != '' ) - $this->glmpdfPlaceText( trim($order['addr2']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - $this->glmpdfPlaceText( trim($order['city']).', '.$order['state']['value'].' '.trim($order['zip']).' '.$order['country']['value'], $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - - // Purchace/Charge information - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $promptCol = 330; - $valCol = 420; - $this->glmpdfPlaceText( "Date of Purchase:", $promptCol, 650, "left", 'black' ); - $this->glmpdfPlaceText( $order['purchase_date']['date'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Card Type:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['cctype'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Name on Card:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccname'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Card Number:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccnumber'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Confirmation:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccconf'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Total Charged:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['charge_total'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - - // Purchase Summary - $ticNumbCol = 20; - $perfNameCol = 80; - $ticNameCol = 200; - $secNameCol = 370; - $dateCol = 440; - $this->glmpdfPlaceText( '', $ticNumbCol, 550, "center", 'black', 0, ''); - - $this->glmpdfSetFont( "Helvetica", 8.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap, $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - $this->glmpdfPlaceText( $this->config->term->performance->cap, $perfNameCol, $this->glmpdfLastY, "left", 'black', -110, ''); - $this->glmpdfPlaceText( $this->config->term->ticket->cap, $ticNameCol, $this->glmpdfLastY, "left", 'black', -160, ''); - $this->glmpdfPlaceText( $this->config->term->section->cap, $secNameCol, $this->glmpdfLastY, "left", 'black', -60, ''); - $this->glmpdfPlaceText( 'Date / Time', $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - - $this->glmpdfPlaceText( '', $ticNumbCol, $this->glmpdfCurrentY-3, "center", 'black', 0, ''); - - foreach( $vouchers as $t ) { - - $voucherCode = $this->addCheckCode($t['id']); - - $this->glmpdfSetFont( "Helvetica", 8.0 ); - $this->glmpdfPlaceText( $voucherCode, $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - $this->glmpdfPlaceText( html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8"), $perfNameCol, $this->glmpdfLastY, "left", 'black', -110, ''); - $this->glmpdfPlaceText( html_entity_decode($t['ticket_name'],ENT_QUOTES,"utf-8"), $ticNameCol, $this->glmpdfLastY, "left", 'black', -160, ''); - $this->glmpdfPlaceText( html_entity_decode($t['section_name'],ENT_QUOTES,"utf-8"), $secNameCol, $this->glmpdfLastY, "left", 'black', -60, ''); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - } - - // Check for Ticket add-ons - if (isset($t['addons_sold']) && count($t['addons_sold']) > 0) { - foreach($t['addons_sold'] as $a) { - - $addonText = $a['add_on_name']; - if (($a['add_on_type']['value']-0) == 2) { - $addonText = $addonText.', '.$a['quant'].' '.$a['unit_name']; - } - $this->glmpdfPlaceText( html_entity_decode($addonText,ENT_QUOTES,"utf-8"), $ticNameCol+10, $this->glmpdfCurrentY, "left", 'black', -240, ''); - } - } - - } - - // Special Needs - $this->glmpdfSetFont( "Helvetica", 9.0 ); - if (trim($order['special_needs']) != '') { - $this->glmpdfPlaceText( "Special Needs:", 20, $this->glmpdfCurrentY-30, "left", 'black' ); - $this->glmpdfPlaceTextBox( $order['special_needs'], 100, $this->glmpdfCurrentY+16, 450, 50, "left", 'black' ); - } - - // General Member Policies - if (trim($member['def_ticket_pol']) != '') { - $this->glmpdfPlaceText( "Policies:", 20, $this->glmpdfCurrentY-30, "left", 'black' ); - $this->glmpdfPlaceTextBox( $member['def_ticket_pol'], 100, $this->glmpdfCurrentY+16, 450, 50, "left", 'black' ); - } - - // Now setup ticket forms - $this->glmpdfSetForms( - 1, - array( - 1 => array( 'x' => 25, 'y' => 495, 'xs' => 560, 'ys' => 275 ) -// 2 => array( 'x' => 25, 'y' => 210, 'xs' => 560, 'ys' => 275 ) - ), - 'US Letter' - ); - // Also reset form count - $this->glmpdfNextPage(); - - // Display Footer - $this->glmpdfSetFont( "Helvetica-Bold", 8.5 ); - $this->glmpdfPlaceText( $footer, 140.5, 2, "center", 'darkblue' ); -/*********CPS - // Display Parking Map - if ($parkingImage) { - $this->glmpdfNextForm(); - $this->glmpdfPlaceImage( $parkingImage, 0, 2, 0, 'meet', 'center', 280, 125); - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Parking Map', 140, 130, "center", 'black' ); - } - - // Display Section Map - if ($sectionImage) { - $this->glmpdfNextForm(); - $this->glmpdfPlaceImage( $sectionImage, 0, 2, 0, 'meet', 'center', 280, 125); - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Section Map', 140, 130, "center", 'black' ); - } -*/ - - // Load mask for darkening the bottom portion of the tickets -// $ticketMask = $this->glmpdfOpenImage(EVENT_MANAGEMENT_APP_BASE.'web/custom/greatlakesbaymag/assets/ticket-gradient.png'); - - // Clear performance image loaded flag - $performanceLoaded = false; - - // Process Vouchers - For each type of ticket purchased - $numb_tickets = 0; - foreach( $vouchers as $t ) - { - - if ($numb_tickets++ > 0) { - $this->glmpdfNextForm(); - } - $this->glmpdfPlaceBox( $this->borderWidth, 0, 275, 560, 275, $this->borderColor ); - - // Display Logo - Only get performance image if it's not currently loaded - if ($performanceLoaded != $t['performance']) { - - $performanceDetail = $Performances->getPerformanceDetail($t['performance']); - - // If we have an image but it's the wrong one, dump the temp file - if ($performanceImageFile) { - unlink($performanceImageFile); - } - - // This performance image is not currently loaded - so do that now - - $performanceImageFile = $imServer->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$performanceDetail['image']); - if ($performanceImageFile) { - // If we have the image, then load it - $performanceImage = $this->glmpdfOpenImage($performanceImageFile); - $performanceLoaded = $t['performance']; - } else { - - // otherwise, try the venue image - $performanceLoaded = $venueImage; - } - - } - - // If we have the performance image, display it - $haveTopImage = false; - if ($performanceImage) { - $this->glmpdfPlaceImage( $performanceImage, 85, 195, 1, 'meet', 'center', 70, 75); - $haveTopImage = true; - } elseif ($venueImageFile) { - $this->glmpdfPlaceImage($coverImage, 85, 195, 1, 'meet', 'center', 70, 75); - $haveTopImage = true; - } - - // Place owner name at top possitioned by whether or not there's an image supplied - $this->glmpdfSetFont( "Helvetica-Bold", 24.0 ); - if ($haveTopImage) { - $this->glmpdfPlaceText( $config->owner->name, 315, 227, "center", 'black', -300, ''); - } else { - $this->glmpdfPlaceText( $config->owner->name, 280, 227, "center", 'black', -350, ''); - } - - // Place mask - //$this->glmpdfPlaceImage($ticketMask, 0, 52, .25, false, 'center', 280, 140); - - // If ticket has already been claimed, then mark ticket - if ($t['time_claimed']['date'] != '') { - $this->glmpdfSetFont( "Times-Bold", 72.0 ); - $this->glmpdfPlaceText( "CLAIMED", 110, 80, "left", 'orangered', 0, '' ); // last parameter can be things like "rotate=90" - } - - // Ticket Information Area - $this->glmpdfSetFont( "Helvetica-Bold", 24.0 ); - $this->glmpdfPlaceLine(1, 80, 0, 80, 275, $color = "black", $dash = false, $d_a = 1, $d_b = 1); - $this->glmpdfPlaceLine(1, 480, 0, 480, 275, $color = "black", $dash = false, $d_a = 1, $d_b = 1); - - // Left End of Ticket - NOTE: use only "left" in glmpdfPlaceText - use "position=..." in optlist instead. - if (($t['entrance']-0) > 0) { - $entranceDetail = $Entrances->getEntranceDetail($t['entrance']); - $this->glmpdfPlaceBox(1, 0, 0, 80, -275, '', $entranceDetail['color']['name'], 'miter'); - } - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Departing from:', 7, 40, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Helvetica-Bold", 20.0 ); - $this->glmpdfPlaceText( strtoupper(html_entity_decode($t['entrance_name'],ENT_QUOTES,"utf-8")), 30, 138, 'left', 'black', -250, 'position=center rotate=90'); - $this->glmpdfPlaceText( strtoupper(html_entity_decode($t['member_name'],ENT_QUOTES,"utf-8")), 60, 138, 'left', 'black', -250, 'position=center rotate=90'); - - // Display values - $this->glmpdfSetFont( "Helvetica-Bold", 26.0 ); - $this->glmpdfPlaceText( html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8"), 280, 170, "center", 'black', -370, ''); - $this->glmpdfSetFont( "Helvetica-Bold", 24.0 ); - $this->glmpdfPlaceText( html_entity_decode($t['ticket_name'],ENT_QUOTES,"utf-8"), 280, 140, "center", 'black', -370, '' ); - $this->glmpdfSetFont( "Helvetica-Bold", 20.0 ); -// $this->glmpdfPlaceText( html_entity_decode($t['section_name'],ENT_QUOTES,"utf-8"), 280, 130, "center", 'black', -370, '' ); - $this->glmpdfSetFont( "Helvetica", 18.0 ); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], 280, 110, "center", 'black', -370, '' ); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, 280, 110, "center", 'black', -370, '' ); - } - - $this->glmpdfSetFont( "Helvetica", 16.0 ); - - // Check for Ticket add-ons - if (isset($t['addons_sold']) && count($t['addons_sold']) > 0) { - $this->glmpdfSetFont( "Helvetica", 14.0 ); - foreach($t['addons_sold'] as $a) { - $addonText = $a['add_on_name']; - if (($a['add_on_type']['value']-0) == 2) { - $addonText = $addonText.', '.$a['quant'].' '.$a['unit_name']; - } - $this->glmpdfPlaceText( $addonText, 280, $this->glmpdfCurrentY, "center", 'black', -370, '' ); - } - } - - // Display NON-REFUNDABLE MESSAGE - $this->glmpdfSetFont( "Helvetica", 14.0 ); - $this->glmpdfPlaceText( "NON-REFUNDABLE", 280, $this->glmpdfCurrentY, "center", 'black', -300, ''); - - // Display address and contact information - if ($venueContact) { - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( html_entity_decode($this->config->term->prop->cap.' contact information',ENT_QUOTES,"utf-8"), 280, $this->glmpdfCurrentY-5, "center", 'black', -300, ''); - $this->glmpdfPlaceText( html_entity_decode($venueContact,ENT_QUOTES,"utf-8"), 280, $this->glmpdfCurrentY, "center", 'black', -300, ''); - } - - // Display address and contact information - if ($companyContact) { - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( html_entity_decode($companyContact,ENT_QUOTES,"utf-8"), 280, 25, "center", 'black', -380, ''); - } - - // Display additional voucher text at the bottom of the voucher if provided - $voucherText = ''; - if (trim($t['ticket_voucher_text']) != '') { - $voucherText = trim(html_entity_decode($t['ticket_voucher_text'],ENT_QUOTES,"utf-8")); - } elseif (trim($performanceDetail['voucher_text']) != '') { - $voucherText = trim(html_entity_decode($performanceDetail['voucher_text'],ENT_QUOTES,"utf-8")); - } - if ($voucherText != '') { - $this->glmpdfPlaceLine(1, 80, 20, 480, 20, 'black', false); - $this->glmpdfSetFont( "Helvetica-Bold", 14.0 ); -// $this->glmpdfPlaceBox(1, 80, 20, 400, 20, "black", "black"); - $this->glmpdfPlaceText( html_entity_decode($voucherText,ENT_QUOTES,"utf-8"), 280, 6, "center", 'black', -370, '' ); - } - - // $this->glmpdfPlaceText( $t['ticket_date']['date'].' - '.$t['ticket_time']['time'], 120, $this->glmpdfCurrentY, "left", 'black', 0, '' ); - - // Print barcode = {ticket_sold ID}-{person type}-{person_sequence} - $barcode = $this->addCheckCode($t['id']); - // If we're supposed to print barcode and voucher number on ticket - switch ($t['ticket_voucher_type']) { - - case 11: // Voucher/Ticket for Pickup - no Barcode - $this->glmpdfSetFont( "Helvetica-Bold", 20.0 ); - $this->glmpdfPlaceText( "Pickup at ".$this->config->term->prop->norm, 510, 140, 'left', 'black', -260, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 140, 'left', 'black', -260, 'position=center rotate=90'); - break; - - case 12; // Voucher/Ticket to be mailed Mailed - no Barcode - case 82; // Object Sold (i.e. books) to be mailed - no Barcode - $this->glmpdfSetFont( "Helvetica-Bold", 20.0 ); - $this->glmpdfPlaceText( "You will receive this by mail", 510, 140, 'left', 'black', -260, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 140, 'left', 'black', -260, 'position=center rotate=90'); - break; - - case 1: // Standard Voucher/Ticket with Barcode - case 81; // Object Sold (i.e. books) to be claimed - with Barcode - default: - $this->glmpdfSetFont( 'barcode', 54 ); - $this->glmpdfPlaceText( "*$barcode*", 510, 140, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 140, 'left', 'black', -260, 'position=center rotate=90'); - break; - - } - - $this->glmpdfPlaceText( "Order #".$order['id'], 552, 140, 'left', 'black', 0, 'position=center rotate=90'); - - // Check if we need to display a coupon -// if( ++$numb_tickets % $this->pdfCouponInterval == 0 ) -// $this->printCoupon(); - - } // Each voucher - - // Make sure we print the minimum number of coupons -// $numb_coupons = 0; -// while( $numb_coupons < $this->pdfMinCoupons ) { -// $this->printCoupon(); -// $numb_coupons++; -// } - - // Close PDF setup and send to user's browser - $this->glmpdfSendToBrowser( '', 'voucher.pdf' ); - - if ($venueImageFile) { - unlink($venueImageFile); - } - if ($parkingImageFile) { - unlink($parkingImageFile); - } - if ($sectionImageFile) { - unlink($sectionImageFile); - } - if ($sectionImageFile) { - unlink($sectionImageFile); - } - - } - - - // function to print a coupon - function printCoupon() - { - // Print a Coupon - $this->glmpdfNextForm(); - $this->glmpdfPlaceBox( $this->borderWidth, 0, 142, 281, 142, $this->borderColor ); - - // Place Coupon Image - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Coupon Title', 85, 130, "center", 'black' ); - $this->glmpdfPlaceText( 'Expires on: 1/1/2020', 85, 75 ); - $this->glmpdfSetFont( "Times-Bold", 30.0 ); - $this->glmpdfPlaceText( "COUPON", 85, 95, "center", 'lightgrey' ); - $this->glmpdfSetFont( "Helvetica", 8.0 ); - $this->glmpdfPlaceTextBox( 'This is a coupon description. It describes this coupon.', 5, 55, 274, 40, "left", 'black' ); - $this->glmpdfSetFont( "Helvetica-Bold", 8.5 ); - $this->glmpdfPlaceText( "Mackinaw Area Visitors Bureau - Mackinaw City, MI - 800-666-0160", 140.5, 2, "center", 'darkblue' ); - - } - - /* - * Function to add check character to end of voucher number - * - * Uses config->voucher_check_secret and voucher # to create MD5 string - * then takes last hex character off of that string and shifts it up to - * always be a character (adds 16 to numbers and 10 to the upper-case - * version of the character). - * i.e. 0 = A, 9 = J, A = K, F = - * - */ - public function addCheckCode($voucherNumb) - { - - // Create MD5 string using voucher number and secret - $md5 = md5($voucherNumb.$this->config->voucher_check_secret); - - // Get last character code of the last character in the MD5 - $cc = strtoupper(substr($md5, -2)); - $cc[0] = $this->shiftCheckCodeCharacter($cc[0]); - $cc[1] = $this->shiftCheckCodeCharacter($cc[1]); - - // Return voucher number with the new character on the end - $voucherNumb .= $cc; - return $voucherNumb; - - } - - private function shiftCheckCodeCharacter($c) { - - $x = ord($c); - - // If it's a digit, add 16 - if ($x < 65) { - $x += 17; - // otherwise, add 10 - } else { - $x += 10; - } - - // Also skip the letter O - if (x >= ord('O')) { - $x += 1; - } - - return chr($x); - } - -} // class - -// Absolutely nothing after next line -?> \ No newline at end of file diff --git a/legacy/models/vouchers/MackinacFerry/voucher.php b/legacy/models/vouchers/MackinacFerry/voucher.php deleted file mode 100644 index b999c87..0000000 --- a/legacy/models/vouchers/MackinacFerry/voucher.php +++ /dev/null @@ -1,1133 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: printVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once PDF_ABSTRACT; -$Pdf = new GlmPdf(); - -/** - * PdfVoucher class - * - * @category PdfVoucher - * @package PDFLib - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @link <> -*/ -class PdfVoucher extends GlmPdf -{ - - public $borderWidth = 1; - public $borderColor = 'black'; - public $pdfCouponInterval = 5; - public $pdfMinCoupons = 3; - public $config; - private $is; - private $dbh; - - function __construct($order, $vouchers, $member, $dbh, $config, $couponTest = false) - { - - $this->dbh = $dbh; - $this->config = $config; - - // Load image server support - require_once IMAGE_SERVER_ABSTRACT; - $this->is = new ImageServerAbstract(); - - // if debug.glmpdf is set in the configs/common.ini file in the CommonApp directory, do grids on PDFs - define ('GLMPDF_DEBUG', $this->config->debug->glmpdf); - - // The following produces a color test sheet. There is no return from that call. - // $this->glmpdfShowValidColors(); exit; - - // Start with cover page. - $this->glmpdfSetForms( - 1, - array( - 1 => array( 'x' => 0, 'y' => 0, 'xs' => 613, 'ys' => 792 ) - ), - 'US Letter' - ); - - // Start page - $this->glmpdfStart( $this->config->owner->name, "Gaslight Media", "Ticket System Receipt/Vouchers" ); - - if( !$this->glmpdfAddFont( 'barcode', 'barcode/FREE3OF9.TTF' ) ) - { - echo 'ERROR: Unable to add barcode font.

    - Did you place the barcode font provided in docs/BarcodeFonts into - a system fonts directory ("/usr/share/fonts/truetype/Barcode")? - Also check the GLMPDF_PDF_FONT_DIR setting in GlmPdf.php.'; - exit; - } - - // Get images to tmp files - if (trim($member['image']) != '') { - $venueImageFile = $this->is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$member['image']); - if ($venueImageFile) { - $venueImage = $this->glmpdfOpenImage($venueImageFile); - - // If failure getting the image - if ($venueImage == false) { - $venueImageFile = false; - } - } - } else { - $venueImageFile = false; - } - - if (trim($member['parking_map']) != '') { - $parkingImageFile = $this->is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$member['parking_map']); - if ($parkingImageFile) { - $parkingImage = $this->glmpdfOpenImage($parkingImageFile); - - // If failure getting the image - if ($parkingImage == false) { - $parkingImageFile = false; - } - } - } else { - $parkingImageFile = false; - } - - if (trim($member['ticket_sec_map']) != '') { - $sectionImageFile = $this->is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$member['ticket_sec_map']); - if ($sectionImageFile) { - $sectionImage = $this->glmpdfOpenImage($sectionImageFile); - - // If failure getting the image - if ($sectionImage == false) { - $sectionImageFile = false; - } - } - } else { - $sectionImageFile = false; - } - - // Load entrance class - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; - $Entrances = new EventManagementAdminEntrances($dbh, $config); - - // Load performance class - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($dbh, $config); - - // Load Voucher Coupons class and get coupons list for display - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataVoucherCoupons.php'; - $VoucherCoupons = new EventManagementDataVoucherCoupons($dbh, $config); - - // Load ticket packages data class - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($dbh, $config); - - - // If no date has been supplied - make it today - if (isset($_REQUEST['date']) && $_REQUEST['date'] != '') { - $date = $_REQUEST['date']; - } else { - $date = date('m/d/Y', time()); - } - - $vc = $VoucherCoupons->getCouponsForDisplay($date); - - // Setup footers -/* - $footer = 'For assistance call '.$this->config->owner->phone; - if ($this->config->owner->toll_free != '') { - $footer .= ' or '.$this->config->owner->toll_free; - } -*/ - - if (!$couponTest) { - - $this->glmpdfNextForm(); - - - /* Cover Page */ - - // Header - if ($venueImageFile) { - $coverImage = $this->glmpdfOpenImage($venueImageFile); - $this->glmpdfPlaceImage($coverImage, 30, 690, .5, false, 'center', 280, 140); - } - $this->glmpdfSetFont( "Helvetica-Bold", 18.0 ); // Header Text - $this->glmpdfPlaceText( $config->owner->name, 340, 750, "center", 'black', -400 ); - $this->glmpdfSetFont( "Helvetica", 14.0 ); - $this->glmpdfPlaceText( $config->owner->short_name." - ".$member['name'], 340, $this->glmpdfCurrentY-10, "center", 'black', -400 ); - $this->glmpdfPlaceText( $member['addr1'], 340, $this->glmpdfCurrentY, "center", 'black', -400 ); - $this->glmpdfPlaceText( $member['city'].", ".$member['state']['name']." ".$member['zip'], 340, $this->glmpdfCurrentY, "center", 'black', -400 ); - - // Sold To Information - $valCol = 60; - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( $this->config->term->order->cap." ID: ".trim($order['id']), $valCol, 650, "left", 'black' ); - $this->glmpdfPlaceText( trim($order['fname'].' '.$order['lname']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - $this->glmpdfPlaceText( trim($order['addr1']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - if( trim($order['addr2']) != '' ) - $this->glmpdfPlaceText( trim($order['addr2']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - $this->glmpdfPlaceText( trim($order['city']).', '.$order['state']['value'].' '.trim($order['zip']).' '.$order['country']['value'], $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - - // Purchace/Charge information - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $promptCol = 330; - $valCol = 420; - $this->glmpdfPlaceText( "Date of Purchase:", $promptCol, 650, "left", 'black' ); - $this->glmpdfPlaceText( $order['purchase_date']['date'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Card Type:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['cctype'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Name on Card:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccname'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Card Number:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccnumber'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Confirmation:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccconf'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Total Charged:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['charge_total'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - - // Purchase Summary - $ticNumbCol = 20; - $perfNameCol = 80; - $ticNameCol = 200; - $secNameCol = 370; - $dateCol = 440; - $this->glmpdfPlaceText( '', $ticNumbCol, 550, "center", 'black', 0, ''); - - $this->glmpdfSetFont( "Helvetica", 8.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap, $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - $this->glmpdfPlaceText( $this->config->term->performance->cap, $perfNameCol, $this->glmpdfLastY, "left", 'black', -110, ''); - $this->glmpdfPlaceText( $this->config->term->ticket->cap, $ticNameCol, $this->glmpdfLastY, "left", 'black', -160, ''); - $this->glmpdfPlaceText( $this->config->term->section->cap, $secNameCol, $this->glmpdfLastY, "left", 'black', -60, ''); - $this->glmpdfPlaceText( 'Date / Time', $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - - $this->glmpdfPlaceText( '', $ticNumbCol, $this->glmpdfCurrentY-3, "center", 'black', 0, ''); - - foreach( $vouchers as $t ) { - - $voucherCode = $this->addCheckCode($t['id']); - - $this->glmpdfSetFont( "Helvetica", 8.0 ); - if (!$t['ticket_package']) { - $this->glmpdfPlaceText( $voucherCode, $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - } else { - $this->glmpdfPlaceText( '', $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - } - $this->glmpdfPlaceText( html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8"), $perfNameCol, $this->glmpdfLastY, "left", 'black', -110, ''); - $this->glmpdfPlaceText( html_entity_decode($t['ticket_name'],ENT_QUOTES,"utf-8"), $ticNameCol, $this->glmpdfLastY, "left", 'black', -160, ''); - if (!$t['is_package']['value']) { - $this->glmpdfPlaceText( html_entity_decode($t['section_name'],ENT_QUOTES,"utf-8"), $secNameCol, $this->glmpdfLastY, "left", 'black', -60, ''); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - } - } - - // Check for Ticket add-ons - if (isset($t['addons_sold']) && count($t['addons_sold']) > 0) { - foreach($t['addons_sold'] as $a) { - - $addonText = $a['add_on_name']; - if (($a['add_on_type']['value']-0) == 2) { - $addonText = $addonText.', '.$a['quant'].' '.$a['unit_name']; - } - $this->glmpdfPlaceText( html_entity_decode($addonText,ENT_QUOTES,"utf-8"), $ticNameCol+10, $this->glmpdfCurrentY, "left", 'black', -240, ''); - } - } - - } - - // Special Needs - $this->glmpdfSetFont( "Helvetica", 9.0 ); - if (trim($order['special_needs']) != '') { - $this->glmpdfPlaceText( "Special Needs:", 20, $this->glmpdfCurrentY-30, "left", 'black' ); - $this->glmpdfPlaceTextBox( $order['special_needs'], 100, $this->glmpdfCurrentY+16, 450, 50, "left", 'black' ); - } - - // General Member Policies - if (trim($member['def_ticket_pol']) != '') { - $this->glmpdfPlaceText( "Policies:", 20, $this->glmpdfCurrentY-30, "left", 'black' ); - $this->glmpdfPlaceTextBox( $member['def_ticket_pol'], 100, $this->glmpdfCurrentY+16, 450, 50, "left", 'black' ); - } - - } - - // Standard voucher & coupon form - 1 Voucher, 8 coupons - $voucher1_coupon8 = array( - 'forms' => 10, - 'layout' => array( - 1 => array( 'x' => 25, 'y' => 515, 'xs' => 560, 'ys' => 232 ), - 2 => array( 'x' => 25, 'y' => 325, 'xs' => 375, 'ys' => 150 ), - 3 => array( 'x' => 415, 'y' => 325, 'xs' => 170, 'ys' => 150 ), - 4 => array( 'x' => 25, 'y' => 160, 'xs' => 170, 'ys' => 150 ), - 5 => array( 'x' => 210, 'y' => 160, 'xs' => 375, 'ys' => 150 ), - 6 => array( 'x' => 25, 'y' => 25, 'xs' => 137, 'ys' => 120 ), - 7 => array( 'x' => 166, 'y' => 25, 'xs' => 137, 'ys' => 120 ), - 8 => array( 'x' => 307, 'y' => 25, 'xs' => 137, 'ys' => 120 ), - 9 => array( 'x' => 448, 'y' => 25, 'xs' => 137, 'ys' => 120 ), - 10 => array( 'x' => 25, 'y' => 25, 'xs' => 419, 'ys' => 120 ), - ) - ); - - // Package vouchers - 3 vouchers, no coupons - $voucher3_coupon0 = array( - 'forms' => 3, - 'layout' => array( - 1 => array( 'x' => 25, 'y' => 561, 'xs' => 560, 'ys' => 176 ), - 2 => array( 'x' => 25, 'y' => 308, 'xs' => 560, 'ys' => 176 ), - 3 => array( 'x' => 25, 'y' => 55, 'xs' => 560, 'ys' => 176 ) - ) - ); - - // Now setup ticket forms - $this->glmpdfSetForms( - $voucher1_coupon8['forms'], - $voucher1_coupon8['layout'], - 'US Letter' - ); - -/*********CPS - // Display Parking Map - if ($parkingImage) { - $this->glmpdfNextForm(); - $this->glmpdfPlaceImage( $parkingImage, 0, 2, 0, 'meet', 'center', 280, 125); - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Parking Map', 140, 130, "center", 'black' ); - } - - // Display Section Map - if ($sectionImage) { - $this->glmpdfNextForm(); - $this->glmpdfPlaceImage( $sectionImage, 0, 2, 0, 'meet', 'center', 280, 125); - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Section Map', 140, 130, "center", 'black' ); - } -*/ - - // Clear performance image loaded flag - $performanceLoaded = false; - -// $this->glmpdfNextPage(); - $firstVoucherPageSet = false; - - // Process Vouchers - For each type of ticket purchased - $numb_tickets = 0; - $counterSQL = ''; - $packageVouchersPrintedSeparately = ''; - $allPackageVouchersSeparate = true; - $packageVoucher = false; - $packageTicketName = ''; - $doDashes = false; - $skipNextFormAdvance = false; - - foreach( $vouchers as $t ) - { - - // Flag to determine if this voucher will be displayed (vouchers not displayed if it's a package ticket) - $displaying_this_voucher = false; - - if (!$couponTest) { - - // Check if the current voucher is a new package that has vouchers that print - if ($t['is_package']['value']) { - - $packageVoucher = true; - - // Check if any vouchers for this package print separately - $ticketPackage = $TicketPackages->getList('package = '.$t['ticket']); - if (is_array($ticketPackage) && count($ticketPackage) > 0) { - - // For each ticket in the package - foreach ($ticketPackage as $tp) { - - // Check if it requires a separate voucher - if ($tp['separate_voucher']['value']) { - - // Set this flag to the package sold ID (same for all vouchers for a package) so we can tell if we hit the end of the package - $packageVouchersPrintedSeparately = $t['package_sold_id']; - $packagePerformanceName = $t['performance_name']; - $packageTicketName = $t['ticket_name']; - } else { - $allPackageVouchersSeparate = false; - } - } - } - - // If we found one, then switch layouts. - if ($packageVouchersPrintedSeparately != '') { - $this->glmpdfSetForms( - $voucher3_coupon0['forms'], - $voucher3_coupon0['layout'], - 'US Letter' - ); - $voucherPageStarted = false; - $skipNextFormAdvance = false; - $doDashes = true; - if ($numb_tickets) { - $skipNextFormAdvance = true; - } - } - - // If we have a package with separate vouchers - } else { - $packageVoucher = false; - } - - if ($packageVouchersPrintedSeparately != '') { - - // Check if we're now past the package that had vouchers printed separately - if ($t['package_sold_id'] != $packageVouchersPrintedSeparately) { - - $this->glmpdfSetForms( - $voucher1_coupon8['forms'], - $voucher1_coupon8['layout'], - 'US Letter' - ); - $voucherPageStarted = false; - $packageVouchersPrintedSeparately = ''; - $skipNextFormAdvance = true; - } - - } - - // Check if this voucher is a print separate voucher for a package - $printVoucher = false; - if ($t['ticket_package']) { - - // Get ticket_package data - $ticketPackage = $TicketPackages->getList('package = '.$t['ticket_package'].' AND ticket = '.$t['ticket']); - - // If Separate Voucher, override and display voucher. - if ($ticketPackage[0]['separate_voucher']['value']) { - $printVoucher = true; - } - - } else { - $printVoucher = true; - } - - // Check if this is a package voucher and we are printing all package tickets separately - if ($packageVoucher && $allPackageVouchersSeparate) { - $printVoucher = false; - } - - // If this isn't a package ticket (we're not printing separate vouchers at this time) - if ($printVoucher) { - - - if ($packageVouchersPrintedSeparately) { - - // If the first voucher page hasn't been set - if (!$voucherPageStarted) { - $this->glmpdfNextPage(); - $voucherPageStarted = true; - - if ($doDashes) { - // Print perforations - $this->glmpdfPlaceLine(1, 0, -38, 560, -38, $color = "dimgray", $dash = true, $d_a = 1, $d_b = 5); - $this->glmpdfPlaceLine(1, 0, -291, 560, -291, $color = "dimgray", $dash = true, $d_a = 1, $d_b = 5); - $doDashes = false; - } - - } - - $displaying_this_voucher = true; - - if ($numb_tickets++ > 0) { - - if ($skipNextFormAdvance) { - $skipNextFormAdvance = false; - } else { - $this->glmpdfNextForm(); - } - } - $this->glmpdfPlaceBox( $this->borderWidth, 0, 176, 560, 176, $this->borderColor ); - - // Display Logo - Only get performance image if it's not currently loaded - if ($performanceLoaded != $t['performance']) { - - $performanceDetail = $Performances->getPerformanceDetail($t['performance']); - - // If we have an image but it's the wrong one, dump the temp file - if ($performanceImageFile) { - unlink($performanceImageFile); - } - - // This performance image is not currently loaded - so do that now - - $performanceImageFile = $this->is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$performanceDetail['image']); - if ($performanceImageFile) { - // If we have the image, then load it - $performanceImage = $this->glmpdfOpenImage($performanceImageFile); - $performanceLoaded = $t['performance']; - } else { - - // otherwise, try the venue image - $performanceLoaded = $venueImage; - } - - } - - // If we have the performance image, display it - $haveTopImage = false; - if ($performanceImage) { - $this->glmpdfPlaceImage( $performanceImage, 85, 100, 1, 'meet', 'center', 70, 75); - $haveTopImage = true; - } elseif ($venueImageFile) { - $this->glmpdfPlaceImage($coverImage, 85, 100, 1, 'meet', 'center', 70, 75); - $haveTopImage = true; - } - - // Place owner name at top possitioned by whether or not there's an image supplied - $this->glmpdfSetFont( "Helvetica-Bold", 20.0 ); - if ($haveTopImage) { - $this->glmpdfPlaceText( $config->owner->name, 315, 131, "center", 'black', -300, ''); - } else { - $this->glmpdfPlaceText( $config->owner->name, 280, 131, "center", 'black', -350, ''); - } - - // If ticket has already been claimed, then mark ticket - if ($t['time_claimed']['date'] != '') { - $this->glmpdfSetFont( "Times-Bold", 72.0 ); - $this->glmpdfPlaceText( "CLAIMED", 110, 80, "left", 'orangered', 0, '' ); // last parameter can be things like "rotate=90" - } - - // Ticket Information Area - $this->glmpdfPlaceLine(1, 80, 0, 80, 176, $color = "black", $dash = false, $d_a = 1, $d_b = 1); - $this->glmpdfPlaceLine(1, 480, 0, 480, 176, $color = "black", $dash = false, $d_a = 1, $d_b = 1); - - // If part of a package, print the package name it's part of. - if ($packageTicketName && !$t['is_package']['value']) { - - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Part of:', 7, 40, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Helvetica-Bold", 12.0 ); - $this->glmpdfPlaceText( $packagePerformanceName, 30, 88, 'left', 'black', -165, 'position=center rotate=90'); - $this->glmpdfPlaceText( $packageTicketName, 60, 88, 'left', 'black', -165, 'position=center rotate=90'); - - } else { - - // Left End of Ticket - NOTE: use only "left" in glmpdfPlaceText - use "position=..." in optlist instead. - if (($t['entrance']-0) > 0) { - $entranceDetail = $Entrances->getEntranceDetail($t['entrance']); - $this->glmpdfPlaceBox(1, 0, 0, 80, -232, '', $entranceDetail['color']['name'], 'miter'); - } - - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Departing from:', 7, 40, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Helvetica-Bold", 16.0 ); - $this->glmpdfPlaceText( strtoupper(html_entity_decode($t['entrance_name'],ENT_QUOTES,"utf-8")), 30, 116, 'left', 'black', -224, 'position=center rotate=90'); - $this->glmpdfPlaceText( strtoupper(html_entity_decode($t['member_name'],ENT_QUOTES,"utf-8")), 60, 116, 'left', 'black', -224, 'position=center rotate=90'); - - } - - // Display values - $this->glmpdfSetFont( "Helvetica-Bold", 16.0 ); - $this->glmpdfPlaceText( html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8"), 280, 91, "center", 'black', -370, ''); - $this->glmpdfSetFont( "Helvetica-Bold", 12.0 ); - $this->glmpdfPlaceText( html_entity_decode($t['ticket_name'],ENT_QUOTES,"utf-8"), 280, 77, "center", 'black', -370, '' ); - - $this->glmpdfSetFont( "Helvetica", 10.0 ); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], 280, 65, "center", 'black', -370, '' ); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, 280, 65, "center", 'black', -370, '' ); - } - - $this->glmpdfSetFont( "Helvetica", 16.0 ); - - // Put package line for voucher here - - // Check for Ticket add-ons -/* No addons for packages - if (isset($t['addons_sold']) && count($t['addons_sold']) > 0) { - $this->glmpdfSetFont( "Helvetica", 14.0 ); - foreach($t['addons_sold'] as $a) { - $addonText = $a['add_on_name']; - if (($a['add_on_type']['value']-0) == 2) { - $addonText = $addonText.', '.$a['quant'].' '.$a['unit_name']; - } - $this->glmpdfPlaceText( $addonText, 280, $this->glmpdfCurrentY, "center", 'black', -370, '' ); - } - } -*/ - // Non-Refundable and other Fixed text for body of Voucher - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( "NON-REFUNDABLE", 280, $this->glmpdfCurrentY, "center", 'black', -300, ''); - - // Display address and contact information - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $contactInfo = $this->config->owner->name.' - ' - .$this->config->owner->address1.' - ' - .($this->config->owner->address2 != '' ? ', '.$this->config->owner->address2 : '') - .$this->config->owner->city.', ' - .$this->config->owner->state.' ' - .$this->config->owner->zip.' - ' - .$this->config->owner->phone - .($this->config->owner->toll_free != '' ? ' - '.$this->config->owner->toll_free : ''); - $this->glmpdfPlaceText( html_entity_decode($contactInfo,ENT_QUOTES,"utf-8"), 280, 25, "center", 'black', -380, ''); - - // Display additional voucher text at the bottom of the voucher if provided - $voucherText = ''; - if (trim($t['ticket_voucher_text']) != '') { - $voucherText = trim(html_entity_decode($t['ticket_voucher_text'],ENT_QUOTES,"utf-8")); - } elseif (trim($performanceDetail['voucher_text']) != '') { - $voucherText = trim(html_entity_decode($performanceDetail['voucher_text'],ENT_QUOTES,"utf-8")); - } - if ($voucherText != '') { - $this->glmpdfPlaceLine(1, 80, 20, 480, 20, 'black', false); - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - // $this->glmpdfPlaceBox(1, 80, 20, 400, 20, "black", "black"); - $this->glmpdfPlaceText( html_entity_decode($voucherText,ENT_QUOTES,"utf-8"), 280, 6, "center", 'black', -370, '' ); - } - - // $this->glmpdfPlaceText( $t['ticket_date']['date'].' - '.$t['ticket_time']['time'], 120, $this->glmpdfCurrentY, "left", 'black', 0, '' ); - - // Print barcode = {ticket_sold ID}-{person type}-{person_sequence} - $barcode = $this->addCheckCode($t['id']); - - // If we're supposed to print barcode and voucher number on ticket - switch ($t['ticket_voucher_type']) { - case 11: - $this->glmpdfSetFont( "Courier-Bold", 10.0 ); - $this->glmpdfPlaceText( "Pickup ".$this->config->term->voucher->norm." at ".$this->config->term->prop->norm, 510, 88, 'left', 'red', -170, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 88, 'left', 'black', -170, 'position=center rotate=90'); - break; - case 12; - $this->glmpdfSetFont( "Courier-Bold", 10.0 ); - $this->glmpdfPlaceText( "You will receive ".$this->config->term->voucher->cap." by mail", 510, 88, 'left', 'red', -170, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 88, 'left', 'black', -170, 'position=center rotate=90'); - break; - case 1: - default: - $this->glmpdfSetFont( 'barcode', 40 ); - $this->glmpdfPlaceText( "*$barcode*", 510, 88, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 10.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 88, 'left', 'black', -224, 'position=center rotate=90'); - break; - } - - $this->glmpdfPlaceText( "Order #".$order['id'], 552, 88, 'left', 'black', 0, 'position=center rotate=90'); - - // Display Footer - $this->glmpdfSetFont( "Helvetica-Bold", 8.5 ); - $this->glmpdfPlaceText( $footer, 140.5, 2, "center", 'darkblue' ); - - - // Print a normal voucher - } else { - - // If the first voucher page hasn't been set - if (!$voucherPageStarted) { - $this->glmpdfNextPage(); - $voucherPageStarted = true; - - if ($doDashes) { - // Print perforations - $this->glmpdfPlaceLine(1, 0, -11, 560, -11, $color = "dimgray", $dash = true, $d_a = 1, $d_b = 5); - $this->glmpdfPlaceLine(1, 0, -265, 560, -265, $color = "dimgray", $dash = true, $d_a = 1, $d_b = 5); - $doDashes = false; - } - - } - - $displaying_this_voucher = true; - - if ($numb_tickets++ > 0) { - - if ($skipNextFormAdvance) { - $skipNextFormAdvance = false; - } else { - $this->glmpdfNextForm(); - } - } - $this->glmpdfPlaceBox( $this->borderWidth, 0, 232, 560, 232, $this->borderColor ); - - // Display Logo - Only get performance image if it's not currently loaded - if ($performanceLoaded != $t['performance']) { - - $performanceDetail = $Performances->getPerformanceDetail($t['performance']); - - // If we have an image but it's the wrong one, dump the temp file - if ($performanceImageFile) { - unlink($performanceImageFile); - } - - // This performance image is not currently loaded - so do that now - - $performanceImageFile = $this->is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$performanceDetail['image']); - if ($performanceImageFile) { - // If we have the image, then load it - $performanceImage = $this->glmpdfOpenImage($performanceImageFile); - $performanceLoaded = $t['performance']; - } else { - - // otherwise, try the venue image - $performanceLoaded = $venueImage; - } - - } - - // If we have the performance image, display it - $haveTopImage = false; - if ($performanceImage) { - $this->glmpdfPlaceImage( $performanceImage, 85, 154, 1, 'meet', 'center', 70, 75); - $haveTopImage = true; - } elseif ($venueImageFile) { - $this->glmpdfPlaceImage($coverImage, 85, 154, 1, 'meet', 'center', 70, 75); - $haveTopImage = true; - } - - // Place owner name at top possitioned by whether or not there's an image supplied - $this->glmpdfSetFont( "Helvetica-Bold", 20.0 ); - if ($haveTopImage) { - $this->glmpdfPlaceText( $config->owner->name, 315, 185, "center", 'black', -300, ''); - } else { - $this->glmpdfPlaceText( $config->owner->name, 280, 185, "center", 'black', -350, ''); - } - - // If ticket has already been claimed, then mark ticket - if ($t['time_claimed']['date'] != '') { - $this->glmpdfSetFont( "Times-Bold", 72.0 ); - $this->glmpdfPlaceText( "CLAIMED", 110, 80, "left", 'orangered', 0, '' ); // last parameter can be things like "rotate=90" - } - - // Ticket Information Area - $this->glmpdfPlaceLine(1, 80, 0, 80, 232, $color = "black", $dash = false, $d_a = 1, $d_b = 1); - $this->glmpdfPlaceLine(1, 480, 0, 480, 232, $color = "black", $dash = false, $d_a = 1, $d_b = 1); - - // If part of a package, print the package name it's part of. - if ($packageTicketName && !$t['is_package']['value']) { - - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Part of:', 7, 40, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Helvetica-Bold", 16.0 ); - $this->glmpdfPlaceText( $packagePerformanceName, 30, 116, 'left', 'black', -224, 'position=center rotate=90'); - $this->glmpdfPlaceText( $packageTicketName, 60, 116, 'left', 'black', -224, 'position=center rotate=90'); - - } else { - - // Voucher left end text overrides departing from text - if ($t['ticket_voucher_leftend_text'] != '') { - $this->glmpdfPlaceBox(1, 0, 0, 80, -232, '', 'lightlilac', 'miter'); - $this->glmpdfSetFont( "Helvetica-Bold", 16.0 ); - $this->glmpdfPlaceText( strtoupper(html_entity_decode($t['ticket_voucher_leftend_text'],ENT_QUOTES,"utf-8")), 40, 116, 'left', 'black', -224, 'position=center rotate=90'); - } else { - // Left End of Ticket - NOTE: use only "left" in glmpdfPlaceText - use "position=..." in optlist instead. - if (($t['entrance']-0) > 0) { - $entranceDetail = $Entrances->getEntranceDetail($t['entrance']); - $this->glmpdfPlaceBox(1, 0, 0, 80, -232, '', $entranceDetail['color']['name'], 'miter'); - } - - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Departing from:', 7, 40, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Helvetica-Bold", 16.0 ); - $this->glmpdfPlaceText( strtoupper(html_entity_decode($t['entrance_name'],ENT_QUOTES,"utf-8")), 30, 116, 'left', 'black', -224, 'position=center rotate=90'); - $this->glmpdfPlaceText( strtoupper(html_entity_decode($t['member_name'],ENT_QUOTES,"utf-8")), 60, 116, 'left', 'black', -224, 'position=center rotate=90'); - } - } - - // Display values - $this->glmpdfSetFont( "Helvetica-Bold", 20.0 ); - $this->glmpdfPlaceText( html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8"), 280, 135, "center", 'black', -370, ''); - $this->glmpdfSetFont( "Helvetica-Bold", 18.0 ); - $this->glmpdfPlaceText( html_entity_decode($t['ticket_name'],ENT_QUOTES,"utf-8"), 280, 114, "center", 'black', -370, '' ); - - $this->glmpdfSetFont( "Helvetica", 14.0 ); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], 280, 96, "center", 'black', -370, '' ); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, 280, 96, "center", 'black', -370, '' ); - } - - $this->glmpdfSetFont( "Helvetica", 16.0 ); - - // Put package line for voucher here - - // Check for Ticket add-ons - if (isset($t['addons_sold']) && count($t['addons_sold']) > 0) { - $this->glmpdfSetFont( "Helvetica", 14.0 ); - foreach($t['addons_sold'] as $a) { - $addonText = $a['add_on_name']; - if (($a['add_on_type']['value']-0) == 2) { - $addonText = $addonText.', '.$a['quant'].' '.$a['unit_name']; - } - $this->glmpdfPlaceText( $addonText, 280, $this->glmpdfCurrentY, "center", 'black', -370, '' ); - } - } - - // Non-Refundable and other Fixed text for body of Voucher - $this->glmpdfSetFont( "Helvetica", 12.0 ); - $this->glmpdfPlaceText( "NON-REFUNDABLE", 280, $this->glmpdfCurrentY, "center", 'black', -300, ''); - - // Display address and contact information - $this->glmpdfSetFont( "Helvetica", 12.0 ); - $contactInfo = $this->config->owner->name.' - ' - .$this->config->owner->address1.' - ' - .($this->config->owner->address2 != '' ? ', '.$this->config->owner->address2 : '') - .$this->config->owner->city.', ' - .$this->config->owner->state.' ' - .$this->config->owner->zip.' - ' - .$this->config->owner->phone - .($this->config->owner->toll_free != '' ? ' - '.$this->config->owner->toll_free : ''); - $this->glmpdfPlaceText( html_entity_decode($contactInfo,ENT_QUOTES,"utf-8"), 280, 25, "center", 'black', -380, ''); - - // Display additional voucher text at the bottom of the voucher if provided - $voucherText = ''; - if (trim($t['ticket_voucher_text']) != '') { - $voucherText = trim(html_entity_decode($t['ticket_voucher_text'],ENT_QUOTES,"utf-8")); - } elseif (trim($performanceDetail['voucher_text']) != '') { - $voucherText = trim(html_entity_decode($performanceDetail['voucher_text'],ENT_QUOTES,"utf-8")); - } - if ($voucherText != '') { - $this->glmpdfPlaceLine(1, 80, 20, 480, 20, 'black', false); - $this->glmpdfSetFont( "Helvetica-Bold", 14.0 ); - // $this->glmpdfPlaceBox(1, 80, 20, 400, 20, "black", "black"); - $this->glmpdfPlaceText( html_entity_decode($voucherText,ENT_QUOTES,"utf-8"), 280, 6, "center", 'black', -370, '' ); - } - - // $this->glmpdfPlaceText( $t['ticket_date']['date'].' - '.$t['ticket_time']['time'], 120, $this->glmpdfCurrentY, "left", 'black', 0, '' ); - - // Print barcode = {ticket_sold ID}-{person type}-{person_sequence} - $barcode = $this->addCheckCode($t['id']); - - // If we're supposed to print barcode and voucher number on ticket - switch ($t['ticket_voucher_type']) { - case 11: - $this->glmpdfSetFont( "Courier-Bold", 12.0 ); - $this->glmpdfPlaceText( "Pickup ".$this->config->term->voucher->norm." at ".$this->config->term->prop->norm, 510, 116, 'left', 'red', -224, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 116, 'left', 'black', -224, 'position=center rotate=90'); - break; - case 12; - $this->glmpdfSetFont( "Courier-Bold", 12.0 ); - $this->glmpdfPlaceText( "You will receive ".$this->config->term->voucher->cap." by mail", 510, 116, 'left', 'red', -224, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 116, 'left', 'black', -224, 'position=center rotate=90'); - break; - case 1: - default: - $this->glmpdfSetFont( 'barcode', 48 ); - $this->glmpdfPlaceText( "*$barcode*", 510, 116, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Courier", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 116, 'left', 'black', -224, 'position=center rotate=90'); - break; - } - - $this->glmpdfPlaceText( "Order #".$order['id'], 552, 116, 'left', 'black', 0, 'position=center rotate=90'); - - // Display Footer - $this->glmpdfSetFont( "Helvetica-Bold", 8.5 ); - $this->glmpdfPlaceText( $footer, 140.5, 2, "center", 'darkblue' ); - - } // End of normal voucher - - } // Printing Voucher - - } - - if ($displaying_this_voucher) { - - if (!$packageVouchersPrintedSeparately) { - - $this->glmpdfNextForm(); - - // Get table of Ads/Coupons - if (isset($vc[1])) { - - // Get the key for the current ad/coupon for position 1 - $k = key($vc[1]); - - // If the max count is -1 (unlimited) or more than the current display count - if ($vc[1][$k]['max_display_count'] < 0 || $vc[1][$k]['max_display_count'] > $vc[1][$k]['display_count']) { - - // Display the ad/coupon and save SQL to update the display count - $counterSQL .= $this->displayCoupon(current($vc[1]), 375, 150); - - // Incriment the local display count - $vc[1][$k]['display_count']++; - } - - // Advance to the next ad/coupon for this position. If all used, start over. - if (next($vc[1]) === false) { - reset($vc[1]); - } - } - - // Advance to the next form - $this->glmpdfNextForm(); - - // Do the same for the remaining ad/coupon forms - - if (isset($vc[2])) { - $k = key($vc[2]); - if ($vc[2][$k]['max_display_count'] < 0 || $vc[2][$k]['max_display_count'] > $vc[2][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[2]), 170, 150); - $vc[2][$k]['display_count']++; - } - if (next($vc[2]) === false) { - reset($vc[2]); - } - } - $this->glmpdfNextForm(); - - if (isset($vc[3])) { - $k = key($vc[3]); - if ($vc[3][$k]['max_display_count'] < 0 || $vc[3][$k]['max_display_count'] > $vc[3][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[3]), 170, 150); - $vc[3][$k]['display_count']++; - } - if (next($vc[3]) === false) { - reset($vc[3]); - } - } - $this->glmpdfNextForm(); - - if (isset($vc[4])) { - $k = key($vc[4]); - if ($vc[4][$k]['max_display_count'] < 0 || $vc[4][$k]['max_display_count'] > $vc[4][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[4]), 375, 150); - $vc[4][$k]['display_count']++; - } - if (next($vc[4]) === false) { - reset($vc[4]); - } - } - $this->glmpdfNextForm(); - - if (isset($vc[5])) { - $k = key($vc[5]); - if ($vc[5][$k]['max_display_count'] < 0 || $vc[5][$k]['max_display_count'] > $vc[5][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[5]), 137, 120); - $vc[5][$k]['display_count']++; - } - if (next($vc[5]) === false) { - reset($vc[5]); - } - } - $this->glmpdfNextForm(); - - if (isset($vc[6])) { - $k = key($vc[6]); - if ($vc[6][$k]['max_display_count'] < 0 || $vc[6][$k]['max_display_count'] > $vc[6][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[6]), 137, 120); - $vc[6][$k]['display_count']++; - } - if (next($vc[6]) === false) { - reset($vc[6]); - } - } - $this->glmpdfNextForm(); - - if (isset($vc[7])) { - $k = key($vc[7]); - if ($vc[7][$k]['max_display_count'] < 0 || $vc[7][$k]['max_display_count'] > $vc[7][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[7]), 137, 120); - $vc[7][$k]['display_count']++; - } - if (next($vc[7]) === false) { - reset($vc[7]); - } - } - $this->glmpdfNextForm(); - - if (isset($vc[8])) { - $k = key($vc[8]); - if ($vc[8][$k]['max_display_count'] < 0 || $vc[8][$k]['max_display_count'] > $vc[8][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[8]), 137, 120); - $vc[8][$k]['display_count']++; - } - if (next($vc[8]) === false) { - reset($vc[8]); - } - } - $this->glmpdfNextForm(); - - if (isset($vc[9])) { - $k = key($vc[9]); - if ($vc[9][$k]['max_display_count'] < 0 || $vc[9][$k]['max_display_count'] > $vc[9][$k]['display_count']) { - $counterSQL .= $this->displayCoupon(current($vc[9]), 419, 120); - $vc[9][$k]['display_count']++; - } - if (next($vc[9]) === false) { - reset($vc[9]); - } - } - } - } - - } // Each voucher - - if ($vc != false) { - $this->dbh->exec("BEGIN;\n".$counterSQL."COMMIT;\n"); - } - - // Close PDF setup and send to user's browser - $this->glmpdfSendToBrowser( '', 'Star_Line_Ticket_Vouchers.pdf' ); - - if ($venueImageFile) { - unlink($venueImageFile); - } - if ($parkingImageFile) { - unlink($parkingImageFile); - } - if ($sectionImageFile) { - unlink($sectionImageFile); - } - if ($sectionImageFile) { - unlink($sectionImageFile); - } - - } - - private function displayCoupon($coupon, $xs, $ys) - { - - // Attempt to get the coupon image - $im = $this->getCouponImage( $this->is, $coupon['coupon_image']); - - // Check for stretch - $fit = 'auto'; - if ($coupon['stretch_to_fit']['value']) { - $fit = 'entire'; - } - - // Check for padding - enforce a minimum size - $pad = $coupon['padding']; - - $x = $xs - ($pad * 2); - if ($x < 10) { - $x == 10; - } - $y = $ys - ($pad * 2); - if ($y < 10) { - $y = 10; - } - - // If the image exists - if ($im) { - - // Place the image - $this->glmpdfPlaceImage($im, $pad, $pad, 1, $fit, 'center', $x, $y); - - - // If a border is requested display that - if ($coupon['show_border']['value']) { - $this->glmpdfPlaceBox( $this->borderWidth, 0, $ys, $xs, $ys, $this->borderColor ); - } - - } - - // SQL to Update Counters - $sql = "UPDATE eventmgt.voucher_coupons SET display_count = display_count + 1 WHERE id = ".$coupon['id'].";\n"; - - return $sql; - - } - - /* - * Function to load an image for use in Voucher Ads or Coupons - * - * This function maintains a static array of loaded images. It - * first checks to see if the image has already been loaded and - * returns the existing object if it is. Otherwise it will - * attempt to load the image, store the open image object in the - * static array for future use, and return it. - * - * @param $is object Image Server Object - * @param $imageName string Name of the image to load - * - * @return object Loaded and opened image object or false if not loaded - * - */ - private function getCouponImage( $is, $imageName ) - { - static $images = array(); - - // Check if image has already been loaded - if (isset($images[$imageName])) { - return $images[$imageName]; - } - - // Try to load the image - $imageFile = $is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$imageName); - if ($imageFile) { - - // Open the image and save it in case it's needeed again - $images[$imageName] = $this->glmpdfOpenImage($imageFile); - - return $images[$imageName]; - - } - - return false; - - } - - /* - * Function to add check character to end of voucher number - * - * Uses config->voucher_check_secret and voucher # to create MD5 string - * then takes last hex character off of that string and shifts it up to - * always be a character (adds 16 to numbers and 10 to the upper-case - * version of the character). - * i.e. 0 = A, 9 = J, A = K, F = - * - */ - public function addCheckCode($voucherNumb) - { - - // Create MD5 string using voucher number and secret - $md5 = md5($voucherNumb.$this->config->voucher_check_secret); - - // Get last character code of the last character in the MD5 - $cc = strtoupper(substr($md5, -2)); - $cc[0] = $this->shiftCheckCodeCharacter($cc[0]); - $cc[1] = $this->shiftCheckCodeCharacter($cc[1]); - - // Return voucher number with the new character on the end - $voucherNumb .= $cc; - return $voucherNumb; - - } - - private function shiftCheckCodeCharacter($c) { - - $x = ord($c); - - // If it's a digit, add 16 - if ($x < 65) { - $x += 17; - // otherwise, add 10 - } else { - $x += 10; - } - - // Also skip the letter O - if (x >= ord('O')) { - $x += 1; - } - - return chr($x); - } - -} // class - -// Absolutely nothing after next line -?> \ No newline at end of file diff --git a/legacy/models/vouchers/MackinacFerry/voucherMobile.php b/legacy/models/vouchers/MackinacFerry/voucherMobile.php deleted file mode 100644 index 02918ef..0000000 --- a/legacy/models/vouchers/MackinacFerry/voucherMobile.php +++ /dev/null @@ -1,711 +0,0 @@ - - * @license http://www.gaslightmedia.com Gaslightmedia - * @release SVN: $Id: printVoucher.inc,v 1.0 2011/01/25 19:31:47 cscott Exp $ - */ - -require_once PDF_ABSTRACT; -$Pdf = new GlmPdf(); - -/** - * PdfVoucher class - * - * @category PdfVoucher - * @package PDFLib - * @author Chuck Scott - * @license http://www.gaslightmedia.com Gaslightmedia - * @link <> -*/ -class PdfVoucher extends GlmPdf -{ - - public $borderWidth = 1; - public $borderColor = 'black'; - public $pdfCouponInterval = 5; - public $pdfMinCoupons = 3; - public $config; - private $is; - private $dbh; - - function __construct($order, $vouchers, $member, $dbh, $config, $couponTest = false) - { - - $this->dbh = $dbh; - $this->config = $config; - - // Load image server support - require_once IMAGE_SERVER_ABSTRACT; - $this->is = new ImageServerAbstract(); - - // if debug.glmpdf is set in the configs/common.ini file in the CommonApp directory, do grids on PDFs - define ('GLMPDF_DEBUG', $this->config->debug->glmpdf); - - // Start with cover page. - $this->glmpdfSetForms( - 1, - array( - 1 => array( 'x' => 0, 'y' => 0, 'xs' => 613, 'ys' => 792 ) - ), - 'US Letter' - ); - - // Set PDF options - In this case, we don't allow printing for mobile vouchers - $optlist = "masterpassword=GLMPdfPerm permissions=noprint"; - - // Start page - $this->glmpdfStart( $this->config->owner->name, "Gaslight Media", "Ticket System Receipt/Vouchers", $optlist ); - $this->glmpdfNextPage(); - - if( !$this->glmpdfAddFont( 'barcode', 'barcode/FREE3OF9.TTF' ) ) - { - echo 'ERROR: Unable to add barcode font.

    - Did you place the barcode font provided in docs/BarcodeFonts into - a system fonts directory ("/usr/share/fonts/truetype/Barcode")? - Also check the GLMPDF_PDF_FONT_DIR setting in GlmPdf.php.'; - exit; - } - - // Get images to tmp files - if (trim($member['image']) != '') { - $venueImageFile = $this->is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$member['image']); - if ($venueImageFile) { - $venueImage = $this->glmpdfOpenImage($venueImageFile); - - // If failure getting the image - if ($venueImage == false) { - $venueImageFile = false; - } - } - } else { - $venueImageFile = false; - } - - - // Load entrance class - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/entrances.php'; - $Entrances = new EventManagementAdminEntrances($dbh, $config); - - // Load performance class - require_once EVENT_MANAGEMENT_APP_BASE.'models/admin/classes/performances.php'; - $Performances = new EventManagementAdminPerformances($dbh, $config); - - // Load ticket packages data class - require_once EVENT_MANAGEMENT_APP_BASE.'classes/data/dataTicketPackages.php'; - $TicketPackages = new EventManagementDataTicketPackages($dbh, $config); - - // If no date has been supplied - make it today - if (isset($_REQUEST['date']) && $_REQUEST['date'] != '') { - $date = $_REQUEST['date']; - } else { - $date = date('m/d/Y', time()); - } - - $firstVoucherPageSet = false; - - // Process Vouchers - For each type of ticket purchased - $numb_tickets = 0; - $counterSQL = ''; - $packageVouchersPrintedSeparately = ''; - $allPackageVouchersSeparate = true; - $packageVoucher = false; - $packageTicketName = ''; - $doDashes = false; - $skipNextFormAdvance = false; - - /* Cover Page */ - - // Header - if ($venueImageFile) { - $coverImage = $this->glmpdfOpenImage($venueImageFile); - $this->glmpdfPlaceImage($coverImage, 30, 690, .5, false, 'center', 280, 140); - } - $this->glmpdfSetFont( "Helvetica-Bold", 18.0 ); // Header Text - $this->glmpdfPlaceText( $config->owner->name, 340, 750, "center", 'black', -400 ); - $this->glmpdfSetFont( "Helvetica", 14.0 ); - $this->glmpdfPlaceText( $config->owner->short_name." - ".$member['name'], 340, $this->glmpdfCurrentY-10, "center", 'black', -400 ); - $this->glmpdfPlaceText( $member['addr1'], 340, $this->glmpdfCurrentY, "center", 'black', -400 ); - $this->glmpdfPlaceText( $member['city'].", ".$member['state']['name']." ".$member['zip'], 340, $this->glmpdfCurrentY, "center", 'black', -400 ); - - // Sold To Information - $valCol = 60; - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( $this->config->term->order->cap." ID: ".trim($order['id']), $valCol, 650, "left", 'black' ); - $this->glmpdfPlaceText( trim($order['fname'].' '.$order['lname']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - $this->glmpdfPlaceText( trim($order['addr1']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - if( trim($order['addr2']) != '' ) - $this->glmpdfPlaceText( trim($order['addr2']), $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - $this->glmpdfPlaceText( trim($order['city']).', '.$order['state']['value'].' '.trim($order['zip']).' '.$order['country']['value'], $valCol, $this->glmpdfCurrentY-5, "left", 'black', -200 ); - - // Purchace/Charge information - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $promptCol = 330; - $valCol = 420; - $this->glmpdfPlaceText( "Date of Purchase:", $promptCol, 650, "left", 'black' ); - $this->glmpdfPlaceText( $order['purchase_date']['date'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Card Type:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['cctype'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Name on Card:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccname'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Card Number:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccnumber'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Confirmation:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['ccconf'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - $this->glmpdfPlaceText( "Total Charged:", $promptCol, $this->glmpdfCurrentY-5, "left", 'black' ); - $this->glmpdfPlaceText( $order['charge_total'], $valCol, $this->glmpdfLastY, "left", 'black', -160 ); - - // Purchase Summary - $ticNumbCol = 20; - $perfNameCol = 80; - $ticNameCol = 200; - $secNameCol = 370; - $dateCol = 440; - $this->glmpdfPlaceText( '', $ticNumbCol, 550, "center", 'black', 0, ''); - - $this->glmpdfSetFont( "Helvetica", 8.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap, $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - $this->glmpdfPlaceText( $this->config->term->performance->cap, $perfNameCol, $this->glmpdfLastY, "left", 'black', -110, ''); - $this->glmpdfPlaceText( $this->config->term->ticket->cap, $ticNameCol, $this->glmpdfLastY, "left", 'black', -160, ''); - $this->glmpdfPlaceText( $this->config->term->section->cap, $secNameCol, $this->glmpdfLastY, "left", 'black', -60, ''); - $this->glmpdfPlaceText( 'Date / Time', $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - - $this->glmpdfPlaceText( '', $ticNumbCol, $this->glmpdfCurrentY-3, "center", 'black', 0, ''); - - foreach( $vouchers as $t ) { - - $voucherCode = $this->addCheckCode($t['id']); - - $this->glmpdfSetFont( "Helvetica", 8.0 ); - if (!$t['ticket_package']) { - $this->glmpdfPlaceText( $voucherCode, $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - } else { - $this->glmpdfPlaceText( '', $ticNumbCol, $this->glmpdfCurrentY, "left", 'black', -52, ''); - } - $this->glmpdfPlaceText( html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8"), $perfNameCol, $this->glmpdfLastY, "left", 'black', -110, ''); - $this->glmpdfPlaceText( html_entity_decode($t['ticket_name'],ENT_QUOTES,"utf-8"), $ticNameCol, $this->glmpdfLastY, "left", 'black', -160, ''); - if (!$t['is_package']['value']) { - $this->glmpdfPlaceText( html_entity_decode($t['section_name'],ENT_QUOTES,"utf-8"), $secNameCol, $this->glmpdfLastY, "left", 'black', -60, ''); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, $dateCol, $this->glmpdfLastY, "left", 'black', -160, ''); - } - } - - // Check for Ticket add-ons - if (isset($t['addons_sold']) && count($t['addons_sold']) > 0) { - foreach($t['addons_sold'] as $a) { - - $addonText = $a['add_on_name']; - if (($a['add_on_type']['value']-0) == 2) { - $addonText = $addonText.', '.$a['quant'].' '.$a['unit_name']; - } - $this->glmpdfPlaceText( html_entity_decode($addonText,ENT_QUOTES,"utf-8"), $ticNameCol+10, $this->glmpdfCurrentY, "left", 'black', -240, ''); - } - } - - } - - // Special Needs - $this->glmpdfSetFont( "Helvetica", 9.0 ); - if (trim($order['special_needs']) != '') { - $this->glmpdfPlaceText( "Special Needs:", 20, $this->glmpdfCurrentY-30, "left", 'black' ); - $this->glmpdfPlaceTextBox( $order['special_needs'], 100, $this->glmpdfCurrentY+16, 450, 50, "left", 'black' ); - } - - // General Member Policies - if (trim($member['def_ticket_pol']) != '') { - $this->glmpdfPlaceText( "Policies:", 20, $this->glmpdfCurrentY-30, "left", 'black' ); - $this->glmpdfPlaceTextBox( $member['def_ticket_pol'], 100, $this->glmpdfCurrentY+16, 450, 50, "left", 'black' ); - } - - // General Member Policies - $noPrintNotice = - "NOTE: These MOBILE FRIENDLY vouchers are NOT FOR PRINTING, they are designed specifically for scanning directly from your mobile device. " - ."Scanners at the dock may not be able to read the barcode below from a printed page. " - ."If you need to print your vouchers, please select and print our standard PRINTABLE vouchers."; - $this->glmpdfPlaceTextBox( $noPrintNotice, 50, $this->glmpdfCurrentY-30, 500, 50, "left", 'black' ); - - - // Start with cover page. - $this->glmpdfSetForms( - 1, - array( - 1 => array( 'x' => 10, 'y' => 10, 'xs' => 593, 'ys' => 150), - ), - 612, - 170 - ); - - $this->glmpdfNextPage(); - - - - - $voucherCount = count($vouchers); - foreach( $vouchers as $t ) - { - - $voucherCount--; - - // Flag to determine if this voucher will be displayed (vouchers not displayed if it's a package ticket) - $displaying_this_voucher = false; - - if (!$couponTest) { - - // Check if the current voucher is a new package that has vouchers that print - if ($t['is_package']['value']) { - - $packageVoucher = true; - - // Check if any vouchers for this package print separately - $ticketPackage = $TicketPackages->getList('package = '.$t['ticket']); - if (is_array($ticketPackage) && count($ticketPackage) > 0) { - - // For each ticket in the package - foreach ($ticketPackage as $tp) { - - // Check if it requires a separate voucher - if ($tp['separate_voucher']['value']) { - - // Set this flag to the package sold ID (same for all vouchers for a package) so we can tell if we hit the end of the package - $packageVouchersPrintedSeparately = $t['package_sold_id']; - $packagePerformanceName = $t['performance_name']; - $packageTicketName = $t['ticket_name']; - } else { - $allPackageVouchersSeparate = false; - } - } - } - - // If we found one, then switch layouts. - if ($packageVouchersPrintedSeparately != '') { - $this->glmpdfSetForms( - $voucher3_coupon0['forms'], - $voucher3_coupon0['layout'], - 'US Letter' - ); - $voucherPageStarted = false; - $skipNextFormAdvance = false; - $doDashes = true; - if ($numb_tickets) { - $skipNextFormAdvance = true; - } - } - - // If we have a package with separate vouchers - } else { - $packageVoucher = false; - } - - if ($packageVouchersPrintedSeparately != '') { - - // Check if we're now past the package that had vouchers printed separately - if ($t['package_sold_id'] != $packageVouchersPrintedSeparately) { - - $this->glmpdfSetForms( - $voucher1_coupon8['forms'], - $voucher1_coupon8['layout'], - 'US Letter' - ); - $voucherPageStarted = false; - $packageVouchersPrintedSeparately = ''; - - } - - } - - // Check if this voucher is a print separate voucher for a package - $printVoucher = false; - if ($t['ticket_package']) { - - // Get ticket_package data - $ticketPackage = $TicketPackages->getList('package = '.$t['ticket_package'].' AND ticket = '.$t['ticket']); - - // If Separate Voucher, override and display voucher. - if ($ticketPackage[0]['separate_voucher']['value']) { - $printVoucher = true; - } - - } else { - $printVoucher = true; - } - - // Check if this is a package voucher and we are printing all package tickets separately - if ($packageVoucher && $allPackageVouchersSeparate) { - $printVoucher = false; - } - - // If this isn't a package ticket (we're not printing separate vouchers at this time) - $voucherPrinted = false; - if ($printVoucher) { - - if ($packageVouchersPrintedSeparately) { - - // If the first voucher page hasn't been set - if (!$voucherPageStarted) { -// $this->glmpdfNextPage(); - $voucherPageStarted = true; - } - - $displaying_this_voucher = true; - - if ($numb_tickets++ > 0) { - - if ($skipNextFormAdvance) { - $skipNextFormAdvance = false; - } else { -// $this->glmpdfNextForm(); - } - } - - - $this->glmpdfSetFont( "Helvetica-Bold", 10 ); -// $this->glmpdfPlaceText( $config->owner->name, 300, 140, "center", 'black', -350, ''); - - // If ticket has already been claimed, then mark ticket - if ($t['time_claimed']['date'] != '') { - $this->glmpdfSetFont( "Times-Bold", 48.0 ); - $this->glmpdfPlaceText( "CLAIMED", 110, 80, "left", 'orangered', 0, '' ); // last parameter can be things like "rotate=90" - } - - // If part of a package, print the package name it's part of. - $packageText = ''; - if ($packageTicketName && !$t['is_package']['value']) { - $packageText = $packageTicketName.' - '; - } - - // Display values - $this->glmpdfSetFont( "Helvetica", 11.0 ); - $this->glmpdfPlaceText( - html_entity_decode($packageText,ENT_QUOTES,"utf-8") - .html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8") - .' - '.html_entity_decode($t['ticket_name'], ENT_QUOTES,"utf-8"), - 300, 135, "center", 'black', -570, '' ); - - $this->glmpdfSetFont( "Helvetica", 8.5 ); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], 300, $this->glmpdfCurrentY, "center", 'black', -370, '' ); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, 300, $this->glmpdfCurrentY, "center", 'black', -370, '' ); - } - - // Display address and contact information - $this->glmpdfSetFont( "Helvetica", 8.5 ); - $contactInfo = $this->config->owner->name.' - ' - .$this->config->owner->address1.' - ' - .($this->config->owner->address2 != '' ? ', '.$this->config->owner->address2 : '') - .$this->config->owner->city.', ' - .$this->config->owner->state.' ' - .$this->config->owner->zip.' - ' - .$this->config->owner->phone - .($this->config->owner->toll_free != '' ? ' - '.$this->config->owner->toll_free : ''); - $this->glmpdfPlaceText( html_entity_decode($contactInfo,ENT_QUOTES,"utf-8"), 300, 2, "center", 'black', -380, ''); - - // Print barcode = {ticket_sold ID}-{person type}-{person_sequence} - $barcode = $this->addCheckCode($t['id']); - - // If we're supposed to print barcode and voucher number on ticket - switch ($t['ticket_voucher_type']) { - case 11: - $this->glmpdfSetFont( "Helvetica-Bold", 12.0 ); - $this->glmpdfPlaceText( "Pickup ".$this->config->term->voucher->norm." at ".$this->config->term->prop->norm, 300, 116, 'center', 'red', -224); - $this->glmpdfSetFont( "Helvetica", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 300, 116, 'center', 'black', -224); - break; - case 12; - $this->glmpdfSetFont( "Helvetica-Bold", 12.0 ); - $this->glmpdfPlaceText( "You will receive ".$this->config->term->voucher->cap." by mail", 510, 116, 'left', 'red', -224); - $this->glmpdfSetFont( "Helvetica", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 116, 'left', 'black', -224); - break; - case 1: - default: - $this->glmpdfSetFont( 'barcode', 110 ); - $this->glmpdfPlaceText( "*$barcode*", 300, 30, 'center', 'black', 0); - break; - } - - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( "Order #".$order['id'].' '.$this->config->term->voucher->cap.' '.$barcode, 300, 20, 'center', 'black', 0); - - $voucherPrinted = true; - - // Print a normal voucher - } else { - - // If the first voucher page hasn't been set - if (!$voucherPageStarted) { -// $this->glmpdfNextPage(); - $voucherPageStarted = true; - } - - $displaying_this_voucher = true; - - if ($numb_tickets++ > 0) { - - if ($skipNextFormAdvance) { - $skipNextFormAdvance = false; - } else { -// $this->glmpdfNextForm(); - } - } - - $this->glmpdfSetFont( "Helvetica-Bold", 10 ); - - // If ticket has already been claimed, then mark ticket - if ($t['time_claimed']['date'] != '') { - $this->glmpdfSetFont( "Times-Bold", 48.0 ); - $this->glmpdfPlaceText( "CLAIMED", 110, 80, "left", 'orangered', 0, '' ); // last parameter can be things like "rotate=90" - } - - // If part of a package, print the package name it's part of. - if ($packageTicketName && !$t['is_package']['value']) { - - $this->glmpdfSetFont( "Helvetica-Bold", 10.0 ); - $this->glmpdfPlaceText( 'Part of:', 7, 40, 'left', 'black', 0, 'position=center rotate=90'); - $this->glmpdfSetFont( "Helvetica-Bold", 16.0 ); - $this->glmpdfPlaceText( $packagePerformanceName, 30, 116, 'left', 'black', -224, 'position=center rotate=90'); - $this->glmpdfPlaceText( $packageTicketName, 60, 116, 'left', 'black', -224, 'position=center rotate=90'); - - } - - // Display values - $this->glmpdfSetFont( "Helvetica", 11.0 ); - $this->glmpdfPlaceText( html_entity_decode($t['performance_name'],ENT_QUOTES,"utf-8").' - '.html_entity_decode($t['ticket_name'],ENT_QUOTES,"utf-8"), - 300, 135, "center", 'black', -570, '' ); - - $this->glmpdfSetFont( "Helvetica", 8.5 ); - if ($t['date_specific']['value']) { - $this->glmpdfPlaceText( $t['ticket_date']['date'], 300, $this->glmpdfCurrentY, "center", 'black', -370, '' ); - } else { - $dateRange = 'Valid From '.$t['start_date']['date'].' through '.$t['end_date']['date']; - $this->glmpdfPlaceText( $dateRange, 300, $this->glmpdfCurrentY, "center", 'black', -370, '' ); - } - - // Display address and contact information - $this->glmpdfSetFont( "Helvetica", 8.5 ); - $contactInfo = $this->config->owner->name.' - ' - .$this->config->owner->address1.' - ' - .($this->config->owner->address2 != '' ? ', '.$this->config->owner->address2 : '') - .$this->config->owner->city.', ' - .$this->config->owner->state.' ' - .$this->config->owner->zip.' - ' - .$this->config->owner->phone - .($this->config->owner->toll_free != '' ? ' - '.$this->config->owner->toll_free : ''); - $this->glmpdfPlaceText( html_entity_decode($contactInfo,ENT_QUOTES,"utf-8"), 300, 2, "center", 'black', -380, ''); - - // Print barcode = {ticket_sold ID}-{person type}-{person_sequence} - $barcode = $this->addCheckCode($t['id']); - - // If we're supposed to print barcode and voucher number on ticket - switch ($t['ticket_voucher_type']) { - case 11: - $this->glmpdfSetFont( "Helvetica-Bold", 12.0 ); - $this->glmpdfPlaceText( "Pickup ".$this->config->term->voucher->norm." at ".$this->config->term->prop->norm, 300, 116, 'center', 'red', -224); - $this->glmpdfSetFont( "Helvetica", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 300, 116, 'center', 'black', -224); - break; - case 12; - $this->glmpdfSetFont( "Helvetica-Bold", 12.0 ); - $this->glmpdfPlaceText( "You will receive ".$this->config->term->voucher->cap." by mail", 510, 116, 'left', 'red', -224); - $this->glmpdfSetFont( "Helvetica", 12.0 ); - $this->glmpdfPlaceText( $this->config->term->voucher->cap." $barcode", 540, 116, 'left', 'black', -224); - break; - case 1: - default: - $this->glmpdfSetFont( 'barcode', 110 ); - $this->glmpdfPlaceText( "*$barcode*", 300, 30, 'center', 'black', 0); - break; - } - - $this->glmpdfSetFont( "Helvetica", 10.0 ); - $this->glmpdfPlaceText( "Order #".$order['id'].' '.$this->config->term->voucher->cap.' '.$barcode, 300, 20, 'center', 'black', 0); - - $voucherPrinted = true; - - - } // End of normal voucher - - if ($voucherPrinted && $voucherCount) { - $this->glmpdfNextForm(); - } - - } // Printing Voucher - - } -/* - if ($displaying_this_voucher) { - if (!$packageVouchersPrintedSeparately) { - } - } -*/ - } // Each voucher - - if ($vc != false) { - $this->dbh->exec("BEGIN;\n".$counterSQL."COMMIT;\n"); - } - - // Close PDF setup and send to user's browser - $this->glmpdfSendToBrowser( '', 'Star_Line_Ticket_Vouchers_Mobile.pdf' ); - - if ($venueImageFile) { - unlink($venueImageFile); - } - if ($parkingImageFile) { - unlink($parkingImageFile); - } - if ($sectionImageFile) { - unlink($sectionImageFile); - } - if ($sectionImageFile) { - unlink($sectionImageFile); - } - - } - - private function displayCoupon($coupon, $xs, $ys) - { - - // Attempt to get the coupon image - $im = $this->getCouponImage( $this->is, $coupon['coupon_image']); - - // Check for stretch - $fit = 'auto'; - if ($coupon['stretch_to_fit']['value']) { - $fit = 'entire'; - } - - // Check for padding - enforce a minimum size - $pad = $coupon['padding']; - - $x = $xs - ($pad * 2); - if ($x < 10) { - $x == 10; - } - $y = $ys - ($pad * 2); - if ($y < 10) { - $y = 10; - } - - // If the image exists - if ($im) { - - // Place the image - $this->glmpdfPlaceImage($im, $pad, $pad, 1, $fit, 'center', $x, $y); - - - // If a border is requested display that - if ($coupon['show_border']['value']) { - $this->glmpdfPlaceBox( $this->borderWidth, 0, $ys, $xs, $ys, $this->borderColor ); - } - - } - - // SQL to Update Counters - $sql = "UPDATE eventmgt.voucher_coupons SET display_count = display_count + 1 WHERE id = ".$coupon['id'].";\n"; - - return $sql; - - } - - /* - * Function to load an image for use in Voucher Ads or Coupons - * - * This function maintains a static array of loaded images. It - * first checks to see if the image has already been loaded and - * returns the existing object if it is. Otherwise it will - * attempt to load the image, store the open image object in the - * static array for future use, and return it. - * - * @param $is object Image Server Object - * @param $imageName string Name of the image to load - * - * @return object Loaded and opened image object or false if not loaded - * - */ - private function getCouponImage( $is, $imageName ) - { - static $images = array(); - - // Check if image has already been loaded - if (isset($images[$imageName])) { - return $images[$imageName]; - } - - // Try to load the image - $imageFile = $is->saveImageToTemp(IMAGE_SERVER_PREFIX.'original/'.$imageName); - if ($imageFile) { - - // Open the image and save it in case it's needeed again - $images[$imageName] = $this->glmpdfOpenImage($imageFile); - - return $images[$imageName]; - - } - - return false; - - } - - /* - * Function to add check character to end of voucher number - * - * Uses config->voucher_check_secret and voucher # to create MD5 string - * then takes last hex character off of that string and shifts it up to - * always be a character (adds 16 to numbers and 10 to the upper-case - * version of the character). - * i.e. 0 = A, 9 = J, A = K, F = - * - */ - public function addCheckCode($voucherNumb) - { - - // Create MD5 string using voucher number and secret - $md5 = md5($voucherNumb.$this->config->voucher_check_secret); - - // Get last character code of the last character in the MD5 - $cc = strtoupper(substr($md5, -2)); - $cc[0] = $this->shiftCheckCodeCharacter($cc[0]); - $cc[1] = $this->shiftCheckCodeCharacter($cc[1]); - - // Return voucher number with the new character on the end - $voucherNumb .= $cc; - return $voucherNumb; - - } - - private function shiftCheckCodeCharacter($c) { - - $x = ord($c); - - // If it's a digit, add 16 - if ($x < 65) { - $x += 17; - // otherwise, add 10 - } else { - $x += 10; - } - - // Also skip the letter O - if (x >= ord('O')) { - $x += 1; - } - - return chr($x); - } - -} // class - -// Absolutely nothing after next line -?> \ No newline at end of file diff --git a/legacy/views/NOTE.txt b/legacy/views/NOTE.txt deleted file mode 100755 index 0862734..0000000 --- a/legacy/views/NOTE.txt +++ /dev/null @@ -1,2 +0,0 @@ -NOTE: When adding a new interface (set of view), add both here and in the web/front directory. -Also add the new interface to the EventManagement configs/common.ini file. \ No newline at end of file diff --git a/legacy/views/admin/tickets/Accommodation/list.html b/legacy/views/admin/tickets/Accommodation/list.html deleted file mode 100755 index e17688e..0000000 --- a/legacy/views/admin/tickets/Accommodation/list.html +++ /dev/null @@ -1,28 +0,0 @@ -

    - -
    -{if:accomsList} - - - {foreach:accomsList,a} - - - - - - - - - {end:} -
     PropertyNameTitleCateogoryQuantity
    {a.property}{a.name}{a.title}{a.category.name}{a.quant}
    -{else:} - (No accommodations listed for selected {term.event.norm} or no {term.event.norm} selected.) -{end:} - - -{startScript:h} - $(document).ready(function(){ - $('#accomsSelectAll').html('All (' + {accomsStats.all} + ')'); - $('#accomsSelectMember').html('Selected Property (' + {accomsStats.member} + ')'); - }); - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Addon/delete.html b/legacy/views/admin/tickets/Addon/delete.html deleted file mode 100755 index 11351b9..0000000 --- a/legacy/views/admin/tickets/Addon/delete.html +++ /dev/null @@ -1,63 +0,0 @@ -
    - -
    Delete this {term.ticket.cap} Add-On
    - -
    {AddonDetail.name}
    - -
    - - -
    - - {if:addonDetail} -
    - - - - - - - - - - - - - - - - -
    Delete {term.ticket.cap} Add-On: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.ticket.norm} add-on.

    -
    {term.addon.cap} Add-On Name:{addonDetail.name}ID: {addonDetail.id}
    Description:{addonDetail.descr:h}
    Type: - {addonDetail.add_on_type.name:h} -
    Maximum Quantity: {addonDetail.max_quant} -
    Unit Name:{addonDetail.unit_name}
    Unit Cost:{addonDetail.unit_cost}
    - {else:} -

    No {term.ticket.plur} add-ons found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#AddonDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Addon/detail.html b/legacy/views/admin/tickets/Addon/detail.html deleted file mode 100755 index c92ae61..0000000 --- a/legacy/views/admin/tickets/Addon/detail.html +++ /dev/null @@ -1,74 +0,0 @@ -
    - - - -
    - - -
    - - {if:addonDetail} -
    - - - - {if:addonDetail.delete} - - - - - {end:} - - - - - - - - - -
    Delete {term.ticket.cap} Add-On: - {if:addonDetail.deleteConfirmed} - {if:addonDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {addonDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.ticket.norm} add-on.

    - {end:} -
    {term.ticket.cap} Add-On Name:{addonDetail.name}ID: {addonDetail.id}
    Description:{addonDetail.descr:h}
    Type: - {addonDetail.add_on_type.name:h} -
    Maximum Quantity: {addonDetail.max_quant} -
    Unit Name:{addonDetail.unit_name}
    Unit Cost:{addonDetail.unit_cost}
    - {else:} -

    No {term.ticket.norm} add-ons found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#AddonDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Addon/edit.html b/legacy/views/admin/tickets/Addon/edit.html deleted file mode 100755 index 59c4c37..0000000 --- a/legacy/views/admin/tickets/Addon/edit.html +++ /dev/null @@ -1,200 +0,0 @@ -
    - -
    - {if:addingNewAddon}Adding New {term.ticket.cap} Add-On{end:} - {if:editingAddon}Editing {term.ticket.cap} Add-On{end:} -
    - -
    -{if:addingNewAddon} - -{else:} - -{end:} -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:addonDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewAddon} - - {else:} - - {end:} - - - - - - - -
    - - - - - {if:fieldRequired.name} - {if:fieldFail.name} - - - {if:fieldRequired.descr} - {if:fieldFail.descr} - - - {if:fieldRequired.add_on_type} - {if:fieldFail.add_on_type} - - - {if:fieldRequired.unit_name} - {if:fieldFail.unit_name} - - - {if:fieldRequired.unit_cost_numb} - {if:fieldFail.unit_cost_numb} - - -
    {else:}{end:}{term.ticket.cap} Add-On Name:{else:}{end:} -
    - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    {else:}{end:}Description:{else:}{end:} - - {if:fieldFail.descr}
    {fieldFail.descr}{end:} -
    {else:}{end:}{term.ticket.cap} Add-On Type:{else:}{end:} - - {if:fieldFail.add_on_type}
    {fieldFail.add_on_type}{end:} -
    - - {if:fieldFail.max_quant}{else:}{end:} - - - -
    Maximum quantity a user may select: - -
    This is the maximum number of these {term.ticket.norm} add-ons that a user may select. -
    -
    -
    {else:}{end:}{term.ticket.cap} Add-On Unit Name:{else:}{end:} -
    - {if:fieldFail.unit_name}
    {fieldFail.unit_name}{end:} -
    {else:}{end:}Price Per Unit:{else:}{end:} - - {if:fieldFail.unit_cost_numb}
    {fieldFail.unit_cost_numb}{end:} -
    -
    - -
    - {if:addingNewAddon} - - {end:} - {if:editingAddon} - - {end:} -
    - -
    - - {else:} -

    No {term.ticket.norm} add-on has been selected yet.

    -

    To edit a {term.ticket.norm} add-on, first select it from the list of available {term.ticket.plur} add-ons. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.addonEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#addonForm').ajaxForm({ - success: function(data) { - {if:addingNewAddon} - var container = $('#Addon_detail_container'); - f_replaceContents(data, container); - {end:} - {if:editingAddon} - var container = $('#Addon_detail_container'); - f_replaceContents(data, container); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#addonFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#descr")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - f_restartOnTabSelect(); - - function addonTypeCheck(e) { - typeval = $('#addonType').val(); - - // If this is a quantity selection - if (typeval == 2) { - $('#max_quant').show(); - } else { - $('#max_quant').hide(); - } - } - - $('#addonType').change( function() { - addonTypeCheck(); - }); - addonTypeCheck(); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Addon/list.html b/legacy/views/admin/tickets/Addon/list.html deleted file mode 100644 index 6627904..0000000 --- a/legacy/views/admin/tickets/Addon/list.html +++ /dev/null @@ -1,124 +0,0 @@ - -
    - -
    -
    -{if:checkPermission(#10#)} - -{end:} - -
    - Search {term.ticket.cap} Add-Ons: (start typing any information in list) - - {if:addons} - -
    - - - - - - {foreach:addons,c} - - - - - - {end:} - -
    Add-On NameTypePrice
    {c.unit_cost} / {c.unit_name}
    -
    - - {else:} -

    No {term.ticket.norm} add-ons listed.

    - {end:} - -
    -
    - -
    - -
    -{startScript:h} - - // Addons Search - var addonsSearchData = [ - {foreach:addons,c} - {label:'{c.name:h}, {c.ticket_name:h}, {c.add_on_type.name}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var AddonListTable = $('#AddonListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - }); - - $(window).resize(function(){ - AddonListTable.fnDraw(); - }); - - // Toggle length of table - var AddonListTableSmall = true; - var AddonListTableHeight = $('#AddonListTable_wrapper div.dataTables_scrollBody').height(); - $('#addonListSizeChange').click(function() { - if (AddonListTableSmall) { - $('#AddonListTable_wrapper div.dataTables_scrollBody').height('auto'); - AddonListTableSmall = false; - $(this).html('Smaller Table'); - AddonListTable.fnSettings().oScroll.sY = '100%'; - AddonListTable.fnDraw(); - } else { - $('#AddonListTable_wrapper div.dataTables_scrollBody').height(AddonListTableHeight); - AddonListTableSmall = true; - $(this).html('Larger Table'); - AddonListTable.fnSettings().oScroll.sY = '100px'; - AddonListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Addon_detail').hide(duration); - - $('.addonListSelect').click(function(){ - $('#AddonListTable_wrapper div.dataTables_scrollBody').height(AddonListTableHeight); - AddonListTableSmall = true; - $('#addonListSizeChange').html('Larger Table'); - AddonListTable.fnSettings().oScroll.sY = '100px'; - AddonListTable.fnDraw(); - f_loadAction('Addon_selected', 'Addon_detail_container', 'AddonID=' + $(this).attr('emAddonId') + '&tabList={tabList}'); - }); - - // Search Addons - $("#addonsSearch").autocomplete({ - source: addonsSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#addonsSearch").attr({value: ui.item.label}); - f_loadAction('Addon_selected', 'Addon_detail_container', 'AddonID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Addon/selected.html b/legacy/views/admin/tickets/Addon/selected.html deleted file mode 100755 index 9dd8aef..0000000 --- a/legacy/views/admin/tickets/Addon/selected.html +++ /dev/null @@ -1,32 +0,0 @@ -
    - -
    -
    {term.ticket.cap} Add-On: {addonDetail.name}
    -
    - -
    - - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with ticket detail loaded - f_loadAction('Addon_detail', 'Addon_detail_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Attendance/added.html b/legacy/views/admin/tickets/Attendance/added.html deleted file mode 100755 index df53b1b..0000000 --- a/legacy/views/admin/tickets/Attendance/added.html +++ /dev/null @@ -1,16 +0,0 @@ -
    - -
    New {term.attendance_log.cap} Added
    - -
    - -{startScript:h} - - $(function() { - - f_loadAction('Attendance_selected', 'Attendance_selected', 'member_id={attendanceDetail.id}&tabList={tabList}'); - - }); - - - diff --git a/legacy/views/admin/tickets/Attendance/delete.html b/legacy/views/admin/tickets/Attendance/delete.html deleted file mode 100755 index d59183b..0000000 --- a/legacy/views/admin/tickets/Attendance/delete.html +++ /dev/null @@ -1,90 +0,0 @@ -
    - -
    Delete this {term.attendance_log.cap}
    - -
    {attendanceDetail.lname}, {attendanceDetail.fname}
    - -{if:checkPermission(#10#)} -
    - - -
    -{end:} - - {if:attendanceDetail} -
    - - - - - - - - - - - - - - - {if:attendanceDetail.org_url} - - {end:} - {if:attendanceDetail.office_phone} - - {end:} - {if:attendanceDetail.mobile_phone} - - {end:} - {if:attendanceDetail.fax} - - {end:} - {if:attendanceDetail.email} - - {end:} - {if:attendanceDetail.login_id} - - {end:} - {if:attendanceDetail.alt_email} - - {end:} - {if:attendanceDetail.notes} - - {end:} - -
    Delete {term.attendance_log.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.attendance_log.norm}.

    -
    Name:{attendanceDetail.lname}, {attendanceDetail.fname}
    Organization:{attendanceDetail.org}
    Address: - {attendanceDetail.addr1}
    - {if:addr2}{attendanceDetail.addr2}
    {end:} - {attendanceDetail.city}, {attendanceDetail.state.name} {attendanceDetail.zip}
    - {attendanceDetail.country.name} -
    Active:{attendanceDetail.active.name}
    Web Address:{attendanceDetail.org_url}
    Office Phone:{attendanceDetail.office_phone}
    Mobile (cell) Phone:{attendanceDetail.mobile_phone}
    FAX:{attendanceDetail.fax}
    E-Mail Address:{attendanceDetail.email}
    Log in ID:{attendanceDetail.login_id}
    Alternate E-Mail Address:{attendanceDetail.alt_email}
    Notes:{attendanceDetail.notes}
    - {else:} -

    No {term.attendace_log.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#AttendanceDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Attendance/detail.html b/legacy/views/admin/tickets/Attendance/detail.html deleted file mode 100644 index 0e464f5..0000000 --- a/legacy/views/admin/tickets/Attendance/detail.html +++ /dev/null @@ -1,115 +0,0 @@ -
    - -
    - {if:addingNewAttendance}Adding New {term.attendace_log.cap}{end:} - {if:editingAttendance}Editing {term.attendance_log.cap}{end:} -
    - -
    {term.attendace_log.cap}: {attendanceDetail.lname}, {attendanceDetail.fname}
    - - {if:checkPermission(#10#)} -
    - - -
    - {end:} - - {if:attendanceDetail} -
    - - - - {if:attendanceDetail.delete} - - - - - {end:} - - - - - - - - {if:attendanceDetail.org_url} - - {end:} - {if:attendanceDetail.office_phone} - - {end:} - {if:attendanceDetail.mobile_phone} - - {end:} - {if:attendanceDetail.fax} - - {end:} - {if:attendanceDetail.email} - - {end:} - {if:attendanceDetail.login_id} - - {end:} - {if:attendanceDetail.alt_email} - - {end:} - {if:attendanceDetail.image} - - - - - {end:} - - {if:attendanceDetail.notes} - - {end:} - -
    Delete {term.attendance.cap}: - {if:attendanceDetail.deleteConfirmed} - {if:attendanceDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {attendanceDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.attendance_log.norm}.

    - {end:} -
    Name:{attendanceDetail.lname}, {attendanceDetail.fname}ID: {attendanceDetail.id}
    Organization:{attendanceDetail.org}
    Address: - {attendanceDetail.addr1}
    - {if:addr2}{attendanceDetail.addr2}
    {end:} - {attendanceDetail.city}, {attendanceDetail.state.name} {attendanceDetail.zip}
    - {attendanceDetail.country.name} -
    Active:{attendanceDetail.active.name}
    Web Address:{attendanceDetail.org_url}
    Office Phone:{attendanceDetail.office_phone}
    Mobile (cell) Phone:{attendanceDetail.mobile_phone}
    FAX:{attendanceDetail.fax}
    E-Mail Address:{attendanceDetail.email}
    Log in ID:{attendanceDetail.login_id}
    Alternate E-Mail Address:{attendanceDetail.alt_email}
    Image: - -
    User Permissions:{attendanceDetail.user_rights.name}
    Notes:{attendanceDetail.notes:h}
    - {else:} -

    No {term.attendance_log.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#AttendanceDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Attendance/edit.html b/legacy/views/admin/tickets/Attendance/edit.html deleted file mode 100755 index ed6072c..0000000 --- a/legacy/views/admin/tickets/Attendance/edit.html +++ /dev/null @@ -1,185 +0,0 @@ -
    - -
    - {if:addingNewAttendance}Adding New {term.attendance_log.cap}{end:} - {if:editingAttendance}Editing {term.attendance_log.cap}{end:} -
    - -
    -{if:addingNewAttendance} - -{else:} - -{end:} -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:attendanceDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewAttendance} - - {else:} - - {end:} - - - - {if:attendanceDetail.attendance_type.value} - - {else:} - - {end:} - - - - - - -
    - - - - - - - - - {if:fieldRequired.name} - {if:fieldFail.name} - - - {if:fieldRequired.notes} - {if:fieldFail.notes} - - - {if:fieldRequired.attendance_date} - {if:fieldFail.attendanceDate} - - -
    {term.prop.cap}: - {if:addingNewAttendance} - - {if:fieldFail.performance}
    {fieldFail.performance}{end:} - {else:} - {attendanceDetail.member_name} - {end:} -
    {else:}{end:}Name of this {term.attendance_log.cap}:{else:}{end:} - - {if:fieldFail.attendance}
    {fieldFail.attendance}{end:} -
    {else:}{end:}Notes:{else:}{end:} - - {if:fieldFail.notes}
    {fieldFail.notes}{end:} -
    {else:}{end:}Date:{else:}{end:} - {if:addingNewAttendance} - - {else:} -
    - {end:} -
    -
    - -
    - {if:addingNewAttendance} - - {end:} - {if:editingAttendance} - - {end:} -
    - -
    - - {else:} -

    No {term.attendance_log.norm} has been selected yet.

    -

    To edit a {term.attendance_log.norm}, first select it from the list of available {term.attendance_log.plur}. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.attendanceEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#AttendanceForm').ajaxForm({ - success: function(data) { - {if:addingNewAttendance} - f_replaceContents(data, $('#Attendance_detail_container')); - {end:} - {if:editingAttendance} - f_replaceContents(data, $('#Attendance_detail_container')); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#attendanceFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields -// f_buildCkeditor($("#notes")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#notes")); - }); - - f_restartOnTabSelect(); - - // Code to start datepicker for each date input - $("#attendanceDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{attendanceDetail.attendance_date.date_list.min}', - maxDate: '{attendanceDetail.attendance_date.date_list.max}' - }); - - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Attendance/list.html b/legacy/views/admin/tickets/Attendance/list.html deleted file mode 100644 index 0c746ac..0000000 --- a/legacy/views/admin/tickets/Attendance/list.html +++ /dev/null @@ -1,125 +0,0 @@ - -
    - -
    -{if:checkPermission(#10#)} - -{end:} - -
    - - Search {term.attendance_log.plur_cap}: (type any portion of a {term.attendance_log.norm} name) - - {if:AttendanceList.Attendance_list} - -
    - - - - - - {foreach:AttendanceList.Attendance_list,c} - - - - - - - - {end:} - -
    Last NameFirst NameOrganizationPhoneE-Mail
    {c.org}{c.office_phone}{c.email}
    -
    - - {else:} -

    No {term.attendance_log.plur} are currently listed.

    -

    You should have at least one {term.attendance_log.norm} listed for each {term.prop.norm}.

    - {end:} - -
    -
    - - -
    -{startScript:h} - - // Attendances Search - var AttendancesSearchData = [ - {foreach:AttendanceList.Attendance_list,c} - {label:'{c.lname:h}, {c.fname:h}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var AttendanceListTable = $('#AttendanceListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - $(window).resize(function(){ - AttendanceListTable.fnDraw(); - }); - - // Toggle length of table - var AttendanceListTableSmall = true; - var AttendanceListTableHeight = $('#AttendanceListTable_wrapper div.dataTables_scrollBody').height(); - $('#AttendanceListSizeChange').click(function() { - if (AttendanceListTableSmall) { - $('#AttendanceListTable_wrapper div.dataTables_scrollBody').height('auto'); - AttendanceListTableSmall = false; - $(this).html('Smaller Table'); - AttendanceListTable.fnSettings().oScroll.sY = '100%'; - AttendanceListTable.fnDraw(); - } else { - $('#AttendanceListTable_wrapper div.dataTables_scrollBody').height(AttendanceListTableHeight); - AttendanceListTableSmall = true; - $(this).html('Larger Table'); - AttendanceListTable.fnSettings().oScroll.sY = '100px'; - AttendanceListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Attendance_detail').hide(duration); - - $('.AttendanceListSelect').click(function(){ - $('#AttendanceListTable_wrapper div.dataTables_scrollBody').height(AttendanceListTableHeight); - AttendanceListTableSmall = true; - $('#AttendanceListSizeChange').html('Larger Table'); - AttendanceListTable.fnSettings().oScroll.sY = '100px'; - AttendanceListTable.fnDraw(); - f_loadAction('Attendance_detail', 'Attendance_detail_container', 'AttendanceID=' + $(this).attr('emAttendanceId') + '&tabList={tabList}'); - }); - - // Search Attendances - $("#AttendancesSearch").autocomplete({ - source: AttendancesSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#AttendancesSearch").attr({value: ui.item.label}); - f_loadAction('Attendance_detail', 'Attendance_detail_container', 'AttendanceID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Contact/added.html b/legacy/views/admin/tickets/Contact/added.html deleted file mode 100755 index a851c80..0000000 --- a/legacy/views/admin/tickets/Contact/added.html +++ /dev/null @@ -1,16 +0,0 @@ -
    - -
    New Contact Added
    - -
    - -{startScript:h} - - $(function() { - - f_loadAction('Contact_selected', 'Contact_selected', 'member_id={contactDetail.id}&tabList={tabList}'); - - }); - - - diff --git a/legacy/views/admin/tickets/Contact/delete.html b/legacy/views/admin/tickets/Contact/delete.html deleted file mode 100755 index 3de1e46..0000000 --- a/legacy/views/admin/tickets/Contact/delete.html +++ /dev/null @@ -1,90 +0,0 @@ -
    - -
    Delete this {term.contact.cap}
    - -
    {contactDetail.lname}, {contactDetail.fname}
    - -{if:checkPermission(#10#)} -
    - - -
    -{end:} - - {if:contactDetail} -
    - - - - - - - - - - - - - - - {if:contactDetail.org_url} - - {end:} - {if:contactDetail.office_phone} - - {end:} - {if:contactDetail.mobile_phone} - - {end:} - {if:contactDetail.fax} - - {end:} - {if:contactDetail.email} - - {end:} - {if:contactDetail.login_id} - - {end:} - {if:contactDetail.alt_email} - - {end:} - {if:contactDetail.notes} - - {end:} - -
    Delete {term.contact.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.contact.norm}.

    -
    Name:{contactDetail.lname}, {contactDetail.fname}
    Organization:{contactDetail.org}
    Address: - {contactDetail.addr1}
    - {if:addr2}{contactDetail.addr2}
    {end:} - {contactDetail.city}, {contactDetail.state.name} {contactDetail.zip}
    - {contactDetail.country.name} -
    Active:{contactDetail.active.name}
    Web Address:{contactDetail.org_url}
    Office Phone:{contactDetail.office_phone}
    Mobile (cell) Phone:{contactDetail.mobile_phone}
    FAX:{contactDetail.fax}
    E-Mail Address:{contactDetail.email}
    Log in ID:{contactDetail.login_id}
    Alternate E-Mail Address:{contactDetail.alt_email}
    Notes:{contactDetail.notes}
    - {else:} -

    No {term.contact.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#ContactDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Contact/detail.html b/legacy/views/admin/tickets/Contact/detail.html deleted file mode 100644 index 9e8b97e..0000000 --- a/legacy/views/admin/tickets/Contact/detail.html +++ /dev/null @@ -1,115 +0,0 @@ -
    - -
    - {if:addingNewContact}Adding New {term.contact.cap}{end:} - {if:editingContact}Editing {term.contact.cap}{end:} -
    - -
    Contact: {contactDetail.lname}, {contactDetail.fname}
    - - {if:checkPermission(#10#)} -
    - - -
    - {end:} - - {if:contactDetail} -
    - - - - {if:contactDetail.delete} - - - - - {end:} - - - - - - - - {if:contactDetail.org_url} - - {end:} - {if:contactDetail.office_phone} - - {end:} - {if:contactDetail.mobile_phone} - - {end:} - {if:contactDetail.fax} - - {end:} - {if:contactDetail.email} - - {end:} - {if:contactDetail.login_id} - - {end:} - {if:contactDetail.alt_email} - - {end:} - {if:contactDetail.image} - - - - - {end:} - - {if:contactDetail.notes} - - {end:} - -
    Delete {term.contact.cap}: - {if:contactDetail.deleteConfirmed} - {if:contactDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {contactDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.contact.norm}.

    - {end:} -
    Name:{contactDetail.lname}, {contactDetail.fname}ID: {contactDetail.id}
    Organization:{contactDetail.org}
    Address: - {contactDetail.addr1}
    - {if:addr2}{contactDetail.addr2}
    {end:} - {contactDetail.city}, {contactDetail.state.name} {contactDetail.zip}
    - {contactDetail.country.name} -
    Active:{contactDetail.active.name}
    Web Address:{contactDetail.org_url}
    Office Phone:{contactDetail.office_phone}
    Mobile (cell) Phone:{contactDetail.mobile_phone}
    FAX:{contactDetail.fax}
    E-Mail Address:{contactDetail.email}
    Log in ID:{contactDetail.login_id}
    Alternate E-Mail Address:{contactDetail.alt_email}
    Image: - -
    User Permissions:{contactDetail.user_rights.name}
    Notes:{contactDetail.notes:h}
    - {else:} -

    No {term.contact.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#ContactDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Contact/edit.html b/legacy/views/admin/tickets/Contact/edit.html deleted file mode 100755 index 7bd32f7..0000000 --- a/legacy/views/admin/tickets/Contact/edit.html +++ /dev/null @@ -1,341 +0,0 @@ -
    - -
    - {if:addingNewContact}Adding New {term.contact.cap}{end:} - {if:editingContact}Editing {term.contact.cap}{end:} -
    - -
    -{if:addingNewContact} - -{else:} - -{end:} -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:contactDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewContact} - - {else:} - - {end:} - - - - {if:contactDetail.contact_type.value} - - {else:} - - {end:} - - - - - - -
    - - - - - - - - -
    - - - - - - - {if:fieldRequired.fname} - {if:fieldFail.fname} - - - {if:fieldRequired.lname} - {if:fieldFail.lname} - - - {if:fieldRequired.org} - {if:fieldFail.org} - - - {if:fieldRequired.addr1} - {if:fieldFail.addr1} - - - {if:fieldRequired.addr2} - {if:fieldFail.addr2} - - - {if:fieldRequired.city} - {if:fieldFail.city} - - - {if:fieldRequired.state} - {if:fieldFail.state} - - - {if:fieldRequired.zip} - {if:fieldFail.zip} - - - {if:fieldRequired.country} - {if:fieldFail.country} - - - - - - - {if:fieldRequired.image} - {if:fieldFail.image} - - -
    {term.contact.cap} Type:{contactDetail.contact_type_name}
    Affiliation:{contactDetail.affiliation_name}
    {else:}{end:}First Name:{else:}{end:} - - {if:fieldFail.fname}
    {fieldFail.fname}{end:} -
    {else:}{end:}Last Name:{else:}{end:} - - {if:fieldFail.lname}
    {fieldFail.lname}{end:} -
    {else:}{end:}Organization Name:{else:}{end:} - - {if:fieldFail.org}
    {fieldFail.org}{end:} -
    {else:}{end:}Address:{else:}{end:} - - {if:fieldFail.addr1}
    {fieldFail.addr1}{end:} -
    {else:}{end:} {else:}{end:} - - {if:fieldFail.addr2}
    {fieldFail.addr2}{end:} -
    {else:}{end:}City:{else:}{end:} - - {if:fieldFail.city}
    {fieldFail.city}{end:} -
    {else:}{end:}State:{else:}{end:} - - {if:fieldFail.state}
    {fieldFail.state}{end:} -
    {else:}{end:}ZIP/Postal Code:{else:}{end:} - - {if:fieldFail.zip}
    {fieldFail.zip}{end:} -
    {else:}{end:}Country:{else:}{end:} - - {if:fieldFail.country}
    {fieldFail.country}{end:} -
    Active: - {if:contactDetail.active.value} - - {else:} - - {end:} -
    {else:}{end:}Image:{else:}{end:} - {if:contactDetail.image} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.image}
    {fieldFail.image}{end:} -
    -
    - - - - - {if:fieldRequired.office_phone} - {if:fieldFail.office_phone} - - - {if:fieldRequired.mobile_phone} - {if:fieldFail.mobile_phone} - - - {if:fieldRequired.alt_phone} - {if:fieldFail.alt_phone} - - - {if:fieldRequired.fax} - {if:fieldFail.fax} - - - {if:fieldRequired.email} - {if:fieldFail.email} - - - {if:fieldRequired.login_id} - {if:fieldFail.login_id} - - - {if:fieldRequired.password} - {if:fieldFail.password} - - - {if:fieldRequired.alt_email} - {if:fieldFail.alt_email} - - - {if:fieldRequired.user_rights} - {if:fieldFail.user_rights} - - - {if:fieldRequired.notes} - {if:fieldFail.notes} - - -
    {else:}{end:}Office phone:{else:}{end:} - - {if:fieldFail.office_phone}
    {fieldFail.office_phone}{end:} -
    {else:}{end:}Mobile phone:{else:}{end:} - - {if:fieldFail.mobile_phone}
    {fieldFail.mobile_phone}{end:} -
    {else:}{end:}Alternate phone:{else:}{end:} - - {if:fieldFail.alt_phone}
    {fieldFail.alt_phone}{end:} -
    {else:}{end:}FAX number:{else:}{end:} - - {if:fieldFail.fax}
    {fieldFail.fax}{end:} -
    {else:}{end:}E-Mail address:{else:}{end:} - - {if:fieldFail.email}
    {fieldFail.email}{end:} -
    {else:}{end:}Optional Log in ID:{else:}{end:} - -

    This field is optional. If a Log in ID is supplied, the user may log in either with their - E-Mail address or this Log in ID. This may be helpful for users with longer E-Mail addresses. - The password below will still be required to log in. Log in IDs are unique, so only one - contact may have a particular ID.

    - {if:fieldFail.login_id}
    {fieldFail.login_id}{end:} -
    {else:}{end:}Password:{else:}{end:} - - {if:fieldFail.password}
    {fieldFail.password:h}{end:} -
    - Passwords require at least 8 characters including at least one number, one letter, and one of the following characters.
    -    # . - _ , $ % & ! -
    {else:}{end:}Alternate E-Mail address:{else:}{end:} - - {if:fieldFail.alt_email}
    {fieldFail.alt_email}{end:} -
    {else:}{end:}User Permissions:{else:}{end:} - - {if:fieldFail.user_rights}
    {fieldFail.user_rights}{end:} -
    {else:}{end:}Notes:{else:}{end:} - - {if:fieldFail.notes}
    {fieldFail.notes}{end:} -
    -
    -
    - -
    - {if:addingNewContact} - - {end:} - {if:editingContact} - - {end:} -
    - -
    - - {else:} -

    No contact has been selected yet.

    -

    To edit a contact, first select it from the list of available contacts. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.contactEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#ContactForm').ajaxForm({ - success: function(data) { - {if:addingNewContact} - f_replaceContents(data, $('#Contact_detail_container')); - {end:} - {if:editingContact} - f_replaceContents(data, $('#Contact_detail_container')); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#contactFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields -// f_buildCkeditor($("#notes")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#notes")); - }); - - f_restartOnTabSelect(); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Contact/list.html b/legacy/views/admin/tickets/Contact/list.html deleted file mode 100644 index 2e9c1bc..0000000 --- a/legacy/views/admin/tickets/Contact/list.html +++ /dev/null @@ -1,125 +0,0 @@ - -
    - -
    -{if:checkPermission(#10#)} - -{end:} - -
    - - Search Contacts: (type any portion of a contact name) - - {if:contactList.contact_list} - -
    - - - - - - {foreach:contactList.contact_list,c} - - - - - - - - {end:} - -
    Last NameFirst NameOrganizationPhoneE-Mail
    {c.org}{c.office_phone}{c.email}
    -
    - - {else:} -

    No contacts are currently listed.

    -

    You should have at least one contact listed for each {term.prop.norm}.

    - {end:} - -
    -
    - - -
    -{startScript:h} - - // Contacts Search - var contactsSearchData = [ - {foreach:contactList.contact_list,c} - {label:'{c.lname:h}, {c.fname:h}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var ContactListTable = $('#ContactListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - $(window).resize(function(){ - ContactListTable.fnDraw(); - }); - - // Toggle length of table - var ContactListTableSmall = true; - var ContactListTableHeight = $('#ContactListTable_wrapper div.dataTables_scrollBody').height(); - $('#contactListSizeChange').click(function() { - if (ContactListTableSmall) { - $('#ContactListTable_wrapper div.dataTables_scrollBody').height('auto'); - ContactListTableSmall = false; - $(this).html('Smaller Table'); - ContactListTable.fnSettings().oScroll.sY = '100%'; - ContactListTable.fnDraw(); - } else { - $('#ContactListTable_wrapper div.dataTables_scrollBody').height(ContactListTableHeight); - ContactListTableSmall = true; - $(this).html('Larger Table'); - ContactListTable.fnSettings().oScroll.sY = '100px'; - ContactListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Contact_detail').hide(duration); - - $('.contactListSelect').click(function(){ - $('#ContactListTable_wrapper div.dataTables_scrollBody').height(ContactListTableHeight); - ContactListTableSmall = true; - $('#contactListSizeChange').html('Larger Table'); - ContactListTable.fnSettings().oScroll.sY = '100px'; - ContactListTable.fnDraw(); - f_loadAction('Contact_detail', 'Contact_detail_container', 'ContactID=' + $(this).attr('emContactId') + '&tabList={tabList}'); - }); - - // Search Contacts - $("#contactsSearch").autocomplete({ - source: contactsSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#contactsSearch").attr({value: ui.item.label}); - f_loadAction('Contact_detail', 'Contact_detail_container', 'ContactID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Debug/index.html b/legacy/views/admin/tickets/Debug/index.html deleted file mode 100755 index c1c41c6..0000000 --- a/legacy/views/admin/tickets/Debug/index.html +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Admin Debug
    -
    -
    - Updated: {debugUpdateTime} -
    -
    - {debugData:h} -
    -{appAdminURL} - - - - - {startScript:h} - - var reloadTimerHandle = false; - var reloadTime = 2000; - - // Reload the current window with Action = Debug_update - function reloadThisWindow() - { - window.location.assign("{appAdminURL}&Action=Debug_update"); - } - - // Sets debug reload timer to pick up new data in some period of time. - Called from emDebugWindowReloadRequest() in main .js file - function debugReloadRequest() - { - // Clear any pending reload request - if (reloadTimerHandle != false) { - window.clearTimeout(reloadTimerHandle); - } - - // Set timer to wait for additional actions before reloading debug page - reloadTimerHandle = window.setTimeout(reloadThisWindow, reloadTime); - - // Clear current debug data and display wait message - document.getElementById('debugBody').innerHTML = '
    Loading, waiting for possible additional requests...
    '; - } - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Debug/start.html b/legacy/views/admin/tickets/Debug/start.html deleted file mode 100755 index 20b8a62..0000000 --- a/legacy/views/admin/tickets/Debug/start.html +++ /dev/null @@ -1,56 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Admin Debug
    -
    -
    Debug Startup
    - - {startScript:h} - - var reloadTimerHandle = false; - var reloadTime = 4000; - - // Reload the current window with Action = Debug_update - function reloadThisWindow() - { - window.location.assign("?Action=Debug_update"); - } - - // Sets debug reload timer to pick up new data in some period of time. - Called from emDebugWindowReloadRequest() in main .js file - function debugReloadRequest() - { - // Clear any pending reload request - if (reloadTimerHandle != false) { - window.clearTimeout(reloadTimerHandle); - } - - // Set timer to wait for additional actions before reloading debug page - reloadTimerHandle = window.setTimeout(reloadThisWindow, reloadTime); - - // Clear current debug data and display wait message - document.getElementById('debugBody').innerHTML = '
    Loading, waiting for possible additional requests...
    '; - } - - - - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Entrance/delete.html b/legacy/views/admin/tickets/Entrance/delete.html deleted file mode 100755 index 2be67ae..0000000 --- a/legacy/views/admin/tickets/Entrance/delete.html +++ /dev/null @@ -1,55 +0,0 @@ -
    - -
    Delete this {term.entrance.cap}
    - -
    {entranceDetail.name}
    - -{if:checkPermission(#10#)} -
    - - -
    -{end:} - - {if:entranceDetail} -
    - - - - - - - - - -
    Delete {term.entrance.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.entrance.norm}.

    -
    Name:{entranceDetail.name}
    - {else:} -

    No {term.entrance.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#EntranceDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Entrance/detail.html b/legacy/views/admin/tickets/Entrance/detail.html deleted file mode 100755 index d72db45..0000000 --- a/legacy/views/admin/tickets/Entrance/detail.html +++ /dev/null @@ -1,104 +0,0 @@ -
    - -
    {term.entrance.cap}: {entranceDetail.name}
    - -
    - - -
    - - {if:entranceDetail} -
    - - - - {if:entranceDetail.delete} - - - - - {end:} - - - - - - - - - - - - - - -
    Delete {term.entrance.cap}: - {if:entranceDetail.deleteConfirmed} - {if:entranceDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {entranceDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.entrance.norm}.

    - {end:} -
    {term.entrance.cap} Name:{entranceDetail.name}
    Location: - {entranceDetail.addr1}
    - {if:entranceDetail.addr2}{entranceDetail.addr2}
    {end:} - {if:entranceDetail.city}{entranceDetail.city}{else:}(n/a){end:}, {entranceDetail.state.name} {entranceDetail.zip}
    - {if:entranceDetail.country.name}{entranceDetail.country.name}
    {end:} - - -
    (map loads here)
    -
    Phone:{entranceDetail.phone}
    Description:{entranceDetail.descr:h}
    Image: - {if:entranceDetail.image} - - {else:}(none){end:} -
    {term.voucher.cap} Color:  {entranceDetail.color.name}
    Sort Order:{entranceDetail.sort}
    - {else:} -

    No {term.entrance.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#EntranceDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - // Code to kick off the geolocation-display feature - $("#locationMap").geolocate({ - lat: "#lat", - lng: "#lon", - mapOptions: { - disableDefaultUI: false, - mapTypeControl: true, - mapTypeId: "roadmap", - zoom: 16 - }, - markerOptions: { - draggable: false, - title: "This is your selected location" - } - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Entrance/edit.html b/legacy/views/admin/tickets/Entrance/edit.html deleted file mode 100755 index 36ca1ca..0000000 --- a/legacy/views/admin/tickets/Entrance/edit.html +++ /dev/null @@ -1,299 +0,0 @@ -
    - -
    - {if:addingNewEntrance}Adding New {term.entrance.cap}{end:} - {if:editingEntrance}Editing {term.entrance.cap}{end:} -
    - -{if:checkPermission(#10#)} -
    - {if:addingNewEntrance} - - {else:} - - {end:} -
    -{end:} - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:entranceDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewEntrance} - - {else:} - - {end:} - - - - - -
    - - - - - {if:fieldRequired.name} - {if:fieldFail.name} - - - - - {if:fieldRequired.addr1} - {if:fieldFail.addr1} - - - {if:fieldRequired.addr2} - {if:fieldFail.addr2} - - - {if:fieldRequired.city} - {if:fieldFail.city} - - - {if:fieldRequired.state} - {if:fieldFail.state} - - - {if:fieldRequired.zip} - {if:fieldFail.zip} - - - {if:fieldRequired.country} - {if:fieldFail.country} - - - {if:fieldRequired.lat} - - - - {if:fieldRequired.phone} - {if:fieldFail.phone} - - - - - - {if:fieldRequired.descr} - {if:fieldFail.descr} - - - {if:fieldRequired.image} - {if:fieldFail.image} - - - {if:fieldRequired.color} - {if:fieldFail.color} - - - {if:fieldRequired.sort} - {if:fieldFail.sort} - - -
    {else:}{end:}{term.entrance.cap} Name:{else:}{end:} - - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    {else:}{end:}Address:{else:}{end:} - - {if:fieldFail.addr1}
    {fieldFail.addr1}{end:} -
    {else:}{end:} {else:}{end:} - - {if:fieldFail.addr2}
    {fieldFail.addr2}{end:} -
    {else:}{end:}City:{else:}{end:} - - {if:fieldFail.city}
    {fieldFail.city}{end:} -
    {else:}{end:}State:{else:}{end:} - - {if:fieldFail.state}
    {fieldFail.state}{end:} -
    {else:}{end:}ZIP/Postal Code:{else:}{end:} - - {if:fieldFail.zip}
    {fieldFail.zip}{end:} -
    {else:}{end:}Country:{else:}{end:} - - {if:fieldFail.country}
    {fieldFail.country}{end:} -
    {else:}{end:}Location: -
    - - -
    -

    - This map will try to find the new location whenever you change the address entered above. -

    -
    (map loads here)
    -

    - MAP USE: Drag the pointer to the desired location for this {term.prop.norm}. - Use + and - buttons or the mouse wheel to zoom in or out. - Click and drag anywhere else on the map to move to another area. -

    -
    {else:}{end:}Main Phone #:{else:}{end:} - - {if:fieldFail.phone}

    {fieldFail.phone}

    {end:} -
    {else:}{end:}Description:{else:}{end:} - - {if:fieldFail.descr}
    {fieldFail.descr}{end:} -
    {else:}{end:}Image:{else:}{end:} - {if:entranceDetail.image} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.image}
    {fieldFail.image}{end:} -
    {else:}{end:}{term.voucher.cap} Color:{else:}{end:} - - {if:fieldFail.color}
    {fieldFail.color}{end:} -
    {else:}{end:}Output Order:{else:}{end:} - - {if:fieldFail.sort}
    {fieldFail.sort}{end:} -
    -
    - -
    - {if:addingNewEntrance} - - {end:} - {if:editingEntrance} - - {end:} -
    - -
    - - {else:} -

    No {term.entrance.norm} has been selected yet.

    -

    To edit a {term.entrance.norm}, first select it from the list of available {term.entrance.plur}. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.entranceEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#EntranceForm').ajaxForm({ - success: function(data) { - {if:addingNewEntrance} - f_replaceContents(data, $('#Member_info_container')); - {end:} - {if:editingEntrance} - f_replaceContents(data, $('#Member_info_container')); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#entranceFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#descr")); - f_buildCkeditor($("#notes")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - /* - * Map operations - */ - - // Code to kick off the geolocation-edit feature - $("#locationMap").geolocate({ - lat: "#lat", - lng: "#lon", - address: [ - "#addr1", - "#city", - "#zip" - ], - mapOptions: { - disableDefaultUI: false, - mapTypeControl: true, - mapTypeId: "roadmap", - zoom: 16 - }, - markerOptions: { - title: "This is your selected location" - } - }); - - f_restartOnTabSelect(); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Entrance/list.html b/legacy/views/admin/tickets/Entrance/list.html deleted file mode 100644 index f3b8924..0000000 --- a/legacy/views/admin/tickets/Entrance/list.html +++ /dev/null @@ -1,129 +0,0 @@ - -
    - -
    - - -
    - - Search {term.entrance.plur_cap}: (type any portion of a {term.entrance.norm} name) - - {if:entranceList} - -
    - - - - - - {foreach:entranceList,c} - - - - - - {end:} - -
    Sort OrderName{term.voucher.cap} Color
    {c.sort}  {c.color.name}
    -
    - - {else:} -

    No {term.entrance.plur} listed.

    -

    - You do not need to have a {term.entrance.norm}. If you do decide to add {term.entrance.plur}, - you may associate specific ones with specific {term.section.plur} or {term.ticket.plur}. -

    - {end:} - -
    -
    - - -
    -{startScript:h} - - // Entrances Search - var entrancesSearchData = [ - {foreach:entranceList,c} - {label:'{c.name:h}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var EntranceListTable = $('#EntranceListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '80px' }, - null, - null - ] - }); - $(window).resize(function(){ - EntranceListTable.fnDraw(); - }); - - // Toggle length of table - var EntranceListTableSmall = true; - var EntranceListTableHeight = $('#EntranceListTable_wrapper div.dataTables_scrollBody').height(); - $('#entranceListSizeChange').click(function() { - if (EntranceListTableSmall) { - $('#EntranceListTable_wrapper div.dataTables_scrollBody').height('auto'); - EntranceListTableSmall = false; - $(this).html('Smaller Table'); - EntranceListTable.fnSettings().oScroll.sY = '100%'; - EntranceListTable.fnDraw(); - } else { - $('#EntranceListTable_wrapper div.dataTables_scrollBody').height(EntranceListTableHeight); - EntranceListTableSmall = true; - $(this).html('Larger Table'); - EntranceListTable.fnSettings().oScroll.sY = '100px'; - EntranceListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Entrance_detail_container').hide(duration); - - $('.entranceListSelect').click(function(){ - $('#EntranceListTable_wrapper div.dataTables_scrollBody').height(EntranceListTableHeight); - EntranceListTableSmall = true; - $('#entranceListSizeChange').html('Larger Table'); - EntranceListTable.fnSettings().oScroll.sY = '100px'; - EntranceListTable.fnDraw(); - f_loadAction('Entrance_detail', 'Entrance_detail_container', 'EntranceID=' + $(this).attr('emEntranceId') + '&tabList={tabList}'); - }); - - // Search Entrances - $("#entrancesSearch").autocomplete({ - source: entrancesSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#entrancesSearch").attr({value: ui.item.label}); - f_loadAction('Entrance_detail', 'Entrance_detail_container', 'EntranceID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Event/index.html b/legacy/views/admin/tickets/Event/index.html deleted file mode 100755 index 288c565..0000000 --- a/legacy/views/admin/tickets/Event/index.html +++ /dev/null @@ -1,17 +0,0 @@ -
    -
    -
    This is the {term.event.norm} area....
    -

    - some stuff goes here -

    -
    -
    - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Help/index.html b/legacy/views/admin/tickets/Help/index.html deleted file mode 100644 index 64ec5a2..0000000 --- a/legacy/views/admin/tickets/Help/index.html +++ /dev/null @@ -1,43 +0,0 @@ -
    -
    -
    Event Management System Help.
    -

    -

    Printable Help Documentation
    -

    -
    -
    - -
    -
    Packaging Quick Reference
    -
    -

    Location that only offers items contained in a package

    - - - - -
    Type: Other - neither vendor nor sales
    Active: Yes
    Payment: No payment setup is required
    -

    Categories that only contain times used in a package

    - - - - -
    Active: No
    Purchace by Admin Only: No
    Promote in Cart: No
    -

    Items that are only used in a package

    - - - - - - -
    Active: No
    Purchace by Admin Only: No
    Always show in cart: No
    Boarding Pass Type: Voucher/Ticket for Pickup - no Barcode
    NO ADDONS!
    -
    -
    - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Member/added.html b/legacy/views/admin/tickets/Member/added.html deleted file mode 100755 index f877380..0000000 --- a/legacy/views/admin/tickets/Member/added.html +++ /dev/null @@ -1,16 +0,0 @@ -
    - -
    New {term.prop.cap} Added
    - -
    - -{startScript:h} - - $(function() { - f_loadAction('Member_list', 'Member_area', 'MembersListOption=all&tabList={tabList}'); - f_loadAction('Member_selected', 'Member_selected', 'member_id={memberDetail.id}&tabList={tabList}'); - - }); - - - diff --git a/legacy/views/admin/tickets/Member/delete.html b/legacy/views/admin/tickets/Member/delete.html deleted file mode 100755 index e0c2ba9..0000000 --- a/legacy/views/admin/tickets/Member/delete.html +++ /dev/null @@ -1,228 +0,0 @@ -
    - -
    Delete this {term.prop.cap}
    - -{if:checkPermission(#10#)} -
    - -
    -{end:} - - {if:memberDetail} -
    - - - - - - - - {if:option.member_db_integrated} - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {if:option.accommodations} - - - - - - - {end:} - - - - -
    Delete {term.prop.cap}: -

    -

    - WARNING: Deleting this {term.prop.norm} will remove all related data. - This will remove all history related to this {term.prop.norm} and will - remove all related data from reports. -

    -

    - You may want to simply mark this {term.prop.norm} as "inactive" by un-checking - the "Account Active" option in the {term.prop.norm} edit screen then delete the - {term.prop.norm} after all yearly reports have been produced. -

    -

    - If you are sure you want to continue, please enter exactly "Please Delete" in - the field below then click the "Confirm Delete" button. This action will not - be reversable! -

    -

    -

    - Delete Confirmation: - -
    -

    -

    -
    Name:{memberDetail.member_name}
    {term.prop.cap} Name:{memberDetail.name}
    {term.prop.cap} Type:{memberDetail.member_type.name}
    Location: - {memberDetail.addr1}
    - {if:memberDetail.addr2}{memberDetail.addr2}
    {end:} - {if:memberDetail.city}{memberDetail.city}{else:}(n/a){end:}, {memberDetail.state.name} {memberDetail.zip}
    - {if:memberDetail.country.name}{memberDetail.country.name}
    {end:} - - -
    (map loads here)
    -
    Phone:{memberDetail.phone}
    E-Mail Address:{memberDetail.email}
    Processing E-Mail Address:{memberDetail.proc_email}
    Secondary Processing E-Mail Address:{memberDetail.proc_email2}
    Send Notice of Each Customer Purchase:{memberDetail.checkout_notify.name}
    Description:{memberDetail.descr:h}
    Credit Cards Accepted: - {foreach:memberDetail.cards_accepted.names,s}{s}
    {end:} -
    Payment Gateway: - {memberDetail.payment_gateway.name}
    - - - - - - -
    {memberDetail.gateway_par1}
    {memberDetail.gateway_par2}
    {memberDetail.gateway_par3.name}
    {memberDetail.gateway_par4.name}
    {memberDetail.gateway_par5}
    -
    PayPal Payment Gateway: -

    PayPal Gateway Enabled: {memberDetail.paypal.name}

    - - - - -
    Client ID{memberDetail.paypal_client_id}
    Secret:{memberDetail.paypal_secret}
    Mode:{memberDetail.paypal_mode.name}
    -
    SSL Seal for Checkout Page: - - - -
    Head Script:{memberDetail.ssl_seal_head_script:h}
    Body Script:{memberDetail.ssl_seal_body_script:h}
    -
    Image:{memberDetail.image}
    Sections Map:{memberDetail.ticket_sec_map}
    Accept Special Requests:{memberDetail.ticket_spec_req.name}
    Check-In Time:{memberDetail.check_in.time}
    Check-Out Time:{memberDetail.check_out.time}
    Accommodation Amenities: - {if:memberDetail.amen_1.displayName}{if:memberDetail.amen_1.value}{memberDetail.amen_1.displayName}
    {end:}{end:} - {if:memberDetail.amen_2.displayName}{if:memberDetail.amen_2.value}{memberDetail.amen_2.displayName}
    {end:}{end:} - {if:memberDetail.amen_3.displayName}{if:memberDetail.amen_3.value}{memberDetail.amen_3.displayName}
    {end:}{end:} - {if:memberDetail.amen_4.displayName}{if:memberDetail.amen_4.value}{memberDetail.amen_4.displayName}
    {end:}{end:} - {if:memberDetail.amen_5.displayName}{if:memberDetail.amen_5.value}{memberDetail.amen_5.displayName}
    {end:}{end:} - {if:memberDetail.amen_6.displayName}{if:memberDetail.amen_6.value}{memberDetail.amen_6.displayName}
    {end:}{end:} - {if:memberDetail.amen_7.displayName}{if:memberDetail.amen_7.value}{memberDetail.amen_7.displayName}
    {end:}{end:} - {if:memberDetail.amen_8.displayName}{if:memberDetail.amen_8.value}{memberDetail.amen_8.displayName}
    {end:}{end:} - {if:memberDetail.amen_9.displayName}{if:memberDetail.amen_9.value}{memberDetail.amen_9.displayName}
    {end:}{end:} - {if:memberDetail.amen_10.displayName}{if:memberDetail.amen_10.value}{memberDetail.amen_10.displayName}
    {end:}{end:} -
    General Policies:{memberDetail.def_ticket_pol:h}
    Sort Order:{memberDetail.sort}
    Notes:{memberDetail.notes:h}
    -
    - {else:} - No member information available. - {end:} - -
    -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - $('#MemberDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - // Code to kick off the geolocation-edit feature - $("#locationMap").geolocate({ - lat: "#lat", - lng: "#lon", - mapOptions: { - disableDefaultUI: false, - mapTypeControl: true, - mapTypeId: "roadmap", - zoom: 16 - }, - markerOptions: { - draggable: false, - title: "This is your selected location" - } - }); - - // Determine which payment gateway is selected and set prompts and visible fields accordingly - // Authorize.net - var g = {memberDetail.payment_gateway.value}; - if (g == 1) { - $('#usePar1').show(duration); - $('#gatewayPar1Name').html('Login: '); - $('#usePar2').show(duration); - $('#gatewayPar2Name').html('Key: '); - $('#usePar3').show(duration); - $('#gatewayPar3Name').html('Mode: '); - $('#usePar4').show(duration); - $('#gatewayPar4Name').html('Merchant E-Mail Sent: '); - $('#usePar5').show(duration); - $('#gatewayPar5Name').html('Merchant E-Mail: '); - } - // Merchant Solutions - if (g == 2) { - $('#usePar1').show(duration); - $('#gatewayPar1Name').html('Account ID: '); - $('#usePar2').show(duration); - $('#gatewayPar2Name').html('Merchant Pin: '); - $('#usePar3').hide(duration); - $('#gatewayPar3Name').html(''); - $('#usePar4').hide(duration); - $('#gatewayPar4Name').html(''); - $('#usePar5').hide(duration); - $('#gatewayPar5Name').html(''); - } - // None selected - if (g == 0) { - $('#usePar1').hide(duration); - $('#usePar2').hide(duration); - $('#usePar3').hide(duration); - $('#usePar4').hide(duration); - $('#usePar5').hide(duration); - } - - // Check delete confirmation - $('#Member_confirmDelete').on('click', null, function() { - - // Check for proper confirmation string - var conf = $('#deleteConfirmationText').val(); - if (conf != 'Please Delete') { - alert('To confirm enter exactly "Please Delete" or click "Cancel Delete" to abort.'); - } else { - f_loadAction('Member_confirmDelete', 'Member_info_container', false); - } - return false; - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Member/detail.html b/legacy/views/admin/tickets/Member/detail.html deleted file mode 100644 index 2a413ae..0000000 --- a/legacy/views/admin/tickets/Member/detail.html +++ /dev/null @@ -1,290 +0,0 @@ -
    - -{if:memberNotFound} - - (member not found) - -{else:} - - {if:memberDeleted} -
    Member Deleted
    - {else:} -
    - {if:checkPermission(#0#)} - - {end:} - {if:checkPermission(#10#)} - - {end:} -
    - {end:} - -
    - {if:addingNewMember}Adding New {term.prop.cap}{end:} - {if:editingMember}Editing {term.prop.cap}{end:} -
    - -
    - - - - {if:option.member_db_integrated} - - {end:} - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {if:option.accommodations} - - - - - - - {end:} - - - - - - -
    Name:{memberDetail.member_name}
    {term.prop.cap} Name:{memberDetail.name:h}ID: {memberDetail.id}
    {term.prop.cap} Type:{memberDetail.member_type.name}
    Active:{memberDetail.active.name}
    Location: - {memberDetail.addr1}
    - {if:memberDetail.addr2}{memberDetail.addr2}
    {end:} - {if:memberDetail.city}{memberDetail.city}{else:}(n/a){end:}, {memberDetail.state.name} {memberDetail.zip}
    - {if:memberDetail.country.name}{memberDetail.country.name}
    {end:} - - -
    (map loads here)
    -
    Phone:{memberDetail.phone}
    E-Mail Address:{memberDetail.email}
    Processing E-Mail Address:{memberDetail.proc_email}
    Secondary Processing E-Mail Address:{memberDetail.proc_email2}
    Send Notice of Each Customer Purchase:{memberDetail.checkout_notify.name}
    Description:{memberDetail.descr:h}
    Credit Cards Accepted: - {foreach:memberDetail.cards_accepted.names,s}{s}
    {end:} -
    Credit Card Payment Gateway: -

    {memberDetail.payment_gateway.name}

    - - - - - - -
    {memberDetail.gateway_par1}
    {memberDetail.gateway_par2}
    {memberDetail.gateway_par3.name}
    {memberDetail.gateway_par4.name}
    {memberDetail.gateway_par5}
    -
    PayPal Payment Gateway: -

    PayPal Gateway Enabled: {memberDetail.paypal.name}

    - - - - -
    Client ID{memberDetail.paypal_client_id}
    Secret:{memberDetail.paypal_secret}
    Mode:{memberDetail.paypal_mode.name}
    -
    SSL Seal for Checkout Page: - - - -
    Head Script:{memberDetail.ssl_seal_head_script:h}
    Body Script:{memberDetail.ssl_seal_body_script:h}
    -
    Image: - {if:memberDetail.image} - - {fileServer.secure}{fileServer.owner_id}/{image_style.default}/{memberDetail.image} - {else:}(none){end:} -
    Parking Map: - {if:memberDetail.parking_map} - - {else:}(none){end:} -
    Sections Map: - {if:memberDetail.ticket_sec_map} - - {else:}(none){end:} -
    Accept Special Requests:{memberDetail.ticket_spec_req.name}
    {term.prop.cap} Scans For: - {if:haveMemberScansFor} -

    When scanning packages, this {term.prop.norm} also scans for the following {term.prop.plur}.

    - - - - - {foreach:memberScansFor,s} - - - - {end:} - -
    {term.prop.plur_cap}
    {s.scans_for_name}
    - {else:} - This {term.prop.norm} is not scanning package {term.ticket.plur} for other {term.prop.plur}. - {end:} -
    Check-In Time:{memberDetail.check_in.time}
    Check-Out Time:{memberDetail.check_out.time}
    Accommodation Amenities: - {if:memberDetail.amen_1.displayName}{if:memberDetail.amen_1.value}{memberDetail.amen_1.displayName}
    {end:}{end:} - {if:memberDetail.amen_2.displayName}{if:memberDetail.amen_2.value}{memberDetail.amen_2.displayName}
    {end:}{end:} - {if:memberDetail.amen_3.displayName}{if:memberDetail.amen_3.value}{memberDetail.amen_3.displayName}
    {end:}{end:} - {if:memberDetail.amen_4.displayName}{if:memberDetail.amen_4.value}{memberDetail.amen_4.displayName}
    {end:}{end:} - {if:memberDetail.amen_5.displayName}{if:memberDetail.amen_5.value}{memberDetail.amen_5.displayName}
    {end:}{end:} - {if:memberDetail.amen_6.displayName}{if:memberDetail.amen_6.value}{memberDetail.amen_6.displayName}
    {end:}{end:} - {if:memberDetail.amen_7.displayName}{if:memberDetail.amen_7.value}{memberDetail.amen_7.displayName}
    {end:}{end:} - {if:memberDetail.amen_8.displayName}{if:memberDetail.amen_8.value}{memberDetail.amen_8.displayName}
    {end:}{end:} - {if:memberDetail.amen_9.displayName}{if:memberDetail.amen_9.value}{memberDetail.amen_9.displayName}
    {end:}{end:} - {if:memberDetail.amen_10.displayName}{if:memberDetail.amen_10.value}{memberDetail.amen_10.displayName}
    {end:}{end:} -
    {term.ticket.cap} Sales Intro Text:{memberDetail.intro_text:h}
    {term.ticket.cap} Sales Checkout E-Mail Sent:{memberDetail.checkout_email:h}
    General Policies:{memberDetail.def_ticket_pol:h}
    Sort Order:{memberDetail.sort}
    Notes:{memberDetail.notes:h}
    -
    - -
    - - - - - -{end:} - diff --git a/legacy/views/admin/tickets/Member/edit.html b/legacy/views/admin/tickets/Member/edit.html deleted file mode 100644 index c92217d..0000000 --- a/legacy/views/admin/tickets/Member/edit.html +++ /dev/null @@ -1,762 +0,0 @@ -
    - -
    - {if:addingNewMember}Adding New {term.prop.cap}{end:} - {if:editingMember}Editing {term.prop.cap}{end:} -
    - -
    -{if:addingNewMember} - - -{if:formFail} -
    Please note:
    -
      -
    • Not all fields were filled in correctly. Please try again.
    • -
    -{end:} - -
    - {if:memberDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewMember}{end:} - {if:editingMember}{end:} - - - - {if:checkPermission(#0#)} - {else:} - - {end:} - -
    - - - - {if:option.member_db_integrated} - - - - - {end:} - - {if:fieldRequired.name} - {if:fieldFail.name} - - {if:option.member_db_integrated} - {else:} - {if:checkPermission(#0#)} - - {if:fieldRequired.member_type} - {if:fieldFail.member_type} - - {else:} - - - - - {end:} - {if:checkPermission(#0#)} - - - - - {end:} - - {if:fieldRequired.addr1} - {if:fieldFail.addr1} - - - {if:fieldRequired.addr2} - {if:fieldFail.addr2} - - - {if:fieldRequired.city} - {if:fieldFail.city} - - - {if:fieldRequired.state} - {if:fieldFail.state} - - - {if:fieldRequired.zip} - {if:fieldFail.zip} - - - {if:fieldRequired.country} - {if:fieldFail.country} - - - {if:fieldRequired.lat} - - - {end:} - - {if:fieldRequired.phone} - {if:fieldFail.phone} - - - {if:fieldRequired.email} - {if:fieldFail.email} - - - {if:fieldRequired.proc_email} - {if:fieldFail.proc_email} - - - {if:fieldRequired.proc_email2} - {if:fieldFail.proc_email2} - - - - - - - {if:fieldRequired.descr} - {if:fieldFail.descr} - - - {if:fieldRequired.cards_accepted} - {if:fieldFail.cards_accepted} - - - {if:fieldRequired.payment_gateway} - {if:fieldFail.payment_gateway} - - - - - - - {if:fieldRequired.image} - {if:fieldFail.image} - - - {if:fieldRequired.parking_map} - {if:fieldFail.parking_map} - - - {if:fieldRequired.ticket_sec_map} - {if:fieldFail.ticket_sec_map} - - - - - - - - - - {if:option.accommodations} - - {if:fieldRequired.check_in} - {if:fieldFail.check_in} - - - {if:fieldRequired.check_out} - {if:fieldFail.check_out} - - {end:} - - {if:fieldRequired.intro_text} - {if:fieldFail.intro_text} - - - {if:fieldRequired.checkout_email} - {if:fieldFail.checkout_email} - - - {if:fieldRequired.def_ticket_pol} - {if:fieldFail.def_ticket_pol} - - - {if:fieldRequired.sort} - {if:fieldFail.sort} - - - {if:fieldRequired.notes} - {if:fieldFail.notes} - - {if:option.accommodations} - - - - - {end:} - -
    {term.prop.Cap} Name: - {if:addingNewMember} - - {else:} - {memberDetail.member_name:h} - {end:} -
    {else:}{end:}{term.prop.cap} Name:{else:}{end:} - {if:checkPermission(#0#)} - - {else:} - {memberDetail.name:h} - {end:} - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    {else:}{end:}{term.prop.cap} Type:{else:}{end:} - - {if:fieldFail.member_type}
    {fieldFail.member_type}{end:} -
    {term.prop.cap} Type:{memberDetail.member_type.name}
    Account Active: - {if:memberDetail.active.value} - - {else:} - - {end:} -
    {else:}{end:}Address:{else:}{end:} - - {if:fieldFail.addr1}
    {fieldFail.addr1}{end:} -
    {else:}{end:} {else:}{end:} - - {if:fieldFail.addr2}
    {fieldFail.addr2}{end:} -
    {else:}{end:}City:{else:}{end:} - - {if:fieldFail.city}
    {fieldFail.city}{end:} -
    {else:}{end:}State:{else:}{end:} - - {if:fieldFail.state}
    {fieldFail.state}{end:} -
    {else:}{end:}ZIP/Postal Code:{else:}{end:} - - {if:fieldFail.zip}
    {fieldFail.zip}{end:} -
    {else:}{end:}Country:{else:}{end:} - - {if:fieldFail.country}
    {fieldFail.country}{end:} -
    {else:}{end:}Location: -
    - - -
    -

    - This map will try to find the new location whenever you change the address entered above. -

    -
    (map loads here)
    -

    - MAP USE: Drag the pointer to the desired location for this {term.prop.norm}. - Use + and - buttons or the mouse wheel to zoom in or out. - Click and drag anywhere else on the map to move to another area. -

    -
    {else:}{end:}Main Phone #:{else:}{end:} - - {if:fieldFail.phone}

    {fieldFail.phone}

    {end:} -
    {else:}{end:}E-Mail Address:{else:}{end:} - - {if:fieldFail.email}

    {fieldFail.email}

    {end:} -
    {else:}{end:}Processing E-Mail Address:{else:}{end:} - - {if:fieldFail.proc_email}

    {fieldFail.proc_email}

    {end:} -
    {else:}{end:}Secondary Processing E-Mail Address:{else:}{end:} - - {if:fieldFail.proc_email2}

    {fieldFail.email}

    {end:} -
    Send Notice of Each Customer Purchase: - {if:memberDetail.checkout_notify.value} - - {else:} - - {end:} -
    {else:}{end:}Description:{else:}{end:} - - {if:fieldFail.descr}
    {fieldFail.descr}{end:} -
    {else:}{end:}Credit Cards Accepted:{else:}{end:} - - {if:fieldFail.cards_accepted}
    {fieldFail.cards_accepted}{end:} -
    {else:}{end:}Credit Card Payment Gateway:{else:}{end:} -

    - -

    - {if:fieldFail.payment_gateway}
    {fieldFail.payment_gateway}{end:} -

    - - - - - - - - - - - -


    - -
    - {if:memberDetail.gateway_par4.value} - - {else:} - - {end:} - -

    -

    -
    - -
    PayPal Payment Gateway: - Enable PayPal Payment Gateway: - {if:memberDetail.paypal.value} - - {else:} - - {end:} -
    (PayPal payment option is currently unavailable - Please contact Gaslight Media if you require this option) -

    - - - - - - - -
    Client ID:
    Secret:
    Mode: - -
    -

    -
    {else:}{end:}Image:{else:}{end:} - {if:memberDetail.image} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.image}
    {fieldFail.image}{end:} -
    {else:}{end:}Parking Map:{else:}{end:} - {if:memberDetail.parking_map} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.parking_map}
    {fieldFail.parking_map}{end:} -
    {else:}{end:}Section Map:{else:}{end:} - {if:memberDetail.ticket_sec_map} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.ticket_sec_map}
    {fieldFail.ticket_sec_map}{end:} -
    Accept Ticket Special Requests: - {if:memberDetail.ticket_spec_req.value} - - {else:} - - {end:} -
    {term.prop.cap} Scans For: -
    -

    When scanning packages, this {term.prop.cap} also scans for the following {term.prop.plur}.

    -

    - - -

    - - - - - - {foreach:memberScansFor,y} - - - - - {end:} - -
    {term.prop.cap}
    {y.scans_for_name:h}
    -
    -
    {else:}{end:}Check-In Time:{else:}{end:} - - - - {if:fieldFail.check_in}

    {fieldFail.check_in}

    {end:} -
    {else:}{end:}Check-Out Time:{else:}{end:} - - - - {if:fieldFail.check_out}

    {fieldFail.check_out}

    {end:} -
    {else:}{end:}{term.ticket.cap} Sales Intro Text:{else:}{end:} - - {if:fieldFail.intro_text}
    {fieldFail.intro_text}{end:} -

    This text is displayed at the top of the page when customers first enter the ticket sales system for one of your {term.performance.plur}.

    -
    {else:}{end:}{term.ticket.cap} Sales Checkout E-Mail Sent:{else:}{end:} - - {if:fieldFail.checkout_email}
    {fieldFail.checkout_email}{end:} -

    This is the E-Mail message the system sends out to a customer when they complete a purchase for {term.performance.plur}. - You may use certain "tags" that will be replaced with relevant text. These begin with { and end with } characters. - the list of such terms you can use are below.

    -

    {first-name}, {last-name}, {address-line-1}, {address-line-2}, - {city}, {state}, {zip}, {country}, {{term.prop.norm}-text}

    -

    The {{term.performance.norm}-text} tag will insert any text in the "Text for Confirmation E-Mail:" fields of - any {term.performance.plur} selected by the customer. If the customer selected a particular {term.performance.norm} - multiple times, that text will only be used once.

    - -
    {else:}{end:}General Policies:{else:}{end:} - - {if:fieldFail.def_ticket_pol}
    {fieldFail.def_ticket_pol}{end:} -

    This field does not permit formatting because it is used on {term.voucher.plur}.

    -
    {else:}{end:}Output Order:{else:}{end:} - - {if:fieldFail.sort}
    {fieldFail.sort}{end:} -
    {else:}{end:}Notes:{else:}{end:} - - {if:fieldFail.notes}
    {fieldFail.notes}{end:} -
    Accommodation Amenities: -

    - These are pre-defined accommodation amenitities for this {term.prop.norm}. You may also add additional accommodation - amenities to this {term.prop.norm} using the "Amenities" sub-menu button. -

    - {if:memberDetail.amen_1.displayName}{if:memberDetail.amen_1.value}{else:}{end:}{memberDetail.amen_1.displayName}
    {end:} - {if:memberDetail.amen_2.displayName}{if:memberDetail.amen_2.value}{else:}{end:}{memberDetail.amen_2.displayName}
    {end:} - {if:memberDetail.amen_3.displayName}{if:memberDetail.amen_3.value}{else:}{end:}{memberDetail.amen_3.displayName}
    {end:} - {if:memberDetail.amen_4.displayName}{if:memberDetail.amen_4.value}{else:}{end:}{memberDetail.amen_4.displayName}
    {end:} - {if:memberDetail.amen_5.displayName}{if:memberDetail.amen_5.value}{else:}{end:}{memberDetail.amen_5.displayName}
    {end:} - {if:memberDetail.amen_6.displayName}{if:memberDetail.amen_6.value}{else:}{end:}{memberDetail.amen_6.displayName}
    {end:} - {if:memberDetail.amen_7.displayName}{if:memberDetail.amen_7.value}{else:}{end:}{memberDetail.amen_7.displayName}
    {end:} - {if:memberDetail.amen_8.displayName}{if:memberDetail.amen_8.value}{else:}{end:}{memberDetail.amen_8.displayName}
    {end:} - {if:memberDetail.amen_9.displayName}{if:memberDetail.amen_9.value}{else:}{end:}{memberDetail.amen_9.displayName}
    {end:} - {if:memberDetail.amen_10.displayName}{if:memberDetail.amen_10.value}{else:}{end:}{memberDetail.amen_10.displayName}
    {end:} -
    -
    - -
    - {if:addingNewMember} - - {end:} - {if:editingMember} - - {end:} -
    - -
    - - {else:} -

    No {term.prop.norm} has been selected yet.

    -

    To edit a {term.prop.norm}, first select it from the list of available {term.prop.plur}.

    - {end:} - -
    - -
    - -
    - - - - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Member/index.html b/legacy/views/admin/tickets/Member/index.html deleted file mode 100755 index 887b60f..0000000 --- a/legacy/views/admin/tickets/Member/index.html +++ /dev/null @@ -1,38 +0,0 @@ - -
    - - -{if:checkPermission(#10#)} -
    - - -
    -{end:} - -
    -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - $('#Member_selected').hide(duration); - - // Start with member stats loaded - f_loadAction('Member_stats', 'Member_container', 'tabList={tabList}'); - - f_restartOnTabSelect(); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Member/list.html b/legacy/views/admin/tickets/Member/list.html deleted file mode 100644 index def3c39..0000000 --- a/legacy/views/admin/tickets/Member/list.html +++ /dev/null @@ -1,131 +0,0 @@ - -
    - -
    - - -
    -{if:checkPermission(#0#)} - -{end:} - -
    - Search {term.prop.cap}: (type any portion of a {term.prop.norm} name) - - {if:membersList} -
    - - - - - - {foreach:membersList,m} - - - - - - - - {end:} - -
    SortNameTypeCityPhone
    {m.sort}
    -
    - {else:} -

    No {term.prop.plur} are currently listed.

    -

    You will need to add at least one to use this system.

    - {end:} - - -
    -
    - -
    - -
    - -{startScript:h} - - // Members Search - var membersSearchData = [ - {foreach:membersList,m} - {label:'{m.name:h}, {m.member_type.nameEsc:h}, {m.city:h}, {m.phone}', value:'{m.id}'}, - {end:} - ]; - - $(function() { - - var MemberListTable = $('#MemberListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - $(window).resize(function(){ - MemberListTable.fnDraw(); - }); - - // Toggle length of table - var MemberListTableSmall = true; - var MemberListTableHeight = $('#MemberListTable_wrapper div.dataTables_scrollBody').height(); - $('#memberListSizeChange').click(function() { - if (MemberListTableSmall) { - $('#MemberListTable_wrapper div.dataTables_scrollBody').height('auto'); - MemberListTableSmall = false; - $(this).html('Smaller Table'); - MemberListTable.fnSettings().oScroll.sY = '100%'; - MemberListTable.fnDraw(); - } else { - $('#MemberListTable_wrapper div.dataTables_scrollBody').height(MemberListTableHeight); - MemberListTableSmall = true; - $(this).html('Larger Table'); - MemberListTable.fnSettings().oScroll.sY = '100px'; - MemberListTable.fnDraw(); - } - }); - - $('.memberListSelect').click(function(){ - $('#MemberListTable_wrapper div.dataTables_scrollBody').height(MemberListTableHeight); - MemberListTableSmall = true; - $('#memberListSizeChange').html('Larger Table'); - MemberListTable.fnSettings().oScroll.sY = '100px'; - MemberListTable.fnDraw(); - f_loadAction('Member_selected', 'Member_selected_container', 'MemberID=' + $(this).attr('emMembId') + '&tabList={tabList}'); - }); - - // Search Members - $("#membersSearch").autocomplete({ - source: membersSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#membersSearch").attr({value: ui.item.label}); - f_loadAction('Member_selected', 'Member_selected_container', 'MemberID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - {if:displayMember} - f_loadAction('Member_selected', 'Member_selected_container', 'MemberID={displayMember}&tabList={tabList}'); - {end:} - - }); - - diff --git a/legacy/views/admin/tickets/Member/redisplayList.html b/legacy/views/admin/tickets/Member/redisplayList.html deleted file mode 100755 index fe83527..0000000 --- a/legacy/views/admin/tickets/Member/redisplayList.html +++ /dev/null @@ -1,19 +0,0 @@ -
    - Reloading... -
    - - - - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Member/selected.html b/legacy/views/admin/tickets/Member/selected.html deleted file mode 100755 index a07f8e9..0000000 --- a/legacy/views/admin/tickets/Member/selected.html +++ /dev/null @@ -1,139 +0,0 @@ -
    - -
    -
    {term.prop.cap}: {memberDetail.name:h}
    - - -
    - - - -
    - - -{if:checkPermission(#10#)} -
    - - - {if:option.accommodations} - - {end:} - {if:option.tickets} - - - {if:blockTab.Performance_selected} - {else:} - {if:checkPermission(#0#)} - {if:noTab.performance}{else:} - - {end:} - {end:} - {end:} - {end:} -
    -{end:} - - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - var x = $('#MemberSelectedStatsTable').dataTable({ - "sScrollY": "100px", - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - // Close all local sliders - $('#Member_info_container').hide(duration); - - // Start with member detail loaded - f_loadAction('Member_detail', 'Member_info_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Member/stats.html b/legacy/views/admin/tickets/Member/stats.html deleted file mode 100755 index c1e2634..0000000 --- a/legacy/views/admin/tickets/Member/stats.html +++ /dev/null @@ -1,69 +0,0 @@ -
    -
    -
    Statistics for all {term.prop.plur}
    -
    - - - - {if:option.events} - - {end:} - {if:option.accommodations} - - {end:} - {if:option.tickets} - - {end:} - -
    Total {term.prop.plur} in this system: {membersStats.all}
    {term.prop.plur_cap} with {term.unit.plur}: {membersStats.accom}
    {term.prop.plur_cap} with {term.ticket.plur}: {membersStats.ticket}
    -
    -
    - {if:membersStats.flag} -
    -
    Please note:
    -
      - {if:membersStats.all}{else:} -
    • No {term.prop.plur} are listed in this system.
    • - {end:} - {if:option.accommodations} - {if:membersStats.accom}{else:} -
    • No {term.prop.plur} have {term.unit.plur}.
    • - {end:} - {end:} - {if:option.tickets} - {if:membersStats.ticket}{else:} -
    • No {term.prop.plur} have {term.ticket.plur}.
    • - {end:} - {end:} - {if:option.events} - {if:membersStats.event}{else:} -
    • There are no {term.event.plur} associated with any {term.prop.plur}.
    • - {end:} - {end:} -
    -
    - {end:} - -
    - -{startScript:h} - - $(function() { - - $('#MemberStatsTable').dataTable({ - "sScrollY": "100px", - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Misc/blank.html b/legacy/views/admin/tickets/Misc/blank.html deleted file mode 100755 index a3dcf0f..0000000 --- a/legacy/views/admin/tickets/Misc/blank.html +++ /dev/null @@ -1,2 +0,0 @@ -
    -
    diff --git a/legacy/views/admin/tickets/Misc/configDetail.html b/legacy/views/admin/tickets/Misc/configDetail.html deleted file mode 100644 index 7a635bb..0000000 --- a/legacy/views/admin/tickets/Misc/configDetail.html +++ /dev/null @@ -1,80 +0,0 @@ -
    - -
    - Miscellaneous System Configuration -
    - -
    - -
    - -
    - - - - - - - - - - - - - - - - - - - - - - - - -
    Text for {term.performance.norm} selection page:{miscConfigDetail.intro_text:h}
    Text for {term.section.norm} selection page:{miscConfigDetail.section_text:h}
    Text for {term.ticket.norm} selection page:{miscConfigDetail.ticket_text:h}
    Text for cart page:{miscConfigDetail.cart_text:h}
    Text for checkout page:{miscConfigDetail.checkout_text:h}
    Text for checkout success page:{miscConfigDetail.success_text:h}
    Tracking script for checkout success page:
    {miscConfigDetail.tracking}
      
    Text prompts for
    optional checkout fields:
    - #1: {miscConfigDetail.opt_field_1_name}
    - #2: {miscConfigDetail.opt_field_2_name}
    - #3: {miscConfigDetail.opt_field_3_name}
    -  
    - (Blank fields are not included in the checkout page.) -
    SSL Seal for Checkout Page: - - - -
    Head Script:{miscConfigDetail.ssl_seal_head_script}
    Body Script:{miscConfigDetail.ssl_seal_body_script}
    -
    Central Payment {term.prop.Cap}: - {if:miscConfigDetail.central_payment} - All payments will be processed through {miscConfigDetail.central_payment:h}. - {else:} - Payments will not be centrally processed. - {end:} -
    -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#MiscConfigDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns": [ - { "sWidth": "300px" }, - null - ] - - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Misc/configEdit.html b/legacy/views/admin/tickets/Misc/configEdit.html deleted file mode 100644 index 3a758ca..0000000 --- a/legacy/views/admin/tickets/Misc/configEdit.html +++ /dev/null @@ -1,214 +0,0 @@ -
    - -
    - Miscellaneous System Configuration -
    - -
    - -
    - - - -
    - - - - - {if:fieldRequired.intro_text} - {if:fieldFail.intro_text} - - - {if:fieldRequired.section_text} - {if:fieldFail.section_text} - - - {if:fieldRequired.ticket_text} - {if:fieldFail.ticket_text} - - - {if:fieldRequired.cart_text} - {if:fieldFail.cart_text} - - - {if:fieldRequired.checkout_text} - {if:fieldFail.checkout_text} - - - {if:fieldRequired.success_text} - {if:fieldFail.success_text} - - - - - - - - - - - - - - - {if:fieldRequired.central_payment} - {if:fieldFail.central_payment} - - -
    {else:}{end:}Text for {term.performance.norm} selection page:{else:}{end:} - - {if:fieldFail.intro_text}
    {fieldFail.intro_text}{end:} -
    {else:}{end:}Text for {term.section.norm} selection page:{else:}{end:} - - {if:fieldFail.section_text}
    {fieldFail.section_text}{end:} -
    {else:}{end:}Text for {term.ticket.norm} selection page:{else:}{end:} - - {if:fieldFail.ticket_text}
    {fieldFail.ticket_text}{end:} -
    {else:}{end:}Text for cart page:{else:}{end:} - - {if:fieldFail.cart_text}
    {fieldFail.cart_text}{end:} -
    {else:}{end:}Text for checkout page:{else:}{end:} - - {if:fieldFail.checkout_text}
    {fieldFail.checkout_text}{end:} -
    {else:}{end:}Text for checkout success page:{else:}{end:} - - {if:fieldFail.success_text}
    {fieldFail.success_text}{end:} -
    Tracking script for checkout success page:
    Optional Checkout Fields: -

    - NOTE: Optional checkout fields below are not used if they are blank.
    - If a field name is provided, the user will be asked to provide input to a field with this name on the checkout page. -

    - - - {if:fieldRequired.opt_field_1_name} - {if:fieldFail.opt_field_1_name} - - - {if:fieldRequired.opt_field_2_name} - {if:fieldFail.opt_field_2_name} - - - {if:fieldRequired.opt_field_3_name} - {if:fieldFail.opt_field_3_name} - -
    {else:}{end:}Field #1 name:{else:}{end:} - - {if:fieldFail.opt_field_1_name}
    {fieldFail.opt_field_1_name}{end:} -
    {else:}{end:}Field #2 name:{else:}{end:} - - {if:fieldFail.opt_field_2_name}
    {fieldFail.opt_field_2_name}{end:} -
    {else:}{end:}Field #3 name:{else:}{end:} - - {if:fieldFail.opt_field_3_name}
    {fieldFail.opt_field_3_name}{end:} -
    -
    SSL Seal for Checkout Page: -

    - NOTE: SSL Seal scripts are normally entered into this form by Gaslight Media personel.
    - Please do not modify these fields unless directed to do so. -

    -

    Note also that URLs in these entries should all be "https" (SSL).

    - - - {if:fieldRequired.ssl_seal_head_script} - {if:fieldFail.ssl_seal_head_script} - - - {if:fieldRequired.ssl_seal_body_script} - {if:fieldFail.ssl_seal_body_script} - -
    {else:}{end:}Head Script:{else:}{end:} - - {if:fieldFail.ssl_seal_head_script}
    {fieldFail.ssl_seal_head_script}{end:} -
    {else:}{end:}Body Script:{else:}{end:} - - {if:fieldFail.ssl_seal_body_script}
    {fieldFail.ssl_seal_body_script}{end:} -
    -
    {else:}{end:}Central Payment {term.prop.Cap}:{else:}{end:} - All payments are processed though this {term.prop.norm}. - {if:fieldFail.central_payment}
    {fieldFail.central_payment}{end:} -
    - NOTE: Leave blank unless you want to force all payments to be processed through one selected {term.prop.norm}. - You may create a new {term.prop.norm} for this purpose that has no {term.performance.plur} and {term.ticket.plur} associated with it - to use strictly for payment processing. -
    -
    - -
    - -
    - -
    - -
    - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('#miscConfigTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#intro_text")); - f_buildCkeditor($("#section_text")); - f_buildCkeditor($("#ticket_text")); - f_buildCkeditor($("#cart_text")); - f_buildCkeditor($("#checkout_text")); - f_buildCkeditor($("#success_text")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#intro_text")); - f_removeCkeditor($("#section_text")); - f_removeCkeditor($("#ticket_text")); - f_removeCkeditor($("#cart_text")); - f_removeCkeditor($("#checkout_text")); - f_removeCkeditor($("#success_text")); - }); - - /* - * AJAX form handling - */ - - $('#miscConfigForm').ajaxForm({ - success: function(data) { - f_replaceContents(data, $('#Misc_container')); - return false; - } - }); - - // Block default form submission - $("#miscConfigForm").submit(function (e) { - $('#miscConfigFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - f_restartOnTabSelect(); - - }); - - - diff --git a/legacy/views/admin/tickets/Misc/index.html b/legacy/views/admin/tickets/Misc/index.html deleted file mode 100755 index 9f6374c..0000000 --- a/legacy/views/admin/tickets/Misc/index.html +++ /dev/null @@ -1,47 +0,0 @@ -
    - -
    -
    Misc:
    -
    - -
    - - -{if:checkPermission(#0#)} -
    - - {if:customFeatures} - - {end:} -
    -{end:} - -
    -
    (select report tab above)
    -
    - -
    -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with Upload page loaded - f_loadAction('Misc_configDetail', 'Misc_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Misc/upload.html b/legacy/views/admin/tickets/Misc/upload.html deleted file mode 100755 index d1c47f6..0000000 --- a/legacy/views/admin/tickets/Misc/upload.html +++ /dev/null @@ -1,191 +0,0 @@ -
    - -
    - -
    - Files for customizing front-end appearance -
    - -
    - -{if:doingIndex} - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    - {end:} - {if:indexFileUploaded} -
    - * Index file uploaded successfully. - Please test to make sure your new file works correctly.
    - If not, click the "Restore Previous File" button. -
    - {end:} - {if:indexFileRestored} -
    - * Previous Index file restored. - Please test to make sure your new file works correctly.
    - If not, please try to locate a known good file to upload. -
    - {end:} -{end:} - -

    index.html: Last updated {indexTime}

    -
    - - -
    - - - - - - - - -
    Upload front-end ticket sales index file: - -
    -
    -

    - This file must include the "{GLM}" text where you would like the page - contents to be inserted. Anything else reasonable before or after that - is permitted. Please be sure to check your file to ensure that html container - tags match properly before uploading. -

    - -
    - - -
    - -
    - -
    - -
    - -{if:doingStylesheet} - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    - {end:} - {if:stylesheetFileUploaded} -
    - * Stylesheet file uploaded successfully.
    - Please test to make sure your new file works correctly. If not, click the "Restore Previous File" button. -
    - {end:} - {if:stylesheetFileRestored} -
    - * Previous Stylesheet file restored. - Please test to make sure your new file works correctly. If not, please try to locate a known good file to upload. -
    - {end:} -{end:} - -
    - -

    styles.css: Last updated {stylesTime}

    -
    - - -
    - - - - - - - - -
    Upload front-end ticket sales stylesheet: - -
    -
    - -
    - - -
    - -
    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.uploadStylesheetTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - $('.uploadIndexTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#uploadStylesheetForm').ajaxForm({ - success: function(data) { - f_replaceContents(data, $('#Misc_container')); - return false; - } - }); - - $('#uploadIndexForm').ajaxForm({ - success: function(data) { - f_replaceContents(data, $('#Misc_container')); - return false; - } - }); - - // Block default form submission - $("#uploadIndexForm").submit(function (e) { - $('#uploadIndexForm').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - $("#uploadStylesheetForm").submit(function (e) { - $('#uploadStylesheetForm').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - f_restartOnTabSelect(); - - }); - - - diff --git a/legacy/views/admin/tickets/Order/detail.html b/legacy/views/admin/tickets/Order/detail.html deleted file mode 100644 index 7058d78..0000000 --- a/legacy/views/admin/tickets/Order/detail.html +++ /dev/null @@ -1,129 +0,0 @@ -
    - -
    {orderDetail.name}
    - -
    - - -
    - - {if:orderDetail} -
    - - - - {if:orderDetail.delete} - - - - - {end:} - - - - - - - - - - - - - - - - - - - - - - - -
    Delete {term.order.cap}: - {if:orderDetail.deleteConfirmed} - {if:orderDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {orderDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.order.norm}.

    - {end:} -
    {term.order.cap} #:{orderDetail.id}
    {term.order.cap} Date:{orderDetail.purchase_date.date}
    Name:{orderDetail.lname}, {orderDetail.fname}
    Address: - {orderDetail.addr1}{if:orderDetail.addr2}
    - {orderDetail.addr2}{end:}
    - {orderDetail.city}, {orderDetail.state.name} {orderDetail.zip}
    - {orderDetail.country.name} -
    Phone:{orderDetail.phone}
    E-Mail:{orderDetail.email}
    OK to Send Info:{orderDetail.email_ok.name}
    {term.prop.cap}:{orderDetail.member_name}
    Credit Card:{orderDetail.cctype}
    Name On Card:{orderDetail.ccname}
    Card Number:{orderDetail.ccnumber}
    Confirmation #:{orderDetail.ccconf}
    Total Charge:{orderDetail.charge_total}
    Special Needs:{orderDetail.special_needs:h}
    Notes:{orderDetails.notes}
    Print {term.voucher.cap_plur} -
    - -
    -
    -
    -
    - -
    -
    -
    -
    - {else:} -

    No {term.order.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#OrderDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - // Print vouchers - $('.VoucherPrint').click(function(){ - // window.location.href = "{appAdminURL}&Action=Order_printVoucher&OrderID={orderDetail.id}"; - var voucherWindow = window.open('{appAdminURL}&Action=Order_printVoucher&OrderID={orderDetail.id}', - "voucherPrint", - "height=750,width=600,menubar=yes,toolbar=yes,alwaysRaised=yes,menu" - ); - voucherWindow.focus(); - voucherWindow.print(); - return false; - }); - - // Print Mobile vouchers - $('.VoucherPrintMobile').click(function(){ - // window.location.href = "{appAdminURL}&Action=Order_printVoucherMobile&OrderID={orderDetail.id}"; - var voucherWindow = window.open('{appAdminURL}&Action=Order_printVoucherMobile&OrderID={orderDetail.id}', - "voucherPrintMobile", - "height=750,width=600,menubar=yes,toolbar=yes,alwaysRaised=yes,menu" - ); - voucherWindow.focus(); - voucherWindow.print(); - return false; - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Order/edit.html b/legacy/views/admin/tickets/Order/edit.html deleted file mode 100755 index 8705607..0000000 --- a/legacy/views/admin/tickets/Order/edit.html +++ /dev/null @@ -1,243 +0,0 @@ -
    - -
    - {if:addingNewOrder}Adding New {term.order.cap}{end:} - {if:editingOrder}Editing {term.order.cap}{end:} -
    - -
    - -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:orderDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewOrder} - - {else:} - - {end:} - - - - - -
    - - - - - - - {if:fieldRequired.fname} - {if:fieldFail.fname} - - - {if:fieldRequired.lname} - {if:fieldFail.lname} - - - {if:fieldRequired.addr1} - {if:fieldFail.addr1} - - - {if:fieldRequired.addr2} - {if:fieldFail.addr2} - - - {if:fieldRequired.city} - {if:fieldFail.city} - - - {if:fieldRequired.state} - {if:fieldFail.state} - - - {if:fieldRequired.zip} - {if:fieldFail.zip} - - - {if:fieldRequired.country} - {if:fieldFail.country} - - - {if:fieldRequired.phone} - {if:fieldFail.phone} - - - {if:fieldRequired.email} - {if:fieldFail.email} - - - - - - - - - - - - - {if:fieldRequired.special_needs} - {if:fieldFail.special_needs} - - - {if:fieldRequired.notes} - {if:fieldFail.notes} - - -
    {term.order.cap} #:{orderDetail.id}
    {term.order.cap} Date:{orderDetail.purchase_date.date}
    {else:}{end:}First Name:{else:}{end:} -
    - {if:fieldFail.fname}
    {fieldFail.fname}{end:} -
    {else:}{end:}Last Name:{else:}{end:} -
    - {if:fieldFail.lname}
    {fieldFail.lname}{end:} -
    {else:}{end:}Address:{else:}{end:} -
    - {if:fieldFail.addr1}
    {fieldFail.addr1}{end:} -
    {else:}{end:} {else:}{end:} -
    - {if:fieldFail.addr2}
    {fieldFail.addr2}{end:} -
    {else:}{end:}City:{else:}{end:} -
    - {if:fieldFail.city}
    {fieldFail.city}{end:} -
    {else:}{end:}State:{else:}{end:} - - {if:fieldFail.state}
    {fieldFail.state}{end:} -
    {else:}{end:}ZIP/Postal Code:{else:}{end:} - - {if:fieldFail.zip}
    {fieldFail.zip}{end:} -
    {else:}{end:}Country:{else:}{end:} - - {if:fieldFail.country}
    {fieldFail.country}{end:} -
    {else:}{end:}Phone:{else:}{end:} - - {if:fieldFail.phone}
    {fieldFail.phone}{end:} -
    {else:}{end:}E-Mail Address:{else:}{end:} - - {if:fieldFail.email}

    {fieldFail.email}

    {end:} -
    OK to Send Info: - {if:orderDetail.email_ok.value} - - {else:} - - {end:} -
    Note that commercial E-Mail protocols require you to have positive confirmation from the addressee before you send them general E-mail or solicitations. -
    {term.prop.cap}:{orderDetail.member_name}
    Credit Card:{orderDetail.cctype}
    Name On Card:{orderDetail.ccname}
    Card Number:{orderDetail.ccnumber}
    Confirmation #:{orderDetail.ccconf}
    Total Charge:{orderDetail.charge_total}
    {else:}{end:}Special Needs:{else:}{end:} -
    - {if:fieldFail.special_needs}
    {fieldFail.special_needs}{end:} -
    {else:}{end:}Notes:{else:}{end:} -
    - {if:fieldFail.notes}
    {fieldFail.notes}{end:} -
    -
    - -
    - {if:addingNewOrder} - - {end:} - {if:editingOrder} - - {end:} -
    - -
    - - {else:} -

    No {term.order.norm} has been selected yet.

    -

    To edit a {term.order.norm}, first select it from the list of available {term.order.plur}. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.orderEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#orderForm').ajaxForm({ - success: function(data) { - {if:addingNewOrder} - f_replaceContents(data, $('#Order_info_container')); - {end:} - {if:editingOrder} - f_replaceContents(data, $('#Order_info_container')); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#orderFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#descr")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - f_restartOnTabSelect(); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Order/list.html b/legacy/views/admin/tickets/Order/list.html deleted file mode 100755 index 98a9f22..0000000 --- a/legacy/views/admin/tickets/Order/list.html +++ /dev/null @@ -1,132 +0,0 @@ - -
    - -
    - -
    - - Search Orders: (start typing any data in list) - - {if:orderList} - -
    - - - - - - {foreach:orderList,c} - - - - - - - - - - - {end:} - -
    Order #Order DateLast NameFirst NameCityStateE-MailPhone
    {c.purchase_date.date}{c.city}{c.state.value}{c.email}{c.phone}
    -
    - - {else:} -

    No orders listed.

    - {end:} - -
    -
    - - -
    -{startScript:h} - - // Orders Search - var ordersSearchData = [ - {foreach:orderList,c} - {label:'{c.purchase_date.date} - {c.lname:h}, {c.fname:h} - {c.city}, {c.state.value} - {c.email}, {c.phone}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var OrderListTable = $('#OrderListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { "sType": "numeric" }, - null, - null, - null, - null, - null, - null, - null - ] - }); - $(window).resize(function(){ - OrderListTable.fnDraw(); - }); - - // Toggle length of table - var OrderListTableSmall = true; - var OrderListTableHeight = $('#OrderListTable_wrapper div.dataTables_scrollBody').height(); - $('#orderListSizeChange').click(function() { - if (OrderListTableSmall) { - $('#OrderListTable_wrapper div.dataTables_scrollBody').height('auto'); - OrderListTableSmall = false; - $(this).html('Smaller Table'); - OrderListTable.fnSettings().oScroll.sY = '100%'; - OrderListTable.fnDraw(); - } else { - $('#OrderListTable_wrapper div.dataTables_scrollBody').height(OrderListTableHeight); - OrderListTableSmall = true; - $(this).html('Larger Table'); - OrderListTable.fnSettings().oScroll.sY = '100px'; - OrderListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Order_detail').hide(duration); - - $('.orderListSelect').click(function(){ - $('#OrderListTable_wrapper div.dataTables_scrollBody').height(OrderListTableHeight); - OrderListTableSmall = true; - $(this).html('Larger Table'); - OrderListTable.fnSettings().oScroll.sY = '100px'; - OrderListTable.fnDraw(); - f_loadAction('Order_selected', 'Order_detail_container', 'OrderID=' + $(this).attr('emOrderId') + '&tabList={tabList}'); - }); - - // Search Orders - $("#ordersSearch").autocomplete({ - source: ordersSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#ordersSearch").attr({value: ui.item.label}); - f_loadAction('Order_selected', 'Order_detail_container', 'OrderID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Order/selected.html b/legacy/views/admin/tickets/Order/selected.html deleted file mode 100755 index c80533b..0000000 --- a/legacy/views/admin/tickets/Order/selected.html +++ /dev/null @@ -1,45 +0,0 @@ -
    - -
    -
    Order #: {orderDetail.id}
    -
    - -
    - - -{if:checkPermission(#20#)} -
    - - -
    -{end:} - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with order detail loaded - f_loadAction('Order_detail', 'Order_info_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Performance/delete.html b/legacy/views/admin/tickets/Performance/delete.html deleted file mode 100644 index 1ed3468..0000000 --- a/legacy/views/admin/tickets/Performance/delete.html +++ /dev/null @@ -1,63 +0,0 @@ -
    - -
    Delete this {term.performance.cap}
    - -
    {performanceDetail.name}
    - -
    - - -
    - - {if:performanceDetail} -
    - - - - - - - - - - - - - - - - - - - -
    Delete {term.performace.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.performance.norm}.

    -
    Name:{performanceDetail.name}
    Active:{performanceDetail.active.name}
    Purchase by Admin Only:{performanceDetail.admin_only.name}
    Start Date:{performanceDetail.start_date.date}
    End Date:{performanceDetail.end_date.date}
    Cuttoff Date:{performanceDetail.cutoff_date.date}
    Image:{performanceDetail.image}
    Policies:{performanceDetail.policies}
    Text for {term.voucher.cap}:{performanceDetail.voucher_text:h}
    Promote in Cart:{performanceDetail.promote_in_cart.name}
    Sort Order:{performanceDetail.sort}
    - {else:} -

    No {term.performance.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#PerformanceDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Performance/detail.html b/legacy/views/admin/tickets/Performance/detail.html deleted file mode 100644 index e157b50..0000000 --- a/legacy/views/admin/tickets/Performance/detail.html +++ /dev/null @@ -1,100 +0,0 @@ -
    - -
    - {if:addingNewPerformance}Adding New {term.performance.cap}{end:} - {if:editingPerformance}Editing {term.performance.cap}{end:} -
    - - - -
    - - -
    - - {if:performanceDetail} -
    - - - - {if:performanceDetail.delete} - - - - - {end:} - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - - - - - - - - - -
    Delete {term.performance.cap}: - {if:performanceDetail.deleteConfirmed} - {if:performanceDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {performanceDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.performance.norm}.

    - {end:} -
    {term.prop.cap} Name:{performanceDetail.member_name:h}
    {term.performance.cap} Name:{performanceDetail.name:h}ID: {performanceDetail.id}
    Active:{performanceDetail.active.name}
    Purchase by Admin Only:{performanceDetail.admin_only.name}
    Description:{performanceDetail.descr:h}
    Short Description:{performanceDetail.short_descr:h}
    Start Date:{performanceDetail.start_date.date}
    End Date:{performanceDetail.end_date.date}
    Purchase Lead Time:{performanceDetail.purch_leadtime} hours
    Image: - {if:performanceDetail.image} - - {else:}(none){end:} -
    Policies:{performanceDetail.policy:h}
    Text for {term.voucher.cap}:{performanceDetail.voucher_text:h}
    Text for Confirmation E-Mail:{performanceDetail.conf_text:h}
    Promote in Cart:{performanceDetail.promote_in_cart.name}
    Sort Order:{performanceDetail.sort}
    Link to purchase: - - {frontEndSCRIPT}?Action=Shop_selection&PerformanceID={performanceDetail.id} - -
    - {else:} -

    No {term.performance.norm} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#PerformanceDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Performance/edit.html b/legacy/views/admin/tickets/Performance/edit.html deleted file mode 100644 index ccb4317..0000000 --- a/legacy/views/admin/tickets/Performance/edit.html +++ /dev/null @@ -1,314 +0,0 @@ -
    - -
    - {if:addingNewPerformance}Adding New {term.performance.cap}{end:} - {if:editingPerformance}Editing {term.performance.cap}{end:} -
    - -
    -{if:addingNewPerformance} - -{else:} - -{end:} -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:performanceDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewPerformance} - - {else:} - - {end:} - - - - - {if:checkPermission(#0#)} - {else:} - - {end:} - -
    - - - - {if:checkPermission(#0#)} - - - - - {end:} - - {if:fieldRequired.name} - {if:fieldFail.name} - - - {if:fieldRequired.descr} - {if:fieldFail.descr} - - - {if:fieldRequired.short_descr} - {if:fieldFail.short_descr} - - - - - - - - - - - {if:fieldRequired.start_date} - {if:fieldFail.start_date} - - - {if:fieldRequired.end_date} - {if:fieldFail.end_date} - - - {if:fieldRequired.purch_leadtime} - {if:fieldFail.purch_leadtime} - - - {if:fieldRequired.image} - {if:fieldFail.image} - - - {if:fieldRequired.policy} - {if:fieldFail.policy} - - - {if:fieldRequired.voucher_text} - {if:fieldFail.voucher_test} - - - {if:fieldRequired.conf_text} - {if:fieldFail.conf_text} - - {if:checkPermission(#0#)} - - - - - {else:} - - {end:} - - {if:fieldRequired.sort} - {if:fieldFail.sort} - - -
    {term.prop.Cap} Name: - {if:addingNewPerformance} - - {else:} - {performanceDetail.member_name:h} - - {end:} -
    {else:}{end:}{term.performance.cap} Name:{else:}{end:} - - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    {else:}{end:}Description:{else:}{end:} - - {if:fieldFail.descr}
    {fieldFail.descr}{end:} -
    {else:}{end:}Short Description:{else:}{end:} - - {if:fieldFail.short_descr}
    {fieldFail.short_descr}{end:} -
    Active: - {if:performanceDetail.active.value} - - {else:} - - {end:} -
    Purchase by Admin Only: - {if:performanceDetail.admin_only.value} - - {else:} - - {end:} -
    {else:}{end:}Start Date:{else:}{end:} - {if:addingNewPerformance} -
    - {else:} -
    - {end:} - This is a general start date. {term.ticket.cap} dates will determine when each {term.performance.norm} occurs. - {if:fieldFail.start_date}
    {fieldFail.start_date}{end:} -
    {else:}{end:}End Date:{else:}{end:} - {if:addingNewPerformance} -
    - {else:} -
    - {end:} - This is a general end date. {term.ticket.cap} dates will determine when each {term.performance.norm} occurs. - {if:fieldFail.end_date}
    {fieldFail.end_date}{end:} -
    {else:}{end:}Purchase Lead Time:{else:}{end:} - Hours
    - Person may not purchase {term.ticket.plur} if less than this number of hourse before the {term.performance.norm}. - {if:fieldFail.purch_leadtime}
    {fieldFail.purch_leadtime}{end:} -
    {else:}{end:}Image:{else:}{end:} - {if:performanceDetail.image} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.image}
    {fieldFail.image}{end:} -
    {else:}{end:}Policies:{else:}{end:} - - {if:fieldFail.policy}
    {fieldFail.policy}{end:} -
    {else:}{end:}Text for {term.voucher.cap}:{else:}{end:} -
    - Please be brief to conserve space on {term.voucher.plur}.
    - There is no formatting permitted for this field. - {if:fieldFail.voucher_text}
    {fieldFail.voucher_text}{end:} -
    {else:}{end:}Text for Confirmation E-Mail:{else:}{end:} - -

    This is text that will be included inside the confirmation E-Mail sent to the purchaser upon checkout. - It can be placed in the desired location by editing the checkout E-Mail for the related {term.prop.norm} - and inserting "{{term.prop.norm}-text}" at the desired location.

    -

    Note that there is one E-Mail message sent for a purchase at a particular {term.prop.norm} and that - each {term.performance.norm} that includes text in this field will contribute to the entire E-Mail. If - you add the same text to this field in multiple {term.performance.plur}, it will show up multiple times - in the confirmation E-Mail message. If there is text you would always like included, consider entering - it into the checkout E-Mail in the edit screen for the {term.prop.norm}.

    - {if:fieldFail.conf_text}
    {fieldFail.cont_text}{end:} -
    Promote in Cart: - {if:performanceDetail.promote_in_cart.value} - - {else:} - - {end:} -
    Promote in Cart:{performanceDetail.promote_in_cart.name}
    {else:}{end:}Output Order:{else:}{end:} - - {if:fieldFail.sort}
    {fieldFail.sort}{end:} -
    -
    - - -
    - {if:addingNewPerformance} - - {end:} - {if:editingPerformance} - - {end:} -
    - - -
    - - {else:} -

    No {term.performance.norm} has been selected yet.

    -

    To edit a {term.performance.norm}, first select it from the list of available {term.performance.plur}. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.performanceEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#PerformanceForm').ajaxForm({ - success: function(data) { - {if:addingNewPerformance} - f_replaceContents(data, $('#Performance_detail_container')); - {end:} - {if:editingPerformance} - f_replaceContents(data, $('#Performance_info_container')); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#performanceFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#descr")); - f_buildCkeditor($("#policy")); - f_buildCkeditor($("#conf_text")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - f_removeCkeditor($("#policy")); - f_removeCkeditor($("#conf_text")); - }); - - /* - * Date input operations - */ - - // Code to start datepicker for each date input - $("#startDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{performanceDetail.start_date.date_list.min}', - maxDate: '{performanceDetail.start_date.date_list.max}' - }); - $("#endDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{performanceDetail.end_date.date_list.min}', - maxDate: '{performanceDetail.end_date.date_list.max}' - }); - $("#cutoffDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{performanceDetail.cutoff_date.date_list.min}', - maxDate: '{performanceDetail.cutoff_date.date_list.max}' - }); - - f_restartOnTabSelect(); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Performance/list.html b/legacy/views/admin/tickets/Performance/list.html deleted file mode 100644 index 4984341..0000000 --- a/legacy/views/admin/tickets/Performance/list.html +++ /dev/null @@ -1,144 +0,0 @@ - -
    - -
    - - -
    - - Search {term.performance.plur_cap}: (type any portion of a {term.performance.norm} name) - - {if:performanceList} - -
    - - - - - - {foreach:performanceList,c} - - - - - - - - - {end:} - -
    Sort OrderNameActiveAdmin Only{term.prop.cap}Promote in Cart
    {c.sort}{c.promote_in_cart.name}
    -
    - - {else:} -

    No {term.performance.plur} listed.

    -

    - You need to have at least one {term.performance.norm} in order to sell {term.ticket.plur}. - If you have a {term.prop.norm} that sells {term.ticket.plur} through other {term.prop.plur}, - then that {term.prop.norm} will need at least one {term.performance.norm}. If you're doing that, - the {term.prop.norm} that will be selling those {term.ticket.plur} does not need a - {term.performance.norm} unless it will be selling its own. -

    - {end:} - -
    - -
    - -
    -{startScript:h} - - // Performances Search - var performancesSearchData = [ - {foreach:performanceList,c} - {label:'{c.name:h}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var PerformanceListTable = $('#PerformanceListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '80px', "sType": "numeric" }, - null, - null, - null, - null, - null - ] - }); - - $(window).resize(function(){ - PerformanceListTable.fnDraw(); - }); - - // Toggle length of table - var PerformanceListTableSmall = true; - var PerformanceListTableHeight = $('#PerformanceListTable_wrapper div.dataTables_scrollBody').height(); - $('#PerformanceListSizeChange').click(function() { - if (PerformanceListTableSmall) { - $('#PerformanceListTable_wrapper div.dataTables_scrollBody').height('auto'); - PerformanceListTableSmall = false; - $(this).html('Smaller Table'); - PerformanceListTable.fnSettings().oScroll.sY = '100%'; - PerformanceListTable.fnDraw(); - } else { - $('#PerformanceListTable_wrapper div.dataTables_scrollBody').height(PerformanceListTableHeight); - PerformanceListTableSmall = true; - $(this).html('Larger Table'); - PerformanceListTable.fnSettings().oScroll.sY = '100px'; - PerformanceListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Performance_detail_container').hide(duration); - - $('.performanceListSelect').click(function(){ - $('#PerformanceListTable_wrapper div.dataTables_scrollBody').height(PerformanceListTableHeight); - PerformanceListTableSmall = true; - $('#PerformanceListSizeChange').html('Larger Table'); - PerformanceListTable.fnSettings().oScroll.sY = '100px'; - PerformanceListTable.fnDraw(); - f_loadAction('Performance_selected', 'Performance_detail_container', 'PerformanceID=' + $(this).attr('emPerformanceId') + '&tabList={tabList}'); - $('#Performance_info').removeClass('emContentAreaHidden'); - }); - - // Search Performances - $("#performancesSearch").autocomplete({ - source: performancesSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#performancesSearch").attr({value: ui.item.label}); - f_loadAction('Performance_selected', 'Performance_detail_container', 'PerformanceID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - {if:displayPerformance} - f_loadAction('Performance_selected', 'Performance_detail_container', 'PerformanceID=' + {displayPerformance} + '&tabList={tabList}'); - {end:} - - }); - - diff --git a/legacy/views/admin/tickets/Performance/redisplayList.html b/legacy/views/admin/tickets/Performance/redisplayList.html deleted file mode 100755 index b77cfda..0000000 --- a/legacy/views/admin/tickets/Performance/redisplayList.html +++ /dev/null @@ -1,18 +0,0 @@ -
    - Reloading... -
    - - - - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Performance/selected.html b/legacy/views/admin/tickets/Performance/selected.html deleted file mode 100755 index 24fa389..0000000 --- a/legacy/views/admin/tickets/Performance/selected.html +++ /dev/null @@ -1,53 +0,0 @@ -
    - -
    -
    {term.performance.cap}: {performanceDetail.name:h}
    -
    - -
    - - -{if:checkPermission(#20#)} -
    - - {if:checkPermission(#0#)} - - {end:} - - -
    -{end:} - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with performance detail loaded - f_loadAction('Performance_detail', 'Performance_info_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Performance/summary.html b/legacy/views/admin/tickets/Performance/summary.html deleted file mode 100755 index fd64808..0000000 --- a/legacy/views/admin/tickets/Performance/summary.html +++ /dev/null @@ -1,84 +0,0 @@ - -
    - - {if:performanceSummary} - -
    - - - - - - - - - - - - - - {foreach:performanceSummary,a} - {if:a.active} - - {else:} - - {end:} - - - - - - - - - {end:} - -
    DateTimeSectionTicketQuantSoldAvailable
    {a.date}{a.time}{a.section}{a.name} - {if:a.active} - {else:} - (inactive) - {end:} - {if:a.unlimited_quant}(unlim){else:}{a.quant}{end:}{a.sold}{if:a.unlimited_quant}(unlim){else:}{a.avail}{end:}
    -
    - -

    Grayed-out entries are currently set to inactive.

    - - {else:} -

    No {term.performance.plur} listed.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var PerformanceSummaryTable = $('#PerformanceSummaryTable').dataTable({ -// "sScrollY": "500px", - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '120px' }, - null, - null, - null, - null, - null, - null - ] - }); - $(window).resize(function(){ - PerformanceSummaryTable.fnDraw(); - }); - - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Promo/delete.html b/legacy/views/admin/tickets/Promo/delete.html deleted file mode 100755 index 6bd1061..0000000 --- a/legacy/views/admin/tickets/Promo/delete.html +++ /dev/null @@ -1,57 +0,0 @@ -
    - -
    Delete this {term.promo.cap}
    - -
    {PromoDetail.name}
    - -
    - - -
    - - {if:promoDetail} -
    - - - - - - - - - - - - - -
    Delete {term.promo.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.ticket.norm} add-on.

    -
    {term.promo.cap}:{promoDetail.name}ID: {promoDetail.id}
    Description:{promoDetail.descr:h}
    Start Date:{promoDetail.start_date.date}
    End Date:{promoDetail.end_date.date}
    Notes:{promoDetail.notes:h}
    - {else:} -

    No {term.promo.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#PromoDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Promo/detail.html b/legacy/views/admin/tickets/Promo/detail.html deleted file mode 100644 index 4d1ed29..0000000 --- a/legacy/views/admin/tickets/Promo/detail.html +++ /dev/null @@ -1,168 +0,0 @@ -
    - - - -
    - - -
    - - {if:promoDetail} -
    - - - - {if:promoDetail.delete} - - - - - {end:} - - - - - - - -
    Delete {term.promo.cap}: - {if:promoDetail.deleteConfirmed} - {if:promoDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {promoDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.promo.norm}.

    - {end:} -
    {term.promo.cap}:{promoDetail.name}ID: {promoDetail.id}
    {term.promo.cap} Long Name:{promoDetail.long_name:h}
    Description:{promoDetail.descr:h}
    Start Date:{promoDetail.start_date.date}
    End Date:{promoDetail.end_date.date}
    Notes:{promoDetail.notes:h}
    -
    - - - -
    {term.promo.cap} {term.ticket.plur_cap} -
    - -
    - - - - - - - {foreach:promoTicketsList,p} - - - - - - - - - - {end:} - - - - - - - - - - - - - - - - - - - - -
    Delete{term.ticket.cap} NameType$ or %# Sold$ CreditNotes
    {p.ticket_name}{p.promo_type.name}{p.numberSold}{p.dollarsSold}
    - - - - - -   
       Totals{numberTotal}{dollarsTotal} 
    - -
    - {else:} -

    No {term.promo.plur} found.

    - {end:} - - -
    -{startScript:h} - $(document).ready(function(){ - - $('#PromoDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - $('#PromoTicketTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '40px', "sType": "numeric" }, - null, - null, - null, - null, - null, - null - ] - }); - - f_restartOnTabSelect(); - - /* - * AJAX form handling - */ - - $('#promoTicketForm').ajaxForm({ - success: function(data) { - var container = $('#Promo_detail_container'); - f_replaceContents(data, container); - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('.promoTicketFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - - }); - diff --git a/legacy/views/admin/tickets/Promo/edit.html b/legacy/views/admin/tickets/Promo/edit.html deleted file mode 100755 index 614125b..0000000 --- a/legacy/views/admin/tickets/Promo/edit.html +++ /dev/null @@ -1,207 +0,0 @@ -
    - -
    - {if:addingNewPromo}Adding New {term.promo.cap}{end:} - {if:editingPromo}Editing {term.promo.cap}{end:} -
    - -
    -{if:addingNewPromo} - -{else:} - -{end:} -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:promoDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewPromo} - - {else:} - - {end:} - - - - - -
    - - - - - {if:fieldRequired.name} - {if:fieldFail.name} - - - {if:fieldRequired.long_name} - {if:fieldFail.long_name} - - - {if:fieldRequired.descr} - {if:fieldFail.descr} - - - {if:fieldRequired.start_date} - {if:fieldFail.start_date} - - - {if:fieldRequired.end_date} - {if:fieldFail.end_date} - - -
    {else:}{end:}{term.promo.cap}:{else:}{end:} -
    - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    {else:}{end:}{term.promo.cap} Long Name:{else:}{end:} -
    - For internal reference. - {if:fieldFail.long_name}
    {fieldFail.long_name}{end:} -
    {else:}{end:}Description:{else:}{end:} - - {if:fieldFail.descr}
    {fieldFail.descr}{end:} -
    {else:}{end:}Start Date:{else:}{end:} - {if:addingNewPromo} - - {else:} - - {end:} - {if:fieldFail.start_date}
    {fieldFail.start_date}{end:} -
    {else:}{end:}End Date:{else:}{end:} - {if:addingNewPromo} - - {else:} - - {end:} - {if:fieldFail.end_date}
    {fieldFail.end_date}{end:} -
    -
    - -
    - {if:addingNewPromo} - - {end:} - {if:editingPromo} - - {end:} -
    - -
    - - {else:} -

    No {term.ticket.norm} add-on has been selected yet.

    -

    To edit a {term.ticket.norm} add-on, first select it from the list of available {term.ticket.plur} add-ons. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.promoEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#promoForm').ajaxForm({ - success: function(data) { - {if:addingNewPromo} - var container = $('#Promo_detail_container'); - f_replaceContents(data, container); - {end:} - {if:editingPromo} - var container = $('#Promo_detail_container'); - f_replaceContents(data, container); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#promoFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#descr")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - f_restartOnTabSelect(); - - function promoTypeCheck(e) { - typeval = $('#promoType').val(); - - // If this is a quantity selection - if (typeval == 2) { - $('#max_quant').show(); - } else { - $('#max_quant').hide(); - } - } - - $('#promoType').change( function() { - promoTypeCheck(); - }); - promoTypeCheck(); - - /* - * Date input operations - */ - - // Code to start datepicker for each date input - $("#startDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{performanceDetail.start_date.date_list.min}', - maxDate: '{performanceDetail.start_date.date_list.max}' - }); - $("#endDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{performanceDetail.start_date.date_list.min}', - maxDate: '{performanceDetail.start_date.date_list.max}' - }); - - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Promo/list.html b/legacy/views/admin/tickets/Promo/list.html deleted file mode 100644 index c7de28a..0000000 --- a/legacy/views/admin/tickets/Promo/list.html +++ /dev/null @@ -1,124 +0,0 @@ - -
    - -
    -
    -{if:checkPermission(#10#)} - -{end:} - -
    - Search {term.promo.plur_cap}: (start typing any information in list) - - {if:promos} - -
    - - - - - - {foreach:promos,c} - - - - - - - {end:} - -
    {term.promo.cap}Long NameStart DateEnd Date
    -
    - - {else:} -

    No {term.promo.plur}.

    - {end:} - -
    -
    - -
    - -
    -{startScript:h} - - // Promotions Search - var promosSearchData = [ - {foreach:promos,c} - {label:'{c.name:h}, {c.long_name:h}, {c.start_date.date}, {c.end_date.date}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var PromoListTable = $('#PromoListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - }); - $(window).resize(function(){ - PromoListTable.fnDraw(); - }); - - // Toggle length of table - var PromoListTableSmall = true; - var PromoListTableHeight = $('#PromoListTable_wrapper div.dataTables_scrollBody').height(); - $('#promoListSizeChange').click(function() { - if (PromoListTableSmall) { - $('#PromoListTable_wrapper div.dataTables_scrollBody').height('auto'); - PromoListTableSmall = false; - $(this).html('Smaller Table'); - PromoListTable.fnSettings().oScroll.sY = '100%'; - PromoListTable.fnDraw(); - } else { - $('#PromoListTable_wrapper div.dataTables_scrollBody').height(PromoListTableHeight); - PromoListTableSmall = true; - $(this).html('Larger Table'); - PromoListTable.fnSettings().oScroll.sY = '100px'; - PromoListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Promo_detail').hide(duration); - - $('.promoListSelect').click(function(){ - $('#PromoListTable_wrapper div.dataTables_scrollBody').height(PromoListTableHeight); - PromoListTableSmall = true; - $('#promoListSizeChange').html('Larger Table'); - PromoListTable.fnSettings().oScroll.sY = '100px'; - PromoListTable.fnDraw(); - f_loadAction('Promo_selected', 'Promo_detail_container', 'PromoID=' + $(this).attr('emPromoId') + '&tabList={tabList}'); - }); - - // Search Promotions - $("#promosSearch").autocomplete({ - source: promosSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#promosSearch").attr({value: ui.item.label}); - f_loadAction('Promo_selected', 'Promo_detail_container', 'PromoID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Promo/selected.html b/legacy/views/admin/tickets/Promo/selected.html deleted file mode 100755 index e6b9c45..0000000 --- a/legacy/views/admin/tickets/Promo/selected.html +++ /dev/null @@ -1,32 +0,0 @@ -
    - -
    -
    {term.promo.cap}: {promoDetail.name}
    -
    - -
    - - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with ticket detail loaded - f_loadAction('Promo_detail', 'Promo_detail_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Report/error.html b/legacy/views/admin/tickets/Report/error.html deleted file mode 100755 index d8b3ff6..0000000 --- a/legacy/views/admin/tickets/Report/error.html +++ /dev/null @@ -1,14 +0,0 @@ - - -
    - - Promo Detail Report - Report Produced: {reportDate} {reportTime} -
    -
    {reportNote}
    - -

    There was a error with your request:

    -
    {errorMsg:h}
    -

     

    - -
    diff --git a/legacy/views/admin/tickets/Report/index.html b/legacy/views/admin/tickets/Report/index.html deleted file mode 100644 index 4cf9164..0000000 --- a/legacy/views/admin/tickets/Report/index.html +++ /dev/null @@ -1,53 +0,0 @@ -
    - -
    -
    Reports:
    -
    - -
    - - -{if:checkPermission(#20#)} -
    - - - - -
    -{end:} - -
    -
    (select report tab above)
    -
    - -
    -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with Ticket Sales report form loaded - f_loadAction('Report_orders', 'Report_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Report/member.html b/legacy/views/admin/tickets/Report/member.html deleted file mode 100755 index c1f5579..0000000 --- a/legacy/views/admin/tickets/Report/member.html +++ /dev/null @@ -1,119 +0,0 @@ - - -{if:printOutput} - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - -{end:} - - - -
    - - {term.prop.cap} Report - {reportDate} {reportTime} -
    - {reportNote} - - {if:membersList} - -
    - - - - - - - - - - - - - - - {foreach:membersList,m} - {if:m.active.value} - - {else:} - - {end:} - - - - - - - - - - {end:} - - - - - - - - - - - - -
    {term.prop.cap} NameActive{term.section.plur_cap}{term.performance.plur_cap}{term.ticket.plur_cap}Inventory# Sold$ Sold
    {m.name}{m.active.name}{m.sectionStats}{m.performanceStats}{m.ticketStats}{m.ticketSalesStats.totalquant}{m.ticketSalesStats.totalsold}{m.ticketSalesStats.totalMoney}
     Totals:{totals.sections}{totals.events}{totals.tickets}{totals.inventory}{totals.sold}{totals.price}
    -
    - - {else:} -

    No results found.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var MemberReportTable = $('#MemberReportTable').dataTable({ - "sScrollX": "100%", - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false - }); - $(window).resize(function(){ - MemberReportTable.fnDraw(); - }); - - - f_restartOnTabSelect(); - - }); - - - - -{if:printOutput} - - -{end:} diff --git a/legacy/views/admin/tickets/Report/memberCSV.html b/legacy/views/admin/tickets/Report/memberCSV.html deleted file mode 100755 index 9597bf5..0000000 --- a/legacy/views/admin/tickets/Report/memberCSV.html +++ /dev/null @@ -1,9 +0,0 @@ -"{term.prop.cap} Report","{reportDate}","{reportTime}","{reportNote}" - -{if:membersList}"{term.prop.cap} Name","Active","{term.section.plur_cap}","{term.performance.plur_cap}","{term.ticket.plur_cap}","Inventory","# Sold","$ Sold" -{foreach:membersList,m}"{m.name}","{m.active.name}","{m.sectionStats}","{m.performanceStats}","{m.ticketStats}","{m.ticketSalesStats.totalquant}","{m.ticketSalesStats.totalsold}","{m.ticketSalesStats.totalMoney}" -{end:} -"","Totals:","{totals.sections}","{totals.events}","{totals.tickets}","{totals.inventory}","{totals.sold}","{totals.price}" -{else:} -No results found." -{end:} diff --git a/legacy/views/admin/tickets/Report/memberReportSelection.html b/legacy/views/admin/tickets/Report/memberReportSelection.html deleted file mode 100755 index 076fd7c..0000000 --- a/legacy/views/admin/tickets/Report/memberReportSelection.html +++ /dev/null @@ -1,187 +0,0 @@ -
    - -
    - {term.prop.cap} Report Selection -
    - -
    - -
    - - -
    - - - - - - - - - - - - - - - - - - - - -
    {term.prop.cap}: - -
    Show inactive {term.prop.plur_cap}
    Date Range for Sales Data: - - -    - From:    - Through:    - -
    Output Type: - -
    -
    - -
    - -
    - -
    - -
    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.memberReportTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '10%' }, - null - ] - }); - - /* - * AJAX form handling - */ - - $('#memberReportForm').ajaxForm({ - beforeSubmit: function(xhr) { - - // Check if this is going to be a csv - var outputType = $('#outputType').val(); - if (outputType == 'csv') { - - // Since this is a csv, open a new window with the desired URL and parameters rather than an ajax submit. - var url = appAdminURL + '&' + $('#memberReportForm').formSerialize(); - window.open(url, 'csvReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=no,width=100, height=10'); - return false; - } - }, - success: function(data) { - - var outputType = $('#outputType').val(); - - if (outputType == 'print') { - var w = window.open('', 'printReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=yes,width=1000, height=700, left=100, top=25'); - $(w.document.body).html(data); - } else { - f_replaceContents(data, $('#report_result_container')); - } - - return false; - } - }); - - // Block default form submission - $("#memberReportForm").submit(function (e) { - - var outputType = $('#outputType').val(); - - if (outputType == 'html') { - $('#report_result_container').html('
    Submitting, Please Wait...
    '); - } - - e.preventDefault(); - }); - - // Code to start datepicker for each date input - $("#startDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [100,200]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - $("#endDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [200,300]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - - // Check if to hide dates - $('#dateRange').on('change', null, function() { - var dateRange = $(this).val(); - if (dateRange == 'specified') { - $('#dateFields').removeClass('emContentAreaHidden'); - } else { - $('#dateFields').addClass('emContentAreaHidden'); - } - }); - - f_restartOnTabSelect(); - - }); - - - diff --git a/legacy/views/admin/tickets/Report/orders.html b/legacy/views/admin/tickets/Report/orders.html deleted file mode 100644 index e88eb94..0000000 --- a/legacy/views/admin/tickets/Report/orders.html +++ /dev/null @@ -1,169 +0,0 @@ - - -{if:printOutput} - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - -{end:} - - - -
    - - Orders Report - {reportDate} {reportTime} -
    - - {reportNote} - - {if:ordersList} - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {foreach:ordersList,r} - - - - - - - - - - - - - - - - - - - - - - - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - -
    Order #Purch DateLast NameFirst NameAddressAddressCityStateZIPCountryPhoneE-MailContact OK{term.prop.cap}Credit CardCard NumberExpirationName on CardConfirmationCharge Amount
    {r.id}{r.purchase_date.date}{r.lname}{r.fname}{r.addr1}{r.addr2}{r.city}{r.state.name}{r.zip}{r.country.name}{r.phone}{r.email}{r.email_ok.name}{r.member_name}{r.cctype}{r.ccnumber}{r.expire}{r.ccname}{r.ccconf}{r.charge_total}
              Number of Orders: {numbOrders}Average Order: {averageOrder}       Total: {totalChargesMoney}
    -
    -
    - - {else:} -

    No results found.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var OrdersReportTable = $('#OrdersReportTable').dataTable({ - "sScrollY": "600px", - "sScrollX": "100%", - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "columnDefs": [ - { - "targets": [ 4, 5, 12, 13, 14, 15, 16, 17, 18 ], - "visible": false - } - ] - }); - - $(window).resize(function(){ - OrdersReportTable.fnDraw(); - }); - - $('.orderSelect').click( function (event) { - var orderID = $(this).attr('data-id'); - f_loadAction('Sold_claim', 'Main_container', 'orderID=' + orderID); - return false; - }); - - f_restartOnTabSelect(); - - }); - - - - -{if:printOutput} - - -{end:} diff --git a/legacy/views/admin/tickets/Report/ordersCSV.html b/legacy/views/admin/tickets/Report/ordersCSV.html deleted file mode 100755 index 003d9bc..0000000 --- a/legacy/views/admin/tickets/Report/ordersCSV.html +++ /dev/null @@ -1,9 +0,0 @@ -"Orders Report","{reportDate}","{reportTime}","{reportNote}" - -{if:ordersList}"ID","Purch Date","Last Name","First Name","Address","Address","City","State","ZIP","Country","Phone","E-Mail","Contact OK","{term.prop.cap}","Credit Card","Card Number","Expiration","Name on Card","Confirmation","Charge Amount" -{foreach:ordersList,r}"{r.id}","{r.purchase_date.date}","{r.lname}","{r.fname}","{r.addr1}","{r.addr2}","{r.city}","{r.state.name}","{r.zip}","{r.country.name}","{r.phone}","{r.email}","{r.email_ok.name}","{r.member_name}","{r.cctype}","{r.ccnumber}","{r.expire}","{r.ccname}","{r.ccconf}","{r.charge_numb}" -{end:} -"","","","","","","","","","","","Number of Orders:","{numbOrders}","","","","","","Total:","{totalCharges}" -{else:} -No results found. -{end:} diff --git a/legacy/views/admin/tickets/Report/ordersReportSelection.html b/legacy/views/admin/tickets/Report/ordersReportSelection.html deleted file mode 100644 index d0d9a42..0000000 --- a/legacy/views/admin/tickets/Report/ordersReportSelection.html +++ /dev/null @@ -1,309 +0,0 @@ -
    - -
    - {term.ticket.cap} Orders Report Selection -
    - -
    - -
    - - -{if:!checkPermission(#0#)} - -{end:} -
    - - - - - - -{if:checkPermission(#0#)} - - - - {end:} -{end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Order #: - - {term.prop.cap}: - -{else:} - {if:users_access_all_members} - {term.prop.cap}: - - {else:} -   
    Last Name: - - Show inactive {term.prop.plur_cap}
    First Name: - - Purchase Date Range: - - -    - From:    - Through:    -
    - Enter only "From:" date to display orders for a single date. -
    -
    -
    City: - - Ticket Date or Likely Date: - - -    - From:    - Through:    - -
    State (2 letter code): - - OK to send E-Mail: - - Show only orders where customer indicated
    it was OK to sent them general E-Mail. -
    ZIP/Postal Code: - - Sort By: - -
    Phone #: - - Output Type: - -
    -
    - -
    - -
    - -
    - -
    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.ordersReportTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '25%' }, - { sWidth: '25%' }, - { sWidth: '25%' }, - { sWidth: '25%' } - ] - }); - - /* - * AJAX form handling - */ - - $('#ordersReportForm').ajaxForm({ - beforeSubmit: function(xhr) { - - // Check if this is going to be a csv - var outputType = $('#outputType').val(); - if (outputType == 'csv') { - - // Since this is a csv, open a new window with the desired URL and parameters rather than an ajax submit. - var url = appAdminURL + '&' + $('#ordersReportForm').formSerialize(); - window.open(url, 'csvReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=no,width=100, height=10'); - return false; - } - }, - success: function(data) { - - var outputType = $('#outputType').val(); - - if (outputType == 'print') { - var w = window.open('', 'printReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=yes,width=1000, height=700, left=100, top=25'); - $(w.document.body).html(data); - } else { - f_replaceContents(data, $('#report_result_container')); - } - - return false; - } - }); - - // Block default form submission - $("#ordersReportForm").submit(function (e) { - - var outputType = $('#outputType').val(); - - if (outputType == 'html') { - $('#report_result_container').html('
    Submitting, Please Wait...
    '); - } - - e.preventDefault(); - }); - - - var currentMousePos = { x: -1, y: -1 }; - $(document).mousemove(function(event) { - currentMousePos.x = event.pageX; - currentMousePos.y = event.pageY; - }); - - // Code to start datepicker for each date input - $("#startDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [100,200]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - $("#endDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [200,300]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - $("#ticketStartDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [100,200]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - $("#ticketEndDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [200,300]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - - // Check if to hide dates - $('#dateType').on('change', null, function() { - var dateType = $(this).val(); - if (dateType == 'all') { - $('#dateFields').addClass('emContentAreaHidden'); - } else { - $('#dateFields').removeClass('emContentAreaHidden'); - } - }); - $('#ticketDateType').on('change', null, function() { - var dateType = $(this).val(); - if (dateType == 'all') { - $('#ticketDateFields').addClass('emContentAreaHidden'); - } else { - $('#ticketDateFields').removeClass('emContentAreaHidden'); - } - }); - - f_restartOnTabSelect(); - - - }); - - - diff --git a/legacy/views/admin/tickets/Report/promoCSV.html b/legacy/views/admin/tickets/Report/promoCSV.html deleted file mode 100755 index 6909e23..0000000 --- a/legacy/views/admin/tickets/Report/promoCSV.html +++ /dev/null @@ -1,10 +0,0 @@ -"Sales Report","Report Produced: {reportDate}","{reportTime}","{reportNote}" - -{if:salesList}{if:checkPermission(#0#)}"{term.prop.cap}",{end:}"{term.performance.cap}","{term.section.cap}","{term.ticket.cap}","Add On","Add On Sold","Date","Time","Quantity","Sold","Claimed","Promo","Paid" -{foreach:salesList,r}{if:checkPermission(#0#)}"{r.memb_name}",{end:}"{r.perf_name}","{r.sect_name}","{r.tick_name}","{r.addon_name}","{r.addon_sold}","{r.date_date}","{r.time_time}","{r.time_quant}","{r.time_sold}","{r.time_claimed}","{r.time_promo}","{r.time_price}" -{end:} -"Grand Totals",{if:checkPermission(#0#)}"",{end:}"","","","","","","{totalQuant}","{totalSold}","{totalClaimed}","{totalPromos}","{totalPrice}" -"",{if:checkPermission(#0#)},""{end:},"","","","","","","","","{percentClaimed}%" -{else:} -No results found. -{end:} diff --git a/legacy/views/admin/tickets/Report/promoDetail.html b/legacy/views/admin/tickets/Report/promoDetail.html deleted file mode 100644 index c6d5293..0000000 --- a/legacy/views/admin/tickets/Report/promoDetail.html +++ /dev/null @@ -1,221 +0,0 @@ - - -{if:printOutput} - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - -{end:} - - - -
    - - Promo Detail Report - Report Produced: {reportDate} {reportTime} -
    -
    {reportNote}
    - - {if:promoList} - -
    - - - - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - {foreach:promoList,r} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - - - - - - - - - {end:} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - -
    {term.prop.cap}{term.performance.cap}{term.section.cap}{term.ticket.cap}Add OnAdd On
    Sold
    DateTimeQuantitySoldClaimedPromoPaidOrder ID{term.voucher.cap}First NameLast NameAddressAddress 2CityStateZIP/PostalCountryPhone #
    {r.memb_name}{r.perf_name}{r.sect_name}{r.tick_name}{r.addon_name}{r.addon_sold}{r.date_date}{r.time_time}{r.time_quant}{r.time_sold}{r.time_claimed}{r.time_promo_money}{r.time_money}{r.order_id}{r.order_voucher_id}{r.order_fname:h}{r.order_lname:h}{r.order_addr1:h}{r.order_addr2:h}{r.order_city:h}{r.order_state:h}{r.order_zip}{r.order_country}{r.order_phone}
                            
    Grand Totals       {totalQuant}{totalSold}{totalClaimed}{totalPromosMoney}{totalMoney}           
             {percentSold}%{percentClaimed}%             
    -
    -
    - - {else:} -

    No results found.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var PromoReportTable = $('#PromoReportTable').dataTable({ - "sScrollY": "600px", - "sScrollX": "100%", - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false - }); - $(window).resize(function(){ - PromoReportTable.fnDraw(); - }); - - - f_restartOnTabSelect(); - - }); - - - - -{if:printOutput} - - -{end:} diff --git a/legacy/views/admin/tickets/Report/promoReportSelection.html b/legacy/views/admin/tickets/Report/promoReportSelection.html deleted file mode 100644 index c19969a..0000000 --- a/legacy/views/admin/tickets/Report/promoReportSelection.html +++ /dev/null @@ -1,220 +0,0 @@ -
    - -
    - Promo Codes Report Selection -
    - -
    - -
    - - -{if:!checkPermission(#0#)} - -{end:} -
    - - - -{if:checkPermission(#0#)} - - - - - - - - -{end:} - - - - - - - - - -
    Type of Report: - -
    Promo Code: - -
    Date Range: - - -    - From:    - Through:    - -
    Output Type: - -
    -
    - -
    - -
    - -
    - -
    - -
    - - -
    - -{startScript:h} - - var mList = new Array(); - {foreach:mList,m} - mList[{m.id}] = ''; - {end:} - - $(function() { - - /* - * Table operations - */ - - $('.promoReportTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '10%' }, - null - ] - }); - - /* - * AJAX form handling - */ - - $('#promoReportForm').ajaxForm({ - beforeSubmit: function(xhr) { - - // Check if this is going to be a csv - var outputType = $('#outputType').val(); - if (outputType == 'csv') { - - // Since this is a csv, open a new window with the desired URL and parameters rather than an ajax submit. - var url = appAdminURL + '&' + $('#promoReportForm').formSerialize(); - window.open(url, 'csvReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=no,width=100, height=10'); - return false; - } - }, - success: function(data) { - - var outputType = $('#outputType').val(); - - if (outputType == 'print') { - var w = window.open('', 'printReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=yes,width=1000, height=700, left=100, top=25'); - $(w.document.body).html(data); - } else { - f_replaceContents(data, $('#report_result_container')); - } - - return false; - } - }); - - // Block default form submission - $("#promoReportForm").submit(function (e) { - - var outputType = $('#outputType').val(); - - if (outputType == 'html') { - $('#report_result_container').html('
    Submitting, Please Wait...
    '); - } - - e.preventDefault(); - }); - - - var currentMousePos = { x: -1, y: -1 }; - $(document).mousemove(function(event) { - currentMousePos.x = event.pageX; - currentMousePos.y = event.pageY; - }); - - // Code to start datepicker for each date input - $("#startDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [100,200]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - $("#endDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [200,300]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - - // Check if to hide dates - $('#dateType').on('change', null, function() { - var dateType = $(this).val(); - if (dateType == 'all') { - $('#dateFields').addClass('emContentAreaHidden'); - } else { - $('#dateFields').removeClass('emContentAreaHidden'); - } - }); - - // Selection of performance list - $('#memberID').on('change', null, function() { - var memberID = $(this).val(); - $('#performanceSelect').html(mList[memberID]); - }); - - f_restartOnTabSelect(); - -{if:!checkPermission(#0#)} - // This must be a member used so start with their performances loaded - $('#performanceSelect').html(mList[{userMemberID}]); -{end:} - - - - - }); - - - diff --git a/legacy/views/admin/tickets/Report/promoSummary.html b/legacy/views/admin/tickets/Report/promoSummary.html deleted file mode 100644 index 2300fc4..0000000 --- a/legacy/views/admin/tickets/Report/promoSummary.html +++ /dev/null @@ -1,129 +0,0 @@ - - -{if:printOutput} - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - -{end:} - - -
    - - Promo Summary Report - Report Produced: {reportDate} {reportTime} -
    -
    {reportNote}
    - - {if:havePromoList} - -
    - -
    - - - - - - - - - - - - - - - - - {foreach:promoList,p} - - - - - - - - - - - - - {end:} - - - - - - - - - - - - - -
    CodePromo{term.performance.cap}{term.ticket.cap}NameDate# SoldPer TicketDiscount
    {p.promo_name}{p.long_name}{p.performance_name}{p.ticket_name}{p.fname} {p.lname}{p.purchase_date}{p.count}{p.amountMoney}{p.sumMoney}
    Grand Totals     {totalCount} {totalDiscount}
    -
    -
    -
    - - {else:} -

    No results found.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var PromoReportTable = $('#PromoReportTable').dataTable({ - "sScrollY": "600px", - "sScrollX": "100%", - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false - }); - $(window).resize(function(){ - PromoReportTable.fnDraw(); - }); - - - f_restartOnTabSelect(); - - }); - - - - -{if:printOutput} - - -{end:} diff --git a/legacy/views/admin/tickets/Report/sales.html b/legacy/views/admin/tickets/Report/sales.html deleted file mode 100644 index a50a573..0000000 --- a/legacy/views/admin/tickets/Report/sales.html +++ /dev/null @@ -1,171 +0,0 @@ - - -{if:printOutput} - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - -{end:} - - - -
    - - Sales Report - Report Produced: {reportDate} {reportTime} -
    -
    {reportNote}
    - - {if:salesList} - -
    - - - - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - {foreach:salesList,r} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - {end:} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - -
    {term.prop.cap}{term.performance.cap}{term.section.cap}{term.ticket.cap}Add OnAdd On
    Sold
    DateTimeQuantitySoldClaimedPromoPaid
    {r.memb_name}{r.perf_name}{r.sect_name}{r.tick_name}{r.addon_name}{r.addon_sold}{r.date_date}{r.time_time}{r.time_quant}{r.time_sold}{r.time_claimed}{r.time_promo_money}{r.time_money}
                 
    Grand Totals       {totalQuant}{totalSold}{totalClaimed}{totalPromosMoney}{totalMoney}
             {percentSold}%{percentClaimed}%  
    -
    -
    - - {else:} -

    No results found.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var SalesReportTable = $('#SalesReportTable').dataTable({ - "sScrollY": "600px", - "sScrollX": "100%", - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false - }); - $(window).resize(function(){ - SalesReportTable.fnDraw(); - }); - - - f_restartOnTabSelect(); - - }); - - - - -{if:printOutput} - - -{end:} diff --git a/legacy/views/admin/tickets/Report/salesCSV.html b/legacy/views/admin/tickets/Report/salesCSV.html deleted file mode 100755 index 6909e23..0000000 --- a/legacy/views/admin/tickets/Report/salesCSV.html +++ /dev/null @@ -1,10 +0,0 @@ -"Sales Report","Report Produced: {reportDate}","{reportTime}","{reportNote}" - -{if:salesList}{if:checkPermission(#0#)}"{term.prop.cap}",{end:}"{term.performance.cap}","{term.section.cap}","{term.ticket.cap}","Add On","Add On Sold","Date","Time","Quantity","Sold","Claimed","Promo","Paid" -{foreach:salesList,r}{if:checkPermission(#0#)}"{r.memb_name}",{end:}"{r.perf_name}","{r.sect_name}","{r.tick_name}","{r.addon_name}","{r.addon_sold}","{r.date_date}","{r.time_time}","{r.time_quant}","{r.time_sold}","{r.time_claimed}","{r.time_promo}","{r.time_price}" -{end:} -"Grand Totals",{if:checkPermission(#0#)}"",{end:}"","","","","","","{totalQuant}","{totalSold}","{totalClaimed}","{totalPromos}","{totalPrice}" -"",{if:checkPermission(#0#)},""{end:},"","","","","","","","","{percentClaimed}%" -{else:} -No results found. -{end:} diff --git a/legacy/views/admin/tickets/Report/salesDetail.html b/legacy/views/admin/tickets/Report/salesDetail.html deleted file mode 100644 index 5f2a699..0000000 --- a/legacy/views/admin/tickets/Report/salesDetail.html +++ /dev/null @@ -1,226 +0,0 @@ - - -{if:printOutput} - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - -{end:} - - - -
    - - Sales Detail Report - Report Produced: {reportDate} {reportTime} -
    -
    {reportNote}
    - - {if:salesList} - -
    - - - - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - - {foreach:salesList,r} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - - - - - - - - - - {end:} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - - -
    {term.prop.cap}{term.performance.cap}{term.section.cap}{term.ticket.cap}Add OnAdd On
    Sold
    DateTimeQuantitySoldClaimedPromoPaidOrder ID{term.voucher.cap}First NameLast NameAddressAddress 2CityStateZIP/PostalCountryPhone #
    {r.memb_name}{r.perf_name}{r.sect_name}{r.tick_name}{r.addon_name}{r.addon_sold}{r.date_date}{r.time_time}{r.time_quant}{r.time_sold}{r.time_claimed}{r.time_promo_money}{r.time_money}{r.order_id}{r.order_voucher_id}{r.order_fname:h}{r.order_lname:h}{r.order_addr1:h}{r.order_addr2:h}{r.order_city:h}{r.order_state:h}{r.order_zip}{r.order_country}{r.order_phone}
                            
    Grand Totals       {totalQuant}{totalSold}{totalClaimed}{totalPromosMoney}{totalMoney}           
             {percentSold}%{percentClaimed}%             
    -
    -
    - - {else:} -

    No results found.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var SalesReportTable = $('#SalesReportTable').dataTable({ - "sScrollY": "600px", - "sScrollX": "100%", - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false - }); - $(window).resize(function(){ - SalesReportTable.fnDraw(); - }); - - - f_restartOnTabSelect(); - - }); - - - - -{if:printOutput} - - -{end:} diff --git a/legacy/views/admin/tickets/Report/salesDetailCSV.html b/legacy/views/admin/tickets/Report/salesDetailCSV.html deleted file mode 100755 index dd0bd0d..0000000 --- a/legacy/views/admin/tickets/Report/salesDetailCSV.html +++ /dev/null @@ -1,11 +0,0 @@ -"Sales Report","Report Produced: {reportDate}","{reportTime}","{reportNote}" - -{if:salesList}{if:checkPermission(#0#)}"{term.prop.cap}",{end:}"{term.performance.cap}","{term.section.cap}","{term.ticket.cap}","Add On","Add On Sold","Date","Time","Quantity","Sold","Claimed","Promo","Paid","Order ID","{term.voucher.cap}","First Name","Last Name","Address","Address 2","City","State","ZIP/Postal","Country","Phone #" -{foreach:salesList,r}{if:checkPermission(#0#)}"{r.memb_name}",{end:}"{r.perf_name}","{r.sect_name}","{r.tick_name}","{r.addon_name}","{r.addon_sold}","{r.date_date}","{r.time_time}","{r.time_quant}","{r.time_sold}","{r.time_claimed}","{r.time_promo}","{r.time_price}","{r.order_id}","{r.order_voucher_id}","{r.order_fname:h}","{r.order_lname:h}","{r.order_addr1:h}","{r.order_addr2:h}","{r.order_city:h}","{r.order_state:h}","{r.order_zip}","{r.order_country}","{r.order_phone}" -{end:} -"Grand Totals",{if:checkPermission(#0#)}"",{end:}"","","","","","","{totalQuant}","{totalSold}","{totalClaimed}","{totalPromos}","{totalPrice}" -"",{if:checkPermission(#0#)},""{end:},"","","","","","","","","{percentClaimed}%" -{else:} -No results found. -{end:} - diff --git a/legacy/views/admin/tickets/Report/salesPackageTickets.html b/legacy/views/admin/tickets/Report/salesPackageTickets.html deleted file mode 100644 index 995b8cf..0000000 --- a/legacy/views/admin/tickets/Report/salesPackageTickets.html +++ /dev/null @@ -1,141 +0,0 @@ - - -{if:printOutput} - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - -{end:} - - - -
    - - Sales Detail Report - Report Produced: {reportDate} {reportTime} -
    -
    {reportNote}
    - - {if:salesList} - -
    - - - - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - {foreach:salesList,r} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - {end:} - - {if:checkPermission(#0#)}{end:} - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - -
    {term.prop.cap}{term.performance.cap}{term.section.cap}{term.ticket.cap}SoldClaimedPaid
    {r.memb_name}{r.perf_name}{r.sect_name}{r.tick_name}{r.time_sold}{r.time_claimed}{r.time_money}
           
    Grand Totals   {totalSold}{totalClaimed}{totalMoney}
         {percentClaimed}% 
    -
    -
    - - {else:} -

    No results found.

    - {end:} - -
    -{startScript:h} - - $(function() { - - var SalesReportTable = $('#SalesReportTable').dataTable({ - "sScrollY": "600px", - "sScrollX": "100%", - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false - }); - $(window).resize(function(){ - SalesReportTable.fnDraw(); - }); - - - f_restartOnTabSelect(); - - }); - - - - -{if:printOutput} - - -{end:} diff --git a/legacy/views/admin/tickets/Report/salesPackageTicketsCSV.html b/legacy/views/admin/tickets/Report/salesPackageTicketsCSV.html deleted file mode 100755 index 4080f0c..0000000 --- a/legacy/views/admin/tickets/Report/salesPackageTicketsCSV.html +++ /dev/null @@ -1,11 +0,0 @@ -"Sales Report","Report Produced: {reportDate}","{reportTime}","{reportNote}" - -{if:salesList}{if:checkPermission(#0#)}"{term.prop.cap}",{end:}"{term.performance.cap}","{term.section.cap}","{term.ticket.cap}","Sold","Claimed","Paid" -{foreach:salesList,r}{if:checkPermission(#0#)}"{r.memb_name}",{end:}"{r.perf_name}","{r.sect_name}","{r.tick_name}","{r.time_sold}","{r.time_claimed}","{r.time_price}" -{end:} -"Grand Totals",{if:checkPermission(#0#)}"",{end:}"","","{totalSold}","{totalClaimed}","{totalPrice}" -"",{if:checkPermission(#0#)},""{end:},"","","{percentClaimed}%" -{else:} -No results found. -{end:} - diff --git a/legacy/views/admin/tickets/Report/salesReportSelection.html b/legacy/views/admin/tickets/Report/salesReportSelection.html deleted file mode 100644 index 01025f2..0000000 --- a/legacy/views/admin/tickets/Report/salesReportSelection.html +++ /dev/null @@ -1,236 +0,0 @@ -
    - -
    - Sales Report Selection -
    - -
    - -
    - - -{if:!checkPermission(#0#)} - -{end:} -
    - - - -{if:checkPermission(#0#)} - - - - - - - - - - - - -{end:} - - - - - - - - - - - - - - - - - -
    Type of Report: - -
    {term.prop.cap}: - -
    Show inactive {term.prop.plur_cap}
    {term.performance.cap}: - (select a {term.prop.norm} first) -
    Date Range: - - -    - From:    - Through:    - -
    Claimed {term.ticket.plur_cap} Only:
    Output Type: - -
    -
    - -
    - -
    - -
    - -
    - -
    - - -
    - -{startScript:h} - - var mList = new Array(); - {foreach:mList,m} - mList[{m.id}] = ''; - {end:} - - $(function() { - - /* - * Table operations - */ - - $('.salesReportTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '10%' }, - null - ] - }); - - /* - * AJAX form handling - */ - - $('#salesReportForm').ajaxForm({ - beforeSubmit: function(xhr) { - - // Check if this is going to be a csv - var outputType = $('#outputType').val(); - if (outputType == 'csv') { - - // Since this is a csv, open a new window with the desired URL and parameters rather than an ajax submit. - var url = appAdminURL + '&' + $('#salesReportForm').formSerialize(); - window.open(url, 'csvReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=no,width=100, height=10'); - return false; - } - }, - success: function(data) { - - var outputType = $('#outputType').val(); - - if (outputType == 'print') { - var w = window.open('', 'printReport', 'toolbar=no,location=no,directories=no,menubar=no,scrollbars=yes,width=1000, height=700, left=100, top=25'); - $(w.document.body).html(data); - } else { - f_replaceContents(data, $('#report_result_container')); - } - - return false; - } - }); - - // Block default form submission - $("#salesReportForm").submit(function (e) { - - var outputType = $('#outputType').val(); - - if (outputType == 'html') { - $('#report_result_container').html('
    Submitting, Please Wait...
    '); - } - - e.preventDefault(); - }); - - - var currentMousePos = { x: -1, y: -1 }; - $(document).mousemove(function(event) { - currentMousePos.x = event.pageX; - currentMousePos.y = event.pageY; - }); - - // Code to start datepicker for each date input - $("#startDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [100,200]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - $("#endDateInput").datepicker({ - dateFormat: "mm/dd/yy", - dialog: [{maxDate}, false, false, [200,300]], - minDate: '{minDate}', - maxDate: '{maxDate}', - beforeShow: function (input, inst) { - setTimeout(function () { - inst.dpDiv.css({ - top: currentMousePos.y, - left: currentMousePos.x - }); - }, 0); - } - }); - - // Check if to hide dates - $('#dateType').on('change', null, function() { - var dateType = $(this).val(); - if (dateType == 'all') { - $('#dateFields').addClass('emContentAreaHidden'); - } else { - $('#dateFields').removeClass('emContentAreaHidden'); - } - }); - - // Selection of performance list - $('#memberID').on('change', null, function() { - var memberID = $(this).val(); - $('#performanceSelect').html(mList[memberID]); - }); - - f_restartOnTabSelect(); - -{if:!checkPermission(#0#)} - // This must be a member used so start with their performances loaded - $('#performanceSelect').html(mList[{userMemberID}]); -{end:} - - - - - }); - - - diff --git a/legacy/views/admin/tickets/Section/delete.html b/legacy/views/admin/tickets/Section/delete.html deleted file mode 100755 index e9bd6d0..0000000 --- a/legacy/views/admin/tickets/Section/delete.html +++ /dev/null @@ -1,55 +0,0 @@ -
    - -
    Delete this {term.section.cap}
    - -
    {sectionDetail.name}
    - -{if:checkPermission(#10#)} -
    - - -
    -{end:} - - {if:sectionDetail} -
    - - - - - - - - - -
    Delete {term.section.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.section.norm}.

    -
    Name:{sectionDetail.name}
    - {else:} -

    No {term.section.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#SectionDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Section/detail.html b/legacy/views/admin/tickets/Section/detail.html deleted file mode 100755 index 3f40371..0000000 --- a/legacy/views/admin/tickets/Section/detail.html +++ /dev/null @@ -1,75 +0,0 @@ -
    - -
    {term.section.cap}: {sectionDetail.name}
    - -
    - - -
    - - {if:sectionDetail} -
    - - - - {if:sectionDetail.delete} - - - - - {end:} - - - - - - - - - -
    Delete {term.section.cap}: - {if:sectionDetail.deleteConfirmed} - {if:sectionDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {sectionDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.section.norm}.

    - {end:} -
    {term.section.cap} Name:{sectionDetail.name}
    Description:{sectionDetail.descr:h}
    Image: - {if:sectionDetail.image} - - {else:}(none){end:} -
    {term.entrance.cap}:{sectionDetail.entrance}
    Sort Order:{sectionDetail.sort}
    - {else:} -

    No {term.section.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#SectionDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Section/edit.html b/legacy/views/admin/tickets/Section/edit.html deleted file mode 100755 index d56f881..0000000 --- a/legacy/views/admin/tickets/Section/edit.html +++ /dev/null @@ -1,186 +0,0 @@ -
    - -
    - {if:addingNewSection}Adding New {term.section.cap}{end:} - {if:editingSection}Editing {term.section.cap}{end:} -
    - -{if:checkPermission(#10#)} -
    - {if:addingNewSection} - - {else:} - - {end:} -
    -{end:} - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:sectionDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewSection} - - {else:} - - {end:} - - - - - -
    - - - - - {if:fieldRequired.name} - {if:fieldFail.name} - - - {if:fieldRequired.descr} - {if:fieldFail.descr} - - - {if:fieldRequired.image} - {if:fieldFail.image} - - - {if:fieldRequired.entrance} - {if:fieldFail.entrance} - - - {if:fieldRequired.sort} - {if:fieldFail.sort} - - -
    {else:}{end:}{term.section.cap} Name:{else:}{end:} - - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    {else:}{end:}Description:{else:}{end:} - - {if:fieldFail.descr}
    {fieldFail.descr}{end:} -
    {else:}{end:}Image:{else:}{end:} - {if:sectionDetail.image} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.image}
    {fieldFail.image}{end:} -
    {else:}{end:}{term.entrance.cap}:{else:}{end:} - - Optional - {if:fieldFail.entrance}
    {fieldFail.entrance}{end:} -
    {else:}{end:}Output Order:{else:}{end:} - - {if:fieldFail.sort}
    {fieldFail.sort}{end:} -
    -
    - -
    - {if:addingNewSection} - - {end:} - {if:editingSection} - - {end:} -
    - -
    - - {else:} -

    No {term.section.norm} has been selected yet.

    -

    To edit a {term.section.norm}, first select it from the list of available {term.section.plur}. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.sectionEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#SectionForm').ajaxForm({ - success: function(data) { - {if:addingNewSection} - f_replaceContents(data, $('#Member_info_container')); - {end:} - {if:editingSection} - f_replaceContents(data, $('#Member_info_container')); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#sectionFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#descr")); - f_buildCkeditor($("#notes")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - f_restartOnTabSelect(); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Section/list.html b/legacy/views/admin/tickets/Section/list.html deleted file mode 100644 index 48b7eec..0000000 --- a/legacy/views/admin/tickets/Section/list.html +++ /dev/null @@ -1,127 +0,0 @@ - -
    - -
    - - -
    - - Search {term.section.plur_cap}: (type any portion of a {term.section.norm} name) - - {if:sectionList} - -
    - - - - - - {foreach:sectionList,c} - - - - - {end:} - -
    Sort OrderName
    {c.sort}
    -
    - - {else:} -

    No {term.section.plur} listed.

    -

    - You will need at least one {term.section.norm} in order to sell {term.ticket.plur}. - You may, however, use a single generic {term.section.norm} such as "General Admission". -

    - {end:} - -
    -
    - - -
    -{startScript:h} - - // Sections Search - var sectionsSearchData = [ - {foreach:sectionList,c} - {label:'{c.name:h}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var SectionListTable = $('#SectionListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '80px' }, - null - ] - }); - $(window).resize(function(){ - SectionListTable.fnDraw(); - }); - - // Toggle length of table - var SectionListTableSmall = true; - var SectionListTableHeight = $('#SectionListTable_wrapper div.dataTables_scrollBody').height(); - $('#sectionListSizeChange').click(function() { - if (SectionListTableSmall) { - $('#SectionListTable_wrapper div.dataTables_scrollBody').height('auto'); - SectionListTableSmall = false; - $(this).html('Smaller Table'); - SectionListTable.fnSettings().oScroll.sY = '100%'; - SectionListTable.fnDraw(); - } else { - $('#SectionListTable_wrapper div.dataTables_scrollBody').height(SectionListTableHeight); - SectionListTableSmall = true; - $(this).html('Larger Table'); - SectionListTable.fnSettings().oScroll.sY = '100px'; - SectionListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Section_detail_container').hide(duration); - - $('.sectionListSelect').click(function(){ - $('#SectionListTable_wrapper div.dataTables_scrollBody').height(SectionListTableHeight); - SectionListTableSmall = true; - $('#sectionListSizeChange').html('Larger Table'); - SectionListTable.fnSettings().oScroll.sY = '100px'; - SectionListTable.fnDraw(); - f_loadAction('Section_detail', 'Section_detail_container', 'SectionID=' + $(this).attr('emSectionId') + '&tabList={tabList}'); - }); - - // Search Sections - $("#sectionsSearch").autocomplete({ - source: sectionsSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#sectionsSearch").attr({value: ui.item.label}); - f_loadAction('Section_detail', 'Section_detail_container', 'SectionID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Sold/claim.html b/legacy/views/admin/tickets/Sold/claim.html deleted file mode 100644 index 6e6a754..0000000 --- a/legacy/views/admin/tickets/Sold/claim.html +++ /dev/null @@ -1,87 +0,0 @@ -
    - - -
    - -
    -
    - - - - - - - - - - - - -
    {term.voucher.cap} #: -
    - Mark as claimed -
    {term.order.cap} #:
    -
    -
    - -
    -
    - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - var ClaimTable = $('#ClaimTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - - }); - - // Display selected Voucher - if Enter key is used - $('#SoldID').keydown( function (event) { - if(event.which == 13) { - var soldID = $('#SoldID').val(); - var doClaim = $('#doClaim').is(':checked'); - - $("#SoldID").focus(); - f_loadAction('Sold_detail', 'Voucher_detail_container', 'SoldID=' + soldID + '&doClaim=' + doClaim + '&tabList={tabList}'); - $('#Voucher_detail_container').removeClass('emContentAreaHidden'); - $("#SoldID").val(''); - } - }); - - // Display selected Order - $('#OrderID').keydown( function (event) { - if(event.which == 13) { - var orderID = $('#OrderID').val(); - $("#OrderID").focus(); - f_loadAction('Order_selected', 'Voucher_detail_container', 'OrderID=' + orderID + '&tabList={tabList}'); - $('#Voucher_detail_container').removeClass('emContentAreaHidden'); - $("#OrderID").val(''); - } - }); - - $("#SoldID").focus(); - - f_restartOnTabSelect(); - - $('input').keydown( function (event) { - $('#scanVoucherIdArea').removeClass('scanVoucherResultNone'); - $('#scanVoucherIdArea').removeClass('scanVoucherResultClaimed'); - $('#scanVoucherIdArea').removeClass('scanVoucherResultUsed'); - }); - - - if ({orderID} > 0) { - f_loadAction('Order_selected', 'Voucher_detail_container', 'OrderID=' + {orderID} + '&tabList={tabList}'); - } - - }); - diff --git a/legacy/views/admin/tickets/Sold/detail.html b/legacy/views/admin/tickets/Sold/detail.html deleted file mode 100644 index e57734e..0000000 --- a/legacy/views/admin/tickets/Sold/detail.html +++ /dev/null @@ -1,278 +0,0 @@ -
    - -
    {soldDetail.name}
    - -{if:haveProblem} -

    We're sorry, we had a problem with your request:

    -
      - {foreach:problem,r} -
    • {r:h}
    • - {end:} -
    -
    -{end:} - - - {if:soldDetail} - -
    - - - - - - - - - -
    - -
    - - - - {if:soldDetail.delete} - - - - - {end:} - {if:markedAsClaimed} - - {end:} - - - - - - - {if:soldDetail.is_package.value} - - {else:} - {if:soldDetail.ticket_package} - - - - - {else:} - Uses available - {end:} - - - - {if:soldDetail.unlimited_use.value} - - {else:} - - {end:} - - - - - - - - - - - {if:soldDetail.date_specific.value} - - {else:} - - {end:} - {if:soldDetail.time_specific.value} - - {else:} - - {end:} - - {else:} - - - - - {else:} - Uses available - {end:} - - - - {if:soldDetail.unlimited_use.value} - - {else:} - - {end:} - - - - - - - - {if:soldDetail.assigned.value} - - {end:} - - - - - {if:soldDetail.date_specific.value} - - {else:} - - - {end:} - {if:soldDetail.time_specific.value} - - {else:} - - {end:} - - - - {end:} - {end:} - -
    Delete {term.ticket.cap} Sold: - {if:soldDetail.deleteConfirmed} - {if:soldDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {soldDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.ticket.norm} sold.

    - {end:} -
    Marked as Claimed
    {term.voucher.cap} #:{soldDetail.id}
    {term.order.cap} #:{soldDetail.ticket_order}
    Type - {if:soldDetail.is_package.value} - Package -

    - - - {foreach:packageDetail,p} - - - - - - - {end:} -
    Ticket NameNumber of UsesTimes ClaimedAvailable
    {p.ticket_name}{p.numb_uses} - {p.numb_claimed} - - {if:p.fullyClaimedAlert} - FULLY CLAIMED! - {else:} - {p.remaining} - {end:} -
    -

    - {else:} - {if:soldDetail.ticket_package} - Package {term.ticket.cap} - {else:} - {term.ticket.cap} - {end:} - {end:} -
    Price Paid:{soldDetail.price_paid}
    {term.voucher.cap} Status: - - {if:fullyClaimedAlert} - FULLY CLAIMED!
    Number of Uses:Unlimited use.
    Number of Uses:{soldDetail.numb_uses}
    Number of Times Claimed: - {soldDetail.numb_claimed} - {if:soldDetail.fullyClaimedAlert} -   FULLY CLAIMED! - {end:} -
    {term.prop.cap}:{soldDetail.member_name}
    {term.entrance.cap}:{soldDetail.entrance_name}
    {term.performance.cap}:{soldDetail.performance_name}
    {term.section.cap}:{soldDetail.section_name}
    {term.ticket.cap}:{soldDetail.ticket_name}
    Specific date only:{soldDetail.date_specific.name}
    {term.ticket.cap} Date:{soldDetail.ticket_date.date}
    Dates useable:{soldDetail.start_date.date} through {soldDetail.end_date.date}
    {term.ticket.cap} Time:{soldDetail.ticket_time.time}
    {term.ticket.cap} Time:Use any time of the day.
    {term.voucher.cap} Status: - - {if:fullyClaimedAlert} - FULLY CLAIMED!
    Number of Uses:Unlimited use.
    Number of Uses:{soldDetail.numb_uses}
    Number of Times Claimed: - {soldDetail.numb_claimed} - {if:soldDetail.fullyClaimedAlert} -   FULLY CLAIMED! - {end:} -
    {term.prop.cap}:{soldDetail.member_name}
    {term.entrance.cap}:{soldDetail.entrance_name}
    Assigned from other {term.prop.norm}:{soldDetail.assigned.name}
    Assigned from:{soldDetail.assigned_from_name}
    {term.performance.cap}:{soldDetail.performance_name}
    {term.section.cap}:{soldDetail.section_name}
    {term.ticket.cap}:{soldDetail.ticket_name}
    Specific date only:{soldDetail.date_specific.name}
    {term.ticket.cap} Date:{soldDetail.ticket_date.date}
    Dates useable:{soldDetail.start_date.date} through {soldDetail.end_date.date}
    Likely use date:{soldDetail.likely_date.date}
    {term.ticket.cap} Time:{soldDetail.ticket_time.time}
    {term.ticket.cap} Time:Use any time of the day.
    Price Paid:{soldDetail.price_paid}
    - {else:} -

    No sold {term.ticket.plur} detail available.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#SoldDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - // Mark as claimed - $('#VoucherClaim').on('click', null, function() { - - $('#ClaimDateTD').html('
    Storing, Please Wait...
    '); - var voucherID = $(this).attr('voucherID'); - - $.ajax({ - url: "{adminURL}&Action=Sold_claimVoucher&VoucherID=" + voucherID, - success: function(data) { - - var code = data.substring(0, 1); - var time = data.substring(2); - - switch (code) { - - case 's': - break; - case 'c': - time = time + ' - NOTE: This voucher had already been claimed'; - break; - case 'f': - time = 'Unable to mark voucher as claimed. Is this a valid voucher?'; - break; - } - - $('#ClaimDateTD').html(time); - - } , - error: function() { - alert('No response. Unable to mark this voucher as claimed at this time.\n'); - } - }); - - }); - - f_restartOnTabSelect(); - - {if:alreadyClaimedAlert} - $('#scanVoucherIdArea').addClass('scanVoucherResultUsed'); - {else:} - {if:markedAsClaimed} - $('#scanVoucherIdArea').addClass('scanVoucherResultClaimed'); - {else:} - $('#scanVoucherIdArea').addClass('scanVoucherResultNone'); - {end:} - {end:} - - }); - diff --git a/legacy/views/admin/tickets/Sold/list.html b/legacy/views/admin/tickets/Sold/list.html deleted file mode 100644 index 3218df0..0000000 --- a/legacy/views/admin/tickets/Sold/list.html +++ /dev/null @@ -1,113 +0,0 @@ - -
    - - {if:soldList} - -
    - - - - - - - - - - - - - - - {foreach:soldList,c} - {if:c.is_package.value} - - - - - - - - - - - {else:} - - - {if:c.ticket_package} - - {else:} - - {end:} - - - - - - - - {end:} - {end:} - -
    Voucher #TypeUsesClaimed{term.performance.cap}{term.entrance.cap}TicketDate
    Package  {c.performance_name:h}{c.entrance_name:h}{c.ticket_name:h} 
    Package {term.ticket.cap}{term.ticket.cap}{c.numb_uses}{c.numb_claimed}{c.performance_name:h}{c.entrance_name:h}{c.ticket_name:h} - - {if:soldDetail.date_specific.value} - {c.ticket_date.date} - {else:} - {c.start_date.date} through {c.end_date.date} - {end:} -
    -
    - - {else:} -

    No Purchased {term.ticket.plur} listed.

    - {end:} - -
    -
    - - -
    -{startScript:h} - - $(function() { - - // Note, not scrolling this table - Show everything - var SoldListTable = $('#SoldListTable').dataTable({ - "bScrollCollapse": true, - "scrollX": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { "sWidth": "5%", "sType": "numeric" }, - null, - null, - null, - null, - null, - null, - null - ] - }); - $(window).resize(function(){ - SoldListTable.fnDraw(); - }); - - // Close all local sliders - $('#Sold_detail_container').hide(duration); - - $('.soldListSelect').click(function(){ - f_loadAction('Sold_selected', 'Sold_detail_container', 'SoldID=' + $(this).attr('emSoldId') + '&tabList={tabList}&checkBypass=true'); - }); - - - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Sold/selected.html b/legacy/views/admin/tickets/Sold/selected.html deleted file mode 100644 index b86f13d..0000000 --- a/legacy/views/admin/tickets/Sold/selected.html +++ /dev/null @@ -1,56 +0,0 @@ -
    - -
    -
    {term.voucher.cap} ID: {soldDetail.id}
    -
    - -
    - - -
    -{if:checkPermission(#30#)} - - -{end:} - -
    - - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with ticket sold detail loaded - f_loadAction('Sold_detail', 'Sold_info_container', "tabList={tabList}&soldID={soldDetail.id}&checkBypass=true"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Ticket/addGetMember.html b/legacy/views/admin/tickets/Ticket/addGetMember.html deleted file mode 100755 index 3fd53ec..0000000 --- a/legacy/views/admin/tickets/Ticket/addGetMember.html +++ /dev/null @@ -1,90 +0,0 @@ -
    - -
    - Adding New {term.ticket.cap} -
    - -
    - -
    - -
    - -
    - - -
    - - - - - - - - -
    Start by selecting {term.prop.cap}: - - {if:fieldFail.performance}
    {fieldFail.performance}{end:} -
    -
    - -
    - -
    - -
    - -
    - -
    - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.ticketEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#ticketForm').ajaxForm({ - success: function(data) { - f_replaceContents(data, $('#Ticket_detail_container')); - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#ticketFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - f_restartOnTabSelect(); - - }); - - - diff --git a/legacy/views/admin/tickets/Ticket/delete.html b/legacy/views/admin/tickets/Ticket/delete.html deleted file mode 100644 index 27bb740..0000000 --- a/legacy/views/admin/tickets/Ticket/delete.html +++ /dev/null @@ -1,140 +0,0 @@ -
    - -
    Delete this {term.ticket.cap}
    - -
    {ticketDetail.name}
    - -
    - - -
    - - {if:ticketDetail} -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - -
    Delete {term.ticket.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.ticket.norm}.

    -
    {term.prop.cap}{ticketDetail.member_name:h}
    {term.ticket.cap} Type:{ticketDetail.ticket_type.name}
    {term.ticket.cap} Name:{ticketDetail.name}
    {term.ticket.cap} Title:{ticketDetail.title}
    Active:{ticketDetail.active.name}
    Purchase by Admin Only:{ticketDetail.admin_only.name}
    {term.performance.cap}:{ticketDetail.performance}
    {term.section.cap}:{ticketDetail.section}
    Dates available for sale: - {if:ticketDetail.for_sale_start_date.date} - May be purchased starting on {ticketDetail.for_sale_start_date.date}
    - {else:} - {if:ticketDetail.for_sale_end_date.date} - {else:} - No purchase date restrictions - {end:} - {end:} - {if:ticketDetail.for_sale_end_date.date} - May be purchased through {ticketDetail.for_sale_end_date.date}
    - {end:} -
    Date: - {if:ticketDetail.date_specific.value} - Dates determined by inventory. - {else:} - {if:ticketDetail.start_date.date} - May be used from {ticketDetail.start_date.date} through {ticketDetail.end_date.date} - {else:} - May be used on any date. - {end:} - {end:} -
    Time: - {if:ticketDetail.time_specific.value} - {ticketDetail.ticket_time.time} - {else:} - No time specified. - {end:} -
    Uses per {term.ticket.cap}: - {if:ticketDetail.unlimited_use.value} - May be used an unlimited number of times. - {else:} - {ticketDetail.uses} - {end:} -
    Quantity: - {if:ticketDetail.unlimited_quant.value} - Unlimited - {else:} - {ticketDetail.quant} - {end:} -
    Consignment Type:{ticketDetail.consignment_type.name}
    Always show in cart:{ticketDetail.cart_sticky.name}
    If checked, will force this to show in the cart regardless of quantity selected.
    Show on Start Page:{ticketDetail.show_on_start.name}
    If checked (Yes), will display this ticket on the start page under the category.
    User selection of an Add-On Required:{ticketDetail.addon_required.name}
    Price:{ticketDetail.price}
    Description:{ticketDetail.descr:h}
    Image: - {if:ticketDetail.image} - - {else:}(none){end:} -
    Text for {term.voucher.cap}:{ticketDetail.voucher_text:h}
    Alternate text for left end of {term.voucher.cap}:{ticketDetail.voucher_leftend_text:h}
    {term.voucher.cap} Type:{ticketDetail.voucher_type.name}
    Sort Order:{ticketDetail.sort}
    - {else:} -

    No {term.ticket.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#TicketDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/Ticket/detail.html b/legacy/views/admin/tickets/Ticket/detail.html deleted file mode 100644 index 047d399..0000000 --- a/legacy/views/admin/tickets/Ticket/detail.html +++ /dev/null @@ -1,200 +0,0 @@ -
    - - - -
    - - -
    - - {if:ticketDetail} -
    - - - - {if:ticketDetail.delete} - - - - - {end:} - - - - {if:option.packages} - - - - - {end:} - - - - - - - - - - - - - - - - - - - - - - - - - - {if:checkPermission(#0#)} - - {end:} - - - - - - - - - - - - - - -
    Delete {term.ticket.cap}: - {if:ticketDetail.deleteConfirmed} - {if:ticketDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {ticketDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.ticket.norm}.

    - {end:} -
    {term.prop.cap}{ticketDetail.member_name:h}
    {term.ticket.cap} Name:{ticketDetail.name}ID: {ticketDetail.id}
    {term.ticket.cap} Title:{ticketDetail.title:h}
    {term.ticket.cap} Type: -

    {ticketDetail.ticket_type.name}

    - {if:isPackage} -

    Package Tickets

    - - - - - - {foreach:ticketPackage,y} - - - - - - - - - {end:} - -
    QuantSeparate VoucherLocationCategoryTicketActive
    {y.quant}{y.separate_voucher.name}{y.member_name:h}{y.performance_name:h}{y.title:h}{if:y.active}Yes{else:}No{end:}
    - {end:} -
    Active:{ticketDetail.active.name}
    Purchase by Admin Only:{ticketDetail.admin_only.name}
    {term.performance.cap}:{ticketDetail.performance:h}
    {term.section.cap}:{ticketDetail.section}
    Dates available for sale: - {if:ticketDetail.for_sale_start_date.date} - May be purchased starting on {ticketDetail.for_sale_start_date.date}
    - {else:} - {if:ticketDetail.for_sale_end_date.date} - {else:} - No purchase date restrictions - {end:} - {end:} - {if:ticketDetail.for_sale_end_date.date} - May be purchased through {ticketDetail.for_sale_end_date.date}
    - {end:} -
    Date: - {if:ticketDetail.date_specific.value} - Dates determined by inventory. -

    - Days of week: {foreach:ticketDetail.days_of_week.names,s}{s}  {end:} - {if:ticketDetail.start_date.date} -
    Inventory will be created from {ticketDetail.start_date.date} through {ticketDetail.end_date.date} - {end:} -

    - - {else:} - {if:ticketDetail.start_date.date} - May be used from {ticketDetail.start_date.date} through {ticketDetail.end_date.date} - {else:} - May be used on any date. - {end:} - {end:} -
    Time: - {if:ticketDetail.time_specific.value} - {ticketDetail.ticket_time.time} - {else:} - No time specified. - {end:} -
    Uses per {term.ticket.cap}: - {if:ticketDetail.unlimited_use.value} - May be used an unlimited number of times. - {else:} - {ticketDetail.uses} - {end:} -
    Quantity: - {if:ticketDetail.unlimited_quant.value} - Unlimited - {else:} - {ticketDetail.quant} - {end:} -
    Consignment Type:{ticketDetail.consignment_type.name}
    Always show in cart (Sticky):{ticketDetail.cart_sticky.name}
    If checked (Yes), will force this to show in the cart regardless of quantity selected.
    Show on Start Page:{ticketDetail.show_on_start.name}
    If checked (Yes), will display this ticket on the start page under the category.
    User selection of an Add-On Required:{ticketDetail.addon_required.name}
    Price:{ticketDetail.price}
    Description:{ticketDetail.descr:h}
    Image: - {if:ticketDetail.image} - - {else:}(none){end:} -
    Text for {term.voucher.cap}:{ticketDetail.voucher_text:h}
    Alternate text for left end of {term.voucher.cap}:{ticketDetail.voucher_leftend_text:h}
    {term.voucher.cap} Type:{ticketDetail.voucher_type.name}
    Sort Order:{ticketDetail.sort}
    Test VoucherPrint test {term.voucher.plur}
    - {else:} -

    No {term.ticket.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#TicketDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - // Print test vouchers - $('.voucherPrint').click(function(){ - var orderID = $(this).attr('emOrderID'); - var orderVerify = $(this).attr('emOrderVerify'); - var voucherWindow = window.open('{adminURL}&Action=Ticket_printSampleVoucher&testTicket={ticketDetail.id}', - "voucherPrint", - "height=750,width=600,menubar=yes,toolbar=yes,alwaysRaised=yes,menu" - ); - voucherWindow.focus(); - voucherWindow.print(); - return false; - }); - - - }); - diff --git a/legacy/views/admin/tickets/Ticket/edit.html b/legacy/views/admin/tickets/Ticket/edit.html deleted file mode 100644 index 48c2045..0000000 --- a/legacy/views/admin/tickets/Ticket/edit.html +++ /dev/null @@ -1,663 +0,0 @@ -
    - -
    - {if:addingNewTicket}Adding New {term.ticket.cap}{end:} - {if:editingTicket}Editing {term.ticket.cap}{end:} -
    - -
    -{if:addingNewTicket} - -{else:} - -{end:} -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:ticketDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewTicket} - - {else:} - - {end:} - - - - - -
    - - - - - - - - - {if:addingNewTicket} - {if:fieldRequired.performance} - {if:fieldFail.performance} - {else:} - - - {end:} - - - {if:fieldRequired.name} - {if:fieldFail.name} - - - {if:fieldRequired.title} - {if:fieldFail.title} - - {if:option.packages} - - {if:fieldRequired.ticket_type} - {if:fieldFail.ticket_type} - - {end:} - - - - - - - - - - {if:fieldRequired.section} - {if:fieldFail.section} - - - - - - - - {if:fieldFail.date_specific} - - - - - - - - - - - - - - - {if:fieldRequired.consignment_type} - {if:fieldFail.consignment_type} - - {if:checkPermission(#0#)} - - - {if:fieldFail.cart_sticky} - - {end:} - - - {if:fieldFail.show_on_start} - - - - {if:fieldFail.addon_required} - - - {if:fieldRequired.price} - {if:fieldFail.price} - - - {if:fieldRequired.descr} - {if:fieldFail.descr} - - - {if:fieldRequired.image} - {if:fieldFail.image} - - - {if:fieldRequired.voucher_text} - {if:fieldFail.voucher_test} - - - {if:fieldRequired.voucher_leftend_text} - {if:fieldFail.voucher_test} - - - {if:fieldRequired.voucher_type} - {if:fieldFail.voucher_type} - - - {if:fieldRequired.sort} - {if:fieldFail.sort} - - -
    {term.prop.cap}{memberDetail.name}
    {else:}{end:}{term.performance.cap}:{else:}{end:} - - {if:fieldFail.performance}
    {fieldFail.performance}{end:} -
    {term.performance.cap}{ticketDetail.performance.name:h}
    {else:}{end:}{term.ticket.cap} Name:{else:}{end:} -
    (for internal use) - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    {else:}{end:}{term.ticket.cap} Title:{else:}{end:} -
    (for display to customers) - {if:fieldFail.title}
    {fieldFail.title}{end:} -
    {else:}{end:}{term.ticket.cap} Type:{else:}{end:} - - {if:fieldFail.ticket_type}
    {fieldFail.ticket_type}{end:} -
    -

    Package Tickets

    -

    - - -

    - - - - - - {foreach:ticketPackage,y} - - - - - - - - - - {end:} - -
     QuantSeparate VoucherLocationCategoryTicketActive
    - {if:y.separate_voucher.value} - - {else:} - - {end:} - {y.member_name:h}{y.performance_name:h}{y.title:h}{if:y.active}Yes{else:}No{end:}
    -
    -
    Active: - {if:ticketDetail.active.value} - - {else:} - - {end:} - {if:!option.packages} - - {end:} -
    Purchase by Admin Only: - {if:ticketDetail.admin_only.value} - - {else:} - - {end:} -
    {else:}{end:}{term.ticket.cap} Section:{else:}{end:} - - {if:fieldFail.section}
    {fieldFail.section}{end:} -
    Dates available for sale: -
    - Set range of dates during which a user may purchase these {term.ticket.plur}.
    - Clear either or both fields if no start or end date is desired. - - - {if:fieldRequired.for_sale_start_date} - {if:fieldFail.for_sale_start_date} - - - {if:fieldRequired.for_sale_end_date} - {if:fieldFail.for_sale_end_date} - -
    {else:}{end:}Start Date:{else:}{end:} - {if:addingNewTicket} -
    - {else:} - - {end:} - This is the first date on which these {term.ticket.plur} may be purchased. -
    {else:}{end:}End Date:{else:}{end:} - {if:addingNewTicket} -
    - {else:} - - {end:} - This is the last date on which these {term.ticket.plur} may be purchaced. -
    -
    -
    Specified Dates:{else:}{end:} - {if:ticketDetail.date_specific.value} - - {else:} - - {end:} - Check if {term.ticket.plur} are for specific dates as determined by inventory.
    -
    -

    - Select days of the week for default inventory.
    - {foreach:ticketDetail.days_of_week.bitmap,s} - {if:s.default} - {s.name} - {else:} - {s.name} - {end:} - {end:} -

    -
    -
    - Set a range of dates during which this {term.ticket.norm} may be used. - - - {if:fieldRequired.start_date} - {if:fieldFail.start_date} - - - {if:fieldRequired.end_date} - {if:fieldFail.end_date} - -
    {else:}{end:}Start Date:{else:}{end:} - - {if:addingNewTicket} -
    - {else:} - - {end:} - This is the first date on which these {term.ticket.plur} can be used. -
    {else:}{end:}End Date:{else:}{end:} - {if:addingNewTicket} -
    - {else:} - - {end:} - This is the last date on which these {term.ticket.plur} can be used. -
    -
    - {if:fieldFail.date_specific}
    {fieldFail.date_specific}{end:} -
    Specified Time: - {if:ticketDetail.time_specific.value} - - {else:} - - {end:} - Check if there is a specific time for this {term.ticket.norm}. -
    - - {if:fieldFail.ticket_time}{else:}{end:} - - - -
    Time: - -
    -
    -
    Uses per {term.ticket.cap}: - {if:ticketDetail.unlimited_use.value} - - {else:} - - {end:} - Check if this {term.ticket.norm} can be scanned/claimed an unlimited number of times. -
    - - {if:fieldFail.unlimited_use}{else:}{end:} - - - -
    Number of Uses: - -
    -
    -
    Quantity: - {if:ticketDetail.unlimited_quant.value} - - {else:} - - {end:} - Check if the number of {term.ticket.plur} available is unlimited. -
    - - {if:fieldFail.quant}{else:}{end:} - - - -
    Quantity: - -
    Number of these {term.ticket.plur} normally available. Used as default when creating inventory. -
    -
    -
    {else:}{end:}Consignment Type:{else:}{end:} - - {if:fieldFail.consignment_type}
    {fieldFail.consignment_type}{end:} -
    Always show in cart:{else:}{end:} - {if:ticketDetail.cart_sticky.value} - - {else:} - - {end:} - {if:fieldFail.cart_sticky}
    {fieldFail.cart_sticky}{end:} -
    Show Ticket on Start Page:{else:}{end:} - {if:ticketDetail.show_on_start.value} - - {else:} - - {end:} - {if:fieldFail.show_on_start}
    {fieldFail.show_on_start}{end:} -
    User Selection of Add-On is Required:{else:}{end:} - {if:ticketDetail.addon_required.value} - - {else:} - - {end:} - {if:fieldFail.addon_required}
    {fieldFail.addon_required}{end:} -

    - Select this option if you need the user to select at least one add-on at some cost - for this ticket to be included in the cart selection. -

    -
    {else:}{end:}Price:{else:}{end:} - - {if:fieldFail.price}
    {fieldFail.price}{end:} -
    {else:}{end:}Description:{else:}{end:} - - {if:fieldFail.descr}
    {fieldFail.descr}{end:} -
    {else:}{end:}Image:{else:}{end:} - {if:ticketDetail.image} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.image}
    {fieldFail.image}{end:} -
    {else:}{end:}Text for {term.voucher.cap}:{else:}{end:} -
    - Please be brief to conserve space on {term.voucher.plur}.
    - There is no formatting permitted for this field. - {if:fieldFail.voucher_text}
    {fieldFail.voucher_text}{end:} -
    {else:}{end:}Alternate text for left end of {term.voucher.cap}:{else:}{end:} -
    - Please be brief to conserve space on {term.voucher.plur}.
    - There is no formatting permitted for this field. KEEP SHORT! - {if:fieldFail.voucher_leftend_text}
    {fieldFail.voucher_leftend_text}{end:} -
    {else:}{end:}{term.voucher.cap} Type:{else:}{end:} - - {if:fieldFail.voucher_type}
    {fieldFail.voucher_type}{end:} -
    {else:}{end:}Output Order:{else:}{end:} - - {if:fieldFail.sort}
    {fieldFail.sort}{end:} -
    -
    - -
    - {if:addingNewTicket} - - {end:} - {if:editingTicket} - - {end:} -
    - -
    - - {else:} -

    No {term.ticket.norm} has been selected yet.

    -

    To edit a {term.ticket.norm}, first select it from the list of available {term.ticket.plur}. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.ticketEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#ticketForm').ajaxForm({ - success: function(data) { - {if:addingNewTicket} - var container = $('#Ticket_detail_container'); - f_replaceContents(data, container); - {end:} - {if:editingTicket} - var container = $('#Ticket_info_container'); - f_replaceContents(data, container); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#ticketFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#descr")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#descr")); - }); - - f_restartOnTabSelect(); - - // Handle show/hide for check fields with additional form fields - function checkField(name, reverse, opposite = false) { - f = $("input[name='" + name + "']"); - if (!reverse) { - if (f.is(':checked')) { - $('#' + name).show(); - } else { - $('#' + name).hide(); - } - } else { - if (f.is(':checked')) { - $('#' + name).hide(); - } else { - $('#' + name).show(); - } - } - - // check for opposite selection - if (opposite) { - if (reverse) { - if (f.is(':checked')) { - $('#' + opposite).show(); - } else { - $('#' + opposite).hide(); - } - } else { - if (f.is(':checked')) { - $('#' + opposite).hide(); - } else { - $('#' + opposite).show(); - } - } - - } - } - - $('.fieldSelect').change( function() { - name = $(this).attr('name'); - checkField(name, false); - }); - $('.fieldSelectRev').change( function() { - name = $(this).attr('name'); - checkField(name, true); - }); - - // Special case for date specific - $('.fieldSelectDateSpecific').change( function() { - checkField('date_specific', false); - }); - - // Setup additional form field show/hide when loading - checkField('section_specific', false); - checkField('date_specific', false); - checkField('time_specific', false); - checkField('unlimited_use', true); - checkField('unlimited_quant', true); - - // Code to start datepicker for each date input - $("#saleStartDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{ticketDetail.for_sale_start_date.date_list.min}', - maxDate: '{ticketDetail.for_sale_start_date.date_list.max}' - }); - $("#saleEndDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{ticketDetail.for_sale_end_date.date_list.min}', - maxDate: '{ticketDetail.for_sale_end_date.date_list.max}' - }); - $("#startDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{ticketDetail.start_date.date_list.min}', - maxDate: '{ticketDetail.start_date.date_list.max}' - }); - $("#endDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{ticketDetail.end_date.date_list.min}', - maxDate: '{ticketDetail.end_date.date_list.max}' - }); - - // Check for ticket_type being package and show the package table. - if ($('#ticket_type').val() == 20) { - $('#ticketPackageContents').show(); - } else { - $('#ticketPackageContents').hide(); - } - $('#ticket_type').change( function() { - if ($(this).val() == 20) { - $('#ticketPackageContents').show(); - } else { - $('#ticketPackageContents').hide(); - } - }); - - // Add selected package ticket - $('#addPackageTicket').click( function() { - var tickID = $('#packageTicketSelect').val(); - - // Check if this tickID is already selected - if (document.querySelector('#selectedTicket_' + tickID)) { - alert('This ticket has already been added to the package.\n Adjust quantity to add more.'); - return false; - }; - - // If we have a good ticket ID that hasn't been added, do it now - if (tickID) { - var t = $('#packageTicketOption_' + tickID); - var tickMember = t.attr('data-member'); - var tickPerformance = t.attr('data-performance'); - var tickTitle = t.attr('data-title'); - var tickActive = t.attr('data-active'); - $('#selectedTicketList').append(' \ - \ - \ - \ - \ - ' + tickMember + ' \ - ' + tickPerformance + ' \ - ' + tickTitle + ' \ - ' + tickActive + ' \ - \ - '); - } - }); - - // Delete selected package ticket - $( document ).on( "click", ".deleteSelectedTicket", function() { - var tickID = $(this).attr('data-id'); - - $('#selectedTicket_' + tickID).remove(); - }); - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Ticket/inventory.html b/legacy/views/admin/tickets/Ticket/inventory.html deleted file mode 100755 index ca9275b..0000000 --- a/legacy/views/admin/tickets/Ticket/inventory.html +++ /dev/null @@ -1,262 +0,0 @@ - -
    - - - -
    - {foreach:ticketCalendar,m} -
    -
    {m.month} {m.year}
    -
    -
    -
    -
    -
    -
    -
    -
    -
    Sun
    -
    Mon
    -
    Tue
    -
    Wed
    -
    Thu
    -
    Fri
    -
    Sat
    -
    - {foreach:m.weeks,w} - {if:w.weekUsed} -
    - {foreach:w.days,d} - {if:d.isDate} - {if:d.selectable} - {if:d.active.value} -
    - {else:} -
    - {end:} -
    -
    {d.dom}
    - -
    -
    -
    -
    Time:
    -
    {d.ticket_time.time}
    - -
    - {if:ticketDetail.unlimited_quant.value} -
    -
    Quantity:
    -
    Unlimited
    -
    - {else:} -
    -
    Quantity:
    -
    {d.quant}
    - -
    -
    -
    Avail:
    -
    {d.available}
    - -
    - {end:} -
    -
    Sold:
    -
    {d.sold}
    - -
    -
    -
    -
    - {else:} -
    -
    -
    {d.dom}
    - -
    -
    -
    -
    - {end:} - {else:} -
     
    - {end:} - {end:} -
    - {end:} - {end:} -
    - {end:} -
    - -
      -
    • Click date cell to dissable or enable a partcular date.
    • -
    • Click on edit icon to change the values.
    • -
    - - -
    - -{startScript:h} - - $(function() { - - // Send user notice if they click a non-inventory cell - $('.emCalDateCellNotice').click( function() { - alert('This is not within the date range for the {term.performance.norm}. To add inventory for this date, edit the {term.performance.norm} and change the start or end date.'); - }); - - // Toggle date cell on-off - $('.emCalDateCellSelectable').click( function() { - - var thisCell = $(this); - var thisId = $(this).attr('invId'); - var invStatus; - - // If the cell is currently selected - if (thisCell.hasClass("emCalDateCellSelected")) { - invStatus = 0; // Change to not selected - } else { - invStatus = 1; // Otherwise change to selected - } - - - $.ajax({ - url: "{adminURL}&Action=Ticket_setActive&TicketInventoryID=" + thisId + "&TicketInventoryStatus=" + invStatus, - success: function() { - // Update cell status display - if (invStatus == 1) { - thisCell.addClass('emCalDateCellSelected'); - } else { - thisCell.removeClass('emCalDateCellSelected'); - } - } , - error: function() { - alert( - 'There was an error while submitting this information.\n' + - 'The information may not have been updated.\n' + - 'Please try again later or call for support.' - ); - } - }); - - }); - - - // Pop-up calendar edit forms - $('.emCalDateEditIcon').click( function() { - - // get needed parameters - var dateTime = $(this).attr('calDate'); - var thisId = $(this).attr('invId'); - var thisTime = $('#ticket_time_' + dateTime).html(); - var thisQuant = $('#quant_' + dateTime).html(); - var thisAvail = $('#avail_' + dateTime).html(); - var thisSold = $('#sold_' + dateTime).html(); - - // Place edit form in cell edit container - $('#edit_'+dateTime).html(' \ -
    \ -
    \ - \ - \ - \ - {if:ticketDetail.unlimited_quant.value} -
    \ -
    Quantity:
    \ -
    Unlimited
    \ -
    \ - {else:} -
    \ -
    Quantity:
    \ - \ -
    \ -
    \ -
    Available:
    \ - \ -
    \ - {end:} -
    \ -
    Sold:
    \ - \ -
    \ -
    \ -
    \ -
    \ - '); - - // Start dialog pop-up - $('#calEdit').dialog({ - autoOpen: true, - modal: true, - position: { - my: "bottom", - at: "top", - of: "#" + dateTime - }, - buttons: { - "Update": function() { - - $('#calEditForm').addClass('emCalEditContainerHidden'); - $('#calEditPleaseWait').html('
    Storing, Please Wait...
    '); - - var tf = $(this); - - // Submit form - $('#calEditForm').ajaxForm({ - success: function(data) { - - // Copy data from pop-up back to selected calendar date - var valEditTime = $("#calEditTime").val(); - var valEditQuant = $("#calEditQuant").val(); - var valEditAvail = $("#calEditAvail").val(); - var valEditSold = $("#calEditSold").val(); - $('#ticket_time_' + dateTime).html( valEditTime ); - $('#quant_' + dateTime).html( valEditQuant ); - $('#avail_' + dateTime).html( valEditAvail ); - $('#sold_' + dateTime).html( valEditSold ); - - // Destroy dialog pop-up - tf.dialog( "close" ); - tf.dialog('destroy').remove(); - return false; - - } , - error: function() { - - // If the data was not able to be submitted - alert( - 'There was an error while submitting this information.\n' + - 'The information may not have been updated.\n' + - 'Please try again later or call for support.' - ); - - // Destroy dialog pop-up - tf.dialog( "close" ); - tf.dialog('destroy').remove(); - return false; - - } - }); - - // Kick ajaxForm submission - $('#calEditForm').submit(); - - } - } - }); - - return false; - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Ticket/inventoryNoCalendar.html b/legacy/views/admin/tickets/Ticket/inventoryNoCalendar.html deleted file mode 100755 index e755884..0000000 --- a/legacy/views/admin/tickets/Ticket/inventoryNoCalendar.html +++ /dev/null @@ -1,80 +0,0 @@ - -
    -
    -

    Editing {term.ticket.norm} inventory for all dates

    -

    This {term.ticket.norm} is not date specific.

    - {foreach:inventoryData,d} -
    - - - - - - - - {if:ticketDetail.unlimited_quant.value} - - {else:} - - - - - - - - - {end:} - - - - - -
    {term.performance.cap}:{ticketDetail.performance}
    {term.ticket.cap}:{ticketDetail.name}
    Quantity:
    UnlimitedInv ID: {d.id}
    Quantity:
    - - Inv ID: {d.id} -
    Available:
    Sold:
     
    -
    -
    {if:inventoryUpdated}Updated{end:}
    - {end:} - -
    - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.invEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#invEditForm').ajaxForm({ - beforeSend: function(e) { - $('#calEditPleaseWait').html('
    Storing, Please Wait...
    '); - }, - success: function(data) { - var container = $('#Ticket_info_container'); - f_replaceContents(data, container); - return false; - } - }); - - - }); - - diff --git a/legacy/views/admin/tickets/Ticket/list.html b/legacy/views/admin/tickets/Ticket/list.html deleted file mode 100644 index b6d3f5c..0000000 --- a/legacy/views/admin/tickets/Ticket/list.html +++ /dev/null @@ -1,166 +0,0 @@ - -
    - -
    -
    -{if:checkPermission(#10#)} - -{end:} - -
    - Search {term.ticket.plur_cap}: (start typing any information in list) - - {if:tickets} - -
    - - - - - - {if:option.packages} - - {end:} - - - - - - - - - - - - {foreach:tickets,c} - - - - {if:option.packages} - - {end:} - - - - - - - - - - {end:} - -
    Sort OrderTicket NameTypeActiveAdmin Only{term.prop.cap}{term.performance.cap}StickyShow on StartSectionTime
    {c.sort}{c.cart_sticky.name}{c.show_on_start.name}{c.section} - {if:c.time_specific.value} - {c.ticket_time.time} - {end:} -
    -
    - - {else:} -

    No {term.ticket.plur} listed.

    - {end:} - -
    -
    - -
    - -
    -{startScript:h} - - // Tickets Search - var ticketsSearchData = [ - {foreach:tickets,c} - {label:'{c.performance}, {c.name:h}, {c.section}, {c.ticket_time.time}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var TicketListTable = $('#TicketListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - "aoColumns" : [ - { sWidth: '80px', "sType": "numeric" }, - null, - null, - {if:option.packages} - null, - {end:} - null, - null, - null, - null, - null, - null, - { sWidth: '80px' } - ] - }); - $(window).resize(function(){ - TicketListTable.fnDraw(); - }); - - // Toggle length of table - var TicketListTableSmall = true; - var TicketListTableHeight = $('#TicketListTable_wrapper div.dataTables_scrollBody').height(); - $('#ticketListSizeChange').click(function() { - if (TicketListTableSmall) { - $('#TicketListTable_wrapper div.dataTables_scrollBody').height('auto'); - TicketListTableSmall = false; - $(this).html('Smaller Table'); - TicketListTable.fnSettings().oScroll.sY = '100%'; - TicketListTable.fnDraw(); - } else { - $('#TicketListTable_wrapper div.dataTables_scrollBody').height(TicketListTableHeight); - TicketListTableSmall = true; - $(this).html('Larger Table'); - TicketListTable.fnSettings().oScroll.sY = '100px'; - TicketListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#Ticket_detail').hide(duration); - - $('.ticketListSelect').click(function(){ - $('#TicketListTable_wrapper div.dataTables_scrollBody').height(TicketListTableHeight); - TicketListTableSmall = true; - $('#ticketListSizeChange').html('Larger Table'); - TicketListTable.fnSettings().oScroll.sY = '100px'; - TicketListTable.fnDraw(); - f_loadAction('Ticket_selected', 'Ticket_detail_container', 'TicketID=' + $(this).attr('emTicketId') + '&tabList={tabList}'); - }); - - // Search Tickets - $("#ticketsSearch").autocomplete({ - source: ticketsSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#ticketsSearch").attr({value: ui.item.label}); - f_loadAction('Ticket_selected', 'Ticket_detail_container', 'TicketID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/Ticket/selected.html b/legacy/views/admin/tickets/Ticket/selected.html deleted file mode 100755 index 0c520e3..0000000 --- a/legacy/views/admin/tickets/Ticket/selected.html +++ /dev/null @@ -1,74 +0,0 @@ -
    - -
    -
    {term.ticket.cap}: {ticketDetail.name}
    -
    - -
    - - -
    -{if:checkPermission(#30#)} - -{end:} -{if:checkPermission(#20#)} - -{end:} -{if:checkPermission(#10#)} - - -{end:} - -{if:checkPermission(#10#)} - {if:noTicketInventory} - - {else:} - - {end:} -{end:} -{if:checkPermission(#20#)} - -{end:} - -
    - - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with ticket detail loaded - f_loadAction('Ticket_detail', 'Ticket_info_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/User/index.html b/legacy/views/admin/tickets/User/index.html deleted file mode 100644 index 6d55633..0000000 --- a/legacy/views/admin/tickets/User/index.html +++ /dev/null @@ -1,85 +0,0 @@ - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - - - - - - - - - - - - - - - - - - - -
    - - - {if:option.tickets} - - - - - - {end:} - {if:option.events} - - {end:} - - - - -
    - - -
    - -
    - -
    - Gaslight Media - Event Management and Ticketing System -
    - - - - - - diff --git a/legacy/views/admin/tickets/User/loginForm.html b/legacy/views/admin/tickets/User/loginForm.html deleted file mode 100755 index 6ee438d..0000000 --- a/legacy/views/admin/tickets/User/loginForm.html +++ /dev/null @@ -1,105 +0,0 @@ - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - var debugWidth = {option.admin_debug_size}; - - - - - - - - - - - - - - - - - - - {config.owner.name} - -
    -
    -
    -
    {owner.name} Event Ticket System
    -

    - Please log in using your user E-Mail address or ID and your password. -

    -
    - - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    - {end:} - -
    -
    - - - - - - - - - - - - - -
    E-Mail Address or Log in ID:
    Password:
    - -
    - -
    - -
    -
    - -

    - This section of this Web site is for authorized persons only. - Tampering and unauthorized access will be reported. -

    - -
    -
    - -
    - Gaslight Media - Event Management System -
    - - {startScript:h} - - $(document).ready(function(){ - - $("#email").focus(); - - }); - - - - - - - - diff --git a/legacy/views/admin/tickets/VoucherCoupon/delete.html b/legacy/views/admin/tickets/VoucherCoupon/delete.html deleted file mode 100755 index f1f3f57..0000000 --- a/legacy/views/admin/tickets/VoucherCoupon/delete.html +++ /dev/null @@ -1,66 +0,0 @@ -
    - -
    Delete this {term.coupon.cap}
    - -
    {VoucherCouponDetail.name}
    - -
    - - -
    - - {if:voucherCouponDetail} -
    - - - - - - - - - - - - - - - - - - - - - - -
    Delete {term.coupon.cap}: -

    Clicking "Confirm Delete" on the right will permanently delete this {term.ticket.norm} add-on.

    -
    {term.coupon.cap}:{voucherCouponDetail.name:h}ID: {voucherCouponDetail.id}
    Type:{voucherCouponDetail.coupon_type.name:h}
    Active:{voucherCouponDetail.active.name}
    Position:{voucherCouponDetail.coupon_position.name:h}
    Display From:{voucherCouponDetail.display_from.date}
    Display To:{voucherCouponDetail.display_to.date}
    Image:
    Stretch to Fit:{voucherCouponDetail.stretch_to_fit.name}
    Padding:{voucherCouponDetail.padding}
    Show Border:{voucherCouponDetail.show_border.name}
    Maximum Display Count:{voucherCouponDetail.max_display_count}
    Current Display Count:{voucherCouponDetail.display_count}
    Notes:{voucherCouponDetail.notes:h}
    - {else:} -

    No {term.coupon.plur} found.

    - {end:} - -
    - -
    -{startScript:h} - $(document).ready(function(){ - - $('#VoucherCouponDeleteTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/VoucherCoupon/detail.html b/legacy/views/admin/tickets/VoucherCoupon/detail.html deleted file mode 100644 index 66ce610..0000000 --- a/legacy/views/admin/tickets/VoucherCoupon/detail.html +++ /dev/null @@ -1,76 +0,0 @@ -
    - - - -
    - - -
    - - {if:voucherCouponDetail} -
    - - - - {if:voucherCouponDetail.delete} - - - - - {end:} - - - - - - - - - - - - - - -
    Delete {term.coupon.cap}: - {if:voucherCouponDetail.deleteConfirmed} - {if:voucherCouponDetail.deleteFailure} -

    FAILED:

    - Sorry, we are unable to delete the entry at this time.
    - {voucherCouponDetail.reason:h} - {else:} -

    Deleted

    - {end:} - {else:} -
    -

    Clicking the button above will permanently delete this {term.coupon.norm}.

    - {end:} -
    {term.coupon.cap}:{voucherCouponDetail.name:h}ID: {voucherCouponDetail.id}
    Active:{voucherCouponDetail.active.name}
    Type:{voucherCouponDetail.coupon_type.name:h}
    Position:{voucherCouponDetail.coupon_position.name:h}
    Display From:{voucherCouponDetail.display_from.date}
    Display To:{voucherCouponDetail.display_to.date}
    Image:
    Stretch to Fit:{voucherCouponDetail.stretch_to_fit.name}
    Padding:{voucherCouponDetail.padding}
    Show Border:{voucherCouponDetail.show_border.name}
    Maximum Display Count:{voucherCouponDetail.max_display_count}
    Current Display Count:{voucherCouponDetail.display_count}
    Notes:{voucherCouponDetail.notes:h}
    -
    - {else:} -

    No {term.coupon.plur} found.

    - {end:} - - -
    -{startScript:h} - $(document).ready(function(){ - - $('#VoucherCouponDetailTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - f_restartOnTabSelect(); - - }); - diff --git a/legacy/views/admin/tickets/VoucherCoupon/edit.html b/legacy/views/admin/tickets/VoucherCoupon/edit.html deleted file mode 100755 index 594512e..0000000 --- a/legacy/views/admin/tickets/VoucherCoupon/edit.html +++ /dev/null @@ -1,283 +0,0 @@ -
    - -
    - {if:addingNewVoucherCoupon}Adding New {term.coupon.cap}{end:} - {if:editingVoucherCoupon}Editing {term.coupon.cap}{end:} -
    a - -
    -{if:addingNewVoucherCoupon} - -{else:} - -{end:} -
    - -{if:formFail} -
    Not all fields were filled in correctly. Please try again.
    -{end:} - -
    - - {if:voucherCouponDetail} - -

    Required fields in RED.

    - -
    - {if:addingNewVoucherCoupon} - - {else:} - - {end:} - - - - - -
    - - - - - {if:fieldRequired.name} - {if:fieldFail.name} - - - - - - - {if:fieldRequired.coupon_type} - {if:fieldFail.coupon_type} - - - {if:fieldRequired.coupon_position} - {if:fieldFail.coupon_position} - - - {if:fieldRequired.display_from} - {if:fieldFail.display_from} - - - {if:fieldRequired.display_to} - {if:fieldFail.display_to} - - - {if:fieldRequired.coupon_image} - {if:fieldFail.coupon_image} - - - - - - - {if:fieldRequired.padding} - {if:fieldFail.padding} - - - - - - - {if:fieldRequired.max_display_count} - {if:fieldFail.max_display_count} - - - {if:fieldRequired.display_count} - {if:fieldFail.display_count} - - - {if:fieldRequired.notes} - {if:fieldFail.notes} - - -
    {else:}{end:}{term.coupon.cap} Name:{else:}{end:} -
    - {if:fieldFail.name}
    {fieldFail.name}{end:} -
    This is for reference only, it is not displayed to users. -
    Active: - {if:voucherCouponDetail.active.value} - - {else:} - - {end:} -
    {else:}{end:}{term.coupon.cap} Type:{else:}{end:} - - {if:fieldFail.coupon_type}
    {fieldFail.coupon_type}{end:} -
    {else:}{end:}{term.coupon.cap} Position:{else:}{end:} - - {if:fieldFail.coupon_position}
    {fieldFail.coupon_position}{end:} -
    {else:}{end:}Display From:{else:}{end:} - {if:addingNewVoucherCoupon} - - {else:} - - {end:} - {if:fieldFail.display_from}
    {fieldFail.display_from}{end:} -
    {else:}{end:}Display To:{else:}{end:} - {if:addingNewVoucherCoupon} - - {else:} - - {end:} - {if:fieldFail.display_to}
    {fieldFail.display_to}{end:} -
    {else:}{end:}{term.coupon.cap} Image:{else:}{end:} - {if:voucherCouponDetail.coupon_image} - -
    Delete this image: - {end:} - -
    Upload or replace the image: - {if:fieldFail.coupon_image}
    {fieldFail.coupon_image}{end:} -
    Stretch to Fit: - {if:voucherCouponDetail.stretch_to_fit.value} - - {else:} - - {end:} -
    {else:}{end:}Padding:{else:}{end:} - - {if:fieldFail.padding}
    {fieldFail.padding}{end:} -
    This is the minimum amount of space between the image and all sides of the Ad/Coupon box.
    - The value is in the units displayed when you select the "Test" button at the upper-right. -
    Show Border: - {if:voucherCouponDetail.show_border.value} - - {else:} - - {end:} -
    {else:}{end:}Maximum Display Count:{else:}{end:} - - {if:fieldFail.max_display_count}
    {fieldFail.max_display_count}{end:} -
    Maximum number of times this {term.coupon.norm} will be included in a {term.voucher.norm}. Set to -1 for unlimited. -
    {else:}{end:}Current Display Count:{else:}{end:} - - {if:fieldFail.display_count}
    {fieldFail.display_count}{end:} -
    This is the number of times this {term.coupon.norm} has been included in a {term.voucher.norm}. -
    {else:}{end:}Notes:{else:}{end:} - - {if:fieldFail.notes}
    {fieldFail.notes}{end:} -
    -
    - -
    - {if:addingNewVoucherCoupon} - - {end:} - {if:editingVoucherCoupon} - - {end:} -
    - -
    - - {else:} -

    No {term.coupon.norm} has been selected yet.

    -

    To edit a {term.coupon.norm}, first select it from the list of available {term.coupon.plur}. - {end:} - -

    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.voucherCouponEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - /* - * AJAX form handling - */ - - $('#voucherCouponForm').ajaxForm({ - success: function(data) { - {if:addingNewVoucherCoupon} - var container = $('#VoucherCoupon_detail_container'); - f_replaceContents(data, container); - {end:} - {if:editingVoucherCoupon} - var container = $('#VoucherCoupon_detail_container'); - f_replaceContents(data, container); - {end:} - return false; - } - }); - - // Block default form submission - $("form").submit(function (e) { - $('#voucherCouponFormSubmit').html('
    Submitting, Please Wait...
    '); - e.preventDefault(); - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#notes")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#notes")); - }); - - f_restartOnTabSelect(); - - /* - * Date input operations - */ - - // Code to start datepicker for each date input - $("#displayFromInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{voucherCouponDetail.display_from.date_list.min}', - maxDate: '{voucherCouponDetail.display_from.date_list.max}' - }); - $("#displayToInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{voucherCouponDetail.display_to.date_list.min}', - maxDate: '{voucherCouponDetail.display_to.date_list.max}' - }); - - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/VoucherCoupon/list.html b/legacy/views/admin/tickets/VoucherCoupon/list.html deleted file mode 100644 index 78c12ec..0000000 --- a/legacy/views/admin/tickets/VoucherCoupon/list.html +++ /dev/null @@ -1,131 +0,0 @@ - -
    - -
    -
    -{if:checkPermission(#10#)} - - -{end:} - -
    - Search {term.coupon.plur_cap}: (start typing any information in list) - - {if:voucherCoupons} - -
    - - - - - - {foreach:voucherCoupons,c} - - - - - - - - - - - {end:} - -
    {term.coupon.cap}ActiveTypePositionFromToMaxCount
    -
    - - {else:} -

    No {term.coupon.plur}.

    - {end:} - -
    -
    - -
    - -
    -{startScript:h} - - // Voucher Coupons Search - var voucherCouponsSearchData = [ - {foreach:voucherCoupons,c} - {label:'{c.name:h}, {c.coupon_position.name:h}, {c.display_from.date}, {c.display_to.date}', value:'{c.id}'}, - {end:} - ]; - - $(function() { - - var VoucherCouponListTable = $('#VoucherCouponListTable').dataTable({ - "sScrollY": "100px", - "scrollX": true, - "bScrollCollapse": true, - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": true, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true, - }); - $(window).resize(function(){ - VoucherCouponListTable.fnDraw(); - }); - - // Toggle length of table - var VoucherCouponListTableSmall = true; - var VoucherCouponListTableHeight = $('#VoucherCouponListTable_wrapper div.dataTables_scrollBody').height(); - $('#voucherCouponListSizeChange').click(function() { - if (VoucherCouponListTableSmall) { - $('#VoucherCouponListTable_wrapper div.dataTables_scrollBody').height('auto'); - VoucherCouponListTableSmall = false; - $(this).html('Smaller Table'); - VoucherCouponListTable.fnSettings().oScroll.sY = '100%'; - VoucherCouponListTable.fnDraw(); - } else { - $('#VoucherCouponListTable_wrapper div.dataTables_scrollBody').height(VoucherCouponListTableHeight); - VoucherCouponListTableSmall = true; - $(this).html('Larger Table'); - VoucherCouponListTable.fnSettings().oScroll.sY = '100px'; - VoucherCouponListTable.fnDraw(); - } - }); - - // Close all local sliders - $('#VoucherCoupon_detail').hide(duration); - - $('.voucherCouponListSelect').click(function(){ - $('#VoucherCouponListTable_wrapper div.dataTables_scrollBody').height(VoucherCouponListTableHeight); - VoucherCouponListTableSmall = true; - $('#voucherCouponListSizeChange').html('Larger Table'); - VoucherCouponListTable.fnSettings().oScroll.sY = '100px'; - VoucherCouponListTable.fnDraw(); - f_loadAction('VoucherCoupon_selected', 'VoucherCoupon_detail_container', 'VoucherCouponID=' + $(this).attr('emVoucherCouponId') + '&tabList={tabList}'); - }); - - // Search Voucher Coupons - $("#voucherCouponsSearch").autocomplete({ - source: voucherCouponsSearchData, - minLength: 1, - focus: function(event, ui) { - // Don't auto fill on focus - return false; - }, - select: function(event, ui) { - $("#voucherCouponsSearch").attr({value: ui.item.label}); - f_loadAction('VoucherCoupon_selected', 'VoucherCoupon_detail_container', 'VoucherCouponID=' + ui.item.value + '&tabList={tabList}'); - return false; - } - }); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/VoucherCoupon/selected.html b/legacy/views/admin/tickets/VoucherCoupon/selected.html deleted file mode 100755 index 0094ebe..0000000 --- a/legacy/views/admin/tickets/VoucherCoupon/selected.html +++ /dev/null @@ -1,32 +0,0 @@ -
    - -
    -
    {term.coupon.cap}: {voucherCouponDetail.name}
    -
    - -
    - - -
    -
    - -
    - -
    - - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - // Start with ticket detail loaded - f_loadAction('VoucherCoupon_detail', 'VoucherCoupon_detail_container', "tabList={tabList}"); - - f_restartOnTabSelect(); - - }); - - diff --git a/legacy/views/admin/tickets/VoucherCoupon/test.html b/legacy/views/admin/tickets/VoucherCoupon/test.html deleted file mode 100755 index c7aff4b..0000000 --- a/legacy/views/admin/tickets/VoucherCoupon/test.html +++ /dev/null @@ -1,142 +0,0 @@ -
    - -
    - Test {term.coupon.plur_cap} -
    - -
    - -

    Required fields in RED.

    - -
    - -
    - - - - - - - - - - - - - - - - - - - - - - - - -
    {term.coupon.cap} Name: - -
    Active: - -
    {term.coupon.cap} Type: - -
    {term.coupon.cap} Position: - -
    Date: - -
    -
    - - - -
    - -
    - -
    - - -
    - -{startScript:h} - - $(function() { - - /* - * Table operations - */ - - $('.voucherCouponEditTable').dataTable({ - "bPaginate": false, - "bLengthChange": false, - "bFilter": false, - "bSort": false, - "bInfo": false, - "bAutoWidth": false, - "bDestroy": true - }); - - // Block default form submission - $("form").submit(function (e) { - var date = $('#date').val(); - var voucherWindow = window.open('{adminURL}&Action=Ticket_printSampleVoucher&testCoupons=true&date=' + date, - "voucherPrint", - "height=750,width=600,menubar=yes,toolbar=yes,alwaysRaised=yes,menu" - ); - return false; - }); - - /* - * CKeditor actions - */ - - // Code to kick off CKEditor for specific fields - f_buildCkeditor($("#notes")); - - // Remove the editors and store the data back in the textareas before the AJAX form submission - $('.emEditSubmit').click( function() { - f_removeCkeditor($("#notes")); - }); - - f_restartOnTabSelect(); - - /* - * Date input operations - */ - - // Code to start datepicker for each date input - $("#date").datepicker({ - dateFormat: "mm/dd/yy", - minDate: '{voucherCouponDetail.display_from.date_list.min}', - maxDate: '{voucherCouponDetail.display_from.date_list.max}' - }); - - // Print test vouchers - $('.voucherPrint').click(function(){ - var date = $(this).attr('emOrderID'); - var orderVerify = $(this).attr('emOrderVerify'); - var voucherWindow = window.open('{adminURL}&Action=Ticket_printSampleVoucher&testTicket={ticketDetail.id}', - "voucherPrint", - "height=750,width=600,menubar=yes,toolbar=yes,alwaysRaised=yes,menu" - ); - voucherWindow.focus(); - voucherWindow.print(); - return false; - }); - - - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/Welcome/index.html b/legacy/views/admin/tickets/Welcome/index.html deleted file mode 100644 index e2c8932..0000000 --- a/legacy/views/admin/tickets/Welcome/index.html +++ /dev/null @@ -1,60 +0,0 @@ -
    - -{if:userMemberID} -
    -
    {userMemberVenueName} {term.ticket.cap} Management System
    - {if:checkPermission(#10#)} -

    - For assistance with this system please call {owner.name} at {owner.phone} -

    - {else:} - - {end:} - -
    -{else:} -
    -
    Welcome to the Gaslight Media Event Management / Ticketing System.
    -

    - In an effort to provide our customers with the best possible service, Gaslight Media will from time to - time make improvements to this application and correct problems that we have noticed - or that have been reported to us. Updates will be posted here so that you can be aware of improvements. - As always, please let us know if you have any concerns, need any assistance, or would like to suggest new features. -

    -
    -
    -
    - -
    -
    -

    The following updates have been included in this version...

    -
      -
    • -

      - "Admin Only" Sales: There is now a tab at the upper-right of the Event Management / Ticketing System admin interface called - "Place an Order". When you click this, it will take you to the front-end of the the Event/Ticketing system to place an order. It - will also know that you are an admin user and will include certain categories and items that are not available to regular - users. To specify which items you would like to mark as "Admin Only", select either the "Categories" or "Items" tab, select - the desired entry from the list, edit that entry and check the "Purchase by Admin Only" checkbox then save by clicking the Update button. -

      -

      - Note that when you are in the front end as an "Admin" user, you will see the "Purchasing By Admin User" banner across the top of each - page. -

      -
    • -
    -
    -
    -
    -{end:} - -
    - -{startScript:h} - - // jQuery Section - $(document).ready(function(){ - - }); - - \ No newline at end of file diff --git a/legacy/views/admin/tickets/index.html b/legacy/views/admin/tickets/index.html deleted file mode 100644 index 4630d9f..0000000 --- a/legacy/views/admin/tickets/index.html +++ /dev/null @@ -1,155 +0,0 @@ - - - - {startScript:h} - - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAdminURL = '{baseAdminURL}'; - var appAdminURL = '{appAdminURL}'; - var memberUser = '{MemberUser}'; - var debugEnabled = {if:option.admin_debug}true{else:}false{end:}; - var debugWidth = {option.admin_debug_size}; - var startWithClaims = {startWithClaims}; - - - - - - - - - - - - - - - - - - - {if:userMemberID} -

    - Logged in: {memberName} (Logout) - -

    - {end:} - - -
    - - {if:userMemberID} - - {else:} - - {end:} - {if:option.tickets} - - - - - -
    - - - -
    - {end:} - {if:option.events} - -
    - {end:} - - - - - -
    - - -
    - -
    - -
    - -{if:userMemberID} - {userMemberVenueName} {term.ticket.cap} Management System
    - {if:checkPermission(#10#)} - For assistance with this system please call {owner.name} at {owner.phone} - {else:} - - {end:} -{else:} - - Gaslight Media - Event Management and Ticketing System -{end:} -
    - - {startScript:h} - - $(function() { - - if (startWithClaims) { - f_loadAction('Sold_claim', 'Main_container', "tabList="); - $('#claimStatusTab').addClass('emTabSelected'); - } - - }); - - // Link to front-end ticket ordering - $('#placeOrder').click( function() { - window.open('{frontEndOrderLink}?adminUserCheck={adminUserFrontLinkCheck}','_blank'); - }); - - - - - - - - - diff --git a/legacy/views/front/FoundationStandAlone/Debug/index.html b/legacy/views/front/FoundationStandAlone/Debug/index.html deleted file mode 100755 index 6af2dc9..0000000 --- a/legacy/views/front/FoundationStandAlone/Debug/index.html +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Front-End Debug
    -
    -
    - Updated: {debugUpdateTime} -
    -
    - {debugData:h} -
    - - - - - {startScript:h} - - // Reload the current window with Action = Debug_update - function reloadDebugWindow() - { - window.location("{baseSCRIPT}&Action=Debug_update"); - } - - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Debug/start.html b/legacy/views/front/FoundationStandAlone/Debug/start.html deleted file mode 100755 index 66c3023..0000000 --- a/legacy/views/front/FoundationStandAlone/Debug/start.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Front-End Debug
    -
    -
    Debug Startup
    - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Shop/PayPalApproved.html b/legacy/views/front/FoundationStandAlone/Shop/PayPalApproved.html deleted file mode 100755 index 323197a..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/PayPalApproved.html +++ /dev/null @@ -1,41 +0,0 @@ - - - - - -
    - -

    Your PayPal payment has been approved.

    - - -
    - -

    - Your cart will now reflect that the payment has been made. -

    - -
    - -
    -
    Close This Window
    -
    - -
    - - - - diff --git a/legacy/views/front/FoundationStandAlone/Shop/PayPalFail.html b/legacy/views/front/FoundationStandAlone/Shop/PayPalFail.html deleted file mode 100755 index 18feaa0..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/PayPalFail.html +++ /dev/null @@ -1,49 +0,0 @@ - - - - - -
    - -

    Unable to process your payment!

    - - -
    - -

    -

    Sorry, there was a problem.
    -

    - -

    - We were unable to find your purchase information and are therefore - are unable to process your payment through PayPal. This could be - due to you not performing any action with your pending purchase - for too long. Please click the "Return to selected tickets" button - at the top of the checkout page to see if your selections are still listed. -

    - -
    - -
    -
    Close This Window
    -
    - -
    - - - - diff --git a/legacy/views/front/FoundationStandAlone/Shop/additionalInfo.html b/legacy/views/front/FoundationStandAlone/Shop/additionalInfo.html deleted file mode 100644 index 96dc231..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/additionalInfo.html +++ /dev/null @@ -1,246 +0,0 @@ - - - -
    - - - -
    -
    - - - {term.nav.show_selected} - {if:!option.ticket_shop.start_at_cart} - {term.nav.select_more} - {end:} - - -

    {cartText:h}

    - -
    -
    - -{if:reason} - - - -
    -
    -
    -

    We're sorry, we had a problem with your request:

    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - - - -{foreach:cart,c} - - {if:option.show_location_blocks} -
    -
    -
    -
    -

    {c.name:h}

    -
    - {end:} - - - - - {if:c.needAssignemntOrDate} - {if:c.needAssignment} - -
    - {if:!c.haveAssignment} -
    {text.cart.select_assignment_location}
    - {else:} -
    {text.cart.select_assignment_location}
    - {end:} - {foreach:c.assignmentMembers,a} - {if:a.entrances} - {foreach:a.entrances,e} -
    - {if:option.cart_images} - {if:e.image} -
    - {end:} - {end:} -
    - {if:e.selected} - {a.name} - {e.name}
    - {else:} - {a.name} - {e.name}
    - {end:} -
    -
    {e.addr1}{if:e.addr2}, {e.addr2}{end:}, {e.city}
    -
    {e.phone}
    - {if:e.descr} -
    {e.descr:h}
    - {end:} -
    -
    - {end:} -
    - {else:} - {if:a.selected} - {a.name}
    - {else:} - {a.name}
    - {end:} - {end:} - {end:} -  
    - {end:} - - {if:option.ask_for_likely_date} - {if:c.needLikelyDate} -
    -

    - {if:!c.likelyDate} - - {else:} - - {end:} - {text.cart.select_likely_date}   - - mm/dd/yyyy - {if:text.cart.select_likely_date_explain} -
    {text.cart.select_likely_date_explain} - {end:} -

    -
    - {end:} - {end:} -
    -
    - {end:} - {if:!c.needAssignment} - - {if:option.cart_images}{if:c.image} -
    - - -
    - {end:}{end:} - {end:} - -
    -
    -
    - -{end:} - - - -{if:cartHasContents} -
    -
    - {if:!blockCheckout} - {term.nav.checkout} - {else:} - Please complete the items in RED above. - {end:} -
    -
    -{else:} -
    -
    -

    Your cart is currently empty.

    -
    -
    -{end:} - - - - - - - - - diff --git a/legacy/views/front/FoundationStandAlone/Shop/cart.html b/legacy/views/front/FoundationStandAlone/Shop/cart.html deleted file mode 100755 index 31268cb..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/cart.html +++ /dev/null @@ -1,670 +0,0 @@ - - - -
    - - - -
    -
    - - - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} - - -

    {cartText:h}

    - -
    -
    - -{if:reason} - - - -
    -
    -
    - We're sorry, we had a problem with your request: -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - -{if:havePromoCodes} - - - -
    -
    - If you have a {term.promo.norm}, please enter it here: - Enter {term.promo.cap} here: -
    -
    - -
    -
    - -{end:} - - - -{foreach:cart,c} - - {if:option.show_location_blocks} -
    -
    -
    -
    -
    {c.name:h}
    -
    - {end:} - - - - {foreach:c.performances,p} -
    -
    -
    - - - -
    -
    - {if:!option.ticket_shop.start_at_cart} - {term.nav.select_more_of_these} - {end:} - - {p.name:h} - -
    -
    - - - -
    -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    - {if:option.ticket_shop.cart.show_performance_image} - {if:p.image} - -
    - -
    - -
    - -
    - {end:} - {end:} -
    - - - - {foreach:p.dates,d} -
     
    -
    -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    -
    - - - - {foreach:d.sections,s} -
    -
    Quant
    - {if:!p.oneSectionOnly} -
    {term.section.cap}
    -
    - {else:} -
    - {end:} - {term.ticket.cap} -
    -
    Price
    -
    Sub-Total
    -
    - - - - {foreach:s.tickets,i} - - - -
    -
    - -
    - {if:!p.oneSectionOnly} -
    {s.name:h}
    -
    - {else:} -
    - {end:} - {i.title} - {if:i.required_addon_not_supplied} -
    - At least one item below is required. - {end:} -
    -
    {if:i.show_price}{i.price}{end:}
    -
    {if:!i.show_addons}{if:i.show_price}{i.extended}{end:}{end:}
    -
    - - - -
    -
    -
    {i.title}
    -
    - {if:i.problem} -
    -
    -
    {i.problemText}
    -
    -
    - {end:} - {if:i.descr} - - -
    -
    -
    - {if:option.ticket_shop.cart.show_ticket_image} - {if:i.image} - - {end:} - {end:} - {i.descr:h} -
    -
    - {end:} - - {if:!p.oneSectionOnly} -
    -
    {term.section.cap}:
    -
    {s.name:h}
    -
    - {end:} -
    -
    Quant:
    -
     
    -
    - -
    -
    - {if:i.price_numb} -
    -
    Price:
    -
    {if:i.show_price}{i.price}{end:}
    -
    - {end:} - {if:!i.show_addons} -
    -
    Sub-Total:
    -
    {if:i.show_price}{i.extended}{end:}
    -
    - {end:} -
    - {if:option.packages} - {foreach:i.packageData,y} -
    -
     
    -
    - {y.quant} -
    -
    - {y.title} - {y.performance_name} -
    -
    - {end:} - {end:} - {if:i.descr} - - -
    -
    -
    - {if:option.ticket_shop.cart.show_ticket_image} - {if:i.image} - - {end:} - {end:} - {i.descr:h} -
    -
    - {end:} - - - - {if:i.show_addons} - {foreach:i.addons,a} - - - -
    -
     
    -
    - -
    -
    {a.name}
    -
    {a.unit_cost}/{a.unit_name:h}
    -
    -
    - - - -
    -
    -

    {a.name}

    -
    -
    -
    Quant:
    -
     
    -
    - -
    -
    -
    -
    Price:
    -
    {a.unit_cost}/{a.unit_name:h}
    -
    - -
    - - {end:} -
     
    -
    -
    Sub-Total:
    -
    {i.extended}
    -
    -
     
    - {end:} - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    -
    -
    Promo:
    -
    {promoCode}:
    -
    {i.promo.credit}
    -
    - - {end:} - - {end:} - - {end:} - - {end:} - -
    -
    -
    - - {end:} - - - - {if:!option.ticket_shop.additionalInfo.use_page} - - {if:c.needAssignemntOrDate} - {if:c.needAssignment} - -
    - {if:!c.haveAssignment} -
    {text.cart.select_assignment_location}
    - {else:} -
    {text.cart.select_assignment_location}
    - {end:} - {foreach:c.assignmentMembers,a} - {if:a.entrances} - {foreach:a.entrances,e} -
    - {if:option.cart_images} - {if:e.image} -
    - {end:} - {end:} -
    - {if:e.selected} - {a.name} - {e.name}
    - {else:} - {a.name} - {e.name}
    - {end:} -
    -
    {e.addr1}{if:e.addr2}, {e.addr2}{end:}, {e.city}
    -
    {e.phone}
    - {if:e.descr} -
    {e.descr:h}
    - {end:} -
    -
    - {end:} -
    - {else:} - {if:a.selected} - {a.name}
    - {else:} - {a.name}
    - {end:} - {end:} - {end:} -  
    - {end:} - - {if:option.ask_for_likely_date} - {if:c.needLikelyDate} -
    - {if:!c.likelyDate} - - {else:} - - {end:} - {text.cart.select_likely_date}   - - mm/dd/yyyy -
    - {end:} - {end:} -
    -
    - {end:} - {if:!c.needAssignment} - - {if:option.cart_images}{if:c.image} -
    - - -
    - {end:}{end:} - {end:} - {end:} - -{if:c.no_payment} -
    -
    -

    - No payment is being processed for these {term.ticket.plur}.
    Payment for these items must be arranged directly with {owner.name}. -

    -
    -
    -{end:} - - {if:option.show_location_blocks} -
    -
    -
    - {end:} - -{end:} - - - -{if:cartHasContents} -
    -
    -

    - Grand Total {totals.grand_total_price} -

    -
    -
    -
    -
    - {if:blockCheckoutMixedPayment} - Please read the message at the top of this page. - {else:} - - {if:option.ticket_shop.additionalInfo.use_page} - {if:blockCheckoutNonAssignment} - Please complete the items in RED above. - {else:} - {if:doingAdditionalInfo} - {term.nav.additional_info} - {else:} - {term.nav.checkout} - {end:} - {end:} - {else:} - {if:!blockCheckout} - {term.nav.checkout} - {else:} - Please complete the items in RED above. - {end:} - {end:} - {end:} -
    -
    -{else:} -
    -
    -

    Your cart is currently empty.

    -
    -
    -{end:} - - - -{if:option.cart_promotions} - -
    -
    You may also be interested in ...
    -
    - -
    -
    -
    - {foreach:cartPromotions,p} -
    - - {if:p.image} -
    - -
    - {end:} -
    - {if:p.short_descr}{p.short_descr:h}{end:} -
    - {if:option.ticket_shop.cart.show_promotion_images} -
    - {if:p.image} - - {end:} -
    - {end:} -
    - {end:} -
    -
    -
    -{end:} - - - - - - - - - diff --git a/legacy/views/front/FoundationStandAlone/Shop/checkout.html b/legacy/views/front/FoundationStandAlone/Shop/checkout.html deleted file mode 100755 index 4ad59ec..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/checkout.html +++ /dev/null @@ -1,1159 +0,0 @@ - - - -
    - - - - -
    -
    - - - {term.nav.show_selected} - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} - - -

    {checkoutText:h}

    - -
    -
    - -{if:reason} -
    -
    -
    - We're sorry, we had a problem with your request: -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - - -
    -
    -
    -
    -
    - Contact Information -
    -
    -
    -
    -
    -
    - {if:formData.contact.fname.required}
    -
    -
    -
    - {if:formData.contact.lname.required}
    -
    -
    -
    - {if:formData.contact.addr1.required}
    -
    -
    -
    - {if:formData.contact.addr2.required}
    -
    -
    -
    - {if:formData.contact.city.required}
    -
    -
    -
    - {if:formData.contact.state.required}
    -
    -
    -
    - {if:formData.contact.country.required}
    -
    -
    -
    - {if:formData.contact.zip.required}
    -
    -
    -
    -
    -
    - {if:formData.contact.phone.required}
    -
    -
    -
    - {if:formData.contact.email.required}
    -
    -
    -
    - {if:formData.contact.email2.required}
    -
    -
    -
    - -
    -
    -
    -
    - {if:formData.contact.email_ok} -
    - {else:} -
    - {end:} -
    -
    - {if:opt_field_1_name} -
    -
    - {if:formData.contact.opt_field_1.required}
    -
    - {end:} - {if:opt_field_2_name} -
    -
    - {if:formData.contact.opt_field_2.required}
    -
    - {end:} - {if:opt_field_3_name} -
    -
    - {if:formData.contact.opt_field_3.required}
    -
    - {end:} -
    -
    -
    -
    -
    - - - -{foreach:cart,c} - - {if:option.show_location_blocks} -
    -
    -
    -
    -
    - {c.name:h} -
    -
    - {end:} - - - - {foreach:c.performances,p} - -
    -
    -
    - - - -
    -
    -

    {p.name:h}

    -
    -
    - - - -
    -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    -
    - - - - {foreach:p.dates,d} -
     
    -
    -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    -
    - - - - {foreach:d.sections,s} -
    -
    - Quant -
    - {if:!p.oneSectionOnly} -
    - {term.section.cap} -
    -
    - {else:} -
    - {end:} - {term.ticket.cap} -
    -
    - Price -
    -
    - Sub-Total -
    -
    - - - - {foreach:s.tickets,i} -
    -
    - {i.selected} -
    - {if:!p.oneSectionOnly} -
    - {s.name:h} -
    -
    - {else:} -
    - {end:} - {i.title} -
    -
    - {if:i.show_price}{i.price}{end:} -
    -
    - {if:!i.show_addons}{if:i.show_price}{i.extended}{end:}{end:} -
    -
    - {if:option.packages} -
    Includes:
    - {foreach:i.packageData,y} -
    -
     
    -
    - {y.quant} -
    -
    - {y.title} - {y.performance_name} -
    -
    - {end:} -
     
    - {end:} - - - - {if:i.descr} -
    -
    -
    - {i.descr:h} -
    -
    - {end:} - - - - {foreach:i.addons,a} -
    -
     
    -
    - {a.selected} -
    -
    - {a.name} -
    -
    - {a.unit_cost}/{a.unit_name:h} -
    -
    - -
    -
    - {end:} - - {if:i.show_addons} -
    -
     
    -
    -   -
    -
    - {i.extended} -
    -
    - {end:} - - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    - {end:} - - {end:} - - {end:} - - {end:} - - {if:p.policy} -
    -
    -

     

    -
    Please read and agree to our policy for this {term.performance.norm}.
    -

    {p.policy:h}

    - -
    -
    - {end:} - -
    -
    -
    - - {end:} - - - - {foreach:c.performances,p} - -
    -
    -
    - - - -
    -
    -

    {p.name:h}

    -
    -
    - - - -
    -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    -
    - - - - {foreach:p.dates,d} -
     
    -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    - - - - {foreach:d.sections,s} - {if:!p.oneSectionOnly} -
    -
    - {term.section.cap}: {s.name:h} -
    -
    - {end:} - - - - {foreach:s.tickets,i} -
    -
    -

    {i.title}

    -
    -
    - {if:i.descr} -
    -
    -
    - {i.descr:h} -
    -
    - {end:} - -
    -
    - Quant -
    -
    {i.selected}
    - {if:i.show_price} -
    - Price -
    -
    {i.price}
    -
    - Sub-Total -
    -
    {if:!i.show_addons}{i.extended}{end:}
    - {end:} -
    - - - - {foreach:i.addons,a} -
    -
    - {a.name} -
    -
    {a.selected}
    -
    -
    -
    - {a.unit_cost}/{a.unit_name:h} -
    -
    {a.money}
    -
    - {end:} - - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    - {end:} - {if:i.show_addons} -
    -
    - Sub-Total -
    -
    {i.extended}
    -
    - {end:} - - {end:} - - {end:} - - {end:} - - {if:p.policy} -
    -
    -

     

    -
    Please read and agree to our policy for this {term.performance.norm}.
    -

    {p.policy:h}

    - -
    -
    - {end:} - -
    -
    -
    - - {end:} - - {if:c.ticket_spec_req.value} -
    -
    - -
    -
    - {end:} - -{if:cartRequiresPayment} - {if:!formData.centralPayment} - - -
    -
    -
    -
    -
    -
    Payment for {term.ticket.plur} at {c.name:h}
    -
    -
    -
    {c.totalPrice}
    -
    -
    -
    -
    -   -
    -
    - - {if:c.paymentResult} - {if:c.paymentResult.approved} -
    -
    - Card Payment Approved -
    -
    -
    -
    - Name on Card: -
    -
    - {c.paymentResult.ccname} -
    -
    -
    -
    - Card Type: -
    -
    - {c.paymentResult.cctype} -
    -
    -
    -
    - Card Number: -
    -
    - {c.paymentResult.ccnumb} -
    -
    -
    -
    - Expiration Date: -
    -
    - {c.paymentResult.ccexp} -
    -
    -
    -
    - Authorization Code: -
    -
    - {c.paymentResult.authCode} -
    -
    - - {else:} -
    -
    -
    Card Payment Not Complete
    -
    -
    -
    -
    -

    {c.paymentResult.description}

    -

    Please check the payment information below and try again or contact your credit card company for assistance.

    - {if:forceCheckoutPhase} - {term.nav.delete_from_cart} - {end:} -
    -
    - {end:} - - {else:} - - {if:c.havePaymentMethod} -
    -
    - {if:c.haveMultiplePaymentMethods} -  PayPal - {else:} - - {end:} -
    -
    - - {if:c.haveCreditCards} -
    -
    - {if:c.haveMultiplePaymentMethods} -  Credit Card - {else:} - - {end:} -
    -
    -
    -
    - {if:c.paymentForm.cctype.required}
    -
    -
    -
    -
    - {if:c.paymentForm.ccname.required}
    -
    -
    -
    - {if:c.paymentForm.ccnumb.required}
    -
    -
    -
    -
    -
    -
    - {if:c.paymentForm.ccexp.required}
    -
    - {if:c.paymentForm.ccexp.required}
    -
    - {if:c.paymentForm.ccexp.problem} - {c.paymentForm.ccexp.problem} - {end:} -
    -
    -
    -
    - {if:c.paymentForm.cccode.required}
    -
    -
    -
    -
    - The Security Code is the three or four digit number on the signature side of your credit card. -
    -
    - {end:} - - {if:c.havePayPal} -
    -
    - -
    -
    - {end:} - - {end:} - - {end:} - -
    -
    -
    - - {end:} -{end:} - {if:c.no_payment} - -
    -
    -

    - - No payment is being processed for these {term.ticket.plur} at this time.
    Payment for these items must be arranged directly with {owner.name}. -

    -
    -
    - - {end:} - - {if:option.show_location_blocks} -
    -
    -
    - {end:} -{end:} - -{if:cartRequiresPayment} -{if:formData.centralPayment} - - {if:formData.centralPayment.havePaymentMethod} - -
    -
    -
    - -
    -
    -

    - Total Charged {totals.price} -

    -
    -
    - -
    -
    - {if:formData.centralPayment.haveMultiplePaymentMethods} -  PayPal - {else:} - - {end:} -
    -
    - - {foreach:formData.centralPayment.paymentForm,p} - {if:formData.centralPayment.haveCreditCards} -
    -
    - {if:formData.centralPayment.haveMultiplePaymentMethods} -  Credit Card - {else:} - - {end:} -
    -
    -
    -
    - {if:p.ccname.required}
    -
    -
    -
    - {if:p.cctype.required}
    -
    -
    -
    -
    - {if:p.ccnumb.required}
    -
    -
    -
    -
    -
    -
    - {if:p.ccexp.required}
    -
    - {if:p.ccexp.required}
    -
    - {if:p.ccexp.problem} - {p.ccexp.problem} - {end:} -
    -
    -
    -
    - {if:p.cccode.required}
    -
    -
    -
    -
    - The Security Code is the three or four digit number on the signature side of your credit card. -
    -
    - {end:} - {end:} - - {if:formData.centralPayment.havePayPal} -
    -
    - -
    -
    - {end:} - - {else:} -
    -
    -

    - No payment is being processed at this time. Payment for these items must be arranged directly with {owner.name}. -

    -
    -
    - - {end:} - -
    -
    -
    - - -{else:} - -
    -
    - Total Charged {totals.price} - {if:!cartHasOneVenueOnly} -

    NOTE: There will be a separate credit card transaction for each {term.prop.norm}.

    - {end:} -
    -
    - -{end:} -{end:} - -
    -
    - {ssl_seal_head_script:h} - {ssl_seal_body_script:h} -
    -
    - {if:!blockCheckout} - {term.nav.purchase} - {else:} - Unable to checkout - please see above. - {end:} -
    -
    - - - - - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Shop/checkoutSuccess.html b/legacy/views/front/FoundationStandAlone/Shop/checkoutSuccess.html deleted file mode 100755 index 820bf82..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/checkoutSuccess.html +++ /dev/null @@ -1,638 +0,0 @@ - - - -{if:checkoutSucccessText} -
    -
    - -

    {checkoutSuccessText:h}

    -
    -
    -{end:} - -
    -
    - Purchase Complete -
    -
    - - - -
    -
    -
    -
    -
    - {foreach:cart,c} - {if:c.paymentResult} - {if:c.paymentResult.approved} -

    - CLick Here to download and PRINT your order
    summary and VOUCHERS for {c.name}

    - CLick Here to download your non-printable
    order summary and MOBILE FRIENDLY VOUCHERS
    -

    - {end:} - {end:} - {end:} -
    -
    - {foreach:cart,c} - {if:c.paymentResult} - {if:c.paymentResult.approved} -

    - CLick Here to download your non-printable
    MOBILE FRIENDLY VOUCHERS
    for {c.name}
    - CLick Here to download and PRINT
    your order summary and VOUCHERS
    for {c.name}

    -

    - {end:} - {end:} - {end:} -
    -
    -
    -
    - Adobe Reader is required to view and print your {term.voucher.plur}. Adobe Reader is a free program available directly from Adobe. - If you do not already have Adobe Reader installed, click the "Get Adobe Reader" link now. -
    -
    - -
    -
    - - If you are unable to print your {term.voucher.plur}, please print this page or write down the order number(s) - below and bring that to the ticket office when you arrive. - -
    -
    - ORDER #: - {foreach:cart,c} - {if:c.paymentResult} - {if:c.paymentResult.approved} - {c.paymentResult.orderID}  - {end:} - {end:} - {end:} -
    -
    -
    -
    -
    - - - -
    -
    -
    -
    -
    - Contact Information -
    -
    -
    -
    - Name: -
    -
    - {formData.contact.fname.value} {formData.contact.lname.value} -
    -
    -
    -
    - {text.cart.checkout.address}: -
    -
    - {formData.contact.addr1.value}
    - {if:formData.contact.addr2.value} - {formData.contact.addr2.value}
    - {end:} - {formData.contact.city.value}, {formData.contact.state.name} {formData.contact.zip.value}
    - {formData.contact.country.name} -
    -
    -
    -
    - {text.cart.checkout.phone}: -
    -
    - {formData.contact.phone.value} -
    -
    -
    -
    - {text.cart.checkout.email}: -
    -
    - {formData.contact.email.value} -
    -
    -
    -
    - OK to Send E-Mail?: -
    -
    - {if:formData.contact.email_ok} - You have asked us to send information on activities and offers. - {else:} - You have asked us to NOT send information on activities and offers. - We will only contact you regarding this order. - {end:} -
    -
    - {if:opt_field_1_name} -
    -
    - {opt_field_1_name}: -
    -
    - {formData.contact.opt_field_1.value} -
    -
    - {end:} - {if:opt_field_2_name} -
    -
    - {opt_field_2_name}: -
    -
    - {formData.contact.opt_field_2.value} -
    -
    - {end:} - {if:opt_field_3_name} -
    -
    - {opt_field_3_name}: -
    -
    - {formData.contact.opt_field_3.value} -
    -
    - {end:} - -
    -
    -
    - - - -{foreach:cart,c} - {if:!c.centralPaymentOnly} - - {if:option.show_location_blocks} -
    -
    -
    -
    -
    - {c.name:h} -
    -
    - {end:} - - - - {foreach:c.performances,p} -
    -
    -
    - - - -
    -
    -

    {p.name:h}

    -
    -
    - - - -
    -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    -
    - - - - {foreach:p.dates,d} -
    -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    -
    - - - - {foreach:d.sections,s} -
    -
    - Quant -
    - {if:!p.oneSectionOnly} -
    - {term.section.cap} -
    -
    - {term.ticket.cap} -
    - {else:} -
    - {term.ticket.cap} -
    - {end:} -
    - Price -
    -
    - Total -
    -
    - - - - {foreach:s.tickets,i} -
    -
    Quant
    -
    {i.selected}
    -
    {i.selected}
    - {if:!p.oneSectionOnly} -
    {term.section.cap}
    -
    {s.name:h}
    -
    {term.ticket.cap}
    -
    {i.name:h}
    - {else:} -
    {term.ticket.cap}
    -
    {i.name:h}
    - {end:} -
    Price
    -
    {i.price}
    -
    {i.price}
    -
    Total
    -
    {i.extended}
    -
    {i.extended}
    -
    - {if:option.packages} -
    Includes:
    - {foreach:i.packageData,y} -
    -
     
    -
    - {y.quant} -
    -
    - {y.title} - {y.performance_name} -
    -
    - {end:} -
     
    - {end:} - - - - {if:i.descr} -
    -
    -
    - {i.descr:h} -
    -
    - {end:} - - - - {foreach:i.addons,a} -
    -
     
    -
    Quant
    -
    {a.selected}
    -
    {a.selected}
    - -
    {term.ticket.cap}
    -
    {a.name:h}
    - -
    Price
    -
    {a.unit_cost}/{a.unit_name:h}
    -
    {a.unit_cost}/{a.unit_name:h}
    - -
    Total
    -
    {a.money}
    -
    {a.money}
    -
    - {end:} - - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    - {end:} - - {end:} - - {end:} - - {end:} - - {if:p.policy} - - - -
    -
    -

    {p.policy:h}

    -
    -
    - {end:} - -
    -
    -
    - - {end:} - - {if:c.paymentForm.spec_req.value} - - - -
    -
    - {c.paymentForm.spec_req.value:h} -
    -
    - {end:} - - {if:!formData.centralPayment} - - -
    -
    -
    -
    -
    - Payment for {term.ticket.plur} at {c.name:h} -
    -
    -
    {c.totalPrice}
    -
    -
    - {if:c.paymentResult.cctype} -
    -
    -   -
    -
    -
    -
    - Card Payment Approved -
    -
    -
    -
    - Card Type: -
    -
    - {c.paymentResult.cctype} -
    -
    -
    -
    - Name on Card: -
    -
    - {c.paymentResult.ccname} -
    -
    -
    -
    - Card Number: -
    -
    - {c.paymentResult.ccnumb} -
    -
    -
    -
    - Expiration Date: -
    -
    - {c.paymentResult.ccexp} -
    -
    -
    -
    - Authorization Code: -
    -
    - {c.paymentResult.authCode} -
    -
    - {else:} -
    -
    -

    *** Payment Processed Manually ***

    -
    -
    - {end:} -
    -
    -
    - - {end:}) - - - {if:c.ticket_policy} -
    -
    - {c.ticket_policy:h} -
    -
    - {end:} - - {if:option.show_location_blocks} -
    -
    -
    - {end:} - - {end:} -{end:} - - -{if:formData.centralPayment} -
    -
    -
    - -
    -
    -

    - Grand Total {totals.price} -

    -
    -
    - - {foreach:cart,c} - {if:c.paymentResult.cctype} -
    -
    - Card Payment Approved -
    -
    -
    -
    - Card Type: -
    -
    - {c.paymentResult.cctype} -
    -
    -
    -
    - Name on Card: -
    -
    - {c.paymentResult.ccname} -
    -
    -
    -
    - Card Number: -
    -
    - {c.paymentResult.ccnumb} -
    -
    -
    -
    - Expiration Date: -
    -
    - {c.paymentResult.ccexp} -
    -
    -
    -
    - Authorization Code: -
    -
    - {c.paymentResult.authCode} -
    -
    - {else:} - {if:c.isCentralPaymentMember} -
    -
    -

    *** Payment Processed Manually ***

    -
    -
    - {end:} - {end:} - - {end:} - -
    -
    -
    - - -{else:} - - -
    -
    - Grand Total {totals.price}
    -{if:!cartHasOneVenueOnly} -

    NOTE: You will see a separate credit card transaction for each {term.prop.norm} above.

    -{end:} -
    -
    - -{end:} - - - - - - - - - - - - - - - - - -{trackingScript:h} - - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Shop/paymentSummary.html b/legacy/views/front/FoundationStandAlone/Shop/paymentSummary.html deleted file mode 100755 index 9e277c8..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/paymentSummary.html +++ /dev/null @@ -1,108 +0,0 @@ -

    - - Save/Print Order Summary and Boarding Passes PDF - -
    - - Download Mobile-Friendly Boarding Passes PDF - - -

    - -

    - {term.ticket.plur_cap} Purchased at:
    - {cartEntry.name} -

    - - -{if:cartEntry.descr}

    {cartEntry.descr:h}

    {end:} - - - - - - - - - - - -{foreach:cartEntry.performances,p} - {foreach:p.dates,d} - {foreach:d.sections,s} - - - {foreach:s.tickets,i} - - - - - - - - {foreach:i.addons,a} - - - - - - - - {end:} - {if:i.promo} - - - - - - - {end:} - {end:} - - - {end:} - {end:} -{end:} - - - - - - - - -
    Quant{term.performance.cap}{term.ticket.cap}PriceTotal
    {i.selected}{p.name:h}{i.title:h}{if:i.show_price}{i.price}{end:}{if:i.show_price}{i.extended}{end:}
       -
    - {a.selected} {a.unit_name} -
    -
    {a.unit_cost}/{a.unit_name}{a.money}
      {term.promo.cap}: {promoCode}  - {i.promo.credit}
     {cartEntry.totalPrice}
    - - -{if:cartEntry.ticket_spec_req} -

    - Special requests: {cartEntry.paymentForm.spec_req.value:h} -

    -{end:} - - -{if:cartEntry.ticket_policy}

    {cartEntry.ticket_policy:h}

    {end:} - -

    - - - - - - - -
    Credit Card Payment Approved
    Card Type{cartEntry.paymentResult.cctype}
    Name on Card{cartEntry.paymentResult.ccname}
    Card Number{cartEntry.paymentResult.ccnumb}
    Expiration Date{cartEntry.paymentResult.ccexp}
    Authorization Code{cartEntry.paymentResult.authCode}
    -

    - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Shop/sectionSelect.html b/legacy/views/front/FoundationStandAlone/Shop/sectionSelect.html deleted file mode 100755 index 4f5e1b3..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/sectionSelect.html +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - -
    - - -
    {term.section.cap} Selection
    - - - - - -
    {sectionText:h}
    - -{if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    -{end:} - -

    You have selected

    -
    -
    -
    -
    {performanceDetail.member_name}

    -
    {performanceDetail.name}
    -
    -
    - - -
    -
    -
    - - -
    -

    Please select from the following

    -
    -{foreach:sectionList,x} -
    - -
    -

    {term.section.cap}: {x.member_name}

    -

    {x.descr:h}

    -
    -
    -{end:} - -
    - -
    - - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Shop/start-COPY.html b/legacy/views/front/FoundationStandAlone/Shop/start-COPY.html deleted file mode 100644 index feda2b4..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/start-COPY.html +++ /dev/null @@ -1,162 +0,0 @@ - - -
    -
    -
    -
    -
    {m.name}
    -
    -
    -
    Address: {m.addr1}{if:m.addr2}, {m.addr2}{end:}, {m.city}
    -
    Phone #: {m.phone}
    -
    {m.descr:h}
    -
    -
    -
    -
    (map loads here)
    -
    - - -
    -
    - -
    - {foreach:m.performances,p} -
    -
    -
    -
    - {if:showTickets} - {p.name} - {else:} - {p.name} - {end:} -
    -
    -
    -
    {term.prop.cap}: {p.member_name}
    -
    Dates: {p.start_date.date} through {p.end_date.date}
    -
    -
    - {if:!showTickets} - {term.nav.select} - {end:} - - - {foreach:p.sections,s} -

     

    -
    -
    -
    - {if:!p.oneSectionOnly} - {s.sectionDetail.name}
    - {end:} - -
    - -
    -
    - - - {foreach:s.ticketsData,x} -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    -
    Price: 
    -
    -
    {x.price}
    -
    -
    -
    -
    Select date: 
    -
    -
    - - -
    -
    -
    -
    -
    Quant: 
    -
    -
    (select date)
    -
    -
    -
    - - {end:} - -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    {x.title}
    - {else:} -
    - {x.name} -
    - {term.nav.select} - {end:} -
    -
    - {if:x.descr} -

    {x.descr:h}

    - {end:} -
    - {if:!x.date_specific.value} - Use any date{if:x.start_date.timestamp} from {x.start_date.date} to {x.end_date.date}{end:}{if:!x.time_specific.value}, {end:} - {end:} - {if:!x.time_specific.value} - Use any time of day, - {else:} - Time: {x.ticket_time.time}, - {end:} - {if:x.unlimted_use.value} - Each {term.ticket.norm} may be used an unlimited number of times - {else:} - - {end:} -
    -
    -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    -
    Price each: 
    -
    -
    {x.price}
    -
    -
    -
    -
    Select date: 
    -
    -
    - - -
    -
    -
    -
    -
    Quant: 
    -
    -
    (select date)
    -
    -
    -
    - - {end:} -
    - - - {end:} - -
    - - {end:} - - - -
    - {end:} -
    -
    - {end:} diff --git a/legacy/views/front/FoundationStandAlone/Shop/start.html b/legacy/views/front/FoundationStandAlone/Shop/start.html deleted file mode 100755 index 95a7dbf..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/start.html +++ /dev/null @@ -1,882 +0,0 @@ - - - -{if:showTickets} - -
    - - - - -{end:} - - - -
    -
    - - - {term.nav.show_selected} - {term.nav.add_to_cart} - - -

    {ticketText:h}

    - -
    -
    - -{if:reason} -
    -
    -
    - We're sorry, we had a problem with your request: -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - - - -{foreach:membersList,m} - - - - - - - - - - - - - - - {if:option.ticket_shop.start.show_performances} - - {foreach:m.performances,p} - -
    -
    - name == $liveMusic){ ?> - Family Fun Cruises - - name == $ferry || $p->name == $valet || $p->name == $guide || $p->name == $sunset || $p->name == $fireWorks) { ?> -
    - name == $liveMusic) { ?> -
    - -
    - - -
    -
    - {if:!option.ticket_shop.start.show_sections} - name != $ferry && $p->name != $valet && $p->name != $guide){ ?> - {term.nav.select} - - - {p.name:h} - - {else:} - {p.name:h} - {end:} -
    -
    - - - -
    -
    - - {foreach:p.sections,s} - - - - - {if:!p.oneSectionOnly} - {s.sectionDetail.name}
    - {end:} - - -

    {p.descr:h}

    - - - - - - - {foreach:s.ticketsData,x} - - - {if:x.show_on_start.value} - - {if:x.mayBuyNow} - -
    -
    -
    -
    -
    - - - -
    -
    - - {if:option.ticket_selection.include_options_in_ticket_list} - price != '$0.00'){ ?> -
    {x.title} - {x.price}
    - title == 'Child Under 5'){ ?> -
    {x.title} - Free
    - -
    {x.title}
    - - {else:} - {x.name} - {end:} -
    -
    -
    -
    - - {if:x.descr} - - {end:} - - -
    -
    - {if:option.packages} - {foreach:x.packageData,y} -
    -
     
    -
    - {y.quant} -
    -
    - {y.title} - {y.performance_name} -
    -
    - {end:} - {end:} -
    - - {if:option.ticket_selection.include_options_in_ticket_list} - -
    - - - {if:x.date_specific.value} - - {end:} - - - - - {foreach:x.addons,a} - - - - {end:} - -
    -
    - - {end:} - -
    - - {if:x.show_on_start.value} -
    - {end:} -
    -
    - {end:} - {end:} - {end:} - - - {end:} - - {if:option.ticket_shop.start.show_performance_descr_short} - - {else:} - {if:p.descr} - - {end:} - {end:} - {if:option.ticket_shop.start.show_performance_start_end_dates} -
    - - {end:} -
    - {if:option.ticket_shop.start.show_performance_image} - {if:p.image} - -
    - -
    - -
    - -
    - {end:} - {end:} -
    - name == $guide){ ?> - - Add to cart and proceed to checkout - - - - -
    -
    -
    - - - {end:} - - {end:} - - - - - - - -{end:} - - - - - - - - - - - - -{if:option.ticket_selection.include_options_in_ticket_list} - - - {startScript:h} - var tickets = {ticketsJSON:h}; - - - - - - - -{end:} - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Shop/ticketOpt.html b/legacy/views/front/FoundationStandAlone/Shop/ticketOpt.html deleted file mode 100755 index f0b3bc6..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/ticketOpt.html +++ /dev/null @@ -1,286 +0,0 @@ - - - - - -
    - -
    -
    Ticket Selection
    - - -
    - -
    {ticketOptText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    - {end:} -

    You have selected

    - -
    -
    -
    -
    {performanceDetail.name}
    -
    -
    -
    {term.prop.cap}: {performanceDetail.member_name}
    - - -
    -
    -
    -
    -
    {sectionDetail.name}
    -
    -
    - -
    -
    -
    -
    -
    {ticketDetail.name}
    -
    -
    - {if:!ticketDetail.date_specific.value} -
    Use any date {if:ticketDetail.start_date.timestamp} from {ticketDetail.start_date.date} to {ticketDetail.end_date.date}{end:}
    - {end:} - {if:!ticketDetail.time_specific.value} -
    Use any time
    - {else:} -
    Time: {ticketDetail.ticket_time.time}
    - {end:} - {if:!ticketDetail.unlimted_use.value} - - {else:} -
    Each {term.ticket.norm} may be used an unlimited number of times
    - {end:} -
    {ticketDetail.descr:h}
    -
    -
    -
    - -

    Please select from the following

    -
    -
    -
    -
    -
    -
    -
    -
    Select desired date:
    -
    -
    (click in field to set date)
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    Select Quantity:
    -
    -
    (please select date first)
    -
    -
    -
    -
    - {if:reason}
    (disabled - please see above)
    {else:}
    {term.nav.add_to_cart}
    {end:} -
    - - - - - - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/Shop/ticketSelect.html b/legacy/views/front/FoundationStandAlone/Shop/ticketSelect.html deleted file mode 100755 index 6d05732..0000000 --- a/legacy/views/front/FoundationStandAlone/Shop/ticketSelect.html +++ /dev/null @@ -1,529 +0,0 @@ - - - - - - - - - - - -
    -
    - - - {term.nav.show_selected} - {if:!option.ticket_shop.start_at_cart} - {term.nav.select_more} - {end:} - - -

    {ticketText:h}

    - -
    -
    - -{if:reason} -
    -
    -
    - We're sorry, we had a problem with your request: -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - - - - - - - - -{foreach:sections,s} - -
    -
    -
    - - - -
    -
    - {performanceDetail.member_name:h}
    -

    {performanceDetail.name:h}

    - member_name; ?> - {if:!oneSectionOnly} -
    {s.sectionDetail.name}
    - {end:} - {if:performanceDetail.descr} - {performanceDetail.descr:h} - {end:} -
    - {if:performanceDetail.image} -
    -
    - - -
    -
    - {end:} -
    - -
    -
    -
    - - - - {foreach:s.ticketsData,x} - {if:x.mayBuyNow} - -
    -
    -
    -
    -
    - - - - - - - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    {x.title} - {x.price}
    -
    - {else:} - {x.name} - {end:} - - - - - - - - - {if:option.packages} - {foreach:x.packageData,y} -
    -
     
    -
    - {y.quant} -
    -
    - {y.title} - {y.performance_name} -
    -
    - {end:} - {end:} -
    - - {if:option.ticket_selection.include_options_in_ticket_list} - -
    - - - {if:x.date_specific.value} - - {end:} - - - - - {foreach:x.addons,a} - - - - {end:} - -
    -
    - - {end:} - -
    -
    -
    - {end:} - {end:} - -{end:} - - - - - - - -{if:option.ticket_selection.include_options_in_ticket_list} - - - {startScript:h} - var tickets = {ticketsJSON:h}; - - - - - - - -{end:} - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/foot.html b/legacy/views/front/FoundationStandAlone/foot.html deleted file mode 100755 index 253ba60..0000000 --- a/legacy/views/front/FoundationStandAlone/foot.html +++ /dev/null @@ -1,27 +0,0 @@ - - - {if:option.development} -
    -
    -
    -
    -
    -
    Running on Development Server:
    -
    - -
    -
    -
    -
    - {end:} - - - - - diff --git a/legacy/views/front/FoundationStandAlone/head.html b/legacy/views/front/FoundationStandAlone/head.html deleted file mode 100755 index 9f092df..0000000 --- a/legacy/views/front/FoundationStandAlone/head.html +++ /dev/null @@ -1,71 +0,0 @@ - - - - - - {if:!jQueryLoaded} - - - - {end:} - - {if:!jQueryUiLoaded} - - - - - {end:} - - {if:!siteHasFoundation} - - - {end:} - - - - - - - {if:customCssFile} - - - - - {end:} - - {if:frontDebug} - - -
    - - - - - {end:} - - -
    -
    Updating your information
    Please wait ...
    -
    Updating
    Please wait ...
    -
    - - {if:adminUser} -

    Purchasing By Admin User

    - {end:} - \ No newline at end of file diff --git a/legacy/views/front/FoundationStandAlone/index.html b/legacy/views/front/FoundationStandAlone/index.html deleted file mode 100755 index fca55f0..0000000 --- a/legacy/views/front/FoundationStandAlone/index.html +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - -

    PLEASE NOTE:

    - -

    - There is no general access to this site. - All access to this site should be through an appropriate link. - If you arrived here by mistake (or exploring), nothing but this message will be displayed. - If you have any concerns about this site, please contact Gaslight Media. -

    - -

    - Gaslight Media
    - 120 East Lake Street
    - Petoskey, MI 49770
    -  
    - Phone: 231-487-0692
    - E-Mail: info@gaslightmedia.com
    - Web: http://www.gaslightmedia.com -

    - - - - - - diff --git a/legacy/views/front/TicketsFoundation/Debug/index.html b/legacy/views/front/TicketsFoundation/Debug/index.html deleted file mode 100755 index 6af2dc9..0000000 --- a/legacy/views/front/TicketsFoundation/Debug/index.html +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Front-End Debug
    -
    -
    - Updated: {debugUpdateTime} -
    -
    - {debugData:h} -
    - - - - - {startScript:h} - - // Reload the current window with Action = Debug_update - function reloadDebugWindow() - { - window.location("{baseSCRIPT}&Action=Debug_update"); - } - - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Debug/start.html b/legacy/views/front/TicketsFoundation/Debug/start.html deleted file mode 100755 index 66c3023..0000000 --- a/legacy/views/front/TicketsFoundation/Debug/start.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Front-End Debug
    -
    -
    Debug Startup
    - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Shop/Copy of cart.html b/legacy/views/front/TicketsFoundation/Shop/Copy of cart.html deleted file mode 100755 index c95b7ea..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/Copy of cart.html +++ /dev/null @@ -1,404 +0,0 @@ - - - -
    -
    - - -
    - - -
    - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} - -
    -
    - -
    {cartText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    - {end:} - {if:havePromoCodes} -
    -
    -
    If you have a {term.promo.norm}, please enter it here:
    -
    -
    - {end:} - {foreach:cart,c} -
    -
    {c.name:h}
    -
    - {foreach:c.performances,p} -
    -
    - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more_of_these} - {end:} -
    - -
    {p.name:h}
    -
    - {if:p.descr}
    {p.descr:h}
    {end:} - {if:p.short_descr}
    {p.short_descr:h}
    {end:} - {if:option.cart_images}{if:p.image} - - {end:}{end:} -
    -
    -
    -
    - {foreach:p.dates,d} -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} - {foreach:d.sections,s} - - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {foreach:s.tickets,i} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {if:i.descr} - - - {if:!p.oneSectionOnly} - - - {end:} - - {foreach:i.addons,a} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {end:} - - - {if:i.promo} - - - {if:!p.oneSectionOnly} - - {end:} - - - - {end:} - - {end:} -
    QuantSection{term.ticket.cap}PriceTotal
    - - {s.name:h}{i.title}{if:i.show_price}{i.price}{end:}{if:i.show_price}{i.extended}{end:}
      - {else:} - - {end:} - {if:option.cart_images}{if:i.image} -
    - {end:}{end:} -
    {i.descr:h}
    -
       -
    - -
    -
    {a.unit_cost}/{a.unit_name:h}{a.money}
      {term.promo.cap}: {promoCode}  - {i.promo.credit}
    - {end:} -
    - {end:} -
    -
    - {end:} -
    - {if:c.ticket_policy}
    {c.ticket_policy:h}
    {end:} - - {if:c.needAssignemntOrDate} - {if:c.needAssignment} - -
    - {if:!c.haveAssignment} -
    {text.cart.select_assignment_location}
    - {else:} -
    {text.cart.select_assignment_location}
    - {end:} - {foreach:c.assignmentMembers,a} - {if:a.entrances} - {foreach:a.entrances,e} -
    - {if:option.cart_images} - {if:e.image} -
    - {end:} - {end:} -
    - {if:e.selected} - {a.name:h} - {e.name:h}
    - {else:} - {a.name:h} - {e.name:h}
    - {end:} -
    -
    {e.addr1}{if:e.addr2}, {e.addr2}{end:}, {e.city}
    -
    {e.phone}
    - {if:e.descr} -
    {e.descr:h}
    - {end:} -
    -
    - {end:} -
    - {else:} - {if:a.selected} - {a.name:h}
    - {else:} - {a.name:h}
    - {end:} - {end:} - {end:} -  
    - {end:} - - {if:option.ask_for_likely_date} - {if:c.needLikelyDate} -
    - {if:!c.likelyDate} - - {else:} - - {end:} - {text.cart.select_likely_date}   - - mm/dd/yyyy -
    - {end:} - {end:} -
    -
    - {end:} - {if:!c.needAssignment} - - {if:option.cart_images}{if:c.image} -
    - - -
    - {end:}{end:} - {end:} - - - - -
    - {end:} - - -
    - {if:cartHasContents} -
    - Grand Total   {totals.price} -
    -
    - {if:totals.tickets} - {if:!blockCheckout} - {term.nav.checkout} - {else:} - Please complete the items in RED above. - {end:} - {else:} - Your cart is currently empty. - {end:} -
    - {else:} -

    Your cart is currently empty.

    - {end:} -
    - - {if:option.cart_promotions} -
    - You may also be interested in ...
    - {foreach:cartPromotions,p} -
    - - {if:p.image} -
    - {end:} -
    - - {if:p.short_descr}
    {p.short_descr:h}
    {end:} - {if:p.short_descr}
    {p.short_descr:h}
    {end:} -
    -
    - {end:} -
    - {end:} - - - -
    - -{startScript:h} - - $(document).ready(function(){ - - $('#cartForm').submit(function( event ) { - return false; - }); - - // Convert input fields to select lists - $('.glmCartQuant').each(function() { - - var id = $(this).attr('id'); - var ticket = $(this).attr('data-ticket'); - var addon = $(this).attr('data-addon'); - var max = $(this).attr('data-max'); - var value = $(this).attr('value'); - var units = $(this).attr('data-units'); - var numbSel = ''; - - // Build a picklist for this input - for (var i = 0 ; i {lte:h} max ; i++) { - if (value == i) { - numbSel = numbSel.concat(''); - } else { - numbSel = numbSel.concat(''); - } - } - - $('#quant_' + id).html('' + units); - - }); - - // Get or set vertical scroll to return to same place when cart reloads - function getVertScroll() { - var vertScroll = window.pageYOffset; - if (vertScroll == 0) { - var vertScroll = document.documentElement.scrollTop; - } - if (vertScroll == 0) { - var vertScroll = document.body.scrollTop; - } - return vertScroll; - } - - // When a cart value changes, submit it as a cart update. - $('.glmCartSelect').change(function() { - vertScroll = getVertScroll(); - var ticket = $(this).attr('data-ticket'); - var addon = $(this).attr('data-addon'); - var value = $(this).val(); - - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=update&ticket_inv=" + ticket + "&addon=" + addon + "&quant=" + value + "&vertScroll=" + vertScroll; - - }); - - // When there's a change in the promo code input, submit it. - $('#promoCodeInput').change(function() { - var value = $(this).val(); - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=promo_code&promo_code=" + value; - }); - - // When a member selection for unassigned items changes, submit it so it's in the session - $('.glmAssignmentChange').change(function() { - vertScroll = getVertScroll(); - var member = $(this).attr('data-Member'); - var assignedTo = $(this).val(); - var assignedToEntrance = $(this).attr('data-entrance'); - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=update_assignment&member_assigned=" + member + "&assigned_to=" + assignedTo + "&entrance_assigned=" + assignedToEntrance + "&vertScroll=" + vertScroll; - }); - - // When a likely departure date changes, submit it so it's in the session - $('.glmLikelyDateChange').change(function() { - vertScroll = getVertScroll(); - var member = $(this).attr('data-Member'); - var likelyDate = $(this).val(); - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=update_likelyDate&member=" + member + "&likely_date=" + likelyDate + "&vertScroll=" + vertScroll; - - }); - - // Code to start datepicker for each date input - if($("#likelyDateInput").length > 0) { - $("#likelyDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: -1, - maxDate: 365 - }); - } - - // Checkout action - $('#GLMcheckoutBtn').click(function() { - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_checkout"; - }); - - function setBlocker() { - $('#glmReloadBlocker').show(); - } - - $('#GLMnavSelectEvent').on('click', function() { // Return to Event Selection - setBlocker(); - window.location = '{startURL:h}'; - }); - -/* Not using right now - // Reprint order button - $('#reprintVoucher').on('keypress', function(event) { - if(event.which == '13'){ - var orderID = $(this).val(); - var voucherWindow = window.open('{appAdminURL}&Action=Order_printVoucher&OrderID=' + orderID, - "voucherPrint", - "height=750,width=600,menubar=yes,toolbar=yes,alwaysRaised=yes,menu" - ); - voucherWindow.focus(); - voucherWindow.print(); - return false; - } - }); -*/ - - if ({vertScroll}) { - window.scrollTo(0,{vertScroll}); - } - - }); - - - diff --git a/legacy/views/front/TicketsFoundation/Shop/PayPalApproved.html b/legacy/views/front/TicketsFoundation/Shop/PayPalApproved.html deleted file mode 100755 index 100d251..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/PayPalApproved.html +++ /dev/null @@ -1,41 +0,0 @@ - - - - - -
    - -

    Your PayPal payment has been approved.

    - - -
    - -

    - Your cart will now reflect that the payment has been made. -

    - -
    - -
    -
    Close This Window
    -
    - -
    - - - - diff --git a/legacy/views/front/TicketsFoundation/Shop/PayPalFail.html b/legacy/views/front/TicketsFoundation/Shop/PayPalFail.html deleted file mode 100755 index f8bed73..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/PayPalFail.html +++ /dev/null @@ -1,49 +0,0 @@ - - - - - -
    - -

    Unable to process your payment!

    - - -
    - -

    -

    Sorry, there was a problem.
    -

    - -

    - We were unable to find your purchase information and are therefore - are unable to process your payment through PayPal. This could be - due to you not performing any action with your pending purchase - for too long. Please click the "Return to selected tickets" button - at the top of the checkout page to see if your selections are still listed. -

    - -
    - -
    -
    Close This Window
    -
    - -
    - - - - diff --git a/legacy/views/front/TicketsFoundation/Shop/cart.html b/legacy/views/front/TicketsFoundation/Shop/cart.html deleted file mode 100755 index 50525ef..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/cart.html +++ /dev/null @@ -1,534 +0,0 @@ - - - -
    - - - -
    -
    - - - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} - - -

    {cartText:h}

    - -
    -
    - -{if:reason} - - - -
    -
    -
    -

    We're sorry, we had a problem with your request:

    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - -{if:havePromoCodes} - - - -
    -
    - -
    -
    - -
    -
    -{end:} - - - -{foreach:cart,c} - - {if:option.show_location_blocks} -
    -
    -
    -
    -

    {c.name:h}

    -
    - {end:} - - - - {foreach:c.performances,p} -
    -
    -
    - - - -
    -
    -

    {p.name:h} - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more_of_these} - {end:} -

    -
    -
    - - - -
    - {if:!option.cart_images} -
    - {if:p.image} - - {end:} -
    - {end:} -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    - {if:!option.cart_images} -
    - {if:p.image} - - {end:} -
    - {end:} -
    - - - - {foreach:p.dates,d} -
    -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    -
    - - - - {foreach:d.sections,s} -
    -
    Quant
    - {if:!p.oneSectionOnly} -
    {term.section.cap}
    -
    - {else:} -
    - {end:} - {term.ticket.cap} -
    -
    Price
    -
    Total
    -
    - - - - {foreach:s.tickets,i} - - - -
    -
    - -
    - {if:!p.oneSectionOnly} -
    {s.name:h}
    -
    - {else:} -
    - {end:} - {i.title} -
    -
    {if:i.show_price}{i.price}{end:}
    -
    {if:i.show_price}{i.extended}{end:}
    -
    - - - -
    -
    -

    {i.title}

    -
    - {if:i.problem} -
    -
    -
    {i.problemText}
    -
    -
    - {end:} - {if:i.descr} - - -
    -
    -
    - {if:option.cart_images} - {if:i.image} - - {end:} - {end:} - {i.descr:h} -
    -
    - {end:} - - {if:!p.oneSectionOnly} -
    -
    {term.section.cap}:
    -
    {s.name:h}
    -
    - {end:} -
    -
    Quant:
    -
     
    -
    - -
    -
    -
    -
    Price:
    -
    {if:i.show_price}{i.price}{end:}
    -
    -
    -
    Total:
    -
    {if:i.show_price}{i.extended}{end:}
    -
    -
    - - {if:i.descr} - - -
    -
    -
    - {if:option.cart_images} - {if:i.image} - - {end:} - {end:} - {i.descr:h} -
    -
    - {end:} - - - - {foreach:i.addons,a} - - - -
    -
     
    -
    - -
    -
    {a.name}
    -
    {a.unit_cost}/{a.unit_name:h}
    -
    {a.money}
    -
    - - - -
    -
    -

    {a.name}

    -
    -
    -
    Quant:
    -
     
    -
    - -
    -
    -
    -
    Price:
    -
    {a.unit_cost}/{a.unit_name:h}
    -
    -
    -
    Total:
    -
    {a.money}
    -
    -
    - - {end:} - - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    -
    -
    Promo:
    -
    {promoCode}:
    -
    {i.promo.credit}
    -
    - - {end:} - - {end:} - - {end:} - - {end:} - -
    -
    -
    - - {end:} - - - - {if:option.show_location_blocks} -
    -
    -
    - {end:} - -{end:} - - - -{if:cartHasContents} -
    -
    -

    Grand Total {totals.price}

    -
    -
    -
    -
    - {if:!blockCheckout} - {term.nav.checkout} - {else:} - Please complete the items in RED above. - {end:} -
    -
    -{else:} -
    -
    -

    Your cart is currently empty.

    -
    -
    -{end:} - - - -{if:option.cart_promotions} -
    -
    -
    -
    -
    You may also be interested in ...
    -
    - {foreach:cartPromotions,p} -
    - - {if:p.image} -
    - -
    - {end:} -
    - {if:p.short_descr}{p.short_descr:h}{end:} -
    -
    - {if:p.image} - - {end:} -
    -
    - {end:} -
    -
    -
    -{end:} - - - - - - - - - diff --git a/legacy/views/front/TicketsFoundation/Shop/checkout.html b/legacy/views/front/TicketsFoundation/Shop/checkout.html deleted file mode 100644 index 1890d95..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/checkout.html +++ /dev/null @@ -1,927 +0,0 @@ - - - -
    - - - - -
    -
    - - - {term.nav.show_selected} - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} - - -

    {checkoutText:h}

    - -
    -
    - -{if:reason} -
    -
    -
    -

    We're sorry, we had a problem with your request:

    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - - - -
    -
    -
    -
    -
    -

    Contact Information

    -
    -
    -
    -
    -
    -
    - {if:formData.contact.fname.required}
    -
    - {if:formData.contact.lname.required}
    -
    - {if:formData.contact.addr1.required}
    -
    - {if:formData.contact.addr2.required}
    -
    - {if:formData.contact.city.required}
    -
    - {if:formData.contact.state.required}
    -
    - {if:formData.contact.country.required}
    -
    - {if:formData.contact.zip.required}
    -
    -
    -
    -
    -
    - {if:formData.contact.phone.required}
    -
    - {if:formData.contact.email.required}
    -
    - {if:formData.contact.email2.required}
    -
    - -
    -
    - {if:formData.contact.email_ok} -
    - {else:} -
    - {end:} -
    - {if:opt_field_1_name} -
    - {if:formData.contact.opt_field_1.required}
    - {end:} - {if:opt_field_2_name} -
    - {if:formData.contact.opt_field_2.required}
    - {end:} - {if:opt_field_1_name} -
    - {if:formData.contact.opt_field_3.required}
    - {end:} -
    -
    -
    -
    -
    -
    - - - -{foreach:cart,c} - - {if:option.show_location_blocks} -
    -
    -
    -
    -
    -

    {c.name:h}

    -
    -
    - {end:} - - - - {foreach:c.performances,p} - -
    -
    -
    - - - -
    -
    -

    {p.name:h}

    -
    -
    - - - -
    -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    -
    - - - - {foreach:p.dates,d} -
    -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    -
    - - - - {foreach:d.sections,s} -
    -
    - Quant -
    - {if:!p.oneSectionOnly} -
    - {term.section.cap} -
    -
    - {else:} -
    - {end:} - {term.ticket.cap} -
    -
    - Price -
    -
    - Total -
    -
    - - - - {foreach:s.tickets,i} -
    -
    - {i.selected} -
    - {if:!p.oneSectionOnly} -
    - {s.name:h} -
    -
    - {else:} -
    - {end:} - {i.title} -
    -
    - {if:i.show_price}{i.price}{end:} -
    -
    - {if:i.show_price}{i.extended}{end:} -
    -
    - - - - {if:i.descr} -
    -
    -
    - {i.descr:h} -
    -
    - {end:} - - - - {foreach:i.addons,a} -
    -
     
    -
    - {a.selected} -
    -
    - {a.name} -
    -
    - {a.unit_cost}/{a.unit_name:h} -
    -
    - {a.money} -
    -
    - {end:} - - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    - {end:} - - {end:} - - {end:} - - {end:} - - {if:p.policy} -
    -
    -

     

    -
    Please read and agree to our policy for this {term.performance.norm}.
    -

    {p.policy:h}

    - -
    -
    - {end:} - -
    -
    -
    - - {end:} - - - - {foreach:c.performances,p} - -
    -
    -
    - - - -
    -
    -

    {p.name:h}

    -
    -
    - - - -
    -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    -
    - - - - {foreach:p.dates,d} -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    - - - - {foreach:d.sections,s} - {if:!p.oneSectionOnly} -
    -
    - {term.section.cap}: {s.name:h} -
    -
    - {end:} - - - - {foreach:s.tickets,i} -
    -
    -

    {i.title}

    -

    -
    - {if:i.descr} -
    -
    -
    - {i.descr:h} -
    -
    - {end:} - -
    -
    - Quant -
    -
    {i.selected}
    -
    - {if:i.show_price} -
    -
    - Price -
    -
    {i.price}
    -
    -
    -
    - Total -
    -
    {i.extended}
    -
    - {end:} - - - - {foreach:i.addons,a} -
    -
    - {a.name} -
    -
    -
    -
    - Quant -
    -
    {a.selected}
    -
    -
    -
    - {a.unit_cost}/{a.unit_name:h} -
    -
    {a.money}
    -
    - {end:} - - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    - {end:} - - {end:} - - {end:} - - {end:} - - {if:p.policy} -
    -
    -

     

    -
    Please read and agree to our policy for this {term.performance.norm}.
    -

    {p.policy:h}

    - -
    -
    - {end:} - -
    -
    -
    - - {end:} - - {if:c.ticket_spec_req.value} -
    -
    - -
    -
    - {end:} - - - -
    -
    -
    -
    -
    -
    Payment for {term.ticket.plur} at {c.name:h}
    -
    -
    -
    {c.totalPrice}
    -
    -
    -
    -
    -   -
    -
    - - {if:c.paymentResult} - {if:c.paymentResult.approved} -
    -
    - Card Payment Approved -
    -
    -
    -
    - Card Type: -
    -
    - {c.paymentResult.cctype} -
    -
    -
    -
    - Name on Card: -
    -
    - {c.paymentResult.ccname} -
    -
    -
    -
    - Card Number: -
    -
    - {c.paymentResult.ccnumb} -
    -
    -
    -
    - Expiration Date: -
    -
    - {c.paymentResult.ccexp} -
    -
    -
    -
    - Authorization Code: -
    -
    - {c.paymentResult.authCode} -
    -
    - - {else:} -
    -
    -
    Card Payment Not Complete
    -
    -
    -
    -
    -

    {c.paymentResult.description}

    -

    Please check the payment information below and try again or contact your credit card company for assistance.

    - {if:forceCheckoutPhase} - {term.nav.delete_from_cart} - {end:} -
    -
    - {end:} - - {else:} - - {if:c.havePaymentMethod} - - {if:c.paypal.value} -
    -
    - {if:c.haveMultiplePaymentMethods} -  PayPal - {else:} - - {end:} -
    -
    - {end:} - {if:c.haveCreditCards} -
    -
    - {if:c.haveMultiplePaymentMethods} -  Credit Card - {else:} - - {end:} -
    -
    -
    -
    - {if:c.paymentForm.cctype.required}
    -
    -
    -
    -
    - {if:c.paymentForm.ccname.required}
    -
    -
    -
    - {if:c.paymentForm.ccnumb.required}
    -
    -
    -
    -
    -
    -
    - {if:c.paymentForm.ccexp.required}
    -
    - {if:c.paymentForm.ccexp.required}
    -
    - {if:c.paymentForm.ccexp.problem} - {c.paymentForm.ccexp.problem} - {end:} -
    -
    -
    -
    - {if:c.paymentForm.cccode.required}
    -
    -
    - {end:} - - {if:c.havePayPal} -
    -
    - -
    -
    - {end:} - - {else:} -
    -
    -

    - This {term.prop.norm} does not have a payment method configured.asdasdsadasd - Please call this {term.prop.norm} to purchase {term.ticket.plur}. -

    -
    -
    - - - {end:} - - - {end:} - -
    -
    -
    - - - {if:option.show_location_blocks} -
    -
    -
    - {end:} -{end:} - -
    -
    -

    Grand Total {totals.price}

    - {if:!cartHasOneVenueOnly} -

    NOTE: There will be a separate credit card transaction for each {term.prop.norm}.

    - {end:} -
    -
    -
    -
    - {ssl_seal_head_script:h} - {ssl_seal_body_script:h} -
    -
    - {if:!blockCheckout} - {term.nav.purchase} - {else:} - Unable to checkout - please see above. - {end:} -
    -
    - - - - - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Shop/checkoutSuccess.html b/legacy/views/front/TicketsFoundation/Shop/checkoutSuccess.html deleted file mode 100644 index b159f83..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/checkoutSuccess.html +++ /dev/null @@ -1,489 +0,0 @@ - - -asdasdasdasdasdasd -{if:checkoutSucccessText} -
    -
    - -

    {checkoutSuccessText:h}

    -
    -
    -{end:} - -
    -
    -

    Purchase Complete

    -
    -
    - - - -
    -
    -
    -
    -
    - {foreach:cart,c} - {if:c.paymentResult} - {if:c.paymentResult.approved} -

    - *** {term.nav.print_vouchers} for {c.name} *** -

    - {end:} - {end:} - {end:} -
    -
    -
    -
    - - Adobe Reader is required to view and print your {term.voucher.plur}. Adobe Reader is a free program available directly from Adobe. - If you do not already have Adobe Reader installed, click the "Get Adobe Reader" link now. - -
    -
    - -
    -
    - - - If you are unable to print your {term.voucher.plur}, please print this page or write down the order number(s) - below and bring that to the ticket office when you arrive. - - -
    -
    - - ORDER #: - {foreach:cart,c} - {if:c.paymentResult} - {if:c.paymentResult.approved} - {c.paymentResult.orderID}  - {end:} - {end:} - {end:} - -
    -
    -
    -
    -
    - - - -
    -
    -
    -
    -
    -

    Contact Information

    -
    -
    -
    -
    - Name: -
    -
    - {formData.contact.fname.value} {formData.contact.lname.value} -
    -
    -
    -
    - {text.cart.checkout.address}: -
    -
    - {formData.contact.addr1.value}
    - {if:formData.contact.addr2.value} - {formData.contact.addr2.value}
    - {end:} - {formData.contact.city.value}, {formData.contact.state.name} {formData.contact.zip.value}
    - {formData.contact.country.name} -
    -
    -
    -
    - {text.cart.checkout.phone}: -
    -
    - {formData.contact.phone.value} -
    -
    -
    -
    - {text.cart.checkout.email}: -
    -
    - {formData.contact.email.value} -
    -
    -
    -
    - OK to Send E-Mail?: -
    -
    - {if:formData.contact.email_ok} - You have asked us to send information on activities and offers. - {else:} - You have asked us to NOT send information on activities and offers. - We will only contact you regarding this order. - {end:} -
    -
    - {if:opt_field_1_name} -
    -
    - {opt_field_1_name}: -
    -
    - {formData.contact.opt_field_1.value} -
    -
    - {end:} - {if:opt_field_2_name} -
    -
    - {opt_field_2_name}: -
    -
    - {formData.contact.opt_field_2.value} -
    -
    - {end:} - {if:opt_field_3_name} -
    -
    - {opt_field_3_name}: -
    -
    - {formData.contact.opt_field_3.value} -
    -
    - {end:} - -
    -
    -
    - - - -{foreach:cart,c} - - {if:option.show_location_blocks} -
    -
    -
    -
    -
    -

    {c.name:h}

    -
    -
    - {end:} - - - - {foreach:c.performances,p} -
    -
    -
    - - - -
    -
    -

    {p.name:h}

    -
    -
    - - - -
    -
    - {if:p.short_descr} - {p.short_descr:h} - {else:} - {if:p.descr} - {p.descr:h} - {end:} - {end:} -
    -
    - - - - {foreach:p.dates,d} -
    -
    -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} -
    -
    -
    - - - - {foreach:d.sections,s} -
    -
    - Quant -
    - {if:!p.oneSectionOnly} -
    - {term.section.cap} -
    -
    - {term.ticket.cap} -
    - {else:} -
    - {term.ticket.cap} -
    - {end:} -
    - Price -
    -
    - Total -
    -
    - - - - {foreach:s.tickets,i} -
    -
    Quant
    -
    {i.selected}
    -
    {i.selected}
    - {if:!p.oneSectionOnly} -
    {term.section.cap}
    -
    {s.name:h}
    -
    {term.ticket.cap}
    -
    {i.name:h}
    - {else:} -
    {term.ticket.cap}
    -
    {i.name:h}
    - {end:} -
    Price
    -
    {i.price}
    -
    {i.price}
    -
    Total
    -
    {i.extended}
    -
    {i.extended}
    -
    - - - - {if:i.descr} -
    -
    -
    - {i.descr:h} -
    -
    - {end:} - - - - {foreach:i.addons,a} -
    -
     
    -
    Quant
    -
    {a.selected}
    -
    {a.selected}
    - -
    {term.ticket.cap}
    -
    {a.name:h}
    - -
    Price
    -
    {a.unit_cost}/{a.unit_name:h}
    -
    {a.unit_cost}/{a.unit_name:h}
    - -
    Total
    -
    {a.money}
    -
    {a.money}
    -
    - {end:} - - - - {if:i.promo} -
    -
     
    -
    - {term.promo.cap}: {promoCode} -
    -
    -
    - {i.promo.credit} -
    -
    - {end:} - - {end:} - - {end:} - - {end:} - - {if:p.policy} - - - -
    -
    -

    {p.policy:h}

    -
    -
    - {end:} - -
    -
    -
    - - {end:} - - {if:c.paymentForm.spec_req.value} - - - -
    -
    - {c.paymentForm.spec_req.value:h} -
    -
    - {end:} - - - -
    -
    -
    -
    -
    - Payment for {term.ticket.plur} at {c.name:h} -
    -
    -
    {c.totalPrice}
    -
    -
    -
    -
    -   -
    -
    -
    -
    - Card Payment Approved -
    -
    -
    -
    - Card Type: -
    -
    - {c.paymentResult.cctype} -
    -
    -
    -
    - Name on Card: -
    -
    - {c.paymentResult.ccname} -
    -
    -
    -
    - Card Number: -
    -
    - {c.paymentResult.ccnumb} -
    -
    -
    -
    - Expiration Date: -
    -
    - {c.paymentResult.ccexp} -
    -
    -
    -
    - Authorization Code: -
    -
    - {c.paymentResult.authCode} -
    -
    -
    -
    -
    - - {if:c.ticket_policy} -
    -
    - {c.ticket_policy:h} -
    -
    - {end:} - - {if:option.show_location_blocks} -
    -
    -
    - {end:} -{end:} - - - -
    -
    -

    Grand Total {totals.price}

    -{if:!cartHasOneVenueOnly} -

    NOTE: You will see a separate credit card transaction for each {term.prop.norm} above.

    -{end:} -
    -
    - -{trackingScript:h} - - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Shop/paymentSummary.html b/legacy/views/front/TicketsFoundation/Shop/paymentSummary.html deleted file mode 100755 index e5b1642..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/paymentSummary.html +++ /dev/null @@ -1,112 +0,0 @@ - -

    - - Click here to reprint your {term.voucher.plur} - -

    - -

    - {term.ticket.plur_cap} Purchased at:
    - {cartEntry.name} -

    - - -{if:cartEntry.descr}

    {cartEntry.descr:h}

    {end:} - - - - - - - - - - - -{foreach:cartEntry.performances,p} - {foreach:p.dates,d} - {foreach:d.sections,s} - - - {foreach:s.tickets,i} - - - - - - - - {foreach:i.addons,a} - - - - - - - - {end:} - {if:i.promo} - - - - - - - {end:} - {end:} - - - {end:} - {end:} -{end:} - - - - - - - - -
    Quant{term.performance.cap}{term.ticket.cap}PriceTotal
    {i.selected}{p.name:h}{i.title:h}{if:i.show_price}{i.price}{end:}{if:i.show_price}{i.extended}{end:}
       -
    - {a.selected} {a.unit_name} -
    -
    {a.unit_cost}/{a.unit_name}{a.money}
      {term.promo.cap}: {promoCode}  - {i.promo.credit}
     {cartEntry.totalPrice}
    - - -{if:cartEntry.ticket_spec_req} -

    - Special requests: {cartEntry.paymentForm.spec_req.value:h} -

    -{end:} - - -{if:cartEntry.ticket_policy}

    {cartEntry.ticket_policy:h}

    {end:} - -

    - - - - - - - -
    Credit Card Payment Approved
    Card Type{cartEntry.paymentResult.cctype}
    Name on Card{cartEntry.paymentResult.ccname}
    Card Number{cartEntry.paymentResult.ccnumb}
    Expiration Date{cartEntry.paymentResult.ccexp}
    Authorization Code{cartEntry.paymentResult.authCode}
    -

    - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Shop/sectionSelect.html b/legacy/views/front/TicketsFoundation/Shop/sectionSelect.html deleted file mode 100755 index eda22a2..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/sectionSelect.html +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - -
    - - -
    {term.section.cap} Selection
    - - - - - -
    {sectionText:h}
    - -{if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    -{end:} - -

    You have selected

    -
    -
    -
    -
    {performanceDetail.member_name}

    -
    {performanceDetail.name}
    -
    -
    - - -
    -
    -
    - - -
    -

    Please select from the following

    -
    -{foreach:sectionList,x} -
    - -
    -

    {term.section.cap}: {x.member_name}

    -

    {x.descr:h}

    -
    -
    -{end:} - -
    - -
    - - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Shop/start.html b/legacy/views/front/TicketsFoundation/Shop/start.html deleted file mode 100755 index a735605..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/start.html +++ /dev/null @@ -1,396 +0,0 @@ - - - -
    - -
    -
    {term.event.cap} Selection
    - - -
    - -
    {introText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    - {end:} -

    Please select from the following

    -{if:showTickets} -
    - - - - -{end:} - - {foreach:membersList,m} -
    -
    -
    -
    -
    {m.name}
    -
    -
    -
    Address: {m.addr1}{if:m.addr2}, {m.addr2}{end:}, {m.city}
    -
    Phone #: {m.phone}
    -
    {m.descr:h}
    -
    -
    -
    -
    (map loads here)
    - - - - -
    - -
    - {foreach:m.performances,p} -
    -
    -
    -
    - {if:showTickets} - {p.name} - {else:} - {p.name} - {end:} -
    -
    -
    -
    {term.prop.cap}: {p.member_name}
    -
    Dates: {p.start_date.date} through {p.end_date.date}
    -
    -
    - {if:!showTickets} - {term.nav.select} - {end:} - - - {foreach:p.sections,s} -

     

    -
    -
    -
    - {if:!p.oneSectionOnly} - {s.sectionDetail.name}
    - {end:} - -
    - -
    -
    - - - {foreach:s.ticketsData,x} -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    -
    Price: 
    -
    -
    {x.price}
    -
    -
    -
    -
    Select date: 
    -
    -
    - - -
    -
    -
    -
    -
    Quant: 
    -
    -
    (select date)
    -
    -
    -
    - - {end:} - -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    {x.title}
    - {else:} -
    - {x.name} -
    - {term.nav.select} - {end:} -
    -
    - {if:x.descr} -

    {x.descr:h}

    - {end:} -
    - {if:!x.date_specific.value} - Use any date{if:x.start_date.timestamp} from {x.start_date.date} to {x.end_date.date}{end:}{if:!x.time_specific.value}, {end:} - {end:} - {if:!x.time_specific.value} - Use any time of day, - {else:} - Time: {x.ticket_time.time}, - {end:} - {if:x.unlimted_use.value} - Each {term.ticket.norm} may be used an unlimited number of times - {else:} - - {end:} -
    -
    -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    -
    Price each: 
    -
    -
    {x.price}
    -
    -
    -
    -
    Select date: 
    -
    -
    - - -
    -
    -
    -
    -
    Quant: 
    -
    -
    (select date)
    -
    -
    -
    - - {end:} -
    - - - {end:} - -
    - - {end:} - - - -
    - {end:} -
    -
    - {end:} -{if:showTickets} - - -{end:} -
    - - - - - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Shop/ticketOpt.html b/legacy/views/front/TicketsFoundation/Shop/ticketOpt.html deleted file mode 100755 index 197419e..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/ticketOpt.html +++ /dev/null @@ -1,286 +0,0 @@ - - - - - -
    - -
    -
    Ticket Selection
    - - -
    - -
    {ticketOptText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    - {end:} -

    You have selected

    - -
    -
    -
    -
    {performanceDetail.name}
    -
    -
    -
    {term.prop.cap}: {performanceDetail.member_name}
    - - -
    -
    -
    -
    -
    {sectionDetail.name}
    -
    -
    - -
    -
    -
    -
    -
    {ticketDetail.name}
    -
    -
    - {if:!ticketDetail.date_specific.value} -
    Use any date {if:ticketDetail.start_date.timestamp} from {ticketDetail.start_date.date} to {ticketDetail.end_date.date}{end:}
    - {end:} - {if:!ticketDetail.time_specific.value} -
    Use any time
    - {else:} -
    Time: {ticketDetail.ticket_time.time}
    - {end:} - {if:!ticketDetail.unlimted_use.value} - - {else:} -
    Each {term.ticket.norm} may be used an unlimited number of times
    - {end:} -
    {ticketDetail.descr:h}
    -
    -
    -
    - -

    Please select from the following

    -
    -
    -
    -
    -
    -
    -
    -
    Select desired date:
    -
    -
    (click in field to set date)
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    Select Quantity:
    -
    -
    (please select date first)
    -
    -
    -
    -
    - {if:reason}
    (disabled - please see above)
    {else:}
    {term.nav.add_to_cart}
    {end:} -
    - - - - - - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/Shop/ticketSelect.html b/legacy/views/front/TicketsFoundation/Shop/ticketSelect.html deleted file mode 100755 index cc806ba..0000000 --- a/legacy/views/front/TicketsFoundation/Shop/ticketSelect.html +++ /dev/null @@ -1,425 +0,0 @@ - - - -
    - - - - - - - -
    -
    - - - {term.nav.show_selected} - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} - - -

    {ticketText:h}

    - -
    -
    - -{if:reason} -
    -
    -
    -

    We're sorry, we had a problem with your request:

    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    -
    -
    -{end:} - - - -{foreach:sections,s} - -
    -
    -
    - -
    -
    -

    {performanceDetail.member_name:h}

    -

    {performanceDetail.name:h}

    -
    - {if:performanceDetail.image} -
    -
    -
    - {end:} -
    - - - -
    -
    - {if:!oneSectionOnly} -
    {s.sectionDetail.name}
    - {end:} - {if:performanceDetail.descr} - {performanceDetail.descr:h} - {end:} -
    -
    - -
    -
    -
    - - - - {foreach:s.ticketsData,x} - -
    -
    -
    - - - -
    -
    - {if:option.ticket_selection.include_options_in_ticket_list} -

    {x.title}

    - {else:} -

    {x.name}

    - {end:} -
    -
    -
    -
    - {if:x.descr} - {x.descr:h} - {end:} -

    - {if:!x.date_specific.value} - Use any date{if:x.start_date.timestamp} from {x.start_date.date} to {x.end_date.date}{end:}
    - {end:} - - {if:!x.time_specific.value} - Use any time of day, - {else:} - Time: {x.ticket_time.time} - {end:} - - {if:x.unlimted_use.value} - Each {term.ticket.norm} may be used an unlimited number of times - {end:} -

    -
    -
    - {if:option.ticket_selection.include_options_in_ticket_list} - -
    -
    - Price
    - {x.price} - -
    -
    - -
    -
    - -
    -
    - - - - {foreach:x.addons,a} - -
    -
     
    -
    - {a.name} - {a.unit_cost} -
    -
    - - - -
    -
    - - {end:} - - {end:} - -
    -
    -
    - - {end:} - -{end:} - - - - - -
    - -{if:option.ticket_selection.include_options_in_ticket_list} - - - {startScript:h} - var tickets = {ticketsJSON:h}; - - - - - - - -{end:} - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/foot.html b/legacy/views/front/TicketsFoundation/foot.html deleted file mode 100755 index 2353504..0000000 --- a/legacy/views/front/TicketsFoundation/foot.html +++ /dev/null @@ -1,19 +0,0 @@ - - - {if:option.development} -
    -
    -
    -
    -
    -
    Running on Development Server:
    -
    - -
    -
    -
    -
    - {end:} - diff --git a/legacy/views/front/TicketsFoundation/head.html b/legacy/views/front/TicketsFoundation/head.html deleted file mode 100644 index f6cce73..0000000 --- a/legacy/views/front/TicketsFoundation/head.html +++ /dev/null @@ -1,66 +0,0 @@ - - - - - - {if:!jQueryLoaded} - - - - {end:} - - {if:!jQueryUiLoaded} - - - - - {end:} - - - - - - - {if:customCssFile} - - - - - {end:} - - {if:frontDebug} - - -
    - - - - - {end:} - - -
    -
    Updating your information
    Please wait ...
    -
    Updating
    Please wait ...
    -
    - - {if:adminUser} -

    Purchasing By Admin User

    - {end:} - \ No newline at end of file diff --git a/legacy/views/front/TicketsFoundation/index.html b/legacy/views/front/TicketsFoundation/index.html deleted file mode 100755 index fca55f0..0000000 --- a/legacy/views/front/TicketsFoundation/index.html +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - -

    PLEASE NOTE:

    - -

    - There is no general access to this site. - All access to this site should be through an appropriate link. - If you arrived here by mistake (or exploring), nothing but this message will be displayed. - If you have any concerns about this site, please contact Gaslight Media. -

    - -

    - Gaslight Media
    - 120 East Lake Street
    - Petoskey, MI 49770
    -  
    - Phone: 231-487-0692
    - E-Mail: info@gaslightmedia.com
    - Web: http://www.gaslightmedia.com -

    - - - - - - diff --git a/legacy/views/front/tickets/Debug/index.html b/legacy/views/front/tickets/Debug/index.html deleted file mode 100755 index a42397f..0000000 --- a/legacy/views/front/tickets/Debug/index.html +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Front-End Debug
    -
    -
    - Updated: {debugUpdateTime} -
    -
    - {debugData:h} -
    - - - {startScript:h} - - // Reload the current window with Action = Debug_update - function reloadDebugWindow() - { - window.location("{baseSCRIPT}&Action=Debug_update"); - } - - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Debug/start.html b/legacy/views/front/tickets/Debug/start.html deleted file mode 100755 index 66c3023..0000000 --- a/legacy/views/front/tickets/Debug/start.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - -
    Startup: {debugStartupTime}
    -
    Event Management Front-End Debug
    -
    -
    Debug Startup
    - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Shop/PayPalApproved.html b/legacy/views/front/tickets/Shop/PayPalApproved.html deleted file mode 100755 index 7df6e28..0000000 --- a/legacy/views/front/tickets/Shop/PayPalApproved.html +++ /dev/null @@ -1,41 +0,0 @@ - - - - - -
    - -

    Your PayPal payment has been approved.

    - - -
    - -

    - Your cart will now reflect that the payment has been made. -

    - -
    - -
    -
    Close This Window
    -
    - -
    - - - - diff --git a/legacy/views/front/tickets/Shop/PayPalFail.html b/legacy/views/front/tickets/Shop/PayPalFail.html deleted file mode 100755 index 9dcd4ec..0000000 --- a/legacy/views/front/tickets/Shop/PayPalFail.html +++ /dev/null @@ -1,49 +0,0 @@ - - - - - -
    - -

    Unable to process your payment!

    - - -
    - -

    -

    Sorry, there was a problem.
    -

    - -

    - We were unable to find your purchase information and are therefore - are unable to process your payment through PayPal. This could be - due to you not performing any action with your pending purchase - for too long. Please click the "Return to selected tickets" button - at the top of the checkout page to see if your selections are still listed. -

    - -
    - -
    -
    Close This Window
    -
    - -
    - - - - diff --git a/legacy/views/front/tickets/Shop/cart.html b/legacy/views/front/tickets/Shop/cart.html deleted file mode 100755 index e5e858d..0000000 --- a/legacy/views/front/tickets/Shop/cart.html +++ /dev/null @@ -1,410 +0,0 @@ - - - -
    -
    - - -
    - - -
    - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} - -
    -
    - -
    {cartText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r}{Chuck} -
    • {r:h}
    • - {end:} -
    -
    - {end:} - {if:havePromoCodes} -
    -
    -
    If you have a {term.promo.norm}, please enter it here:
    -
    -
    - {end:} - {foreach:cart,c} -
    -
    {c.name}
    -
    - {foreach:c.performances,p} -
    -
    - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more_of_these} - {end:} -
    - -
    {p.name}
    -
    - {if:p.descr}
    {p.descr:h}
    {end:} - {if:p.short_descr}
    {p.short_descr:h}
    {end:} - {if:option.cart_images}{if:p.image} - - {end:}{end:} -
    -
    -
    -
    - {foreach:p.dates,d} -
    - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} - {foreach:d.sections,s} - - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {foreach:s.tickets,i} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {if:i.problem} - - - - {end:} - {if:i.descr} - - - {if:!p.oneSectionOnly} - - - {end:} - - {foreach:i.addons,a} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {end:} - - - {if:i.promo} - - - {if:!p.oneSectionOnly} - - {end:} - - - - {end:} - - {end:} -
    QuantSection{term.ticket.cap}PriceTotal
    - - {s.name}{i.title}{if:i.show_price}{i.price}{end:}{if:i.show_price}{i.extended}{end:}
     {i.problemText}
      - {else:} - - {end:} - {if:option.cart_images}{if:i.image} -
    - {end:}{end:} -
    {i.descr:h}
    -
       -
    - -
    -
    {a.unit_cost}/{a.unit_name}{a.money}
      {term.promo.cap}: {promoCode}  - {i.promo.credit}
    - {end:} -
    - {end:} -
    -
    - {end:} -
    - {if:c.ticket_policy}
    {c.ticket_policy:h}
    {end:} - - {if:c.needAssignemntOrDate} - {if:c.needAssignment} - -
    - {if:!c.haveAssignment} -
    {text.cart.select_assignment_location}
    - {else:} -
    {text.cart.select_assignment_location}
    - {end:} - {foreach:c.assignmentMembers,a} - {if:a.entrances} - {foreach:a.entrances,e} -
    - {if:option.cart_images} - {if:e.image} -
    - {end:} - {end:} -
    - {if:e.selected} - {a.name} - {e.name}
    - {else:} - {a.name} - {e.name}
    - {end:} -
    -
    {e.addr1}{if:e.addr2}, {e.addr2}{end:}, {e.city}
    -
    {e.phone}
    - {if:e.descr} -
    {e.descr:h}
    - {end:} -
    -
    - {end:} -
    - {else:} - {if:a.selected} - {a.name}
    - {else:} - {a.name}
    - {end:} - {end:} - {end:} -  
    - {end:} - - {if:option.ask_for_likely_date} - {if:c.needLikelyDate} -
    - {if:!c.likelyDate} - - {else:} - - {end:} - {text.cart.select_likely_date}   - - mm/dd/yyyy -
    - {end:} - {end:} -
    -
    - {end:} - {if:!c.needAssignment} - - {if:option.cart_images}{if:c.image} -
    - - -
    - {end:}{end:} - {end:} - - - - -
    - {end:} - - -
    - {if:cartHasContents} -
    - Grand Total   {totals.price} -
    -
    - {if:totals.tickets} - {if:!blockCheckout} - {term.nav.checkout} - {else:} - Please complete the items in RED above. - {end:} - {else:} - Your cart is currently empty. - {end:} -
    - {else:} -

    Your cart is currently empty.

    - {end:} -
    - - {if:option.cart_promotions} -
    - You may also be interested in ...
    - {foreach:cartPromotions,p} -
    - - {if:p.image} -
    - {end:} -
    - - {if:p.short_descr}
    {p.short_descr:h}
    {end:} - {if:p.short_descr}
    {p.short_descr:h}
    {end:} -
    -
    - {end:} -
    - {end:} - - - -
    - -{startScript:h} - - $(document).ready(function(){ - - // Block direct form submission - Everything submits by jQuery action - $('#cartForm').submit(function( event ) { - return false; - }); - - // Convert input fields to select lists - $('.glmCartQuant').each(function() { - - var id = $(this).attr('id'); - var ticket = $(this).attr('data-ticket'); - var addon = $(this).attr('data-addon'); - var max = $(this).attr('data-max'); - var value = $(this).attr('value'); - var units = $(this).attr('data-units'); - var numbSel = ''; - - // Build a picklist for this input - for (var i = 0 ; i {lte:h} max ; i++) { - if (value == i) { - numbSel = numbSel.concat(''); - } else { - numbSel = numbSel.concat(''); - } - } - - $('#quant_' + id).html('' + units); - - }); - - // Get or set vertical scroll to return to same place when cart reloads - function getVertScroll() { - var vertScroll = window.pageYOffset; - if (vertScroll == 0) { - var vertScroll = document.documentElement.scrollTop; - } - if (vertScroll == 0) { - var vertScroll = document.body.scrollTop; - } - return vertScroll; - } - - // When a cart value changes, submit it as a cart update. - $('.glmCartSelect').change(function() { - vertScroll = getVertScroll(); - var ticket = $(this).attr('data-ticket'); - var addon = $(this).attr('data-addon'); - var value = $(this).val(); - - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=update&ticket_inv=" + ticket + "&addon=" + addon + "&quant=" + value + "&vertScroll=" + vertScroll; - - }); - - // When there's a change in the promo code input, submit it. - $('#promoCodeInput').change(function() { - var value = $(this).val(); - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=promo_code&promo_code=" + value; - }); - - // When a member selection for unassigned items changes, submit it so it's in the session - $('.glmAssignmentChange').change(function() { - vertScroll = getVertScroll(); - var member = $(this).attr('data-Member'); - var assignedTo = $(this).val(); - var assignedToEntrance = $(this).attr('data-entrance'); - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=update_assignment&member_assigned=" + member + "&assigned_to=" + assignedTo + "&entrance_assigned=" + assignedToEntrance + "&vertScroll=" + vertScroll; - }); - - // When a likely departure date changes, submit it so it's in the session - $('.glmLikelyDateChange').change(function() { - vertScroll = getVertScroll(); - var member = $(this).attr('data-Member'); - var likelyDate = $(this).val(); - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=update_likelyDate&member=" + member + "&likely_date=" + likelyDate + "&vertScroll=" + vertScroll; - - }); - - // Code to start datepicker for each date input - if($("#likelyDateInput").length > 0) { - $("#likelyDateInput").datepicker({ - dateFormat: "mm/dd/yy", - minDate: -1, - maxDate: 365 - }); - } - - // Checkout action - $('#GLMcheckoutBtn').click(function() { - setBlocker(); - window.location = "{baseSCRIPT}&Action=Shop_checkout"; - }); - - function setBlocker() { - $('#glmReloadBlocker').show(); - } - - $('#GLMnavSelectEvent').on('click', function() { // Return to Event Selection - setBlocker(); - window.location = '{startURL:h}'; - }); - -/* Not using right now - // Reprint order button - $('#reprintVoucher').on('keypress', function(event) { - if(event.which == '13'){ - var orderID = $(this).val(); - var voucherWindow = window.open('{appAdminURL}&Action=Order_printVoucher&OrderID=' + orderID, - "voucherPrint", - "height=750,width=600,menubar=yes,toolbar=yes,alwaysRaised=yes,menu" - ); - voucherWindow.focus(); - voucherWindow.print(); - return false; - } - }); -*/ - - if ({vertScroll}) { - window.scrollTo(0,{vertScroll}); - } - - }); - - - diff --git a/legacy/views/front/tickets/Shop/checkout.html b/legacy/views/front/tickets/Shop/checkout.html deleted file mode 100755 index 057d6e1..0000000 --- a/legacy/views/front/tickets/Shop/checkout.html +++ /dev/null @@ -1,717 +0,0 @@ - - - -
    - -
    -
    Selected {term.ticket.plur_cap}
    - -
    - {term.nav.show_selected} - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} -
    -
    - -
    {checkoutText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -

    See below for more information.

    -
    - {end:} -
    - - -
    -
    Contact Information
    - -
    -
    -
    {text.cart.checkout.first_name}:
    -
    {text.cart.checkout.first_name}:
    - {if:formData.contact.fname.problem} -
    -
    {formData.contact.fname.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.last_name}:
    -
    {text.cart.checkout.last_name}:
    - {if:formData.contact.lname.problem} -
    -
    {formData.contact.lname.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.address}:
    -
    {text.cart.checkout.address}:
    - {if:formData.contact.addr1.problem} -
    -
    {formData.contact.addr1.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
     
    -
     
    - {if:formData.contact.addr2.problem} -
    -
    {formData.contact.addr2.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.city}:
    -
    {text.cart.checkout.city}:
    - {if:formData.contact.city.problem} -
    -
    {formData.contact.city.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.state}:
    -
    {text.cart.checkout.state}:
    - {if:formData.contact.state.problem} -
    -
    {formData.contact.state.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.country}:
    -
    {text.cart.checkout.country}:
    - {if:formData.contact.country.problem} -
    -
    {formData.contact.country.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.zip}:
    -
    {text.cart.checkout.zip}:
    - {if:formData.contact.zip.problem} -
    -
    {formData.contact.zip.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.phone}:
    -
    {text.cart.checkout.phone}:
    - {if:formData.contact.phone.problem} -
    -
    {formData.contact.phone.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.email}:
    -
    {text.cart.checkout.email}:
    - {if:formData.contact.email.problem} -
    -
    {formData.contact.email.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    {text.cart.checkout.email_again}:
    -
    {text.cart.checkout.email_again}:
    - {if:formData.contact.email2.problem} -
    -
    {formData.contact.email2.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    OK to Send E-Mail?
    - {if:formData.contact.email_ok} -
    {text.cart.checkout.activities_offers}
    - {else:} -
    {text.cart.checkout.activities_offers}
    - {end:} -
    - - {if:opt_field_1_name} -
    -
    {opt_field_1_name}:
    -
    {opt_field_1_name}:
    - {if:formData.contact.opt_field_1.problem} -
    -
    {formData.contact.opt_field_1.problem}
    - {else:} -
    - {end:} - -
    -
    - {end:} - {if:opt_field_2_name} -
    -
    {opt_field_2_name}:
    -
    {opt_field_2_name}:
    - {if:formData.contact.opt_field_2.problem} -
    -
    {formData.contact.opt_field_2.problem}
    - {else:} -
    - {end:} - -
    -
    - {end:} - {if:opt_field_3_name} -
    -
    {opt_field_3_name}:
    -
    {opt_field_3_name}:
    - {if:formData.contact.opt_field_3.problem} -
    -
    {formData.contact.opt_field_3.problem}
    - {else:} -
    - {end:} - -
    -
    - {end:} - - -
    -
    - - {foreach:cart,c} -
    -
    {term.prop.cap}: {c.name}
    - - -
    - {foreach:c.performances,p} -
    -
    -
    -
    -
    {p.name}
    -
    - - {if:option.cart_images}{if:option.cart_images}{if:p.image}{end:}{end:}{end:} -
    -
    -
    -
    - {foreach:p.dates,d} -
    -
    - - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} - -
    - - - {foreach:d.sections,s} - - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {foreach:s.tickets,i} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {if:i.descr} - - - {if:!p.oneSectionOnly} - - - {end:} - - {foreach:i.addons,a} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {end:} - - {if:i.promo} - - - {if:!p.oneSectionOnly} - - {end:} - - - - {end:} - {end:} -
    QuantSection{term.ticket.cap}PriceTotal
    - {i.selected} - {s.name}{i.title}{if:i.show_price}{i.price}{end:}{if:i.show_price}{i.extended}{end:}
      - {else:} - - {end:} - {if:option.cart_images} - {if:i.image} -
    - {end:} - {end:} -
    {i.descr:h}
    -
       -
    - {a.selected} {a.unit_name} -
    -
    {a.unit_cost}/{a.unit_name}{a.money}
      {term.promo.cap}: {promoCode}  - {i.promo.credit}
    - {end:} -
    - {end:} -
    -
    - {if:p.policy} -
    -
    - Please read and agree to our policy for this {term.performance.norm}. -
    -
    -

    {p.policy:h}

    -
    -
    -

    I agree to the policy stated above.

    -
    -
    - {end:} -
    - {end:} -
    - - {if:c.ticket_policy}
    {c.ticket_policy:h}
    {end:} - {if:c.ticket_policy}
    {c.ticket_policy:h}
    {end:} - -
    - - {if:c.ticket_spec_req.value} -
    -
    Please enter any special requests:
    -
    -
    - {end:} -
    Payment for {term.ticket.plur} at {c.name}
    -
    - - {if:c.paymentResult} - {if:c.paymentResult.approved} -
    Card Payment Approved
    -
    Card Type
    {c.paymentResult.cctype}
    -
    Name on Card
    {c.paymentResult.ccname}
    -
    Card Number
    {c.paymentResult.ccnumb}
    -
    Expiration Date
    {c.paymentResult.ccexp}
    -
    Authorization Code
    {c.paymentResult.authCode}
    -
    -
    {term.nav.print_vouchers}
    -
    - {else:} -
    Card Payment Not Complete
    -
    • {c.paymentResult.description}
    -

    Please check the payment information below and try again or contact your credit card company for assistance.

    - {if:forceCheckoutPhase} -
    -
    {term.nav.delete_from_cart}
    -
    - {end:} - {end:} - {end:} - {if:c.paymentResult.approved} -

    Payment Accepted

    - {else:} - {if:c.havePaymentMethod} - -
    - {if:c.havePayPal} - {if:c.haveMultiplePaymentMethods} -  PayPal - {else:} - - {end:} - {end:} - {if:c.haveCreditCards} - {if:c.havePayPal} -      - {end:} - {if:c.haveMultiplePaymentMethods} -  Credit Card - {else:} - - {end:} - {end:} -
    - - {if:c.haveCreditCards} - {if:c.haveMultiplePaymentMethods} - - {else:} - - {end:} -
    -
    Total Charged to this Card
    -
    {c.totalPrice}
    -
    -
    -
    Card Type
    -
    Card Type
    - {if:c.paymentForm.cctype.problem} -
    -
    {c.paymentForm.cctype.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    Name on Card
    -
    Name on Card
    - {if:c.paymentForm.ccname.problem} -
    -
    {c.paymentForm.ccname.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    Card Number
    -
    Card Number
    - {if:c.paymentForm.ccnumb.problem} -
    -
    {c.paymentForm.ccnumb.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    Expiration Date
    -
    Expiration Date
    - {if:c.paymentForm.ccexp.problem} -
    -
    {c.paymentForm.ccexp.problem}
    - {else:} -
    - {end:} - Month - - Year - -
    -
    -
    -
    Security Code
    -
    Security Code
    - {if:c.paymentForm.cccode.problem} -
    -
    {c.paymentForm.cccode.problem}
    - {else:} -
    - {end:} - -
    -
    -
    -
    - The Security Code is the three or four digit number on the signature side of your credit card. -
    -
    - - {end:} - {if:c.havePayPal} - - {if:c.haveMultiplePaymentMethods} - - {else:} - - {end:} -
    - -
    -
    - {end:} - {if:c.haveMultiplePaymentMethods} - -
    Please select a Payment Method
    -
    - {end:} - {else:} - -
    - This {term.prop.norm} does not have a payment method configured. - Please call this {term.prop.norm} to purchase {term.ticket.plur}. -
    -
    - {end:} - {end:} -
    -
    -
    - {end:} - - -
    -
    -
    Complete Purchase
    - -

    - {ssl_seal_head_script:h} - {ssl_seal_body_script:h} -

    -
    -
    -
    - -
    - -
    Grand Total
    -
    -
    - -
    {totals.price}
    -
    -
    - {if:!cartHasOneVenueOnly} -
    - NOTE: There will be a separate order number and a separate credit card transaction for each {term.prop.norm}. -
    - {end:} -
    - {if:!blockCheckout} - {term.nav.purchase} - {else:} - Unable to checkout - please see above. - {end:} -
    -
    -
    - -
    - - - - - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Shop/checkoutSuccess.html b/legacy/views/front/tickets/Shop/checkoutSuccess.html deleted file mode 100755 index c295276..0000000 --- a/legacy/views/front/tickets/Shop/checkoutSuccess.html +++ /dev/null @@ -1,367 +0,0 @@ - - - - - -
    - - -
    Purchase Complete
    - - - - - {foreach:cart,c} - {if:c.paymentResult} - {if:c.paymentResult.approved} -

    -

    *** {term.nav.print_vouchers} for {c.name} ***
    -

    - {end:} - {end:} - {end:} - - - -
    -
    - -
    -
    - -

    - Adobe Reader is required to view and print your {term.voucher.plur}. Adobe Reader is a free program available directly from Adobe. - If you do not already have Adobe Reader installed, click the "Get Adobe Reader" link now. -

    -
    -
    -
    - -

    - If you are unable to print your {term.voucher.plur}, please print this page or write down the order number(s) - below and bring that to the ticket office when you arrive. -

    - ORDER #: - {foreach:cart,c} - {if:c.paymentResult} - {if:c.paymentResult.approved} - {c.paymentResult.orderID}  - {end:} - {end:} - {end:} -
    -
    -
    - - -
    {successText:h}
    - -
    -
    Contact Information
    -
    -
    First Name:
    {formData.contact.fname.value}
    -
    Last Name:
    {formData.contact.lname.value}
    -
    Address:
    {formData.contact.addr1.value}
    -
     
    {formData.contact.addr2.value}
    -
    City:
    {formData.contact.city.value}
    -
    State:
    {formData.contact.state.value}
    -
    Country:
    {formData.contact.country.value}
    -
    ZIP/Postal Code:
    {formData.contact.zip.value}
    -
    Phone:
    {formData.contact.phone.value}
    -
    E-Mail address:
    {formData.contact.email.value}
    - {if:opt_field_1_name}
    {opt_field_1_name}:
    {formData.contact.opt_field_1.value:h}
    {end:} - {if:opt_field_2_name}
    {opt_field_2_name}:
    {formData.contact.opt_field_2.value:h}
    {end:} - {if:opt_field_3_name}
    {opt_field_3_name}:
    {formData.contact.opt_field_3.value:h}
    {end:} -
     
    - {if:formData.contact.email_ok} - You have asked us to send information on activities and offers. - {else:} - You have asked us to NOT send information on activities and offers.
    - We will only contact you regarding this order. - {end:} -
    - -
    - -
    - - - {foreach:cart,c} -
    - -
    {term.ticket.plur_cap} at: {c.name}
    - - -
    - {if:c.descr}
    {c.descr:h}
    {end:} - {if:option.cart_images}{if:c.image}{end:}{end:} - -
    - -
    - - {foreach:c.performances,p} - -
    - -
    -
    -
    - {term.performance.cap}: {p.name} -
    -
    - - {if:option.cart_images}{if:option.cart_images}{if:p.image}{end:}{end:}{end:} -
    -
    -
    - -
    - {foreach:p.dates,d} - -
    - {term.ticket.cap} date: - - {if:d.dateSpecific} - {d.fullDate} - {else:} - Use any date - {if:c.likelyDate} - - Likely Date {c.likelyDate} - {end:} - {end:} - -
    - - - {foreach:d.sections,s} - - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {foreach:s.tickets,i} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {if:i.descr} - - - {if:!p.oneSectionOnly} - - - {end:} - - {foreach:i.addons,a} - - - {if:!p.oneSectionOnly} - - {end:} - - - - - {end:} - - {if:i.promo} - - - {if:!p.oneSectionOnly} - - {end:} - - - - {end:} - {end:} -
    QuantSection{term.ticket.cap}PriceTotal
    - {i.selected} - {s.name}{i.title}{if:i.show_price}{i.price}{end:}{if:i.show_price}{i.extended}{end:}
      - {else:} - - {end:} - {if:option.cart_images} - {if:i.image} -
    - {end:} - {end:} -
    {i.descr:h}
    -
       -
    - {a.selected} {a.unit_name} -
    -
    {a.unit_cost}/{a.unit_name}{a.money}
      {term.promo.cap}: {promoCode}  - {i.promo.credit}
    - {end:} - - - {end:} - -
    - -
    - - {if:p.policy} -
    -
    -
    - Our policy for this {term.performance.norm}. -
    -

    {p.policy:h}

    -
    -
    - {end:} - - {end:} - -
    - - - - {if:!cartHasOneVenueOnly} - -
    -
    -
    -
    Sub Total
    -
    -
    -
    {c.totalPrice}
    -
    -
    -
    - {end:} - - {if:c.ticket_policy}
    {c.ticket_policy:h}
    {end:} - - - {if:c.ticket_policy}
    {c.ticket_policy:h}
    {end:} - - -
    - - - {if:c.ticket_spec_req.value} -
    -
    Special requests:
    -
    {c.paymentForm.spec_req.value:h}
    -
    - {end:} - - - {if:c.paymentResult} -
    - {if:c.paymentResult.approved} -
    Card Payment Approved
    - -
    Card Type
    {c.paymentResult.cctype}
    -
    Name on Card
    {c.paymentResult.ccname}
    -
    Card Number
    {c.paymentResult.ccnumb}
    -
    Expiration Date
    {c.paymentResult.ccexp}
    -
    Authorization Code
    {c.paymentResult.authCode}
    -
    -
    {term.nav.print_vouchers}
    -
    - {else:} -
    Card Payment Not Complete
    -
    • {c.paymentResult.description}
    -

    Please check the payment information below and try again or contact your credit card company for assistance.

    - {if:forceCheckoutPhase} -
    -
    {term.nav.delete_from_cart}
    -
    - {end:} - - {end:} - -
    - {end:} - -
    - -
    - - {end:} - -
    - {if:cartHasContents} -
    -
    Cart Totals
    -
    -
    -
    Grand Total
    -
    -
    -
    {totals.price}
    -
    -
    -
    - {else:} -

    Your cart is currently empty.

    - {end:} -
    - -
    - -{trackingScript:h} - - - - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Shop/paymentSummary.html b/legacy/views/front/tickets/Shop/paymentSummary.html deleted file mode 100644 index de870b4..0000000 --- a/legacy/views/front/tickets/Shop/paymentSummary.html +++ /dev/null @@ -1,103 +0,0 @@ -

    - - Click here to reprint your {term.voucher.plur} - -

    - -

    - {term.ticket.plur_cap} Purchased at:
    - {cartEntry.name} -

    - - -{if:cartEntry.descr}

    {cartEntry.descr:h}

    {end:} - - - - - - - - - - - -{foreach:cartEntry.performances,p} - {foreach:p.dates,d} - {foreach:d.sections,s} - - - {foreach:s.tickets,i} - - - - - - - - {foreach:i.addons,a} - - - - - - - - {end:} - {if:i.promo} - - - - - - - {end:} - {end:} - - - {end:} - {end:} -{end:} - - - - - - - - -
    Quant{term.performance.cap}{term.ticket.cap}PriceTotal
    {i.selected}{p.name:h}{i.title:h}{if:i.show_price}{i.price}{end:}{if:i.show_price}{i.extended}{end:}
       -
    - {a.selected} {a.unit_name} -
    -
    {a.unit_cost}/{a.unit_name}{a.money}
      {term.promo.cap}: {promoCode}  - {i.promo.credit}
     {cartEntry.totalPrice}
    - - -{if:cartEntry.ticket_spec_req} -

    - Special requests: {cartEntry.paymentForm.spec_req.value:h} -

    -{end:} - - -{if:cartEntry.ticket_policy}

    {cartEntry.ticket_policy:h}

    {end:} - -

    - - - - - - - -
    Credit Card Payment Approved
    Card Type{cartEntry.paymentResult.cctype}
    Name on Card{cartEntry.paymentResult.ccname}
    Card Number{cartEntry.paymentResult.ccnumb}
    Expiration Date{cartEntry.paymentResult.ccexp}
    Authorization Code{cartEntry.paymentResult.authCode}
    -

    - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Shop/sectionSelect.html b/legacy/views/front/tickets/Shop/sectionSelect.html deleted file mode 100755 index 54bf3d5..0000000 --- a/legacy/views/front/tickets/Shop/sectionSelect.html +++ /dev/null @@ -1,96 +0,0 @@ - - - - - - -
    - - -
    {term.section.cap} Selection
    - - - - - -
    {sectionText:h}
    - -{if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    -{end:} - -

    You have selected

    -
    -
    -
    -
    {performanceDetail.member_name}

    -
    {performanceDetail.name}
    -
    -
    - - -
    -
    -
    - - -
    -

    Please select from the following

    -
    -{foreach:sectionList,x} -
    - -
    -

    {term.section.cap}: {x.member_name}

    -

    {x.descr:h}

    -
    -
    -{end:} - -
    - -
    - - {startScript:h} - - $(document).ready(function(){ - - // Code to kick off the geolocation-display feature - $("#locationMap").geolocate({ - lat: "#lat", - lng: "#lon", - mapOptions: { - disableDefaultUI: false, - mapTypeControl: true, - mapTypeId: "roadmap", - zoom: 12 - }, - markerOptions: { - draggable: false, - title: "This is your selected location" - } - }); - - }); - - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Shop/start.html b/legacy/views/front/tickets/Shop/start.html deleted file mode 100644 index 0433743..0000000 --- a/legacy/views/front/tickets/Shop/start.html +++ /dev/null @@ -1,398 +0,0 @@ - - - -
    - -
    -
    {term.event.cap} Selection
    - - -
    - -
    {introText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    - {end:} -

    Please select from the following

    -{if:showTickets} -
    - - - - -{end:} - - {foreach:membersList,m} -
    -
    -
    -
    -
    {m.name}
    -
    -
    -
    Address: {m.addr1}{if:m.addr2}, {m.addr2}{end:}, {m.city}
    -
    Phone #: {m.phone}
    -
    {m.descr:h}
    -
    -
    - {if:option.select_images} - {if:m.image} -
    - {end:} - {end:} - -
    - {foreach:m.performances,p} -
    -
    -
    -
    - {if:showTickets} - {p.name} - {else:} - {p.name} - {end:} -
    -
    -
    -
    {term.prop.cap}: {p.member_name}
    -
    Dates: {p.start_date.date} through {p.end_date.date}
    -
    {p.descr:h}
    -
    -
    - {if:option.select_images} - {if:p.image} -
    - {end:} - {end:} - {if:!showTickets} - - {end:} - - - - {foreach:p.sections,s} -

     

    -
    -
    -
    - {if:!p.oneSectionOnly} - {s.sectionDetail.name}
    - {end:} - -
    - -
    -
    - - - {foreach:s.ticketsData,x} -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    -
    Price: 
    -
    -
    {x.price}
    -
    -
    -
    -
    Select date: 
    -
    -
    - - -
    -
    -
    -
    -
    Quant: 
    -
    -
    (select date)
    -
    -
    -
    - - {end:} - -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    {x.title}
    - {else:} -
    - {x.name} -
    - {term.nav.select} - {end:} -
    -
    - {if:x.descr} -

    {x.descr:h}

    - {end:} -
    - {if:!x.date_specific.value} - Use any date{if:x.start_date.timestamp} from {x.start_date.date} to {x.end_date.date}{end:}{if:!x.time_specific.value}, {end:} - {end:} - {if:!x.time_specific.value} - Use any time of day, - {else:} - Time: {x.ticket_time.time}, - {end:} - {if:x.unlimted_use.value} - Each {term.ticket.norm} may be used an unlimited number of times - {else:} - - {end:} -
    -
    -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    -
    Price each: 
    -
    -
    {x.price}
    -
    -
    -
    -
    Select date: 
    -
    -
    - - -
    -
    -
    -
    -
    Quant: 
    -
    -
    (select date)
    -
    -
    -
    - - {end:} -
    - - - {end:} - -
    - - {end:} - - - -
    - {end:} -
    -
    - {end:} -{if:showTickets} - -
    -{end:} -
    - -{startScript:h} - - var addButtonPushed = false; - - // Dates for inventory data - var tickets = {ticketsJSON:h}; - - var ticketQuantSelection = '\ - \ - '; - - var ticketTooLate = '\ -

    \ - Sorry, too late to select these {term.ticket.plur} on-line.\ -

    \ - '; - - - - $(document).ready(function(){ - - // Code to kick off the geolocation-display feature - function doLocationMap(id) { - $("#locationMap_" + id).geolocate({ - lat: "#lat_" + id, - lng: "#lon_" + id, - mapOptions: { - disableDefaultUI: false, - mapTypeControl: true, - mapTypeId: "roadmap", - zoom: 12 - }, - markerOptions: { - draggable: false, - title: "This is your selected location" - } - }); - } - {foreach:membersList,m} - doLocationMap({m.id}); - {end:} - - // DatePicker action - function avail(date) { - m = (date.getMonth()+1); - if (m < 10) { - m = '0' + m; - } - d = date.getDate(); - if (d < 10) { - d = '0' + d; - } - y = date.getFullYear(); - mdy = m + '/' + d + '/' + y; - if (dates[mdy]) { - return [true,"","Available"]; - } else { - return [false,"","Not Available"]; - } - } - - // for each ticket - $.each(tickets, function(index, ticket) { - - var inventory = ticket.inventory; - - // Build date data array and count dates for this ticket - var dateCount = 0; - var dateData = false - $.each(inventory, function(index, date) { - - // Count the number of dates - dateCount++; - - // If this is the first one, store it in case it's the only one - dateData = date; - - }); // each date - - // if there's no date specific tickets - if (!ticket.dateSpecific) { - - // Populate date input field - $('#GLMeventDateSelect_' + ticket.id).html(''); - doQuantSelection(ticket.id, dateData.id, dateData.available, dateData.tooLate); - - // if there's only one date, then display that and move on. - } else if (!ticket.dateSpecific || dateCount == 1) { - - // populate date input field - $('#GLMeventDate_' + ticket.id).html('
    Date:
    ' + dateData['date'] + '
    '); - doQuantSelection(ticket.id, dateData.id, dateData.available, dateData.tooLate); - - } else { - - // DatePicker action - function avail(date) { - m = (date.getMonth()+1); - if (m < 10) { - m = '0' + m; - } - d = date.getDate(); - if (d < 10) { - d = '0' + d; - } - y = date.getFullYear(); - mdy = m + '/' + d + '/' + y; - if (inventory[mdy]) { - return [true,"","Available"]; - } else { - return [false,"","Not Available"]; - } - } - - // Use the date picker to select a date - $('#GLMeventDateInput_' + ticket.id).datepicker({ - beforeShowDay: avail, - dateFormat: "mm/dd/yy", -// *** NEED TO FIX REFERENCE TO "performanceDetail" since that's not available on this page - minDate: "{performanceDetail.start_date.date}", - maxDate: "{performanceDetail.end_date.date}", - onSelect: function(selectedDate, inst) { - // Get data for the selected date - dateData = inventory[selectedDate]; - $('#GLMeventInvID_' + ticket.id).val(dateData.id); - doQuantSelection(ticket.id, dateData.id, dateData.available, dateData.tooLate); - } // Date Selection - - }); // Date Picker - - - } - - }); // each ticket - - function doQuantSelection(id, invId, available, tooLate) { - - // Build the ticket quant options - var ticketQuants = ''; - var selectMax = available; - if (selectMax > 50) { - selectMax = 50; - } - - if (tooLate) { - $('#GLMticketQuantContainer_' + id).html(ticketTooLate); - } else { - - // note that the braced lte below is needed to inject a less-than-or-equal-to operator without having flexy chew on it. - for (var i = 1; i {lte:h} (selectMax*1); i++) { - ticketQuants = ticketQuants.concat(''); - } - - // Populate the ticket quantity container - tmpQuantSel = ticketQuantSelection.replace(/\[id\]/g, id); - $('#GLMticketQuantContainer_' + id).html(tmpQuantSel.replace(/\[ticket-quants\]/g, ticketQuants)); - } - - } - - $('#GLMselectButton').click(function() { - - // Check for a selected ticket - var ticketSelected = false; - $('.glmTicketQuant').each(function( index ) { - if ($(this).val() != '') { - ticketSelected = true; - } - }); - - if (ticketSelected) { - selectButtonPressed = true; - setBlocker(); - $('#GLMselectForm').submit(); - } else { - alert('Please select a {term.ticket.norm} quantity.') - return false; - } - - }); - - function setBlocker() { - $('#glmReloadBlocker').show(); - } - - }); - - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Shop/ticketOpt.html b/legacy/views/front/tickets/Shop/ticketOpt.html deleted file mode 100755 index 5acf967..0000000 --- a/legacy/views/front/tickets/Shop/ticketOpt.html +++ /dev/null @@ -1,273 +0,0 @@ - - - - - -
    - -
    -
    Ticket Selection
    - - -
    - -
    {ticketOptText:h}
    - {if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    - {end:} -

    You have selected

    - -
    -
    -
    -
    {performanceDetail.name}
    -
    -
    -
    {term.prop.cap}: {performanceDetail.member_name}
    - - -
    -
    -
    -
    -
    {sectionDetail.name}
    -
    -
    - -
    -
    -
    -
    -
    {ticketDetail.name}
    -
    -
    - {if:!ticketDetail.date_specific.value} -
    Use any date {if:ticketDetail.start_date.timestamp} from {ticketDetail.start_date.date} to {ticketDetail.end_date.date}{end:}
    - {end:} - {if:!ticketDetail.time_specific.value} -
    Use any time
    - {else:} -
    Time: {ticketDetail.ticket_time.time}
    - {end:} - {if:!ticketDetail.unlimted_use.value} - - {else:} -
    Each {term.ticket.norm} may be used an unlimited number of times
    - {end:} -
    {ticketDetail.descr:h}
    -
    -
    -
    - -

    Please select from the following

    -
    -
    -
    -
    -
    -
    -
    -
    Select desired date:
    -
    -
    (click in field to set date)
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    Select Quantity:
    -
    -
    (please select date first)
    -
    -
    -
    -
    - {if:reason}
    (disabled - please see above)
    {else:}
    {term.nav.add_to_cart}
    {end:} -
    - -{startScript:h} - - // Whether ticket has date specific inventory - var dateSpecific = {ticketDetail.date_specific.value} + 0; - - // Dates for inventory data - var dates = {inventoryJSON:h}; - - $(document).ready(function(){ - - // DatePicker action - function avail(date) { - m = (date.getMonth()+1); - if (m < 10) { - m = '0' + m; - } - d = date.getDate(); - if (d < 10) { - d = '0' + d; - } - y = date.getFullYear(); - mdy = m + '/' + d + '/' + y; - if (dates[mdy]) { - return [true,"","Available"]; - } else { - return [false,"","Not Available"]; - } - } - var dateData = false; - - var ticketQuantSelection = '\ - \ - '; - var ticketTooLate = '\ -

    \ - Sorry, too late to select these {term.ticket.plur} on-line.\ - {term.ticket.plur_cap} must be purchased at least {detail.performance.purch_leadtime} hours prior to the {term.performance.norm}.\ - Please select another date or time.\ -

    \ - '; - var selectedInv; - var ticketQuants; - var addButtonPushed = false; - - // Start by counting the number of dates to see if we have only 1 - var dateCount = 0; -// if (dateSpecific) { - $.each(dates, function(index, date) { - dateCount = dateCount + 1; - dateData = date; - }); -// } - // if there's no date specific tickets - if (!dateSpecific) { - // Populate date input field - $('#GLMeventDateSelectBlock').html(''); - doQuantSelection(); - // if there's only one date, then display that and move on. - } else if (!dateSpecific || dateCount == 1) { - // populate date input field - $('#GLMeventDate').val(dateData['date']); - $('#GLMtickets').html('
    Date:
    ' + dateData['date'] + '
    '); - - doQuantSelection(); - } else { - // Use the date picker to select a date - dateData = false; - $("#GLMeventDate").datepicker({ - beforeShowDay: avail, - dateFormat: "mm/dd/yy", - minDate: "{performanceDetail.start_date.date}", - maxDate: "{performanceDetail.end_date.date}", - onSelect: function(selectedDate, inst) { - // Update input message - $('#GLMdateMessage').html('
    '); - - // Get data for the selected date - dateData = dates[selectedDate]; - doQuantSelection(); - } // Date Selection - - }); // Date Picker - - } - - function doQuantSelection() { - // Build the ticket quant options - ticketQuants = ''; - var selectMax = dateData['available']; - if (selectMax > 50) { - selectMax = 50; - } - var tooLate = dateData['tooLate']; - if (tooLate) { - $('#GLMticketQuantContainer').html(ticketTooLate); - } else { - // note that the braced lte below is needed to inject a less-than-or-equal-to operator without having flexy chew on it. - for (var i = 1; i {lte:h} (selectMax*1); i++) { - ticketQuants = ticketQuants.concat(''); - } - - // Populate the ticket quantity container - $('#GLMticketQuantContainer').html(ticketQuantSelection.replace(/\[ticket-quants\]/g, ticketQuants)); - } -// doAddToCartSetup(); - } - -// function doAddToCartSetup() { - // Add to cart action - $('#GLMaddToCart').click(function() { - if (addButtonPushed) { - return; - } - var reason = ''; - // Check date - if (dateData) { - selectedInv = dateData.id; - } else { - reason = reason.concat('* You need to select a date first.\n'); - } - // Check quantity - var selectedQuant = (parseInt($('#glmQuantSelector').val()) + 0); - if (selectedQuant == 0) { - reason = reason.concat('* You need to select a quantity first.\n'); - } - // Check if there's a reason we can't add this to the cart yet - if (reason != '') { - alert(reason); - return; - } - // Adding to cart - addButtonPushed = true; - $("#GLMeventDate").datepicker('disable'); - $('#glmQuantSelector').prop('disabled', 'disabled'); - setBlocker(); - // Submit to cart - window.location = "{baseSCRIPT}&Action=Shop_cart&cart=add&PerformanceID={performanceDetail.id}&SectionID={sectionDetail.id}&TicketID={ticketDetail.id}&ticket_inv=" + selectedInv + "&quant=" + selectedQuant; - - }); -// } - // Code to kick off the geolocation-display feature - $("#locationMap").geolocate({ - lat: "#lat", - lng: "#lon", - mapOptions: { - disableDefaultUI: false, - mapTypeControl: true, - mapTypeId: "roadmap", - zoom: 12 - }, - markerOptions: { - draggable: false, - title: "This is your selected location" - } - }); - // Navigation buttons - $('#GLMnavCart').click(function() { // Add to Cart - window.location = '{baseSCRIPT}&Action=Shop_cart'; - }); - $('#GLMnavSelectEvent').on('click', function() { // Return to Event Selection - window.location = '{startURL:h}'; - }); - - function setBlocker() { - $('#glmReloadBlocker').show(); - } - - }); - - \ No newline at end of file diff --git a/legacy/views/front/tickets/Shop/ticketSelect.html b/legacy/views/front/tickets/Shop/ticketSelect.html deleted file mode 100644 index 290249b..0000000 --- a/legacy/views/front/tickets/Shop/ticketSelect.html +++ /dev/null @@ -1,310 +0,0 @@ - - - -
    - -
    -
    {term.ticket.cap} Selection
    - -
    - {term.nav.show_selected} - {if:!option.ticket_selection.start_at_cart} - {term.nav.select_more} - {end:} -
    -
    - -
    {ticketText:h}
    -{if:reason} -
    -
    We're sorry, we had a problem with your request:
    -
      - {foreach:reason,r} -
    • {r:h}
    • - {end:} -
    -
    -{end:} -

    You have selected

    - - - -{foreach:sections,s} -
    -
    - - -
    - {if:performanceDetail.image} -
    - {end:} -
    - -
    -
    {performanceDetail.member_name:h}

    -
    {performanceDetail.name:h}
    -
    -
    -
    - {if:!oneSectionOnly} - {s.sectionDetail.name}
    - {end:} - -
    - - {if:performanceDetail.descr} - {performanceDetail.descr:h} - {end:} -
    -
    -
    -
    -
    - -

    Please select from the following

    -
    -
    - - - - - {foreach:s.ticketsData,x} -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    -
    -
    Price: 
    -
    -
    {x.price}
    -
    -
    -
    -
    Select date: 
    -
    -
    - - -
    -
    -
    -
    -
    Quant: 
    -
    -
    (select date)
    -
    -
    -
    - {end:} -
    - {if:option.ticket_selection.include_options_in_ticket_list} -
    {x.title}
    - {else:} -
    - {x.name} -
    - {end:} -
    -
    - {if:x.descr} -

    {x.descr:h}

    - {end:} -

    - {if:!x.date_specific.value} - Use any date{if:x.start_date.timestamp} from {x.start_date.date} to {x.end_date.date}{end:}{if:!x.time_specific.value}, {end:} - {end:} - {if:!x.time_specific.value} - Use any time of day, - {else:} - Time: {x.ticket_time.time}, - {end:} - {if:x.unlimted_use.value} - Each {term.ticket.norm} may be used an unlimited number of times - {else:} - - {end:} -

    -
    -
    -
    -
    - {end:} - -
    -
    - -{end:} - -
    - -{if:option.ticket_selection.include_options_in_ticket_list} - - {startScript:h} - - var addButtonPushed = false; - - // Dates for inventory data - var tickets = {ticketsJSON:h}; - - var ticketQuantSelection = '\ - \ - '; - - var ticketTooLate = '\ -

    \ - Sorry, too late to select these {term.ticket.plur} on-line.\ - {term.ticket.plur_cap} must be purchased at least [hours] hours prior to the {term.performance.norm}.\ - Please select another date or time.\ -

    \ - '; - - - $(document).ready(function(){ - - // for each ticket - $.each(tickets, function(index, ticket) { - - var inventory = ticket.inventory; - - // Build date data array and count dates for this ticket - var dateCount = 0; - var dateData = false - $.each(inventory, function(index, date) { - - // Count the number of dates - dateCount++; - - // If this is the first one, store it in case it's the only one - dateData = date; - - }); // each date - - // if there's no date specific tickets - if (!ticket.dateSpecific) { - - // Populate date input field - $('#GLMeventDateSelect_' + ticket.id).html(''); - doQuantSelection(ticket.id, dateData.id, dateData.available, ticket.tooLate); - - // if there's only one date, then display that and move on. - } else if (!ticket.dateSpecific || dateCount == 1) { - - // populate date input field - $('#GLMeventDateSelect_' + ticket.id).html(' \ -
    Date Available: 
    \ -
    \ -
    \ - ' + dateData.ticket_date.date + ' \ - \ -
    \ -
    '); - - doQuantSelection(ticket.id, dateData.id, dateData.available, ticket.tooLate); - - } else { - - // DatePicker action - function avail(date) { - m = (date.getMonth()+1); - if (m < 10) { - m = '0' + m; - } - d = date.getDate(); - if (d < 10) { - d = '0' + d; - } - y = date.getFullYear(); - mdy = m + '/' + d + '/' + y; - if (inventory[mdy]) { - return [true,"","Available"]; - } else { - return [false,"","Not Available"]; - } - } - - // Use the date picker to select a date - if($('#GLMeventDateInput_' + ticket.id).length > 0) { - $('#GLMeventDateInput_' + ticket.id).datepicker({ - beforeShowDay: avail, - dateFormat: "mm/dd/yy", - minDate: ticket.startDate, - maxDate: ticket.endDate, - onSelect: function(selectedDate, inst) { - // Get data for the selected date - dateData = inventory[selectedDate]; - $('#GLMeventInvID_' + ticket.id).val(dateData.id); - doQuantSelection(ticket.id, dateData.id, dateData.available, ticket.tooLate); - } // Date Selection - - }); // Date Picker - } - - } - - }); // each ticket - - function doQuantSelection(id, invId, available, tooLate) { - - // Build the ticket quant options - var ticketQuants = ''; - var selectMax = available; - if (selectMax > 50) { - selectMax = 50; - } - - if (tooLate) { - $('#GLMticketQuantContainer_' + id).html(ticketTooLate.replace(/\[hours\]/g, {performanceDetail.purch_leadtime})); - } else { - // note that the braced lte below is needed to inject a less-than-or-equal-to operator without having flexy chew on it. - for (var i = 1; i {lte:h} (selectMax*1); i++) { - ticketQuants = ticketQuants.concat(''); - } - - // Populate the ticket quantity container - tmpQuantSel = ticketQuantSelection.replace(/\[id\]/g, id); - $('#GLMticketQuantContainer_' + id).html(tmpQuantSel.replace(/\[ticket-quants\]/g, ticketQuants)); - } - - } - - var selectButtonPressed = false; - - $('#GLMselectButton').click(function() { - - // Prevent multiple submissions - if (selectButtonPressed == true) { - return; - } - - // Check for a selected ticket - var ticketSelected = false; - $('.glmTicketQuant').each(function( index ) { - if ($(this).val() != '') { - ticketSelected = true; - } - }); - - if (ticketSelected) { - selectButtonPressed = true; - setBlocker(); - $('#GLMselectForm').submit(); - } else { - alert('Please select a {term.ticket.norm} quantity.') - return false; - } - - }); - - function setBlocker() { - $('#glmReloadBlocker').show(); - } - - - }); - -{end:} - \ No newline at end of file diff --git a/legacy/views/front/tickets/foot.html b/legacy/views/front/tickets/foot.html deleted file mode 100755 index 36eb69f..0000000 --- a/legacy/views/front/tickets/foot.html +++ /dev/null @@ -1,9 +0,0 @@ - -{if:option.development} -

    - Running on Development Server: - - Reset Session - -

    -{end:} \ No newline at end of file diff --git a/legacy/views/front/tickets/head.html b/legacy/views/front/tickets/head.html deleted file mode 100644 index 2b09b3e..0000000 --- a/legacy/views/front/tickets/head.html +++ /dev/null @@ -1,38 +0,0 @@ - -{startScript:h} - // Pass some reference parameters to JAVAScript - var baseSiteURL = '{baseURL}'; - var baseAppURL = '{baseAppURL}'; - -{if:!jQueryLoaded} - -{end:} -{if:!jQueryUiLoaded} - - -{end:} - - - -{if:customCssFile} - - -{end:} -{if:frontDebug} - -
    -{end:} -{startScript:h} - var disp_setting="toolbar=no,location=no,directories=no,menubar=no,scrollbars=yes,width=1000, height=700, left=100, top=25"; - {if:frontDebug} - debugWindowFront = window.open("{baseURL}index.php?Action=Debug_update","emDebugWindowFront",disp_setting); - {end:} - - -
    -
    Updating your information
    Please wait ...
    -
    - - {if:adminUser} -

    Purchasing By Admin User

    - {end:} diff --git a/legacy/views/front/tickets/index.html b/legacy/views/front/tickets/index.html deleted file mode 100755 index fca55f0..0000000 --- a/legacy/views/front/tickets/index.html +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - -

    PLEASE NOTE:

    - -

    - There is no general access to this site. - All access to this site should be through an appropriate link. - If you arrived here by mistake (or exploring), nothing but this message will be displayed. - If you have any concerns about this site, please contact Gaslight Media. -

    - -

    - Gaslight Media
    - 120 East Lake Street
    - Petoskey, MI 49770
    -  
    - Phone: 231-487-0692
    - E-Mail: info@gaslightmedia.com
    - Web: http://www.gaslightmedia.com -

    - - - - - - diff --git a/legacy/web/admin/icons/calendar.png b/legacy/web/admin/icons/calendar.png deleted file mode 100755 index 6589138..0000000 Binary files a/legacy/web/admin/icons/calendar.png and /dev/null differ diff --git a/legacy/web/admin/icons/information.png b/legacy/web/admin/icons/information.png deleted file mode 100755 index 12cd1ae..0000000 Binary files a/legacy/web/admin/icons/information.png and /dev/null differ diff --git a/legacy/web/admin/icons/page_edit.png b/legacy/web/admin/icons/page_edit.png deleted file mode 100755 index 046811e..0000000 Binary files a/legacy/web/admin/icons/page_edit.png and /dev/null differ diff --git a/legacy/web/admin/tickets/documentation/VenueAdminGuide.pdf b/legacy/web/admin/tickets/documentation/VenueAdminGuide.pdf deleted file mode 100755 index 2daf7aa..0000000 Binary files a/legacy/web/admin/tickets/documentation/VenueAdminGuide.pdf and /dev/null differ diff --git a/legacy/web/admin/tickets/tickets.css b/legacy/web/admin/tickets/tickets.css deleted file mode 100755 index 4b87f3d..0000000 --- a/legacy/web/admin/tickets/tickets.css +++ /dev/null @@ -1,549 +0,0 @@ -/* Event Management - Tickets interface */ -body { - padding-right: 10px; - font-family: Helvetica, Arial, sans-serif; -} -.emMainTabs { - -} -.emTabSpace { - position: relative; - float: left; - padding: .5em; -} -.emMainTabs .emTab { - position: relative; - z-index: 30; - float: left; - /* width: 28.33333333%; */ - padding: .2em; - padding-right: .4em; - margin-right: .5em; - background: #CCC; - border-radius: 5px 5px 0 0; - font-size: .8em; - font-weight: normal; - color: #333; - border-top: 1px solid #aaa; - border-left: 1px solid #aaa; - border-right: 1px solid #aaa; -} -.emMainTabs .emTabSelected { - background: #AED7FF; - border-top: 1px solid #09F; - border-left: 1px solid #09F; - border-right: 1px solid #09F; - z-index: 10; - bottom: -1px; -} -.emRight { - float: right; -} -.emSubTabs { - -} -.emSubTabs .emTab { - position: relative; - z-index: 30; - float: left; - /* width: 28.33333333%; */ - padding: .2em; - padding-right: .4em; - margin-right: .5em; - background: #CCC; - border-radius: 5px 5px 0 0; - font-size: .8em; - font-weight: normal; - color: #333; - border-top: 1px solid #aaa; - border-left: 1px solid #aaa; - border-right: 1px solid #aaa; -} -.emSubTabs .emTabSelected { - background: #AED7FF; - border-top: 1px solid #09F; - border-left: 1px solid #09F; - border-right: 1px solid #09F; - z-index: 10; - bottom: -1px; -} -.emUsdTabs .emTab { - position: relative; - z-index: 30; - float: left; - /* width: 28.33333333%; */ - padding: .2em; - padding-right: .4em; - margin-right: .5em; - margin-bottom: 2px; - background: #CCC; - border-radius: 5px 5px 5px 5px; - font-size: .8em; - font-weight: normal; - color: #333; - border-top: 1px solid #aaa; - border-left: 1px solid #aaa; - border-right: 1px solid #aaa; -} -.emUsdTabs .emTabSelected { - background: #AED7FF; - border-top: 1px solid #09F; - border-left: 1px solid #09F; - border-right: 1px solid #09F; - z-index: 10; - bottom: -1px; -} -.emUsdTabs .emPseudoTab{ - position: relative; - z-index: 30; - float: left; - /* width: 28.33333333%; */ - padding: .2em; - padding-right: .4em; - margin-right: .5em; - margin-bottom: 2px; - background: #CCC; - border-radius: 5px 5px 5px 5px; - font-size: .8em; - font-weight: normal; - color: #333; - border-top: 1px solid #aaa; - border-left: 1px solid #aaa; - border-right: 1px solid #aaa; -} -.emContentArea { - clear: left; - padding: 4px; - background: #AED7FF; - border: 1px solid #09F; - margin-bottom: 5px; -} -.emContentAreaHidden { - display: none; -} -.emBlock { - padding: 3px; - background: #fff; - border-radius: 4px 4px 4px 4px; - z-index: 20; - overflow: hidden; - clear: both; -} -.emMainBlock { - -} -.emSubBlock { - -} -.emBlockName { - font-size: 1.2em; - font-weight: bold; - color: #333; - margin-bottom: 5px; -} -.emBlockSeparator { - clear: left; - margin: 0 0 10px 0px; - border-top: 1px solid #000; -} -.emBlockSection { - margin-top: 5px; -} -.emBlockSectionHEad { - padding-left: 10px; - margin-bottom: 5px; - font-weight: bold; -} -.emItem { - -} -.emItemName, .emItemValue { - display: block; - float: left; - width: 40%; -} -.emItemName { - clear: left; -} -.emItemName:after { - content: " :"; -} -.emLink { - cursor: pointer; - color: #0077cc; -} -/* for things we want to look like links but that don't trigger normal actions */ -.emPseudoLink { - cursor: pointer; - color: #0077cc; -} -.emLink:hover { - color: #549BB1; -} -#EMfoot { - text-align: center; -} - -.emSummary, .emListContainer { - overflow: hidden; - padding: 4px 1%; -/* margin-bottom: 16px; */ - background: #FFF; - /* box-shadow: inset 0 0 14px rgba(0,0,0,.6); */ -/* margin-top: 8px; */ - border-radius: 4px; -} -.emListContainer { - display: table; - width: 96%; -} -.emListContainerShort { - height: 5em; - overflow: scroll; -} -.emLoading { - font-size: 2em; - color: red; - opacity: 0.2; - -} -.emLoadingSmall { - font-size: 1em; - color: red; - opacity: 0.2; - -} -.emNotices { - border: 1px solid red; - padding: 5px; - padding-left: 20px; - margin: 0px; -} -.emNoticeHead { - font-size: 1.5em; - color: red; - padding: 0px; - margin: 0px; -} -.emNotice { -} -.emForm { -} -.emFormReqField { - color: red; -} -/* DataTables Styling */ -.emListTableContainer { - margin-top: 5px; - margin-bottom: 5px; - border: 1px solid #ccc; - clear: both; -} -.emListTableContainerLeft { - margin-top: 5px; - margin-bottom: 5px; - border: 1px solid #ccc; - float: left; - clear: both; - width: 90%; -} -.emListTable { - font-size: .8em; - border: 1px solid #ccc; - spacing: 0px; - border-collapse:collapse; - text-align: left; -} -.emListTable tr.even { - border: 1px solid #ccc; - background: #fff; -} -.emListTable tr.even th { - border: 1px solid #ccc; - white-space: nowrap; - background: #eee; -} -.emListTable tr.even td { - border: 1px solid #ccc; -} -.emListTable tr.odd { - border: 1px solid #ccc; - background: #fff; -} -.emListTable tr.odd th { - border: 1px solid #ccc; - white-space: nowrap; - background: #eee; -} -.emListTable tr.odd td { - border: 1px solid #ccc; -} -.emListTable thead { - background: #eee; - color: #000; -} -.emListTable thead tr th{ - border: 1px solid #ccc; - white-space: nowrap; -} -.emListTable thead tr td { - border: 1px solid #ccc; -} -.emListTable tbody { - background: #fff; - color: #000; -} -.emListTable tbody tr.even { - border: 1px solid #ccc; - background: #fff; -} -.emListTable tbody tr.even th { - border: 1px solid #ccc; - white-space: nowrap; -} -.emListTable tbody tr.even th.sorting_1 { - border: 1px solid #ccc; - background: #fff; -} -.emListTable tbody tr.even td { - border: 1px solid #ccc; -} -.emListTable tbody tr.even td.sorting_1 { - border: 1px solid #ccc; - background: #fff; -} -.emListTable tbody tr.odd { - border: 1px solid #ccc; - background: #fff; -} -.emListTable tbody tr.odd th { - border: 1px solid #ccc; - white-space: nowrap; -} -.emListTable tbody tr.odd th.sorting_1 { - border: 1px solid #ccc; - background: #fff; -} -.emListTable tbody tr.odd td { - border: 1px solid #ccc; -} -.emListTable tbody tr.odd td.sorting_1 { - border: 1px solid #ccc; - background: #fff; -} -.sorting_asc { - background: #000 url("../images/sort_asc.png") no-repeat scroll right center transparent; -} -.sorting_desc { - background: #000 url("../images/sort_desc.png") no-repeat scroll right center transparent; -} -/* Input Form Items */ -.emRequiredInputField { - color: red; -} -.emBadInputField { - background: #FFaBa9; -} -input.emTextInput { - width: 80%; -} -input.emTextInputMedium { - width: 120px; -} -input.emTextInputLong { - width: 100%; -} -input.emTextInputShort { - width: 80px; -} -input.emTextInputVeryShort { - width: 30px; -} -input.emTextInputGeoDegMin { - width: 2.5em; -} -input.emTextInputGeoSec { - width: 5em; -} -.emMapWindowDetail { - width: 200px; - height: 150px; - border: 1px solid #333; -} -.emMapWindowEdit { - width: 450px; - height: 250px; - border: 1px solid #333; -} -.showAsOverlay { - position: fixed; - z-index: 10000; - margin: auto; - margin-left: 20px; - box-shadow: 0px 0px 0px 20px rgba(0,0,0,0.8); - display: none; - background: black; - color: white; -} - -/* Calendar Styles */ -.emCalendars { - font-size: .7em; - width: 100%; -} -.emCalMonth { - display: table; - table-layout: fixed; - width: 95%; - border-collapse: collapse; - border: 2px solid #333; - margin: auto; - margin-top: 1em; -} -.emCalMonthName { - display: table-caption; - caption-side: top; - text-align: center; - padding: .5em; - border: 1px solid #333; - font: 2em bold; - background: #AED7FF; -} -.emCalMonthColumn { - display: table-column; -} -.emCalHead { - display: table-row; -} -.emCalHeadCell { - display: table-cell; - text-align: center; - border: 1px solid #333; - padding: .3em; - background-color: #333; - color: #fff; -} -.emCalWeek { - display: table-row; -} -.emCalNoDateCell { - display: table-cell; - background-color: #666; - border: 1px solid #333; -} -.emCalDateCell { - display: table-cell; - border: 1px solid #333; - background-color: #ccc; -} -.emCalDate{ - font-weight: bold; - margin-bottm: 2em; - clear: both; -} -.emCalDateTitle { - float: left; - padding: .2em; - height: 1em; - font-size: 1.5em; - font-weight: bold; - color: white; -} -.emCalDateEditLinks { - float: right; - padding: .3em; -} -.emCalData { - padding: .3em; - clear: both; - height: 4em; -} -.emCalDataRow { - clear: both; -} -.emCalCap { - font-weight: bold; - float: left; -} -.emCalValue{ - font-weight: normal; - float: right; -} -.emCalDateCellSelectable { - cursor: pointer; -} -.emCalDateCellSelectable:hover { - background-color: #eee; -} -.emCalDateCellSelected { - background-color: #cde9ff; -} -.emCalDateCellSelected:hover { - background-color: #aed7ff; -} -.emCalEditContainerHidden { - display: none; -} -.emCalEditForm { - font-size: .8em; - font-weight: normal; -} -.emCalEditField { - clear: both; -} -.emCalEditPrompt { - float: left; -} -.emCalEditValue { - float: right; -} -.emCalEditValueLeft { - float: left; -} -.zTop { - z-index: 10000; -} -.emTextHighlight { - color: #0077cc; -} -.GLMreason { -} -.GLMreasonTitle { - font-weight: bold; -} -.GLMreasonList { - color: red; - padding: 0px; - margin: 0px; -} -.GLMloginStatusField { - white-space:nowrap; - font-size: .8em; - margin-right: 2em; -} -.GLMloginStatusPrompt { - font-weight: bold; -} -.GLMinfoValue { - -} -.submitKeepOnPage { - padding: 10px; - background-color: #fff; - position: fixed; - bottom: 10px; - left: 50px; - border: 5px solid #AED7FF; - border-radius: 4px 4px 4px 4px; - z-index: 1000; -} -.scanVoucherResultNone { - background-color: lightgray; -} -.scanVoucherResultClaimed { - background-color: lightgreen; -} -.scanVoucherResultUsed { - background-color: red; -} - diff --git a/legacy/web/admin/tickets/tickets.js b/legacy/web/admin/tickets/tickets.js deleted file mode 100644 index eafb822..0000000 --- a/legacy/web/admin/tickets/tickets.js +++ /dev/null @@ -1,248 +0,0 @@ -/* - * Event Management Admin Area JAVAScript - Tickets interface - */ - -var f_loadAction = false; -var f_replaceContents = false; -var f_tabSelect = false; -var f_restartOnTabSelect = false; -var duration = 0; -var debugWindow = false; -var f_createEditor = false; -var f_removeEditor = false; - -if (memberUser) { - var adminURL = baseAdminURL; -} else { - var adminURL = baseAdminURL + 'EventManagement/EventManagement.php'; -} - -function emDebugWindowReloadRequest() { - if (debugWindow) { - debugWindow.debugReloadRequest(); - } -} - -// jQuery Section -$(document).ready(function(){ - - /* - * Data Setup Section - */ - - var siteURL = baseSiteURL; - var appURL = baseSiteURL + 'common/EventManagement/'; - var appWebURL = baseSiteURL + 'common/Public/'; - - /* - * Load an action to a div with the specified action - */ - function loadAction(action, container, params) { - - // Display loading message - $('#'+container).html('
    Loading, Please Wait...
    '); - $('#'+container).show(duration); - - // Build the URL and call it with AJAX - url = appAdminURL + "&Action=" + action; - if (params) { - url = url + '&' + params; - - } - - $.post( url, - '', - function(data) { - // Populate the container with the results - $('#'+container).html(data); - restartOnTabSelect(); - } - ); - - } - f_loadAction = loadAction; - - // Replace the contents of a div - function replaceContents(data, destination) { - destination.html(data); - $(window).scrollTop($(destination).position().top-50); - } - f_replaceContents = replaceContents; - - /* - * General Slider Operations - */ - - // Slider area actions - $('.emSlider').on('click', null, function() { - - // Get the ID of the area to slide from the emSliderId="" parameter in the div tag. - var sliderId = $(this).attr('emSliderId'); - - // If the slider is currently open - close it, otherwise open it. - if ($('#'+sliderId).is(':visible')) { - $('#'+sliderId).hide(duration); - } else { - $('#'+sliderId).show(duration); - } - }); - // Startup by closing all areas that are supposed to be closed by default - $('.emSliderClosed').hide(duration); - - /* - * Tab Operations - */ - - function tabSelect() { - - // Get Tab Group Name - var tabGroup = $(this).attr('emTabGroup'); - - // Get last selected tab ID - var lastTab = $('.'+tabGroup+'.emTabSelected').attr('emTabId'); - - // Get the new tab ID - var newTab = $(this).attr('emTabId'); - - // Get destination container ID -// ? var container = false; - var container = $(this).attr('emContainerId'); - - // Get any parmeters for the loadAction() AJAX call - var params = $(this).attr('emTabParams'); - - // If they didn't click the already selected tab - // if (lastTab != newTab) { - - // Assign the clicked object to a parameter for use in the function - var selectedTab = $(this); - - // If there was an already selected tab then hide old and processe new tab - if (lastTab) { - - // Slide up the previously selected section - $('#'+container).hide(duration, function() { - - // If there's a destination container, then get content - if (container) { - loadAction(newTab, container, params); - } - - // Make last tab not selected and now a link - $('.'+tabGroup+'.emTabSelected').removeClass('emTabSelected'); - - // Mark new tab as selected and not a link - selectedTab.addClass('emTabSelected'); - - // Open the new tab's block - $('#'+newTab).show(duration); - - - }); - - // Otherwise if there's no old tab, just process the new one - } else { - - // If there's a destination container, then get content - if (container) { - loadAction(newTab, container, params); - } - - // Mark new tab as selected and not a link - selectedTab.addClass('emTabSelected'); - - // Open the new tab's block - $('#'+newTab).show(duration); - - } - - } - f_tabSelect = tabSelect; - - function restartOnTabSelect() - { - $('.emTab').off('click', f_tabSelect); - $('.emTab').on('click', f_tabSelect); - } - f_restartOnTabSelect = restartOnTabSelect; - restartOnTabSelect(); - - /* - * CKEditor Actions - */ - - CKEDITOR.config.toolbar_EventManagement = - [ - ['Font','FontSize','Bold','Italic'], - ['Cut','Copy','PasteText','-','Undo','Redo'], - ['NewPage', 'Preview'], - '/', - ['NumberedList','BulletedList','-','Outdent','Indent'], - ['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'], - ['TextColor'], - ['Link','Unlink'], - ['Table','Find','Replace','-','RemoveFormat','Source'] - ] ; - - // Build a specific CKeditor - function buildCkeditor(f) { - // Get field ID - fieldId = f.attr('id'); - - // Create the editor - if (f.is("textarea")) { - // Only try to replace the textarea if the - // CKEditor is compatible w/ the browser. - if (CKEDITOR.env.isCompatible) { - CKEDITOR.replace(fieldId, { - toolbar : 'EventManagement', - // width : 570, - height : 100 - }); - } - } - } - f_buildCkeditor = buildCkeditor; - - // Remove a specific CKeditor - function removeCkeditor(f) { - // Get field ID - fieldId = f.attr('id'); - var instance = CKEDITOR.instances[fieldId]; - var data = instance.getData(); - instance.destroy(true); - f.text(data); - } - f_removeCkeditor = removeCkeditor; - - // If option.admin_debug has been set, create debug window - if(debugEnabled) { - var disp_setting="toolbar=no,location=no,directories=no,menubar=no,scrollbars=yes,width=" + debugWidth + ", height=700, left=100, top=25"; - debugWindow = window.open(appAdminURL + "&Action=Debug_start","emDebugWindow",disp_setting); - } - - - /* - * Check for user timeout - */ - - var inactivityTime = 86400000; // Number of milliseconds to user timeout - - // If there's no activity for 86,400 seconds (1 day) do something - var activityTimeout = setTimeout(inActive, inactivityTime); - - function resetActive(){ - $(document.body).attr('class', 'active'); - clearTimeout(activityTimeout); - activityTimeout = setTimeout(inActive, inactivityTime); - } - - // No activity do something. - function inActive(){ - $(document.body).html('

    User timeout ...

    Please select "Event Management" to start.

    '); - } - - // Check for mousemove, could add other events here such as checking for key presses ect. - $(document).bind('mousemove', function(){resetActive()}); - -}); diff --git a/legacy/web/front/FoundationStandAlone/EventManagement.css b/legacy/web/front/FoundationStandAlone/EventManagement.css deleted file mode 100755 index 54b845d..0000000 --- a/legacy/web/front/FoundationStandAlone/EventManagement.css +++ /dev/null @@ -1,594 +0,0 @@ -/* Additional styles for Event Management front-end */ - -/* These are verified for use with the Foundation layouts */ - -/* Styles to over-ride Foundation styles mudged by site styling. */ -.h2Tickets { - color: #B5383E; - display: block; - margin-bottom: .5em; - font-family: TimesNewRoman,"Times New Roman",Times,Baskerville,Georgia,serif; - font-size: 1.8em; - line-height: 110%; - font-weight: bold; -} -.h3Tickets { - font-size: 1.2em !important; - font-weight: bold !important; -} -.h3Tickets:hover { - color: #B5383E !important; -} -.buttonTickets { - color: white !important; - font-size: 1.3em !important; - padding: .2em 1em .2em 1em !important; - margin: 0 .2em .2em .2em !important; -} -.buttonTicketsGo { - color: white !important; - background-color: #00BF00; - font-size: 1.3em !important; - padding: .2em 1em .2em 1em !important; - margin: 0 .2em .2em .2em !important; -} -.buttonTicketsGo:hover { - background-color: #00AF00; -} - -/* Anything below needs to be verified if used with the Foundation layouts */ - -#GLMpageIntro { - margin: 1em 0 1em 0; -} -.glmBlock { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 10px 0; - padding: 5px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmBlockContent { - margin: 0 0 0em 0; - clear: both; - width: 100%; -} -.glmBlockContentLeft { - display: block; - float: left; - overflow: hidden; -} -.glmBlockContentRight { - display: block; - float: right; - width: 40%; - overflow: hidden; - margin-bottom: 10px; - margin-left: 5%; - min-width: 120px; -} -.glmBlockContentIndent { - display: block; - margin-left: 3em; -} -.glmCartVenueDescr, .glmCartEventDescr { - font-size: 0.8em; - margin: 0 0 2.2em 0 -} -.glmCartVenueDescr, .glmCartEventDescr { - margin: 0 0 15px 0 -} -.glmCartSelect { - width: 4em; -} -.glmCartBlock.totals .glmCartWide { - width: 100%; - padding-top: 10px; -} -.glmCartBlock { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 1em 0; - padding: 10px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmCartBlock.totals { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 10px 0; - padding: 0; - border: 0; - background: none; -} -.glmCartBlockSmallTitle { - font-size: 16px; - line-height: 22px; - font-family: "Lora","Times New Roman",Times,serif; -} -.glmCartBlock input[type="textarea"] { - display: block; - float: left; - clear: left; - width: 100%; -} -.glmEventDateInput { - width: 80px; -} -.glmCartBlock.totals .glmCartBlockTitle { - border-bottom: 1px solid #CCC; -} -#GLMcontent { - padding: 0; - margin: 0 auto -} -#GLMevent, #GLMtickets, #GLMvenue { - /* max-width: 500px; */ - margin: 0 auto 1em auto -} -#GLMnavigation:after { - content: ""; - display: table; - clear: both -} -.glmNavItem { - float: right; - padding: 3px 10px; - width: auto; - display: block; - overflow: hidden; - background: #900; - border: 1px solid #900; - border-radius: 8px; - cursor: pointer; - text-transform: uppercase; -} -a.glmNavItem { - color: #FFF; - font-weight: bold; - text-shadow: none; -} -div.glmNavItem { - color: #FFF; - font-weight: bold; - text-shadow: none; -} -.glmNavItem.cart { - background: #040267; - border: 1px solid #040267; -} -.glmNavItemWide { - display: block; - width: 400px; - overflow: hidden; - margin: 12px 0 0 0; - padding: 8px 0; - background: #900; - border: 1px solid #900; - border-radius: 8px; - color: #FFF; - text-align: center; - vertical-align: middle; - font-size: 18px; - font-weight: bold; - font-family: "Times New Roman", Times, serif; - cursor: pointer; -} -.glmSelectItem { - padding: 5px; - margin: 0; - width: 150px; - border-left: 1px solid #e3e3e3; - cursor: pointer; - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - text-align: center; - font-weight: 600; - font-shadow: 0 1px #fff; - font-size: 0.85em; - background: #fcfcfc; - -webkit-background-clip: padding; - -moz-background-clip: padding; - background-clip: padding-box; -} -#GLMcheckout .glmNavItem, #GLMticketCart .glmNavItem { - width: 33.3333% -} -#GLMeventDates, #GLMvenueLocation, #GLMvenueDetail, #GLMvenueSectionMap { - margin: 0 0 15px 0 -} -.glmPrompt { - font-weight: 600; - font-size: 1.1em -} -.glmTicketDescr { - font-size: 0.85em -} -.glmTicketAvailable { - margin: 5px 0; - font-weight: 600 -} -.glmSectionTickets { - margin: 15px 0 -} -.glmTicketName { - font-size: 1.35em; - font-weight: 600 -} -.glmTicketDateInput { - width: 7em !important; - display: inline !important; -} -.glmTicketQuantInput { - width: 4em !important; - display: inline !important; -} -.glmTicketCcnameInput { - width: 32em !important; -} -.glmTicketCcInput { - width: 12em !important; -} -.glmSectionSelector { - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - cursor: pointer; - background-color: #f8f8f8; - padding: 8px 15px; - margin: 5px 0; - font-size: 1.15em; - font-weight: 600; - display: inline-block; - font-shadow: 0 1px #fff -} -.glmSectionSelector:active { - -webkit-box-shadow: inset 0 0 8px #dbdbdb; - -moz-box-shadow: inset 0 0 8px #dbdbdb; - box-shadow: inset 0 0 8px #dbdbdb -} -#GLMticketsSummary { - font-weight: 600; - font-size: 1.35em; - margin-top: 30px -} -.glmTicketsSelect { - clear: both; - margin: 1em; -} -.glmTicketsSelectPrompt { - font-size: 1em; - font-weight: 600; - line-height: 125%; - float: left; - padding-right: .2em; -} -.glmTicketsSelectValueWrapper { - float: right; - width: 150px; - text-align: right; -} -.glmTicketsSelectValue { - float: right; - width: 40%; - text-align: right; -} -#glmQuantSelector { - float: right; - text-align: right; - width: 100px; - height: 28px; -} -#GLMpolicy { - font-size: 0.85em; - font-style: italic; -/* margin-bottom: 15px; */ -} -.glmTicketPrice { - font-weight: 600; - margin: 15px 0 5px 0; - font-size: 1.25em -} -#GLMreason { - border: 1px solid #333; - padding: 1em; -} -.GLMreasonTitle { - color: red; -} -.GLMreasonList { -} -.GLMmapWindow { - width: 100%; - height: 140px; - border: 1px solid #CCC; -} -.glmDescr { -} -.glmCartFailedInput { - background: #FFaBa9; - padding: .2em; -} -.glmCartRequired { - color: red; -} -/* CHECKOUT STUFF */ -.glmCartFormLine { - clear: both; -} -.glmCartFormPrompt { - width: 30%; - float: left; - text-align: right; - font-weight: 600; - font-size: 1.1em; - padding-right: .5em; -} -.glmCartFormInput { - padding-left: 1em; - width: 70%; - float: left; - margin-bottom: .5em; -} -.glmCartFormInput span { - display: block; - width: 100%; - overflow: hidden; -} -/* Forms */ -.glmCartForm { - display: block; - width: 100%; - overflow: hidden; - padding: 10px; - background: #F5F5F5; - margin: 0 0 10px 0; - font-size: 12px; - border: 1px solid #CCC; - color: #656565; -} -.glmCartForm input[type="text"] { - display: block; - float: left; - clear: left; - width: 300px; -} -.glmCartForm select { - display: block; - float: left; - clear: left; - width: 200px; -} -.glmCartPayment { - margin: 2em 0 0 0 -} -.glmInput { - float: right; -} -/* Mobile */ -@media screen and (max-width:768px) { - .glmBlockContentRight { - float: left; - width: 100%; - margin-left: 0; - margin-right: 0; - margin-top: 10px; - margin-bottom: 10px; - } - .glmBlockContentLeft { - display: inline; - float: left; - width: 100%; - } - .glmBlockContentLeft div { - clear: none !important; - } - /* Mobile Forms */ - -} -/* Small Mobile */ -@media screen and (max-width:599px) { - .GLMmapWindow { - height: 130px; - } - .glmCartFormPrompt { - display: block; - width: 100%; - overflow: hidden; - text-align: left; - } - .glmCartFormInput { - margin-left: 0; - padding-left: 0; - } - #GLMpageTitle { - width: 50%; - } - .glmCartHeader { - float: left; - clear: none; - width: 50%; - overflow: hidden; - - margin-bottom: 20px; - } - .glmCartHeader .glmCartText { - display: block; - width: 100%; - overflow: hidden; - border-bottom: 1px solid #CCC; - height: 30px; - } - .glmCartValues { - float: left; - clear: none; - width: 50%; - overflow: hidden; - margin-bottom: 20px; - } - .glmCartValues .glmCartText { - display: block; - width: 100%; - overflow: hidden; - border-bottom: 1px solid #CCC; - height: 30px; - } - .glmCartSubTotals .glmCartTable .glmCartHeader { - float: right; - width: 66%; - } - .glmCartSubTotals .glmCartTable .glmCartHeader .glmCartText { - width: 42%; - margin-right: 0; - margin-left: 8%; - height: auto; - text-align: right; - } - .glmCartSubTotals .glmCartTable .glmCartValues { - float: right; - clear: right; - width: 66%; - } - .glmCartSubTotals .glmCartTable .glmCartValues .glmCartText { - width: 42%; - margin-right: 0; - margin-left: 8%; - border-bottom: 0; - height: auto; - text-align: right; - } - .glmCartTable.totals { - padding-left: 0; - padding-right: 0; - } - .glmCartTable.totals .glmCartHeader { - float: right; - width: 100%; - margin-bottom: 0; - } - .glmCartTable.totals .glmCartHeader .glmCartText { - width: 28%; - margin-right: 0; - margin-left: 5%; - border-bottom: 1px solid #CCC; - height: auto; - text-align: right; - } - .glmCartTable.totals .glmCartValues { - float: right; - width: 100%; - } - .glmCartTable.totals .glmCartValues .glmCartText { - width: 28%; - margin-right: 0; - margin-left: 5%; - border-bottom: 0; - height: auto; - text-align: right; - } - .glmTicketsSelectValueWrapper { - float: left; - width: 150px; - clear: left; - margin-top: 10px; - } - .glmBlockLeft { - width: 100%; - } - .glmCartEventDescrMobile { - display: inline; - } - .glmCartEventDescr { - display: none; - } -} -/* MidSmall Mobile */ -@media screen and (max-width:449px) { - #GLMpageTitle { - font-size: 16px; - line-height: 20px; - } - .glmBlockName { - font-size: 14px; - line-height: 18px; - } - .glmCartFormInput { - width: 100%; - } - .glmCartForm input[type="text"] { - width: 100%; - } - .glmCartForm select { - width:100%; - } - .glmNavItemWide { - width: 100%; - } - .glmNavItem.add { - width: 100%; - text-align: center; - } - #GLMcheckoutBtn { - width: 100%; - text-align: center; - } - -} -/* XSmall Mobile */ -@media screen and (max-width:399px) { - .glmNavItem.chooser { - display: block; - width: 100%; - overflow: hidden; - margin-top: 10px; - text-align: center; - } -} - -#glmReloadBlocker { - display: none; - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - background-color : transparent; - text-align: center; - z-index: 1000; -} -#glmReloadBlocker div { - height: auto; - width: 250px; - padding: 10px; - background: #eee; - position: fixed; - border-radius: 10px; - border: 2px solid #666; - color: red; - font-size: 1.1em; - line-height: 150%; - - margin: -150px 0 0 -150px; - left: 55%; - top: 60%; - - box-shadow: 10px 10px 5px #888888; -} -#glmDevelopmentNotice { - padding: 5px; - border: 1px solid black; - width: auto; - clear: both; - margin-top: 4em; -} diff --git a/legacy/web/front/FoundationStandAlone/EventManagement.js b/legacy/web/front/FoundationStandAlone/EventManagement.js deleted file mode 100755 index 34e8596..0000000 --- a/legacy/web/front/FoundationStandAlone/EventManagement.js +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Event Management Front-End Area JAVAScript - TicketsFoundation interface - */ - -var f_loadAction = false; -var f_replaceContents = false; -var duration = 0; - -// jQuery Section -$(document).ready(function(){ - - /* - * Data Setup Section - */ - - var siteURL = flex_baseURL; - var appURL = flex_baseAppURL; - - /* - * Load an action to a div with the specified id where id is also Action to be run - */ - function loadAction(id, container, params) { - - // Display loading message - $('#'+container).html('
    Loading, Please Wait...
    '); - $('#'+container).show(duration); - - // Build the URL and call it with AJAX - url = appURL + "?Action=" + id; - if (params) { - url = url + '&' + params; - } - $.post( url, - '', - function(data) { - // Populate the container with the results - $('#'+container).html(data); - restartOnTabSelect(); - } - ); - - } - f_loadAction = loadAction; - - // Replace the contents of a div - function replaceContents(data, destination) { - destination.html(data); - } - f_replaceContents = replaceContents; - - /* - * General Slider Operations - */ - - // Slider area actions - $('.glmSectionSelector').on('click', null, function() { - - // Get the ID of the area to slide from the emSliderId="" parameter in the div tag. - var sliderId = $(this).attr('emSliderId'); - - // If the slider is currently open - close it, otherwise open it. - if ($('#'+sliderId).is(':visible')) { - $('#'+sliderId).hide(duration); - } else { - $('#'+sliderId).show(duration); - } - }); - // Startup by closing all areas that are supposed to be closed by default - $('.glmSectionTickets').hide(duration); - - /* - * Check for user timeout - */ - var inactivityTime = 1800000; // Number of milliseconds to user timeout - - // If theres no activity for 5 seconds do something - var activityTimeout = setTimeout(inActive, inactivityTime); - - function resetActive(){ - $(document.body).attr('class', 'active'); - clearTimeout(activityTimeout); - activityTimeout = setTimeout(inActive, inactivityTime); - } - - // No activity do something. - function inActive(){ - alert("Your user session has timed out. Click OK to continue."); - window.location.href = siteURL; - } - - // Check for mousemove, could add other events here such as checking for key presses ect. - $(document).bind('mousemove', function(){resetActive()}); - -}); diff --git a/legacy/web/front/FoundationStandAlone/assets/get_adobe_reader.png b/legacy/web/front/FoundationStandAlone/assets/get_adobe_reader.png deleted file mode 100755 index f53add8..0000000 Binary files a/legacy/web/front/FoundationStandAlone/assets/get_adobe_reader.png and /dev/null differ diff --git a/legacy/web/front/FoundationStandAlone/assets/paypal_but6.gif b/legacy/web/front/FoundationStandAlone/assets/paypal_but6.gif deleted file mode 100755 index 5da5a52..0000000 Binary files a/legacy/web/front/FoundationStandAlone/assets/paypal_but6.gif and /dev/null differ diff --git a/legacy/web/front/FoundationStandAlone/assets/pdficon_large.png b/legacy/web/front/FoundationStandAlone/assets/pdficon_large.png deleted file mode 100755 index c42f155..0000000 Binary files a/legacy/web/front/FoundationStandAlone/assets/pdficon_large.png and /dev/null differ diff --git a/legacy/web/front/TicketsFoundation/EventManagement.css b/legacy/web/front/TicketsFoundation/EventManagement.css deleted file mode 100755 index 5a205d5..0000000 --- a/legacy/web/front/TicketsFoundation/EventManagement.css +++ /dev/null @@ -1,772 +0,0 @@ -/* Additional styles for Event Management front-end */ -#GLMHeader { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 5px 0; - padding: 0; - border-bottom: 1px solid #CCC; -} -#GLMpageTitle { - color: #040267; - float: left; - font-family: "Lora","Times New Roman",Times,serif; - font-size: 20px; - line-height: 24px; - font-weight: normal; - margin: 0 0 10px; - padding: 0 0 5px 0; - width: 70%; - /*background: rgba(0,0,0,0.1);*/ -} -#GLMpageIntro { - margin: 1em 0 1em 0; -} -.glmBold { - font-weight: 600; -} -.glmBlock { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 10px 0; - padding: 5px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmBlockList { - margin-top: 10px; - clear: both; -} -.glmBlockHeader, .glmBlockHeadder { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 5px 0; -} -.glmBlockName { - display: inline; - font-size: 18px; - line-height: 22px; - font-family: "Lora","Times New Roman",Times,serif; -} -.glmBlockRightCol { - float: right; -} -.glmBlockContent { - margin: 0 0 0em 0; - clear: both; - width: 100%; -} -.glmBlockContentLeft { - display: block; - float: left; - overflow: hidden; -} -.glmBlockContentRight { - display: block; - float: right; - width: 40%; - overflow: hidden; - margin-bottom: 10px; - margin-left: 5%; - min-width: 120px; -} -.glmBlockContentIndent { - display: block; - margin-left: 3em; -} -.glmSection { -} -.glmSection .glmSectionName { -} -.glmSection .glmSectionBold { - font-size: 1.1em; - font-weight: 600; -} -.glmSectionName { - font-size: 1.1em; - font-weight: 600; - margin: 1em 0 0 0; -} -#GLMeventDescr, #GLMvenueDescr, .glmCartVenueDescr, .glmCartEventDescr { - font-size: 0.8em; - margin: 0 0 2.2em 0 -} -.glmCartEventDescrMobile { - display: none; -} -.glmCartVenueDescr, .glmCartEventDescr { - margin: 0 0 15px 0 -} -.glmCartEvents { -} -.glmCartEvent { -} -.glmCartSelect { - width: 4em; -} -.glmCartEventTitle { - font-size: 18px; - line-height: 22px; - font-family: "Lora","Times New Roman",Times,serif; -} -.glmCartEventInfo { - margin-top: .5em; - clear: both; -} -.glmCartEventInfoLeft { - float: left; - padding-right: 100px; -} -.glmCartHeader { - font-size: 1.1em; - font-weight: 600; - clear: both; -} -.glmCartHeader .glmCartText { - font-weight: bold; - border-bottom: 1px solid #CCC; -} -.glmCartValues { - clear: both; -} -.glmCartTable { - display: block; - width: 100%; - overflow: hidden; - margin: 10px 0 0 0; - padding: 10px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmCartTable.totals { - display: block; - width: 100%; - overflow: hidden; - margin: 10px 0 0 0; - padding: 10px 0 10px 20px; - border: 0; - background: none; -} -.glmCartTable.sub { - padding-top: 0; - padding-bottom: 0; -} -.glmCartNumb { - width: 20%; - float: left; - align: right; -} -.glmCartText { - display: block; - width: 17%; - margin-right: 3%; - float: left; - padding: 2px 0 0 0; -} - -.glmGrandTotals { - float: right; - color: #900; - font-weight: 600; - font-size: 1.1em; -} - -.glmCartTable.totals .glmCartText { - display: block; - width: 30%; - margin-right: 3%; - float: right; - padding: 2px 0 0 0; -} -.glmCartTable.totals .glmCartHeader .glmCartText { - color: #900; -} -.glmCartTable.totals .glmCartText.grand { - margin-right: 0; - padding-right: 0; -} -.glmCartTotal { - width: 30%; - float: left; -} -.glmCartWide { - width: 40%; - float: left; -} -.glmCartBlock.totals .glmCartWide { - width: 100%; - padding-top: 10px; -} -.glmCartTotal { - width:20%; - font-weight: 600; - font-size: 1.1em; -} -.glmCartSubTotals { - margin-top: 10px; - clear: both; -} -.glmCartSubTotals .glmCartTable { - background: none; - border: 0; -} -.glmCartSubTotals .glmCartTable .glmCartHeader { - float: right; - width: 40%; -} -.glmCartSubTotals .glmCartTable .glmCartHeader .glmCartText { - width: 42%; - margin-right: 8%; - height: auto; - text-align: left; -} -.glmCartSubTotals .glmCartTable .glmCartValues { - float: right; - clear: right; - width: 40%; -} -.glmCartSubTotals .glmCartTable .glmCartValues .glmCartText { - width: 42%; - margin-right: 8%; - border-bottom: 0; - height: auto; - text-align: left; -} -.glmCartTotals { - margin-top: 10px; -} -.glmCartBlock { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 1em 0; - padding: 10px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmCartBlock.totals { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 10px 0; - padding: 0; - border: 0; - background: none; -} -.glmCartBlockTitle { - font-size: 22px; - line-height: 28px; - font-family: "Lora","Times New Roman",Times,serif; - margin: 0 0 0 0; -} -.glmCartBlockSmallTitle { - font-size: 16px; - line-height: 22px; - font-family: "Lora","Times New Roman",Times,serif; -} -.glmCartBlock input[type="textarea"] { - display: block; - float: left; - clear: left; - width: 100%; -} -.glmEventDateInput { - width: 80px; -} -.glmCartBlock.totals .glmCartBlockTitle { - border-bottom: 1px solid #CCC; -} -.glmCartBlockSubTitle { - margin-top: 1em; - font-size: 1.1em; - font-weight: 600; - margin-bottom: .5em; -} -.glmCartBlockSubTitleValue { - -} -.glmCartBlockText { -} -.glmCartBlockDates { - clear: both; -} -.glmCartBlockDate { - margin-top: .5em; -} -.glmSpecialRequests { - margin: 0 0 3em 0; -} -#GLMcontent { - padding: 0; - margin: 0 auto -} -#GLMcontent>* { -/* padding: 0 15px; */ -} -#GLMevent, #GLMtickets, #GLMvenue { - /* max-width: 500px; */ - margin: 0 auto 1em auto -} -#GLMnavigation:after { - content: ""; - display: table; - clear: both -} -.glmNavItemInactive { - float: right; - padding: 3px 10px; - width: auto; - display: block; - overflow: hidden; - background: #ddd; - border: 1px solid #aaa; - border-radius: 8px; - cursor: pointer; - text-transform: uppercase; - text-align: center; -} -.glmNavItem { - float: right; - padding: 3px 10px; - width: auto; - display: block; - overflow: hidden; - background: #900; - border: 1px solid #900; - border-radius: 8px; - cursor: pointer; - text-transform: uppercase; -} -a.glmNavItem { - color: #FFF; - font-weight: bold; - text-shadow: none; -} -div.glmNavItem { - color: #FFF; - font-weight: bold; - text-shadow: none; -} -.glmNavItem.cart { - background: #040267; - border: 1px solid #040267; -} -.glmNavItemWide { - display: block; - width: 400px; - overflow: hidden; - margin: 12px 0 0 0; - padding: 8px 0; - background: #900; - border: 1px solid #900; - border-radius: 8px; - color: #FFF; - text-align: center; - vertical-align: middle; - font-size: 18px; - font-weight: bold; - font-family: "Times New Roman", Times, serif; - cursor: pointer; -} -.glmSelectItem { - padding: 5px; - margin: 0; - width: 150px; - border-left: 1px solid #e3e3e3; - cursor: pointer; - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - text-align: center; - font-weight: 600; - font-shadow: 0 1px #fff; - font-size: 0.85em; - background: #fcfcfc; - -webkit-background-clip: padding; - -moz-background-clip: padding; - background-clip: padding-box; -} -#GLMcheckout .glmNavItem, #GLMticketCart .glmNavItem { - width: 33.3333% -} -#GLMeventDates, #GLMvenueLocation, #GLMvenueDetail, #GLMvenueSectionMap { - margin: 0 0 15px 0 -} -.glmPrompt { - font-weight: 600; - font-size: 1.1em -} -.glmTicketDescr { - font-size: 0.85em -} -.glmTicketAvailable { - margin: 5px 0; - font-weight: 600 -} -.glmSectionTickets { - margin: 15px 0 -} -.glmTicketName { - font-size: 1.35em; - font-weight: 600 -} -.glmSectionSelector { - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - cursor: pointer; - background-color: #f8f8f8; - padding: 8px 15px; - margin: 5px 0; - font-size: 1.15em; - font-weight: 600; - display: inline-block; - font-shadow: 0 1px #fff -} -.glmSectionSelector:active { - -webkit-box-shadow: inset 0 0 8px #dbdbdb; - -moz-box-shadow: inset 0 0 8px #dbdbdb; - box-shadow: inset 0 0 8px #dbdbdb -} -#GLMticketsSummary { - font-weight: 600; - font-size: 1.35em; - margin-top: 30px -} -.glmTicketsSelect { - clear: both; - margin: 1em; -} -.glmTicketsSelectPrompt { - font-size: 1em; - font-weight: 600; - line-height: 125%; - float: left; - padding-right: .2em; -} -.glmTicketsSelectValueWrapper { - float: right; - width: 150px; - text-align: right; -} -.glmTicketsSelectValue { - float: right; - width: 40%; - text-align: right; -} -#glmQuantSelector { - float: right; - text-align: right; - width: 100px; - height: 28px; -} -#GLMpolicy { - font-size: 0.85em; - font-style: italic; -/* margin-bottom: 15px; */ -} -.glmTicketPrice { - font-weight: 600; - margin: 15px 0 5px 0; - font-size: 1.25em -} -#GLMreason { - border: 1px solid #333; - padding: 1em; -} -.GLMreasonTitle { - color: red; -} -.GLMreasonList { -} -.GLMmapWindow { - width: 100%; - height: 140px; - border: 1px solid #CCC; -} -.glmDescr { -} -.glmCartFailedInput { - background: #FFaBa9; - padding: .2em; -} -.glmCartRequired { - color: red; -} -/* CHECKOUT STUFF */ -.glmCartFormLine { - clear: both; -} -.glmCartFormPrompt { - width: 30%; - float: left; - text-align: right; - font-weight: 600; - font-size: 1.1em; - padding-right: .5em; -} -.glmCartFormInput { - padding-left: 1em; - width: 70%; - float: left; - margin-bottom: .5em; -} -.glmCartFormInput span { - display: block; - width: 100%; - overflow: hidden; -} -/* Forms */ -.glmCartForm { - display: block; - width: 100%; - overflow: hidden; - padding: 10px; - background: #F5F5F5; - margin: 0 0 10px 0; - font-size: 12px; - border: 1px solid #CCC; - color: #656565; -} -.glmCartForm input[type="text"] { - display: block; - float: left; - clear: left; - width: 300px; -} -.glmCartForm select { - display: block; - float: left; - clear: left; - width: 200px; -} -.glmCartPayment { - margin: 2em 0 0 0 -} -.glmInput { - float: right; -} -/* Mobile */ -@media screen and (max-width:768px) { - .glmBlockContentRight { - float: left; - width: 100%; - margin-left: 0; - margin-right: 0; - margin-top: 10px; - margin-bottom: 10px; - } - .glmBlockContentLeft { - display: inline; - float: left; - width: 100%; - } - .glmBlockContentLeft div { - clear: none !important; - } - /* Mobile Forms */ - -} -/* Small Mobile */ -@media screen and (max-width:599px) { - .GLMmapWindow { - height: 130px; - } - .glmCartFormPrompt { - display: block; - width: 100%; - overflow: hidden; - text-align: left; - } - .glmCartFormInput { - margin-left: 0; - padding-left: 0; - } - #GLMpageTitle { - width: 50%; - } - .glmCartHeader { - float: left; - clear: none; - width: 50%; - overflow: hidden; - - margin-bottom: 20px; - } - .glmCartHeader .glmCartText { - display: block; - width: 100%; - overflow: hidden; - border-bottom: 1px solid #CCC; - height: 30px; - } - .glmCartValues { - float: left; - clear: none; - width: 50%; - overflow: hidden; - margin-bottom: 20px; - } - .glmCartValues .glmCartText { - display: block; - width: 100%; - overflow: hidden; - border-bottom: 1px solid #CCC; - height: 30px; - } - .glmCartSubTotals .glmCartTable .glmCartHeader { - float: right; - width: 66%; - } - .glmCartSubTotals .glmCartTable .glmCartHeader .glmCartText { - width: 42%; - margin-right: 0; - margin-left: 8%; - height: auto; - text-align: right; - } - .glmCartSubTotals .glmCartTable .glmCartValues { - float: right; - clear: right; - width: 66%; - } - .glmCartSubTotals .glmCartTable .glmCartValues .glmCartText { - width: 42%; - margin-right: 0; - margin-left: 8%; - border-bottom: 0; - height: auto; - text-align: right; - } - .glmCartTable.totals { - padding-left: 0; - padding-right: 0; - } - .glmCartTable.totals .glmCartHeader { - float: right; - width: 100%; - margin-bottom: 0; - } - .glmCartTable.totals .glmCartHeader .glmCartText { - width: 28%; - margin-right: 0; - margin-left: 5%; - border-bottom: 1px solid #CCC; - height: auto; - text-align: right; - } - .glmCartTable.totals .glmCartValues { - float: right; - width: 100%; - } - .glmCartTable.totals .glmCartValues .glmCartText { - width: 28%; - margin-right: 0; - margin-left: 5%; - border-bottom: 0; - height: auto; - text-align: right; - } - .glmTicketsSelectValueWrapper { - float: left; - width: 150px; - clear: left; - margin-top: 10px; - } - .glmBlockLeft { - width: 100%; - } - .glmCartEventDescrMobile { - display: inline; - } - .glmCartEventDescr { - display: none; - } -} -/* MidSmall Mobile */ -@media screen and (max-width:449px) { - #GLMpageTitle { - font-size: 16px; - line-height: 20px; - } - .glmBlockName { - font-size: 14px; - line-height: 18px; - } - .glmCartFormInput { - width: 100%; - } - .glmCartForm input[type="text"] { - width: 100%; - } - .glmCartForm select { - width:100%; - } - .glmNavItemWide { - width: 100%; - } - .glmNavItem.add { - width: 100%; - text-align: center; - } - #GLMcheckoutBtn { - width: 100%; - text-align: center; - } - -} -/* XSmall Mobile */ -@media screen and (max-width:399px) { - .glmNavItem.chooser { - display: block; - width: 100%; - overflow: hidden; - margin-top: 10px; - text-align: center; - } -} - -#glmReloadBlocker { - display: none; - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - background-color : transparent; - text-align: center; - z-index: 1000; -} -#glmReloadBlocker div { - height: auto; - width: 250px; - padding: 10px; - background: #eee; - position: fixed; - border-radius: 10px; - border: 2px solid #666; - color: red; - font-size: 1.1em; - line-height: 150%; - - margin: -150px 0 0 -150px; - left: 55%; - top: 60%; - - box-shadow: 10px 10px 5px #888888; -} -#glmDevelopmentNotice { - padding: 5px; - border: 1px solid black; - width: auto; - clear: both; - margin-top: 4em; -} diff --git a/legacy/web/front/TicketsFoundation/EventManagement.js b/legacy/web/front/TicketsFoundation/EventManagement.js deleted file mode 100755 index 34e8596..0000000 --- a/legacy/web/front/TicketsFoundation/EventManagement.js +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Event Management Front-End Area JAVAScript - TicketsFoundation interface - */ - -var f_loadAction = false; -var f_replaceContents = false; -var duration = 0; - -// jQuery Section -$(document).ready(function(){ - - /* - * Data Setup Section - */ - - var siteURL = flex_baseURL; - var appURL = flex_baseAppURL; - - /* - * Load an action to a div with the specified id where id is also Action to be run - */ - function loadAction(id, container, params) { - - // Display loading message - $('#'+container).html('
    Loading, Please Wait...
    '); - $('#'+container).show(duration); - - // Build the URL and call it with AJAX - url = appURL + "?Action=" + id; - if (params) { - url = url + '&' + params; - } - $.post( url, - '', - function(data) { - // Populate the container with the results - $('#'+container).html(data); - restartOnTabSelect(); - } - ); - - } - f_loadAction = loadAction; - - // Replace the contents of a div - function replaceContents(data, destination) { - destination.html(data); - } - f_replaceContents = replaceContents; - - /* - * General Slider Operations - */ - - // Slider area actions - $('.glmSectionSelector').on('click', null, function() { - - // Get the ID of the area to slide from the emSliderId="" parameter in the div tag. - var sliderId = $(this).attr('emSliderId'); - - // If the slider is currently open - close it, otherwise open it. - if ($('#'+sliderId).is(':visible')) { - $('#'+sliderId).hide(duration); - } else { - $('#'+sliderId).show(duration); - } - }); - // Startup by closing all areas that are supposed to be closed by default - $('.glmSectionTickets').hide(duration); - - /* - * Check for user timeout - */ - var inactivityTime = 1800000; // Number of milliseconds to user timeout - - // If theres no activity for 5 seconds do something - var activityTimeout = setTimeout(inActive, inactivityTime); - - function resetActive(){ - $(document.body).attr('class', 'active'); - clearTimeout(activityTimeout); - activityTimeout = setTimeout(inActive, inactivityTime); - } - - // No activity do something. - function inActive(){ - alert("Your user session has timed out. Click OK to continue."); - window.location.href = siteURL; - } - - // Check for mousemove, could add other events here such as checking for key presses ect. - $(document).bind('mousemove', function(){resetActive()}); - -}); diff --git a/legacy/web/front/TicketsFoundation/assets/get_adobe_reader.png b/legacy/web/front/TicketsFoundation/assets/get_adobe_reader.png deleted file mode 100755 index f53add8..0000000 Binary files a/legacy/web/front/TicketsFoundation/assets/get_adobe_reader.png and /dev/null differ diff --git a/legacy/web/front/TicketsFoundation/assets/paypal_but6.gif b/legacy/web/front/TicketsFoundation/assets/paypal_but6.gif deleted file mode 100755 index 5da5a52..0000000 Binary files a/legacy/web/front/TicketsFoundation/assets/paypal_but6.gif and /dev/null differ diff --git a/legacy/web/front/TicketsFoundation/assets/pdficon_large.png b/legacy/web/front/TicketsFoundation/assets/pdficon_large.png deleted file mode 100755 index c42f155..0000000 Binary files a/legacy/web/front/TicketsFoundation/assets/pdficon_large.png and /dev/null differ diff --git a/legacy/web/front/tickets/EventManagement.css b/legacy/web/front/tickets/EventManagement.css deleted file mode 100755 index ddb0de0..0000000 --- a/legacy/web/front/tickets/EventManagement.css +++ /dev/null @@ -1,773 +0,0 @@ -/* Additional styles for Event Management front-end */ -#GLMHeader { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 5px 0; - padding: 0; - border-bottom: 1px solid #CCC; -} -#GLMpageTitle { - color: #040267; - float: left; - font-family: "Lora","Times New Roman",Times,serif; - font-size: 20px; - line-height: 24px; - font-weight: normal; - margin: 0 0 10px; - padding: 0 0 5px 0; - width: 70%; - /*background: rgba(0,0,0,0.1);*/ -} -#GLMpageIntro { - margin: 1em 0 1em 0; -} -.glmBold { - font-weight: 600; -} -.glmBlock { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 10px 0; - padding: 5px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmBlockList { - margin-top: 10px; - clear: both; -} -.glmBlockHeader, .glmBlockHeadder { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 5px 0; -} -.glmBlockName { - display: inline; - font-size: 18px; - line-height: 22px; - font-family: "Lora","Times New Roman",Times,serif; -} -.glmBlockRightCol { - float: right; -} -.glmBlockContent { - margin: 0 0 0em 0; - clear: both; - width: 100%; -} -.glmBlockContentLeft { - display: block; - float: left; - width: 70%; - overflow: hidden; -} -.glmBlockContentRight { - display: block; - float: right; - width: 20%; - overflow: hidden; - margin-bottom: 10px; - margin-left: 5%; - min-width: 120px; -} -.glmBlockContentIndent { - display: block; - margin-left: 3em; -} -.glmSection { -} -.glmSection .glmSectionName { -} -.glmSection .glmSectionBold { - font-size: 1.1em; - font-weight: 600; -} -.glmSectionName { - font-size: 1.1em; - font-weight: 600; - margin: 1em 0 0 0; -} -#GLMeventDescr, #GLMvenueDescr, .glmCartVenueDescr, .glmCartEventDescr { - font-size: 0.8em; - margin: 0 0 2.2em 0 -} -.glmCartEventDescrMobile { - display: none; -} -.glmCartVenueDescr, .glmCartEventDescr { - margin: 0 0 15px 0 -} -.glmCartEvents { -} -.glmCartEvent { -} -.glmCartSelect { - width: 4em; -} -.glmCartEventTitle { - font-size: 18px; - line-height: 22px; - font-family: "Lora","Times New Roman",Times,serif; -} -.glmCartEventInfo { - margin-top: .5em; - clear: both; -} -.glmCartEventInfoLeft { - float: left; - padding-right: 100px; -} -.glmCartHeader { - font-size: 1.1em; - font-weight: 600; - clear: both; -} -.glmCartHeader .glmCartText { - font-weight: bold; - border-bottom: 1px solid #CCC; -} -.glmCartValues { - clear: both; -} -.glmCartTable { - display: block; - width: 100%; - overflow: hidden; - margin: 10px 0 0 0; - padding: 10px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmCartTable.totals { - display: block; - width: 100%; - overflow: hidden; - margin: 10px 0 0 0; - padding: 10px 0 10px 20px; - border: 0; - background: none; -} -.glmCartTable.sub { - padding-top: 0; - padding-bottom: 0; -} -.glmCartNumb { - width: 20%; - float: left; - align: right; -} -.glmCartText { - display: block; - width: 17%; - margin-right: 3%; - float: left; - padding: 2px 0 0 0; -} - -.glmGrandTotals { - float: right; - color: #900; - font-weight: 600; - font-size: 1.1em; -} - -.glmCartTable.totals .glmCartText { - display: block; - width: 30%; - margin-right: 3%; - float: right; - padding: 2px 0 0 0; -} -.glmCartTable.totals .glmCartHeader .glmCartText { - color: #900; -} -.glmCartTable.totals .glmCartText.grand { - margin-right: 0; - padding-right: 0; -} -.glmCartTotal { - width: 30%; - float: left; -} -.glmCartWide { - width: 40%; - float: left; -} -.glmCartBlock.totals .glmCartWide { - width: 100%; - padding-top: 10px; -} -.glmCartTotal { - width:20%; - font-weight: 600; - font-size: 1.1em; -} -.glmCartSubTotals { - margin-top: 10px; - clear: both; -} -.glmCartSubTotals .glmCartTable { - background: none; - border: 0; -} -.glmCartSubTotals .glmCartTable .glmCartHeader { - float: right; - width: 40%; -} -.glmCartSubTotals .glmCartTable .glmCartHeader .glmCartText { - width: 42%; - margin-right: 8%; - height: auto; - text-align: left; -} -.glmCartSubTotals .glmCartTable .glmCartValues { - float: right; - clear: right; - width: 40%; -} -.glmCartSubTotals .glmCartTable .glmCartValues .glmCartText { - width: 42%; - margin-right: 8%; - border-bottom: 0; - height: auto; - text-align: left; -} -.glmCartTotals { - margin-top: 10px; -} -.glmCartBlock { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 1em 0; - padding: 10px; - border: 1px solid #CFCFCF; - background: rgba(0,0,0,0.05); -} -.glmCartBlock.totals { - display: block; - width: 100%; - overflow: hidden; - margin: 0 0 10px 0; - padding: 0; - border: 0; - background: none; -} -.glmCartBlockTitle { - font-size: 22px; - line-height: 28px; - font-family: "Lora","Times New Roman",Times,serif; - margin: 0 0 0 0; -} -.glmCartBlockSmallTitle { - font-size: 16px; - line-height: 22px; - font-family: "Lora","Times New Roman",Times,serif; -} -.glmCartBlock input[type="textarea"] { - display: block; - float: left; - clear: left; - width: 100%; -} -.glmEventDateInput { - width: 80px; -} -.glmCartBlock.totals .glmCartBlockTitle { - border-bottom: 1px solid #CCC; -} -.glmCartBlockSubTitle { - margin-top: 1em; - font-size: 1.1em; - font-weight: 600; - margin-bottom: .5em; -} -.glmCartBlockSubTitleValue { - -} -.glmCartBlockText { -} -.glmCartBlockDates { - clear: both; -} -.glmCartBlockDate { - margin-top: .5em; -} -.glmSpecialRequests { - margin: 0 0 3em 0; -} -#GLMcontent { - padding: 0; - margin: 0 auto -} -#GLMcontent>* { -/* padding: 0 15px; */ -} -#GLMevent, #GLMtickets, #GLMvenue { - /* max-width: 500px; */ - margin: 0 auto 1em auto -} -#GLMnavigation:after { - content: ""; - display: table; - clear: both -} -.glmNavItemInactive { - float: right; - padding: 3px 10px; - width: auto; - display: block; - overflow: hidden; - background: #ddd; - border: 1px solid #aaa; - border-radius: 8px; - cursor: pointer; - text-transform: uppercase; - text-align: center; -} -.glmNavItem { - float: right; - padding: 3px 10px; - width: auto; - display: block; - overflow: hidden; - background: #900; - border: 1px solid #900; - border-radius: 8px; - cursor: pointer; - text-transform: uppercase; -} -a.glmNavItem { - color: #FFF; - font-weight: bold; - text-shadow: none; -} -div.glmNavItem { - color: #FFF; - font-weight: bold; - text-shadow: none; -} -.glmNavItem.cart { - background: #040267; - border: 1px solid #040267; -} -.glmNavItemWide { - display: block; - width: 400px; - overflow: hidden; - margin: 12px 0 0 0; - padding: 8px 0; - background: #900; - border: 1px solid #900; - border-radius: 8px; - color: #FFF; - text-align: center; - vertical-align: middle; - font-size: 18px; - font-weight: bold; - font-family: "Times New Roman", Times, serif; - cursor: pointer; -} -.glmSelectItem { - padding: 5px; - margin: 0; - width: 150px; - border-left: 1px solid #e3e3e3; - cursor: pointer; - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - text-align: center; - font-weight: 600; - font-shadow: 0 1px #fff; - font-size: 0.85em; - background: #fcfcfc; - -webkit-background-clip: padding; - -moz-background-clip: padding; - background-clip: padding-box; -} -#GLMcheckout .glmNavItem, #GLMticketCart .glmNavItem { - width: 33.3333% -} -#GLMeventDates, #GLMvenueLocation, #GLMvenueDetail, #GLMvenueSectionMap { - margin: 0 0 15px 0 -} -.glmPrompt { - font-weight: 600; - font-size: 1.1em -} -.glmTicketDescr { - font-size: 0.85em -} -.glmTicketAvailable { - margin: 5px 0; - font-weight: 600 -} -.glmSectionTickets { - margin: 15px 0 -} -.glmTicketName { - font-size: 1.35em; - font-weight: 600 -} -.glmSectionSelector { - border: 1px solid #e3e3e3; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - -ms-border-radius: 6px; - -o-border-radius: 6px; - border-radius: 6px; - cursor: pointer; - background-color: #f8f8f8; - padding: 8px 15px; - margin: 5px 0; - font-size: 1.15em; - font-weight: 600; - display: inline-block; - font-shadow: 0 1px #fff -} -.glmSectionSelector:active { - -webkit-box-shadow: inset 0 0 8px #dbdbdb; - -moz-box-shadow: inset 0 0 8px #dbdbdb; - box-shadow: inset 0 0 8px #dbdbdb -} -#GLMticketsSummary { - font-weight: 600; - font-size: 1.35em; - margin-top: 30px -} -.glmTicketsSelect { - clear: both; - margin: 1em; -} -.glmTicketsSelectPrompt { - font-size: 1em; - font-weight: 600; - line-height: 125%; - float: left; - padding-right: .2em; -} -.glmTicketsSelectValueWrapper { - float: right; - width: 150px; - text-align: right; -} -.glmTicketsSelectValue { - float: right; - width: 40%; - text-align: right; -} -#glmQuantSelector { - float: right; - text-align: right; - width: 100px; - height: 28px; -} -#GLMpolicy { - font-size: 0.85em; - font-style: italic; -/* margin-bottom: 15px; */ -} -.glmTicketPrice { - font-weight: 600; - margin: 15px 0 5px 0; - font-size: 1.25em -} -#GLMreason { - border: 1px solid #333; - padding: 1em; -} -.GLMreasonTitle { - color: red; -} -.GLMreasonList { -} -.GLMmapWindow { - width: 100%; - height: 140px; - border: 1px solid #CCC; -} -.glmDescr { -} -.glmCartFailedInput { - background: #FFaBa9; - padding: .2em; -} -.glmCartRequired { - color: red; -} -/* CHECKOUT STUFF */ -.glmCartFormLine { - clear: both; -} -.glmCartFormPrompt { - width: 30%; - float: left; - text-align: right; - font-weight: 600; - font-size: 1.1em; - padding-right: .5em; -} -.glmCartFormInput { - padding-left: 1em; - width: 70%; - float: left; - margin-bottom: .5em; -} -.glmCartFormInput span { - display: block; - width: 100%; - overflow: hidden; -} -/* Forms */ -.glmCartForm { - display: block; - width: 100%; - overflow: hidden; - padding: 10px; - background: #F5F5F5; - margin: 0 0 10px 0; - font-size: 12px; - border: 1px solid #CCC; - color: #656565; -} -.glmCartForm input[type="text"] { - display: block; - float: left; - clear: left; - width: 300px; -} -.glmCartForm select { - display: block; - float: left; - clear: left; - width: 200px; -} -.glmCartPayment { - margin: 2em 0 0 0 -} -.glmInput { - float: right; -} -/* Mobile */ -@media screen and (max-width:768px) { - .glmBlockContentRight { - float: left; - width: 100%; - margin-left: 0; - margin-right: 0; - margin-top: 10px; - margin-bottom: 10px; - } - .glmBlockContentLeft { - display: inline; - float: left; - width: 100%; - } - .glmBlockContentLeft div { - clear: none !important; - } - /* Mobile Forms */ - -} -/* Small Mobile */ -@media screen and (max-width:599px) { - .GLMmapWindow { - height: 130px; - } - .glmCartFormPrompt { - display: block; - width: 100%; - overflow: hidden; - text-align: left; - } - .glmCartFormInput { - margin-left: 0; - padding-left: 0; - } - #GLMpageTitle { - width: 50%; - } - .glmCartHeader { - float: left; - clear: none; - width: 50%; - overflow: hidden; - - margin-bottom: 20px; - } - .glmCartHeader .glmCartText { - display: block; - width: 100%; - overflow: hidden; - border-bottom: 1px solid #CCC; - height: 30px; - } - .glmCartValues { - float: left; - clear: none; - width: 50%; - overflow: hidden; - margin-bottom: 20px; - } - .glmCartValues .glmCartText { - display: block; - width: 100%; - overflow: hidden; - border-bottom: 1px solid #CCC; - height: 30px; - } - .glmCartSubTotals .glmCartTable .glmCartHeader { - float: right; - width: 66%; - } - .glmCartSubTotals .glmCartTable .glmCartHeader .glmCartText { - width: 42%; - margin-right: 0; - margin-left: 8%; - height: auto; - text-align: right; - } - .glmCartSubTotals .glmCartTable .glmCartValues { - float: right; - clear: right; - width: 66%; - } - .glmCartSubTotals .glmCartTable .glmCartValues .glmCartText { - width: 42%; - margin-right: 0; - margin-left: 8%; - border-bottom: 0; - height: auto; - text-align: right; - } - .glmCartTable.totals { - padding-left: 0; - padding-right: 0; - } - .glmCartTable.totals .glmCartHeader { - float: right; - width: 100%; - margin-bottom: 0; - } - .glmCartTable.totals .glmCartHeader .glmCartText { - width: 28%; - margin-right: 0; - margin-left: 5%; - border-bottom: 1px solid #CCC; - height: auto; - text-align: right; - } - .glmCartTable.totals .glmCartValues { - float: right; - width: 100%; - } - .glmCartTable.totals .glmCartValues .glmCartText { - width: 28%; - margin-right: 0; - margin-left: 5%; - border-bottom: 0; - height: auto; - text-align: right; - } - .glmTicketsSelectValueWrapper { - float: left; - width: 150px; - clear: left; - margin-top: 10px; - } - .glmBlockLeft { - width: 100%; - } - .glmCartEventDescrMobile { - display: inline; - } - .glmCartEventDescr { - display: none; - } -} -/* MidSmall Mobile */ -@media screen and (max-width:449px) { - #GLMpageTitle { - font-size: 16px; - line-height: 20px; - } - .glmBlockName { - font-size: 14px; - line-height: 18px; - } - .glmCartFormInput { - width: 100%; - } - .glmCartForm input[type="text"] { - width: 100%; - } - .glmCartForm select { - width:100%; - } - .glmNavItemWide { - width: 100%; - } - .glmNavItem.add { - width: 100%; - text-align: center; - } - #GLMcheckoutBtn { - width: 100%; - text-align: center; - } - -} -/* XSmall Mobile */ -@media screen and (max-width:399px) { - .glmNavItem.chooser { - display: block; - width: 100%; - overflow: hidden; - margin-top: 10px; - text-align: center; - } -} - -#glmReloadBlocker { - display: none; - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - background-color : transparent; - text-align: center; - z-index: 1000; -} -#glmReloadBlocker div { - height: auto; - width: 300px; - padding: 10px; - background: #eee; - position: fixed; - border-radius: 10px; - border: 2px solid #666; - color: red; - font-size: 1.3em; - line-height: 150%; - - margin: -150px 0 0 -150px; - left: 50%; - top: 60%; - - box-shadow: 10px 10px 5px #888888; -} -#glmDevelopmentNotice { - padding: 5px; - border: 1px solid black; - width: auto; - clear: both; - margin-top: 4em; -} diff --git a/legacy/web/front/tickets/EventManagement.js b/legacy/web/front/tickets/EventManagement.js deleted file mode 100755 index 2344c83..0000000 --- a/legacy/web/front/tickets/EventManagement.js +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Event Management Front-End Area JAVAScript - Tickets interface - */ - -var f_loadAction = false; -var f_replaceContents = false; -var duration = 0; - -// jQuery Section -$(document).ready(function(){ - - /* - * Data Setup Section - */ - - var siteURL = baseSiteURL; - var appURL = baseAppURL; - - /* - * Load an action to a div with the specified id where id is also Action to be run - */ - function loadAction(id, container, params) { - - // Display loading message - $('#'+container).html('
    Loading, Please Wait...
    '); - $('#'+container).show(duration); - - // Build the URL and call it with AJAX - url = appURL + "?Action=" + id; - if (params) { - url = url + '&' + params; - } - $.post( url, - '', - function(data) { - // Populate the container with the results - $('#'+container).html(data); - restartOnTabSelect(); - } - ); - - } - f_loadAction = loadAction; - - // Replace the contents of a div - function replaceContents(data, destination) { - destination.html(data); - } - f_replaceContents = replaceContents; - - /* - * General Slider Operations - */ - - // Slider area actions - $('.glmSectionSelector').on('click', null, function() { - - // Get the ID of the area to slide from the emSliderId="" parameter in the div tag. - var sliderId = $(this).attr('emSliderId'); - - // If the slider is currently open - close it, otherwise open it. - if ($('#'+sliderId).is(':visible')) { - $('#'+sliderId).hide(duration); - } else { - $('#'+sliderId).show(duration); - } - }); - // Startup by closing all areas that are supposed to be closed by default - $('.glmSectionTickets').hide(duration); - - /* - * Check for user timeout - */ - var inactivityTime = 1800000; // Number of milliseconds to user timeout - - // If theres no activity for 5 seconds do something - var activityTimeout = setTimeout(inActive, inactivityTime); - - function resetActive(){ - $(document.body).attr('class', 'active'); - clearTimeout(activityTimeout); - activityTimeout = setTimeout(inActive, inactivityTime); - } - - // No activity do something. - function inActive(){ - alert("Your user session has timed out. Click OK to continue."); - window.location.href = siteURL; - } - - // Check for mousemove, could add other events here such as checking for key presses ect. - $(document).bind('mousemove', function(){resetActive()}); - -}); diff --git a/legacy/web/front/tickets/assets/paypal_but6.gif b/legacy/web/front/tickets/assets/paypal_but6.gif deleted file mode 100755 index 5da5a52..0000000 Binary files a/legacy/web/front/tickets/assets/paypal_but6.gif and /dev/null differ diff --git a/setup/adminHooks.php b/setup/adminHooks.php index 584a4de..5027dea 100644 --- a/setup/adminHooks.php +++ b/setup/adminHooks.php @@ -25,3 +25,21 @@ * * Also note that parameters will be in the context of the main admin controller constructor. */ + +// Add hooksHelp.html file to admin Management hooks output +add_filter('glm-member-db-admin-management-hooksHelp', function($content) { + + // Read in this plugin/addon hook help file + $fname = GLM_MEMBER_EVENTMANAGEMENT_PLUGIN_PATH.'/setup/hooksHelp.html'; + if (is_file($fname)) { + $hooksHelp = file_get_contents($fname); + if ($hooksHelp != false) { + $content .= $hooksHelp; + } + } + return $content; + }, + 10, + 2 +); + diff --git a/setup/adminMenus.php b/setup/adminMenus.php index 17b86bc..e0240f1 100644 --- a/setup/adminMenus.php +++ b/setup/adminMenus.php @@ -50,3 +50,14 @@ * */ +add_submenu_page( + 'glm-members-admin-menu-members', + 'Ticketing', + 'Ticketing', + 'glm_members_members', + 'glm-members-admin-menu-ticketing-index', + function() { + echo "

    THIS PLUGIN HAS NOT YET BEEN DEVELOPED.

    "; + return; + } +); diff --git a/setup/hooksHelp.html b/setup/hooksHelp.html index bbe0e75..9c1d06f 100644 --- a/setup/hooksHelp.html +++ b/setup/hooksHelp.html @@ -1,16 +1,3 @@ - -

    Sample Add-On

    - - User Permission Hooks - - - some_hook_name - FILTER or ACTION - - - What this hook does. - - - ---> \ No newline at end of file +

    Event Management Add-On