File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
backend/src/main/java/com/ai/lawyer/global/config Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change 11package com .ai .lawyer .global .config ;
22
33import org .springframework .beans .factory .annotation .Value ;
4+ import org .springframework .boot .context .properties .ConfigurationProperties ;
45import org .springframework .boot .jdbc .DataSourceBuilder ;
56import org .springframework .context .annotation .Bean ;
67import org .springframework .context .annotation .Configuration ;
@@ -34,6 +35,7 @@ public class DataDBConfig {
3435
3536 @ Bean
3637 @ Primary
38+ @ ConfigurationProperties (prefix = "spring.datasource" )
3739 public DataSource dataDBSource () {
3840 return DataSourceBuilder .create ()
3941 .url (url )
@@ -50,7 +52,7 @@ public LocalContainerEntityManagerFactoryBean dataEntityManager() {
5052 LocalContainerEntityManagerFactoryBean em = new LocalContainerEntityManagerFactoryBean ();
5153
5254 em .setDataSource (dataDBSource ());
53- em .setPackagesToScan (new String []{"com.ai.lawyer.domain.* " });
55+ em .setPackagesToScan (new String []{"com.ai.lawyer.domain" });
5456 em .setJpaVendorAdapter (new HibernateJpaVendorAdapter ());
5557
5658 HashMap <String , Object > properties = new HashMap <>();
You can’t perform that action at this time.
0 commit comments