Commit 2f601d75 authored by Bart Vullings's avatar Bart Vullings

ZP-1321 Carddav rare phone types. Released under the Affero GNU General Public...

ZP-1321 Carddav rare phone types. Released under the Affero GNU General Public License (AGPL) version 3.
parent 3ccbfd83
...@@ -1081,6 +1081,15 @@ class BackendCardDAV extends BackendDiff implements ISearchProvider { ...@@ -1081,6 +1081,15 @@ class BackendCardDAV extends BackendDiff implements ISearchProvider {
elseif (in_array('cell', $tel['type'])) { elseif (in_array('cell', $tel['type'])) {
$message->mobilephonenumber = $tel['val'][0]; $message->mobilephonenumber = $tel['val'][0];
} }
elseif (in_array('main', $tel['type'])) {
$message->companymainphone = $tel['val'][0];
}
elseif (in_array('assistant', $tel['type'])) {
$message->assistnamephonenumber = $tel['val'][0];
}
elseif (in_array('text', $tel['type'])) {
$message->mms = $tel['val'][0];
}
elseif (in_array('home', $tel['type'])) { elseif (in_array('home', $tel['type'])) {
if (in_array('fax', $tel['type'])) { if (in_array('fax', $tel['type'])) {
$message->homefaxnumber = $tel['val'][0]; $message->homefaxnumber = $tel['val'][0];
...@@ -1242,8 +1251,12 @@ class BackendCardDAV extends BackendDiff implements ISearchProvider { ...@@ -1242,8 +1251,12 @@ class BackendCardDAV extends BackendDiff implements ISearchProvider {
'home2phonenumber' => 'TEL;TYPE=HOME,VOICE', 'home2phonenumber' => 'TEL;TYPE=HOME,VOICE',
'homefaxnumber' => 'TEL;TYPE=HOME,FAX', 'homefaxnumber' => 'TEL;TYPE=HOME,FAX',
'mobilephonenumber' => 'TEL;TYPE=CELL', 'mobilephonenumber' => 'TEL;TYPE=CELL',
'carphonenumber' => 'TEL;TYPE=VOICE', 'carphonenumber' => 'TEL;TYPE=CAR',
'pagernumber' => 'TEL;TYPE=PAGER', 'pagernumber' => 'TEL;TYPE=PAGER',
'companymainphone' => 'TEL;TYPE=WORK,MAIN',
'mms' => 'TEL;TYPE=TEXT',
'radiophonenumber' => 'TEL;TYPE=RADIO,VOICE',
'assistnamephonenumber' => 'TEL;TYPE=ASSISTANT,VOICE',
';;businessstreet;businesscity;businessstate;businesspostalcode;businesscountry' => 'ADR;TYPE=WORK', ';;businessstreet;businesscity;businessstate;businesspostalcode;businesscountry' => 'ADR;TYPE=WORK',
';;homestreet;homecity;homestate;homepostalcode;homecountry' => 'ADR;TYPE=HOME', ';;homestreet;homecity;homestate;homepostalcode;homecountry' => 'ADR;TYPE=HOME',
';;otherstreet;othercity;otherstate;otherpostalcode;othercountry' => 'ADR', ';;otherstreet;othercity;otherstate;otherpostalcode;othercountry' => 'ADR',
...@@ -1290,7 +1303,7 @@ class BackendCardDAV extends BackendDiff implements ISearchProvider { ...@@ -1290,7 +1303,7 @@ class BackendCardDAV extends BackendDiff implements ISearchProvider {
// http://en.wikipedia.org/wiki/VCard // http://en.wikipedia.org/wiki/VCard
// TODO: add support for v4.0 // TODO: add support for v4.0
// not supported: anniversary, assistantname, assistnamephonenumber, children, department, officelocation, radiophonenumber, spouse, rtf // not supported: anniversary, assistantname, children, department, officelocation, spouse, rtf
return $data; return $data;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment