Stelio Kontos
Forum Replies Created
-
Additionally, the links for the associated products link to that generator’s edit page (the same page they’re being viewed from – https://i.imgur.com/DOTRVu1.png). It would seem more appropriate to have them link to the actual product edit page instead.
Current:
{site_url}/wp-admin/admin.php?page=lmfwc_generators&action=edit&id={generator_id}&_wpnonce={nonce}
Suggested:{site_url}/wp-admin/post.php?post={post_id}&action=edit
Video demonstrating PUT/POST calls through Postman
Env info:
### wp-core ### version: 6.0.1 site_language: en_US user_language: en_US timezone: -05:00 permalink: /%year%/%monthnum%/%day%/%postname%/ https_status: true multisite: false user_registration: 0 blog_public: 1 default_comment_status: open environment_type: production user_count: 1296 dotorg_communication: true ### wp-server ### server_architecture: Linux 2.6.32-954.3.5.lve1.4.87.el6.x86_64 x86_64 httpd_software: LiteSpeed php_version: 7.4.30 64bit php_sapi: litespeed max_input_variables: 2000 time_limit: 600 memory_limit: 1024M max_input_time: 1500 upload_max_filesize: 1024M php_post_max_size: 1024M curl_version: 7.71.0 OpenSSL/1.1.1p suhosin: false imagick_availability: false pretty_permalinks: true htaccess_extra_rules: true ### wp-database ### extension: mysqli server_version: 10.3.35-MariaDB-log-cll-lve client_version: mysqlnd 7.4.30 max_allowed_packet: 1073741824 max_connections: 500
@utpal23 In your settings, only check *one* order status – the lowest status level necessary for the client to get access to the license key. Leave all order status levels above that one unchecked, and see if that fixes it. (Checking a status level should enable it for both that level, and all status levels above that one, by default).
If it’s still not showing up, check the order notes to verify that the order status was set to the one you have checked at some point; if not, manually update the status to that one, and recheck if it shows up. It is possible I suppose that skipping a status level might not trigger enabling the key visibility on the account page, but I haven’t checked the source to verify.
Also, did the plugin ever send the license key email? The email should be triggered at the same time that it becomes visible on the user account page.
Lastly, if you are using custom order statuses (as it appears you are), try disabling the plugin(s) responsible for that, since status names may not actually represent the underlying status it appears to be.
With each of the tests I suggested above, run a new order through the system to test it; simply refreshing the account page for the same order each time may not reflect the changes depending on what actions are being used to trigger the visibility in my account. (At the very least, manually update the order status each time, if testing on the same order).
Forum: Plugins
In reply to: [License Manager for WooCommerce] Migrating licensesActually, the logic in the import controller appears to make several assumptions about which fields are included in the imported text; I attempted multiple imports both with/without column names in first line, from clipboard and from csv file, using an export with default options (exporting all fields) and leaving the additional fields on the import page blank, and none of them resulted in a proper import.
As a user, the options on the import page are counter-intuitive, as that data is typically expected to already be in the import file. After briefly glancing at the license controller code (apologies if I’m mistaken), it appears that those fields (orderId, productId, userId, status, source) are ignored from the import data altogether. As those fields are not required, leaving them blank results in a “successful” import, but with malformed license key data.
If @haseeb0001 is open, I don’t mind putting together a PR to improve on the import functionality. My approach would be something along the lines of:
– Parse the import data to determine which columns are included.
– Add an option to the import page settings to specify if the manually-set options should act as:
(1) default values for entries with null values in those columns, or
(2) override values that take precedence over the column value in the import data
– Make any manual import settings the code requires for a valid import (and are ignored in the import file) required (though import data should be enough imo).
– Add a confirmation view showing the result of the import to allow the user a chance to review the imported licenses prior to committing the imported data to the db. An option to edit values on the review page could always be added down the road, potentially as a premium feature even.Forum: Plugins
In reply to: [License Manager for WooCommerce] License Key for variable productProduct attributes with the “Use as variation” option enabled do not actually create a specific “sub product” (aka, unique product id for that variation combination) if they are not specified explicitly as a variation. In other words, any attributes prefixed with “Any ___” get added to the order as meta data for a single product id. Both items in this picture have a different value for the “warranty” attribute, but they’re still the same product (#34050136: Trial Time – 3 days), and share the same stock/shipping/price: https://i.imgur.com/5GoH9cr.png.
The plugin associates license keys to a product id, but does not attempt to query the product attribute meta data (and imo, this is how it should be), so in the previous image, the warranty value won’t actually show up with your license key.
In your case, you need a different variation for each possible attribute combination; use the “create variations from all attributes” option to create them all at once. Then edit each one to be virtual with the correct price and license key options. Both possible values for the “warranty” attribute now have unique sub-product ids, and are two distinct products instead of one product with different meta data: https://i.imgur.com/rhSteyu.png.
- This reply was modified 2 years, 4 months ago by Stelio Kontos. Reason: fixed screenshot link
- This reply was modified 2 years, 4 months ago by Stelio Kontos.
Forum: Plugins
In reply to: [License Manager for WooCommerce] License Key for variable product@thisvo I do believe this is possible, actually. Is this what you are intending to do? The first key (Y08-6AB-KNL) is with the second variation left unselected.
Product page with two variations:
Generated variation-specific license keys:
License keys listing on user account page: