mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-22 07:53:39 +01:00
Update to link to new csv alternate for import
This commit is contained in:
parent
886c7f665c
commit
4ccc2823a5
@ -119,31 +119,22 @@
|
||||
// else they may be accounts, etc.
|
||||
if (!$filter) { $filter = 'none'; }
|
||||
|
||||
if ($filter == "none") {
|
||||
if (!$cat_id) {
|
||||
$qfilter = 'tid=n';
|
||||
} else {
|
||||
$qfilter = 'tid=n,cat_id='.$cat_id;
|
||||
}
|
||||
} elseif($filter == "private") {
|
||||
if (!$cat_id) {
|
||||
$qfilter = 'tid=n,access=private,owner='.$phpgw_info['user']['account_id'];
|
||||
} else {
|
||||
$qfilter = 'tid=n,access=private,owner='.$phpgw_info['user']['account_id'].',cat_id='.$cat_id;
|
||||
}
|
||||
} elseif($filter == "yours") {
|
||||
if (!$cat_id) {
|
||||
$qfilter = 'tid=n,owner='.$phpgw_info['user']['account_id'];
|
||||
} else {
|
||||
$qfilter = 'tid=n,owner='.$phpgw_info['user']['account_id'].',cat_id='.$cat_id;
|
||||
}
|
||||
} else {
|
||||
if (!$cat_id) {
|
||||
$qfilter = 'tid=n,owner='.$filter;
|
||||
} else {
|
||||
$qfilter = 'tid=n,owner='.$filter.'cat_id='.$cat_id;
|
||||
}
|
||||
$qfilter = 'tid=n';
|
||||
|
||||
switch ($filter) {
|
||||
case 'none':
|
||||
break;
|
||||
case 'private':
|
||||
$qfilter .= ',access=private'; // fall through
|
||||
case 'yours':
|
||||
$qfilter .= ',owner='.$phpgw_info['user']['account_id'];
|
||||
break;
|
||||
default:
|
||||
$qfilter .= ',owner='.$filter;
|
||||
}
|
||||
if ($cat_id) {
|
||||
$qfilter .= ',cat_id='.$cat_id;
|
||||
}
|
||||
|
||||
// Check if prefs were set, if not, create some defaults
|
||||
if (!$columns_to_display )
|
||||
@ -221,6 +212,8 @@
|
||||
$t->set_var('vcard_url',$phpgw->link('/addressbook/vcardin.php'));
|
||||
$t->set_var('lang_import',lang('Import Contacts'));
|
||||
$t->set_var('import_url',$phpgw->link('/addressbook/import.php'));
|
||||
$t->set_var('lang_import_alt',lang('Alt. CSV Import'));
|
||||
$t->set_var('import_alt_url',$phpgw->link('/addressbook/csv_import.php'));
|
||||
$t->set_var('lang_export',lang('Export Contacts'));
|
||||
$t->set_var('export_url',$phpgw->link('/addressbook/export.php'));
|
||||
$t->set_var('start',$start);
|
||||
|
@ -101,6 +101,17 @@
|
||||
</form>
|
||||
</div>
|
||||
</td>
|
||||
<td width="16%">
|
||||
<div align="left">
|
||||
<form action="{import_alt_url}" method="post">
|
||||
<input type="hidden" name="sort" value="{sort}">
|
||||
<input type="hidden" name="order" value="{order}">
|
||||
<input type="hidden" name="filter" value="{filter}">
|
||||
<input type="hidden" name="start" value="{start}">
|
||||
<input type="submit" name="Import" value="{lang_import_alt}">
|
||||
</form>
|
||||
</div>
|
||||
</td>
|
||||
<td width="16%">
|
||||
<div align="left">
|
||||
<form action="{export_url}" method="post">
|
||||
|
Loading…
Reference in New Issue
Block a user