菜鸟一枚,最近做项目接触新的jersey框架,做一个新增的功能,但是前台文本框输入的内容,
到后台取值的时候为null了,后台的方法是进去了的,但是值为null,百思不得其解
这是我页面代码 ,有点丑不要见怪
然后页面是被js引用的,js代码如下:
$scope.saveAddress=function(){
addAddress($scope, $rootScope,null,$http,$httpParamSerializer);
}
function addAddress($scope, $rootScope, $state,$http,$httpParamSerializer){
var basePath = getHostDomain();
httpGetDataByGet(basePath+'rest/service/main/addAddress',null,function(dt){
$scope.user.thisPermissions = dt.persissions;
});
}
你要贴页面源码和后台源码才能看哟
是不是属性的名称写的不对
做编辑的时候 判断 当传过来的值不为NULL和空的时候才进行更新操作