@@ -37,7 +37,7 @@ abstract class Product extends AbstractEntity implements SortableInterface, Prod | |||
protected $updatedBy; | |||
/** | |||
* @ORM\ManyToOne(targetEntity="Lc\ShopBundle\Context\ProductFamilyInterface", inversedBy="products") | |||
* @ORM\ManyToOne(targetEntity="Lc\ShopBundle\Context\ProductFamilyInterface", inversedBy="products", cascade={"persist"}) | |||
* @ORM\JoinColumn(nullable=false) | |||
*/ | |||
protected $productFamily; |
@@ -175,11 +175,6 @@ table th.filtered { | |||
position: relative; | |||
} | |||
/* line 66, ../../sass/backend/custom.scss */ | |||
.table-filters-line th input { | |||
width: 350px; | |||
} | |||
/* line 67, ../../sass/backend/custom.scss */ | |||
#list_filter_id { | |||
width: 60px; |
@@ -63,7 +63,7 @@ table th.filtered{border-top:3px solid var(--primary);} | |||
.lc-table-list thead a{color: #212529} | |||
.table-filters-line th {font-weight: 400; position: relative;} | |||
.table-filters-line th input{width: 350px;} | |||
.table-filters-line th input{} | |||
#list_filter_id{width: 60px;} | |||
.lc-table-list .date-range{width: 130px;} | |||
@@ -28,6 +28,7 @@ class MerchantUtils | |||
$merchant = isset($params['merchant']) ? $params['merchant'] : null ; | |||
$active = isset($params['active']) ? $params['active'] : true ; | |||
$flush = isset($params['flush']) ? $params['flush'] : true ; | |||
$persist = isset($params['persist']) ? $params['persist'] : true ; | |||
$userMerchant = $userMerchantRepository->findOneBy([ | |||
'user' => $user, | |||
@@ -51,7 +52,9 @@ class MerchantUtils | |||
$userMerchant->setCredit($params['credit']) ; | |||
} | |||
$this->em->persist($userMerchant); | |||
if($persist) { | |||
$this->em->persist($userMerchant); | |||
} | |||
if($flush) { | |||
$this->em->flush() ; |