我在數組中添加了物品值存儲列表,如何將角度數組列表傳遞給控制器。如何將角度數組列表傳遞給控制器
$ scope.AddRecord = [];
$scope.AddUpdateItem = function (item_id, item_discription, item_quantity, item_unit, item_rate, item_discount) {
var getItemAction = $scope.Action;
if (getItemAction == "Update") {
$scope.AddRecord[key].budget_item_id = item_id;
$scope.AddRecord[key].budget_item_discription = item_discription;
$scope.AddRecord[key].budget_item_quantity = item_quantity;
$scope.AddRecord[key].budget_item_unit = item_unit;
$scope.AddRecord[key].budget_item_rate = item_rate;
$scope.AddRecord[key].budget_item_discount = item_discount;
$scope.divItem = false;
ClearFields();
} else
{
$scope.AddRecord.push({ 'budget_item_id': $scope.item_id, 'budget_item_discription': $scope.item_discription, 'budget_item_quantity': $scope.item_quantity, 'budget_item_unit': $scope.item_unit, 'budget_item_rate': $scope.item_rate, 'budget_item_discount': $scope.item_discount });
ClearFields();
}
}
我添加的項值店的名單陣列,但我不能夠通過列表控制器,所以請有人幫助我如何通過角數組列表到控制器
做ÿ ou想通過它另一個控制器或想要使用 –
感謝重播我想通過我的asp.net mvc控制器,因爲我需要在數據庫 –
存儲值請看看..你在尋找這.. http:///stackoverflow.com/questions/9293423/can-one-controller-call-another/31469444#31469444 –