Hi all:
As part of our itop implementation (1.0.1; although we are weighing the pluses of 1.0.2) we need to add another currency (our national currency named colones). We currently use both us dollars and colones for our main contracts.
We want to add our currency in which way that don't broke anything and let use the four currencies.
Can you help me to acomplish this?
Do I have to edit the dicctionaries also (I meant besides the spanish one; since we use English and Spanish UIs)?
Thanks a lot
PD: By the way we found the currency field on itopcontract table but seem the currency are on another table.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
2. open the Toolkit page http://max02240:200/toolkit/ and check that the Data Model Consistency does not report any errors.
3. Select tab Database Schema, which shows the following message:
Class Contract
field 'cost_currency' in table 'contract' has a wrong type: found 'enum('dollars','euros')' while expecting 'ENUM('dollars','euros','pounds')'
ALTER TABLE `contract` CHANGE `cost_currency` `cost_currency` ENUM('dollars','euros','pounds') NULL;
Press “Apply Selected SQL commands!”
4. Now make the changes in the dictionary file C:\Inetpub\wwwroot\web\modules\itop-service-mgmt-1.0.0\en.dict.itop-service-mgmt.php
Hi all:
As part of our itop implementation (1.0.1; although we are weighing the pluses of 1.0.2) we need to add another currency (our national currency named colones). We currently use both us dollars and colones for our main contracts.
We want to add our currency in which way that don't broke anything and let use the four currencies.
Can you help me to acomplish this?
Do I have to edit the dicctionaries also (I meant besides the spanish one; since we use English and Spanish UIs)?
Thanks a lot
PD: By the way we found the currency field on itopcontract table but seem the currency are on another table.
iTop comes standard with currency defined in dollars or euros. Make the following changes to add pounds.
1. edit C:\Inetpub\wwwroot\web\modules\itop-service-mgmt-1.0.0\model.itop-service-mgmt.php and make the following change:
MetaModel::Init_AddAttribute(new AttributeEnum("cost_currency", array("allowed_values"=>new ValueSetEnum('dollars,euros'), "sql"=>"cost_currency", "default_value"=>"euros", "is_null_allowed"=>true, "depends_on"=>array())));
To
MetaModel::Init_AddAttribute(new AttributeEnum("cost_currency", array("allowed_values"=>new ValueSetEnum('pounds,dollars,euros'), "sql"=>"cost_currency", "default_value"=>"pounds", "is_null_allowed"=>true, "depends_on"=>array())));
2. open the Toolkit page http://max02240:200/toolkit/ and check that the Data Model Consistency does not report any errors.
3. Select tab Database Schema, which shows the following message:
Class Contract
field 'cost_currency' in table 'contract' has a wrong type: found 'enum('dollars','euros')' while expecting 'ENUM('dollars','euros','pounds')'
ALTER TABLE `contract` CHANGE `cost_currency` `cost_currency` ENUM('dollars','euros','pounds') NULL;
Press “Apply Selected SQL commands!”
4. Now make the changes in the dictionary file C:\Inetpub\wwwroot\web\modules\itop-service-mgmt-1.0.0\en.dict.itop-service-mgmt.php
Add these two lines to the class contract:
'Class:Contract/Attribute:cost_currency/Value:pounds' => 'Pounds',
'Class:Contract/Attribute:cost_currency/Value:pounds+' => '',
This worked fine except of course the path for version 2 should be C:\Inetpub\wwwroot\web\modules\itop-service-mgmt-provider...
I could not work out to get it to show "Pounds" rather than "pounds" though.
you have to add it in the dictionary
ex:
'Class:Contract/Attribute:cost_currency/Value:pounds' => 'Pounds',
'Class:Contract/Attribute:cost_currency/Value:pounds+' => '',