09保时捷卡宴
--修改启用期间-年份
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='StartYear')
UPDATE  t_SystemProfile SET FValue='2010' WHERE  FCategory='IC' AND Fkey='StartYear'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','CurrentYear','2010')
--修改启用期间-月份
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='StartPeriod')
UPDATE  t_SystemProfile SET FValue='1' WHERE  FCategory='IC' AND Fkey='StartPeriod'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','StartPeriod','1')
--修改当前期间-年份
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='CurrentYear')
UPDATE  t_SystemProfile SET FValue='2010' WHERE  FCategory='IC' AND Fkey='CurrentYear'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','CurrentYear','2010')
--修改当前期间-月份
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='CurrentPeriod')
UPDATE  t_SystemProfile SET FValue='1' WHERE  FCategory='IC' AND Fkey='CurrentPeriod'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','CurrentPeriod','1')
--修改单据保存后更新库存
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='UPSTOCKWHENSAVE')
UPDATE  t_SystemProfile SET FValue='1' WHERE  FCategory='IC' AND Fkey='UPSTOCKWHENSAVE'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','UPSTOCKWHENSAVE','1')
--修改单据审核后更新库存
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='UPSTOCKWHENSAVE')
UPDATE  t_SystemProfile SET FValue='0' WHERE  FCategory='IC' AND Fkey='UPSTOCKWHENSAVE'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','UPSTOCKWHENSAVE','0')
--修改数量核算状态下,期末处理在“采购模块”
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='CloseInModule')
UPDATE  t_SystemProfile SET FValue='100' WHERE  FCategory='IC' AND Fkey='CloseInModule'
天津一汽夏利汽车股份有限公司
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','CloseInModule','100')
--修改数量核算状态下,期末处理在“仓存模块”
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='CloseInModule')
UPDATE  t_SystemProfile SET FValue='101' WHERE  FCategory='IC' AND Fkey='CloseInModule'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','CloseInModule','101')
--修改数量核算状态下,期末处理在“销售模块”
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='CloseInModule')
UPDATE  t_SystemProfile SET FValue='103' WHERE  FCategory='IC' AND Fkey='CloseInModule'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','CloseInModule','103')
------------------------------------------------仓存系统是否显示金额信息---------------------------------------------北京二手车58
IF Exists(select * from t
_SystemProfile WHERE  FCategory='IC' AND Fkey='MoneyVisForStock')
英菲尼迪万人盛典
UPDATE  t_SystemProfile SET FValue='1' WHERE  FCategory='IC' AND Fkey='MoneyVisForStock'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','MoneyVisForStock','1')
-------------------------------------------------------------------------------------------------------------
--核算项目选择【0:数量核算;1:数量金额核算】成都限号2023年1月最新限号时间表
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='AuditChoice')
UPDATE  t_SystemProfile SET FValue='0' WHERE  FCategory='IC' AND Fkey='AuditChoice'
ELSE
INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','AuditChoice','0')
--暂估的某种设置,未知----------------------------------------------
IF Exists(select * from t_SystemProfile WHERE  FCategory='IC' AND Fkey='ZanguVoucher')
UPDATE  t_SystemProfile SET FValue='0' WHERE  FCategory='IC' AND Fkey='ZanguVoucher'
ELSE
陆尊gl8INSERT INTO t_SystemProfile(FCategory,FKey,FValue) Values('IC','ZanguVoucher','0')
---------------------------------------------------------------------------------
--修改成数量核算下所执行代码,作用未知----------------
Update ICOperate SET FALLOW=1 WHERE FID IN ('0104','010401','010402')
UPDATE  t_dataflowsubfunc SET  fvisible=0 WHERE  fsubfuncid=2080 
UPDATE  t_dataflowsubfunc SET  fvisible=0 WHERE  fsubfuncid=2380 
UPDATE  t_dataflowsubfunc SET  fvisible=1 WHERE  fsubfuncid=2180 
UPDATE t_DataFlowTimeStamp SET FName=FName
--修改成数量金额核算下所执行代码,作用未知----------
Update ICOperate SET FALLOW=0 WHERE FID IN ('0005','000501','0104','010401','010402','0405','040501')
UPDATE  t_dataflowsubfunc SET  fvisible=0 WHERE  fsubfuncid=2080 
UPDATE  t_dataflowsubfunc SET  fvisible=0 WHERE  fsubfuncid=2380 
UPDATE  t_dataflowsubfunc SET  fvisible=0 WHERE  fsubfuncid=2180 
UPDATE t_DataFlowTimeStamp SET FName=FName