[Vtigercrm-developers] 600_610.php migration script...
Alan Lord (News)
alanslists at gmail.com
Thu Nov 20 08:02:30 GMT 2014
On 19/11/14 15:12, Alan Lord wrote:
>
>> $customer = PBXManager_Record_Model::lookUpRelatedWithNumber($callfrom);
>
> That function lookUpRelatedWithNumber() will *never* return a $customer
> array because there is no phone number in the callto column - there is a
> href with a crmid...
Of course I meant call_from which, for all of our customers only ever
contains the user's firstname lastname string...
> What on earth was the idea behind this?
Also, the subsequent query in the script above to populate the new
pbxmanager columns attempts to write the value of $customer (which is an
*ARRAY*) into one customer column. Is there some magic I wasn't aware of
to handle this?
> $adb->pquery('UPDATE vtiger_pbxmanager SET customer = ? AND user = ? AND totalduration = ? AND callstatus = ? WHERE pbxmanagerid = ?', array($customer, $user, $timeofcall, $callstatus, $pbxmanagerid));
Al
--
Libertus Solutions
http://www.libertus.co.uk
More information about the vtigercrm-developers
mailing list