@@ -87,11 +87,6 @@ abstract class Address extends AbstractEntity | |||
*/ | |||
protected $comment; | |||
/** | |||
* @ORM\OneToMany(targetEntity="Lc\ShopBundle\Context\OrderShopInterface", mappedBy="invoiceAddress") | |||
*/ | |||
protected $orders; | |||
/** | |||
* @ORM\OneToOne(targetEntity="Lc\ShopBundle\Context\PointSaleInterface", mappedBy="address", cascade={"persist", "remove"}) | |||
*/ | |||
@@ -287,36 +282,6 @@ abstract class Address extends AbstractEntity | |||
return $this; | |||
} | |||
/** | |||
* @return Collection|ShopOrder[] | |||
*/ | |||
public function getOrders(): Collection | |||
{ | |||
return $this->orders; | |||
} | |||
public function addOrder(OrderShop $order): self | |||
{ | |||
if (!$this->orders->contains($order)) { | |||
$this->orders[] = $order; | |||
$order->setInvoiceAddress($this); | |||
} | |||
return $this; | |||
} | |||
public function removeOrder(OrderShop $order): self | |||
{ | |||
if ($this->orders->contains($order)) { | |||
$this->orders->removeElement($order); | |||
// set the owning side to null (unless already changed) | |||
if ($order->getInvoiceAddress() === $this) { | |||
$order->setInvoiceAddress(null); | |||
} | |||
} | |||
return $this; | |||
} | |||
public function getPointSale(): ?PointSale | |||
{ |
@@ -7,7 +7,7 @@ use Doctrine\ORM\Mapping as ORM; | |||
/** | |||
* @ORM\MappedSuperclass() | |||
*/ | |||
abstract class Product extends AbstractEntity | |||
abstract class Product extends AbstractDocumentEntity | |||
{ | |||
/** | |||
* @ORM\ManyToOne(targetEntity="Lc\ShopBundle\Context\ProductFamilyInterface", inversedBy="products") |
@@ -0,0 +1,11 @@ | |||
window.onload = function () { | |||
/*if (window.CKEDITOR){ | |||
var path = '/ckfinder/connector'; | |||
CKFinder.config( { connectorPath: (window.location.pathname.indexOf("app_dev.php") == -1) ? path : '/app_dev.php'+path} ); | |||
for (var ckInstance in CKEDITOR.instances){ | |||
CKFinder.setupCKEditor(CKEDITOR.instances[ckInstance]); | |||
} | |||
}*/ | |||
alert('ncihce'); | |||
} | |||
CKFinder.config( { connectorPath: '/ckfinder/connector' } ); |
@@ -0,0 +1,4 @@ | |||
{% block _product_ck_finder_widget %} | |||
{# ... #} | |||
<a href="...">More information</a> | |||
{% endblock %} |
@@ -0,0 +1,13 @@ | |||
<?php | |||
namespace Lc\ShopBundle\Services; | |||
use CKSource\Bundle\CKFinderBundle\Authentication\Authentication as AuthenticationBase; | |||
class CustomCKFinderAuth extends AuthenticationBase | |||
{ | |||
public function authenticate() | |||
{ | |||
return true; | |||
} | |||
} |