1
0
mirror of https://github.com/owncloudarchive/contacts.git synced 2025-02-07 01:54:16 +01:00

Contacts: l11n for geo autocomplete. Not sure if it works though.

This commit is contained in:
Thomas Tanghus 2012-04-03 08:13:10 +02:00
parent c86b29d471
commit f84c53f9a9
2 changed files with 4 additions and 1 deletions

View File

@ -919,6 +919,7 @@ Contacts={
featureClass: "P", featureClass: "P",
style: "full", style: "full",
maxRows: 12, maxRows: 12,
lang: lang,
name_startsWith: request.term name_startsWith: request.term
}, },
success: function( data ) { success: function( data ) {
@ -937,7 +938,7 @@ Contacts={
}, },
minLength: 2, minLength: 2,
select: function( event, ui ) { select: function( event, ui ) {
if(ui.item) { if(ui.item && $('#adr_country').val().trim().length == 0) {
$('#adr_country').val(ui.item.country); $('#adr_country').val(ui.item.country);
} }
/*log( ui.item ? /*log( ui.item ?
@ -961,6 +962,7 @@ Contacts={
featureCode: "PCLI", featureCode: "PCLI",
/*countryBias: "true",*/ /*countryBias: "true",*/
/*style: "full",*/ /*style: "full",*/
lang: lang,
maxRows: 12, maxRows: 12,
name_startsWith: request.term name_startsWith: request.term
}, },

View File

@ -1,6 +1,7 @@
<script type='text/javascript'> <script type='text/javascript'>
var totalurl = '<?php echo OC_Helper::linkToAbsolute('contacts', 'carddav.php'); ?>/addressbooks'; var totalurl = '<?php echo OC_Helper::linkToAbsolute('contacts', 'carddav.php'); ?>/addressbooks';
var categories = <?php sort($_['categories']); echo json_encode($_['categories']); ?>; var categories = <?php sort($_['categories']); echo json_encode($_['categories']); ?>;
var lang = '<?php echo OC_Preferences::getValue(OC_User::getUser(), 'core', 'lang', 'en'); ?>';
</script> </script>
<div id="controls"> <div id="controls">
<form> <form>