add Menu type for Virtue Mart component in Joomla - joomla1.5

I installed VM manually and the menu type is missing from the list. How can i add this manually. I understand i have to use views but i don't have a views folder for the component.Do i need to create a view for it if so how do i need to go about it.

Look in the jos_components table and see if you have a record for VM. If not, then use this -
INSERT INTO `jos_components` (`name`, `link`, `menuid`, `parent`, `admin_menu_link`, `admin_menu_alt`, `option`, `ordering`, `admin_menu_img`, `iscore`, `params`, `enabled`) VALUES
('VirtueMart', 'option=com_virtuemart', 0, 0, 'option=com_virtuemart', 'VirtueMart', 'com_virtuemart', 0, '../components/com_virtuemart/shop_image/ps_image/menu_icon.png', 0, '', 1);

Related

All my fields are tabindex=-1 in my editview

I've created a custom module based on people template.
i've customised the editView (which is synced with the detailView) and I have assigned a tabindex value for every field.
But when I use that editView almost every field has tabindex=-1 so I only can't get to them using my mouse, which is very slow.
I was changing include/EditView/EditView.tpl but it looks the changes there has no effect on the generated code.
I changed all tabindex=$tabindex for a tabindex="-3", "-4", "5" in every tabindex assignment, but I couldn't see it in my html page, I also tried making a QRR previously.
So my question is where can I fix that -1 issue or, at least, where is really being generated my editView.
Thanks in advance!!!
Well! I found a workaround... I guessed that the problem was the autogenerated fields, they had no "space" among another fields's tabindex values...
So, instead of giving the fields tabindex values of 1, 2, 3, 4... I gave them as 10, 20, 30, 40...
And, against all odds, it works!
Perhaps it's useful for somebody....
Well, I finally found where this fields, and tabindex values of course, were generated.
The include/EditView/EditView.tpl has been overwritten by the themes/suiteP/include/EditView/EditView.tpl.
This SmartyTemplate calls tab_panel_content.tpl in the same folder... Well, as I'm using SuitePImproved this wasn't true, suitePImproved/include/EditView/EditView.tpl was loading suiteP/include/EditView/tab_panel_content.tpl so that had to be fixed.
Anyway, in the tab_panel_content.tpl file you find tabindex=$tabindex 4 times, that $tabindexare replaced by:
$subfields.tabindex
$colData.field.tabindex
$colData.field.tabindex
$colData.field.tabindex
And this is working everywhere for me.
This change is not upgrade-safe because I didn't get loaded that tpl from the custom/themes... I'll come back later to fix that

How to find a particular Sublayout assigned to which content item in Sitecore.?

I have one Sublayout called "A" and i have more number of Content items. I just wanted to find out which content item that "A" Sublayout assigned to. How can i do this.?
You can select chosen sublayout in your content tree, and select Links option from the Navigate tab in ribbon:
You will see all the items which links to your sublayout.
Be aware, that if you see any __Standard Values item in that list, your sublayout may be also used by items which use that template.
Screenshot is from Sitecore 8, but it works the same in Sitecore 7.2.

sap.m.Select: start with a blank selection input element

