This commit is contained in:
2023-05-31 10:19:05 +08:00
parent 1b65a7a9e5
commit 9c621c75cd
238 changed files with 9905 additions and 4034 deletions

View File

@@ -28,18 +28,10 @@ public class GetCodeGenIndexButtonHelper
method = string.Format("scope.row.rowEdit=true");
break;
default:
switch (primaryKeyPolicy)
switch (isFlow)
{
case 2:
switch (isFlow)
{
case true:
method = string.Format("addOrUpdateHandle(scope.row.flowTaskId)");
break;
default:
method = string.Format("addOrUpdateHandle(scope.row.{0})", primaryKey);
break;
}
case true:
method = string.Format("updateHandle(scope.row)");
break;
default:
method = string.Format("addOrUpdateHandle(scope.row.{0})", primaryKey);
@@ -61,23 +53,15 @@ public class GetCodeGenIndexButtonHelper
switch (primaryKeyPolicy)
{
case 2:
method = string.Format("goDetail(scope.row.flowTaskId,scope.row.flowState)");
method = string.Format("goDetail(scope.row.flowTaskId,scope.row.flowState, scope.row.flowId)");
break;
default:
method = string.Format("goDetail(scope.row.{0},scope.row.flowState)", primaryKey);
method = string.Format("goDetail(scope.row.{0},scope.row.flowState, scope.row.flowId)", primaryKey);
break;
}
break;
default:
switch (primaryKeyPolicy)
{
case 2:
method = string.Format("addOrUpdateHandle(scope.row.flowTaskId,scope.row.flowState)");
break;
default:
method = string.Format("addOrUpdateHandle(scope.row.{0},scope.row.flowState)", primaryKey);
break;
}
method = string.Format("detailHandle(scope.row)", primaryKey);
break;
}
break;
@@ -95,14 +79,24 @@ public class GetCodeGenIndexButtonHelper
/// <summary>
/// 代码生成单表Index列表头部按钮方法.
/// </summary>
/// <param name="value">按钮类型.</param>
/// <param name="isFlow">是否工作流表单.</param>
/// <returns></returns>
public static string IndexTopButton(string value)
public static string IndexTopButton(string value, bool isFlow)
{
var method = string.Empty;
switch (value)
{
case "add":
method = "addOrUpdateHandle()";
switch (isFlow)
{
case true:
method = "addHandle()";
break;
default:
method = "addOrUpdateHandle()";
break;
}
break;
case "download":
method = "exportData()";
@@ -113,6 +107,9 @@ public class GetCodeGenIndexButtonHelper
case "upload":
method = "handelUpload()";
break;
case "batchPrint":
method = "printDialog()";
break;
}
return method;