Database connection ...

Added by Victor Leboucher over 9 years ago

Hello everybody,

Actually i work on a plugin for redmine, witch migre only selected bug from mantis.
First congratulation for Jean-philippe Lang for this tools of project, it's very simple with lot of fonctionnalities.
The rule of the plugin is very pratical.

In opposition to the script migrate_from_mantis.rake , my plugin migre only some bug before selected, i don't want all the mantis database.

But in my development i have some problemes and i think this forum can help me, i take all sugestions.

Inevitably, for the migration, i will connect redmine on the database of mantis, i have use the class of the script "etablished_connection" for testing the connection, (i stock the information of the mantis database in a table create in the import of the plugin), on the rule the connection works but after all command in redmine are aim at about bugtracker.setting (for exemple),then redmine is connected at mantis.
I want information for avoid connect to mantis and reconnect to redmine database, and if nessesary how redmine connect it to its base ?
only on load, the serveur load database.yml and it finish with the connection, or it have a connection variables?
I am on the bad way or the rule of my plugin is rather difficult to realise?

And i have another probleme with the file init.rb.
If i want configure my plugin, i want use the adequate fuction.When i add the line :"settings :partial => 'settings/settings'" after "name" author" ... ,and i have the folder settings in my views with tje file _settings.rb, the navigator return me this error directly on load the main page : D:/Service/Profiles/vleboucher.BDOM/Mes documents/NetBeansProjects/Redmine/app/models/setting.rb:96: , unexpected null

I don't understand my error , and after compare with another plugin, i don't kwon when i have forget a modification.

I hope i am not so disordered in my explication, i wait your response with impatience.
I here for complementary informations

Thx for reading.

Victor Leboucher