comparison ClassPlanShipments.lua @ 106:1197c8825eda

- remove 7.2.5 changes from live
author Nenue
date Sun, 28 May 2017 19:58:56 -0400
parents 4d1520186ea4
children b2be2de2b133
comparison
equal deleted inserted replaced
105:9f664a0ef8a8 106:1197c8825eda
105 for i = 1, #looseShipments do 105 for i = 1, #looseShipments do
106 local name, texture, shipmentCapacity, shipmentsReady, shipmentsTotal, creationTime, duration, timeleftString = CG_GetLandingPageShipmentInfoByContainerID(looseShipments[i]); 106 local name, texture, shipmentCapacity, shipmentsReady, shipmentsTotal, creationTime, duration, timeleftString = CG_GetLandingPageShipmentInfoByContainerID(looseShipments[i]);
107 AddShipmentInfo(AK_NOTES, name, texture, shipmentCapacity, shipmentsReady, shipmentsTotal, creationTime, duration, timeleftString) 107 AddShipmentInfo(AK_NOTES, name, texture, shipmentCapacity, shipmentsReady, shipmentsTotal, creationTime, duration, timeleftString)
108 end 108 end
109 109
110 local talentTrees = C_Garrison.GetTalentTreeIDsByClassID(garrisonType, select(3, UnitClass("player"))); 110 local talentTrees = CG_GetTalentTrees(garrisonType, select(3, UnitClass("player")));
111 -- this is a talent that has completed, but has not been seen in the talent UI yet. 111 -- this is a talent that has completed, but has not been seen in the talent UI yet.
112 local completeTalentID = CG_GetCompleteTalent(garrisonType); 112 local completeTalentID = CG_GetCompleteTalent(garrisonType);
113 print('Talents:') 113 --print('Talents:')
114 if (talentTrees) then 114 if (talentTrees) then
115 for treeIndex, treeID in ipairs(talentTrees) do 115 for treeIndex, tree in ipairs(talentTrees) do
116 local _, _, tree = C_Garrison.GetTalentTreeInfoForID(garrisonType, treeID);
117 for talentIndex, talent in ipairs(tree) do 116 for talentIndex, talent in ipairs(tree) do
118 local showTalent = false; 117 local showTalent = false;
119 if (talent.isBeingResearched) or (talent.id == completeTalentID) then 118 if (talent.isBeingResearched) or (talent.id == completeTalentID) then
120 AddShipmentInfo(OH_TALENT, talent.name, talent.icon, 1, (talent.isBeingResearched and 0 or 1), 1, talent.researchStartTime, talent.researchDuration, talent.timeleftString) 119 AddShipmentInfo(OH_TALENT, talent.name, talent.icon, 1, (talent.isBeingResearched and 0 or 1), 1, talent.researchStartTime, talent.researchDuration, talent.timeleftString)
121 end 120 end
209 end 208 end
210 209
211 210
212 ShipmentList.SortHandler = function(a, b) 211 ShipmentList.SortHandler = function(a, b)
213 local status = false 212 local status = false
214 if b.isComplete ~= a.isComplete then 213 if b.isComplete ~= a.isComplete then
215 if a.isComplete then 214 if a.isComplete then
216 status = true
217 end
218 else
219 if a[SortKey] then
220 if b[SortKey] then
221 status = (SortTable[a[SortKey]] < SortTable[b[SortKey]])
222 else
223 status = true 215 status = true
224 end 216 end
225 else 217 else
218 if a[SortKey] then
219 if b[SortKey] then
220 status = (SortTable[a[SortKey]] < SortTable[b[SortKey]])
221 else
222 status = true
223 end
224 else
226 if a.profileKey ~= b.profileKey then 225 if a.profileKey ~= b.profileKey then
227 status = (a.profileKey < b.profileKey) 226 status = (a.profileKey < b.profileKey)
228 227
229 else 228 else
230 if a.shipmentsReady and b.shipmentsReady then 229 if a.shipmentsReady and b.shipmentsReady then