function Controller(){function e(){var e=_.groupBy(a.data.teams.home.crew,function(e){return e.substitute});_.defer(function(){var i=_.groupBy(a.data.teams.away.crew,function(e){return e.substitute});_.defer(function(){_.each(e.false,function(e){t.initialHome.add(Alloy.createController("matchDetailLineUpCell",{name:e.name,image:e.image,align:"left"}).getView())}),_.defer(function(){_.each(i.false,function(e){t.initialAway.add(Alloy.createController("matchDetailLineUpCell",{name:e.name,image:e.image,align:"right"}).getView())}),_.defer(function(){_.each(e.true,function(e){t.substitutesHome.add(Alloy.createController("matchDetailLineUpCell",{name:e.name,image:e.image,align:"left"}).getView())}),_.defer(function(){_.each(i.true,function(e){t.substitutesAway.add(Alloy.createController("matchDetailLineUpCell",{name:e.name,image:e.image,align:"right"}).getView())})})})})})})}require("alloy/controllers/BaseController").apply(this,Array.prototype.slice.call(arguments)),this.__controllerPath="matchDetailLineUp",arguments[0]?arguments[0].__parentSymbol:null,arguments[0]?arguments[0].$model:null,arguments[0]?arguments[0].__itemTemplate:null;var t=this,i={};t.__views.matchDetailLineUp=Ti.UI.createScrollView({layout:"vertical",id:"matchDetailLineUp"}),t.__views.matchDetailLineUp&&t.addTopLevelView(t.__views.matchDetailLineUp),t.__views.headerInitalLineUp=Ti.UI.createLabel({font:{fontSize:16,fontFamily:Alloy.CFG.fonts.bold},backgroundGradient:Alloy.CFG.gradients.lightGrey,width:Ti.UI.FILL,height:28,top:1,id:"headerInitalLineUp"}),t.__views.matchDetailLineUp.add(t.__views.headerInitalLineUp),t.__views.wrapperInitial=Ti.UI.createView({height:Ti.UI.SIZE,backgroundColor:Alloy.CFG.colors.lightGrey,id:"wrapperInitial"}),t.__views.matchDetailLineUp.add(t.__views.wrapperInitial),t.__views.initialHome=Ti.UI.createView({layout:"vertical",width:159,height:Ti.UI.SIZE,top:0,left:0,id:"initialHome"}),t.__views.wrapperInitial.add(t.__views.initialHome),t.__views.initialAway=Ti.UI.createView({layout:"vertical",width:159,height:Ti.UI.SIZE,top:0,right:0,id:"initialAway"}),t.__views.wrapperInitial.add(t.__views.initialAway),t.__views.headerSubstitutes=Ti.UI.createLabel({font:{fontSize:16,fontFamily:Alloy.CFG.fonts.bold},backgroundGradient:Alloy.CFG.gradients.lightGrey,width:Ti.UI.FILL,height:28,top:1,id:"headerSubstitutes"}),t.__views.matchDetailLineUp.add(t.__views.headerSubstitutes),t.__views.wrapperSubstitutes=Ti.UI.createView({height:Ti.UI.SIZE,backgroundColor:Alloy.CFG.colors.lightGrey,id:"wrapperSubstitutes"}),t.__views.matchDetailLineUp.add(t.__views.wrapperSubstitutes),t.__views.substitutesHome=Ti.UI.createView({layout:"vertical",width:159,height:Ti.UI.SIZE,top:0,left:0,id:"substitutesHome"}),t.__views.wrapperSubstitutes.add(t.__views.substitutesHome),t.__views.substitutesAway=Ti.UI.createView({layout:"vertical",width:159,height:Ti.UI.SIZE,top:0,right:0,id:"substitutesAway"}),t.__views.wrapperSubstitutes.add(t.__views.substitutesAway),i.destroy=function(){},_.extend(t,t.__views),require("helpers"),require("feedSigner"),require("netConnect");var a=arguments[0]||{};t.headerInitalLineUp.text="   "+L("Matchdetail_Lineups_Header"),t.headerSubstitutes.text="   "+L("Matchdetail_Substitutes"),e(),_.extend(t,i)}var Alloy=require("alloy"),Backbone=Alloy.Backbone,_=Alloy._;module.exports=Controller;