Completed
Branch master (fa5654)
by dima
03:39
created
app/Price/Models/Selfprice/Base/Selfprice.php 4 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -289,7 +289,7 @@  discard block
 block discarded – undo
289 289
      *
290 290
      * @param  string  $msg
291 291
      * @param  int     $priority One of the Propel::LOG_* logging levels
292
-     * @return boolean
292
+     * @return boolean|null
293 293
      */
294 294
     protected function log($msg, $priority = Propel::LOG_INFO)
295 295
     {
@@ -1132,7 +1132,7 @@  discard block
 block discarded – undo
1132 1132
      * TableMap::TYPE_COLNAME, TableMap::TYPE_FIELDNAME, TableMap::TYPE_NUM.
1133 1133
      * The default key type is the column's TableMap::TYPE_PHPNAME.
1134 1134
      *
1135
-     * @param mixed $parser A AbstractParser instance,
1135
+     * @param string $parser A AbstractParser instance,
1136 1136
      *                       or a format name ('XML', 'YAML', 'JSON', 'CSV')
1137 1137
      * @param string $data The source data to import from
1138 1138
      * @param string $keyType The type of keys the array uses.
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,6 @@
 block discarded – undo
11 11
 use Propel\Runtime\ActiveQuery\Criteria;
12 12
 use Propel\Runtime\ActiveQuery\ModelCriteria;
13 13
 use Propel\Runtime\ActiveRecord\ActiveRecordInterface;
14
-use Propel\Runtime\Collection\Collection;
15 14
 use Propel\Runtime\Connection\ConnectionInterface;
16 15
 use Propel\Runtime\Exception\BadMethodCallException;
17 16
 use Propel\Runtime\Exception\LogicException;
Please login to merge, or discard this patch.
Indentation   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -694,7 +694,7 @@  discard block
 block discarded – undo
694 694
             throw new PropelException('Cannot insert a value for auto-increment primary key (' . SelfpriceTableMap::COL_ID . ')');
695 695
         }
696 696
 
697
-         // check the columns in natural order for more readable SQL queries
697
+            // check the columns in natural order for more readable SQL queries
698 698
         if ($this->isColumnModified(SelfpriceTableMap::COL_ID)) {
699 699
             $modifiedColumns[':p' . $index++]  = 'id';
700 700
         }
@@ -936,25 +936,25 @@  discard block
 block discarded – undo
936 936
         }
937 937
     }
938 938
 
939
-     /**
940
-     * Populate the current object from a string, using a given parser format
941
-     * <code>
942
-     * $book = new Book();
943
-     * $book->importFrom('JSON', '{"Id":9012,"Title":"Don Juan","ISBN":"0140422161","Price":12.99,"PublisherId":1234,"AuthorId":5678}');
944
-     * </code>
945
-     *
946
-     * You can specify the key type of the array by additionally passing one
947
-     * of the class type constants TableMap::TYPE_PHPNAME, TableMap::TYPE_CAMELNAME,
948
-     * TableMap::TYPE_COLNAME, TableMap::TYPE_FIELDNAME, TableMap::TYPE_NUM.
949
-     * The default key type is the column's TableMap::TYPE_PHPNAME.
950
-     *
951
-     * @param mixed $parser A AbstractParser instance,
952
-     *                       or a format name ('XML', 'YAML', 'JSON', 'CSV')
953
-     * @param string $data The source data to import from
954
-     * @param string $keyType The type of keys the array uses.
955
-     *
956
-     * @return $this|\Price\Models\Selfprice\Selfprice The current object, for fluid interface
957
-     */
939
+        /**
940
+         * Populate the current object from a string, using a given parser format
941
+         * <code>
942
+         * $book = new Book();
943
+         * $book->importFrom('JSON', '{"Id":9012,"Title":"Don Juan","ISBN":"0140422161","Price":12.99,"PublisherId":1234,"AuthorId":5678}');
944
+         * </code>
945
+         *
946
+         * You can specify the key type of the array by additionally passing one
947
+         * of the class type constants TableMap::TYPE_PHPNAME, TableMap::TYPE_CAMELNAME,
948
+         * TableMap::TYPE_COLNAME, TableMap::TYPE_FIELDNAME, TableMap::TYPE_NUM.
949
+         * The default key type is the column's TableMap::TYPE_PHPNAME.
950
+         *
951
+         * @param mixed $parser A AbstractParser instance,
952
+         *                       or a format name ('XML', 'YAML', 'JSON', 'CSV')
953
+         * @param string $data The source data to import from
954
+         * @param string $keyType The type of keys the array uses.
955
+         *
956
+         * @return $this|\Price\Models\Selfprice\Selfprice The current object, for fluid interface
957
+         */
958 958
     public function importFrom($parser, $data, $keyType = TableMap::TYPE_PHPNAME)
