- Bootstrapping import menu

This commit is contained in:
MrCasual
2015-10-21 15:15:57 -04:00
parent 0199e2c7e1
commit 0a771acb02
3 changed files with 17 additions and 0 deletions

View File

View File

@@ -76,6 +76,14 @@ class Menu {
'mailpoet-settings', 'mailpoet-settings',
array($this, 'settings') array($this, 'settings')
); );
add_submenu_page(
'mailpoet',
__('Import'),
__('Import'),
'manage_options',
'mailpoet-import',
array($this, 'import')
);
// add_submenu_page( // add_submenu_page(
// 'mailpoet', // 'mailpoet',
// __('Newsletter editor'), // __('Newsletter editor'),
@@ -204,6 +212,10 @@ class Menu {
echo $this->renderer->render('newsletter/form.html', $data); echo $this->renderer->render('newsletter/form.html', $data);
} }
function import() {
echo $this->renderer->render('import.html');
}
function formEditor() { function formEditor() {
$id = (isset($_GET['id']) ? (int)$_GET['id'] : 0); $id = (isset($_GET['id']) ? (int)$_GET['id'] : 0);
$form = Form::findOne($id); $form = Form::findOne($id);

5
views/import.html Normal file
View File

@@ -0,0 +1,5 @@
<% extends 'layout.html' %>
<% block content %>
<div id="import"></div>
<% endblock %>