0

我正在尝试将子网格添加到价目表项目的价目表实体。在插入子网格对话框中查看实体选项的下拉列表时,我没有看到价格表项目作为选项。经过进一步调查,列表中的唯一选项似乎是设置为可自定义的 1:N 关系,而价目表项则不是。

有谁知道这个的解决方法?

4

1 回答 1

0

我询问了 viewID,因为在“主”表单的 FormXml 中,您可以找到一个部分详细说明与(价格表)关联的产品的子网格是如何构建的,pricelevel并且主要参数是ViewId是您有兴趣查看/编辑的实体的系统视图 ID。

我询问了部署类型(内部部署与在线部署),因为您只需查看SavedQuery表中的数据库即可获取ViewIDfor productpricelevel(价格级别详细信息),但我相信您可以通过普通的 CRM 查询获得此信息也是。无论如何,我记录的“所有价目表项目”视图的 ViewID 是“AB4877E9-6D01-4D28-84C3-BE7564C1BB09”,我敢打赌它对您的组织来说是一样的。

使用此信息,您可以修改 FormXmlpricelevel并添加到子网格 XML 中productpricelevel,如下所示。如果您需要修改 UI 的布局,您可以查看具有您想要的布局的另一个实体并进行适当的修改。

<row>
  <!--cell id: a distinct GUID for this area of the form. Any will do.-->
  <cell id="{74e711eb-0eec-119e-8703-ce8b5dbbca94}" showlabel="true" colspan="1" auto="false" rowspan="8">
    <labels>
      <!--label description: the name (if any) of any label you want to see with the subgrid-->
      <label description="Price Level Detail" languagecode="1033" />
    </labels>
    <!--control id: the name of the subgrid
    classid: the type of control (in this case, a subgrid)-->
    <control id="CustomPriceLevelItemSubGrid" classid="{E7A81278-8635-4d9e-8D4D-59480B391C5B}">
      <parameters>
        <!--ViewID: the ID stored in the system for the entity you're interested in (in this case, productpricelevel/Price Level Detail)-->
        <ViewId>{AB4877E9-6D01-4D28-84C3-BE7564C1BB09}</ViewId>
        <IsUserView>false</IsUserView>
        <!--RelationshipName: the name of the relationship that links the two entities (pricelevel to productpricelevel)-->
        <RelationshipName>price_level_product_price_levels</RelationshipName>
        <!--TargetEntityType: the entity you want to see displayed in the subgrid-->
        <TargetEntityType>productpricelevel</TargetEntityType>
        <AutoExpand>Fixed</AutoExpand>
        <EnableQuickFind>true</EnableQuickFind>
        <EnableViewPicker>true</EnableViewPicker>
        <ViewIds></ViewIds>
        <EnableJumpBar>true</EnableJumpBar>
        <ChartGridMode>Grid</ChartGridMode>
        <VisualizationId></VisualizationId>
        <IsUserChart>false</IsUserChart>
        <EnableChartPicker>false</EnableChartPicker>
        <RecordsPerPage>4</RecordsPerPage>
      </parameters>
    </control>
  </cell>
</row>
<row />
<row />
<row />
<row />
<row />
<row />
<row />
于 2011-12-04T04:54:50.183 回答