mirror of
https://github.com/Karaka-Management/oms-Draw.git
synced 2026-02-03 08:48:40 +00:00
make id public, organigram impl. media password/encryption, settings bug fix, Money->FloatInt change, ...
This commit is contained in:
parent
1b14ec36f2
commit
26e056d068
|
|
@ -32,7 +32,7 @@ class DrawImage implements \JsonSerializable
|
|||
* @var int
|
||||
* @since 1.0.0
|
||||
*/
|
||||
protected int $id = 0;
|
||||
public int $id = 0;
|
||||
|
||||
/**
|
||||
* Media object.
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ echo $this->getData('nav')->render(); ?>
|
|||
<td><?= $this->getHtml('Created'); ?>
|
||||
<tbody>
|
||||
<?php $count = 0; foreach ($images as $key => $value) : ++$count;
|
||||
$url = \phpOMS\Uri\UriFactory::build('draw/single?{?}&id=' . $value->getId()); ?>
|
||||
$url = \phpOMS\Uri\UriFactory::build('draw/single?{?}&id=' . $value->id); ?>
|
||||
<tr>
|
||||
<td data-label="<?= $this->getHtml('Name'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->media->name); ?></a>
|
||||
<td data-label="<?= $this->getHtml('Creator'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->media->createdBy->login); ?></a>
|
||||
|
|
|
|||
|
|
@ -108,7 +108,7 @@ final class ApiControllerTest extends \PHPUnit\Framework\TestCase
|
|||
$this->module->apiDrawCreate($request, $response);
|
||||
|
||||
self::assertEquals('Draw Title', $response->get('')['response']->media->name);
|
||||
self::assertGreaterThan(0, $response->get('')['response']->getId());
|
||||
self::assertGreaterThan(0, $response->get('')['response']->id);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ final class DrawImageTest extends \PHPUnit\Framework\TestCase
|
|||
*/
|
||||
public function testDefault() : void
|
||||
{
|
||||
self::assertEquals(0, $this->img->getId());
|
||||
self::assertEquals(0, $this->img->id);
|
||||
self::assertNull($this->img->media);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -37,6 +37,6 @@ final class NullDrawImageTest extends \PHPUnit\Framework\TestCase
|
|||
public function testId() : void
|
||||
{
|
||||
$null = new NullDrawImage(2);
|
||||
self::assertEquals(2, $null->getId());
|
||||
self::assertEquals(2, $null->id);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user