959 959
     {
960 960
         if (!$parser instanceof AbstractParser) {
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -711,7 +711,7 @@  discard block
 block discarded – undo
711 711
             $con = Propel::getServiceContainer()->getWriteConnection(UserTableMap::DATABASE_NAME);
712 712
         }
713 713
 
714
-        $con->transaction(function () use ($con) {
714
+        $con->transaction(function() use ($con) {
715 715
             $deleteQuery = ChildUserQuery::create()
716 716
                 ->filterByPrimaryKey($this->getPrimaryKey());
717 717
             $ret = $this->preDelete($con);
@@ -746,7 +746,7 @@  discard block
 block discarded – undo
746 746
             $con = Propel::getServiceContainer()->getWriteConnection(UserTableMap::DATABASE_NAME);
747 747
         }
748 748
 
749
-        return $con->transaction(function () use ($con) {
749
+        return $con->transaction(function() use ($con) {
750 750
             $isInsert = $this->isNew();
751 751
             $ret = $this->preSave($con);
752 752
             if ($isInsert) {
Please login to merge, or discard this patch.
app/Price/Models/Selfprice/Map/SelfpriceTableMap.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -365,8 +365,8 @@
 block discarded – undo
365 365
      * @throws PropelException Any exceptions caught during processing will be
366 366
      *                         rethrown wrapped into a PropelException.
367 367
      */
368
-     public static function doDelete($values, ConnectionInterface $con = null)
369
-     {
368
+        public static function doDelete($values, ConnectionInterface $con = null)
369
+        {
370 370
         if (null === $con) {
371 371
             $con = Propel::getServiceContainer()->getWriteConnection(UserTableMap::DATABASE_NAME);
372 372
         }
Please login to merge, or discard this patch.
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -102,12 +102,12 @@  discard block
 block discarded – undo
102 102
      * first dimension keys are the type constants
103 103
      * e.g. self::$fieldNames[self::TYPE_PHPNAME][0] = 'Id'
104 104
      */
105
-    protected static $fieldNames = array (
106
-        self::TYPE_PHPNAME       => array('Id', 'Name', 'Datecreate', 'Desc', ),
107
-        self::TYPE_CAMELNAME     => array('id', 'name', 'datecreate', 'desc', ),
108
-        self::TYPE_COLNAME       => array(SelfpriceTableMap::COL_ID, SelfpriceTableMap::COL_NAME, SelfpriceTableMap::COL_DATECREATE, SelfpriceTableMap::COL_DESC, ),
109
-        self::TYPE_FIELDNAME     => array('id', 'name', 'datecreate', 'desc', ),
110
-        self::TYPE_NUM           => array(0, 1, 2, 3, )
105
+    protected static $fieldNames = array(
106
+        self::TYPE_PHPNAME       => array('Id', 'Name', 'Datecreate', 'Desc',),
107
+        self::TYPE_CAMELNAME     => array('id', 'name', 'datecreate', 'desc',),
108
+        self::TYPE_COLNAME       => array(SelfpriceTableMap::COL_ID, SelfpriceTableMap::COL_NAME, SelfpriceTableMap::COL_DATECREATE, SelfpriceTableMap::COL_DESC,),
109
+        self::TYPE_FIELDNAME     => array('id', 'name', 'datecreate', 'desc',),
110
+        self::TYPE_NUM           => array(0, 1, 2, 3,)
111 111
     );
112 112
 
113 113
     /**
@@ -116,12 +116,12 @@  discard block
 block discarded – undo
116 116
      * first dimension keys are the type constants
117 117
      * e.g. self::$fieldKeys[self::TYPE_PHPNAME]['Id'] = 0
118 118
      */
119
-    protected static $fieldKeys = array (
120
-        self::TYPE_PHPNAME       => array('Id' => 0, 'Name' => 1, 'Datecreate' => 2, 'Desc' => 3, ),
121
-        self::TYPE_CAMELNAME     => array('id' => 0, 'name' => 1, 'datecreate' => 2, 'desc' => 3, ),
122
-        self::TYPE_COLNAME       => array(SelfpriceTableMap::COL_ID => 0, SelfpriceTableMap::COL_NAME => 1, SelfpriceTableMap::COL_DATECREATE => 2, SelfpriceTableMap::COL_DESC => 3, ),
123
-        self::TYPE_FIELDNAME     => array('id' => 0, 'name' => 1, 'datecreate' => 2, 'desc' => 3, ),
124
-        self::TYPE_NUM           => array(0, 1, 2, 3, )
119
+    protected static $fieldKeys = array(
120
+        self::TYPE_PHPNAME       => array('Id' => 0, 'Name' => 1, 'Datecreate' => 2, 'Desc' => 3,),
121
+        self::TYPE_CAMELNAME     => array('id' => 0, 'name' => 1, 'datecreate' => 2, 'desc' => 3,),
122
+        self::TYPE_COLNAME       => array(SelfpriceTableMap::COL_ID => 0, SelfpriceTableMap::COL_NAME => 1, SelfpriceTableMap::COL_DATECREATE => 2, SelfpriceTableMap::COL_DESC => 3,),
123
+        self::TYPE_FIELDNAME     => array('id' => 0, 'name' => 1, 'datecreate' => 2, 'desc' => 3,),
124
+        self::TYPE_NUM           => array(0, 1, 2, 3,)
125 125
     );
126 126
 
127 127
     /**
@@ -403,8 +403,8 @@  discard block
 block discarded – undo
403 403
             $criteria = $criteria->buildCriteria(); // build Criteria from Selfprice object
404 404
         }
405 405
 
406
-        if ($criteria->containsKey(SelfpriceTableMap::COL_ID) && $criteria->keyContainsValue(SelfpriceTableMap::COL_ID) ) {
407
-            throw new PropelException('Cannot insert a value for auto-increment primary key ('.SelfpriceTableMap::COL_ID.')');
406
+        if ($criteria->containsKey(SelfpriceTableMap::COL_ID) && $criteria->keyContainsValue(SelfpriceTableMap::COL_ID)) {
407
+            throw new PropelException('Cannot insert a value for auto-increment primary key (' . SelfpriceTableMap::COL_ID . ')');
408 408
         }
409 409
 
410 410
 
@@ -413,7 +413,7 @@  discard block
 block discarded – undo
413 413
 
414 414
         // use transaction because $criteria could contain info
415 415
         // for more than one table (I guess, conceivably)
416
-        return $con->transaction(function () use ($con, $query) {
416
+        return $con->transaction(function() use ($con, $query) {
417 417
             return $query->doInsert($con);
418 418
         });
419 419
     }
Please login to merge, or discard this patch.
app/Price/Models/Selfprice/Base/SelfpriceQuery.php 2 patches
Indentation   -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,6 @@
 block discarded – undo
49 49
  * @method     ChildUser findOneByRememberToken(string $remember_token) Return the first ChildUser filtered by the remember_token column
50 50
  * @method     ChildUser findOneByCreatedAt(string $created_at) Return the first ChildUser filtered by the created_at column
51 51
  * @method     ChildUser findOneByUpdatedAt(string $updated_at) Return the first ChildUser filtered by the updated_at column *
52
-
53 52
  * @method     ChildUser requirePk($key, ConnectionInterface $con = null) Return the ChildUser by primary key and throws \Propel\Runtime\Exception\EntityNotFoundException when not found
54 53
  * @method     ChildUser requireOne(ConnectionInterface $con = null) Return the first ChildUser matching the query and throws \Propel\Runtime\Exception\EntityNotFoundException when not found
55 54
  *
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -524,7 +524,7 @@  discard block
 block discarded – undo
524 524
 
525 525
         // use transaction because $criteria could contain info
526 526
         // for more than one table or we could emulating ON DELETE CASCADE, etc.
527
-        return $con->transaction(function () use ($con) {
527
+        return $con->transaction(function() use ($con) {
528 528
             $affectedRows = 0; // initialize var to track total num of affected rows
529 529
             $affectedRows += parent::doDeleteAll($con);
530 530
             // Because this db requires some delete cascade/set null emulation, we have to
@@ -559,7 +559,7 @@  discard block
 block discarded – undo
559 559
 
560 560
         // use transaction because $criteria could contain info
561 561
         // for more than one table or we could emulating ON DELETE CASCADE, etc.
562
-        return $con->transaction(function () use ($con, $criteria) {
562
+        return $con->transaction(function() use ($con, $criteria) {
563 563
             $affectedRows = 0; // initialize var to track total num of affected rows
564 564
 
565 565
             UserTableMap::removeInstanceFromPool($criteria);
Please login to merge, or discard this patch.
db/migrations/PropelMigration_1475647555.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
     public function getUpSQL()
39 39
     {
40 40
         return array (
41
-  'default' => '
41
+    'default' => '
42 42
 # This is a fix for InnoDB in MySQL >= 4.1.x
43 43
 # It "suspends judgement" for fkey relationships until are tables are set.
44 44
 SET FOREIGN_KEY_CHECKS = 0;
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
     public function getDownSQL()
69 69
     {
70 70
         return array (
71
-  'default' => '
71
+    'default' => '
72 72
 # This is a fix for InnoDB in MySQL >= 4.1.x
73 73
 # It "suspends judgement" for fkey relationships until are tables are set.
74 74
 SET FOREIGN_KEY_CHECKS = 0;
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
      */
38 38
     public function getUpSQL()
39 39
     {
40
-        return array (
40
+        return array(
41 41
   'default' => '
42 42
 # This is a fix for InnoDB in MySQL >= 4.1.x
43 43
 # It "suspends judgement" for fkey relationships until are tables are set.
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
      */
68 68
     public function getDownSQL()
69 69
     {
70
-        return array (
70
+        return array(
71 71
   'default' => '
72 72
 # This is a fix for InnoDB in MySQL >= 4.1.x
73 73
 # It "suspends judgement" for fkey relationships until are tables are set.
Please login to merge, or discard this patch.