Record View Counter, Update Record, Increment
When using ADDT, I created a record view counter. In my database, each record had a numeric column entitled viewCount. On page load (for a record's detail page), the page had a custom transaction as follows that would add 1 to the number in the viewCount column:
// Make a custom transaction instance
$countViews = new tNG_custom($conn_wmConn);
$tNGs->addTransaction($countViews);
// Register triggers
$countViews->registerTrigger("STARTER", "Trigger_Default_Starter", 1, "VALUE", "1");
// Set custom transaction SQL
$countViews->setSQL("UPDATE wm_inventory SET viewCount = viewCount + 1 WHERE id = {GET.id}");
// Add columns
// End of custom transaction instance
This would increment the viewCounter column in my database for that record by 1 when its detail page was loaded.
How can I go about setting up something similar with WebAssist's extensions? I have played around with adding an dataassist update record sb, but doesn't seem to work.
Thanks for any help.
D.