SVN-Revision: r923
This commit is contained in:
cyf
2025-08-07 09:20:25 +00:00
parent 25e9863964
commit f7a53010be
9 changed files with 376 additions and 34 deletions
@@ -883,6 +883,23 @@ namespace Lskj.Business.Impl
and a.stepCode<{4} and a.stepCode<{4}
union all union all
select 0,'退回至提交人') x order by stepcode desc", masterTable, parmaryKey, columnPrefix, paramaryValue, currStepCode, flowStepTable, flowTypeStepTable); select 0,'退回至提交人') x order by stepcode desc", masterTable, parmaryKey, columnPrefix, paramaryValue, currStepCode, flowStepTable, flowTypeStepTable);
if (SystemInfo.Instance.SpecialReverseStep)
{
sqlValue = string.Format(@"select * from (select distinct a.stepCode,c.stepName
from {5} a
inner join {0} b on a.flowsourcekey=b.{1}
inner join {6} c on a.stepCode=c.stepCode and c.billType=b.{2}billtype
where a.flowSourceKey='{3}'
and isnull(a.autoStep,0)=0
and ISNULL(a.operDirection,'F')='F'
and a.stepCode<{4}
and a.operAdvice<>'自动亩核'
and a.operAdvice<>'不同意'
union all
select 0,'退回至提交人') x order by stepcode desc", masterTable, parmaryKey, columnPrefix, paramaryValue, currStepCode, flowStepTable, flowTypeStepTable);
}
return SqlHelper.ExecuteDataTable(sqlValue); return SqlHelper.ExecuteDataTable(sqlValue);
} }
@@ -938,6 +938,14 @@ namespace Lskj.Business.Impl
{ {
field += ",ImportCurrentValue"; field += ",ImportCurrentValue";
} }
if (HasExistsColumn("p_systembillsourcecond", "UnionFields"))
{
field += ",UnionFields";
}
if (HasExistsColumn("p_systembillsourcecond", "UnionValue"))
{
field += ",UnionValue";
}
string sqlValue = string.Format(@"select id,controlLeft,controlTop,controlWidth,controlHeight,controlType as fieldTypeId,controlName as fieldName,controlLabel as userName,'' DataFormat, string sqlValue = string.Format(@"select id,controlLeft,controlTop,controlWidth,controlHeight,controlType as fieldTypeId,controlName as fieldName,controlLabel as userName,'' DataFormat,
defaultValue,sourceSql as lookupSql,keyField as lookupKeyField,resultField as lookupResult,edited,checkCond,InputHintText{0} defaultValue,sourceSql as lookupSql,keyField as lookupKeyField,resultField as lookupResult,edited,checkCond,InputHintText{0}
from p_systembillsourcecond from p_systembillsourcecond
+27
View File
@@ -483,6 +483,33 @@ namespace Lskj.Business.Impl
if (HasExistsColumn("p_systembillDetail", "labelText")) if (HasExistsColumn("p_systembillDetail", "labelText"))
sumCond += ",a.labelText"; sumCond += ",a.labelText";
if (HasExistsColumn("p_systembillDetail", "canCopy"))
sumCond += ",a.canCopy";
if (HasExistsColumn("p_systembillDetail", "addModuleId"))
sumCond += ",a.addModuleId";
if (HasExistsColumn("p_systembillDetail", "UnionCompare"))
sumCond += ",a.UnionCompare";
if (HasExistsColumn("p_systembillDetail", "isExportColumns"))
sumCond += ",a.isExportColumns";
if (HasExistsColumn("p_systembillDetail", "Summation"))
sumCond += ",a.Summation";
if (HasExistsColumn("p_systembillDetail", "IsRadio"))
sumCond += ",a.IsRadio";
if (HasExistsColumn("p_systembillDetail", "SearchBoxAddition"))
sumCond += ",a.SearchBoxAddition ";
if (HasExistsColumn("p_systembillDetail", "RepeatedVerification"))
sumCond += ",a.RepeatedVerification ";
if (HasExistsColumn("p_systembillDetail", "LookUpWidth"))
sumCond += ",a.LookUpWidth ";
if (HasExistsColumn("p_systembillDetail", "LookUpFieldsWidth"))
sumCond += ",a.LookUpFieldsWidth ";
if (HasExistsColumn("p_systembillDetail", "PrivilegeView"))
sumCond += ",a.PrivilegeView ";
if (HasExistsColumn("p_systembillDetail", "PrivilegeOper"))
sumCond += ",a.PrivilegeOper ";
if (HasExistsColumn("p_systembillDetail", "ProhibitPaste"))
sumCond += ",a.ProhibitPaste ";
string columsSql = string.Format(@"SELECT DISTINCT string columsSql = string.Format(@"SELECT DISTINCT
isnull(CASE WHEN ISNULL(b.userList,'')='' AND ISNULL(a.PrivilegeView,'')<>'' OR isnull(isVisible,0)=1 THEN 0 ELSE width END,0) width, isnull(CASE WHEN ISNULL(b.userList,'')='' AND ISNULL(a.PrivilegeView,'')<>'' OR isnull(isVisible,0)=1 THEN 0 ELSE width END,0) width,
isnull(CASE WHEN ISNULL(c.userList,'')='' AND ISNULL(a.PrivilegeOper,'')<>'' THEN 1 ELSE edited END,0) edit,isnull(isVisible,0) isVisible, isnull(CASE WHEN ISNULL(c.userList,'')='' AND ISNULL(a.PrivilegeOper,'')<>'' THEN 1 ELSE edited END,0) edit,isnull(isVisible,0) isVisible,
+1 -24
View File
@@ -219,27 +219,4 @@ namespace Lskj.Business.Impl
/// <returns>System.String.</returns> /// <returns>System.String.</returns>
public static string GetConnection() public static string GetConnection()
{ {
return string.Format(AESUtil.Decrypt(Connection1), serverName, DataBase); return string.Format
}
/// <summary>
/// <para>说明:遍历获取方法中文注释</para>
/// <para>创建人:唐德馨</para>
/// <para>创建日期:2021-08-13 </para>
/// <para>修改人:</para>
/// <para>修改日期:</para>
/// <para>修改备注:</para>
/// <para>版本:1.0</para>
/// </summary>
/// <returns>System.String.</returns>
public static string GetMethodExplain(string methodName, DataTable DataTable)
{
DataTable dataTable = DataTable;
if (dataTable == null || dataTable.Rows.Count == 0) return string.Empty;
IEnumerable<DataRow> resultRow = dataTable.Select().Where(n => n["p_ErrMethod"].Equals(methodName));
if (resultRow.Count() != 0)
return resultRow.First()["p_interpretText"].ToString();
else
return string.Empty;
}
}
}
+9 -1
View File
@@ -401,7 +401,15 @@ namespace Lskj.Business.Impl
/// <returns>System.Int32.</returns> /// <returns>System.Int32.</returns>
public static DataTable GetAllModulesData() public static DataTable GetAllModulesData()
{ {
string sqlValue = "select convert(varchar(50), SubSysId)+'_'+ MenuStruct ID ,MenuId,MenuCaption,PurviewId,'0' as Editflag ,'0' as Readflag,DllFilename from P_FormMenuConfigTab order by MenuId"; //string sqlValue = "select convert(varchar(50), SubSysId)+'_'+ MenuStruct ID ,MenuId,MenuCaption,PurviewId,'0' as Editflag ,'0' as Readflag,DllFilename from P_FormMenuConfigTab order by MenuId";
string sqlValue = @"select
b.subsysname as FirstDirectory,
(select MenuCaption from P_FormMenuConfigTab where subsysid=a.SubSysId and len(menustruct)=2 and MenuStruct=left(a.menustruct,2) and useFlag=1) as SecondaryDirectory,
convert(varchar(50), a.SubSysId)+'_'+ MenuStruct ID ,MenuId,MenuCaption,PurviewId,'0' as Editflag ,'0' as Readflag,DllFilename from P_FormMenuConfigTab a
left join P_SubSystemTab b on a.SubSysId=b.SubSysId
order by MenuId";
return GetDataTableResult(sqlValue); return GetDataTableResult(sqlValue);
} }
@@ -36,6 +36,8 @@ namespace Lskj.Business.Impl
/// <returns>DataTable.</returns> /// <returns>DataTable.</returns>
/// <exception cref="System.NotImplementedException"></exception> /// <exception cref="System.NotImplementedException"></exception>
public static DataTable GetReportDetailPages(string menuCode) public static DataTable GetReportDetailPages(string menuCode)
{
try
{ {
string sqlTemplate = @"WITH UserRoles AS ( string sqlTemplate = @"WITH UserRoles AS (
SELECT r.roleName SELECT r.roleName
@@ -58,6 +60,13 @@ namespace Lskj.Business.Impl
string sqlValue = string.Format(sqlTemplate, ERPInfo.Instance.UserName, menuCode); string sqlValue = string.Format(sqlTemplate, ERPInfo.Instance.UserName, menuCode);
return SqlHelper.ExecuteDataTable(sqlValue); return SqlHelper.ExecuteDataTable(sqlValue);
} }
catch (Exception ex)
{
string sqlValue = "select * from p_systemDlltabDetail where tab=@tab and isVisible=0 order by orderid";
return SqlHelper.ExecuteDataTable(sqlValue, new SqlParameter[] { new SqlParameter("@tab", menuCode) });
}
}
/// <summary> /// <summary>
/// <para>说明:获取报表明细列</para> /// <para>说明:获取报表明细列</para>
/// <para>创建人:龚宇超</para> /// <para>创建人:龚宇超</para>
@@ -300,6 +300,13 @@ namespace Lskj.Business
if (!string.IsNullOrWhiteSpace(Instance.Bill_cg_showname)) ERPInfo.Instance.DraftReplacementValue = Instance.Bill_cg_showname; if (!string.IsNullOrWhiteSpace(Instance.Bill_cg_showname)) ERPInfo.Instance.DraftReplacementValue = Instance.Bill_cg_showname;
Instance.HideFixedConditions = item.Table.Columns.Contains("HideFixedConditions") && !string.IsNullOrEmpty(item["HideFixedConditions"] + "") ? "1".Equals(item["HideFixedConditions"] + "") : false; Instance.HideFixedConditions = item.Table.Columns.Contains("HideFixedConditions") && !string.IsNullOrEmpty(item["HideFixedConditions"] + "") ? "1".Equals(item["HideFixedConditions"] + "") : false;
Instance.ShowGrallyInTop = item.Table.Columns.Contains("ShowGrallyInTop") && !string.IsNullOrEmpty(item["ShowGrallyInTop"] + "") ? "1".Equals(item["ShowGrallyInTop"] + "") : false; Instance.ShowGrallyInTop = item.Table.Columns.Contains("ShowGrallyInTop") && !string.IsNullOrEmpty(item["ShowGrallyInTop"] + "") ? "1".Equals(item["ShowGrallyInTop"] + "") : false;
Instance.FallbackDefaultSelection = item.Table.Columns.Contains("FallbackDefaultSelection") && !string.IsNullOrEmpty(item["FallbackDefaultSelection"] + "") ? "1".Equals(item["FallbackDefaultSelection"] + "") : false;
Instance.FoundationHideTableRefresh = item.Table.Columns.Contains("FoundationHideTableRefresh") && !string.IsNullOrEmpty(item["FoundationHideTableRefresh"] + "") ? "1".Equals(item["FallbackDefaultSelection"] + "") : false;
Instance.AntiAuditUrl = item.Table.Columns.Contains("AntiAuditUrl") && !string.IsNullOrEmpty(item["AntiAuditUrl"] + "") ? item["AntiAuditUrl"] + "" : "";
Instance.HidePDFGeneration = item.Table.Columns.Contains("HidePDFGeneration") && !string.IsNullOrEmpty(item["HidePDFGeneration"] + "") ? "1".Equals(item["HidePDFGeneration"] + "") : false;
Instance.HideFlowchartTab = item.Table.Columns.Contains("HideFlowchartTab") && !string.IsNullOrEmpty(item["HideFlowchartTab"] + "") ? "1".Equals(item["HideFlowchartTab"] + "") : false;
Instance.SpecialReverseStep = item.Table.Columns.Contains("SpecialReverseStep") && !string.IsNullOrEmpty(item["SpecialReverseStep"] + "") ? "1".Equals(item["SpecialReverseStep"] + "") : false;
Instance.MainProhibitSwitchingAccount = item.Table.Columns.Contains("MainProhibitSwitchingAccount") && !string.IsNullOrEmpty(item["MainProhibitSwitchingAccount"] + "") ? "1".Equals(item["MainProhibitSwitchingAccount"] + "") : false;
} }
/// <summary> /// <summary>
/// 高拍仪AccessKey /// 高拍仪AccessKey
@@ -978,3 +985,26 @@ namespace Lskj.Business
/// <summary> /// <summary>
/// 关闭筛选列显示条数 /// 关闭筛选列显示条数
/// </summary> /// </summary>
public bool DisableFilteringQuantity;
/// <summary>
///树节点搜索框搜索后只显示根节点
/// </summary>
public bool TreeNodeBoxSpecialDisplay;
/// <summary>
/// 导入时去除所有string类型单元格(文本框和下拉框,搜索框等)前后空格
/// </summary>
public bool ImportRemoveSpaces;
/// <summary>
///切换账套限制工号(工号大于这个数的都不能切换账套)
/// </summary>
public int AccountSwitchingRestrictions;
/// <summary>
/// 水印中的 草稿 替换值
/// </summary>
public string Bill_cg_showname;
/// <summary>
/// 单表未配置条件隐藏上方(固定条件和右侧按钮)
/// </summary>
public bool HideFixedConditions;
/// <summary>
/// 分组时快捷菜单是否显
@@ -1,4 +1,5 @@
using Lskj.Model; using Lskj.Core;
using Lskj.Model;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Data; using System.Data;
@@ -23,7 +24,7 @@ namespace Lskj.Business.Impl
/// <returns>DataTable.</returns> /// <returns>DataTable.</returns>
public static DataTable GetBaseFlowData(string menuCode) public static DataTable GetBaseFlowData(string menuCode)
{ {
string sqlValue = string.Format("select * from p_systemdlltabflow where typeCode='{0}'", menuCode); string sqlValue = string.Format("select * from p_systemdlltabflow where typeCode='{0}' ORDER BY stepCode ", menuCode);
return GetDataTableResult(sqlValue); return GetDataTableResult(sqlValue);
} }
/// <summary> /// <summary>
@@ -504,4 +505,259 @@ namespace Lskj.Business.Impl
sqlValue = string.Format(@"UPDATE p_systembillsourcecond set controlName='{0}',controlLabel='{1}',controlType='{2}',defaultValue='{3}',sourceSql='{4}',keyField='{5}',resultField='{6}', sqlValue = string.Format(@"UPDATE p_systembillsourcecond set controlName='{0}',controlLabel='{1}',controlType='{2}',defaultValue='{3}',sourceSql='{4}',keyField='{5}',resultField='{6}',
controlLeft='{7}',controlTop='{8}',controlHeight='{9}',controlWidth='{10}',checkCond='{11}',ShowMobile='{12}' where id='{13}' ;", controlLeft='{7}',controlTop='{8}',controlHeight='{9}',controlWidth='{10}',checkCond='{11}',ShowMobile='{12}' where id='{13}' ;",
(dr["controlName"] + "").Replace("'", "''"), (dr["controlLabel"] + "").Replace("'", "''"), (dr["controlType"] + "").Replace("'", "''"), (dr["defaultValue"] + "").Replace("'", "''"), (dr["sourceSql"] + "").Replace("'", "''"), (dr["keyField"] + "").Replace("'", "''"), (dr["resultField"] + "").Replace("'", "''"), (dr["controlName"] + "").Replace("'", "''"), (dr["controlLabel"] + "").Replace("'", "''"), (dr["controlType"] + "").Replace("'", "''"), (dr["defaultValue"] + "").Replace("'", "''"), (dr["sourceSql"] + "").Replace("'", "''"), (dr["keyField"] + "").Replace("'", "''"), (dr["resultField"] + "").Replace("'", "''"),
(dr["controlLeft"] + "").Replace("'", "''"), (dr["controlTop"] + "").Replace("'", "''"), (dr["controlHeight"] + "").Replace("'", "''"), (dr["controlWidth"] + "").Replace("'", "''"), (dr["checkCond"] + "").Replace("'", "''"), (dr["ShowMobile"] + ""). (dr["controlLeft"] + "").Replace("'", "''"), (dr["controlTop"] + "").Replace("'", "''"), (dr["controlHeight"] + "").Replace("'", "''"), (dr["controlWidth"] + "").Replace("'", "''"), (dr["checkCond"] + "").Replace("'", "''"), (dr["ShowMobile"] + "").Replace("'", "''"), (dr["id"] + "").Replace("'", "''")
);
}
return ExecSqlValue(sqlValue) > 0;
}
/// <summary>
/// <para>说明:保存终审条件信息</para>
/// <para>创建人:曹屹峰</para>
/// <para>创建日期:2022-06-7 </para>
/// <para>修改人:</para>
/// <para>修改日期:</para>
/// <para>修改备注:</para>
/// <para>版本:1.0</para>
/// </summary>
/// <returns>System.String.</returns>
public static bool deleteFinalConditions(string id, string key)
{
string sqlValue = string.Empty;
sqlValue = string.Format("delete from p_systemControlLocation where formkey='{0}' and fieldid='{1}'", key, id);
sqlValue += string.Format("delete from p_systembillsourcecond where id='{0}'", id);
return ExecSqlValue(sqlValue) > 0;
}
/// <summary>
/// 创建 生成终审sql 的存储过程
/// </summary>
/// <returns></returns>
public static bool CreateSQL()
{
//有存储过程就不创建
string sql = "SELECT 1 FROM sys.procedures WHERE name = 'p_systemCreateendFlowSQL'";
string value=GetResult(sql) + "";
if (value.Equals("1")) return true;
string sqlValue = @"CREATE PROCEDURE dbo.p_systemCreateendFlowSQL
@typecode varchar(20),
@stepcode int,
@operatorid int,
@msg varchar(2000) output
AS
BEGIN
declare @modtype int,
@mastertable varchar(50),
@fieldsql varchar(max)='',
@tmpsql varchar(max)='',
@fieldname varchar(50),
@username varchar(100),
@fieldtypeid int,
@lookupkey varchar(50),
@lookupresult varchar(50),
@lookupsql varchar(max),
@rtagid int=0,
@jointable varchar(max)='',
@column_prefix varchar(20),
@shNewMode int=0,
@bxshFlag int=0,
@flowTable varchar(50),
@flowStepTable varchar(50),
@tmpkeyfield varchar(50),
@flowStepGridTable varchar(50),
@orderid int
print 'start'
set @msg=''
begin tran
begin try
select @modtype=modType,@mastertable=TableName from v_systemdlltab where DllCoid=@typecode
if @modtype is null
begin
set @msg='模块['+@typecode+']未找到'
goto on_error
end
print '1'
set @column_prefix=dbo.p_getColumnPrefix(@mastertable)
if @modtype=2
begin
set @tmpkeyfield=@column_prefix+'billdocument_id'
set @flowTable='wms_billflowoper'
set @flowStepTable='p_systembillflowtypestep'
set @flowStepGridTable='p_systembillstepgrid'
if object_id('wms_billflowoper') is not null
set @shNewMode=1
if exists(select 1 from sys.columns
where object_id=object_id('p_systembillflowtypestep')
and lower(name)='pstepcode')
and exists(select 1 from sys.columns
where object_id=object_id(@mastertable) and lower(name)=LOWER(@column_prefix+'pstepcode'))
set @bxshFlag=1
end
print '2'
if @modtype=1
begin
select top 1 @tmpkeyfield=fieldname
from p_systemwordbooktab
where tab=@typecode
order by orderid
set @flowTable='p_baseflowoper'
set @flowStepTable='p_systemdlltabflowtypestep'
set @flowStepGridTable='p_systemdlltabflowstepgrid'
if object_id('p_baseflowoper') is not null
set @shNewMode=1
if exists(select 1 from sys.columns
where object_id=object_id('p_systemdlltabflowtypestep')
and lower(name)='pstepcode')
and exists(select 1 from sys.columns
where object_id=object_id(@mastertable) and lower(name)=LOWER(@column_prefix+'pstepcode'))
set @bxshFlag=1
end
print '3'
print 'bxshFlag='+cast(@bxshFlag as varchar)+' shNewMode='+cast(@shNewMode as varchar)
if @modtype=2
set @tmpsql='declare tmpCur cursor for
select top 1000 fieldName,
case when isnull(userName,'''')='''' and isnull(sysname,'''')='''' then fieldName
when isnull(userName,'''')='''' then sysName
else userName end as userName,fieldTypeId,
lookupKeyField,lookupResult,lookupSql
from p_systembillinfo a
inner join sys.columns b on object_id(''' + @mastertable + ''')=b.object_id and lower(a.fieldname)=lower(b.name)
where typecode='+QUOTENAME( @typecode,'''')+
' and (isnull(isvisible,0)=0 or lower(fieldName) in ('+QUOTENAME(+lower(@column_prefix)+'stepcode','''')+','+QUOTENAME(LOWER(@column_prefix)+'rtagid','''')+','+QUOTENAME(LOWER(@column_prefix)+'billdocument_id','''')+')) order by orderid'
if @modtype=1
set @tmpsql='declare tmpCur cursor for
select top 1000 fieldName,
case when isnull(userName1,'''')='''' and isnull(sysname,'''')='''' then fieldName
when isnull(userName1,'''')='''' then sysName
else userName1 end as userName,fieldsqlTag as fieldTypeId,
fieldsqlid as lookupKeyField,fieldsqlname as lookupResult,fieldsql as lookupSql
from p_systemwordbooktab a
inner join sys.columns b on object_id('+QUOTENAME(@mastertable,'''')+')=b.object_id and lower(a.fieldname)=lower(b.name)
where tab='+QUOTENAME( @typecode,'''')+
' and (isnull(vislble,0)=0 or lower(fieldName) in ('+QUOTENAME(+lower(@column_prefix)+'stepcode','''')+','+QUOTENAME(LOWER(@column_prefix)+'rtagid','''')+','+QUOTENAME(@tmpkeyfield,'''')+'))
order by orderid'
print '@tmpsql22222222='+isnull(@tmpsql,'')
exec(@tmpsql)
print '4'
open tmpCur
fetch next from tmpCur into @fieldname ,
@username ,
@fieldtypeid ,
@lookupkey ,
@lookupresult ,
@lookupsql
set @tmpsql=''
--生成步骤语句
print '5'
set @orderid=1
while @@FETCH_STATUS=0
begin
if LOWER(@fieldname)<>lower(@column_prefix+'stepcode')
begin
if LOWER(@fieldname)=lower(@column_prefix+'rtagid')
set @rtagid=1
if @tmpsql=''
set @tmpsql=@tmpsql+'a.'+@fieldname
else
set @tmpsql=@tmpsql+CHAR(10)+',a.'+@fieldname
set @orderid=@orderid+1
end
fetch next from tmpCur into @fieldname ,
@username ,
@fieldtypeid ,
@lookupkey ,
@lookupresult ,
@lookupsql
end
close tmpCur
deallocate tmpCur
set @tmpsql=@tmpsql+','+CAST(@stepcode as varchar)+' as '+@column_prefix+'stepcode'
if @rtagid=0
begin
set @tmpsql=@tmpsql+',a.'+@column_prefix+'rtagid'
end
set @tmpsql = 'select ' + char(10) + @tmpsql + CHAR(10) + ' from ' + @mastertable + ' a ' + @jointable
print '@tmpsql111111111='+isnull(@tmpsql,'')
if @shNewMode=1
begin
if @bxshFlag=0
begin
set @tmpsql = @tmpsql + CHAR(10) + ' where 1=1'+
' and isnull(a.' + @column_prefix + 'stepOver,0)=1 ' + CHAR(10)
end
else
begin
set @tmpsql = @tmpsql + CHAR(10) + ' where 1=1'+
' and isnull(a.' + @column_prefix + 'stepOver,0)=1 ' + CHAR(10)
end
end
else
begin
if @bxshFlag=0
begin
set @tmpsql = @tmpsql + char(10) + ' where 1=1 and isnull(a.' + @column_prefix + 'stepOver,0)=1'
end
else
begin
set @tmpsql= @tmpsql + char(10) + ' where isnull(a.' + @column_prefix + 'stepOver,0)=1'
end
end
print '@tmpsql='+isnull(@tmpsql,'')
set @msg=@tmpsql
commit
return 1
end try
begin catch
set @msg= LEFT( ERROR_MESSAGE(),1000)
IF EXISTS(SELECT 1 FROM MASTER.dbo.SYSCURSORS WHERE cursor_name='tmpcur')
BEGIN
CLOSE tmpcur -- 关闭游标
DEALLOCATE tmpcur -- 释放游标
END
goto on_error
end catch
on_error:
rollback
return -1
END
";
ExecSqlValue(sqlValue);
return true;
}
/// <summary>
/// 生成终审回退sql
/// </summary>
/// <returns></returns>
public static int GenerateFinalSqlStatement(string mMenuCode,string stepcode, out string retuenMsg)
{
SqlParameter pMsg = ERPInfo.Instance.ChangeParameterType ? new SqlParameter("@msg", SqlDbType.NVarChar, 6000) : new SqlParameter("@msg", SqlDbType.VarChar, 2000);
pMsg.Direction = ParameterDirection.Output;
SqlParameter returnValue = new SqlParameter("@return", SqlDbType.Int, 4);
returnValue.Direction = ParameterDirection.ReturnValue;
SqlParameter[] param =
{
new SqlParameter("@typecode",SqlDbType.VarChar,20),
new SqlParameter("@stepcode",SqlDbType.Int),
new SqlParameter("@operatorid",SqlDbType.Int),
pMsg,
@@ -70,7 +70,7 @@ namespace Lskj.Business
/// <returns>DataTable.</returns> /// <returns>DataTable.</returns>
public static DataTable GetBillFlowData(string menuCode) public static DataTable GetBillFlowData(string menuCode)
{ {
string sqlValue = string.Format("select * from p_systembillflow where typeCode='{0}'", menuCode); string sqlValue = string.Format("select * from p_systembillflow where typeCode='{0}' ORDER BY stepCode", menuCode);
return GetDataTableResult(sqlValue); return GetDataTableResult(sqlValue);
} }
/// <summary> /// <summary>
@@ -557,4 +557,14 @@ namespace Lskj.Business
(dr["controlLeft"] + "").Replace("'", "''"), (dr["controlTop"] + "").Replace("'", "''"), (dr["controlHeight"] + "").Replace("'", "''"), (dr["controlWidth"] + "").Replace("'", "''"), (dr["checkCond"] + "").Replace("'", "''"), (dr["ShowMobile"] + "").Replace("'", "''"), (dr["id"] + "").Replace("'", "''") (dr["controlLeft"] + "").Replace("'", "''"), (dr["controlTop"] + "").Replace("'", "''"), (dr["controlHeight"] + "").Replace("'", "''"), (dr["controlWidth"] + "").Replace("'", "''"), (dr["checkCond"] + "").Replace("'", "''"), (dr["ShowMobile"] + "").Replace("'", "''"), (dr["id"] + "").Replace("'", "''")
); );
sqlValue = sqlValue + string.Format(@"update p_systemControlLocation set fieldname='{0}',username='{1}',fieldtypeid='{2}', defaultvalue='{3}' where formkey='{4}' and fieldid='{5}'", sqlValue = sqlValue + string.Format(@"update p_systemControlLocation set fieldname='{0}',username='{1}',fieldtypeid='{2}', defaultvalue='{3}' where formkey='{4}' and fieldid='{5}'",
(dr["controlName"] + "").Replace("'", "''"), (dr["controlLabel"] + "").Replace("'", "''"), (dr["controlType"] + "").Replace("'", "''"), (dr["defaultValue"] + "") (dr["controlName"] + "").Replace("'", "''"), (dr["controlLabel"] + "").Replace("'", "''"), (dr["controlType"] + "").Replace("'", "''"), (dr["defaultValue"] + "").Replace("'", "''"), (dr["formkey"] + "").Replace("'", "''"), (dr["id"] + "").Replace("'", "''"));
}
return ExecSqlValue(sqlValue) > 0;
}
/// <summary>
/// <para>说明:保存终审条件信息</para>
/// <para>创建人:曹屹峰</para>
/// <para>创建日期:2022-06-7 </para>
/// <para>修改人:</para