Browse Source

流程监控添加状态的搜索条件

新疆影视学院高职
zhangli 2 years ago
parent
commit
4a8110498e
3 changed files with 32 additions and 2 deletions
  1. +3
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/MonitorIndex.cshtml
  2. +9
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/MonitorIndex.js
  3. +20
    -1
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Process/NWFProcessSerivce.cs

+ 3
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/MonitorIndex.cshtml View File

@@ -23,6 +23,9 @@
<div class="lr-layout-tool-item">
<input id="txt_Keyword" type="text" class="form-control" placeholder="请输入要查询关键字" />
</div>
<div class="lr-layout-tool-item">
<div id="F_EnabledMark" style="width: 100px;"></div>
</div>
<div class="lr-layout-tool-item">
<a id="btn_Search" class="btn btn-primary btn-sm"><i class="fa fa-search"></i>&nbsp;<span class="lrlg">查询</span></a>
</div>


+ 9
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/MonitorIndex.js View File

@@ -43,10 +43,17 @@ var bootstrap = function ($, learun) {
page.search();
}
});
$('#F_EnabledMark').lrselect({
placeholder: '请选择状态',
data: [{ id: '1', text: '运行中' }, { id: '2', text: '作废' }, { id: '3', text: '结束' }],
value: "id",
text: "text"
});

// 查询
$('#btn_Search').on('click', function () {
var keyword = $('#txt_Keyword').val();
page.search({ keyword: keyword });
page.search({ keyword: keyword, F_EnabledMark: $('#F_EnabledMark').lrselectGet() });
});
// 刷新
$('#lr_refresh').on('click', function () {
@@ -117,6 +124,7 @@ var bootstrap = function ($, learun) {
$parent.find('.active').removeClass('active');
$this.addClass('active');
categoryId = $this.attr('data-value');
$('#F_EnabledMark').lrselectSet('');
page.search();
});
},


+ 20
- 1
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Process/NWFProcessSerivce.cs View File

@@ -139,6 +139,25 @@ namespace Learun.Application.WorkFlow
string keyword = queryParam["keyword"].ToString();
expression = expression.And(t => t.F_Title.Contains(keyword) || t.F_SchemeName.Contains(keyword) || t.F_CreateUserName.Contains(keyword));
}
// 状态
if (!queryParam["F_EnabledMark"].IsEmpty()) // 1:未完成 2:已完成
{
if (queryParam["F_EnabledMark"].ToString() == "1")
{
//运行中
expression = expression.And(t => t.F_EnabledMark == 1);
}
else if (queryParam["F_EnabledMark"].ToString() == "2")
{
//作废
expression = expression.And(t => t.F_EnabledMark != 1);
}
else if (queryParam["F_EnabledMark"].ToString() == "3")
{
//结束 已完成
expression = expression.And(t => t.F_IsFinished == 1);
}
}
expression = expression.And(t => t.F_EnabledMark != 2);
expression = expression.And(t => t.F_IsChild == 0);

@@ -325,7 +344,7 @@ namespace Learun.Application.WorkFlow
DateTime endTime = queryParam["EndTime"].ToDate();
strSql.Append(" and CONVERT(varchar, zb.lc_accept) >= CONVERT(varchar, '" + startTime + "') and CONVERT(varchar, zb.LC_accept) <= CONVERT(varchar, '" + endTime + "')");
}
return this.BaseRepository("CollegeMIS").FindList<LC_docx2Entity>(strSql.ToString(), dp,pagination);
return this.BaseRepository("CollegeMIS").FindList<LC_docx2Entity>(strSql.ToString(), dp, pagination);

}
catch (Exception ex)


Loading…
Cancel
Save