导航

上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 13 下一页

2013年12月30日

摘要: Hibernate,jpa注解映射中A多对一BA的表中有B的外键。如果想只获取A表中的B的外键而不想发送查询B的sql语句。那么: @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.MERGE}) @JoinColumn(name="userid") private User user;//用户 @Column(name="userid", updatable=false, insertable=false) private Long user_fk;//用户id只需要添加一个外键的属性配置为 @C 阅读全文

posted @ 2013-12-30 02:56 曙光城邦 阅读(903) 评论(0) 推荐(0) 编辑

2013年12月25日

摘要: KeywordSampleJPQL snippetAndfindByLastnameAndFirstname… where x.lastname = ?1 and x.firstname = ?2OrfindByLastnameOrFirstname… where x.lastname = ?1 or x.firstname = ?2BetweenfindByStartDateBetween… where x.startDate between 1? and ?2LessThanfindByAgeLessThan… where x.age ?1AfterfindByStartDateAfte. 阅读全文

posted @ 2013-12-25 17:47 曙光城邦 阅读(927) 评论(0) 推荐(1) 编辑

2013年12月14日

摘要: 一、引入js文件二、增加图片上传功能 uploadUrl为上传图片的servlet,或controller。 #editor1为textarea的id三、编写上传类,返回回调函数/**图片上传 * @author Administrator * */@Controller@RequestMappin... 阅读全文

posted @ 2013-12-14 18:34 曙光城邦 阅读(574) 评论(0) 推荐(0) 编辑

2013年12月9日

摘要: 左侧固定,右侧宽度100%自适应左侧宽度200px右侧宽度100%看了N篇文章,找了N中答案,什么clear啊,float啊,原来正道才是这么简单,而且100%兼容。Good!对于右侧嵌入iframe, 则是 兼容ie6 ff等等但不能使用css指定iframe的width height,否则存在浏览器兼容问题 阅读全文

posted @ 2013-12-09 14:47 曙光城邦 阅读(586) 评论(0) 推荐(0) 编辑

2013年12月6日

摘要: 11-12买的书,花费邮资50多元选的是特快专递,提示我预计四天内书就到了经过23天后!23天后...奇迹发生了!!! 书还在北京!!才开始配送 ....打过不下5次电话...直达23天后.....才有了反应!!!以后买书! 还是老老实实到亚马逊吧!!!! 阅读全文

posted @ 2013-12-06 15:35 曙光城邦 阅读(261) 评论(0) 推荐(0) 编辑

2013年11月29日

摘要: http://www.ibm.com/developerworks/cn/opensource/os-cn-spring-jpa/持久层的实现类可以让框架生成。只需要声明持久层接口,框架直接生成代理类,开箱即用N种重复性的增删改查功能 阅读全文

posted @ 2013-11-29 14:58 曙光城邦 阅读(191) 评论(0) 推荐(0) 编辑

2013年11月8日

摘要: 使用SpringMVC spring dwr时,dwr使用的bean,要将bean配置到根webapplicationcontext中,即applicationContext.xml中,不能放到dispatcher-servlet.xml中。否则会报NoSuchBeanDefinitionException异常。 阅读全文

posted @ 2013-11-08 22:31 曙光城邦 阅读(232) 评论(0) 推荐(0) 编辑

2013年11月5日

摘要: 中文版 http://ishare.iask.sina.com.cn/f/11908269.html想找点资料,MB啊,操了,百度成屎了没啥好教程擦了,这些傻逼博主,写的Jb啥吗,代码不能跑,文字描述差。 希望以后我不要傻逼,能让大家最起码跑起一个demo。就一个最简单的demo,搞了两个小时,才出来,MB啊。回调不说回调,莫名其妙的多东西,粘贴一堆JB代码,干啥的也不说。dwr是服务器推送数据到客户端,你tm全是客户端js调用服务器端java函数,干毛擦,我要的是服务器调客户端往那边传数据啊 擦,你妹啊,你姐啊 阅读全文

posted @ 2013-11-05 15:28 曙光城邦 阅读(266) 评论(0) 推荐(0) 编辑

2013年10月31日

摘要: springMVC 表单验证demo 视图层使用的是jsp提交表单验证失败添加成功界面,防刷新SSHDemo3.zip 22kbhttp://pan.baidu.com/s/1gQ2IS 阅读全文

posted @ 2013-10-31 01:00 曙光城邦 阅读(440) 评论(0) 推荐(0) 编辑

2013年10月30日

摘要: @RequestMapping("/add2") public String addStudentValid(@Valid @ModelAttribute("s") Student s,BindingResult result){ if(result.hasErrors()){ List fieldErrors = result.getFieldErrors(); for (FieldError fieldError : fieldErrors) { log.info(... 阅读全文

posted @ 2013-10-30 00:15 曙光城邦 阅读(7386) 评论(0) 推荐(0) 编辑

上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 13 下一页