Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
  1. Create Card with Card ID : “WooCommerce” (or any) - this card as imaginary customer

  2. Create special Card Type for this Imaginary customer

    image-20240903-025458.pngImage Removedimage-20240904-062342.pngImage Added


  3. Link this Card ID in WooCoomerce Upload Task : Parameter ContractCardID

    image-20240903-025639.png

  4. Create Webhook to trigger when contract Activated Or Ended

    image-20240903-031102.png


    Enabled : Yes
    Custom Mode : Yes
    Fire on Changed : Yes
    Data Type : Contract
    Url : dummy

    Criteria : [Workflow Status.Name] In ('Active', 'Closed') And ([All Customers] = True Or [Card Contracts][[Card.Card ID] = 'WooCommerceWOOCOMMERCECARDID'] And [Workflow Status.Name] In ('Active', 'Closed'Or [Card Type] = 'WOOCOMMERCECARDTYPE')

    Property Changed : WorkflowStatus
    Contents : {FUNCTION:WooCommerceContractUpdateProduct}

  5. Create a contract with this imaginary customer only (OR AllCustomers OR Card Type)
    -- Note: only would be pick up by Webhook if match Card ID or Card Type in Webhook

    image-20240903-030026.png
  6. Add Product and set active contract

    image-20240903-030237.png
  7. Task product upload will update this product

  8. Result in WooCommerce
    a. Before

    image-20240903-030450.png

    c. After

    image-20240903-030811.png
  9. When contract ended, Webhook will trigger and Task will run on schedule to update the product to WooCommerce

...