在角度6中使用日期选择器时,我收到此错误
错误错误:未捕获(在承诺中):错误:StaticInjectorError(AppModule)[AddBidComponent - > Date]:StaticInjectorError(Platform:core)[AddBidComponent - > Date]:NullInjectorError:没有Date的提供者!错误:StaticInjectorError(AppModule)[AddBidComponent - > Date]:StaticInjectorError(Platform:core)[AddBidComponent - > Date]:NullInjectorError:没有Date的提供者!
我已经在提供程序中添加了日期类
我附上我的模块类也请查看它
import { BsDatepickerModule } from 'ngx-bootstrap/datepicker';
@NgModule({
imports: [
CommonModule,
GooglePlaceModule,
AgmCoreModule.forRoot({apiKey: 'api-key'}),
BsDatepickerModule.forRoot()
],
declarations: [
SingleProjectComponent,
AddBidComponent
],
providers: [
GoogleMapsAPIWrapper,
GoogleMapService,
BsDatepickerModule
]
})
export class SingleProjectModule { }
请帮我解决这个错误