[Vtigercrm-developers] how to get deleted records via webservice
lucia digirolamo
l.digirolamo at websonica.net
Fri Sep 6 13:31:11 GMT 2019
Hi,
I have an external php script who programmatically check a vtiger 6.4.
In order to do so, I've used the vtwsclib library. Now I need to get the
records that have been deleted in the crm (records which have deleted =
1 in vtiger_crmentity table). Unfortunately, the vtwsclib doQuery()
function works only with modules and not directly with tables. So I
tried to use the vtwsclib doInvoke() with a custom webservice:
- I added my webservice in the operation table:
|INSERT INTO
`vtiger_ws_operation`(`name`,`handler_path`,`handler_method`,`type`,`prelogin`)VALUES
('my_webservice_method','include/Webservices/WbsWebserviceMethod.php','vtws_my_webservice_method’,
'GET', 0);|
- I added the only parameter I need in the parameters table:
|INSERT INTO
`vtiger_ws_operation_parameters`(`operationid`,`name`,`type`,`sequence`)VALUES
(35,'key','String',1);|
- I created the 'include/Webservices/WbsWebserviceMethod.php':
|<?php functionvtws_my_webservice_method($key){returntrue;}?>|
- I call the custom webservice from my external php:
|<?php functionvtws_my_webservice_method($key){ // some other code and
login. Login is successful. $results = $client->doInvoke('|||vtws_my_webservice_method|', ['key' => $key], 'GET');
var_dump($results);}?>|
but it doesn't work, the doInvoke() returns false. Did I miss something?
Thanks
||
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.vtigercrm.com/pipermail/vtigercrm-developers/attachments/20190906/ee045014/attachment.html>
More information about the vtigercrm-developers
mailing list