Home Reference Source
public class | source

Editor

Extends:

React.Component → Editor

Editor component has theese props:

  • validator - required validator interface { validate: (data, ctx) => Promise, validateProp: (name, value, ctx, data) => Promise }
  • updateErrorMessage - default error message, when update fails
  • loadingErrorMessage - default error message, when loading fails

Not required, when running inside the {TableEditor}

  • id - identifier of item to edit
  • data - data to edit (if provided, data are not loaded from resource)
  • resource - API url or {AjaxResource} interface
  • t - translator function
  • modalTitle - boolean or string, which shows editor as Modal
  • onSubmitDidFinish - success callback after submit
  • onSubmitDidFail - error callback after submit