| Conditions | 1 |
| Paths | 1 |
| Total Lines | 29 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | define(function(require) { |
||
| 2 | 'use strict'; |
||
| 3 | |||
| 4 | var OpportunityCardView; |
||
| 5 | var CardView = require('orodatagrid/js/app/views/board/card-view'); |
||
| 6 | var multiCurrencyFormatter = require('orocurrency/js/formatter/multi-currency'); |
||
| 7 | |||
| 8 | OpportunityCardView = CardView.extend({ |
||
| 9 | className: 'opportunity-card-view card-view', |
||
| 10 | template: require('tpl!../../../../templates/board/opportunity-card-view.html'), |
||
| 11 | |||
| 12 | /** |
||
| 13 | * @inheritDoc |
||
| 14 | */ |
||
| 15 | constructor: function OpportunityCardView() { |
||
| 16 | OpportunityCardView.__super__.constructor.apply(this, arguments); |
||
| 17 | }, |
||
| 18 | |||
| 19 | getTemplateData: function() { |
||
| 20 | var data = OpportunityCardView.__super__.getTemplateData.call(this, arguments); |
||
| 21 | var budgetAmount = multiCurrencyFormatter.unformatMultiCurrency(data.budgetAmount); |
||
| 22 | data.budgetAmount = budgetAmount.amount; |
||
| 23 | data.budgetCurrency = budgetAmount.currency; |
||
| 24 | return data; |
||
| 25 | } |
||
| 26 | }); |
||
| 27 | |||
| 28 | return OpportunityCardView; |
||
| 29 | }); |
||
| 30 |