Platon Technologies
neprihlásený Prihlásiť Registrácia
SlovakEnglish
open source software development oslavujeme 10 rokov vývoja otvoreného softvéru! Sobota, 24. október 2026

Rozdiely pre phpMyEdit/phpMyEdit.class.php medzi verziami 1.93 a 1.94

verzia 1.93, 2003/08/16 14:01:17 verzia 1.94, 2003/08/18 20:31:58
Riadok 19 
Riadok 19 
  * http://www.platon.sk/projects/phpMyEdit/   * http://www.platon.sk/projects/phpMyEdit/
  */   */
   
 /* $Platon: phpMyEdit/phpMyEdit.class.php,v 1.92 2003/08/16 01:41:26 nepto Exp $ */  /* $Platon: phpMyEdit/phpMyEdit.class.php,v 1.93 2003/08/16 14:01:17 nepto Exp $ */
   
 /*  This is a generic table editing program. The table and fields to be  /*  This is a generic table editing program. The table and fields to be
         edited are defined in the calling program.          edited are defined in the calling program.
Riadok 385  class phpMyEdit
Riadok 385  class phpMyEdit
                 return $values;                  return $values;
         } /* }}} */          } /* }}} */
   
         /*          function fqn($field, $dont_desc = false, $dont_cols = false) /* {{{ */
          * get the table/field name  
          */  
         function fqn($field, $use_qfx = false, $dont_desc = false, $dont_cols = false) /* {{{ */  
         {          {
                 is_numeric($field) || $field = array_search($field, $this->fds);                  is_numeric($field) || $field = array_search($field, $this->fds);
                 // use_qfx                  // if read SQL expression exists use it
                 if ($use_qfx)                  if (isset($this->fdd[$field]['sql']))
                         return 'qf'.$field;                          return $this->fdd[$field]['sql'];
                 // on copy/change always use simple key retrieving                  // on copy/change always use simple key retrieving
                 if ($this->add_operation()                  if ($this->add_operation()
                                 || $this->copy_operation()                                  || $this->copy_operation()
                                 || $this->change_operation()) {                                  || $this->change_operation()) {
                                 $ret = 'PMEtable0.'.$this->fds[$field];                                  $ret = 'PMEtable0.'.$this->fds[$field];
                 } else {                  } else {
                         if (isset($this->fdd[$field]['sql'])) {                          if ($this->fdd[$this->fds[$field]]['values']['description'] && ! $dont_desc) {
                                 $ret = $this->fdd[$field]['sql'];  
                         } elseif ($this->fdd[$this->fds[$field]]['values']['description'] && ! $dont_desc) {  
                                 $desc = &$this->fdd[$this->fds[$field]]['values']['description'];                                  $desc = &$this->fdd[$this->fds[$field]]['values']['description'];
                                 if (is_array($desc) && is_array($desc['columns'])) {                                  if (is_array($desc) && is_array($desc['columns'])) {
                                         $ret      = 'CONCAT('; // )                                          $ret      = 'CONCAT('; // )
Riadok 447  class phpMyEdit
Riadok 442  class phpMyEdit
                         }                          }
                         $fields[] = $this->fqn($k).' AS qf'.$k;                          $fields[] = $this->fqn($k).' AS qf'.$k;
                         if ($this->col_has_values($k)) {                          if ($this->col_has_values($k)) {
                                 $fields[] = $this->fqn($k, false, true, true).' AS qf'.$k.'_idx';                                  $fields[] = $this->fqn($k, true, true).' AS qf'.$k.'_idx';
                         }                          }
                         if ($this->col_has_datemask($k)) {                          if ($this->col_has_datemask($k)) {
                                 $fields[] = 'UNIX_TIMESTAMP('.$this->fqn($k).') AS qf'.$k.'_timestamp';                                  $fields[] = 'UNIX_TIMESTAMP('.$this->fqn($k).') AS qf'.$k.'_timestamp';
Riadok 619  class phpMyEdit
Riadok 614  class phpMyEdit
                                         // XXX: $dont_desc and $dont_cols hack                                          // XXX: $dont_desc and $dont_cols hack
                                         $dont_desc = isset($this->fdd[$k]['values']['description']);                                          $dont_desc = isset($this->fdd[$k]['values']['description']);
                                         $dont_cols = isset($this->fdd[$k]['values']['column']);                                          $dont_cols = isset($this->fdd[$k]['values']['column']);
                                         $qo[$this->fqn($k, false, $dont_desc, $dont_cols)] =                                          $qo[$this->fqn($k, $dont_desc, $dont_cols)] =
                                                 array('oper'  => $qf_op, 'value' => "($qf_val)"); // )                                                  array('oper'  => $qf_op, 'value' => "($qf_val)"); // )
                                 }                                  }
                         } else if (isset($mi)) {                          } else if (isset($mi)) {
Riadok 630  class phpMyEdit
Riadok 625  class phpMyEdit
                                         continue;                                          continue;
                                 }                                  }
                                 $afilter = addslashes($mi);                                  $afilter = addslashes($mi);
                                 $qo[$this->fqn($k, false, true, true)] = array('oper'  => '=', 'value' => "'$afilter'");                                  $qo[$this->fqn($k, true, true)] = array('oper'  => '=', 'value' => "'$afilter'");
                                 $this->qfn .= '&'.$li.'='.rawurlencode($mi);                                  $this->qfn .= '&'.$li.'='.rawurlencode($mi);
                         } else if (isset($m)) {                          } else if (isset($m)) {
                                 if ($m == '*') {                                  if ($m == '*') {
Riadok 657  class phpMyEdit
Riadok 652  class phpMyEdit
                                                         }                                                          }
                                                 }                                                  }
                                                 if (count($ids) > 0) {                                                  if (count($ids) > 0) {
                                                         $ar[$this->fqn($k, false, true, true)]                                                          $ar[$this->fqn($k, true, true)]
                                                                 = array('oper'  => 'IN', 'value' => '('.join(',', $ids).')');                                                                  = array('oper'  => 'IN', 'value' => '('.join(',', $ids).')');
                                                 }                                                  }
                                         }                                          }

Legend:
Odstranené z verzie1.93  
zmenené riadky
  Pridané vo verzii1.94

Platon Group <platon@platon.sk> http://platon.sk/
Copyright © 2002-2006 Platon Group
Stránka používa redakčný systém Metafox
Na začiatok