Ignore:
Timestamp:
Sep 20, 2010, 12:43:52 AM (14 years ago)
Author:
grum
Message:

Migration from version 1.0.1 to 1.0.2 implemented

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/ColorStat/cstat_install.class.inc.php

    r6176 r6976  
    9090
    9191      $result=$this->tablef->create($tables_def);
     92
     93      GPCCore::register($this->getPluginName(), CSTAT_VERSION, CSTAT_GPC_NEEDED);
     94
    9295      return($result);
    9396    }
     
    99102    public function uninstall()
    100103    {
     104      GPCCore::unregister($this->getPluginName());
     105
    101106      $this->deleteConfig();
    102107      $this->tablef->drop();
     
    109114
    110115      $this->initConfig();
    111       //$this->loadConfig(); //don't keep the previous config : we need to start with default values
     116      $this->loadConfig();
    112117      $this->config['installed']=CSTAT_VERSION2;
    113       $this->config['newInstall']='y';
    114118      $this->saveConfig();
    115 
     119/*
    116120      pwg_query("DELETE FROM ".$this->tables['color_table']);
    117121      pwg_query("DELETE FROM ".$this->tables['images_colors']);
     
    128132                    FROM ".IMAGES_TABLE."
    129133                    WHERE id NOT IN (SELECT image_id FROM ".$this->tables['images'].")");
     134*/
     135      GPCCore::register($this->getPluginName(), CSTAT_VERSION, CSTAT_GPC_NEEDED);
     136      GPCRequestBuilder::register($this->getPluginName(), dirname($this->getFileLocation()).'/cstat_rb_callback.class.inc.php');
    130137
    131138      return('');
     
    134141    public function deactivate()
    135142    {
     143      GPCRequestBuilder::unregister($this->getPluginName());
    136144    }
    137145
Note: See TracChangeset for help on using the changeset viewer.