1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-27 10:50:10 +03:00

Feature #3472: Rename showback COST to TOTAL_COST

This commit is contained in:
Carlos Martín 2015-02-04 13:07:53 +01:00
parent f2f660ba73
commit 8fada81b17
4 changed files with 6 additions and 6 deletions

View File

@ -206,7 +206,7 @@ class AcctHelper < OpenNebulaHelper::OneHelper
end
column :COST, "Cost", :size=>15 do |d|
d["COST"]
d["TOTAL_COST"]
end
default :USER_NAME, :GROUP_NAME, :VM_ID, :VM_NAME, :MONTH, :YEAR, :HOURS, :COST

View File

@ -322,7 +322,7 @@ module OpenNebula
# into account, if no end time is required use -1
# @option params [Integer] :group Group id to filter the results
# @option params [String] :xpath Xpath expression to filter the results.
# For example: SHOWBACK[COST>0]
# For example: SHOWBACK[TOTAL_COST>0]
# @option params [String] :order_by_1 Xpath expression to group the
# @option params [String] :order_by_2 Xpath expression to group the
# returned hash. This will be the second level of the hash
@ -376,7 +376,7 @@ module OpenNebula
# into account, if no end time is required use -1
# @option params [Integer] :group Group id to filter the results
# @option params [String] :xpath Xpath expression to filter the results.
# For example: SHOWBACK[COST>10]
# For example: SHOWBACK[TOTAL_COST>10]
#
# @return [String] the xml representing the showback data
def showback_xml(filter_flag=INFO_ALL, options={})

View File

@ -5017,8 +5017,8 @@ function fillShowback(div, req, response) {
}
}
vms_per_date[showback.YEAR][showback.MONTH].VMS.push([showback.VMID, showback.VMNAME, showback.UNAME, showback.HOURS, showback.COST]);
vms_per_date[showback.YEAR][showback.MONTH].TOTAL += parseFloat(showback.COST);
vms_per_date[showback.YEAR][showback.MONTH].VMS.push([showback.VMID, showback.VMNAME, showback.UNAME, showback.HOURS, showback.TOTAL_COST]);
vms_per_date[showback.YEAR][showback.MONTH].TOTAL += parseFloat(showback.TOTAL_COST);
});
var series = []

View File

@ -513,7 +513,7 @@ struct SBRecord {
oss << "<CPU_COST>" << cpuc_s << "</CPU_COST>"
<< "<MEMORY_COST>"<< memc_s << "</MEMORY_COST>"
<< "<COST>" << cost_s << "</COST>"
<< "<TOTAL_COST>" << cost_s << "</TOTAL_COST>"
<< "<HOURS>" << hour_s << "</HOURS>";
return oss;