Hi,
I have changed a custom field to a button and i want to perform customAction when clicked on the button.
This button can be viewed in the View Page.
//here is my button:
//This is my ListOption_Load:
$this->CustomActions[“order”] = new ListAction(“order”, “Add To MY Cart”, IsLoggedIn(), ACTION_AJAX, ACTION_SINGLE,“” ,“fas fa-cart-plus ew-icon”);
//This is my Row_CustomAction
$oid = ExecuteScalar(“SELECT OrderNo FROM mycart ORDER BY OrderNo DESC LIMIT 1”);
$myResult = Execute(“INSERT INTO cartdetails (OrderNo, SellerID, CustomerID, Code, Qty, Price, Status)
VALUES(‘$oid’, '” . $row[“UsersID”] . “', ‘$cuid’, '” . $row[“Code”] . “', ‘1’, '” . $row[“Price”] . “', ‘1’ )
ON DUPLICATE KEY UPDATE Qty = Qty+1”);
Note: As it is this code is doing its job "without the custom field as a button.
can you guys pls. let me know how to connect this button to this custom action.
Thank you