##// END OF EJS Templates
integrations: fixed missing template variable for fork reference checks.
marcink -
r3611:37100ede stable
parent child Browse files
Show More
@@ -67,12 +67,6 b' class RepoSettingsView(RepoAppView):'
67 67 .filter(UserFollowing.user_id == c.default_user_id) \
68 68 .filter(UserFollowing.follows_repository == self.db_repo).scalar()
69 69
70 c.has_origin_repo_read_perm = False
71 if self.db_repo.fork:
72 c.has_origin_repo_read_perm = h.HasRepoPermissionAny(
73 'repository.write', 'repository.read', 'repository.admin')(
74 self.db_repo.fork.repo_name, 'repo set as fork page')
75
76 70 c.ver_info_dict = self.rhodecode_vcs_repo.get_hooks_info()
77 71
78 72 return self._get_template_context(c)
@@ -114,7 +114,6 b' class IntegrationSettingsViewBase(BaseAp'
114 114 _ = self.request.translate
115 115 c = super(IntegrationSettingsViewBase, self)._get_local_tmpl_context(
116 116 include_app_defaults=include_app_defaults)
117
118 117 c.active = 'integrations'
119 118
120 119 return c
@@ -404,6 +403,11 b' class RepoIntegrationsView(IntegrationSe'
404 403 c.repo_name = self.db_repo.repo_name
405 404 c.repository_pull_requests = ScmModel().get_pull_requests(self.repo)
406 405
406 c.has_origin_repo_read_perm = False
407 if self.db_repo.fork:
408 c.has_origin_repo_read_perm = h.HasRepoPermissionAny(
409 'repository.write', 'repository.read', 'repository.admin')(
410 self.db_repo.fork.repo_name, 'summary fork link')
407 411 return c
408 412
409 413 @LoginRequired()
General Comments 0
You need to be logged in to leave comments. Login now