Skip to content

Truncate note name and point to the original note link #426

Answered by wenlzhang
wenlzhang asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for the suggestion. To figure out what has happened, I did the following tests, but did not find out why.

  1. Test 1: Print out all related pages with the field film-genre included and no empty film-genre exists.
  2. Test 2: Include explicitly all desired film-genre in the where part, to filter out (potential) empty film-genre.

The code for the second case looks like the following:

for (let group of dv.pages("#NoteDataview").groupBy(p => p["film-genre"])) {
    dv.header(3, group.key);
    dv.table(["Name", "Rating", "Watched"],
        group.rows
	    .where(k => "film-rating" in k && (k["film-genre"] == "Genre1" || k["film-genre"] == "Genre2"))
            .sort(k => k["film-rating"], …

Replies: 2 comments 8 replies

Comment options

You must be logged in to vote
3 replies
@wenlzhang
Comment options

@wenlzhang
Comment options

@blacksmithgu
Comment options

Comment options

You must be logged in to vote
5 replies
@wenlzhang
Comment options

@blacksmithgu
Comment options

@wenlzhang
Comment options

@blacksmithgu
Comment options

@wenlzhang
Comment options

Answer selected by M-bot
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants