PluginProbe
StoreEngine — Complete eCommerce Solution with Memberships, Licensing, Affiliates & More / 2.2.0
StoreEngine — Complete eCommerce Solution with Memberships, Licensing, Affiliates & More v2.2.0
2.3.0 2.2.0 2.1.1 2.1.0 2.0.0 1.10.0 1.9.1 1.9.0 1.2.1 1.2.2 1.3.0 1.3.1 1.3.2 1.3.3 1.4.0 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4 1.5.5 1.5.6 1.5.7 1.5.8 1.6.0 All 59 releases
storeengine / includes / database / create-order-operational-data.php

create-order-operational-data.php in StoreEngine — Complete eCommerce Solution with Memberships, Licensing, Affiliates & More 2.2.0, at includes/database/create-order-operational-data.php

40 lines 1.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace StoreEngine\Database;
4
5 if ( ! defined( 'ABSPATH' ) ) {
6 exit;
7 }
8
9 class CreateOrderOperationalData {
10
11 public static function up( $prefix, $charset_collate ) {
12 $table_name = $prefix . 'storeengine_order_operational_data';
13 $sql = "CREATE TABLE IF NOT EXISTS {$table_name} (
14 `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
15 `order_id` bigint(20) unsigned DEFAULT NULL,
16 `created_via` varchar(100) DEFAULT NULL,
17 `storeengine_version` varchar(20) DEFAULT NULL,
18 `prices_include_tax` tinyint(1) DEFAULT NULL,
19 `coupon_usages_are_counted` tinyint(1) DEFAULT NULL,
20 `download_permission_granted` tinyint(1) DEFAULT NULL,
21 `cart_hash` varchar(100) DEFAULT NULL,
22 `new_order_email_sent` tinyint(1) DEFAULT NULL,
23 `order_key` varchar(100) DEFAULT NULL,
24 `order_stock_reduced` tinyint(1) DEFAULT NULL,
25 `date_paid_gmt` datetime DEFAULT NULL,
26 `date_completed_gmt` datetime DEFAULT NULL,
27 `shipping_tax_amount` decimal(26,8) DEFAULT NULL,
28 `shipping_total_amount` decimal(26,8) DEFAULT NULL,
29 `discount_tax_amount` decimal(26,8) DEFAULT NULL,
30 `discount_total_amount` decimal(26,8) DEFAULT NULL,
31 `recorded_sales` tinyint(1) DEFAULT NULL,
32 PRIMARY KEY (`id`),
33 UNIQUE KEY `order_id` (`order_id`),
34 KEY `order_key` (`order_key`)
35 ) $charset_collate;";
36
37 dbDelta( $sql );
38 }
39 }
40