TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
ali ramezani
NA
16
570
Don't Fill Data to dropdown list in angularjs!
Nov 1 2017 6:02 PM
I write this code, but not work!!
please help me.
Controller:
(function () {
appModule.controller('education.views.students.createOrEditModal', [
'$scope', '$window','$uibModalInstance', 'abp.services.app.student', 'studentId', 'abp.services.app.city', 'uiGridConstants',
function ($scope, $window, $uibModalInstance, studentService, studentId, cityService, uiGridConstants) {
var vm = this;
vm.saving = false;
vm.student = null;
vm.selectedCity = null;
vm.Cities = [];
vm.GetValue = function () {
var CityId = vm.selectedCity.Id;
var CityName = vm.selectedCity.Name;
//console.log(CityId, CityName);
cityService.getCities({
}).then(function (result) {
vm.Cities = result.data;
//console.log(vm.Cities);
});
};
cshtml:
<div ng-app="appModule">
<div ng-controller="education.views.students.createOrEditModal">
<select ng-model="selectedCity" ng-options="City as City.name for City in vm.Cities track by City.Id" ng-change="vm.GetValue()">
<option value="">Select City</option>
</select>
<br />
@*selected Value is : {{selectedCity}}*@
</div>
</div>
Attachment:
Problem_Code.zip
Reply
Answers (
1
)
Implementation of DHTMLX / DayPoilet or FullCalendar
expected closing tag img error in itext xmlworker