springboot项目使用myBatistaplus代码生成器生成代码后启动报错问题

报错内容:
Error creating bean with name 'modelApplicationServiceImpl': Unsatisfied dependency expressed through field 'baseMapper'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.lxjn.hgd.module.model.mapper.ModelApplicationMapper' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}

图:
原因:myBatistaplus代码生成器生成的代码
mapper层代码不会加@Mapper注解
解决办法:
方法一、给mapper层代码加上@Mapper注解
方法二、在启动类上加@MapperScan("mapper包的引用路径")注解
发表评论 / Comment

用心评论~

金玉良言 / Appraise
HenryditLV 1
2021-01-10 18:36
只有一个点击可以长大你的钱真的很快。
链接 - http://gasthausamflughafen.de/food-delivery-bitcoin.php
HenryditLV 1
2021-01-10 14:29
使用金融机器人开始您的在线工作。
链接 - http://gasthausamflughafen.de/failed-bitcoin.php
HenryditLV 1
2021-01-10 04:55
你的钱工作,即使你睡觉。
链接 - http://stuntszene.de/cara-menambang-bitcoin-di-hp-android.php
HenryditLV 1
2021-01-10 04:55
金融机器人是#1投资工具永远。 发射!
链接 - http://stuntszene.de/win-free-bitcoins.php
HenryditLV 1
2021-01-10 01:18
使用这个机器人是让你致富的最佳方式。
链接 - - http://t-protex.de/bitcoin-cash-purchase-disabled.php
HenryditLV 1
2021-01-10 00:22
需要现金? 启动这个机器人,看看它可以。
链接 - - http://natur-holzbausteine.de/dutch-exchange-bitcoin.php
HenryditLV 1
2021-01-09 23:38
让金融机器人成为您在金融市场的同伴。
链接 - http://gasthausamflughafen.de/market-bitcoin-gold.php
HenryditLV 1
2021-01-09 18:59
赚$1000一天很容易,如果你使用这个金融机器人。
链接 - http://t-protex.de/can-i-buy-and-sell-bitcoin-same-day.php
HenryditLV 1
2021-01-09 14:27
机器人不夜城。 它为你24/7钱24/7.
链接 - http://gasthausamflughafen.de/how-to-exchange-btc-to-usd-on-binance.php
HenryditLV 1
2021-01-09 10:57
让您的计算机是你earning钱的工具。
链接 - - http://gasthausamflughafen.de/bitcoin-cash-to-btc-exchange.php