I need to modify the core Store model to include another flag (a boolean). I’ve gone through and it looks like I just need to add a column to the database table that stores store configuration information. I’ve already written the subclass to extend Mage_Core_Model_Store and verified that it works, but I’m kind of stuck on a couple of things:
1) How do I add this flag to the store model so it is stored in the database, and
2) Is there a tutorial or something on creating the ability to configure this flag in the admin backend?
I’ve gone through what I can find, especially the payment module tutorial, but it doesn’t seem directly applicable. Any help is appreciated.
OK, here’s a question then: I’ve been developing this module right along in an installation of Magento, so there’s been no need for an ‘installation’ per se.. how would I get Magento to read that file if the files are already in place?
i want to save payment datas in my new module to order_payment therefor i can use dynamic attributes from EAV models?
Where and how can i define that new attributes for my module? Also in the module_setup? For example i want to add bank account and
account owner to my order.
Is following way correct?
$this->startSetup()->run(" select @entity_type_id:=entity_type_id from eav_entity_type where entity_type_code='order_payment';
Could someone also explain to me what the deal is with EAV? I’ve never heard of that term before starting to work with Magento, and I don’t understand how you use the eav_attributes to modify an existing model, what models you can change with it, and so forth.
Basically what I’m looking to do is to add a boolean to the store config, and then based on the value of that boolean, have Magento read data in from another table. The information in the mysql-install file above is useful, but I need to know how to add a completely new table as well.
Also, how in the heck do you add something to an existing page in the admin? I need to add a config item to allow the admin to turn the feature on or off by storefront, and also to input data that the feature uses.
Please help, I’ve been making good progress so far extending the models I need to, but have come to a deadend with the backend stuff.
I could still use some help with creating a brand new table to store data for a new module, as well as some help in how I would install a module ‘in place’, ie get Magento to read the mysql-setup file and create what it needs to create.
Help with setting up the admin for configuring this data kind of goes with that, so any help is appreciated.
I know it’s bad form to bump one’s own posts, but I really need some help here with figuring out how to add a brand new table to the database, how to “install” a module that you’ve been developing (so the SQL code is read) and how to set things up in the admin interface.
I have to add a boolean field to each store for a new feature I’m writing. If this field is true, then it needs to pull from another table that contains a store id and a five digit sequence (in other words, a one-to-many relationship between the store id and the data. Each store ID will appear several times, but the data will only appear in one record for each store.)
I can’t think of another way to do this outside of adding a table.