SysOperation framework doesn't show input parameters

As title, I added my controller to the menuItem and my and i can see the dialog, but when i press ok i get this error:

 controller class:

class ServiceLevelSupplierController extends SysOperationServiceController
{
    public static void main(Args _args)
    {
        ServiceLevelSupplierController controller = new ServiceLevelSupplierController(classStr(ServiceLevelSupplierController),methodStr(ServiceLevelSupplierService,process),SysOperationExecutionMode::Synchronous);
        controller.parmArgs(_args);
        controller.parmShowDialog(true);
        controller.startOperation();
    }

}

Contract class:

[DataContractAttribute]
class ServiceLevelSupplierContract 
{
    StartDate                       startDate;
    int                             numberOfMonths;
    str                             packedQuery;

    [DataMemberAttribute("StartDate"),SysOperationDisplayOrderAttribute("1")]
    public StartDate parmStartDate(TransDate    _startDate = startDate)
    {
        startDate = _startDate;

        return startDate;
    }

    [
        DataMemberAttribute('numberOfMonths'),
        SysOperationDisplayOrderAttribute("2")
    ]
    public Int parmNumberOfMonths(Int     _numberOfMonths = numberOfMonths)
    {
        numberOfMonths = _numberOfMonths;

        return numberOfMonths;
    }

    [
        DataMemberAttribute,
        AifQueryTypeAttribute('_packedQuery', queryStr(ServiceLevelSupplierQuery))
    ]
    public str parmQr(str _packedQuery = packedQuery)
    {
        packedQuery = _packedQuery;
        return packedQuery;
    }

    public void setQuery(Query _query)
    {
        packedQuery = SysOperationHelper::base64Encode(_query.pack());
    }

    public Query getQuery()
    {
        return new Query(SysOperationHelper::base64Decode(PackedQuery));
    }

Service class:

class ServiceLevelSupplierService extends SysOperationServiceBase
{
    QueryRun                             queryRun;
    StartDate                            startDate;
    int                                  numberOfMonths;
    PurchTable                           purchTable;
    PurchLine                            purchLine;
    VendTable                            vendTable;
    CalculationOfServiceLevel            CalculationOfServiceLevel;

    [SysEntryPointAttribute]
    public void process(ServiceLevelSupplierContract  _contract)
    {
        queryRun = new QueryRun(_contract.getQuery());


        this.getPromptParameters(_contract);

        while (queryRun.next())
        {
            CalculationOfServiceLevel.clear();
            purchTable     = queryRun.get(tableNum(PurchTable));
            purchLine      = queryRun.get(tableNum(PurchLine));
            vendTable      = queryRun.get(tableNum(VendTable));
            CalculationOfServiceLevel.VendAccount = vendTable.AccountNum;
            CalculationOfServiceLevel.insert();
        }
    }

    public void getPromptParameters(ServiceLevelSupplierContract _contract)
    {
        startDate                   = _contract.parmStartDate();
        numberOfMonths              = _contract.parmNumberOfMonths();
    }

}

what's wrong?

Related
Recommended