Quantcast
Channel: SmartClient Forums
Viewing all 4756 articles
Browse latest View live

Tilde Issue on AppEngine? Probably not SmartGWT bug

$
0
0
All,

My application can't seem to resolve the file "back_array~2.png" that is located in the skins directory. I'm running on Google AppEngine. When running locally, it seems to show the arrow just fine. Therefore, I don't think it has anything to do with SmartGWT.

"GET /barbermgwt/sc/skins/Enterprise/images/NavigationBar/back_arrow~2.png HTTP/1.1" 404

Further, other files in the skin directory come up just fine, for example: "GET /barbermgwt/sc/skins/Enterprise/skin_styles.css HTTP/1.1" 200

I've tried accessing the file directly from the browser and same issue (so again nothing with SmartGWT).

Anybody else have the same issue?

I'm running: Isomorphic SmartClient/SmartGWT Framework (v10.0p_2014-12-19/PowerEdition Deployment 2014-12-19)

Isomorphic, any chance we can change that filename to back_arrow.png and drop the tilde?

One problem about SelectItem fetching or filtering data from server by datasource

$
0
0
1. Version v9.0p_2014-02-15/LGPL Development Only

2. FireFox any version and Chrome

The problem description:

I use one SelectItem in a DynamicForm, and the SelectItem fetches data from server by DataSource. It fetches data when it

creates the first time (so I set its 'autoFetchData' true). I use 'picklist' to display it when click. The displayed listgrid is

set filtered (Its property 'showFilterEditor' is set true).

Acturally it was very like the example 'Featured Samples.Filter Related Records'.

But when I use as above, the problem appears. I click the selectitem and the listgird displays. I input one char in any

filtereditor, and the filtering does not process. When I open the server debug port and repeat it, I find the selectitme also

fetch data from server but not filter data which has been fetch on creating selectitem.
Furtherly when I input one char again, that is to say, input two chars, the filtering appears. And I futrher modify the input

value into one char or multiple chars, the filtering is normar.
But when I click the selectitem again and show the listgrid, the problem also appears again.

(Note: the SelectItem is located the line 91 and named infBoxLabel in the attach file 'uni_topo.js')
[code]
var infBoxLabel = ({
name: "infBoxLabel",
titleAlign : "left",
colSpan : 2,
width : "100%",
title:Uni_Util.getTitleHtml(sdn_uni_interface_name),
type:"select",
multiple:true,
valueField:"infName",
displayField:"infName",
pickListWidth:480,
autoFetchData:true,
defaultToFirstOption:true,
pickListProperties: {autoFetchData:false,
showFilterEditor:true,
filterOnKeypress:true,
filterButtonProperties:{visibility:"hidden"},
autoFetchTextMatchStyle:"substring",
},
pickListFields:[{name:"infName",
title:sdn_uni_phy_name,
type:"text",
required:true,
showDefaultContextMenu:false},

{name:"adminStatus",
title:sdn_uni_phy_admin_status,
valueMap:[sdn_uni_phy_admin_status_enable, sdn_uni_phy_admin_status_disable],
type:"select",
required:true,
showDefaultContextMenu:false},

{name:"infDesc",
title:sdn_uni_phy_description,
type:"text",
required:true,
showDefaultContextMenu:false}],
pickListCriteria:{start:0, length:10000, condStr:JSON.stringify({vrID: this.vrID, neIDs: this.neID})},
optionDataSource:isc.RestDataSource.create({
dataFormat : "json",
fetchDataURL : "/web/res/web-sdn-service/phyinf/fetch",
fields: [{name:"infName"},{name:"adminStatus"},{name:"infDesc"}],
operationBindings : [{operationType:"fetch", dataProtocol:"postMessage"}],
allowAdvancedCriteria:true,
}),
endRow: false,
});
[/ code]

Please check it.
Thank you.

Attached Images
File Type: png Not filter.png (17.9 KB)
File Type: png filter_also.png (14.6 KB)
File Type: png fiter.png (12.9 KB)
Attached Files
File Type: js uni_topo.js (21.0 KB)

Custom DataSource and POJO

$
0
0
I'm trying to pass a non-scalar field from client to server through a custom data source. I've tried several approaches, and none of them work. The current symptom I have is that when the client calls addData() with the record that contains the non-scalar field, the client eventually times out with:

