• REGISTRATION REQUIREMENTS:

    Your username here MUST MATCH your XenForo username (connected to your XF license).

    Once you have registered here, then you need to start a conversation at xenforo.com w/Bob and provide the following:
    1. Your XenForo License Validation Token
    2. The Domain Name associated with the License
    NOTE: Your account will be validated once ALL requirements are verified/met. Thank you for your patience.

Fixed External purchase url can be set regardless of category settings

Status
Not open for further replies.

Painbaker

New Member
AMS Premium
CAS Premium
IMS Premium
LD Premium
RMS Premium
SC Premium
UBS Premium
Pick'em
Sportsbook
XenForo Version String: XenForo 2.2.13

Addon Version String: CAS 2.2.28


Steps to reproduce:
1) Enable "Allow an external purchase url to be set when posting or editing ads" for category
2) Open ad adding/editing page, set external purhase URL
3) Disable external purchase urls in category
4) Save ad

Code:
setExternalPurchaseUrl($this->filter('external_purchase_url', 'str'));

Probably should be wrapped in a
Code:
if ($ad.canSetExternalPurchaseUrl()) {}
condition
 
Fair enough, altho extremely edge case ;)

setupAddItem:
PHP:
        if ($ad->canSetExternalPurchaseUrl())
        {
            $adder->setExternalPurchaseUrl($this->filter('external_purchase_url', 'str'));
        }

setupAdEdit:
PHP:
        if ($ad->canSetExternalPurchaseUrl())
        {
            $editor->setExternalPurchaseUrl($this->filter('external_purchase_url', 'str'));
        }

setupAdCreate:
PHP:
        if ($category->canSetExternalPurchaseUrl())
        {
            $creator->setExternalPurchaseUrl($this->filter('external_purchase_url', 'str'));
        }

setupItemEdit:
PHP:
        if ($item->canSetExternalPurchaseUrl())
        {
            $editor->setExternalPurchaseUrl($this->filter('external_purchase_url', 'str'));
        }
 
Status
Not open for further replies.
Back
Top