vscode icon indicating copy to clipboard operation
vscode copied to clipboard

Feature Request - "Drop Document" option in context menu

Open jcgerhard opened this issue 5 years ago • 3 comments

Feature Request

Having a "Drop Document" option in a documents' context menu

Detailed Description

To get a more fluent way of working with a mongo instance, it would be nice to have this additional option in the mouse context menu of a document entry. I oftentimes need to drop/delete documents while working on a collection. This feature would make it way more easy to do this.

Context

I have been working with the extension solely for a few weeks now. I really love it beacause there is no need to left VS Code to work on a database anymore. I would like to replace my mongodb client completely with this extension. This feature would make it way more comfortable to use while working the hole day with it.

Possible Implementation

mongo-vscode-document-drop

jcgerhard avatar Jul 08 '20 12:07 jcgerhard

Could you please create a feature request in our feedback forum?

alenakhineika avatar Jul 21 '21 13:07 alenakhineika

I'd probably call it "Delete Document…" instead of "Drop Document" to match how MongoDB refers to deleting documents in the documentation.

I'm not sure what the best UX is, but probably best to add an "Are you sure?" prompt somehow where it shows the user the document, and they have to click y or click "Yes" in a prompt. Opinions welcome!

Just keeping this here for reference: https://www.mongodb.com/docs/manual/tutorial/remove-documents/

SethFalco avatar May 28 '22 18:05 SethFalco

This feature looks critical to me. I have no idea of how to delete documents using the extension, without doing it with a playground. Am I missing something?

santiagopuentep avatar Aug 24 '22 05:08 santiagopuentep

@jcgerhard @santiagopuentep We've added document actions in the new 0.10.0 release. Thanks for opening the issue and the good writeup! https://github.com/mongodb-js/vscode/releases

Anemy avatar Jan 12 '23 18:01 Anemy

That's great! I thought this project has died. I will test it. Keep up!

jcgerhard avatar Jan 13 '23 07:01 jcgerhard

I tried it and it's not working. There's not even context menu when right clicking on a document.

santiagopuentep avatar Jan 13 '23 14:01 santiagopuentep

@santiagopuentep Are you sure you're using the most up to date version of the extension? 0.10.0? The extension auto update in VSCode can take a bit to update. You might have to restart VSCode. Here's what right clicking a document should look like: Screen Shot 2023-01-13 at 10 22 39 AM

Anemy avatar Jan 13 '23 15:01 Anemy

@Anemy Yes, I have 0.1.0, and I had restarted VSCode, but now I restarted it again just in case and now it works. Thanks.

santiagopuentep avatar Jan 13 '23 18:01 santiagopuentep