Skip to content

Conversation

@kurtnordstrom
Copy link

No description provided.

func (a *PatronRequestApiHandler) GetPatronRequests(w http.ResponseWriter, r *http.Request, params proapi.GetPatronRequestsParams) {
symbol, err := api.GetSymbolForRequest(r, a.tenant, params.XOkapiTenant, params.Symbol)
logParams := map[string]string{"method": "GetPatronRequests", "side": params.Side, "symbol": symbol}
func (a *PatronRequestApiHandler) GetStateModelModelsReturnables(w http.ResponseWriter, r *http.Request) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kurtnordstrom let's bundle returnables.yaml with the app and unmarshal here and serialize on GET

InvokeAction(common.ExtendedContext, events.Event)
}

type ReturnablesPatronRequestActionService struct {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kurtnordstrom action mapping service should not be state model specifc, it's just a collection of all action implementationsthat can be used in a specific state model

- actionResult

paths:
/state_model/models/returnables:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kurtnordstrom let's not harcode the state model name in the path but match the {name} against the bundled file name

}

/* Constructor function to initialize the mappings for the returnables */
func NewReturnableActionMapping() *ReturnableActionMapping {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kurtnordstrom let's pass StateModel to the constructor to set up the mapping and drop the ReturnableActionMapping concrete impl since, I think, it will all be controlled via the StateModel

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants