How to modify non-customizable entity in MS Dynamics CRM 4.0 (Add Product price column to Price List...

本文介绍了一种在MS CRM 4.0中为产品价格清单视图添加单价字段的方法。由于PriceList实体默认不可定制,文章提供了一个SQL技巧来更新数据库设置,使实体变得可定制,从而允许用户修改视图并加入金额字段。

For one of the clients, there was a simple and understandable yet not-that-easy-to-do requirement to add a price next to each product displayed as price list item under the price list. MS guys probably forgot about the basic need of anyone setting up the product catalogue and price lists and that is quick and easy review of the prices of the products.

The first idea is to go to the Customizations area, where you can customize entities, find the corresponding view, add and reshuffle columns according to requirement, publish, done. Not that easy this time. Although the Price List entity is displayed as Customizable, when you actually want to customize it, it turns out it is not. And you cannot even see any forms and views related to this entity. That should basically prevent you from modifying it and preparing you for an unpleasant situation where client is told - “this is not possible…” And clients like it very much! ;)

But there is a little trick that can do it and let you modify the view of product list items so that you can add amount field (price) to the view.

In MS CRM 4.0 SQL database there is a table containing settings for all entities present in the system and it is called… Entity. In this table there is a column named IsCustomizable and this is set to 0 (zero) for the PriceList entity.

  1. Open SQL Server Management Studio
  2. Connect to MSCRM database (not the config one, but the real one with MSCRM tables)
  3. Run following update command:
update ENTITY
set ISCUSTOMIZABLE = 1
WHERE NAME = 'ProductPriceLevel'

note: Entity is a DB synonym for Metadata.Entity table

Then you can drill down to the corresponding view in the CRM / Settings / Customization / Price List Item.

When you open the entity page you can see the node for Forms and Views - not present there previously, and you can modify the view - Product Price List - Price List as any other views in the system. Add column Amount (Base), save and publish. After that you can see that there is price displayed next to each Price List Item (Product) in that particular view.

转载于:https://www.cnblogs.com/janmson/archive/2009/06/24/1510347.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值