无法在模式弹出窗口中显示 angular 架构表单

Could not display angular schema form in modal pop up

我正在尝试根据 json 数据制作一个 angular-schema-form 表单。 我的情况是,我有一个网格,我为此使用 ng-grid。因此,在网格的每一行上,我都有一个编辑按钮,允许用户编辑行 data.On 点击编辑按钮,出现一个模态弹出窗口。所以这里是我将模态弹出窗体设计为 angular-schema-form.Here 是我试过的。

这是我在网格中的编辑按钮模板

<div class="ui-grid-cell-contents">
  <button type="button"
     class="btn btn-xs btn-primary"
     ng-click="editRow(grid,row);">

  </button>
</div>

我的模态弹出模板是这样的

<div>
  <div class="modal-header">
      <h3 class="modal-title">Edit Row</h3>
  </div>
  <div class="modal-body">
    <form sf-schema="schema" sf-form="form" sf-model="entity"></form>
  </div>
  <div class="modal-footer">
      <button class="btn btn-success" ng-click="save()">Save</button>
      <button class="btn btn-warning" ng-click="$close()">Cancel</button>
  </div>
</div>

在我的 js 文件中,我的编码如下,这存在于主控制器中

 $scope.editRow = function (grid, row) {
        $modal.open({
            templateUrl: 'PopUpTemplate.htm',
            controller: function ($scope,$modalInstance,UserPopUpSchema, grid, row) {
               schema = UserPopUpSchema;
               entity = angular.copy(row.entity);
               form = [
           'FullName',
           'UserName',
           'Password',
           'EmailId',
           'phNum'
           ];


            },
            resolve: {
                grid: function () { return grid; },
                row: function () { return row; },
                UserPopUpSchema: function () {
                    return UserPopUpSchema;
                }
            }
        });
    };
} ]);

这里的用户弹出模式是一个常量,如下所示:

app.constant('UserPopUpSchema', {
    type: 'object',
    properties: {
        FullName: { type: 'string', title: 'FullName' },
        UserName: { type: 'string', title: 'UserName' },
        Password: { type: 'string', title: 'Password' },
        EmailAddress: { type: 'string', title: 'EmailId' },
        Phone: {type:'string',title:'phNum'}
    }
});

我已经按照 angular -schema-form documentation.But 中给出的正确添加了 js 文件 documentation.But 我无法显示 angular-schema-form。

感谢您的帮助

所以我在这里替换了模态弹出窗口中的表单

 form = [
           'FullName',
           'UserName',
           'Password',
           'EmailId',
           'phNum'
           ];

form["*"];

可能是语法错误。

而且我必须在控制器中访问具有范围依赖性的表单、模型、模式 作为 $scope.form,$scope.model,$scope.schema