You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by robertkowalski <gi...@git.apache.org> on 2016/03/15 17:44:51 UTC

[GitHub] couchdb-fauxton pull request: Improvements for table view

GitHub user robertkowalski opened a pull request:

    https://github.com/apache/couchdb-fauxton/pull/667

    Improvements for table view

     - show conflicts / conflict-count in table-view
     - remember if table or json view is selected, even after a refresh
    
    
    to create a conflict for the document `elephant` in `animaldb` use the `new_edits=false` parameter with a random rev:
    
    ```
    curl -XPUT http://localhost:8000/animaldb/elephant?new_edits=false -d '{"_rev":"4-afae890a0310210db079b0f49fb2569d","foo":"bar"}' -H 'Content-Type: application/json'
    ```

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/robertkowalski/couchdb-fauxton table-conflict

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/couchdb-fauxton/pull/667.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #667
    
----
commit 25ea97765b0e85597deff02d9a53dacd52a9476f
Author: Robert Kowalski <ro...@apache.org>
Date:   2016-03-15T14:37:37Z

    show conflicts / conflict-count in table-view

commit 3bfc16a4c0557807fc87593b6b797f279829b66d
Author: Robert Kowalski <ro...@apache.org>
Date:   2016-03-15T16:29:08Z

    persist setting for view type
    
    remember if table or json view is selected, even after a refresh
    
    this closes COUCHDB-2967

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-fauxton pull request: Improvements for table view

Posted by robertkowalski <gi...@git.apache.org>.
Github user robertkowalski commented on the pull request:

    https://github.com/apache/couchdb-fauxton/pull/667#issuecomment-205828293
  
    @benkeen did you enable `include_docs`?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-fauxton pull request: Improvements for table view

Posted by benkeen <gi...@git.apache.org>.
Github user benkeen commented on the pull request:

    https://github.com/apache/couchdb-fauxton/pull/667#issuecomment-205888624
  
    Nice! +1


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-fauxton pull request: Improvements for table view

Posted by robertkowalski <gi...@git.apache.org>.
Github user robertkowalski closed the pull request at:

    https://github.com/apache/couchdb-fauxton/pull/667


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-fauxton pull request: Improvements for table view

Posted by benkeen <gi...@git.apache.org>.
Github user benkeen commented on a diff in the pull request:

    https://github.com/apache/couchdb-fauxton/pull/667#discussion_r58572618
  
    --- Diff: app/addons/documents/index-results/index-results.components.react.jsx ---
    @@ -126,21 +126,40 @@ function (app, FauxtonAPI, React, Stores, Actions, Components, Documents, Fauxto
           );
         },
     
    -    getAttachmentRow: function (el) {
    +    getAdditionalInfoRow: function (el) {
           var attachmentCount = Object.keys(el._attachments || {}).length;
    -      var paperClip = null;
    -      var text = null;
    +      var attachmentIndicator = null;
    +      var textAttachments = null;
    +
    +      var conflictCount = Object.keys(el._conflicts || {}).length;
    +      var conflictIndicator = null;
    +      var textConflicts = null;
    +
     
           if (attachmentCount) {
    -        text = attachmentCount === 1 ? attachmentCount + ' Attachment' : attachmentCount + ' Attachments';
    -        paperClip = (
    -          <div><i className="icon fonticon-paperclip"></i> {attachmentCount}</div>
    +        textAttachments = attachmentCount === 1 ? attachmentCount + ' Attachment' : attachmentCount + ' Attachments';
    +        attachmentIndicator = (
    +          <div style={{display: 'inline', marginLeft: '5px'}} title={textAttachments}>
    +            <i className="icon fonticon-paperclip"></i>{attachmentCount}
    +          </div>
    +        );
    +      }
    +
    +      if (conflictCount) {
    +        textConflicts = conflictCount === 1 ? conflictCount + ' Conflict' : conflictCount + ' Conflicts';
    +        conflictIndicator = (
    +          <div className="tableview-conflict" data-conflicts-indicator style={{display: 'inline'}} title={textConflicts}>
    --- End diff --
    
    Might be nice to explicitly set `data-conflicts-indicator="true"`. I didn't know `.table [data-conflicts-indicator="true"]` would match this. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-fauxton pull request: Improvements for table view

Posted by benkeen <gi...@git.apache.org>.
Github user benkeen commented on the pull request:

    https://github.com/apache/couchdb-fauxton/pull/667#issuecomment-204008207
  
    I ran that command but don't see any new addition in the table view content for that DB. How new is that feature? Do I need to update couch?
    



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-fauxton pull request: Improvements for table view

Posted by robertkowalski <gi...@git.apache.org>.
Github user robertkowalski commented on the pull request:

    https://github.com/apache/couchdb-fauxton/pull/667#issuecomment-212366442
  
    superseded by #670


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---