I am trying to implement selector pattern for lightning component. I have created this class to retrieve the data and fetch into a data table.But I am getting the following errors.
@Override specified for non-overriding method: List soco.DataImportController.getSObjectFieldList()
AuraEnabled methods do not support return type of Schema.SObjectType
@AuraEnabled
public Schema.SObjectType getSObjectType(){
return Opportunity.sObjectType;
}
public override List<Schema.SObjectField> getSObjectFieldList(){
return new List<Schema.SObjectField> {
Opportunity.AccountId,
Opportunity.Id,
Opportunity.Name,
Opportunity.StageName
};
}
Does selector patterns supported for lightning? Can anyone please help me.