Version 5.0.0 beta 7
This commit is contained in:
1 parent
fa2a720105
commit
54d5dcd0a0
156 files changed
+4337
-2995
No files matched your search
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<javascript app="downloads">
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/downloads" javascript_name="ips.downloads.browse.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000200">/**
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/downloads" javascript_name="ips.downloads.browse.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000200">/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -59,7 +59,7 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));</file>
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/pending" javascript_name="ips.pending.buttons.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000250">/**
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/pending" javascript_name="ips.pending.buttons.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000250">/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -87,7 +87,7 @@
|
||||
|
||||
});
|
||||
}(jQuery, _));</file>
|
||||
<file javascript_app="downloads" javascript_location="admin" javascript_path="controllers/settings" javascript_name="ips.settings.settings.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000050">/**
|
||||
<file javascript_app="downloads" javascript_location="admin" javascript_path="controllers/settings" javascript_name="ips.settings.settings.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000050">/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -140,7 +140,7 @@
|
||||
|
||||
});
|
||||
}(jQuery, _));</file>
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.linkedScreenshots.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000100">/**
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.linkedScreenshots.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000100">/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -212,7 +212,7 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));</file>
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.main.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000100"><![CDATA[/**
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.main.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000100"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -657,7 +657,7 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.changeLog.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000150"><![CDATA[/**
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.changeLog.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000150"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -779,7 +779,7 @@
|
||||
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.download.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000150">/**
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.download.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000150">/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -907,7 +907,7 @@
|
||||
|
||||
});
|
||||
}(jQuery, _));</file>
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.subscribe.js" javascript_type="controller" javascript_version="5000032" javascript_position="1000150">/**
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.subscribe.js" javascript_type="controller" javascript_version="5000034" javascript_position="1000150">/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
@@ -970,7 +970,7 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));</file>
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="templates" javascript_name="ips.templates.submit.js" javascript_type="template" javascript_version="5000032" javascript_position="1000050"><![CDATA[/* VIEW TEMPLATES */
|
||||
<file javascript_app="downloads" javascript_location="front" javascript_path="templates" javascript_name="ips.templates.submit.js" javascript_type="template" javascript_version="5000034" javascript_position="1000050"><![CDATA[/* VIEW TEMPLATES */
|
||||
ips.templates.set('downloads.submit.screenshot', " \
|
||||
<div class='ipsUploader__row ipsUploader__row--image ipsAttach {{#done}}ipsAttach_done{{/done}}' id='{{id}}' data-role='file' data-fileid='{{id}}' data-filesize='{{sizeRaw}}' data-fullsizeurl='{{imagesrc}}' data-thumbnailurl='{{thumbnail}}' data-fileType='image'>\
|
||||
<div class='ipsUploader__rowPreview' data-role='preview'>\
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<language>
|
||||
<app key="downloads" version="5000032">
|
||||
<app key="downloads" version="5000034">
|
||||
<word key="__app_downloads" js="0">Downloads</word>
|
||||
<word key="frontnavigation_downloads" js="0">Downloads</word>
|
||||
<word key="__indefart_downloads_file_comment" js="0">a comment on a file</word>
|
||||
|
||||
@@ -261,7 +261,7 @@
|
||||
<a href='{$file->url( "getPrefComment" )}' class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$file->name}</span></a>
|
||||
<figure class='ipsData__image'>
|
||||
{{if $file->primary_screenshot_thumb}}
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="core_Attachment"}' alt='' loading='lazy'>
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="downloads_Screenshots"}' alt='' loading='lazy'>
|
||||
{{else}}
|
||||
<i></i>
|
||||
{{endif}}
|
||||
@@ -347,8 +347,8 @@
|
||||
<input type='checkbox' data-role='moderation' name="moderate[{$file->id}]" data-actions="{expression="implode( ' ', $table->multimodActions( $file ) )"}" data-state='{{if $file->tableStates()}}{$file->tableStates()}{{endif}}' class="ipsInput ipsInput--toggle">
|
||||
</div>
|
||||
{{endif}}
|
||||
{template="thumbImage" group="global" app="core" params="$file->primary_screenshot_thumb, $file->name, 'medium', '', 'view_this', $file->url( 'getPrefComment' ), 'core_Attachment', '', true"}
|
||||
<h4 class='ipsData__title ipsType_sectionHead'>
|
||||
{template="thumbImage" group="global" app="core" params="$file->primary_screenshot_thumb, $file->name, 'medium', '', 'view_this', $file->url( 'getPrefComment' ), 'downloads_Screenshots', '', true"}
|
||||
<h4 class='ipsData__title'>
|
||||
{{if $file->unread()}}
|
||||
<span class='ipsIndicator' data-ipsTooltip title='{{if $file->unread() === -1}}{lang="new"}{{else}}{lang="updated"}{{endif}}'></span>
|
||||
{{endif}}
|
||||
@@ -356,10 +356,10 @@
|
||||
{{foreach $file->badges() as $badge}}{$badge|raw}{{endforeach}}
|
||||
|
||||
{{if $file->prefix()}}
|
||||
<span>{template="prefix" group="global" app="core" params="$file->prefix( TRUE ), $file->prefix()"}</span>
|
||||
{template="prefix" group="global" app="core" params="$file->prefix( TRUE ), $file->prefix()"}
|
||||
{{endif}}
|
||||
|
||||
<span class=''><a href='{$file->url( "getPrefComment" )}' title='{lang="view_this_file" sprintf="$file->name"} {{if $file->canEdit()}}{lang="click_hold_edit"}{{endif}}' {{if $file->canEdit()}}data-role="editableTitle"{{endif}}>{$file->name}</a></span>
|
||||
<a href='{$file->url( "getPrefComment" )}' title='{lang="view_this_file" sprintf="$file->name"} {{if $file->canEdit()}}{lang="click_hold_edit"}{{endif}}' {{if $file->canEdit()}}data-role="editableTitle"{{endif}}>{$file->name}</a>
|
||||
</h4>
|
||||
<p class='i-color_soft i-link-color_inherit'>
|
||||
{lang="byline_nodate" htmlsprintf="$file->author()->link( NULL, NULL, $file->isAnonymous() )"}
|
||||
@@ -373,7 +373,7 @@
|
||||
|
||||
<!-- Rating -->
|
||||
{{if $file->container()->bitoptions['reviews']}}
|
||||
{template="rating" group="global" location="front" app="core" params="'large', $file->averageReviewRating(), \IPS\Settings::i()->reviews_rating_out_of, $file->memberReviewRating()"} <span class='i-color_soft'>({lang="num_reviews" pluralize="$file->reviews"})</span>
|
||||
{template="rating" group="global" location="front" app="core" params="'large', $file->averageReviewRating(), \IPS\Settings::i()->reviews_rating_out_of, $file->memberReviewRating()"} <span class='i-color_soft'>({lang="num_reviews" pluralize="$file->reviews"})</span>
|
||||
{{endif}}
|
||||
|
||||
<!-- Comments -->
|
||||
@@ -391,15 +391,15 @@
|
||||
<!-- Price -->
|
||||
{{if \IPS\Application::appIsEnabled( 'nexus' ) and settings.idm_nexus_on}}
|
||||
<p class='i-font-size_2 i-text-align_center i-margin-top_2'>
|
||||
<span class='cFilePrice'>
|
||||
{{if $file->isPaid()}}
|
||||
{{if $price = $file->price()}}
|
||||
{$price|raw}
|
||||
{{endif}}
|
||||
{{else}}
|
||||
{lang="file_free"}
|
||||
{{endif}}
|
||||
</span>
|
||||
<span class='cFilePrice'>
|
||||
{{if $file->isPaid()}}
|
||||
{{if $price = $file->price()}}
|
||||
{$price|raw}
|
||||
{{endif}}
|
||||
{{else}}
|
||||
{lang="file_free"}
|
||||
{{endif}}
|
||||
</span>
|
||||
</p>
|
||||
<!-- Purchase Count -->
|
||||
<p>
|
||||
@@ -412,7 +412,7 @@
|
||||
</p>
|
||||
<!-- Tags -->
|
||||
{{if \count( $file->tags() )}}
|
||||
{template="tags" group="global" app="core" params="$file->tags(), TRUE"}
|
||||
{template="tags" group="global" app="core" params="$file->tags(), TRUE"}
|
||||
{{endif}}
|
||||
{{endif}}
|
||||
</div>]]></template>
|
||||
@@ -523,7 +523,7 @@
|
||||
<a href='{$file->url( "getPrefComment" )}' class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$file->name}</span></a>
|
||||
<figure class='ipsData__image'>
|
||||
{{if $file->primary_screenshot_thumb}}
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="core_Attachment"}' alt='' loading='lazy'>
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="downloads_Screenshots"}' alt='' loading='lazy'>
|
||||
{{else}}
|
||||
<i></i>
|
||||
{{endif}}
|
||||
@@ -615,7 +615,7 @@
|
||||
<a href="{$file->url( 'getPrefComment' )}" class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$file->name}</span></a>
|
||||
<a href="{$file->url( 'getPrefComment' )}" class='ipsData__image'>
|
||||
{{if $file->primary_screenshot_thumb}}
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="core_Attachment"}' alt='' loading='lazy'>
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="downloads_Screenshots"}' alt='' loading='lazy'>
|
||||
{{else}}
|
||||
<i></i>
|
||||
{{endif}}
|
||||
@@ -704,7 +704,7 @@
|
||||
<a href='{$file->url( "getPrefComment" )}' class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$file->name}</span></a>
|
||||
<a href="{$file->url( 'getPrefComment' )}" class='ipsData__image'>
|
||||
{{if $file->primary_screenshot_thumb}}
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="core_Attachment"}' alt='' loading='lazy'>
|
||||
<img src='{file="$file->primary_screenshot_thumb" extension="downloads_Screenshots"}' alt='' loading='lazy'>
|
||||
{{else}}
|
||||
<i></i>
|
||||
{{endif}}
|
||||
@@ -1011,7 +1011,7 @@
|
||||
</div>
|
||||
{{else}}
|
||||
<div class='ipsData__meta'>
|
||||
{lang="byline" htmlsprintf="$row->author()->link( $row->warningRef() )"}{datetime="$row->__get( $row::$databaseColumnMap['date'] )"}
|
||||
{lang="byline_name_date" htmlsprintf="$row->author()->link( $row->warningRef() ), \IPS\DateTime::ts( $row->__get( $row::$databaseColumnMap['date'] ) )->html(TRUE)"}
|
||||
{lang="in"} <a href="{$row->container()->url()}">{$row->container()->_title}</a>
|
||||
</div>
|
||||
{{endif}}
|
||||
@@ -1136,11 +1136,11 @@
|
||||
{{endif}}
|
||||
</a>
|
||||
<div class='ipsData__main'>
|
||||
<h4 class='ipsData__title ipsType_sectionHead'>
|
||||
<h4 class='ipsData__title'>
|
||||
{{if $file->prefix()}}
|
||||
<span>{template="prefix" group="global" app="core" location="front" params="$file->prefix( TRUE ), $file->prefix()"}</span>
|
||||
{template="prefix" group="global" app="core" location="front" params="$file->prefix( TRUE ), $file->prefix()"}
|
||||
{{endif}}
|
||||
<span><a href='{$file->url()}' title='{lang="view_this_file" sprintf="$file->name"}'>{$file->name}</a></span>
|
||||
<a href='{$file->url()}' title='{lang="view_this_file" sprintf="$file->name"}'>{$file->name}</a>
|
||||
</h4>
|
||||
<p class='i-color_soft i-link-color_inherit'>
|
||||
{lang="byline_nodate" htmlsprintf="$file->author()->link()"}
|
||||
|
||||
@@ -280,5 +280,7 @@
|
||||
"5000029": "5.0.0 Beta 3",
|
||||
"5000030": "5.0.0 Beta 4",
|
||||
"5000031": "5.0.0 Beta 5",
|
||||
"5000032": "5.0.0 Beta 6"
|
||||
"5000032": "5.0.0 Beta 6",
|
||||
"5000033": "5.0.0 Beta 7",
|
||||
"5000034": "5.0.0 Beta 7"
|
||||
}
|
||||
@@ -1259,27 +1259,12 @@ class view extends Controller
|
||||
}
|
||||
catch ( Exception $e ) { }
|
||||
}
|
||||
|
||||
/**
|
||||
* We only need to generate a new thumbnail if we are using watermarking.
|
||||
* If we are not, then we can simply use the previous thumbnail, if this existed previously, rather than generating a new one every time we upload a new version, which is unnecessary extra processing as well as disk usage.
|
||||
* If we are, then it is impossible to know if the watermark has since changed, so we need to go ahead and do it anyway.
|
||||
*/
|
||||
$existing = NULL;
|
||||
if ( $watermarked !== TRUE )
|
||||
{
|
||||
try
|
||||
{
|
||||
$existing = Db::i()->select( '*', 'downloads_files_records', array( "record_location=? AND record_file_id=?", (string) $file, $this->file->id ), NULL, NULL, NULL, NULL, Db::SELECT_FROM_WRITE_SERVER )->first();
|
||||
}
|
||||
catch( UnderflowException $e ) {}
|
||||
}
|
||||
|
||||
|
||||
Db::i()->insert( 'downloads_files_records', array(
|
||||
'record_file_id' => $this->file->id,
|
||||
'record_type' => 'ssupload',
|
||||
'record_location' => (string) $file,
|
||||
'record_thumb' => ( $watermarked OR !$existing ) ? (string) $file->thumbnail( 'downloads_Screenshots' ) : $existing['record_thumb'],
|
||||
'record_thumb' => (string) $file->thumbnail( 'downloads_Screenshots' ),
|
||||
'record_realname' => $file->originalFilename,
|
||||
'record_size' => $file->filesize(),
|
||||
'record_time' => time(),
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
{
|
||||
"id": 5000033,
|
||||
"name": "5.0.0 Beta 7",
|
||||
"steps": {
|
||||
"queries": false,
|
||||
"lang": false,
|
||||
"theme": true,
|
||||
"themeeditor": true,
|
||||
"javascript": false,
|
||||
"emailTemplates": false,
|
||||
"acpSearchKeywords": false,
|
||||
"settings": false,
|
||||
"tasks": false,
|
||||
"modules": false,
|
||||
"widgets": false,
|
||||
"customOptions": false,
|
||||
"customRoutines": false
|
||||
},
|
||||
"forceMainUpgrader": false,
|
||||
"forceManualDownloadNoCiC": false,
|
||||
"forceManualDownloadCiC": false
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"html": {
|
||||
"added": [],
|
||||
"edited": [
|
||||
"front\/browse\/featuredFile",
|
||||
"front\/browse\/fileGrid",
|
||||
"front\/browse\/indexBlock",
|
||||
"front\/browse\/rows",
|
||||
"front\/browse\/tableRow",
|
||||
"front\/global\/manageFollowRow",
|
||||
"admin\/nexus\/fileInfo"
|
||||
],
|
||||
"removed": []
|
||||
},
|
||||
"css": {
|
||||
"added": [],
|
||||
"edited": [],
|
||||
"removed": []
|
||||
},
|
||||
"resources": {
|
||||
"added": [],
|
||||
"edited": [],
|
||||
"removed": []
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"categories": {
|
||||
"added": [],
|
||||
"edited": [],
|
||||
"removed": []
|
||||
},
|
||||
"settings": {
|
||||
"added": [],
|
||||
"edited": [
|
||||
"layout_downloads_categories"
|
||||
],
|
||||
"removed": []
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
{
|
||||
"id": 5000034,
|
||||
"name": "5.0.0 Beta 7",
|
||||
"steps": {
|
||||
"queries": false,
|
||||
"lang": false,
|
||||
"theme": false,
|
||||
"themeeditor": true,
|
||||
"javascript": false,
|
||||
"emailTemplates": false,
|
||||
"acpSearchKeywords": false,
|
||||
"settings": false,
|
||||
"tasks": false,
|
||||
"modules": false,
|
||||
"widgets": false,
|
||||
"customOptions": false,
|
||||
"customRoutines": false
|
||||
},
|
||||
"forceMainUpgrader": false,
|
||||
"forceManualDownloadNoCiC": false,
|
||||
"forceManualDownloadCiC": false
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"categories": {
|
||||
"added": [],
|
||||
"edited": [],
|
||||
"removed": []
|
||||
},
|
||||
"settings": {
|
||||
"added": [],
|
||||
"edited": [
|
||||
"layout_downloads_categories"
|
||||
],
|
||||
"removed": []
|
||||
}
|
||||
}
|
||||
@@ -46,6 +46,7 @@ use IPS\Db;
|
||||
use IPS\Db\Select;
|
||||
use IPS\downloads\extensions\nexus\Item\File as FileNexusItem;
|
||||
use IPS\downloads\File\PendingVersion;
|
||||
use IPS\Events\Event;
|
||||
use IPS\File as SystemFile;
|
||||
use IPS\File\Iterator;
|
||||
use IPS\Helpers\Form;
|
||||
@@ -71,6 +72,7 @@ use IPS\Node\Model;
|
||||
use IPS\Notification;
|
||||
use IPS\Output;
|
||||
use IPS\Output\Plugin\Filesize;
|
||||
use IPS\Output\UI\UiExtension;
|
||||
use IPS\Patterns\ActiveRecordIterator;
|
||||
use IPS\Request;
|
||||
use IPS\Settings;
|
||||
@@ -1505,7 +1507,7 @@ Filter
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
return $member->group['idm_view_downloads'];
|
||||
return (bool) $member->group['idm_view_downloads'];
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2417,6 +2419,13 @@ Filter
|
||||
$this->_primaryScreenshotThumb = FALSE;
|
||||
$this->syncTopic();
|
||||
}
|
||||
|
||||
/* Call UI extensions */
|
||||
$this->ui( 'formPostSave', array( $values ) );
|
||||
|
||||
/* Fire event for listeners */
|
||||
Event::fire( 'onCreateOrEdit', $this, array( $values ) );
|
||||
|
||||
Webhook::fire( 'downloads_new_version', array( $this ) );
|
||||
}
|
||||
|
||||
@@ -2782,7 +2791,11 @@ Filter
|
||||
*/
|
||||
public function newVersionFormElements( Form &$form ) : void
|
||||
{
|
||||
|
||||
/* UI Extension for new version. You can check Request::i()->do to see which form you're working with. */
|
||||
foreach( UiExtension::i()->run( $this, 'formElements', array( $this->container() ) ) as $element )
|
||||
{
|
||||
$form->add( $element );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user