소스 검색

添加申诉相关实体类

luocaiyang 3 년 전
부모
커밋
80906d90fb

+ 23 - 7
wispro.sp.api/Controllers/PerformanceItemController.cs

@@ -157,7 +157,7 @@ namespace wispro.sp.api.Controllers
                 return ret;
             }
 
-            if(string.IsNullOrEmpty(field) || string.IsNullOrEmpty(value))
+            if(string.IsNullOrEmpty(field) )
             {
                 ret.Success = false;
                 ret.ErrorMessage = $"参数不对!";
@@ -166,7 +166,12 @@ namespace wispro.sp.api.Controllers
             }
 
             string[] fields = field.Split(new char[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
-            string[] values= value.Split(new char[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
+
+            string[] values = new string[] { null };
+            if (!string.IsNullOrEmpty(value))
+            {
+                values = value.Split(new char[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
+            }
 
             if (fields.Length != values.Length) {
                 ret.Success = false;
@@ -586,6 +591,7 @@ namespace wispro.sp.api.Controllers
             #region 将某些属性设为null,避免循环取值造成返回json过大
             foreach (PerformanceItem item in retList)
             {
+
                 foreach (ItemStaff itemStaff in item.ItemStaffs)
                 {
                     itemStaff.DoPerson.ItemStaffs = null;
@@ -593,12 +599,22 @@ namespace wispro.sp.api.Controllers
                     itemStaff.Item = null;
                 }
 
-                item.Reviewer.ReviewerItems = null;
-                item.Reviewer.Customers = null;
-                item.Reviewer.ItemStaffs = null;
+                if (item.Reviewer != null)
+                {
+                    item.Reviewer.ReviewerItems = null;
+                    item.Reviewer.Customers = null;
+                    item.Reviewer.ItemStaffs = null;
+                }
 
-                item.Customer.PerformanceItems = null;
-                item.CalMonth.PerformanceItems = null;
+                if (item.Customer != null)
+                {
+                    item.Customer.PerformanceItems = null;
+                }
+
+                if (item.CalMonth != null)
+                {
+                    item.CalMonth.PerformanceItems = null;
+                }
             }
             #endregion
 

+ 1 - 0
wispro.sp.api/Utility/Utility.cs

@@ -30,6 +30,7 @@ namespace wispro.sp.api.Utility
                 {
                     interpreter.SetVariable("p", item);
                     item.BasePoint = (double?)interpreter.Eval(rule.PointExpress);
+                    break;
                 }
             }
             #endregion

+ 3 - 2
wispro.sp.web/Layouts/BasicLayout.razor

@@ -5,8 +5,9 @@
 <CascadingAuthenticationState>
     <AuthorizeView>
         <Authorized>
-            <AntDesign.ProLayout.BasicLayout Logo="@("images/小美logo-64-64.png")"
-                                             MenuData="_menuData" Theme="MenuTheme.Light" Layout="AntDesign.ProLayout.Layout.Mix">
+            
+            <AntDesign.ProLayout.BasicLayout Logo="@("images/小美logo-64-64.png")" Collapsed="true"
+                           MenuData="_menuData" Theme="MenuTheme.Light" Layout="AntDesign.ProLayout.Layout.Mix">
 
                 <RightContentRender>
                     <wispro.sp.web.Components.RightContent />

+ 228 - 164
wispro.sp.web/Pages/AppCase/MyCaselist.razor

@@ -2,7 +2,7 @@
 @using wispro.sp.web.Components
 @using wispro.sp.share 
 
-<PageContainer>
+<PageContainer TabList="@tabList" OnTabChange="OnTabChange">
     <Breadcrumb>
         <Breadcrumb>
             <BreadcrumbItem>
@@ -14,175 +14,239 @@
 
         </Breadcrumb>
     </Breadcrumb>
-    <Content>
-        @*<Button Type="primary" Icon="plus" OnClick="AddNew" Style="float:right">添加</Button>*@
-    </Content>
-    <ChildContent>
-        <div class="card-container">
-            <Tabs Type="@TabType.Card">
-                <TabPane Key="1" Tab="待确认绩效清单">
-                    <ChildContent>
-                        <Card>
-                            @*<Pagination @bind-Current="@_pageIndex" @bind-Total="@_total" ShowSizeChanger OnChange="OnChange" />*@
-                            @if (_Datas == null)
-                            {
-                                <center><Spin /></center>
-                            }
-                            else
-                            {
-                                <PageHeader>
-                                    <PageHeaderTitle>基础点数统计</PageHeaderTitle>
-                                    <PageHeaderExtra><Button Type="@ButtonType.Primary">缺失数据提报</Button></PageHeaderExtra>
-                                    <PageHeaderContent>
-                                        <div style="border:1px solid #000000">
-                                            <AntDesign.Row Align="center" Justify="center">
-                                                <AntDesign.Col Span="2" style="border-left:1px solid #000000"><center></center></AntDesign.Col>
-                                                <AntDesign.Col Span="4" style="border:1px solid #000000"><center>新申请</center></AntDesign.Col>
-                                                <AntDesign.Col Span="4" style="border:1px solid #000000"><center>OA(国内、涉外)</center></AntDesign.Col>
-                                                <AntDesign.Col Span="4" style="border:1px solid #000000"><center>其它</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"></AntDesign.Col>
-                                                <AntDesign.Col Span="4" style="border:1px solid #000000">一次OA授权</AntDesign.Col>
-                                                <AntDesign.Col Span="4" style="border:1px solid #000000"></AntDesign.Col>
-                                            </AntDesign.Row>
-                                            <AntDesign.Row>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>代理人</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>核稿</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>核稿</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>核稿</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>调查案</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办人</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>审核人</center></AntDesign.Col>
-                                                <AntDesign.Col Span="4" style="border:1px solid #000000"><center>总计</center></AntDesign.Col>
-                                            </AntDesign.Row>
-                                            <AntDesign.Row>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@_userService.CurrentUser.Name</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("新申请处理")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("新申请审核")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("OA处理")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("OA审核")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("其它处理")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("其它审核")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center></center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("一次OA授权处理")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("一次OA授权审核")</center></AntDesign.Col>
-                                                <AntDesign.Col Span="4" style="border:1px solid #000000"><center>@GetStatistics("ALL")</center></AntDesign.Col>
-                                            </AntDesign.Row>
-                                            
-                                        </div>
-                                    </PageHeaderContent>
-                                </PageHeader>
-                                
-                                <AntDesign.Table DataSource="_Datas" TItem="PerformanceItem"
-                                                 @bind-PageIndex="_pageIndex"
-                                                 @bind-PageSize="_pageSize"
-                                                 Total="_total"
-                                                 ScrollX="1150" Size="TableSize.Small" Bordered
-                                                 @bind-SelectedRows="selectedItems"
-                                                 OnRow="OnRow"
-                                                 Loading="_loading"
-                                                 RowClassName="@(x => x.Data.isDanger()?"danger":"")"
-                                                 OnChange="HandleTableChange" RemoteDataSource>
-                                    <RowTemplate>
-                                        <AntDesign.Selection Key="@(context.Id.ToString())" Width="50" Fixed="left" />
-                                        <AntDesign.Column Title="序号" TData="int" Width="50" Fixed="left">
-                                            @serialNumber(_pageIndex, _pageSize, context.Id)
-                                        </AntDesign.Column>
-                                        <AntDesign.Column Title="绩效特殊字段" DataIndex="@nameof(context.AgentFeedbackMemo)" TData="string" Width="250" Fixed="left">
+    
 
-                                            <Select DataSource="@_Reasons"
-                                                    @bind-Value="@context.AgentFeedbackMemo"
-                                                    LabelName="@nameof(Reason.Name)"
-                                                    ValueName="@nameof(Reason.Value)"
-                                                    Placeholder="请选项一项"
-                                                    DefaultActiveFirstItem="false"
-                                                    EnableSearch="true"
-                                                    AllowClear="true"
-                                                    Style="width:220px;"
-                                                    OnSelectedItemChanged="SelectChanged"
-                                                    OnClearSelected="()=>ClearSelect(context.Id)"
-                                                    OnFocus="()=>OnFocus(context)">
-                                            </Select>
+        <ChildContent>
 
-                                        </AntDesign.Column>
-                                        <AntDesign.Column Title="基础点数" TData="string" Width="100">@(context.BasePoint ==null?"": context.BasePoint)</AntDesign.Column>
-                                        <AntDesign.Column Title="我方文号" @bind-Field="@context.CaseNo" Width="150" Sortable Filterable  />
-                                        <AntDesign.Column Title="案件类型" @bind-Field="@context.CaseType" Width="120" Sortable Filterable />
-                                        <AntDesign.Column Title="案件系数" @bind-Field="@context.CaseCoefficient" Width="120" Sortable Filterable />
-                                        <AntDesign.Column Title="处理事项" @bind-Field="@context.DoItem" Width="150" Sortable Filterable />
-                                        <AntDesign.Column Title="处理事项系数" @bind-Field="@context.DoItemCoefficient" Width="150" Sortable Filterable />
-                                        <AntDesign.Column Title="案件阶段" @bind-Field="@context.CaseStage" Width="100"></AntDesign.Column>
-                                        <AntDesign.Column Title="处理人" TData="string" DataIndex="@nameof(context.ItemStaffs)" Width="150">
-                                            @if (context.ItemStaffs != null)
-                                            {
-                                                foreach (ItemStaff itemStaff in context.ItemStaffs)
-                                                {
-                                                    <span>@(itemStaff.DoPerson.Name)&nbsp;</span>
-                                                }
-                                            }
-                                        </AntDesign.Column>
-                                        <AntDesign.Column Title="核稿人" TData="string" Width="100">@(context.Reviewer ==null?"": context.Reviewer.Name)</AntDesign.Column>
-                                        
-                                        <ActionColumn Fixed="right" Title="操作" Width="120">
-                                            <Space>
-                                                <SpaceItem>
-                                                    <AntDesign.DropdownButton OnClick="()=>OnsubShensu(context)" Type="@((ButtonType.Primary, ButtonType.Default))" ButtonsStyle="@("background-color: #1890ff;")">
-                                                        <Overlay>
-                                                            <Menu>
-                                                                @if (((!context.CaseNo.Contains("CN") || context.CaseNo.Contains("WO")) && context.DoItem == "新申请") || context.DoItem == "翻译")
-                                                                {
+            <Card>
+                @*<Pagination @bind-Current="@_pageIndex" @bind-Total="@_total" ShowSizeChanger OnChange="OnChange" />*@
+                @if (_Datas == null)
+                {
+                    <center><Spin /></center>
+                }
+                else
+                {
+                    if (_CurrentKey == "myList")
+                    {
+                        <PageHeader>
+                            <PageHeaderTitle>基础点数统计</PageHeaderTitle>
+                            <PageHeaderExtra><Button Type="@ButtonType.Primary">缺失数据提报</Button></PageHeaderExtra>
+                            <PageHeaderContent>
+                                <div style="border:1px solid #000000">
+                                    <AntDesign.Row Align="center" Justify="center">
+                                        <AntDesign.Col Span="2" style="border-left:1px solid #000000"><center></center></AntDesign.Col>
+                                        <AntDesign.Col Span="4" style="border:1px solid #000000"><center>新申请</center></AntDesign.Col>
+                                        <AntDesign.Col Span="4" style="border:1px solid #000000"><center>OA(国内、涉外)</center></AntDesign.Col>
+                                        <AntDesign.Col Span="4" style="border:1px solid #000000"><center>其它</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"></AntDesign.Col>
+                                        <AntDesign.Col Span="4" style="border:1px solid #000000">一次OA授权</AntDesign.Col>
+                                        <AntDesign.Col Span="4" style="border:1px solid #000000"></AntDesign.Col>
+                                    </AntDesign.Row>
+                                    <AntDesign.Row>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>代理人</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>核稿</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>核稿</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>核稿</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>调查案</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>承办人</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>审核人</center></AntDesign.Col>
+                                        <AntDesign.Col Span="4" style="border:1px solid #000000"><center>总计</center></AntDesign.Col>
+                                    </AntDesign.Row>
+                                    <AntDesign.Row>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@_userService.CurrentUser.Name</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("新申请处理")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("新申请审核")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("OA处理")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("OA审核")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("其它处理")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("其它审核")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center></center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("一次OA授权处理")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="2" style="border:1px solid #000000"><center>@GetStatistics("一次OA授权审核")</center></AntDesign.Col>
+                                        <AntDesign.Col Span="4" style="border:1px solid #000000"><center>@GetStatistics("ALL")</center></AntDesign.Col>
+                                    </AntDesign.Row>
 
-                                                                    @*<MenuItem Key="1" icon="plus" Click="OnsubShensu"></MenuItem>*@
-                                                                    <MenuItem Key="2" icon="plus" OnClick="() => OnJXCal(context)">计算字数</MenuItem>
+                                </div>
+                            </PageHeaderContent>
+                        </PageHeader>
 
-                                                                }
-                                                                @if(context.ItemStaffs.Count > 1)
-                                                                {
-                                                                     <MenuItem Key="3" icon="plus" OnClick="() => OnJXCal(context)">设定分配比例</MenuItem>
-                                                                }
-                                                            </Menu>
-                                                            </Overlay>
-                                                        <ChildContent>申诉</ChildContent>
-                                                    </AntDesign.DropdownButton>
-                                                </SpaceItem>
-                                            </Space>
+                        <AntDesign.Table DataSource="_Datas" TItem="PerformanceItem" @ref="@table"
+                                         @bind-PageIndex="_pageIndex"
+                                         @bind-PageSize="_pageSize"
+                                         Total="_total"
+                                         ScrollX="1150" Size="TableSize.Small" Bordered
+                                         @bind-SelectedRows="selectedItems"
+                                         OnRow="OnRow"
+                                         Loading="_loading"
+                                         RowClassName="@(x => x.Data.isDanger() ? "danger" : "")"
+                                         OnChange="HandleTableChange" RemoteDataSource>
+                            <RowTemplate>
+                                <AntDesign.Selection Key="@(context.Id.ToString())" Width="50" Fixed="left" />
+                                <AntDesign.Column Title="序号" TData="int" Width="50" Fixed="left">
+                                    @serialNumber(_pageIndex, _pageSize, context.Id)
+                                </AntDesign.Column>
+                                <AntDesign.Column Title="绩效特殊字段" @bind-Field="@context.AgentFeedbackMemo" Width="250" Fixed="left">
 
-                                        </ActionColumn>
-                                    </RowTemplate>
-                                    <ExpandTemplate>
-                                        <div style="width:1000px;margin-left:30px;">
-                                            <Card Title=@("详情")>
-                                                <Body>
-                                                    <Descriptions Bordered Size="@DescriptionsSize.Small">
-                                                        <DescriptionsItem Title="完成时间">@(context.Data.FinishedDate.HasValue?context.Data.FinishedDate.Value.ToString("yyyy-MM-dd"):"")</DescriptionsItem>
-                                                        <DescriptionsItem Title="返稿日">@(context.Data.ReturnDate.HasValue?context.Data.ReturnDate.Value.ToString("yyyy-MM-dd"):"")</DescriptionsItem>
-                                                        <DescriptionsItem Title="客户期限">@(context.Data.CustomerLimitDate.HasValue?context.Data.CustomerLimitDate.Value.ToString("yyyy-MM-dd"):"")</DescriptionsItem>
-                                                        <DescriptionsItem Title="初稿日">@(context.Data.FirstDraftDate.HasValue?context.Data.FirstDraftDate.Value.ToString("yyyy-MM-dd"):"")</DescriptionsItem>
-                                                        <DescriptionsItem Title="内部期限">@(context.Data.InternalDate.HasValue?context.Data.InternalDate.Value.ToString("yyyy-MM-dd"):"")</DescriptionsItem>
-                                                        <DescriptionsItem Title="案件状态">@context.Data.CaseState</DescriptionsItem>
-                                                        <DescriptionsItem Title="处理事项备注">@context.Data.DoItemMemo</DescriptionsItem>
-                                                        <DescriptionsItem Title="案件名称" Span="2">@context.Data.CaseName</DescriptionsItem>
-                                                        <DescriptionsItem Title="申请人" Span="3">@context.Data.ApplicationName</DescriptionsItem>
-                                                        <DescriptionsItem Title="备注" Span="3">@context.Data.CaseMemo</DescriptionsItem>
-                                                    </Descriptions>
-                                                </Body>
-                                            </Card>
-                                        </div>
-                                    </ExpandTemplate>
-                                </AntDesign.Table>
+                                    
 
-                            }
-                            </Card>
-                    </ChildContent>
-                </TabPane>
-                <TabPane Key="2" Tab="历史绩效清单">
-                    <ChildContent>Tab 2</ChildContent>
-                </TabPane>
-            </Tabs>
-        </div>
-    </ChildContent>
+                                </AntDesign.Column>
+                                <AntDesign.Column Title="基础点数" TData="string" Width="100">@(context.BasePoint == null ? "" : context.BasePoint)</AntDesign.Column>
+                                <AntDesign.Column Title="我方文号" @bind-Field="@context.CaseNo" Width="150" Sortable Filterable />
+                                <AntDesign.Column Title="案件类型" @bind-Field="@context.CaseType" Width="120" Sortable Filterable />
+                                <AntDesign.Column Title="案件系数"
+                                                  @bind-Field="@context.CaseCoefficient" Width="120"
+                                                  Filters="CaseCoeFilters"
+                                                  FilterMultiple="false"
+                                                  OnFilter="((value,name)=>name.StartsWith(value))"
+                                                  Sortable />
+                                <AntDesign.Column Title="处理事项" @bind-Field="@context.DoItem" Width="150" Sortable Filterable />
+                                <AntDesign.Column Title="处理事项系数" @bind-Field="@context.DoItemCoefficient" Width="150" Sortable Filterable />
+                                <AntDesign.Column Title="案件阶段" @bind-Field="@context.CaseStage" Width="100"></AntDesign.Column>
+                                <AntDesign.Column Title="处理人" TData="string" DataIndex="@nameof(context.ItemStaffs)" Width="150">
+                                    @if (context.ItemStaffs != null)
+                                    {
+                                        foreach (ItemStaff itemStaff in context.ItemStaffs)
+                                        {
+                                            <span>@(itemStaff.DoPerson.Name)&nbsp;</span>
+                                        }
+                                    }
+                                </AntDesign.Column>
+                                <AntDesign.Column Title="核稿人" TData="string" Width="100">@(context.Reviewer == null ? "" : context.Reviewer.Name)</AntDesign.Column>
+
+                                <ActionColumn Fixed="right" Title="操作" Width="120">
+                                    <Space>
+                                        <SpaceItem>
+                                            <AntDesign.DropdownButton OnClick="() => OnsubShensu(context)" Type="@((ButtonType.Primary, ButtonType.Default))" ButtonsStyle="@("background-color: #1890ff;")">
+                                                <Overlay>
+                                                    <Menu>
+                                                        @if (((!context.CaseNo.Contains("CN") || context.CaseNo.Contains("WO")) && context.DoItem == "新申请") || context.DoItem == "翻译")
+                                                        {
+
+                                                            @*<MenuItem Key="1" icon="plus" Click="OnsubShensu"></MenuItem>*@
+                                                            <MenuItem Key="2" icon="plus" OnClick="() => OnJXCal(context)">计算字数</MenuItem>
+
+                                                        }
+                                                        @if (context.ItemStaffs.Count > 1)
+                                                        {
+                                                            <MenuItem Key="3" icon="plus" OnClick="() => OnJXCal(context)">设定分配比例</MenuItem>
+                                                        }
+                                                    </Menu>
+                                                </Overlay>
+                                                <ChildContent>申诉</ChildContent>
+                                            </AntDesign.DropdownButton>
+                                        </SpaceItem>
+                                    </Space>
+
+                                </ActionColumn>
+                            </RowTemplate>
+                            <ExpandTemplate>
+                                <div style="width:1000px;margin-left:30px;">
+                                    <Card Title=@("详情")>
+                                        <Body>
+                                            <Descriptions Bordered Size="@DescriptionsSize.Small">
+                                                <DescriptionsItem Title="绩效特殊字段" Span="3">
+                                                    <Select DataSource="@_Reasons"
+                                                            @bind-Value="@context.Data.AgentFeedbackMemo"
+                                                            LabelName="@nameof(Reason.Name)"
+                                                            ValueName="@nameof(Reason.Value)"
+                                                            Placeholder="请选项一项"
+                                                            DefaultActiveFirstItem="false"
+                                                            EnableSearch="true"
+                                                            AllowClear="true"
+                                                            Style="width:220px;"
+                                                            OnSelectedItemChanged="SelectChanged"
+                                                            OnClearSelected="() => ClearSelect(context.Data.Id)"
+                                                            OnFocus="() => OnFocus(context.Data)">
+                                                    </Select>
+                                                </DescriptionsItem>
+                                                <DescriptionsItem Title="完成时间">@(context.Data.FinishedDate.HasValue ? context.Data.FinishedDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="返稿日">@(context.Data.ReturnDate.HasValue ? context.Data.ReturnDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="客户期限">@(context.Data.CustomerLimitDate.HasValue ? context.Data.CustomerLimitDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="初稿日">@(context.Data.FirstDraftDate.HasValue ? context.Data.FirstDraftDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="内部期限">@(context.Data.InternalDate.HasValue ? context.Data.InternalDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="案件状态">@context.Data.CaseState</DescriptionsItem>
+                                                <DescriptionsItem Title="处理事项备注">@context.Data.DoItemMemo</DescriptionsItem>
+                                                <DescriptionsItem Title="案件名称" Span="2">@context.Data.CaseName</DescriptionsItem>
+                                                <DescriptionsItem Title="申请人" Span="3">@context.Data.ApplicationName</DescriptionsItem>
+                                                <DescriptionsItem Title="备注" Span="3">@context.Data.CaseMemo</DescriptionsItem>
+
+                                            </Descriptions>
+                                        </Body>
+                                    </Card>
+                                </div>
+                            </ExpandTemplate>
+                        </AntDesign.Table>
+                    }
+                    else
+                    {
+                        <AntDesign.Table DataSource="_Datas" TItem="PerformanceItem" @ref="@table"
+                                         @bind-PageIndex="_pageIndex"
+                                         @bind-PageSize="_pageSize"
+                                         Total="_total" ScrollX="1200"
+                                         Size="TableSize.Small" Bordered
+                                         @bind-SelectedRows="selectedItems"
+                                         OnRow="OnRow"
+                                         Loading="_loading"
+                                         OnChange="HandleTableChange" RemoteDataSource>
+                            <RowTemplate>
+                                <AntDesign.Selection Key="@(context.Id.ToString())" Width="50" Fixed="left" />
+                                <AntDesign.Column Title="序号" TData="int" Width="50" Fixed="left">
+                                    @serialNumber(_pageIndex, _pageSize, context.Id)
+                                </AntDesign.Column>
+                                <AntDesign.Column Title="绩效特殊字段" @bind-Field="@context.AgentFeedbackMemo"  Width="250" Fixed="left"/>
+                                <AntDesign.Column Title="基础点数" TData="string" Width="100">@(context.BasePoint == null ? "" : context.BasePoint)</AntDesign.Column>
+                                <AntDesign.Column Title="我方文号" @bind-Field="@context.CaseNo" Width="150" Sortable Filterable />
+                                <AntDesign.Column Title="案件类型" @bind-Field="@context.CaseType" Width="120" Sortable Filterable />
+                                <AntDesign.Column Title="案件系数" 
+                                                  @bind-Field="@context.CaseCoefficient"     Width="120" 
+                                                  Filters="CaseCoeFilters"
+                                                  FilterMultiple="false"
+                                                  OnFilter="((value,name)=>name.StartsWith(value))"
+                                                  Sortable  />
+                                <AntDesign.Column Title="处理事项" @bind-Field="@context.DoItem" Width="150" Sortable Filterable />
+                                <AntDesign.Column Title="处理事项系数" @bind-Field="@context.DoItemCoefficient" Width="150" Sortable Filterable />
+                                <AntDesign.Column Title="案件阶段" @bind-Field="@context.CaseStage" Width="100"></AntDesign.Column>
+                                <AntDesign.Column Title="处理人" TData="string" DataIndex="@nameof(context.ItemStaffs)" Width="150">
+                                    @if (context.ItemStaffs != null)
+                                    {
+                                        foreach (ItemStaff itemStaff in context.ItemStaffs)
+                                        {
+                                            <span>@(itemStaff.DoPerson.Name)&nbsp;</span>
+                                        }
+                                    }
+                                </AntDesign.Column>
+                                <AntDesign.Column Title="核稿人" TData="string" Width="100">@(context.Reviewer == null ? "" : context.Reviewer.Name)</AntDesign.Column>
+                            </RowTemplate>
+                            <ExpandTemplate>
+                                <div style="width:1000px;margin-left:30px;">
+                                    <Card Title=@("详情")>
+                                        <Body>
+                                            <Descriptions Bordered Size="@DescriptionsSize.Small">
+                                                <DescriptionsItem Title="完成时间">@(context.Data.FinishedDate.HasValue ? context.Data.FinishedDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="返稿日">@(context.Data.ReturnDate.HasValue ? context.Data.ReturnDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="客户期限">@(context.Data.CustomerLimitDate.HasValue ? context.Data.CustomerLimitDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="初稿日">@(context.Data.FirstDraftDate.HasValue ? context.Data.FirstDraftDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="内部期限">@(context.Data.InternalDate.HasValue ? context.Data.InternalDate.Value.ToString("yyyy-MM-dd") : "")</DescriptionsItem>
+                                                <DescriptionsItem Title="案件状态">@context.Data.CaseState</DescriptionsItem>
+                                                <DescriptionsItem Title="处理事项备注">@context.Data.DoItemMemo</DescriptionsItem>
+                                                <DescriptionsItem Title="案件名称" Span="2">@context.Data.CaseName</DescriptionsItem>
+                                                <DescriptionsItem Title="申请人" Span="3">@context.Data.ApplicationName</DescriptionsItem>
+                                                <DescriptionsItem Title="备注" Span="3">@context.Data.CaseMemo</DescriptionsItem>
+                                            </Descriptions>
+                                        </Body>
+                                    </Card>
+                                </div>
+                            </ExpandTemplate>
+                        </AntDesign.Table>
+                    }
+                }
+            </Card>
+
+        </ChildContent>
+   
 </PageContainer>
 
 <style>

+ 83 - 41
wispro.sp.web/Pages/AppCase/MyCaselist.razor.cs

@@ -7,6 +7,7 @@ using Microsoft.AspNetCore.Components.Web;
 using System;
 using System.Collections.Generic;
 using System.Linq;
+using System.Text.Json;
 using System.Threading.Tasks;
 using wispro.sp.entity;
 using wispro.sp.share;
@@ -24,6 +25,13 @@ namespace wispro.sp.web.Pages.AppCase
         const string strCaseCoefficient = "CaseCoefficient";
         const string strWordCount = "WordCount";
 
+        public TableFilter<string>[] CaseCoeFilters = new TableFilter<string>[] {
+            new() { Text = "S", Value = "S" },
+            new() { Text = "A", Value = "A" },
+            new() { Text = "B", Value = "B" },
+            new() { Text = "C", Value = "C" },
+            new() { Text = "D", Value = "D" }
+        };
         class Reason
         {
             public string Value { get; set; }
@@ -60,9 +68,8 @@ namespace wispro.sp.web.Pages.AppCase
             new Reason(){Name="撰写中客户取消申请",Value="撰写中客户取消申请"},
             new Reason(){Name="中-英",Value="中-英"},
             new Reason(){Name="英-中",Value="英-中"},
-            new Reason(){Name="英-德",Value="英-德"}
-
-
+            new Reason(){Name="英-德",Value="英-德"},
+            new Reason(){Name="已算绩效",Value="已算绩效"}
         };
         private List<PerformanceItem> _Datas;
         private List<StaffStatistics> MyStatistics;
@@ -77,6 +84,11 @@ namespace wispro.sp.web.Pages.AppCase
         bool _visible = false;
         bool _isAdd = false;
 
+        List<TabPaneItem> tabList = new List<TabPaneItem>() { 
+            new TabPaneItem(){ Key ="myList", Tab ="本月待确认绩效" },
+            new TabPaneItem(){  Key ="myAll", Tab ="往期已计算绩效"},
+        };
+
         [Inject] public PerformanceItemServices _ItemService { get; set; }
         [Inject] public MessageService _message { get; set; }
         [Inject] protected NavigationManager NavigationManager { get; set; }
@@ -86,43 +98,59 @@ namespace wispro.sp.web.Pages.AppCase
 
 
         private bool isFirstInit = true;
+        private Table<PerformanceItem> table;
         protected async override Task OnInitializedAsync()
         {
             if (isFirstInit)
             {
-                _loading = true;
-                var HandlingCalMonth =await  _CalMonthService.GetHandlingMonth();
-
-                MyStatistics = await _ItemService.CalMyStatistics(HandlingCalMonth.Year,HandlingCalMonth.Month, _userService.CurrentUser.Userid.Value);
-                var data = await _ItemService.GetMyList(_userService.CurrentUser.Userid.Value, jxType.doing,_pageIndex,_pageSize);
 
-                _Datas = data.Results;
-                _total = data.TotalCount;
+                _loading = true;
+                await RefreshMyStatistics();
+                _Datas = new List<PerformanceItem>();// data.Results;
+                _total = 0;//data.TotalCount;
                 _loading = false;
             }
 
             isFirstInit = false;
             StateHasChanged();
-            Console.WriteLine($"OnInitializedAsync:[tota:{_total}\tPageIndex:{_pageIndex}\tPageSize:{_pageSize}]");
+            //Console.WriteLine($"OnInitializedAsync:[tota:{_total}\tPageIndex:{_pageIndex}\tPageSize:{_pageSize}]");
+        }
+
+        private async Task RefreshMyStatistics()
+        {
+            var HandlingCalMonth = await _CalMonthService.GetHandlingMonth();
+
+            MyStatistics = await _ItemService.CalMyStatistics(HandlingCalMonth.Year, HandlingCalMonth.Month, _userService.CurrentUser.Userid.Value);
+            
         }
 
         private string GetStatistics(string strType)
         {
-            if (strType != "ALL")
+            try
             {
-                var tem= MyStatistics.Where<StaffStatistics>(s => s.jxType == strType).FirstOrDefault();
-                if(tem != null)
+                if (strType != "ALL")
                 {
-                    return (tem.totalBasePoint.HasValue?tem.totalBasePoint.Value.ToString("0.00"):"");
+
+                    var tem = MyStatistics.Where<StaffStatistics>(s => s.jxType == strType).FirstOrDefault();
+                    if (tem != null)
+                    {
+                        return (tem.totalBasePoint.HasValue ? tem.totalBasePoint.Value.ToString("0.00") : "");
+                    }
+                    else
+                    {
+                        return "";
+                    }
                 }
+
+
                 else
                 {
-                    return "";
+                    return MyStatistics.Select(s => s.totalBasePoint.Value).Sum().ToString("0.00");
                 }
             }
-            else
+            catch
             {
-                return MyStatistics.Select(s => s.totalBasePoint.Value).Sum().ToString("0.00");
+                return "";
             }
         }
 
@@ -144,13 +172,28 @@ namespace wispro.sp.web.Pages.AppCase
 
         private async Task HandleTableChange(QueryModel<PerformanceItem> queryModel)
         {
-            _loading = true;
-            var data = await _ItemService.Query(_userService.CurrentUser.Userid.Value, jxType.doing, queryModel);
-            
-            _Datas = data.Results;
-            _total = data.TotalCount;
-            _loading = false;
-            StateHasChanged();
+            Console.WriteLine(JsonSerializer.Serialize(queryModel));
+
+            if (_CurrentKey == tabList[0].Key)
+            {
+                _loading = true;
+                var data = await _ItemService.Query(_userService.CurrentUser.Userid.Value, jxType.doing, queryModel);
+
+                _Datas = data.Results;
+                _total = data.TotalCount;
+                _loading = false;
+                StateHasChanged();
+            }
+            else
+            {
+                _loading = true;
+                var data = await _ItemService.Query(_userService.CurrentUser.Userid.Value, jxType.finished, queryModel);
+
+                _Datas = data.Results;
+                _total = data.TotalCount;
+                _loading = false;
+                StateHasChanged();
+            }
 
             
         }
@@ -293,23 +336,8 @@ namespace wispro.sp.web.Pages.AppCase
             new Staff(){Id =4,Name ="贾凤涛"},
         };
 
-        private async Task OnChange(PaginationEventArgs args)
-        {
-            if (_pageIndex != args.Page || _pageSize != args.PageSize)
-            {
-                _pageIndex = args.Page;
-                _pageSize = args.PageSize;
-
-                _loading = true;
-                _Datas = null;
-                var data = await _ItemService.GetMyList(_userService.CurrentUser.Userid.Value, jxType.doing, _pageIndex, _pageSize);
-
-                _Datas = data.Results;
-                _total = data.TotalCount;
-                _loading = false;
-            }
-        }
 
+        #region 特殊绩效字段选择框变更时处理代码
         void SelectChanged(Reason  value)
         {
             if (!_loading && EditingItem != null)
@@ -317,6 +345,8 @@ namespace wispro.sp.web.Pages.AppCase
 
                 var respone = _ItemService.SaveFieldChange(EditingItem.Id, strAgentFeedbackMemo, EditingItem.AgentFeedbackMemo);
                 EditingItem = null;
+                RefreshMyStatistics();
+                table.ReloadData();
             }
         }
 
@@ -325,7 +355,11 @@ namespace wispro.sp.web.Pages.AppCase
             Console.WriteLine($"ClearSelcet:{itemId}");
             var respone = _ItemService.SaveFieldChange(itemId, strAgentFeedbackMemo,"");
             EditingItem = null;
+
+            RefreshMyStatistics();
+            table.ReloadData();
         }
+        #endregion
 
         Dictionary<string, object> OnRow(RowData<PerformanceItem> row)
         {
@@ -345,5 +379,13 @@ namespace wispro.sp.web.Pages.AppCase
         {
             EditingItem = item;
         }
+
+        string _CurrentKey = "myList";
+        void OnTabChange(string key)
+        {
+            _CurrentKey = key;
+            table.ReloadData();
+            StateHasChanged();
+        }
     }
 }

+ 1 - 1
wispro.sp.web/Services/PerformanceItemServices.cs

@@ -124,7 +124,7 @@ namespace wispro.sp.web.Services
             query.Sorts =new  List<OrderField>();
             foreach(var sort in queryModel.SortModel)
             {
-                Console.WriteLine($"{sort.FieldName}\t{sort.Sort}");
+                //Console.WriteLine($"{sort.FieldName}\t{sort.Sort}");
                 if (!string.IsNullOrEmpty(sort.Sort))
                 {
                     query.Sorts.Add(new OrderField() { FieldName = sort.FieldName, Sort = (sort.Sort == "descend" ? 1 : 0) });

+ 9 - 9
wispro.sp.winClient/Form1.cs

@@ -238,21 +238,21 @@ namespace wispro.sp.winClient
 
         public async Task TestQueryFilter()
         {
-            QueryFilter filter = new QueryFilter();
-            filter.ConditionTree = new ExpressTree();
-            string ValueType = typeof(PerformanceItem).GetProperty("CaseNo").PropertyType.ToString();
-            FieldCondition condition1 = new FieldCondition() { FieldName = "CaseNo", Operator = OperatorEnum.Contains, Value = "PACN", ValueType = ValueType };
-            FieldCondition condition2 = new FieldCondition() { FieldName = "CaseNo", Operator = OperatorEnum.Contains, Value = "PAUS", ValueType = ValueType };
+            //QueryFilter filter = new QueryFilter();
+            //filter.ConditionTree = new ExpressTree();
+            //string ValueType = typeof(PerformanceItem).GetProperty("CaseNo").PropertyType.ToString();
+            //FieldCondition condition1 = new FieldCondition() { FieldName = "CaseNo", Operator = OperatorEnum.Contains, Value = "PACN", ValueType = ValueType };
+            //FieldCondition condition2 = new FieldCondition() { FieldName = "CaseNo", Operator = OperatorEnum.Contains, Value = "PAUS", ValueType = ValueType };
 
-            filter.ConditionTree.AddCondition(LogicEnum.And,condition1);
-            filter.ConditionTree.AddCondition(LogicEnum.Or, condition2);
+            //filter.ConditionTree.AddCondition(LogicEnum.And,condition1);
+            //filter.ConditionTree.AddCondition(LogicEnum.Or, condition2);
 
-            System.Diagnostics.Debug.WriteLine(filter.ConditionTree.ToExpressString("s")); ;
+            //System.Diagnostics.Debug.WriteLine(filter.ConditionTree.ToExpressString("s")); ;
 
         }
         private async void button3_Click(object sender, EventArgs e)
         {
-            await TestQueryFilter();
+            //await TestQueryFilter();
 
             await InitRules();
 

+ 40 - 0
wospro.sp.entity/AppealRecord.cs

@@ -0,0 +1,40 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace wispro.sp.entity
+{
+    public class AppealRecord
+    {
+        public int Id { get; set; }
+
+        public Staff Creater { get; set; }
+
+        public DateTime CreateTime { get; set; } = DateTime.Now;
+
+        public List<AttachFile> AttachFiles { get; set; }
+
+        public string Reason { get; set; }
+
+        /// <summary>
+        /// 申诉状态
+        /// 0:待审核
+        /// 1:审核完成
+        /// </summary>
+        public int State { get; set; }
+
+        public Staff Reviewer { get; set; }
+
+        public int ReviewerId { get; set; }
+
+        public string ReviewerMemo { get; set; }
+
+        public DateTime? ReviewTime { get; set; } 
+
+        public virtual AppealType Type { get; set; }
+
+        public int TypeId { get; set; }
+    }
+}

+ 33 - 0
wospro.sp.entity/AppealType.cs

@@ -0,0 +1,33 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace wispro.sp.entity
+{
+    public class AppealType
+    {
+        public int Id { get; set; }
+
+        /// <summary>
+        /// 类型名称
+        /// </summary>
+        public string Name { get; set; }
+
+        /// <summary>
+        /// 可以申诉的条件表达式
+        /// 以linq Express保存
+        /// </summary>
+        public string CanDoExpress { get; set; }
+
+        /// <summary>
+        /// 默认审核人获取表达式
+        /// </summary>
+        public string ReviewerExpress { get; set; }
+
+        public virtual List<InputField> CreateInputFields { get; set; }
+
+        public virtual List<InputField> ReviewFields { get; set; }
+    }
+}

+ 4 - 0
wospro.sp.entity/AttachFile.cs

@@ -17,5 +17,9 @@ namespace wispro.sp.entity
         public Staff UploadUser { get; set; }
 
         public int UploadUserId { get; set; }
+
+        public AppealRecord AppealRecord { get; set; }
+
+        public int AppealRecordId { get; set; }
     }
 }

+ 47 - 0
wospro.sp.entity/InputField.cs

@@ -0,0 +1,47 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace wispro.sp.entity
+{
+    public class InputField
+    {
+        public int Id { get; set; }
+        /// <summary>
+        /// 栏位名称
+        /// </summary>
+        public string FieldName { get; set; }
+
+        /// <summary>
+        /// 栏位类型
+        /// </summary>
+        public string FieldType { get; set; }
+
+        /// <summary>
+        /// 栏位值
+        /// </summary>
+        public string FieldValue { get; set; }
+
+        /// <summary>
+        /// 对应绩效事项的值
+        /// </summary>
+        public string MapObjectField { get; set; }
+
+
+        public virtual AppealType AppealType { get; set; }
+
+        /// <summary>
+        /// 申诉类型
+        /// </summary>
+        public int AppealTypeId { get; set; }
+
+        /// <summary>
+        /// 申诉状态
+        /// </summary>
+        public int AppealState { get; set; }
+
+        
+    }
+}

+ 24 - 0
wospro.sp.entity/InputFieldValue.cs

@@ -0,0 +1,24 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace wispro.sp.entity
+{
+    public class InputFieldValue
+    {
+        public int Id { get; set; }
+
+        public virtual InputField InputField { get; set; }
+        public int InputFieldId { get; set; }
+
+        public string Value { get; set; }
+
+        public int AppealRecordId { get; set; }
+
+        
+
+        
+    }
+}

+ 0 - 10
wospro.sp.entity/PerformanceItem.cs

@@ -23,16 +23,6 @@ namespace wispro.sp.entity
         
         public int Id { get; set; }
 
-        ///// <summary>
-        ///// 绩效计算年度
-        ///// </summary>
-        //public int Year { get; set; }
-
-        ///// <summary>
-        ///// 绩效计算月份
-        ///// </summary>
-        //public int Month { get; set; }
-
         /// <summary>
         /// 我方文号
         /// </summary>