Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Entity拡張時にオリジナルのファイルを優先して参照するよう変更 #4711

Merged
merged 1 commit into from Dec 18, 2020

Conversation

izayoi256
Copy link
Contributor

@izayoi256 izayoi256 commented Oct 2, 2020

概要(Overview・Refs Issue)

#4708

実装に関する補足(Appendix)

  • 拡張対象の名前空間によって、拡張元のファイルを制御。
    • Eccube\Entity\*なら%kernel.project_dir%/src/Eccube/Entityを参照。
    • Customize\Entity\*なら%kernel.project_dir%/app/Customize/Entityを参照。
    • Plugin\[PluginCode]\Entity\*なら%kernel.project_dir%/app/Plugin/[PluginCode]/Entityを参照。
    • それぞれファイルが見つからない時はReflectionClass::getFileName()を参照。

テスト(Test)

ユニットテストを実装してみたものの、テスト時は元々オリジナルのファイルを参照するため実証不可につきself::markTestSkipped()

実際に$ php bin:console eccube:generate:proxyを実行する限りでは、本体もカスタマイズもプラグインもオリジナルファイルの変更に追従するようになった。

マイナーバージョン互換性保持のための制限事項チェックリスト

  • 既存機能の仕様変更
  • フックポイントの呼び出しタイミングの変更
  • フックポイントのパラメータの削除・データ型の変更
  • twigファイルに渡しているパラメータの削除・データ型の変更
  • Serviceクラスの公開関数の、引数の削除・データ型の変更
  • 入出力ファイル(CSVなど)のフォーマット変更

レビュワー確認項目

  • 動作確認
  • コードレビュー
  • E2E/Unit テスト確認(テストの追加・変更が必要かどうか)
  • 互換性が保持されているか
  • セキュリティ上の問題がないか

@okazy okazy added the improvement 機能改善 label Oct 5, 2020
@okazy okazy added this to the 4.0.x milestone Oct 5, 2020
@kiy0taka kiy0taka self-assigned this Dec 18, 2020
@kiy0taka kiy0taka added bug and removed improvement 機能改善 labels Dec 18, 2020
@kiy0taka kiy0taka merged commit ece7185 into EC-CUBE:4.0 Dec 18, 2020
@kiy0taka
Copy link
Contributor

ありがとうございました。

@okazy okazy modified the milestones: 4.0.x, 4.0.6 Dec 18, 2020
@izayoi256 izayoi256 deleted the feature/proxy-regenerate branch December 18, 2020 05:45
@chihiro-adachi chihiro-adachi modified the milestones: 4.0.6, 4.1 Jul 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants