バージョン選択

フォーラム

メニュー

オンライン状況

41 人のユーザが現在オンラインです。 (31 人のユーザが フォーラム を参照しています。)
登録ユーザ: 0
ゲスト: 41
もっと...

サイト内検索

質問 > フロント機能 > 会員登録で項目を追加したい

フロント機能

新規スレッドを追加する

フラット表示 前のトピック | 次のトピック
投稿者 スレッド
masaru
投稿日時: 2021/10/30 18:47
対応状況: −−−
半人前
登録日: 2009/7/7
居住地:
投稿: 18
Re: 会員登録で項目を追加したい
御教示いただいたサイトの記事を参考に

OrderTrait.php

<?php

namespace Customize\Entity;

use Doctrine\ORM\Mapping as ORM;
use Eccube\Annotation\EntityExtension;

/**
* @EntityExtension("Eccube\Entity\Order")
*/
trait OrderTrait
{
/**
* @ORM\Column(type="string", nullable=true)
*/
public $department_name;
}

というファイルを作成し、
../../../bin/console eccube:generate:proxies
を実行し、
../../../bin/console cache:clear --no-warmup
をやったら
PHP Fatal error: Eccube\Entity\Order and Customize\Entity\OrderTrait define the same property ($department_name) in the composition of Eccube\Entity\Order. However, the definition differs and is considered incompatible. Class was composed in /var/www/html/eccube/app/proxy/entity/src/Eccube/Entity/Order.php on line 42
In Order.php line 42:
Compile Error: Eccube\Entity\Order and Customize\Entity\OrderTrait define the same property ($department_name) in the composition of ccube\Entity\Order. However, the definition differs and is considered incompatible. Class was composed

となってしまいました。

src/Eccube/Entity/Order.php


/**
* @var string|null
*
* @ORM\Column(name="department_name", type="string", length=255, nullable=true)
*/
private $department_name;
/**

の記述があるのが重複しているということでしょうか。
フラット表示 前のトピック | 次のトピック


題名 投稿者 日時
   会員登録で項目を追加したい masaru 2021/10/30 2:33
     Re: 会員登録で項目を追加したい ec9iii 2021/10/30 10:45
     » Re: 会員登録で項目を追加したい masaru 2021/10/30 18:47
         Re: 会員登録で項目を追加したい ec9iii 2021/11/1 10:03

 



ログイン


EC-CUBE公式 Amazon Payプラグイン

統計情報

総メンバー数は89,167名です
総投稿数は110,047件です

投稿数ランキング

1
seasoft
7367
2
468
3217
3
AMUAMU
2712
4
nanasess
2314
5
umebius
2085
6
yuh
1819
7
h_tanaka
1650
8
red
1570
9
mcontact
1299
10
tsuji
958
11
fukap
907
12
shutta
835
13
tao_s
799
14 ramrun 789
15 karin 689
16 sumida 641
17
homan
633
18 DELIGHT 572
19
patapata
502
20
flealog
485


ネットショップの壺

EC-CUBEインテグレートパートナー

Copyright© EC-CUBE CO.,LTD. All Rights Reserved.