backend/protected/modules/product/modules/import/components/abstracts/AbstractImportWriter.php 1 location
|
@@ 49-62 (lines=14) @@
|
| 46 |
|
|
| 47 |
|
abstract public function showStatistics();
|
| 48 |
|
|
| 49 |
|
public function beginTransaction()
|
| 50 |
|
{
|
| 51 |
|
if( Yii::app()->db->getCurrentTransaction() && is_null($this->useCurrentTransaction) )
|
| 52 |
|
{
|
| 53 |
|
$this->useCurrentTransaction = false;
|
| 54 |
|
return;
|
| 55 |
|
}
|
| 56 |
|
|
| 57 |
|
if( is_null($this->useCurrentTransaction) )
|
| 58 |
|
{
|
| 59 |
|
Yii::app()->db->beginTransaction();
|
| 60 |
|
$this->useCurrentTransaction = true;
|
| 61 |
|
}
|
| 62 |
|
}
|
| 63 |
|
|
| 64 |
|
public function commitTransaction()
|
| 65 |
|
{
|
protected/commands/components/AbstractImportCommand.php 1 location
|
@@ 29-42 (lines=14) @@
|
| 26 |
|
);
|
| 27 |
|
}
|
| 28 |
|
|
| 29 |
|
public function beginTransaction()
|
| 30 |
|
{
|
| 31 |
|
if( Yii::app()->db->getCurrentTransaction() && is_null($this->useCurrentTransaction) )
|
| 32 |
|
{
|
| 33 |
|
$this->useCurrentTransaction = false;
|
| 34 |
|
return;
|
| 35 |
|
}
|
| 36 |
|
|
| 37 |
|
if( is_null($this->useCurrentTransaction) )
|
| 38 |
|
{
|
| 39 |
|
Yii::app()->db->beginTransaction();
|
| 40 |
|
$this->useCurrentTransaction = true;
|
| 41 |
|
}
|
| 42 |
|
}
|
| 43 |
|
|
| 44 |
|
public function commitTransaction()
|
| 45 |
|
{
|
protected/share/behaviors/CurrentTransactionBehavior.php 1 location
|
@@ 12-25 (lines=14) @@
|
| 9 |
|
{
|
| 10 |
|
protected $useCurrentTransaction;
|
| 11 |
|
|
| 12 |
|
public function beginTransaction()
|
| 13 |
|
{
|
| 14 |
|
if( Yii::app()->db->getCurrentTransaction() && is_null($this->useCurrentTransaction) )
|
| 15 |
|
{
|
| 16 |
|
$this->useCurrentTransaction = false;
|
| 17 |
|
return;
|
| 18 |
|
}
|
| 19 |
|
|
| 20 |
|
if( is_null($this->useCurrentTransaction) )
|
| 21 |
|
{
|
| 22 |
|
Yii::app()->db->beginTransaction();
|
| 23 |
|
$this->useCurrentTransaction = true;
|
| 24 |
|
}
|
| 25 |
|
}
|
| 26 |
|
|
| 27 |
|
public function commitTransaction()
|
| 28 |
|
{
|