Commits

Marcin Kuzminski  committed ef75203

fixed missing div on my_account + added nothing here yet when there are no
pull requests for user

  • Participants
  • Parent commits 36915dd

Comments (0)

Files changed (4)

File rhodecode/public/css/style.css

     margin-bottom: 0;
     margin-top: 5px;
 }
+
+.empty_data{
+    color:#B9B9B9;	
+}
+
 a.permalink{
 	visibility: hidden;
 }

File rhodecode/templates/admin/users/user_edit.html

            %for section in sorted(c.perm_user.permissions.keys()):
               <div class="perms_section_head">${section.replace("_"," ").capitalize()}</div>
               %if not c.perm_user.permissions[section]:
-                  <span style="color:#B9B9B9">${_('Nothing here yet')}</span>
+                  <span class="empty_data">${_('Nothing here yet')}</span>
               %else:
               <div id='tbl_list_wrap_${section}' class="yui-skin-sam">
                <table id="tbl_list_${section}">

File rhodecode/templates/admin/users/user_edit_my_account.html

     </div>
     <div id="my" class="table" style="display:none">
     </div>
-    <div id="pullrequests" class="table" style="display:none">
+    <div id="pullrequests" class="table" style="display:none"></div>
 </div>
+
+
+
 <script type="text/javascript">
 var filter_activate = function(){
     var nodes = YUQ('#my tr td a.repo_name');

File rhodecode/templates/admin/users/user_edit_my_account_pullrequests.html

 
 <div class="pullrequests_section_head">${_('Opened by me')}</div>
 <ul>
-    %for pull_request in c.my_pull_requests:
-    <li>
-    <a href="${h.url('pullrequest_show',repo_name=pull_request.other_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">
-    ${_('Pull request #%s opened on %s') % (pull_request.pull_request_id, h.fmt_date(pull_request.created_on))}
-    </a>
-    </li>
-    %endfor
+    %if c.my_pull_requests:
+      %for pull_request in c.my_pull_requests:
+      <li>
+      <a href="${h.url('pullrequest_show',repo_name=pull_request.other_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">
+      ${_('Pull request #%s opened on %s') % (pull_request.pull_request_id, h.fmt_date(pull_request.created_on))}
+      </a>
+      </li>
+      %endfor
+   %else:
+    <li><span class="empty_data">${_('Nothing here yet')}</span></li>
+   %endif
 </ul>
 
 <div class="pullrequests_section_head">${_('I participate in')}</div>
 <ul>
-    %for pull_request in c.participate_in_pull_requests:
-    <li>
-    <a href="${h.url('pullrequest_show',repo_name=pull_request.other_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">
-    ${_('Pull request #%s opened by %s on %s') % (pull_request.pull_request_id, pull_request.author.full_name, h.fmt_date(pull_request.created_on))}
-    </a>
-    </li>
-    %endfor
+    %if c.my_pull_requests:
+      %for pull_request in c.participate_in_pull_requests:
+      <li>
+      <a href="${h.url('pullrequest_show',repo_name=pull_request.other_repo.repo_name,pull_request_id=pull_request.pull_request_id)}">
+      ${_('Pull request #%s opened by %s on %s') % (pull_request.pull_request_id, pull_request.author.full_name, h.fmt_date(pull_request.created_on))}
+      </a>
+      </li>
+      %endfor
+    %else:
+     <li><span class="empty_data">${_('Nothing here yet')}</span></li>
+    %endif
 </ul>