This repository has been archived on 2024-08-09. You can view files and clone it, but cannot push or open issues or pull requests.
joomla/bin/component_parts/view.sh

27 lines
485 B
Bash
Raw Normal View History

2023-06-01 15:20:10 +00:00
#!/bin/bash
# Check if $name is set
if [[ -z "${name}" ]]; then
echo "Error: Variable \$name is not set. Exiting (displaycontroller.sh)."
exit 1
fi
2023-06-06 08:58:54 +00:00
cat <<EOM > admin/src/View/${name^}/HtmlView.php
2023-06-01 15:20:10 +00:00
<?php
2023-06-06 08:58:54 +00:00
namespace Harvst\\Component\\${name^}\\Administrator\\View\\${name^};
2023-06-01 15:20:10 +00:00
defined('_JEXEC') or die;
use Joomla\CMS\MVC\View\HtmlView as BaseHtmlView;
class HtmlView extends BaseHtmlView {
function display(\$tpl = null) {
parent::display(\$tpl);
}
}
EOM