Create a gist now

Instantly share code, notes, and snippets.

【EC-CUBE3】会員情報の項目を追加する方法
<?php
/*
* This file is part of the Profile
*
* Copyright (C) 2016 会員プロフィール
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Plugin\Profile;
use Eccube\Application;
use Eccube\Plugin\AbstractPluginManager;
class PluginManager extends AbstractPluginManager
{
/**
* プラグインインストール時の処理
*
* @param $config
* @param Application $app
* @throws \Exception
*/
public function install($config, Application $app)
{
}
/**
* プラグイン削除時の処理
*
* @param $config
* @param Application $app
*/
public function uninstall($config, Application $app)
{
}
/**
* プラグイン有効時の処理
*
* @param $config
* @param Application $app
* @throws \Exception
*/
public function enable($config, Application $app)
{
$this->migrationSchema($app, __DIR__.'/Resource/doctrine/migration', $config['code']);
}
/**
* プラグイン無効時の処理
*
* @param $config
* @param Application $app
* @throws \Exception
*/
public function disable($config, Application $app)
{
$this->migrationSchema($app, __DIR__.'/Resource/doctrine/migration', $config['code'], 0);
}
/**
* プラグイン更新時の処理
*
* @param $config
* @param Application $app
* @throws \Exception
*/
public function update($config, Application $app)
{
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment