-
-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JobScheduler.Hangfire.Notification System.InvalidCastException #1045
Comments
the JobNotification test currently are on refactoring, so they cannot validate that at least on the tested scenario they work. In any case without a sample and detailed steps on how to repro I cannot help mych |
I just configure a Execute Action Job, save one object in detail view and then force the trigger. |
sample please |
I'm working on a big project, and it's hard to me right now isolate same parts. About this situation i bypass it validating the Object Type in the Notificaton Module:
I have one last question regarding the creation of Object State Notification, and it's why some Objects are not available to select in the Object Lookup. Curiously are the same as what I want. |
a lot can happen when u validate the problem against your big project and my resources are also very limited, that's why a sample is always the only way to go. your last question is unclear to me best guess you need to see how the objects populate [DataSourceProperty(nameof(Objects))]
[ValueConverter(typeof(ObjectTypeValueConverter))]
[Persistent][RuleRequiredField]
public ObjectType Object {
get => _object;
set => SetPropertyValue(nameof(Object), ref _object, value);
}
[Browsable(false)]
public IList<ObjectType> Objects
=> ((IModelJobSchedulerNotification)CaptionHelper.ApplicationModel
.ToReactiveModule<IModelReactiveModulesJobScheduler>().JobScheduler).Notification.Types
.Select(type => new ObjectType(type.Type.TypeInfo.Type) {Name = type.Type.Caption}).ToArray(); |
there are detailed docs https://github.com/eXpandFramework/Reactive.XAF/tree/master/src/Modules/JobScheduler.Notification is your type there? |
Exception occurs after trigger Execute Action Job :
System.InvalidCastException
HResult=0x80004002
Message=Unable to cast object of type 'Xpand.XAF.Modules.JobScheduler.Hangfire.BusinessObjects.ExecuteActionJob' to type 'Xpand.XAF.Modules.JobScheduler.Hangfire.Notification.BusinessObjects.ObjectStateNotification'.
Source=Xpand.XAF.Modules.JobScheduler.Notification
StackTrace:
at Xpand.XAF.Modules.JobScheduler.Hangfire.Notification.NotificationService.<>c__DisplayClass4_0.b__1(IObjectSpace objectSpace) in C:\Users\ricardo\Desktop\grupolc_sigo\JobScheduler.Notification\NotificationService.cs:line 58
at System.Reactive.Linq.ObservableImpl.Using
2._.Run(Using
2 parent)The text was updated successfully, but these errors were encountered: