Resource icon

xF1 Unmaintained Xen Product Manager - License Claim 1.0.1

No permission to download
📀 Resource submitted by: AnimeHaxor • 💬 Messages: 6522 • 🏆 Points: 113 • 👍 Likes: 40594 • 📀 Resources: 2251
Compatible XF Versions
  1. 1.5
Additional Requirements
php 5.4+
Xen Product Manager 1.2.x+
Licence claim process for XenForo Product Manager, based of an add-on provided Chris D for handling xenmods add-ons, this has been generalized to handle any number of sites that XPM licences have been exported from.

Some assembly required. You will need to manually export SQL from the exporting side, and then manually import the SQL on the importing side. There is no UI for this.

on the exporting side:

  • Export the contents of the following query, replacing (...) with the list of product ids that are being exported.
  • xenproduct_external_licence2 is a staging table name and SHOULD NOT be xenproduct_external_licence
    Code:
    create table xenproduct_external_licence2 as
    SELECT item.cart_id, item.product_id, item.item_id, license.license_alias, license.license_url, license.expiry_date, license.purchase_date, license.license_optional_extras, cart.cart_key, user.user_id, user.username, user.email
    FROM xenproduct_cart_item AS item
    INNER JOIN xenproduct_license AS license ON
    (item.item_id = license.item_id)
    INNER JOIN xenproduct_cart AS cart ON
    (item.cart_id = cart.cart_id)
    INNER JOIN xf_user AS user ON
    (cart.user_id = user.user_id)
    WHERE item.product_id IN(...)
  • export the table;
    ie:
    Code:
    mysqldump xenproduct_external_licence2

Importing side
  • Install this add-on.
  • Insert site record, note the label is end-user viewable;
    Code:
    insert ignore into xenproduct_site_claimable (site_claimable_id, label) values (1, 'Example.com')
  • Recreate each add-on.
    • set the site + external product id as required.
  • copy data over with the correct site_claimable_id (ie change the 1 in the following query);
    Code:
    insert ignore xenproduct_external_licence (site_claimable_id, cart_id, product_id, item_id, license_alias, license_url, expiry_date, purchase_date, license_optional_extras, cart_key, user_id, username, email)
    select 1, cart_id, product_id, item_id, license_alias, license_url, expiry_date, purchase_date, license_optional_extras, cart_key, user_id, username, email
    from xenproduct_external_licence2;
  • cleanup staging table once confident:
    Code:
    drop table xenproduct_external_licence2;
Author
AnimeHaxor
Size
16.2 KB
Extension
zip
Downloads
10
Views
1,693
First release
Last update

More resources from AnimeHaxor

Latest updates

  1. 1.0.1 - Bugfix update

    Prevent template warning (caused by no external sites being available) when editing an existing...

Similar resources

Newest Products (for Xen Product Manager) - ThemesCorp Admin
This add-on allows you to view the Newewst products in a block in the sidebar.
Xen Product Manager AnimeHaxor
Sell licenses for digital products and manage optional extras and renewals all within XenForo
Shows a hint for users to prevent the creation of redundant licenses.

741Threads
2,316Messages
68,404Members
mmvLatest member
Back