PRE SIGN URL EXPIRAY TIME CHANGED
This commit is contained in:
parent
73e42bdf6e
commit
d37e6c0139
@ -110,6 +110,19 @@ class AWS_S3
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getS3SingleObj($bucket_name,$folder_name,$time = '+5 minutes')
|
||||||
|
{
|
||||||
|
//echo $time;die();
|
||||||
|
$result = $this->S3->getObject([
|
||||||
|
'Bucket' => $bucket_name,
|
||||||
|
'Key' => $folder_name
|
||||||
|
//'ResponseContentType' => 'image/png'
|
||||||
|
//'ResponseContentDisposition' => 'attachment; woodgrass1.jpg',
|
||||||
|
]);
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
// Get List of objetcs as byte(Raw file).
|
// Get List of objetcs as byte(Raw file).
|
||||||
public function getAllObjectsInaBucket($bucket_name,$folder_name)
|
public function getAllObjectsInaBucket($bucket_name,$folder_name)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -221,7 +221,7 @@ class PD_Model extends SPARQ_Model {
|
|||||||
/*
|
/*
|
||||||
*Get All PD Related Documents as signed and expired URL's from S3 Buckets
|
*Get All PD Related Documents as signed and expired URL's from S3 Buckets
|
||||||
*/
|
*/
|
||||||
public function getSignedPDDocsURL($pdid,$form_id = null,$company_id = null,$is_common_api = null,$rental_count_id = null)
|
public function getSignedPDDocsURL($pdid,$form_id = null,$company_id = null,$is_common_api = null,$rental_count_id = null,$api_client = '')
|
||||||
{
|
{
|
||||||
//echo $pdid,$form_id,$company_id;die();
|
//echo $pdid,$form_id,$company_id;die();
|
||||||
$document_lists = array();
|
$document_lists = array();
|
||||||
@ -266,7 +266,7 @@ class PD_Model extends SPARQ_Model {
|
|||||||
{
|
{
|
||||||
|
|
||||||
$profilepics3path = 'pd'.$pdid.'/'.$value['pd_document_name'];
|
$profilepics3path = 'pd'.$pdid.'/'.$value['pd_document_name'];
|
||||||
$singed_uri = $this->aws_s3->getSingleObjectInaBucketAsSignedURI($bucket_name,$profilepics3path,'+30 minutes');
|
$singed_uri = $this->aws_s3->getSingleObjectInaBucketAsSignedURI($bucket_name,$profilepics3path,'+2 day');
|
||||||
$document_lists[$key]['doc_url'] = $singed_uri;
|
$document_lists[$key]['doc_url'] = $singed_uri;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user