[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [15868]
From: |
nelson . guerra |
Subject: |
[Fmsystem-commits] [15868] |
Date: |
Fri, 21 Oct 2016 02:03:18 +0000 (UTC) |
Revision: 15868
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=15868
Author: nelson224
Date: 2016-10-21 02:03:18 +0000 (Fri, 21 Oct 2016)
Log Message:
-----------
Modified Paths:
--------------
branches/dev-syncromind-2/property/inc/class.uitts.inc.php
Modified: branches/dev-syncromind-2/property/inc/class.uitts.inc.php
===================================================================
--- branches/dev-syncromind-2/property/inc/class.uitts.inc.php 2016-10-21
02:03:02 UTC (rev 15867)
+++ branches/dev-syncromind-2/property/inc/class.uitts.inc.php 2016-10-21
02:03:18 UTC (rev 15868)
@@ -58,8 +58,8 @@
'receive_order' => true,
'check_purchase_right'=> true,
'show_attachment' => true,
- 'handle_files' => true,
- 'multi_upload' => true
+ 'handle_multi_upload_file' => true,
+ 'build_multi_upload_file' => true
);
/**
@@ -495,14 +495,15 @@
}
}
- public function handle_files()
+ public function handle_multi_upload_file()
{
$id = phpgw::get_var('id');
phpgw::import_class('property.multiuploader');
$options['base_dir'] = 'fmticket/'.$id;
- $options['script_url'] =
html_entity_decode(self::link(array('menuaction' =>
'property.uitts.handle_files', 'id' => $id)));
+ $options['upload_dir'] =
$GLOBALS['phpgw_info']['server']['files_dir'].'/property/'.$options['base_dir'].'/';
+ $options['script_url'] =
html_entity_decode(self::link(array('menuaction' =>
'property.uitts.handle_multi_upload_file', 'id' => $id)));
$upload_handler = new property_multiuploader($options,
false);
switch ($_SERVER['REQUEST_METHOD']) {
@@ -516,10 +517,10 @@
case 'PATCH':
case 'PUT':
case 'POST':
- $upload_handler->post_and_save();
+ $upload_handler->add_file();
break;
case 'DELETE':
- $upload_handler->delete2();
+ $upload_handler->delete_file();
break;
default:
$upload_handler->header('HTTP/1.1 405
Method Not Allowed');
@@ -528,6 +529,25 @@
$GLOBALS['phpgw']->common->phpgw_exit();
}
+ public function build_multi_upload_file()
+ {
+ phpgwapi_jquery::init_multi_upload_file();
+ $id = phpgw::get_var('id', 'int');
+
+ $GLOBALS['phpgw_info']['flags']['noframework'] = true;
+ $GLOBALS['phpgw_info']['flags']['nofooter'] = true;
+
+ $multi_upload_action =
$GLOBALS['phpgw']->link('/index.php', array('menuaction' =>
'property.uitts.handle_multi_upload_file', 'id' => $id));
+
+ $data = array
+ (
+ 'multi_upload_action' => $multi_upload_action
+ );
+
+ $GLOBALS['phpgw']->xslttpl->add_file(array('files',
'multi_upload_file'));
+ $GLOBALS['phpgw']->xslttpl->set_var('phpgw',
array('multi_upload' => $data));
+ }
+
function columns()
{
$receipt = array();
@@ -1181,25 +1201,6 @@
self::render_template_xsl('datatable_jquery', $data);
}
-
- public function multi_upload()
- {
- phpgwapi_jquery::init_multi_upload_file();
- $id = phpgw::get_var('id', 'int');
-
- $GLOBALS['phpgw_info']['flags']['noframework'] = true;
- $GLOBALS['phpgw_info']['flags']['nofooter'] = true;
-
- $multi_upload_action =
$GLOBALS['phpgw']->link('/index.php', array('menuaction' =>
'property.uitts.handle_files', 'id' => $id));
-
- $data = array
- (
- 'multi_upload_action' => $multi_upload_action
- );
-
- $GLOBALS['phpgw']->xslttpl->add_file(array('files',
'multi_upload_file'));
- $GLOBALS['phpgw']->xslttpl->set_var('phpgw',
array('multi_upload' => $data));
- }
function add()
{
@@ -3051,10 +3052,10 @@
'pref_send_mail' =>
isset($GLOBALS['phpgw_info']['user']['preferences']['property']['tts_user_mailnotification'])
?
$GLOBALS['phpgw_info']['user']['preferences']['property']['tts_user_mailnotification']
: '',
'fileupload' =>
isset($this->bo->config->config_data['fmttsfileupload']) ?
$this->bo->config->config_data['fmttsfileupload'] : '',
'multiple_uploader' => true,
- 'fileuploader_action' =>
"{menuaction:'property.fileuploader.add',"
+ /*'fileuploader_action' =>
"{menuaction:'property.fileuploader.add',"
. "upload_target:'property.botts.addfiles',"
- . "id:'{$id}'}",
- 'multi_upload_parans' =>
"{menuaction:'property.uitts.multi_upload', id:'{$id}'}",
+ . "id:'{$id}'}",*/
+ 'multi_upload_parans' =>
"{menuaction:'property.uitts.build_multi_upload_file', id:'{$id}'}",
'link_view_file' =>
$GLOBALS['phpgw']->link('/index.php', $link_file_data),
'link_to_files' =>
isset($this->bo->config->config_data['files_url']) ?
$this->bo->config->config_data['files_url'] : '',
'files' => isset($ticket['files']) ?
$ticket['files'] : '',
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [15868],
nelson . guerra <=