ModX Revo pdoResources step by step filtering - modx

I need to show similar products based on step by step TV filtration using pdoResources, e.g.
&tvFilters="product_grape==[[*product_grape]]"
and if there are no other products with same product_grape exists, than I need to switch to next filter using other condition e.g.
&tvFilters="product_type==[[*product_type]]".
I tried &tvFilters="product_grape==[[*product_grape]]||product_type==[[*product_type]]" but it didn't do the trick.

Actually, that was pretty easy:
[[*product_grapesort:is=``:then=`
&tvFilters=`product_type==%[[*product_type]]%`
`:else=`
&tvFilters=`product_grape==%[[*product_grape]]%`
`]]

Related

Creating a loop that runs through each item

a loop if purchaseid matches vendorid, If match set the sublistvalue of purchase cost else update with the new purchase cost, the loop should run through each an every item until the end
Sounds like you just need a for loop, running on the line count (there's not a lot of detail to your question, so that's just a guess).
You need to know when you want it to run, and the internal IDs for each of the sublists/fields that you are touching/referencing. Once you have that, you should be good. The SuiteScript docs are a great place to start. When logged into your NetSuite instance, click the Help link in the top right, and search for "SuiteScript 2.0 Modules".

Locating Work items which have comments addressed to me?

In Azure DevOps is possible to #Tag a user in the comments of a work item. Is it possible to query the items to find the work items which have comments which I am tagged in?
Write a query that does a Contains Words on History, then use "#display name"
Use the Work items page and select "Mentioned" from the dropdown.
URL would look like: https://dev.azure.com/*YOURORG*/*YOURPROJECT*/_workitems/mentioned/
Note that this also picks up mentions in other fields such as description, but I find this to be the easiest way.
"Work items" Page
Mentioned" dropdown
Note the number of comments. If there are no comments, then clearly you weren't mentioned in a comment.
Sort by "Mentioned Date". Latest occurrence by default.
You can make a custom query just setting the ID in #RecentMentions like this:

Kentico cms.file publish date

I've got a simple repeater that list links to uploaded documents using cms.file. I'm drawing a blank on adjust the ORDER BY based on publish date. I can't find anything here on this, so i apologize if this is a duplicate.
Best practice is to add custom field to page type (in this case cms.file or better create the new one) and set ORDER BY condition to this new field. There are also properties like DocumentModifiedWhen, DocumentCreatedWhen, DocumentCheckedOutWhen you can use.
I'm going to use DocumentModifiedWhen as the ORDER By statement.
There are two fields [DocumentPublishTo] and [DocumentPublishFrom] that you can think of using. These are the two fields which appear at the bottom of each form page by default.

Sort articles by template variable

I have built a website (with MODX) where some products are managed and displayed via the articles addon. The products should have a custom ordering but I don't know how to use a template variable for that.
If I enter the name of the TV in the "Sort Field" field nothing is shown at all.
So is it somehow possible to use a TV there?
Or is there another way to achive a custom ordering (note that I need the summary and date fields, so I cant't abuse them for that)?
You can do this by using getResource package. Look at sorbyTV, sortdirTV, sortbyTVType parameters in manual:
http://rtfm.modx.com/extras/revo/getresources#getResources-SelectionProperties

Maximo workflow task node actions

I'm wanting to modify an existing workflow in workflow designer to give 3 routing options for a user instead of 2. It says that a task node can only have one positive and one negative line. What's the work-around for this?
I don't think an action group would work since I want 3 different 'To node's
Thanks
I'm away from a system to confirm, but I believe you are looking for a "Manual Input Node". I think that one will present any number of options to the user. The options will be based on the label of the lines coming out of the node and workflow will follow the path of the line the user picks.

Resources