Skip to content

Commit

Permalink
Make default structure match saved structure params for ticket models
Browse files Browse the repository at this point in the history
  • Loading branch information
joedolson committed Dec 27, 2023
1 parent 6e9a781 commit e0906f7
Showing 1 changed file with 21 additions and 11 deletions.
32 changes: 21 additions & 11 deletions src/my-tickets.php
Original file line number Diff line number Diff line change
Expand Up @@ -579,72 +579,82 @@ function mt_default_settings() {
),
);
$continuous = array(
'sales_type' => 'tickets',
'counting_method' => 'continuous',
'reg_expires' => '3',
'multiple' => 'true',
'sales_type' => 'tickets',
'counting_method' => 'continuous',
'pricing' => array(
'adult' => array(
'label' => 'Adult',
'price' => '',
'price' => '20',
'tickets' => '',
'sold' => '',
'close' => '',
),
'senior-student' => array(
'label' => 'Senior/Student',
'price' => '',
'price' => '15',
'tickets' => '',
'sold' => '',
'close' => '',
),
'child' => array(
'label' => 'Child',
'price' => '',
'price' => '10',
'tickets' => '',
'sold' => '',
'close' => '',
),
),
'tickets' => '120',
);

$discrete = array(
'sales_type' => 'tickets',
'counting_method' => 'discrete',
'reg_expires' => '3',
'multiple' => 'true',
'sales_type' => 'tickets',
'counting_method' => 'discrete',
'pricing' => array(
'section-a' => array(
'label' => 'Section A',
'price' => '20',
'tickets' => '40',
'sold' => '',
'close' => '',
),
'section-b' => array(
'label' => 'Section B',
'price' => '15',
'tickets' => '40',
'price' => '10',
'tickets' => '60',
'sold' => '',
'close' => '',
),
),
'tickets' => 'inherit',
);

$showtime = array(
'reg_expires' => '3',
'multiple' => 'true',
'sales_type' => 'tickets',
'counting_method' => 'event',
'reg_expires' => '1',
'multiple' => 'true',
'pricing' => array(
'first-showing' => array(
'label' => date_i18n( 'Y-m-d H:i', strtotime( '8:00pm + 1 day' ) ),
'price' => '20',
'tickets' => '40',
'sold' => '',
'close' => '',
),
'second-showing' => array(
'label' => date_i18n( 'Y-m-d H:i', strtotime( '2:00pm + 2 days' ) ),
'price' => '15',
'tickets' => '40',
'sold' => '',
'close' => '',
),
),
'tickets' => 'inherit',
);

$defaults = array(
Expand Down

0 comments on commit e0906f7

Please sign in to comment.