(-:-) 2015-01-21 19:55:46,917 [WARN ] smartGWT Datasource operation returned an error.

ConsoleLogger.java:69 (-:-) 2015-01-21 19:55:46,922 [WARN ] Datasource is PivotBookmarksDMI
ConsoleLogger.java:69 (-:-) 2015-01-21 19:55:46,927 [WARN ] Datasource operation is ADD
ConsoleLogger.java:69 (-:-) 2015-01-21 19:55:46,932 [WARN ] Error code is -100
ConsoleLogger.java:69 (-:-) 2015-01-21 19:55:46,937 [WARN ] Error message is Error on Server - Unable to Complete
ConsoleLogger.java:69

If I don't add the POJO/map to the record on the client, the server custom DMI code works fine. If I add the POJO or map to the record to the client and call addData(), then the add operation times out.

I've tried putting the data into the record on the client as a Map, or I've tried using setAttributeAsJavaObject. I still get a timeout on the server.


Here's the datasource xml file:

<DataSource
ID="PivotBookmarksDMI"
dropExtraFields="true"
serverConstructor="com.Atlantic.AtlanticScheduler.server.Pivot.PivotBookmarksDMI"
>
<fields>

<field name="code" type="text" primaryKey="true" />
<field name="path" type="text" />
<field name="description" type="text" />
<field name="colorDimensionName" type="text" required="true" />
<field name="labelDimensionName" type="text" required="true" />
<field name="rowDimensionNames" title="Row Dimensions"
multiple="true"
type="text"
required="true"
/>

</fields>
</DataSource>


Here's the server code. I never see any of the logging info in this method, which is consistent with the timeout occurring.

public class PivotBookmarksDMI extends BasicDataSource {

@Override
public DSResponse executeAdd(DSRequest req) throws Exception {
logger.info("-------Running add on PivotBookmarksDMI.");

logger.info("client supplied values are " + req.getValues());

@SuppressWarnings("unchecked")
Map<String, Object> values = req.getValues();
logger.info("got values");
return dsResponse;
}
}
I looked in the showcases (both plain and Pro/EE), and couldn't find an example. I looked on this forum and couldn't find a solution. The forum did suggest that setAttributeAsJavaObject could work, but when I used that to insert the POJO into the record, the timeout persisted.


I'm using:

SmartClient Version: v9.1p_2014-11-01/PowerEdition Deployment (built 2014-11-01)

Chrome 40.0.2214.69 beta (64-bit)


What's the correct approach to solve this problem?

One bug about the sample ''Filter Related Records"

$
0
0
1. Version v9.0p_2014-02-15/LGPL Development Only

2. FireFox any version and Chrome

The sample ''Filter Related Records" can work normally for filtering.
Note that we only pay close attention to the left component. In this I want to know how it filters, that is to say, is it filter datas from client or fetch datas form server when inputting chars in the listgrid editors?

I write some codes as like the samle ''Filter Related Records" . The codes are
Code:

var infBoxLabel = ({
                        name: "infBoxLabel",
                        titleAlign : "left",
                        colSpan : 2,
                        width : "100%",
                        title:Uni_Util.getTitleHtml(sdn_uni_interface_name),
                        type:"select",
                        multiple:true,
                        valueField:"infName",
                        displayField:"infName",
                        pickListWidth:480,
                        autoFetchData:true,
                        defaultToFirstOption:true,
                        pickListProperties: {autoFetchData:true,   
                                                showFilterEditor:true,
                                                filterOnKeypress:true,
                                                filterButtonProperties:{visibility:"hidden"},
                                                autoFetchTextMatchStyle:"substring",       
                                                },   
                        pickListFields:[{name:"infName",
                                        title:sdn_uni_phy_name,
                                        type:"text",
                                        required:true,
                                        primaryKey:true,
                                        showDefaultContextMenu:false},
                                                                               
                                        {name:"adminStatus",
                                        title:sdn_uni_phy_admin_status,
                                        valueMap:[sdn_uni_phy_admin_status_enable, sdn_uni_phy_admin_status_disable],
                                        type:"select",
                                        required:true,
                                        showDefaultContextMenu:false},
                                                                               
                                        {name:"infDesc",
                                        title:sdn_uni_phy_description,
                                        type:"text",
                                        required:true,
                                        showDefaultContextMenu:false}],

                        pickListCriteria:{start:0, length:10000, condStr:JSON.stringify({vrID: this.vrID, neIDs: this.neID})}, 
                        optionDataSource:isc.RestDataSource.create({
                                                        dataFormat  : "json",
                                                        fetchDataURL : "/web/res/web-sdn-service/phyinf/fetch",
                                                        fields: [{name:"infName"},{name:"adminStatus"},{name:"infDesc"}],       
                                                        operationBindings : [{operationType:"fetch", dataProtocol:"postMessage"}],       
                                                        }),               
                        endRow: false,
                });

