Hi,
based upon below url i am going to do implement one function
If i can select all in dropdown need to assign All value to Like '%'
(Like value should replace inplace of "=" and '%' value should replace in place to 'Name')
EX:select Name,Gender where Name={Name}
if i can select All then replace above query like below
select Name,Gender where Name Like '%'
Code -
$scope.Save = function () {
debugger;
var Id1 = $scope.items;
var rId = $scope.RName;
var details = {};
var array = [];
for (var i = 0; i < $scope.items.length; i++) {
var data = {};
data.Text = $scope.items[i].CName;
if ($scope.items[i].CType.toLowerCase() == 'dropdown') {
if ($scope.items[i].FromTable == "All") {
data.Value = "%";
}
else {
data.Value = $scope.items[i].FromTable;
}
//data.Value = $scope.items[i].FromTable;
} else if ($scope.items[i].CType.toLowerCase() == 'datepicker') {
data.Value = ConvertDate($scope.items[i].Date.toString());
} else if ($scope.items[i].CType.toLowerCase() == 'textbox') {
data.Value = $scope.items[i].ValueCName;
}
array.push(data)
details.RId = rId;
details.details = array;
}
}
Could you please help me