QuickAdd Plugin

EDIT:

I figured this out and wanted to clarify it for others.

Solution is to use the format {{DATE+-1}}, and not use {{DATE±1}}.

ORIGINAL MESSAGE:

Are you requesting a feature, or does this work for you?

I just updated to the latest QuickAdd version and what you seem to indicate works for you doesn’t work for me. The choices I get are:

  • YYYY-MM-DD (today)
  • {{DATE±1

If I select the 2nd choice, the following is appended in my file:

{{DATE±1,{{DATE±2}},{{DATE±3}}}}

If this does work for you, can you provide any additional details?

[FEATURE REQUEST] Suggestions from existing field values for {{VALUE}} or suggester (API) ?

Problem description

Often, I use {{VALUE}} or the suggester (from QuickAdd API) to complete a field in a note (e.g. : type::). It would be really useful if {{VALUE}} or the suggester could automatically retrieve the possible values for the field (either from all the notes or a chosen subset of notes) and suggest them.


Github link : [FEATURE REQUEST] Suggestions from existing field values for {{VALUE}} or suggester (API) ? · Issue #337 · chhoumann/quickadd · GitHub

Same here

Looking for a solution for this as well! Sometimes I don’t need a reminder and would like to just press enter and have it skip that particular prompt in QuickAdd and go to the next one. Also, Is there a way to order prompts? Mine seem to come in a nonsequential order.

1 Like

Is it possible to have a workflow taking showing a suggester with all projects (files with a certain tag) and adding a kanban item to a the Backlog column (or select which column each time)? I couldn’t really figure out how to adapt the move files with tag workflow to do that.

@Christian

Hi All,

I am trying to write a quickadd macro to save a progress timeline. The number itself is obtained (and shown in the note) using dataview. I’ve written the macro to push such value and the timestamp to the frontmatter using quickadd and metaedit, though, I don’t know how to do that in the macro context instead of the dataviewjs scope, ie, getting the list of tasks objects from the macro itself.

I think it might not be hard with the proper imports as the quickadd API exposes the app, but I’m not a js dev myself. So, how’d you import and use dataview from a quickadd js macro?

Thanks !

This is somehow related to my question above. I think if you manage to use dataviewjs from within the macro js code, then you could use it to query and push them to a suggester

… my two cents

Hey everyone! I was really hoping QuickAdd to do something that turned out harder than I imagined. I want to send/capture some text to another note but I don’t want to be constrained by a list of options. The only way I’ve found to do this is using {{value}}, but I’d have to input the entire file path so that QuickAdd can find it. Is there a way to make the prompt asking for the file name be a Quick Switcher prompt, or at least any kind of search?
Alternatively, could it at least look for a file with the name I’ve given it?

Hi,

Are you familiar with the QuickAdd API?

The suggester should work for such use case as

const pickedFile = await params.quickAddApi.suggester(
    (file) => file.basename,
    params.app.vault.getMarkdownFiles()
);
1 Like

Hi!
No, unfortunately I’m not familiar with JS or with handling API’s. However, I found a simpler solution: write the text, then use the extract text command from the note refactor core plugin. Another more advanced way someone guided me to is to use the Text Transporter plugin which is basically made for this kind of application. Thanks for your help though! :smiley:

1 Like

Brilliant plugin.

When using QuickAdd to create a new note for a movie is there a way to make the note active in the editor? At the moment, the note is created in the right folder but it doesn’t appear in the main window ready for editing.

And if a script downloads a date in one format, can it automatically be reformatted? For example, {{VALUE:Released}} downloads in DD-MM-YYYY format, but can it automatically be changed to YYYY-MM-DD-dddd?

Thanks for any tips.

In the instructions as described here: Create a movie database - Minimal Documentation
7.4 within ‘Step 3. Create a macro in QuickAdd’ is where you can set the QuickAdd option to open the newly created file.

To get there and amend your current setup:

  • From QuickAdd setting:
  • Click Manage Macros
  • Click Configure (be sure to pick the right one if you’ve more than one)
  • Then click the settings cog next to (probably step two): Movie Template (yours may be named differently)
  • Scroll down and enable ‘Open the created file’

As for changing the release date format… I’d love to do that too but have so far failed!

1 Like

How did I miss that in the instructions? Thank you so much for the detailed and clear reply. Works perfectly now.

I had seen your post about the date issue and spent a couple of hours trying to find a solution. Thought I would add it to this thread (1) for my own use, and (2) in the hope that it might be seen in a different thread and get an answer. If I ever work it out, I will be sure to share.

Thanks again.

The Create a Movie database thing is great, isn’t it? I’ve created a whole set of files and menus and, using Dataview got lots of different ways to view films: by my rating, release date, out now, the date I watched, showings I’ve booked etc.

To get around the release date issue, I’ve added a second release date field to my template and have dataview view showing where ‘my’ release date is blank: using this view a bit like an inbox. I then add the date myself in the format I want. It’s helpful to manually do it as the release date from IMDb doesn’t always tally with more local release dates. It’s less onerous than it sounds as now I’ve got a settled system, I usually only 1 or 2 films at a time.

1 Like

Yep, totally agree.

Am also using a second field for the release date and updating it manually. Would be soooooo good to automate it though. One day …

Folks,

I asked a question here on how to be able to request a single date/time from the user and then apply it or parts of it in deference places using QuickAdd and its variable support. I think the (clunky) solution I found may help some people. Follwoing is a file template I use for a Capture:

---
title: {{VALUE}}
allDay: false
scheduled: {{VDATE:Scheduled, YYYY-MM-DDTHH:MM}}
date: <% tp.date.now("YYYY-MM-DD", 0, "{{VALUE:Scheduled}}", "YYYY-MM-DDTHH:MM") %>
startTime: <% tp.date.now("HH:MM", 0, "{{VALUE:Scheduled}}", "YYYY-MM-DDTHH:MM") %>
endTime: <% (Number(tp.date.now("HH", 0, "{{VALUE:Scheduled}}", "YYYY-MM-DDTHH:MM")) + 1).toString() + ":00" %>
completed: null
---

So here the user is asked to for date/time to schedule an event for the Full Calendar plugin, and the date part is used for the date field, the time part is used for the startTime field, and the endTime is calculated as the startTime + 1 (numbers treated as numbers, not dates).

Some folks might find it useful, perhaps, and, even better, maybe some folks can improve this!

1 Like

Hi everyone!

i was wondering if there’s a supported way to create a template choice, that instead of using the current date in the title, it uses the date from the filename of the active note/ parent note/ the note in which the template is triggered

Loved using the capture choice so far, i was wondering if this can be done in the templates too, or if its possible via script using the API, i tried script in macros but yielded 0 success in terms of changing the templates filename

I was wondering if anyone or @Christian can help me shedding some light on this

Hi @Christian , first - thank you for this plugin! I am wondering if there is a way to use a macro that first prompts the quick switcher and only if file needs to be created, then to trigger the folder that asks which template. Only because I ave lost track of what notes I have and need to be using the search a lot more. Is there a way to do this in macro?

@Nevertheless I have used templaters: <%moment(tp.file.title,‘YYYY-MM-DD’) %> to use the current file’s date. But not sure if that is what you meant?

Hello everyone! Is it possible to use images in a suggester? I am trying something like this:

	var questions = [];
	var answers = [];
	for(var i = 0; i < books.length; i+=1){
		questions[i]="<span>" + books[i][0] + "</span><img src=\"" + books[i][1] + ">";
		answers[i]=i+1;
	}
	
	const choice = await QuickAdd.quickAddApi.suggester( questions, answers );

where books[][0] has the title, books[][1] a link to the cover, but the html is not rendered. Probably the default suggester is only displaying text.

I am trying to make a macro similar to the imdb example. The problem with books is that there are several editions with the same author and title, I was hoping to select them by cover, because the cover differs.

1 Like