UserType / Hibernate / JodaMoney error : PersistentMoneyAmount requires currencyCode to be defined as a parameter

前端 未结 3 1832
孤街浪徒
孤街浪徒 2021-01-24 20:20

I\'m using UserType 3.0.0.RC1 to map JodaMoney to Hibernate.

I\'m stuck with an error when the SessionFactory initialises:

PersistentMoneyAmount r

3条回答
  •  粉色の甜心
    2021-01-24 21:07

    I ended up solving this using the following configuration in my persistence.xml:

    
        
            
            
            
            
            
        
    
    

    The tricky part is that I needed to provide a jadira.usertype.seed in order for the jadira.usertype.currencyCode to be detected.

提交回复
热议问题