generated from autonomic-cooperative/wordpress-starter
	Initial work on showing labels for non-coffee items
	
		
			
	
		
	
	
		
	
		
			All checks were successful
		
		
	
	
		
			
				
	
				continuous-integration/drone/push Build is passing
				
			
		
		
	
	
				
					
				
			
		
			All checks were successful
		
		
	
	continuous-integration/drone/push Build is passing
				
			This commit is contained in:
		@ -122,13 +122,13 @@ if(!is_user_logged_in()){
 | 
				
			|||||||
              }
 | 
					              }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
          if (!$is_coffee && !$is_subscription) {
 | 
					          if ($is_coffee || $is_subscription) {
 | 
				
			||||||
              continue;
 | 
					              $brew_method = $item->get_meta("pa_brew-method");
 | 
				
			||||||
 | 
					              $weight = $item->get_meta("weight");
 | 
				
			||||||
 | 
					          } else {
 | 
				
			||||||
 | 
					              $product_name = $item->get_name();
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
          $brew_method = $item->get_meta("pa_brew-method");
 | 
					 | 
				
			||||||
          $weight = $item->get_meta("weight");
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
          if ($is_coffee) {
 | 
					          if ($is_coffee) {
 | 
				
			||||||
              // Non-subscription order
 | 
					              // Non-subscription order
 | 
				
			||||||
              $product_name = $item->get_name();
 | 
					              $product_name = $item->get_name();
 | 
				
			||||||
@ -159,11 +159,15 @@ if(!is_user_logged_in()){
 | 
				
			|||||||
        <div class="label">
 | 
					        <div class="label">
 | 
				
			||||||
          <div>
 | 
					          <div>
 | 
				
			||||||
            <div class="product-details">
 | 
					            <div class="product-details">
 | 
				
			||||||
 | 
					              <?php if ($is_coffee || $is_subscription) { ?>
 | 
				
			||||||
              <p class="weight"><?php echo $weight; ?></p>
 | 
					              <p class="weight"><?php echo $weight; ?></p>
 | 
				
			||||||
 | 
					              <?php } ?>
 | 
				
			||||||
              <p class="origin"><?php echo $product_name; ?></p>
 | 
					              <p class="origin"><?php echo $product_name; ?></p>
 | 
				
			||||||
 | 
					              <?php if ($is_coffee || $is_subscription) { ?>
 | 
				
			||||||
              <p class="bean-type"><?php echo $brew_method; ?></p>
 | 
					              <p class="bean-type"><?php echo $brew_method; ?></p>
 | 
				
			||||||
              <p class="roast"><?php echo $roast; ?> Roast</p>
 | 
					              <p class="roast"><?php echo $roast; ?> Roast</p>
 | 
				
			||||||
              <p class="date">Roasted on: <span><?php echo $roast_date; ?></span></p>
 | 
					              <p class="date">Roasted on: <span><?php echo $roast_date; ?></span></p>
 | 
				
			||||||
 | 
					              <?php } ?>
 | 
				
			||||||
              <p class="code"><?php
 | 
					              <p class="code"><?php
 | 
				
			||||||
              echo $is_new ? "N" : "";
 | 
					              echo $is_new ? "N" : "";
 | 
				
			||||||
              echo $gift_message ? "G" : "";
 | 
					              echo $gift_message ? "G" : "";
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user