forked from D3Public/oxtotp
remove warning issues
This commit is contained in:
parent
3f77b212b4
commit
337107fe52
@ -17,7 +17,6 @@ use BaconQrCode\Renderer\RendererInterface;
|
|||||||
use BaconQrCode\Writer;
|
use BaconQrCode\Writer;
|
||||||
use D3\Totp\Application\Factory\BaconQrCodeFactory;
|
use D3\Totp\Application\Factory\BaconQrCodeFactory;
|
||||||
use D3\Totp\Application\Model\Exceptions\d3totp_wrongOtpException;
|
use D3\Totp\Application\Model\Exceptions\d3totp_wrongOtpException;
|
||||||
use Doctrine\DBAL\DBALException;
|
|
||||||
use OTPHP\TOTP;
|
use OTPHP\TOTP;
|
||||||
use OxidEsales\Eshop\Application\Model\User;
|
use OxidEsales\Eshop\Application\Model\User;
|
||||||
use OxidEsales\Eshop\Core\Database\Adapter\DatabaseInterface;
|
use OxidEsales\Eshop\Core\Database\Adapter\DatabaseInterface;
|
||||||
@ -89,7 +88,7 @@ class d3totp extends BaseModel
|
|||||||
*/
|
*/
|
||||||
public function getUser()
|
public function getUser()
|
||||||
{
|
{
|
||||||
$userId = $this->userId ? $this->userId : $this->getFieldData('oxuserid');
|
$userId = $this->userId ?: $this->getFieldData('oxuserid');
|
||||||
|
|
||||||
$user = $this->d3GetUser();
|
$user = $this->d3GetUser();
|
||||||
$user->load($userId);
|
$user->load($userId);
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
[{assign var="readonly" value=""}]
|
[{assign var="readonly" value=""}]
|
||||||
[{/if}]
|
[{/if}]
|
||||||
|
|
||||||
<style type="text/css">
|
<style>
|
||||||
td.edittext {
|
td.edittext {
|
||||||
white-space: normal;
|
white-space: normal;
|
||||||
}
|
}
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
[{assign var="userid" value=$user->getId()}]
|
[{assign var="userid" value=$user->getId()}]
|
||||||
[{$totp->loadByUserId($userid)}]
|
[{$totp->loadByUserId($userid)}]
|
||||||
|
|
||||||
<style type="text/css">
|
<style>
|
||||||
.registerNew {
|
.registerNew {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
@ -38,18 +38,16 @@ use OxidEsales\Eshop\Application\Model as OxidModel;
|
|||||||
$sMetadataVersion = '2.0';
|
$sMetadataVersion = '2.0';
|
||||||
|
|
||||||
$sModuleId = 'd3totp';
|
$sModuleId = 'd3totp';
|
||||||
|
$logo = '<img src="https://logos.oxidmodule.com/d3logo.svg" alt="(D3)" style="height:1em;width:1em">';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Module information
|
* Module information
|
||||||
*/
|
*/
|
||||||
$aModule = [
|
$aModule = [
|
||||||
'id' => $sModuleId,
|
'id' => $sModuleId,
|
||||||
'title' => [
|
'title' => [
|
||||||
'de' =>
|
'de' => $logo . 'Zwei-Faktor-Authentisierung',
|
||||||
'<svg style="height:1em;width:1em"><image xlink:href="https://logos.oxidmodule.com/d3logo.svg" style="height:1em;width:1em" /></svg> '.
|
'en' => $logo . 'two-factor authentication',
|
||||||
'Zwei-Faktor-Authentisierung',
|
|
||||||
'en' =>
|
|
||||||
'<svg style="height:1em;width:1em"><image xlink:href="https://logos.oxidmodule.com/d3logo.svg" style="height:1em;width:1em" /></svg> '.
|
|
||||||
'two-factor authentication',
|
|
||||||
],
|
],
|
||||||
'description' => [
|
'description' => [
|
||||||
'de' => 'Zwei-Faktor-Authentisierung (TOTP) für OXID eSales Shop',
|
'de' => 'Zwei-Faktor-Authentisierung (TOTP) für OXID eSales Shop',
|
||||||
|
@ -30,14 +30,14 @@ class d3_account_totpTest extends d3TotpUnitTestCase
|
|||||||
/**
|
/**
|
||||||
* setup basic requirements
|
* setup basic requirements
|
||||||
*/
|
*/
|
||||||
public function setUp()
|
public function setUp(): void
|
||||||
{
|
{
|
||||||
parent::setUp();
|
parent::setUp();
|
||||||
|
|
||||||
$this->_oController = oxNew(d3_account_totp::class);
|
$this->_oController = oxNew(d3_account_totp::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function tearDown()
|
public function tearDown(): void
|
||||||
{
|
{
|
||||||
parent::tearDown();
|
parent::tearDown();
|
||||||
|
|
||||||
|
@ -33,14 +33,14 @@ class d3_totp_LoginControllerTest extends d3TotpUnitTestCase
|
|||||||
/**
|
/**
|
||||||
* setup basic requirements
|
* setup basic requirements
|
||||||
*/
|
*/
|
||||||
public function setUp()
|
public function setUp(): void
|
||||||
{
|
{
|
||||||
parent::setUp();
|
parent::setUp();
|
||||||
|
|
||||||
$this->_oController = oxNew(d3_totp_LoginController::class);
|
$this->_oController = oxNew(d3_totp_LoginController::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function tearDown()
|
public function tearDown(): void
|
||||||
{
|
{
|
||||||
parent::tearDown();
|
parent::tearDown();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user