![]() |
#751 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Is Action Chain's Single-Field Edit able to use custom stored templates? I re-use certain templates a lot - but it's very easy to miss one when updating them.
|
![]() |
![]() |
![]() |
#752 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,199
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
Stored templates are part of the template language, so it should work.
|
![]() |
![]() |
Advert | |
|
![]() |
#753 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Hmm, I'm getting an error for it. Did I format it wrong? It works in template tester.
Code:
calibre, version 5.33.2 ERROR: Template Error: Running the template: program: columnupdate_kobocoll() returned an error: Formatter: Unknown function columnupdate_kobocoll near 'columnupdate_kobocoll' on line 1 |
![]() |
![]() |
![]() |
#754 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,199
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
That's odd. My own stored templates are working with no problems. Can you post your stored template to see if I can replicate?
|
![]() |
![]() |
![]() |
#755 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Named it columnupdate_kobocoll.
All three of the listed columns are taglikes; #genres and #vls are composites (former puiling from tags, latter using the virtual_libraries() function). Code:
program: g = field('#genres'); k = field('#kobocoll'); vl = field('#vls'); v = first_non_empty( list_contains(vl, ',', '^Loans$', 'Loans', ''), list_contains(g, ',', '^Fanfiction$', 'Fanfiction', ''), list_contains(g, ',', '^Horses$', 'Horses', ''), list_contains(g, ',', '^Cozy Mystery$', 'Cozy Mysteries', ''), list_contains(g, ',', '^(Fantasy|Science Fiction)$', 'Fantasy & Sci-Fi', ''), ); list_union(k, v, ',') Last edited by ownedbycats; 12-13-2021 at 06:49 AM. |
![]() |
![]() |
Advert | |
|
![]() |
#756 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,199
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
Does restarting calibre make any difference?
|
![]() |
![]() |
![]() |
#757 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Restarting Calibre worked. I actually noticed that some of my other custom functions were working and tried it just a minute or two before you posted.
![]() |
![]() |
![]() |
![]() |
#758 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,199
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
For now, whenever you create a new stored template, you will have to restart for it to work in Action Chains.
Last edited by capink; 12-13-2021 at 07:57 AM. |
![]() |
![]() |
![]() |
#759 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Would the issue also happen when a custom function is updated? Either breaking again or producing outdated results.
|
![]() |
![]() |
![]() |
#760 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,199
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
Unfortunately yes. I will examine this later today or tomorrow to see what can be done.
Edit: The problem is actually in the code of Action Chains not updating template functions. I will include a fix for this in the next version. Last edited by capink; 12-13-2021 at 07:59 AM. |
![]() |
![]() |
![]() |
#761 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Question: Can Action Chains be made to sort a specific column in a specific order?
The calibre action for "sort by" (see attached chain) tends to be a bit flaky for doing this; if it's the current sort, the menu entries change and break validation, and there's no way to define ascending/descending. Last edited by ownedbycats; 12-19-2021 at 12:20 PM. |
![]() |
![]() |
![]() |
#762 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,013
Karma: 500000
Join Date: Jun 2015
Device: Rocketbook, kobo aura h2o, kobo forma, kobo libra color
|
|
![]() |
![]() |
![]() |
#763 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Unfortunately, VM doesn't support only sorting; you need to select columns too.
![]() |
![]() |
![]() |
![]() |
#764 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,199
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
Quote:
|
|
![]() |
![]() |
![]() |
#765 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,035
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Thank you.
![]() |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Action Chains Resources | capink | Plugins | 78 | 08-05-2025 04:01 AM |
[Editor Plugin] Editor Chains | capink | Plugins | 106 | 06-17-2025 05:36 PM |
[GUI Plugin] Noosfere_util, a companion plugin to noosfere DB | lrpirlet | Plugins | 2 | 08-18-2022 03:15 PM |
[GUI Plugin] Save Virtual Libraries To Column (GUI) | chaley | Plugins | 14 | 04-04-2021 05:25 AM |