×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Javascript
Posted by: Nilesh Yadav
Added: Jun 8, 2017 9:33 AM
Modified: Jun 8, 2017 10:12 AM
Views: 6
  1. $scope.workflowStatusList = [
  2.       {id:'Pending', value:'Pending'},
  3.       {id:'Complited', value:'Complited'}
  4.     ];
  5. $scope.workflowStatus = $scope.workflowStatusList[0]; // red
  6.  
  7. <!-- for Single  HTML -->
  8.  
  9. $scope.workflowStatusList = ['Pending','Complited'];
  10. $scope.workflowStatus = $scope.workflowStatusList[0]; // red
  11.  
  12. <!-- HTML -->
  13.  
  14. <select ng-model="workflowStatus" ng-options="wfs.id for wfs in workflowStatusList">
  15.       <option value="">Select status</option>
  16. </select>
  17.  
  18. <!-- for Single  HTML -->
  19.  
  20. <select ng-model="workflowStatus" ng-options="wfs for wfs in workflowStatusList">
  21.         <option value="">Select status</option>
  22. </select>