if(oldVid!=null) {
vs = new ViewStore(owner, oldVid);
} else {
vs = new ViewStore(null, "default");
}
ViewBean view = vs.get();
view.setOwner(request.getRemoteUser());
view.setName(name);
view.setDescription(name);
if(oldVid==null) {
view.setPermissionType("private");
}
vs = new ViewStore(request.getRemoteUser(), name);
vs.set(view);
} catch (Exception e) {
log.error(ExceptionUtil.getStackTrace(e));