abook_vcard cleanup
This commit is contained in:
parent
a270ca5101
commit
f3ec818a66
@ -228,7 +228,7 @@ class Connections extends \Zotlabs\Web\Controller {
|
|||||||
|
|
||||||
$contacts = array();
|
$contacts = array();
|
||||||
|
|
||||||
if(count($r)) {
|
if($r) {
|
||||||
|
|
||||||
foreach($r as $rr) {
|
foreach($r as $rr) {
|
||||||
if($rr['xchan_url']) {
|
if($rr['xchan_url']) {
|
||||||
|
@ -37,7 +37,7 @@ class Connedit extends \Zotlabs\Web\Controller {
|
|||||||
intval(argv(1))
|
intval(argv(1))
|
||||||
);
|
);
|
||||||
if($r) {
|
if($r) {
|
||||||
\App::$poi = $r[0];
|
\App::$poi = array_shift($r);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -373,7 +373,7 @@ class Connedit extends \Zotlabs\Web\Controller {
|
|||||||
intval(\App::$poi['abook_id'])
|
intval(\App::$poi['abook_id'])
|
||||||
);
|
);
|
||||||
if($r) {
|
if($r) {
|
||||||
\App::$poi = $r[0];
|
\App::$poi = array_shift($r);
|
||||||
}
|
}
|
||||||
|
|
||||||
$clone = \App::$poi;
|
$clone = \App::$poi;
|
||||||
@ -665,13 +665,13 @@ class Connedit extends \Zotlabs\Web\Controller {
|
|||||||
|
|
||||||
if(feature_enabled(local_channel(),'affinity')) {
|
if(feature_enabled(local_channel(),'affinity')) {
|
||||||
|
|
||||||
$labels = array(
|
$labels = [
|
||||||
t('Me'),
|
t('Me'),
|
||||||
t('Family'),
|
t('Family'),
|
||||||
t('Friends'),
|
t('Friends'),
|
||||||
t('Acquaintances'),
|
t('Acquaintances'),
|
||||||
t('All')
|
t('All')
|
||||||
);
|
];
|
||||||
call_hooks('affinity_labels',$labels);
|
call_hooks('affinity_labels',$labels);
|
||||||
$label_str = '';
|
$label_str = '';
|
||||||
|
|
||||||
@ -789,8 +789,7 @@ class Connedit extends \Zotlabs\Web\Controller {
|
|||||||
else
|
else
|
||||||
$locstr = t('none');
|
$locstr = t('none');
|
||||||
|
|
||||||
$o .= replace_macros($tpl,array(
|
$o .= replace_macros($tpl, [
|
||||||
|
|
||||||
'$header' => (($self) ? t('Connection Default Permissions') : sprintf( t('Connection: %s'),$contact['xchan_name'])),
|
'$header' => (($self) ? t('Connection Default Permissions') : sprintf( t('Connection: %s'),$contact['xchan_name'])),
|
||||||
'$autoperms' => array('autoperms',t('Apply these permissions automatically'), ((get_pconfig(local_channel(),'system','autoperms')) ? 1 : 0), t('Connection requests will be approved without your interaction'), $yes_no),
|
'$autoperms' => array('autoperms',t('Apply these permissions automatically'), ((get_pconfig(local_channel(),'system','autoperms')) ? 1 : 0), t('Connection requests will be approved without your interaction'), $yes_no),
|
||||||
'$addr' => $contact['xchan_addr'],
|
'$addr' => $contact['xchan_addr'],
|
||||||
@ -840,42 +839,34 @@ class Connedit extends \Zotlabs\Web\Controller {
|
|||||||
'$abook_prev' => $abook_prev,
|
'$abook_prev' => $abook_prev,
|
||||||
'$abook_next' => $abook_next,
|
'$abook_next' => $abook_next,
|
||||||
'$vcard_label' => t('Details'),
|
'$vcard_label' => t('Details'),
|
||||||
'$displayname' => $displayname,
|
'$displayname' => $displayname,
|
||||||
'$name_label' => t('Name'),
|
'$name_label' => t('Name'),
|
||||||
'$org_label' => t('Organisation'),
|
'$org_label' => t('Organisation'),
|
||||||
'$title_label' => t('Title'),
|
'$title_label' => t('Title'),
|
||||||
'$tel_label' => t('Phone'),
|
'$tel_label' => t('Phone'),
|
||||||
'$email_label' => t('Email'),
|
'$email_label' => t('Email'),
|
||||||
'$impp_label' => t('Instant messenger'),
|
'$impp_label' => t('Instant messenger'),
|
||||||
'$url_label' => t('Website'),
|
'$url_label' => t('Website'),
|
||||||
'$adr_label' => t('Address'),
|
'$adr_label' => t('Address'),
|
||||||
'$note_label' => t('Note'),
|
'$note_label' => t('Note'),
|
||||||
'$mobile' => t('Mobile'),
|
'$mobile' => t('Mobile'),
|
||||||
'$home' => t('Home'),
|
'$home' => t('Home'),
|
||||||
'$work' => t('Work'),
|
'$work' => t('Work'),
|
||||||
'$other' => t('Other'),
|
'$other' => t('Other'),
|
||||||
'$add_card' => t('Add Contact'),
|
'$add_card' => t('Add Contact'),
|
||||||
'$add_field' => t('Add Field'),
|
'$add_field' => t('Add Field'),
|
||||||
'$create' => t('Create'),
|
'$create' => t('Create'),
|
||||||
'$update' => t('Update'),
|
'$update' => t('Update'),
|
||||||
'$delete' => t('Delete'),
|
'$delete' => t('Delete'),
|
||||||
'$cancel' => t('Cancel'),
|
'$cancel' => t('Cancel'),
|
||||||
'$po_box' => t('P.O. Box'),
|
'$po_box' => t('P.O. Box'),
|
||||||
'$extra' => t('Additional'),
|
'$extra' => t('Additional'),
|
||||||
'$street' => t('Street'),
|
'$street' => t('Street'),
|
||||||
'$locality' => t('Locality'),
|
'$locality' => t('Locality'),
|
||||||
'$region' => t('Region'),
|
'$region' => t('Region'),
|
||||||
'$zip_code' => t('ZIP Code'),
|
'$zip_code' => t('ZIP Code'),
|
||||||
'$country' => t('Country')
|
'$country' => t('Country')
|
||||||
|
]);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
));
|
|
||||||
|
|
||||||
$arr = array('contact' => $contact,'output' => $o);
|
$arr = array('contact' => $contact,'output' => $o);
|
||||||
|
|
||||||
|
@ -121,3 +121,8 @@ input.vcard-fn,
|
|||||||
#template-form-vcard-note {
|
#template-form-vcard-note {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.connphone {
|
||||||
|
font-size: 150%;
|
||||||
|
color: green;
|
||||||
|
}
|
@ -88,15 +88,6 @@
|
|||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<div class="panel">
|
<div class="panel">
|
||||||
<div class="section-subtitle-wrapper" role="tab" id="vcard-tool">
|
|
||||||
<h3>
|
|
||||||
<a data-toggle="collapse" data-parent="#contact-edit-tools" href="#vcard-tool-collapse" aria-expanded="true" aria-controls="vcard-tool-collapse">
|
|
||||||
{{$vcard_label}}
|
|
||||||
</a>
|
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="vcard-tool-collapse" class="panel-collapse collapse{{if !$is_pending || $section == 'vcard'}} in{{/if}}" role="tabpanel" aria-labelledby="vcard-tool">
|
|
||||||
|
|
||||||
|
|
||||||
<div id="template-form-vcard-org" class="form-group form-vcard-org">
|
<div id="template-form-vcard-org" class="form-group form-vcard-org">
|
||||||
@ -194,10 +185,6 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="section-content-wrapper-np">
|
<div class="section-content-wrapper-np">
|
||||||
<div id="vcard-cancel-{{$vcard.id}}" class="vcard-cancel vcard-cancel-btn" data-id="{{$vcard.id}}" data-action="cancel"><i class="fa fa-close"></i></div>
|
<div id="vcard-cancel-{{$vcard.id}}" class="vcard-cancel vcard-cancel-btn" data-id="{{$vcard.id}}" data-action="cancel"><i class="fa fa-close"></i></div>
|
||||||
<div id="vcard-add-field-{{$vcard.id}}" class="dropdown pull-right vcard-add-field">
|
<div id="vcard-add-field-{{$vcard.id}}" class="dropdown pull-right vcard-add-field">
|
||||||
@ -216,8 +203,8 @@
|
|||||||
<div id="vcard-header-{{$vcard.id}}" class="vcard-header" data-id="{{$vcard.id}}" data-action="open">
|
<div id="vcard-header-{{$vcard.id}}" class="vcard-header" data-id="{{$vcard.id}}" data-action="open">
|
||||||
<span id="vcard-preview-{{$vcard.id}}" class="vcard-preview">
|
<span id="vcard-preview-{{$vcard.id}}" class="vcard-preview">
|
||||||
{{if $vcard.fn}}<span class="vcard-fn-preview">{{$vcard.fn}}</span>{{/if}}
|
{{if $vcard.fn}}<span class="vcard-fn-preview">{{$vcard.fn}}</span>{{/if}}
|
||||||
{{if $vcard.emails.0.address}}<span class="vcard-email-preview hidden-xs">{{$vcard.emails.0.address}}</span>{{/if}}
|
{{if $vcard.emails.0.address}}<span class="vcard-email-preview hidden-xs"><a href="mailto:{{$vcard.emails.0.address}}">{{$vcard.emails.0.address}}</a></span>{{/if}}
|
||||||
{{if $vcard.tels.0}}<span class="vcard-tel-preview hidden-xs">{{$vcard.tels.0.nr}}</span>{{/if}}
|
{{if $vcard.tels.0}}<span class="vcard-tel-preview hidden-xs">{{$vcard.tels.0.nr}} <a href="tel:{{$vcard.tels.0.nr}}"><i class="fa fa-phone connphone"></i></a></span>{{/if}}
|
||||||
</span>
|
</span>
|
||||||
<input id="vcard-fn-{{$vcard.id}}" class="vcard-fn" type="text" name="fn" value="{{$vcard.fn}}" size="{{$vcard.fn|count_characters:true}}" placeholder="{{$name_label}}">
|
<input id="vcard-fn-{{$vcard.id}}" class="vcard-fn" type="text" name="fn" value="{{$vcard.fn}}" size="{{$vcard.fn|count_characters:true}}" placeholder="{{$name_label}}">
|
||||||
</div>
|
</div>
|
||||||
@ -378,26 +365,14 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="settings-submit-wrapper" >
|
||||||
|
<button type="submit" name="done" value="{{$submit}}" class="btn btn-primary">{{$submit}}</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="settings-submit-wrapper" >
|
|
||||||
<button type="submit" name="done" value="{{$submit}}" class="btn btn-primary">{{$submit}}</button>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user