示例#1
0
文件: models.py 项目: suqi/taiga-back
 def future_client_increment(self):
     client_increment = self._get_points_increment(True, False)
     shared_increment = {
         key: value / 2
         for key, value in self.future_shared_increment.items()
     }
     return dict_sum(client_increment, shared_increment)
示例#2
0
 def _get_user_stories_points(self, user_stories):
     role_points = [us.role_points.all() for us in user_stories]
     flat_role_points = itertools.chain(*role_points)
     flat_role_dicts = map(
         lambda x: {x.role_id: x.points.value
                    if x.points.value else 0}, flat_role_points)
     return dict_sum(*flat_role_dicts)
示例#3
0
 def client_increment_points(self):
     self._get_increment_points()
     client_increment = self._get_increment_points()["client_increment"]
     shared_increment = {
         key: value/2 for key, value in self._get_increment_points()["shared_increment"].items()
     }
     return dict_sum(client_increment, shared_increment)
示例#4
0
文件: models.py 项目: suqi/taiga-back
 def future_team_increment(self):
     team_increment = self._get_points_increment(False, True)
     shared_increment = {
         key: value / 2
         for key, value in self.future_shared_increment.items()
     }
     return dict_sum(team_increment, shared_increment)
示例#5
0
 def client_increment_points(self):
     self._get_increment_points()
     client_increment = self._get_increment_points()["client_increment"]
     shared_increment = {
         key: value/2 for key, value in self._get_increment_points()["shared_increment"].items()
     }
     return dict_sum(client_increment, shared_increment)
示例#6
0
 def team_increment_points(self):
     team_increment = self._get_increment_points()["team_increment"]
     shared_increment = {
         key: value / 2
         for key, value in self._get_increment_points()
         ["shared_increment"].items()
     }
     return dict_sum(team_increment, shared_increment)
示例#7
0
 def _get_user_stories_points(self, user_stories):
     role_points = [us.role_points.all() for us in user_stories]
     flat_role_points = itertools.chain(*role_points)
     flat_role_dicts = map(lambda x: {x.role_id: x.points.value if x.points.value else 0}, flat_role_points)
     return dict_sum(*flat_role_dicts)
示例#8
0
 def team_increment_points(self):
     team_increment = self._get_increment_points()["team_increment"]
     shared_increment = {
         key: value/2 for key, value in self._get_increment_points()["shared_increment"].items()
     }
     return dict_sum(team_increment, shared_increment)
示例#9
0
 def future_client_increment(self):
     client_increment = self._get_points_increment(True, False)
     shared_increment = {key: value / 2 for key, value in self.future_shared_increment.items()}
     return dict_sum(client_increment, shared_increment)
示例#10
0
 def future_team_increment(self):
     team_increment = self._get_points_increment(False, True)
     shared_increment = {key: value / 2 for key, value in self.future_shared_increment.items()}
     return dict_sum(team_increment, shared_increment)
示例#11
0
 def closed_points(self):
     return dict_sum(*[ml.closed_points for ml in self.milestones.all()])
示例#12
0
 def closed_points(self):
     return dict_sum(*[ml.closed_points for ml in self.milestones.all()])