It has one bug. When it shows the listgrid firstly, the filtering is normal. But when it shows the listgrid again, the filtering is not normal when inputting one char but normal multiple chars.

The only different point is that my code is fecthing data from server by 'pickListCriteria' and 'optionDataSource', and the sample code is not.

Why is it so?






Thank you.

Cannot enter number range when using "FilterOnKeypress" and "AllowFilterExpressions"

$
0
0
I want to use an integer column in my ListGrid. This column should filter on keypress and allow filter expressions. This works fine for most of the expressions, but entering a number range (i.e. "100...150") will not work.

Steps to reproduce:
* run example code
* Click into filter of the number column
* Enter "100...120"
Expected behavior:
* Text "100...120" is shown in filter input field
Experienced behavior:
* Text "100120" is shown in filter input field

However if you copy and paste "100...120" into the field everything works fine. Entering "a100...120" and removing the "a" afterwards will also work.

Do you have any idea how to solve or work around this issue?

Code:

public class Tryout implements EntryPoint {
       
        @Override
        public void onModuleLoad() {
               
                // create a number field as primary key
                final DataSourceField numberDataSourceField = new DataSourceField("number", FieldType.INTEGER);
                numberDataSourceField.setPrimaryKey(true);
               
                // create Record
                final ListGridRecord record1 = new ListGridRecord();
                record1.setAttribute(numberDataSourceField.getName(), 100);

                // create Record
                final ListGridRecord record2 = new ListGridRecord();
                record2.setAttribute(numberDataSourceField.getName(), 150);

                // create Data Source using the number field and the two records
                final DataSource dataSource = new DataSource();
                dataSource.setFields(numberDataSourceField);
                dataSource.setClientOnly(true);
                dataSource.setCacheData(new ListGridRecord[] {record1, record2});

                // create a grid using the datasource (filterable)
                final ListGrid listGrid = new ListGrid();
                listGrid.setDataSource(dataSource);
                listGrid.setAutoFetchData(true);
                listGrid.setShowFilterEditor(true);
               
                // this combination produces the unwanted behavior
                listGrid.setFilterOnKeypress(true);
                listGrid.setAllowFilterExpressions(true);
               
                // show grid
                listGrid.setWidth(200);
                listGrid.setHeight(200);
                listGrid.show();
        }
}

* SmartClient Version: v10.0p_2014-11-30/LGPL Development Only (built 2014-11-30)
* Tested on Firefox 31.0 Windows 7 Professional

Thanks in advance!

Calendar: current day?

$
0
0
Is it possible to mark the current day in the week-view and month-view? For example here: http://www.smartclient.com/smartgwt/showcase/#databound_calendar_category you don't see which day is "today". Maybe with a different background color?

Calendar: delete entries in the month-view?

$
0
0
Is it possible to delete an entry from the month-view? I can delete entries from the week-view and the day-view, but not from the month-view.

Calendar : change texts in EventEditor

$
0
0
How to change the texts in the EventEditor? E.g. the text for "Event name" TextField and "Save event" Button?

SmartGWT.mobile & GWT 2.7.0

$
0
0
I just tested using smartgwt-mobile with gwt 2.7.0 - and get a build error.

Version: smartgwt-mobile-1.0d_2015-01-22

If I try and build the included 'helloworld' sample .. I get the same error as in my project... Is this known about? or am I doing something wrong?

Code:

gwtc:
    [java] Compiling module com.mycompany.HelloWorld
    [java]    Ignored 1 unit with compilation errors in first pass.
    [java] Compile with -strict or with -logLevel set to DEBUG or WARN to see all errors.
    [java]    [ERROR] Could not find com.google.gwt.core.client.impl.StackTraceCreator.CollectorChrome in types compiled from source. Is the source glob too strict?
    [java]    [ERROR] Errors in 'com/google/gwt/core/client/impl/StackTraceCreator.java'
    [java]      [ERROR] Line 364: Rebind result 'com.google.gwt.core.client.impl.StackTraceCreator.CollectorChrome' could not be found


