* Get total shipment orders from(+) and to(-) the base (economy). * @param baseIdx - 0-7 for bases, 8 for economy * @return - total sum of shipment orders */
| 838 | * @return - total sum of shipment orders |
| 839 | */ |
| 840 | int TransactionControl::Trade::shipmentsTotal(const int baseIdx) const |
| 841 | { |
| 842 | int total = 0; |
| 843 | if (shipments.find(baseIdx) != shipments.end()) |
| 844 | { |
| 845 | for (auto &s : shipments.at(baseIdx)) |
| 846 | { |
| 847 | total += s.second; |
| 848 | } |
| 849 | } |
| 850 | return total; |
| 851 | } |
| 852 | |
| 853 | /** |
| 854 | * Get shipment order. |
no test coverage detected