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

prevent creating the default table when using a custom entity #50

Merged
merged 1 commit into from Aug 1, 2019

Conversation

@craue
Copy link
Owner

commented Jul 10, 2019

An approach to possibly fix #36.

What I don't like is that BaseSetting.orm.xml will need to be duplicated (in separated folders due to doctrine/DoctrineBundle#209), so let me know if there's a cleaner way.

@coveralls

This comment has been minimized.

Copy link

commented Jul 10, 2019

Coverage Status

Coverage remained the same at 100.0% when pulling e0006ce on prevent-creating-default-table-with-custom-entity into 7c386c0 on master.

@crmpicco

This comment has been minimized.

Copy link

commented Jul 11, 2019

@craue Thanks for responding so quickly to yesterday's comment on #36

My Craue Config in config.yml looks like this:

craue_config:
    entity_name: CRMPiccoBundle\Entity\ConfigSetting

and I extend the BaseSetting parent class like this:

/**
 * ConfigSetting entity for the config_setting table.
 *
 * @author Craig R Morton <crmpicco@aol.com>
 * @date 03-07-2017
 */

namespace CRMPiccoBundle\Entity;

use Craue\ConfigBundle\Entity\BaseSetting;
use Doctrine\ORM\Mapping as ORM;

/**
 * @ORM\Entity(repositoryClass="Craue\ConfigBundle\Repository\SettingRepository")
 * @ORM\Table(name="config_setting")
 */
class ConfigSetting extends BaseSetting
{

This PR looks great to me. It would be great if this was merged in and released to save me maintaining a fork as this bundle does exactly what I need it to do (and more).

Thanks 👍

@crmpicco

This comment has been minimized.

Copy link

commented Jul 24, 2019

Hi @craue, is this likely to be merged in soon?

@craue

This comment has been minimized.

Copy link
Owner Author

commented Jul 24, 2019

I was hoping for some more feedback from people actually trying the code about whether it really works as expected and solves the issue.

@craue craue force-pushed the prevent-creating-default-table-with-custom-entity branch from f928fab to 5ea527c Aug 1, 2019

@craue craue force-pushed the prevent-creating-default-table-with-custom-entity branch from 5ea527c to e0006ce Aug 1, 2019

@craue craue added new feature and removed improvement labels Aug 1, 2019

@craue craue merged commit 1ffd9df into master Aug 1, 2019

3 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
coverage/coveralls Coverage remained the same at 100.0%
Details

@craue craue deleted the prevent-creating-default-table-with-custom-entity branch Aug 1, 2019

@craue

This comment has been minimized.

Copy link
Owner Author

commented Aug 1, 2019

Version 2.3.0 is out containing this feature.

@crmpicco

This comment has been minimized.

Copy link

commented Aug 2, 2019

You're a ⭐️ !

@Mopster Mopster referenced this pull request Aug 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.