Updates to pages to reflect lib code changes
This commit is contained in:
@@ -7,10 +7,10 @@ $config = $main->config();
|
||||
// Grab the name of this source
|
||||
$encoded_filename = null;
|
||||
if ($req->get('submit')) {
|
||||
$encoded_filename = RippingCluster_Main::issetelse($_POST['id'], RippingCluster_Exception_InvalidParameters);
|
||||
$encoded_filename = RippingCluster_Main::issetelse($_POST['id'], 'RippingCluster_Exception_InvalidParameters');
|
||||
|
||||
// Create the jobs from the request
|
||||
$jobs = RippingCluster_Job::fromPostRequest($_POST['id'], $_POST['rip-options'], $_POST['rips']);
|
||||
$jobs = RippingCluster_Job::fromPostRequest($_POST['plugin'], $_POST['id'], $_POST['rip-options'], $_POST['rips']);
|
||||
|
||||
// Spawn the background client process to run all the jobs
|
||||
RippingCluster_Job::runAllJobs();
|
||||
@@ -22,9 +22,10 @@ if ($req->get('submit')) {
|
||||
|
||||
} else {
|
||||
$this->smarty->assign('rips_submitted', false);
|
||||
$encoded_filename = $req->get('id', RippingCluster_Exception_InvalidParameters);
|
||||
$encoded_filename = $req->get('id', 'RippingCluster_Exception_InvalidParameters');
|
||||
|
||||
$source = RippingCluster_Rips_Source::loadEncoded($encoded_filename);
|
||||
$plugin = $req->get('plugin', 'RippingCluster_Exception_InvalidParameters');
|
||||
$source = RippingCluster_Source_PluginFactory::loadEncoded($plugin, $encoded_filename);
|
||||
|
||||
$this->smarty->assign('source', $source);
|
||||
$this->smarty->assign('titles', $source->titles());
|
||||
|
||||
@@ -4,7 +4,8 @@ $main = RippingCluster_Main::instance();
|
||||
$req = $main->request();
|
||||
$config = $main->config();
|
||||
|
||||
$source = RippingCluster_Rips_Source::loadEncoded($req->get('id', RippingCluster_Exception_InvalidParameters));
|
||||
$plugin = $req->get('plugin', 'RippingCluster_Exception_InvalidParameters');
|
||||
$source = RippingCluster_Source_PluginFactory::loadEncoded($plugin, $req->get('id', 'RippingCluster_Exception_InvalidParameters'));
|
||||
|
||||
$this->smarty->assign('source', $source);
|
||||
$this->smarty->assign('titles', $source->titles());
|
||||
|
||||
@@ -3,12 +3,11 @@
|
||||
$main = RippingCluster_Main::instance();
|
||||
$config = $main->config();
|
||||
|
||||
$lister = new RippingCluster_Rips_SourceLister($config->get('rips.source_dir'));
|
||||
$sources = $lister->sources();
|
||||
$sources = RippingCluster_Source_PluginFactory::enumerateAll();
|
||||
|
||||
$sources_cached = array();
|
||||
foreach ($sources as $source) {
|
||||
$sources_cached[$source->filename()] = RippingCluster_Rips_Source::isCached($source->filename());
|
||||
$sources_cached[$source->filename()] = RippingCluster_Source::isCached($source->filename());
|
||||
}
|
||||
|
||||
$this->smarty->assign('sources', $sources);
|
||||
|
||||
@@ -8,9 +8,10 @@
|
||||
to see a list of running jobs, or the <a href="{$base_uri}logs/" title="View logs">logs</a> page for more detailed progress information.
|
||||
</p>
|
||||
{else}
|
||||
<h3>{$source->filename()|htmlspecialchars}</h3>
|
||||
<h3>{$source->filename()|escape:"html"}</h3>
|
||||
|
||||
<form name="setup-rips" id="setup-rips" action="{$base_uri}rips/setup-rip/submit/" method="post">
|
||||
<input type="hidden" name="plugin" value="{$source->plugin()|escape:"html"}" />
|
||||
<fieldset>
|
||||
<legend>Configure global rip options</legend>
|
||||
|
||||
|
||||
@@ -10,11 +10,12 @@
|
||||
</p>
|
||||
<ul>
|
||||
{foreach from=$sources item=source}
|
||||
{assign var='source_plugin' value=$source->plugin()}
|
||||
{assign var='source_filename' value=$source->filename()}
|
||||
{assign var='source_filename_encoded' value=$source->filenameEncoded()}
|
||||
<li>
|
||||
[ <a href="{$base_uri}rips/source-details/id/{$source_filename_encoded}" title="Browse source details">Browse</a> |
|
||||
<a href="{$base_uri}rips/setup-rip/id/{$source_filename_encoded}" title="Rip this source">Rip</a> ]
|
||||
[ <a href="{$base_uri}rips/source-details/plugin/{$source_plugin}/id/{$source_filename_encoded}" title="Browse source details">Browse</a> |
|
||||
<a href="{$base_uri}rips/setup-rip/plugin/{$source_plugin}/id/{$source_filename_encoded}" title="Rip this source">Rip</a> ]
|
||||
{$source_filename|escape:'html'}{if $sources_cached.$source_filename} (cached){/if}
|
||||
</li>
|
||||
{/foreach}
|
||||
|
||||
Reference in New Issue
Block a user