... Also I found trying to search to find if this [and other issues in the past] had already come up much trickier because of all the discussions of SmartGWT not-mobile - would it not make sense to have a separate forum for SmartGWT-mobile - particularly as it has quite a different API [and output] to the desktop products?



Thanks,

VStack/VLayout with lots of members

$
0
0
Hi,

I would like to know what is the recommended way to create a large stack of elements. We have a panel which might contain lots of members (organised vertically and which cannot be considered as table rows) and as soon as it's getting bigger (e.g. 100+) it starts also getting a lot slower. I presume that it's because the layout recomputes all the heights etc... everytime a new member is added.

Any feedback is welcome,
Thanks,

Thomas

PS: We are using SGWT Power Edition 4.1

propagate event between item in smartgwt

$
0
0
Hi
Technologies:
smartgwt3.0,gwt2.1,
IE9,
JDK6.22u.
I want when I click a buttonItem, another buttonItem is clicked autoamtically.
How attach the 2 events.
I try to resolve the problem using fireEvent, but I d'idn't understand very well the real function of this method

Progressive Loading multiple fetches

$
0
0
Hi,

I cannot set up proper config values for progressive loading.
Now I got back to defaults.

Server is returning totalRows = endRow + 20.
I've found that this should be default but tried other values with no luck.
Grid is displaying no more than 20.

So in first request server provides 75 records and total rows = 95.
Immediately after that client calls for another part and another...
What are the correct options to prevent this calls to happen.
Tried setting up drawAhead and other options with no luck.

Code:

18:08:56.799:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):setCriteria: filter criteria changed, invalidating cache
18:08:56.800:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):Invalidating cache
18:08:56.805:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):getRange(0, 39) will fetch from 0 to 75
18:08:56.806:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):fetching rows 0,75 from server
18:08:57.208:XRP7:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):Received 75 records from server
18:08:57.209:XRP7:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):cached 75 rows, from 0 to 75 (95 total rows, 75 cached)
18:08:57.271:TMR1:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):getRange(0, 95) will fetch from 75 to 150
18:08:57.575:TMR6:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):fetching rows 75,150 from server
18:08:57.699:XRP9:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):Received 75 records from server
18:08:57.700:XRP9:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):cached 75 rows, from 75 to 150 (170 total rows, 150 cached)
18:08:57.706:TMR0:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):getRange(0, 170) will fetch from 150 to 225
18:08:58.014:TMR1:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):fetching rows 150,225 from server
18:08:58.160:XRP0:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):Received 75 records from server
18:08:58.161:XRP0:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):cached 75 rows, from 150 to 225 (245 total rows, 225 cached)
18:08:58.184:TMR4:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):getRange(0, 245) will fetch from 225 to 300
18:08:58.557:TMR3:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):fetching rows 225,300 from server
18:08:58.699:XRP1:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):Received 75 records from server
18:08:58.700:XRP1:INFO:ResultSet:isc_ResultSet_1 (dataSource: dsActivity, created by: isc_ListGrid_4):cached 75 rows, from 225 to 300 (320 total rows, 300 cached)

I'm using SmartGWT 5.0p 2015-01-20 with GWT 2.7.0
Tested in Super Dev Mode and after full compilation on Chrome and Firefox with same results.

Best regards
Mariusz Goch

getting the record id after a data source add

$
0
0
After using a DataSource to add a record to a table where the ID/primary key is automatically generated is there a way to find out what the ID is in the call back function.

I need this so I can later update the record that was just added.

How to change the "drop indicator" to "no-drop indicator" dynamically while dragging?

$
0
0
Hi,
We are using Smart Gwt-4.1p (23rd May 2014)
Browser: IE10, 11, Google Chrome:37.0.2062.124 m

We are using the TreeGrid and ListGrid in our project. We are trying to put the drag and drop feature from ListGrid to TreeGrid. We have achieved to drag and drop the records. But, we would like to show the "no-drop indicator" for few nodes in the tree ie.., the treeGrid should not allow drop on few levels in the tree. So now, How can we change the indicators from "drop indicator"(allowed) to "no-drop indicator"(disallowed) and vice versa dynamically?

