Teams are framed as individuals embedded in hierarchical and knowledge networks, who interact among each other with the aim of accomplishing a common task. Social interactions are the means through which team members exert their mutual social influence, change opinions, and converge to a common understanding. In this paper, we investigate how the density and connectivity of the team knowledge network and the team organizational structure relate to team performance. The latter is measured in terms of level of agreement among the team members (consensus outcome). We first develop a theoretical model grounded on social influence theory and then a computational model based on the Ising approach. Successively, we carry out a broad simulation analysis in environments characterized by different levels of uncertainty. Results show that high-density values of the team knowledge network are beneficial in the majority of cases, but may become detrimental, when the uncertainty of the environment is low, the team knowledge network exhibits a random connectivity, and the team organizational structure is characterized by high centralization of the authority and a strong leadership behavior. We also find that scale-free connectivity of the team knowledge network hinders the achievement of consensus, compared to the random connectivity case. Based on the simulation results, we finally identify the best organizational structure that should be adopted to improve the consensus outcome.