Now checking date range tickets may be purchased in view file.
authorChuck Scott <cscott@gaslightmedia.com>
Thu, 1 Aug 2019 16:47:49 +0000 (12:47 -0400)
committerChuck Scott <cscott@gaslightmedia.com>
Thu, 1 Aug 2019 16:47:49 +0000 (12:47 -0400)
views/front/MMM/Shop/ticketSelect.html

index 952a48c..ca34a82 100755 (executable)
             <input type="hidden" name="PerformanceID" value="{performanceDetail.id}">
             <input type="hidden" name="SectionID" value="{sectionDetail.id}">
     {foreach:s.ticketsData,x}
-     {if:!x.tooLateToBuy}
             <div class="glmBlock">
-      {if:option.ticket_selection.include_options_in_ticket_list}
+        {if:option.ticket_selection.include_options_in_ticket_list}
+
+         {if:x.tooEarlyToBuy}
+            <div class="glmBlockContent">
+                <b>Sorry, these tickets may not be purchased before {x.for_sale_start_date.date}.</b>
+            </div>
+         {else:}
+          {if:x.tooLateToBuy}
+            <div class="glmBlockContent">
+                <b>Sorry, these tickets may not be purchased after {x.for_sale_end_date.date}.</b>
+            </div>         
+          {else:}
+
                 <div class="glmBlockContentRight">
                     <div class="glmBlockContent">
                         <div class="glmTicketsSelectPrompt">Price:&nbsp;</div>
@@ -87,6 +98,8 @@
                             <div class="glmInput">{x.price}</div>
                         </div>
                     </div>
+
+
                     <div id="GLMeventDateSelect_{x.id}" class="glmBlockContent">
                         <div class="glmTicketsSelectPrompt">Select date:&nbsp;</div>
                         <div class="glmTicketsSelectValue"> 
                             <div id="GLMticketQuantContainer_{x.id}" class="glmInput">(select date)</div>
                         </div>
                     </div>
+                    
+    
                 </div> <!-- glmBLockContentRight -->
-      {end:}
+
+          {end:} <!-- / !too early to buy -->
+         {end:}  <!-- / !too late to buy -->
+                    
+        {end:}
                 <div class="glmBlockContentLeft"> 
-      {if:option.ticket_selection.include_options_in_ticket_list}
+        {if:option.ticket_selection.include_options_in_ticket_list}
                     <div class="glmBlockName">{x.title}</div>
-      {else:}
+        {else:}
                     <div class="glmBlockName">
                         <a href="{baseSCRIPT}&Action=Shop_ticketOpt&PerformanceID={performanceDetail.id}&SectionID={x.section_id}&TicketID={x.id}">{x.name}</a>
                     </div>
-      {end:}
+        {end:}
                        <div class="glmBlockContent">
                         <div class="glmDescr">
         {if:x.descr}
                             <p>{x.short_descr:h}</p>
         {end:}
-                            <p>
-        {if:!x.date_specific.value}
-                                {if:x.start_date.timestamp} Date: {x.start_date.date}{end:}{if:!x.start_end_dates_same} to {x.end_date.date}{end:}{if:!x.time_specific.value} {end:} 
-        {end:}
-        {if:!x.time_specific.value}
-                                
-        {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:}
-                                <!-- Each {term.ticket.norm} may be used {x.uses} time(s) -->
-        {end:}
-                            </p>
+
+
+    
+    
+                                <p>
+            {if:!x.date_specific.value}
+                                    {if:x.start_date.timestamp} Date: {x.start_date.date}{end:}{if:!x.start_end_dates_same} to {x.end_date.date}{end:}{if:!x.time_specific.value} {end:} 
+            {end:}
+            {if:!x.time_specific.value}
+                                    
+            {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:}
+                                    <!-- Each {term.ticket.norm} may be used {x.uses} time(s) -->
+            {end:}
+                                </p>
+
+
+
+
                         </div>
                     </div>
                 </div><!--/.glmBlockContentLeft-->
             </div><!--/.glmBlock-->
-     {end:}
+
     {end:}
                    <div id="GLMselect">
                 <a class="GLMselectButton glmNavItem">{term.nav.select}</a>