You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What I am trying to do is to make the dataview tables editable in my vault using the metadata menu plugin but after searching I realised that I can only do this if I rewrite these tables again in dataviewjs but unfortunately I don’t have much experience in JavaScript but I did manage to do this but I have a query that I couldn’t convert which is:
TABLE WITHOUT ID
regexreplace(regexreplace(regexreplace(regexreplace(regexreplace(Tasks.text, "\d{2}:\d{2}\s*", ""), "[APap][Mm]", ""), "\[.*$", ""), "\-",""),"\*","") as task,
meta(Tasks.section).subpath as "Status",
file.link as "Board",
Tasks.Scheduled As "Scheduled", Tasks.duration As "Duration"
from #Task-Board
FLATTEN file.tasks As Tasks
WHERE contains(Tasks.text, "<% moment(tp.file.title,'YYYY-[W]ww').format("YYYY-MM-DD")%>") OR
contains(Tasks.text, "<% moment(tp.file.title,'YYYY-[W]ww').add(+1, 'day').format("YYYY-MM-DD")%>") OR
contains(Tasks.text, "<% moment(tp.file.title,'YYYY-[W]ww').add(+2, 'day').format("YYYY-MM-DD")%>") OR
contains(Tasks.text, "<% moment(tp.file.title,'YYYY-[W]ww').add(+3, 'day').format("YYYY-MM-DD")%>") OR
contains(Tasks.text, "<% moment(tp.file.title,'YYYY-[W]ww').add(+4, 'day').format("YYYY-MM-DD")%>") OR
contains(Tasks.text, "<% moment(tp.file.title,'YYYY-[W]ww').add(+5, 'day').format("YYYY-MM-DD")%>") OR
contains(Tasks.text, "<% moment(tp.file.title,'YYYY-[W]ww').add(+6, 'day').format("YYYY-MM-DD")%>")
SORT date(Tasks.due.file.name)
I am using this query to view tasks from kanban boards in my weekly note and
I use many regexreplace to remove information from the task and show only its name and the tasks format is:
HH:MM A - HH:MM A
(The Task)
[ scheduled : YYYY-MM-DD] [duration: (duration ) ] # (project name)
another task like the one above it
and you can use this information to make the regex in dataviewjs if possible.
so can you help me rewrite this query in dataviewjs?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
What I’m trying to do
What I am trying to do is to make the dataview tables editable in my vault using the metadata menu plugin but after searching I realised that I can only do this if I rewrite these tables again in dataviewjs but unfortunately I don’t have much experience in JavaScript but I did manage to do this but I have a query that I couldn’t convert which is:
I am using this query to view tasks from kanban boards in my weekly note and
I use many regexreplace to remove information from the task and show only its name and the tasks format is:
HH:MM A - HH:MM A
(The Task)
[ scheduled : YYYY-MM-DD] [duration: (duration ) ] # (project name)
another task like the one above it
and you can use this information to make the regex in dataviewjs if possible.
so can you help me rewrite this query in dataviewjs?
Beta Was this translation helpful? Give feedback.
All reactions