Any suggestions would be appreciated.

Smart Gwt Additional Themes

$
0
0
Hi,
Before starting my question, I really like SmartGWT. On the other hand, I think it is common for many of the developers that skins are not nice and clean enough. Since skinning and style development is very different than standards, it is not easy to adapt other styling frameworks to smartgwt.
So my question is , I am wondering if there are commercial options for different skins other than the ones coming with SmartGWT either from isomorphic or other companies. And I am also curious about how isomorphic is thinking about styling?

MultiComboBoxItem layoutStyle horizontalReverse AutoFitButtons bug Internet Explorer

$
0
0
There is a MultiComboBoxItem on the form with values "ONE", "TWO", "THREE". If you select all these values, the item shows "THR…" instead of "THREE". This problem occurs by redrawing the filled item with disabled parent layout too. It works fine on FF, GC browsers, but on IE we can reproduce it by showcase too: Select horizontalReverse, and then enter some values, e.g. "Glue UHU Clear…" or "Spray…" Could you please check it?
http://www.smartclient.com/smartgwt/...bobox_category

Code:

MultiComboBoxItem item = new MultiComboBoxItem();
item.setLayoutStyle(MultiComboBoxLayoutStyle.HORIZONTALREVERSE);
item.setName("Name");
item.setShowTitle(false);

IE Version 11.0.9600.17498 on Win8.1
SmartGWT Version: 4.1p BuildDate: Wed Sep 24 08:30:00 CEST 2014

BUG : Simplicity Skin unable to select last record

$
0
0
Sorry to repost in a new thread but I was commenting on another post which was a potential issue but after investigation I've proven it's an definitely a bug. Original Post

To show the issue very simply in the showcase, go to the example...

Showcase Example

There is no option of the Simplicity skin for the showcase so I added a browser addon to modify cookies so that I could set the skin to Simplicity. So I changed cookie value to "Simplicity" and reloaded the browser to apply the skin, you will find you can not select the bottom record in the grid until you scroll past it.

Changing skin is not an option for our clients, could this get fixed please?

Thanks,
Dale

-------------------------------------------------------------------------------
GWT Version : 2.4.0
SmartGWT Version : 5.0p
SmartGWT Build Date : 14/01/2015 10:58
Browsers : IE 9 - 11, Chrome, Firefox
-------------------------------------------------------------------------------

Buttons are not loaded in list grid, when we do refersh

$
0
0
Hi,

We are using Smart Gwt-4.1p (23rd May 2014)
Browser: IE10, 11, Google Chrome:37.0.2062.124 m

Issue : Buttons are not loaded in list grid, when record is more than 30.
First time button is loaded properly.
Steps:
1. Expand column width so that will get horizontal scroll and last 3 button columns should display on scroll.
2. Click on refresh button

All the button is not loaded and user is not able to scroll till last width. Horizontal Scroll is coming back to beginning and button object is getting created on horizontal scroll.
Finally button is not displaying in list grid.

PFA files.
Thanks...

Attached Files
File Type: java SecDBListGrid.java (10.0 KB)
File Type: java TestsmartGwtProject.java (11.2 KB)
File Type: java CloningListDS.java (5.3 KB)
File Type: js DeviceCloningListDS.js (9.0 KB)

Update cursor after call setCursor

$
0
0
I used the setCursor method on DrawRect object, after move the mouse the cursor is changed.

Is there any way to update cursor immediately?

focus management: question about DynamicForm focus/blur

$
0
0
Hi,
I am using below code to display rectangle over dynamic form then user focuses in one of the form`s field, it works okay except if field is SelectItem, ComboBoxItem or DatePicker, it looks like DynamicForm is loosing focus then I click on one of these fields.
Is it expected behavior? As it seems like DynamicForm will stay focused then its field gets focus, but miss focus then field opens another component. Shouldn't focus be set on all elements DynamicForm, field & drop down component? From sources I cannot find out how yours focus management works. Is there any docs?

Thanks.

Code:

dynamicForm.focusChanged = function (hasFocus) {
  layout.setBorder(hasFocus ? "1px solid #D8D8D8" : "1px solid #000000");
};

Viewing all 4756 articles
Browse latest View live