- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
有没有一种方法可以将PropertyEditor关联到特定的Controller。
我可能想为DateTime类使用两个PropertyEditor,并将它们与不同的 Controller 关联。
或具有2个Date字段的域类,一个需要更改2010-12-23的日期,另一个需要更改2010-12-23 10:00:01
最佳答案
无法与 Controller 关联。 PropertyEditorRegistrar
对于registerCustomEditor()
只有两个签名:整个属性类和属性名称。
第二个签名在Grails 1.3.6 之前不起作用,这是一个错误GRAILS-6592。
所以
registry.registerCustomEditor(Date.class, 'startDate', new MyDateAddressEditor())
关于grails - 将PropertyEditor关联到特定 Controller ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4511050/
当将 PropertyEditors 与 Spring MVC 一起使用时,让它们从数据库中获取实体是不是很糟糕?我是否应该创建一个空实体并设置其 ID。 例如实体Employee: @Entity
本文整理了Java中org.springframework.beans.propertyeditors.ZoneIdEditor类的一些代码示例,展示了ZoneIdEditor类的具体用法。这些代码示
我一直在寻找任何使用 ControlsFX PropertySheet 的好例子,但除了这个找不到任何东西。 https://www.google.nl/search?q=Main.java+amaz
我在 ExtJS 中有一个 PropertyEditor。 Ext.define('PropertyEditorGrid', { //... this.flexColumnGrid = E
我发现 PropertyEditorManager根据 ThreadGroupContext 注册/查找编辑基础,而不是 Java7 之前的每个全局注册表。 而 Java7 每次都会为新的 Threa
当我提交 Spring 表单并且 PropertyEditor 无法转换值时,会引发异常,并且这样的消息最终会出现在我的验证器错误对象中: Failed to convert property val
使用 Spring 3.1 并给出这种东西: class Thing { public Thing() {} public Thing(String someProperty) {} } cl
我在提交表单时遇到 Ajax 请求问题。表单包含这些字符串化 JSON 数据: {"articleContent":"aaa","title":"Po vyplnění titulku aktuali
本文整理了Java中org.springframework.beans.propertyeditors.ZoneIdEditor.()方法的一些代码示例,展示了ZoneIdEditor.()的具体用法
本文整理了Java中org.springframework.beans.propertyeditors.ZoneIdEditor.getValue()方法的一些代码示例,展示了ZoneIdEditor
我是 Spring 3 MVC 的新手,正在尝试实现 PropertyEditor。下面是我尝试过的代码: Employee.java private String name; private Str
我有一个 PropertyEditor 以便将 ids 转换为 Persons,它的 setAsText(字符串文本)如下: public void setAsText(String text) th
我正在使用 spring batch 进行文件到数据库的处理,目前我正在使用 PropertyEditors将分隔文件中的字符串转换为下面提供的某个对象。 Map, PropertyEditor> e
使用 Spring MVC事实证明,我可以用许多不同的方式绑定(bind)我的表格,我真的觉得自己迷路了。 parse和 print Formatter 的方法相当于那些 PropertyEditor
我正在使用 Spring 3.0.3。我通过将此行添加到我的 Spring 配置 XML 中启用了默认的 ConversionService。 我还为某些数据类型使用自定义 PropertyEdit
我正在使用 SWT/JFACE 开发游戏编辑器。我正在 SWT 中寻找诸如 PropertyEditor 或 PropertyGrid (如 C# 中的 PropertyGrid)之类的东西,以提供编
我想知道是否有办法在 Spring MVC 3.0 之后全局注册 PropertyEditor。在文档 their documentation 中它们展示了如何使用注解在每个 Controller 的
这是我的 applicationContext.xml 的样子: ............
我是一名优秀的程序员,十分优秀!