Feb 17, 2015

Gist: WP-CLI migration from ejunkie to WooCommerce

This script is used to migrate a transaction export from ejunkie into a Woocommerce-powered site. Please read the comments throughout to adjust this to your use case.

You'll need to create a new table and import your ejunkie data before running this. Table syntax is below, a few things to keep in mind:

CREATE TABLE `ejunkie_migrate` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`purchase_date_time` datetime NOT NULL,
`transaction_id` tinytext NOT NULL,
`payment_processor` tinytext NOT NULL,
`ejunkie_txn_id` tinytext NOT NULL,
`payment_status` tinytext NOT NULL,
`first_name` tinytext NOT NULL,
`last_name` tinytext NOT NULL,
`email` tinytext NOT NULL,
`billing_info` tinytext,
`payer_ip` tinytext NOT NULL,
`invoice_id` tinytext NOT NULL,
`affiliate_email` tinytext,
`affiliate_name` tinytext,
`affiliate_id` int(20) DEFAULT NULL,
`currency` tinytext NOT NULL,
`item_name` tinytext NOT NULL,
`item_number` tinytext NOT NULL,
`quantity` int(3) NOT NULL,
`amount` float NOT NULL,
`affiliate_share` float NOT NULL DEFAULT '0',
`download_info` tinytext,
`payment_country` tinytext NOT NULL,
`wp_order_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;

< Take Action! >

Go there › Suggest changes on GitHub ›

< Read More >

Tags

Gist

Newer

Mar 05, 2015

Intermediate Sass/SCSS class in Seattle

For web development folks in Seattle who want to level up on Sass, SCSS, Bourbon, and the like, I'm helping to organize an intermediate-level class sometime in the next couple of months.

Older