@@ -19,12 +19,12 @@ | |||
<el-col :span="4"> | |||
<el-input placeholder="请输入教职工编号/姓名进行查询" v-model="query.keyword" clearable size="small"></el-input> | |||
</el-col> | |||
<el-col :span="4"> | |||
<el-col :span="2"> | |||
<el-select v-model="query.department" filterable clearable size="small" placeholder="请选择部门"> | |||
<el-option v-for="item in departmentOptions" :label="item.label" :value="item.value"></el-option> | |||
</el-select> | |||
</el-col> | |||
<el-col :span="4"> | |||
<el-col :span="3"> | |||
<el-date-picker size="small" | |||
v-model="time" | |||
v-on:change="timeChange" | |||
@@ -34,10 +34,13 @@ | |||
value-format="yyyy-MM-dd"> | |||
</el-date-picker> | |||
</el-col> | |||
<el-col :span="2"> | |||
<el-input placeholder="请输入发放次数" v-model="query.sendCount" clearable size="small"></el-input> | |||
</el-col> | |||
<el-col :span="2"> | |||
<a class="btn btn-default" v-on:click="search"><i class="el-icon-search" style="margin-right:4px"></i>查询</a> | |||
</el-col> | |||
<el-col :span="10" style="display: flex;justify-content: right;"> | |||
<el-col :span="11" style="display: flex;justify-content: right;"> | |||
<a v-on:click="refresh" class="btn btn-default" style="margin-right:8px;font-size:14px"><i class="el-icon-refresh"></i></a> | |||
<a class="btn btn-default" v-on:click="detailShow"><i class="el-icon-edit-outline" style="margin-right:4px"></i>查看</a> | |||
<a class="btn btn-default" v-on:click="del"><i class="el-icon-delete" style="margin-right:4px"></i>删除</a> | |||
@@ -1,9 +1,9 @@ | |||
<?xml version="1.0" encoding="utf-8"?> | |||
<connectionStrings> | |||
<add name="BaseDb" connectionString="Server=123.57.209.16;Initial Catalog=adms7ultimate2_西昌;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | |||
<add name="CollegeMIS" connectionString="Server=123.57.209.16;Initial Catalog=CollegeMIS_西昌;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | |||
<add name="hangfireString" connectionString="Server=123.57.209.16;Initial Catalog=Hangfire;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | |||
<add name="BaseDb" connectionString="Server=8.141.155.183,53314;Initial Catalog=adms7ultimate2_西昌;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | |||
<add name="CollegeMIS" connectionString="Server=8.141.155.183,53314;Initial Catalog=CollegeMIS_西昌;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | |||
<add name="hangfireString" connectionString="Server=8.141.155.183,53314;Initial Catalog=Hangfire;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | |||
<add name="paikeDbString" connectionString="Data Source=10.30.0.11;Database=paike;User ID=root;Password=12345678;" providerName="MySql.Data.MySqlClient" /> | |||
<add name="YongyouDb" connectionString="Server=123.57.209.16;Password=bjqjkj@2014~2015!;User ID=sa; Initial Catalog=u8gx" providerName="System.Data.SqlClient" /> | |||
<add name="YongyouDb" connectionString="Server=8.141.155.183,53314;Password=bjqjkj@2014~2015!;User ID=sa; Initial Catalog=u8gx" providerName="System.Data.SqlClient" /> | |||
<add name="xcdatacenter" connectionString="Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=ORCL)));User ID=system;Password=1" providerName="Oracle.ManagedDataAccess.Client"/> | |||
</connectionStrings> |
@@ -410,7 +410,12 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement | |||
{ | |||
dept = qj["department"].ToString(); | |||
} | |||
return GetAmountsCols(pagination, yearStart, monthStart, yearEnd, monthEnd, string.Empty, kw, dept, out totalSend); | |||
var sc = string.Empty; | |||
if (!qj["sendCount"].IsEmpty()) | |||
{ | |||
sc = qj["sendCount"].ToString(); | |||
} | |||
return GetAmountsCols(pagination, yearStart, monthStart, yearEnd, monthEnd, string.Empty, kw, dept, sc, out totalSend); | |||
} | |||
catch (Exception ex) | |||
@@ -514,8 +519,7 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement | |||
yearEnd = ts.Year; | |||
monthEnd = ts.Month; | |||
} | |||
return GetAmountsCols(pagination, yearStart, monthStart, yearEnd, monthEnd, userNo, string.Empty, string.Empty, out var total); | |||
return GetAmountsCols(pagination, yearStart, monthStart, yearEnd, monthEnd, userNo, string.Empty, string.Empty,string.Empty, out var total); | |||
} | |||
catch (Exception ex) | |||
@@ -552,7 +556,7 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement | |||
year = yearStart; | |||
month = monthStart; | |||
return GetAmountsCols(new Pagination { rows = 30, page = 1 }, yearStart, monthStart, yearEnd, monthEnd, userNo, string.Empty, string.Empty, out var total); | |||
return GetAmountsCols(new Pagination { rows = 30, page = 1 }, yearStart, monthStart, yearEnd, monthEnd, userNo, string.Empty, string.Empty,string.Empty, out var total); | |||
} | |||
catch (Exception ex) | |||
@@ -617,7 +621,7 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement | |||
} | |||
} | |||
private List<Gz_AmountsCols> GetAmountsCols(Pagination pagination, int yearStart, int monthStart, int yearEnd, int monthEnd, string userNo, string kw, string dept, out decimal total) | |||
private List<Gz_AmountsCols> GetAmountsCols(Pagination pagination, int yearStart, int monthStart, int yearEnd, int monthEnd, string userNo, string kw, string dept, string sendCount, out decimal total) | |||
{ | |||
var items = this.BaseRepository("CollegeMIS").FindList<Gz_ItemsEntity>(x => x.IsShow == true).ToList(); | |||
var skip = pagination.rows * (pagination.page - 1); | |||
@@ -645,7 +649,10 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement | |||
{ | |||
q = q.Where(x => x.UserNo == userNo); | |||
} | |||
if(!sendCount.IsEmpty()) | |||
{ | |||
q=q.Where(x=>x.SendCount == sendCount); | |||
} | |||
var query = q.GroupBy(x => new { x.UserNo, x.Year, x.Month, x.SendCount }); | |||
pagination.records = query.Count(); | |||