I am having a problem while using SAP UI5. I am using a NumericContent Tile. Here I want to set "km/h" as a scale, but it always gets abbriged to "km/".
How can I prevent this?
<TileContent footer="{i18nExtended>SpeedTripMax}" class="sapUiSmallMargin">
<content>
<NumericContent value="{mymodel>/SpeedTripMax}"
truncateValueTo="6" scale="km/h"/>
</content>
</TileContent>
I do not know why it is happening, but according to api one should use sap.suite.ui.commons.GenericTile instead of sap.suite.ui.commons.NumericTile because it is deprecated since version 1.25.
Try GenericTile approach.
EDITED 10:42 120717:
I tested it on my system and it is bug, because k/h works fine:
The max string length is just 3 signs:
I was testing it within GenericTile.
Related
I am trying to enable the Carousel's loop feature.
In my view, I declare the property:
<Carousel height="auto" loop="true" pages="{ProductCollection}">
<customLayout>
<CarouselLayout visiblePagesCount="2" />
</customLayout>
</Carousel>
It seems not to work!
Here's a sample of my code: https://embed.plnkr.co/zILEH3/
Turns out it was a bug that it worked backwards at all 😄 which is fixed by now..
According to the note in the API reference, which I missed, the sap.m.Carousel was designed to ignore the loop if the visiblePagesCount is not 1.
Note: When this property is set to something different than the default value, the loop property of Carousel is ignored.
I want to crop images in Fluid with the f:image or the f:uri.image viewhelper (TYPO3 8.7). Since TYPO3 7.2 the usual way does not work anymore:
This:
<f:image image="{file}" width="500c" height="500" />
does not work.
In the fluid guide I found the hint that since TYPO3 7.2 I have to use crop. I found this in the change log:
https://docs.typo3.org/typo3cms/extensions/core/7.6/Changelog/7.2/Feature-65584-AddImageCropping.html
So this should work, but it doesnt:
<f:image image="{file}" crop="0,0,500,500" />
The images are rendered but in default size.
Any ideas? Anything changed in later versions?
I tried with a fresh installation and found my fault.
cropping with c and m does indeed work in TYPO3 8 - the hint in the fluid manual is wrong.
in short syntax you have to use '' in order to send the c or m correct.
This syntax is wrong:
<img src="{f:uri.image(image:file, width:200c, height:200)}">
there is no error message and the images are rendered but the letter c is ignored. You have to use this syntax:
<img src="{f:uri.image(image:file, width:'200c', height:'200')}">
this will work.
One additional hint: after changing the syntax the images are not rendered every time but only when the size has changed. Sometimes you get simply the cached images ... Deleting the content on /fileadmin/_temp does help.
Well - perhaps it will help some one :-)
You can use f:image like below. it's work for me.
<f:image src="{file.originalResource.publicUrl}" width="770c" height="517c" height="350c" />
You could also specify the crop settings in tca and use this settings in the FE, for an example look at the repository : https://github.com/frans-beech-it/t3ext-config_examples.
Besides that, in the install tool you can check if cropping works on your machine. It can happen that there are already processed images for your size, if you adjust the cropping information of image with 1px a new processed image is created. If then the image works, clear the processed files to generate a new image for your desired formats.
I am adding a SearchField with suggestions in the XML view. When I execute, I get the error
Error: Cannot add direct child without default aggregation defined for control sap.m.SearchField.
Please tell me what mistake I am making.
<SearchField
placeholder="final search"
tooltip="Search for datastore source names"
suggestionItems="{/records}"
selectOnFocus="true"
>
<suggestionItems>
<SuggestionItem
text="{dbname}"
description="{dbname}"
/>
</suggestionItems>
</SearchField>
Try to have a look to this example
sap.m.Input
suggestionItems="{/ProductCollection}" is the collection with all the available entries, text="{Name}" is one of the attributes of the collection item.
Check this example without search help https://sapui5.hana.ondemand.com/sdk/explored.html#/sample/sap.m.sample.InputSuggestionsDynamic/preview or https://sapui5.hana.ondemand.com/sdk/explored.html#/sample/sap.m.sample.InputSuggestionsCustomFilter/preview
You must be using an old UI5 version. The aggregation suggestionItems was introduced in 1.34.
Here, you can see that the app crashes throwing the same error if run with the version lower than 1.34: https://jsbin.com/qepojux/edit?html,js,output
To see with which UI5 version the app is currently running, press Ctrl+Left Alt+Shift+P.
See also Versioning of SAPUI5.
I am starting with SpagoBI, I managed to display a static chart using Highchart, what I want to do is a dynamic chart means if my data set is updated I want my chart to be updated as well, without manually refreshing the web page. like the example under this link [1]
I used SpagoBi studio to deploy the chart, I tested the option of "refresh Seconds" (I edited to 1 second) while deploying but it is not working.
How can I do that?
Update: the chart template:
<HIGHCHART width="100%" height="100%">
<CHART defaultSeriesType="spline" zoomType="xy"/>
<TITLE text="Temperature 1"/>
<LEGEND/>
<SUBTITLE/>
<X_AXIS allowDecimals="true" maxZoom="4" min="0" tickWidth="1" type="linear" alias="recvTime">
<TITLE/>
</X_AXIS>
<Y_AXIS maxPadding="0.0" maxZoom="4" tickWidth="1" type="linear" alias="attrValue">
<TITLE/>
</Y_AXIS>
<PLOT_OPTIONS>
<SPLINE stacking="">
<DATA_LABELS/>
</SPLINE>
</PLOT_OPTIONS>
<DRILL>
<PARAM_LIST/>
</DRILL>
<SERIES_LIST>
<SERIES name="Temperature" alias="recvTime,attrValue" type="spline"/>
</SERIES_LIST>
</HIGHCHART>
[1]http://www.highcharts.com/demo/dynamic-update
try setting the refresh_time property:
<HIGHCHART refresh_time='5' width="100%" height="100%" >
....
Hope this help!
I'm not able to reproduce your problem with the "Refresh seconds" option... are you using the FIWARE package or another SpagoBI version?
Anyway, using the "Refresh seconds" option, the chart will be re-created from scratch at the specified rate, not updated as the Highchart example.
Charts provided by SpagoBI with the ExtJS library can be refreshed: just specify "refreshTime" in the template XML root tag:
<EXTCHART refreshTime='10'...
this will let the chart refresh its data without being re-created from scratch.
But, refreshing data is still not exactly the "time shifting" functionality as in the Highcharts example; if you are looking for that, you should have a look at the Console[1] engine.
Best regards
Davide
[1] http://wiki.spagobi.org/xwiki/bin/view/spagobi_server/Console
I have created a custom Plone content type in my package i.e. my.product.
I am in need of integrating a working copy support: so that a "published" document (in my case, a published content type) stays online while it is being edited. Basically, I want to take advantage of 'Working Copy Support (Iterate)' provided by plone.app.iterate to achieve what is explained here. This will provide me with ability to check-in/check-out my changes.
Is this possible in Plone 4 with custom content types using Archetypes? How would one go about it if yes?
I added the following two files inside my.product/my/product/profiles/default folder and it appears to work:
diff_tool.xml
<?xml version="1.0"?>
<object>
<difftypes>
<type portal_type="MyCustomType">
<field name="any" difftype="Compound Diff for AT types"/>
</type>
</difftypes>
</object>
repositorytool.xml
<?xml version="1.0"?>
<repositorytool>
<policymap>
<type name="MyCustomType">
<policy name="at_edit_autoversion"/>
<policy name="version_on_revert"/>
</type>
</policymap>
</repositorytool>
I have never used plone.app.iterate, but this is the generic approach how to solve the problem.
Actions are installed by plone.app.iterate GenericSetup profile. You can see actions here:
https://github.com/plone/plone.app.iterate/blob/master/plone/app/iterate/profiles/default/actions.xml
Pay note to the line *available_expr* which tells when to show the action or not. It points to helper view with the conditition.
The view is defined here
https://github.com/plone/plone.app.iterate/blob/master/plone/app/iterate/browser/configure.zcml#L7
The checks that are performed for the content item if it's archiveable
https://github.com/plone/plone.app.iterate/blob/master/plone/app/iterate/browser/control.py#L47
Most likely the failure comes from if not interfaces.IIterateAware.providedBy condition. Your custom contennt must declare this interface. However, you can confirm this putting a pdb breakpoint in checkin_allowed(self) and step it though line-by-line and see what happens with your content type.