File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -267,10 +267,12 @@ impl Solution<'_> {
267267 pub fn iter_activity_keys_for_existing (
268268 & self ,
269269 ) -> impl Iterator < Item = ( & AssetRef , & TimeSliceID ) > {
270+ let cols = & self . solution . columns ( ) [ self . variables . existing_asset_var_idx . clone ( ) ] ;
270271 self . variables
271272 . activity_var_keys ( )
272273 . skip ( self . variables . existing_asset_var_idx . start )
273- . map ( |( asset, time_slice) | ( asset, time_slice) )
274+ . zip ( cols. iter ( ) )
275+ . map ( |( ( asset, time_slice) , _) | ( asset, time_slice) )
274276 }
275277
276278 /// Activity for each candidate asset
@@ -289,10 +291,12 @@ impl Solution<'_> {
289291 pub fn iter_activity_keys_for_candidates (
290292 & self ,
291293 ) -> impl Iterator < Item = ( & AssetRef , & TimeSliceID ) > {
294+ let cols = & self . solution . columns ( ) [ self . variables . candidate_asset_var_idx . clone ( ) ] ;
292295 self . variables
293296 . activity_var_keys ( )
294297 . skip ( self . variables . candidate_asset_var_idx . start )
295- . map ( |( asset, time_slice) | ( asset, time_slice) )
298+ . zip ( cols. iter ( ) )
299+ . map ( |( ( asset, time_slice) , _) | ( asset, time_slice) )
296300 }
297301
298302 /// Iterate over unmet demand
You can’t perform that action at this time.
0 commit comments