1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-13 00:24:15 +02:00

Admin plugin #3 General Updates

This commit is contained in:
Awilum
2018-04-03 16:34:29 +03:00
parent bf19fd3bcc
commit 40fed19ade
4 changed files with 37 additions and 6 deletions

View File

@@ -44,7 +44,7 @@ class Admin {
* @var bool
* @access protected
*/
protected static $isLoggedIn = true;
protected static $isLoggedIn = false;
/**
* Protected clone method to enforce singleton behavior.
@@ -109,6 +109,10 @@ class Admin {
protected static function getAuthPage()
{
if (Request::post('login_submit')) {
}
include 'views/login.php';
}

View File

@@ -1,2 +1,4 @@
sitemap: "Sitemap"
sitemap_description: "Sitemap plugin provide automatically generated XML sitemap for Flextype."
admin: "Admin"
admin_username: "Username"
admin_password: "Password"
admin_login: "Login"

View File

@@ -1,2 +1 @@
sitemap: "Sitemap"
sitemap_description: "Sitemap plugin provide automatically generated XML sitemap for Flextype."
admin: "Admin"

View File

@@ -1 +1,27 @@
Login page
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="description" content="">
<meta name="author" content="">
<title><?php echo Flextype\I18n::find('admin_login', 'admin', Flextype\Config::get('site.locale')); ?></title>
<!-- Bootstrap core CSS -->
<link href="<?php echo Url::getBase(); ?>/site/plugins/admin/node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
<!-- Custom styles for this template -->
<link href="<?php echo Url::getBase(); ?>/site/plugins/admin/css/auth.css" rel="stylesheet">
</head>
<body class="text-center">
<form class="form-signin">
<label for="inputUsername" class="sr-only"><?php echo Flextype\I18n::find('admin_username', 'admin', Flextype\Config::get('site.locale')); ?></label>
<input type="input" id="inputUsername" class="form-control" placeholder="<?php echo Flextype\I18n::find('admin_username', 'admin', Flextype\Config::get('site.locale')); ?>" required autofocus>
<label for="inputPassword" class="sr-only"><?php echo Flextype\I18n::find('admin_password', 'admin', Flextype\Config::get('site.locale')); ?></label>
<input type="password" id="inputPassword" class="form-control" placeholder="<?php echo Flextype\I18n::find('admin_password', 'admin', Flextype\Config::get('site.locale')); ?>" required>
<button class="btn btn-lg btn-dark btn-block" name="login_submit" type="submit"><?php echo Flextype\I18n::find('admin_login', 'admin', Flextype\Config::get('site.locale')); ?></button>
</form>
</body>
</html>