K3 单据,单据体自定义字段显示及时库存

--1、解决了显示可发数量的单据,且已经审核的单据,库存数据更新后,单据上的可发数量随库存变化,现在能实现当时的可发数量和件数保存到单据中
--2、解决了负库存数据显示为0的问题
--2011.09.28 by 申宪峰

--更改显示现库存和可发件数的单据模板的取数方式
--领料单
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='B04' and ffieldname='FEntrySelfB0426'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='B04' and ffieldname='FEntrySelfB0427'

--产成品入库
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='A02' and ffieldname='FEntrySelfA0225'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='A02' and ffieldname='FEntrySelfA0226'

--其他入库
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='A97' and ffieldname='FEntrySelfA9726'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='A97' and ffieldname='FEntrySelfA9727'

--其他出库
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='B09' and ffieldname='FEntrySelfB0924'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='B09' and ffieldname='FEntrySelfB0925'

--销售订单
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='S01' and ffieldname='FEntrySelfS0133'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='S01' and ffieldname='FEntrySelfS0134'

--发货通知单
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='S02' and ffieldname='FEntrySelfS0218'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='S02' and ffieldname='FEntrySelfS0221'

--采购申请单
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='P01' and ffieldname='FEntrySelfP0118'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='P01' and ffieldname='FEntrySelfP0119'

--采购订单
update ictemplateentry set frelationid='fitemid',faction='.,f_104' where fid='P02' and ffieldname='FEntrySelfP0223'
update ictemplateentry set frelationid='fitemid',faction='.,f_105' where fid='P02' and ffieldname='FEntrySelfP0226'

 -采购申请单,上限,下限,到货周期
select * from ictemplateentry where fid='p01'

update ictemplateentry set frelationid='fitemid',faction='.,FLOWLIMIT' where fid='P01' and ffieldname='FEntrySelfP0116'
update ictemplateentry set frelationid='fitemid',faction='.,FHIGHLIMIT' where fid='P01' and ffieldname='FEntrySelfP0117'
update ictemplateentry set frelationid='fitemid',faction='.,FFIXLEADTIME' where fid='P01' and ffieldname='FEntrySelfP0120'

--采购订单,上限,下限,计划单价
select * from ictemplateentry where fid='p02'

update ictemplateentry set frelationid='fitemid',faction='.,FLOWLIMIT' where fid='P02' and ffieldname='FEntrySelfP0224'
update ictemplateentry set frelationid='fitemid',faction='.,FHIGHLIMIT' where fid='P02' and ffieldname='FEntrySelfP0225'
update ictemplateentry set frelationid='fitemid',faction='.,FPLANPRICE' where fid='P02' and ffieldname='FEntrySelfP0227'

--购货发票,计划单价
select * from ictemplateentry where fid='I02'
update ictemplateentry set frelationid='fitemid',faction='.,FPLANPRICE' where fid='I02' and ffieldname='FEntrySelfI0231'

  • 0
    点赞
  • 11
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值