When using a data aggregation on sap.m.Select, the first entry is always selected. Here's a link to the SDK's preview.
Example code from my app
new sap.m.Select("id-names", {
width: '100%',
}).bindAggregation("items", "data>/trip/names", new sap.ui.core.Item({
text: "{data>Name}"
}));
There is a parameter called selectedKey on the constructor to change this to another index. What I want is the select to be blank, because I want to force my users to make a choice, not blandly accept the first entry in the list.
I could force an blank entry in my aggregation data>/trip/names but that would pollute my list.
Is there a better way to achieve this?
Since the OpenUI5 version 1.34, you can set the forceSelection property to false.
The forceSelection property indicates whether the selection is restricted to one of the items in the list. The default value is true (which means, if the selection is not set, the first item in the dropdown list is selected).
When to set it to false?
If you do not want a default item to be pre selected.
Additional information
https://github.com/SAP/openui5/commit/b2191fd50e2115f8f9d2db7604a75fb50c57591f
Currently, no. There seems to be no better way.
There is a ticket for that on GitHub.
It's also my opinion to avoid messing with the dataset and much liked the idea of adding an additional item aggregate. However my improvement on this is to use a formatter on the control itself so it is clearly visible and executed at the right time.
I make use of a formatter with fully qualified controller to get the control as 'this' parameter. In the formatter function I add a ListItem, as proposed by #Victor S
In XML view
<Select forceSelection="false" selectedKey="{model>/key}" items="{path: 'model>/Items'}" icon="{path: '', formatter: 'mynamespace.Utils.addDeselectOption'}">
In the Utils controller:
addDeselectOption: function() {
var that = this;
this.getBinding("items").attachDataReceived(function(){
that.insertItem(new sap.ui.core.ListItem({text: '', key: undefined}), 0);
});
}
Works form me in UI5 1.52
Even though this solution is not great, I managed to get the empty field stick by adding both, the forceSelection=false property, and also in the controller's onInit function (I used the Select element):
var codeField = this.getView().byId("codeField");
setTimeout(function() {
codeField.insertItem(new sap.ui.core.ListItem({text: '', key: undefined}), 0);
}, 1000);
If the forceSelection=false is left out, the field will load either too early or too late to the drop down, which will cause the wrong selection to be visible. Hope it helps someone.
You can also extend the control and build you own select with e.g. an additional parameter add empty choice...I am actually also thinking about that...

File Selection from List in a Wizard page

I have a Wizard page which gets a list of IFile. I want to show the user the list and select one file from the list. Then the Wizard returns the selected file.
Is there a standard file chooser that I can use instead of building from scratch in the createControl() of the WizardPage? (Maybe something like table view list with scrollbar to show the list.)
There is FilteredResourcesSelectionDialog that is a popup displaying any resource wanted, eventually with pre-loaded regexp, allowing to search for file, and you give him a root directory :
You call getResult() to retrieve selection as Object[].
If you want to do just a wizard that does that, then I would do it this way.
If it's a list include in a wizard that does other things, then just list all the files and create a org.eclipse.swt.widgets.List
Though there is no ready-to-use FileViewer or the like, you can use a TableViewer with a WorkbenchLabelProvider to show the list of files.
IFile[] files = ...
TableViewer fileViewer = new TableViewer( parent );
fileViewer.setInput( files );
fileViewer.setContentProvider( ArrayContentProvider.getInstance() );
fileViewer.setLabelProvider( new WorkbenchLabelProvider() );
This will create a single-selection table (viewer) that displays the files from the files array.
If multi-selection or further styles apply, use new TableViewer( parent, SWT.MULTI | ... ) to create the viewer.
If the list of files need to be sorted by name or type, you can use the ResourceComparator from the org.eclipse.ui.ide plug-in.
fileViewer.setComparator( new ResourceComparator( ResourceComparator.NAME ) );
If you don't want the extra plug-in dependency or need to sort by another criteria, it may still be used as a template.

TYPO3/TemplaVoila: Unknown column 'belayout' in 'field list' when adding new Template Object

We're trying to implement a mobile version of our Typo3 site, but whenever I add a new Template Object and select something in "Make this a sub-template of", I get this error:
I'm not very good with typo3, so if anyone could point me in the right direction it would be great. Thanks.
Go to Install Tool > Database Analyser > COMPARE and mark the checkboxes to add missing fields and tables (you don't need to remove suggested things)
Repeat the operation as long as required, if some field can not be added by COMPARE, you need to include it manually via phpMyAdmin. Most probably in such case you'll need to resolve some conflict.
Next go to Extension Manager, find the TemplaVoila ext and search for Update button, to make sure that the config is saved correctly to the file.