I set up the following Content Definition in an Orchard 1.9.1 site:
Manufacturer
- Logo (Media Library Picker Field)
- Container (single supported type - Product)
Product
- Containable
- [Generic Fields]
I added a few sample Product items to the site, and as part of that it had me select the Member Of option, which was a list of Manufacturer items I had already added.
The issue I have is, when I try to build a query to use with a projection widget, I can't seem to find a way to get either a Manufacturer's children, or a Product's parent container since I need to display all content on a single view. There are only going to be ~20 line items here, so performance is a non-issue. If I do multiple queries (one for each type), everything shows up individually but the Shape Tracing tool, when showing me the various Model items on the view, can't seem to show me either of these options.
My end goal is building a custom view to display this information, but I can't figure out how to traverse either up the Product to what its' parent container is, or traverse down from a Manufacturer to the child Product items below it.
How do I build a query that lets me see all of this so I can build a projection widget off of that?
Edit
I played with this some more and came across the ability to take a query and attach a layout to it. That is definitely getting me closer, however the grouping option says No properties are currently available in order to group this view, however I would think being part of a container/containable would define grouping automatically. As it stands, this lets me show everything, but unfortunately the parent/child show, and then the children repeat again, independent of the parent. It's so close, but I can't quite get it right.
Related
I'm trying to create a flat view that shows all documents in a list without folders, but I can't figure out how to get for each document the columns of the parent folder.
We have to keep the folders system, but be able to use filters on this view.
View screenshot with folders
View Screenshot without folders, where I need to get the folder columns
I think this is a misunderstanding of the columns behavior, in fact you are displaying the same columns in both views (except for Modified, Index, ISO Language), however I assume what you really want is to display the same Field Values of the parent folder for each child item, that kind of behavior (values inheritance between folders and child items) isn't possible by just editing the view neither by applying some list settings.
First of all you need to understand that list items, documents and folders are all list items from the system perspective so they have individual properties for each one of them, a folder is just a special type of item that is able to contain other items (strictly speaking is just simulating a container).
In your case the Field Values that are being displayed in the columns of the folders view are values that belong to the folder itself but not to his child items. If you want to propagate those field values for the child items of each folder then you have two options:
Manually: Assign the values to each child item by editing their
properties using the Edit Form or using a Grid View to edit multiple
items faster.
Automatically: Create a Workflow or Event Receiver to copy the values
of the parent folder to each new item/document that is added to the
list/library.
However, as I can see your library is not being used in production yet, so my personal recommendation is to change your approach and use something similar to a Managed Metadata term store instead of folders (folders should be your last option to categorize items/documents, just for cases when you really don't have another way to achieve your goal), with the Managed Metadata approach you are able to apply tags to the items allowing them to belong to multiple categories and being filtered and searched more efficiently, but I know what you may be thinking "how can I do this if the Managed Metadata Service is not available in SharePoint Foundation", well thats why I said "use something similar", there should be more than one third party solution out there that will provide a similar functionality, but if you want to choose the less effort path, just use out-of-the-box Multi-choice field or Multi-lookup field, that you can start to using right now and assign the categories that you want to your items and create different views and filter them.
To achieve this you need to create a new view, or modify an already existing one, in your library.
When you edit or create a new view you are presented with the "Edit view" screen, here you can choose to "Show all files without folders" in the "Folders" section.
See e.g. for more details http://www.bloggedbychris.com/2013/10/19/flatten-document-library-list-sharepoint-2013-2010/ on this particular problem.
I'm exploring Nwazet.Commerce module and I've managed to replicate most of what http://nwazet.com/ does ... However I'm struggling with projection widget that displays product categorization (on nwazet.com page one to the right that has Automation, Cables & Connections, ...).
I assume these are terms for a taxonomy? How should I set projection query to get this list of terms from a single taxonomy? When I tried "Content with type CategoryTerm" it lists not just terms but also products that have them.
Thanks for any pointers.
You got it exactly right: the categories are taxonomy terms. The problem is very likely that you are displaying the terms in the projection query layout with the full detail view, where the term will display the list of items under itself. Instead, you could use a summary or a custom display type in your layout, and customize the template alternate for that display type. Alternatively, and this is how the site is set-up, you can switch to property mode for the layout and just keep it to a simple display text property with "link to the item" checked.
Some additional info: for perf, I add an eager fetch filter on Autoroute and Title part records.
I tried using smart image in multi composite field. In that the images are getting persisted, the remaining fields in the multi composite fields are not getting persisted. when i edited the dialog for the first time the values are getting stored on the node. when i edit the dialog next time it is showing me empty fields for the fields other than smart image.
This won't work. SmartImage and SmartFile have some restrictions to them. And there are two different versions: SmartImage and SmartFile vs. Html5SmartImage and Html5SmartFile. Depending on your actual Version of CQ it is even only possible to have the smartimage as a separate tab without any other fields. On top of that the behaviour for the different browser and versions together with the configuration of your SmartImage have different outcomes in JCR. This is even true for AEM 5.6.1 and the Html5 versions of the the xtype.
I can't post the full solution (as the code is not mine) but give some pointers how you could achieve your requirement:
Write your own Widget that replaces the multifield xtype. The author called it genericmultifield and what it does is to open an additional configurable dialog for each item. In this dialog you have the full controll again. It stores each item as a separate node below your resource from where you open your main dialog.
Though you need good ExtJs knowledge to achieve this and considering AEM 6, with a complete new Touch UI I am not sure if it is wise to do so. I didn't have time to check out AEM6, but maybe they already have something like this in their new UI.
Currently, the site search will search all of the skus of the items marked as being visible in search. This is all well and good.
The problem arises when the customer knows a sku of the individual child item. So, let's say a product comes in both a 20 foot and 25 foot variation. We would put those into a configurable product and have a single product page where a customer could then choose which of those two lengths.
What happens is, a customer invariably knows that the sku of the 20 ft variation is RDB-20, while the other is RDB-25. A search for RDB-25 then, comes back with no results since the simple product is not visible in search - it doesn't realize there is a match.
How do I get the search to search an item with visibility "Not Visible Individually", when it's parent is visible in search?
The desired effect is that, if a child SKU is searched for, the parent should show up in the results.
There really is no good way of doing it without extending the default search, but at that point you might as well look for other options.
Here's a workaround that might be doable depending on how you manage your products and it worked for me until I moved on from the default search.
Rather than altering the search, try adding an attribute to all products and make it hidden concatenating all the skus into this field. The search should find the text attribute and show the configurable.
Its a bit of a workaround but works for me.
This is untested, but I did a bit of perusing in our attributes and I think I found something that might help.
Currently since our child products don't show up in our search, we have the parent populate with the children product's attributes.
However, things like brand, taxable amount, description, populate for every child product while our SKU does not.
The only difference I can see between the two attributes is under manage attributes -> click on attribute -> and then under properties go to frontend properties and select
Use In Search Results Layered Navigation: YES
Used in Product Listing: YES
Use In Layered Navigation: Filterable (with results)
I'm not sure which of these do what, but in the population of the fulltext search data table, somewhere it is being told to populate for the children and I believe that the admin panel is where.
I hope this helps!
Lets say for example, I have a list of products that each have it's own page... in what way can I create a single page that will list each product as it's contents as a list (with hyperlinks)? Not really sure how to do this directly in Orchard - or will I need to create a custom page / widget? Thanks for any help... new to Orchard and not sure how to tackle this.
You have a couple options. I believe the Orchard gallery at orchardproject.net has a module called Simple Commerce that may solve your problem. (it's simple so it might not)
(In the following section, I've tried to boldface the terminology words that are 1) are crucial to understanding how to use Orchard and 2) helpful in finding your way around the dashboard)
Another option may be first creating a Content Type--probably one named Product with some Fields describing an individual product. Price, SKU and description come to mind, but you'll be better able to describe your own products. Each Content Type in Orchard can be associated with any combination of Parts. You may have to research which ones you actually want for an individual product, but I'd recommend:
Body (this could replace the Description I suggested above) You could include any amount of HTML/script in this section to make your individual product pages look fancy!
Common (this has to be added when Containable is used)
Containable (this will allow the items to be listed)
Route (so you can link to a specific product)
This gives each product its own slug (URL)
Tags (to allow products to be categorized)
Now, you need to create a new List from the dashboard so you can display the products together (and inherit other features like pagination, etc). Be sure to select the Product Content Type in the Contains drop down list.
Then, you can start creating your Content (your Products) one by one. In the dashboard, click the new Product item and describe each new piece of Content.
Finally, you can link directly to this new List using the Products List's *slug*. You could (and might want to) add the Products List to your main navigation menu. Clicking the Products List and checking the "Show on main menu" box will automagically add a navigation button directly to this page. You could, of course, link to this List from anywhere using the slug (also found on the list's edit page)
This page, from the Orchard documentation pages describes more things you can do with a list of content like modifying the layout of the list, placing content fields in different places and even converting your products to widgets which you could use to display some promotional product offering in a special spot on your site.
I highly recommend reading through at least the documentation provided on the Orchard site to get a good grasp of what this CMS can do out of the box and what you would need to write custom code to accomplish (which you could do in this case, but Orchard can handle it out of the box)
Hope this helps!
Two ways to do this:
http://orchardproject.net/docs/Creating-lists.ashx and http://orchardproject.net/gallery/List/Modules/Orchard.Module.Contrib.Taxonomies