Index: ossp-pkg/as/as-gui/as_reportpanel.cpp RCS File: /v/ossp/cvs/ossp-pkg/as/as-gui/as_reportpanel.cpp,v rcsdiff -q -kk '-r1.12' '-r1.13' -u '/v/ossp/cvs/ossp-pkg/as/as-gui/as_reportpanel.cpp,v' 2>/dev/null --- as_reportpanel.cpp 2003/02/21 23:44:36 1.12 +++ as_reportpanel.cpp 2003/02/24 17:39:04 1.13 @@ -478,11 +478,11 @@ // QString Reportpanel::getWeektotals(QDate Dayref, int nWeeks) { - using namespace std; // Needed for hash tables with hmap - map Hashtasks; // Hashtable for storing tasks - map Hashhours; // Hashtable for storing hours - map::iterator Taskiter; // The hashtable task iterator - map::iterator Houriter; // The hashtable hour iterator + using namespace std; // Needed for maps and hash + map Hashtasks; // Hashtable to store tasks + multimap Hashhours; // Hashtable to store hours + map::iterator Taskiter; // Hashtable task iterator + multimap::iterator Houriter; // Hashtable hour iterator QString Totals; // Data totals to return for writing QString Tempstring; // Temporary processing string @@ -527,7 +527,7 @@ // Reverse copy the tasks hashtable to both sort and index by amount key for (Taskiter = Hashtasks.begin(); Taskiter != Hashtasks.end(); Taskiter++) - Hashhours[Taskiter->second] = Taskiter->first; + Hashhours.insert(pair(Taskiter->second, Taskiter->first)); // Write the actual data totals to the outgoing string in reverse order for (Houriter = Hashhours.begin(); Houriter != Hashhours.end(); Houriter++) @@ -596,11 +596,11 @@ // QString Reportpanel::getMonthtotals(QDate Dayref, int nMonths) { - using namespace std; // Needed for hash tables with hmap - map Hashtasks; // Hashtable for storing tasks - map Hashhours; // Hashtable for storing hours - map::iterator Taskiter; // The hashtable task iterator - map::iterator Houriter; // The hashtable hour iterator + using namespace std; // Needed for maps and hash + map Hashtasks; // Hashtable to store tasks + multimap Hashhours; // Hashtable to store hours + map::iterator Taskiter; // Hashtable task iterator + multimap::iterator Houriter; // Hashtable hour iterator QString Totals; // Data totals to return for writing QString Tempstring; // Temporary processing string @@ -647,7 +647,7 @@ // Reverse copy the tasks hashtable to both sort and index by amount key for (Taskiter = Hashtasks.begin(); Taskiter != Hashtasks.end(); Taskiter++) - Hashhours[Taskiter->second] = Taskiter->first; + Hashhours.insert(pair(Taskiter->second, Taskiter->first)); // Write the actual data totals to the outgoing string in reverse order for (Houriter = Hashhours.begin(); Houriter != Hashhours.end(); Houriter++)