Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-19556] Android: TableView data properties does not work inside the applyProperties.

GitHub Issuen/a
TypeBug
PriorityHigh
StatusOpen
ResolutionUnresolved
Affected Version/sn/a
Fix Version/sn/a
ComponentsAndroid
LabelsTableView, applyProperties, data, reprod
ReporterMotiur Rahman
AssigneeUnknown
Created2015-09-21T12:10:04.000+0000
Updated2019-11-11T14:52:48.000+0000

Description

TableView data properties do not work inside the applyProperties. But it works as expected on iOS. It should work for both http://docs.appcelerator.com/platform/latest/#!/api/Titanium.UI.TableView-method-applyProperties *Steps to Reproduce:* 1.Run this code with the testing environment. 2. And check data is loaded in the tableView or not? *Testing Environment:* Command-Line Interface, version 5.0.1, Ti SDK: 5.0.0.GA, Android Version: 4.2.2, 4.4.2, 5.1.0, Studio Version: 4.3.0 *Test Code:*
var win = Ti.UI.createWindow({
	backgroundColor : 'white'
});

// Create a TableView.
var table = Ti.UI.createTableView({
	//backgroundColor:'red',
});

var tableData = [{
	title : 'Apples'
}, {
	title : 'Bananas'
}, {
	title : 'Carrots'
}, {
	title : 'Potatoes'
}];

table.applyProperties({
	data : tableData,
	backgroundColor : 'gray',
	top : 50,
	bottom : 20,
	left : 20,
	right : 20,
	borderRadius : 10
});

//table.data = tableData;

// Add to the parent view.
win.add(table);

win.open();

Thanks.

Comments

  1. Sharif AbuDarda 2016-12-23

    Hello, I can re-confirm the issue for SDK 6.0.1.GA. In Android, TableView data properties do not work inside the applyProperties. But the other property work fine in applyProperties. Thanks.
  2. Lee Morris 2017-07-05

    I am able to reproduce this issue with the following environment; Pixel (7.1) Studio 4.9.0.201705302345 Ti SDK 6.1.1 GA Appc NPM 4.2.9 Appc CLI 6.2.2 Ti CLI 5.0.14 Alloy 1.9.11 Xcode 8.2 (8C38) Node v4.8.2 Java 1.8.0_131

JSON Source