I am new to software development and to angularjs, and am currently working through a simple project. I have a drop down box in my html that stores the user's selection in an angular model and I need to pass that string to my ASP.NET MVC model that is currently storing two properties that need to be defined. Here is my html:
<div data-ng-controller="EnvironmentController">
Environment:
<select data-ng-model="selectEnvironment">
<option data-ng-repeat="environment in environments"
value="{{environment}}">{{environment}}</option>
</select>
{{selectEnvironment}}
</div>
Then in my angular javascript file, I need to create a function that can send 'selectEnvironment' as a string back to my asp.net model below:
public class SelectionModels
{
public string selectVersion { get; set; }
public string selectEnv { get; set; }
}
Hope that is clear enough. Please let me know if there are any further questions or if I missed any details. THANK YOU!