"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});

var _reactIntl = require("react-intl");

const template = configContext => {
  const React = configContext.lib.React;
  var _configContext$layout = configContext.layoutComponents;
  const Col = _configContext$layout.Col,
        Cols = _configContext$layout.Cols,
        Panel = _configContext$layout.Panel;
  const Field = configContext.recordComponents.Field;


  return React.createElement(
    Field,
    { name: "document" },
    React.createElement(
      Panel,
      { name: "info", collapsible: true },
      React.createElement(
        Cols,
        null,
        React.createElement(
          Col,
          null,
          React.createElement(Field, { name: "valuationcontrolRefNumber" }),
          React.createElement(
            Field,
            { name: "valueAmountsList" },
            React.createElement(
              Field,
              { name: "valueAmounts" },
              React.createElement(Field, { name: "valueCurrency" }),
              React.createElement(Field, { name: "valueAmount" })
            )
          ),
          React.createElement(Field, { name: "valueDate" }),
          React.createElement(Field, { name: "valueRenewalDate" })
        ),
        React.createElement(
          Col,
          null,
          React.createElement(Field, { name: "valueSource" }),
          React.createElement(Field, { name: "valueType" }),
          React.createElement(Field, { name: "valueNote" })
        )
      )
    )
  );
};

exports.default = configContext => ({
  messages: (0, _reactIntl.defineMessages)({
    name: {
      "id": "form.valuation.default.name",
      "defaultMessage": "Standard Template"
    }
  }),
  template: template(configContext)
});