Merge branch 'master' of gitorious.org:owncloud/owncloud into ace-editor
This commit is contained in:
commit
afa93c1f28
|
@ -107,7 +107,12 @@ OC_Contacts_VCard::edit($id,$vcard->serialize());
|
|||
$adr_types = OC_Contacts_VCard::getTypesOfProperty($l10n, 'ADR');
|
||||
$phone_types = OC_Contacts_VCard::getTypesOfProperty($l10n, 'TEL');
|
||||
|
||||
if ($vcard->children[$line]->name == 'FN'){
|
||||
$tmpl = new OC_Template('contacts','part.property.FN');
|
||||
}
|
||||
else{
|
||||
$tmpl = new OC_Template('contacts','part.property');
|
||||
}
|
||||
$tmpl->assign('adr_types',$adr_types);
|
||||
$tmpl->assign('phone_types',$phone_types);
|
||||
$tmpl->assign('property',OC_Contacts_VCard::structureProperty($vcard->children[$line],$line));
|
||||
|
|
|
@ -110,7 +110,7 @@ $(document).ready(function(){
|
|||
|
||||
$('.contacts_property [data-use="edit"]').live('click',function(){
|
||||
var id = $('#rightcontent').data('id');
|
||||
var checksum = $(this).parents('li').first().data('checksum');
|
||||
var checksum = $(this).parents('.contacts_property').first().data('checksum');
|
||||
$.getJSON('ajax/showsetproperty.php',{'id': id, 'checksum': checksum },function(jsondata){
|
||||
if(jsondata.status == 'success'){
|
||||
$('.contacts_property[data-checksum="'+checksum+'"]').html(jsondata.data.page)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?php if(array_key_exists('FN',$_['details'])): ?>
|
||||
<p id="contacts_details_name"><?php echo $_['details']['FN'][0]['value']; ?></p>
|
||||
<?php echo $this->inc('part.property.FN', array('property' => $_['details']['FN'][0])); ?>
|
||||
<img class="svg action" id="contacts_deletecard" src="<?php echo image_path('', 'actions/delete.svg'); ?>" title="<?php echo $l->t('Delete contact');?>" />
|
||||
|
||||
<?php if(isset($_['details']['PHOTO'])): // Emails first ?>
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
<p id="contacts_details_name" class="contacts_property" data-checksum="<?php echo $_['property']['checksum']; ?>">
|
||||
<?php echo $_['property']['value']; ?>
|
||||
<span style="display:none;" data-use="edit"><img class="svg action" src="<?php echo image_path('', 'actions/rename.svg'); ?>" /></span>
|
||||
</p>
|
||||
<?php if (!isset($_['details'])): ?>
|
||||
<script>
|
||||
$('#leftcontent li.active a').text('<?php echo $_['property']['value']; ?>');
|
||||
</script>
|
||||
<?php endif ?>
|
|
@ -1,7 +1,9 @@
|
|||
<form id="contacts_setpropertyform">
|
||||
<input type="hidden" name="checksum" value="<?php echo $_['property']['checksum']; ?>">
|
||||
<input type="hidden" name="id" value="<?php echo $_['id']; ?>">
|
||||
<?php if($_['property']['name']=='ADR'): ?>
|
||||
<?php if($_['property']['name']=='FN'): ?>
|
||||
<p class="contacts_property_data"><input id="fn" type="text" name="value" value="<?php echo $_['property']['value']; ?>"></p>
|
||||
<?php elseif($_['property']['name']=='ADR'): ?>
|
||||
<p class="contacts_property_name"><label for="adr_pobox"><?php echo $l->t('Address'); ?></label></p>
|
||||
<ol class="contacts_property_data" id="contacts_addresspart">
|
||||
<li class="input">
|
||||
|
|
|
@ -125,7 +125,7 @@ FileList={
|
|||
tr.data('renaming',true);
|
||||
var td=tr.children('td.filename');
|
||||
var input=$('<input class="filename"></input>').val(name);
|
||||
var form=$('<form action="#"></form>')
|
||||
var form=$('<form></form>')
|
||||
form.append(input);
|
||||
td.children('a.name').text('');
|
||||
td.children('a.name').append(form)
|
||||
|
@ -134,7 +134,6 @@ FileList={
|
|||
event.stopPropagation();
|
||||
event.preventDefault();
|
||||
var newname=input.val();
|
||||
tr.data('renaming',false);
|
||||
tr.attr('data-file',newname);
|
||||
td.children('a.name').empty();
|
||||
if(newname.indexOf('.')>0){
|
||||
|
@ -148,12 +147,12 @@ FileList={
|
|||
if(newname.indexOf('.')>0){
|
||||
span.append($('<span class="extention">'+newname.substr(newname.lastIndexOf('.'))+'</span>'));
|
||||
}
|
||||
$.ajax({
|
||||
url: 'ajax/rename.php',
|
||||
data: { dir : $('#dir').val(), newname: newname, file: name }
|
||||
$.get(OC.filePath('files','ajax','rename.php'), { dir : $('#dir').val(), newname: newname, file: name },function(){
|
||||
tr.data('renaming',false);
|
||||
});
|
||||
return false;
|
||||
});
|
||||
form.click(function(event){
|
||||
input.click(function(event){
|
||||
event.stopPropagation();
|
||||
event.preventDefault();
|
||||
});
|
||||
|
|
|
@ -70,7 +70,9 @@ $(document).ready(function() {
|
|||
procesSelection();
|
||||
} else {
|
||||
var filename=$(this).parent().parent().attr('data-file');
|
||||
if(!FileList.isLoading(filename)){
|
||||
var tr=$('tr').filterAttr('data-file',filename);
|
||||
var renaming=tr.data('renaming')
|
||||
if(!renaming && !FileList.isLoading(filename)){
|
||||
var mime=$(this).parent().parent().data('mime');
|
||||
var type=$(this).parent().parent().data('type');
|
||||
var action=FileActions.getDefault(mime,type);
|
||||
|
|
Loading…
Reference in New Issue