Beispiel #1
0
 protected function hookAddColumnCustdataType()
 {
     if ($this->connection->table_exists('memdefaults')) {
         $dataR = $this->connection->query('SELECT memtype, cd_type FROM memdefaults');
         $tempModel = new MemtypeModel($this->connection);
         while ($dataW = $this->connection->fetch_row($dataR)) {
             $tempModel->reset();
             $tempModel->memtype($dataW['memtype']);
             if ($tempModel->load()) {
                 $tempModel->custdataType($dataW['cd_type']);
                 $tempModel->save();
             }
         }
     }
 }