Changeset - 99997d8f31eb
[Not reviewed]
default
1 4 0
Mads Kiilerich - 12 years ago 2013-06-14 16:28:38
madski@unity3d.com
pull requests: remove old 'my pull requests' code from the secret place under 'My Account'
5 files changed with 0 insertions and 97 deletions:
0 comments (0 inline, 0 general)
kallithea/config/routing.py
Show inline comments
 
@@ -367,9 +367,6 @@ def make_map(config):
 
        m.connect("my_account_watched", "/my_account/watched",
 
                  action="my_account_watched", conditions=dict(method=["GET"]))
 

	
 
        m.connect("my_account_pullrequests", "/my_account/pull_requests",
 
                  action="my_account_pullrequests", conditions=dict(method=["GET"]))
 

	
 
        m.connect("my_account_perms", "/my_account/perms",
 
                  action="my_account_perms", conditions=dict(method=["GET"]))
 

	
kallithea/controllers/admin/my_account.py
Show inline comments
 
@@ -230,27 +230,6 @@ class MyAccountController(BaseController
 
        h.flash(_("Removed email from user"), category='success')
 
        return redirect(url('my_account_emails'))
 

	
 
    def my_account_pullrequests(self):
 
        c.active = 'pullrequests'
 
        self.__load_data()
 
        c.show_closed = request.GET.get('pr_show_closed')
 

	
 
        def _filter(pr):
 
            s = sorted(pr, key=lambda o: o.created_on, reverse=True)
 
            if not c.show_closed:
 
                s = filter(lambda p: p.status != PullRequest.STATUS_CLOSED, s)
 
            return s
 

	
 
        c.my_pull_requests = _filter(PullRequest.query()\
 
                                .filter(PullRequest.user_id ==
 
                                        self.authuser.user_id)\
 
                                .all())
 
        my_prs = [x.pull_request for x in PullRequestReviewers.query()
 
                    .filter(PullRequestReviewers.user_id ==
 
                        self.authuser.user_id).all()]
 
        c.participate_in_pull_requests = _filter(my_prs)
 
        return render('admin/my_account/my_account.html')
 

	
 
    def my_account_api_keys(self):
 
        c.active = 'api_keys'
 
        self.__load_data()
kallithea/templates/admin/my_account/my_account.html
Show inline comments
 
@@ -41,7 +41,6 @@
 
          <li class="${'active' if c.active=='emails' else ''}"><a href="${h.url('my_account_emails')}">${_('My Emails')}</a></li>
 
          <li class="${'active' if c.active=='repos' else ''}"><a href="${h.url('my_account_repos')}">${_('My Repositories')}</a></li>
 
          <li class="${'active' if c.active=='watched' else ''}"><a href="${h.url('my_account_watched')}">${_('Watched')}</a></li>
 
          <li class="${'active' if c.active=='pullrequests' else ''}"><a href="${h.url('my_account_pullrequests')}">${_('Pull requests')}</a></li>
 
          <li class="${'active' if c.active=='perms' else ''}"><a href="${h.url('my_account_perms')}">${_('My permissions')}</a></li>
 
        </ul>
 
    </div>
kallithea/templates/admin/my_account/my_account_pullrequests.html
Show inline comments
 
deleted file
kallithea/tests/functional/test_my_account.py
Show inline comments
 
@@ -40,12 +40,6 @@ class TestMyAccountController(TestContro
 
                            User.get_by_username(TEST_USER_ADMIN_LOGIN)).count()
 
        response.mustcontain('"totalRecords": %s' % cnt)
 

	
 
    def test_my_account_my_pullrequests(self):
 
        self.log_user()
 
        response = self.app.get(url('my_account_pullrequests'))
 

	
 
        response.mustcontain('Nothing here yet')
 

	
 
    def test_my_account_my_emails(self):
 
        self.log_user()
 
        response = self.app.get(url('my_account_emails'))
0 comments (0 inline, 0 general)