{{#*inline "getPortlet" portlet}}
  {{~#eq portlet.portletType 'CONTAINER'~}}
    {{#if portlet.psControls}}
      {{~#each portlet.psControls as | control |~}}
{{> getPortlet portlet=control}}{{#unless @last}},{{/unless}}
      {{~/each~}}
    {{/if}}
  {{~else~}}
'{{portlet.name}}'
  {{~/eq~}}
{{/inline}}
// 部件配置对象
export const ctrlState = () => {
  return {
    controlCodeName: '{{ctrl.codeName}}',
    controlName: '{{ctrl.name}}',
    isEnableCustomized: {{ctrl.enableCustomized}},
    portlets: [
      {{~#each ctrl.psControls as | portlet |~}}
        {{> getPortlet portlet=portlet}}{{#unless @last}},{{/unless}}
      {{~/each~}}
    ]
  }
}