墨染丶

导航

2020年5月6日 #

SpringBoot 依赖注入

摘要: TestBiz接口: package example.biz; public interface TestBiz { public String getTest(String str); } TestBizImp接口实现类: package example.biz.imp; import examp 阅读全文

posted @ 2020-05-06 16:41 墨染丶 阅读(341) 评论(0) 推荐(0) 编辑

each循环方法跳出

摘要: #####.each { it -> if (!it.####) { return false // 相当于 for循环中的 break }}return true //相当于for循环中的 continue 阅读全文

posted @ 2020-05-06 10:55 墨染丶 阅读(264) 评论(0) 推荐(0) 编辑

2020年4月28日 #

grails中render、respond、redirect的使用

摘要: render: 界面跳转(url不变)、向网页输出数据(接口都用这个) render 之后,程序会继续执行,但是 后面不能使用 redirect 、respond 例如: def test() { def json = new JSON(School.findAll().first()) json. 阅读全文

posted @ 2020-04-28 16:18 墨染丶 阅读(389) 评论(0) 推荐(0) 编辑

2020年4月27日 #

searchBean 运算符

摘要: public static Operator from(String op) { switch (op) { case "in": //简写 case "Include": //sql中的 like 运算符 '%like%'前后均模糊搜索 return Include; case "eq": cas 阅读全文

posted @ 2020-04-27 19:22 墨染丶 阅读(426) 评论(0) 推荐(0) 编辑

2020年3月24日 #

公司大佬设计开源项目: OkHttp轻量封装 、功能全面、设计力求优雅与纯粹,Java领域前后端处Http问题的新选择

摘要: 地址:https://gitee.com/ejlchina-zhxu/httputils 阅读全文

posted @ 2020-03-24 14:15 墨染丶 阅读(131) 评论(0) 推荐(0) 编辑

2020年3月12日 #

Spring事务控制和传递性

摘要: 1.在同一类方法间相互调用,如果调用方无事务控制,被调用方有事务控制,则被调用方也无事务 原因:外部经过spring容器调用service的方法事务才生效,service类内部方法间相互调用事务不生效,也就是传说中的自调用失效问题。主要原因是 Spring数据库事务的约定,其实现原理是AOP,而AO 阅读全文

posted @ 2020-03-12 15:28 墨染丶 阅读(776) 评论(0) 推荐(0) 编辑

2020年1月19日 #

网页实现点击图片放大缩小 不随滚轮大小变化

摘要: css { .wrap { position: fixed; top: 0; left: 0; background: rgba(0, 0, 0, 0.7); z-index: 2; width: 100%; height: 100%; display: none;} } html { <div i 阅读全文

posted @ 2020-01-19 14:11 墨染丶 阅读(1040) 评论(0) 推荐(0) 编辑

2020年1月7日 #

textarea 文本框 实现右下角展现 动态字数

摘要: 文本框CSS .textarea-style{ border:1px solid #000001; border-radius:5pt; height:60pt; font-size:10pt; margin-bottom: 2vh; width:100%; color: #000001; over 阅读全文

posted @ 2020-01-07 13:11 墨染丶 阅读(4428) 评论(0) 推荐(0) 编辑

2019年12月26日 #

禁止<textarea>富文本拉伸的方式是设置 style="resize:none" 样式

摘要: style="resize:none" 阅读全文

posted @ 2019-12-26 15:55 墨染丶 阅读(1140) 评论(0) 推荐(0) 编辑

对html表格中的某一列进行替换(针对JQuery)

摘要: <style>.banner-title{ width: 1%; //设置样式,表格中文本的宽度会撑起外面表格的宽度}</style> function jsReady($) { $("tbody tr").each(function(){ //对tbody tr(行)进行遍历 var $td = 阅读全文

posted @ 2019-12-26 15:35 墨染丶 阅读(822) 评论(0) 推荐(0) 编辑