Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
performance
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zry
performance
Commits
23155235
Commit
23155235
authored
Sep 01, 2020
by
ruyun.zhang@suvalue.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
handsontable format
parent
40d2f569
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
67 additions
and
20 deletions
+67
-20
performance/Performance.Api/wwwroot/Performance.DtoModels.xml
+21
-0
performance/Performance.DtoModels/Enum.cs
+17
-0
performance/Performance.DtoModels/HandsonTable.cs
+24
-1
performance/Performance.Infrastructure/Extensions/Extensions.Dictionary.cs
+3
-1
performance/Performance.Services/PerExcelService/RecognitionDataFormat.cs
+2
-18
No files found.
performance/Performance.Api/wwwroot/Performance.DtoModels.xml
View file @
23155235
...
...
@@ -148,6 +148,27 @@
工作量
</summary>
</member>
<member
name=
"F:Performance.DtoModels.DataFormat.普通格式"
>
<summary>
普通格式
</summary>
</member>
<member
name=
"F:Performance.DtoModels.DataFormat.小数"
>
<summary>
小数
</summary>
</member>
<member
name=
"F:Performance.DtoModels.DataFormat.货币"
>
<summary>
货币
</summary>
</member>
<member
name=
"F:Performance.DtoModels.DataFormat.百分比"
>
<summary>
百分比
</summary>
</member>
<member
name=
"F:Performance.DtoModels.DataFormat.科学计数"
>
<summary>
科学计数
</summary>
</member>
<member
name=
"F:Performance.DtoModels.DataFormat.分数"
>
<summary>
分数
</summary>
</member>
<member
name=
"F:Performance.DtoModels.DataFormat.日期"
>
<summary>
日期
</summary>
</member>
<member
name=
"P:Performance.DtoModels.PerAgainData.RowNumber"
>
<summary>
行号
...
...
performance/Performance.DtoModels/Enum.cs
View file @
23155235
...
...
@@ -93,4 +93,21 @@ public enum AgWorkloadType
/// </summary>
Workload
=
2
,
}
public
enum
DataFormat
{
/// <summary> 普通格式 </summary>
普通格式
,
/// <summary> 小数 </summary>
小数
,
/// <summary> 货币 </summary>
货币
,
/// <summary> 百分比 </summary>
百分比
,
/// <summary> 科学计数 </summary>
科学计数
,
/// <summary> 分数 </summary>
分数
,
/// <summary> 日期 </summary>
日期
}
}
performance/Performance.DtoModels/HandsonTable.cs
View file @
23155235
...
...
@@ -87,13 +87,36 @@ private void InitColumns(List<collect_permission> permissions)
public
class
HandsonColumn
{
public
HandsonColumn
(
string
data
,
bool
readOnly
=
false
)
public
HandsonColumn
(
string
data
,
bool
readOnly
=
false
,
DataFormat
format
=
DataFormat
.
普通格式
)
{
Data
=
data
;
ReadOnly
=
readOnly
;
switch
(
format
)
{
case
DataFormat
.
普通格式
:
Type
=
"text"
;
break
;
case
DataFormat
.
小数
:
Type
=
"numeric"
;
NumericFormat
=
new
NumericFormat
{
Pattern
=
"0,00.00"
};
break
;
case
DataFormat
.
百分比
:
Type
=
"numeric"
;
NumericFormat
=
new
NumericFormat
{
Pattern
=
"0,00.00%"
};
break
;
}
}
public
string
Data
{
get
;
set
;
}
public
bool
ReadOnly
{
get
;
set
;
}
public
string
Type
{
get
;
set
;
}
public
NumericFormat
NumericFormat
{
get
;
set
;
}
}
public
class
NumericFormat
{
public
string
Pattern
{
get
;
set
;
}
}
public
class
DefalutHandsonHeader
...
...
performance/Performance.Infrastructure/Extensions/Extensions.Dictionary.cs
View file @
23155235
...
...
@@ -2,6 +2,7 @@
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Linq.Expressions
;
using
System.Text
;
namespace
Performance.Infrastructure
...
...
@@ -55,4 +56,4 @@ public static T GetValue<T>(this SortedDictionary<string, object> keyValues, str
return
kv
;
}
}
}
}
\ No newline at end of file
performance/Performance.Services/PerExcelService/RecognitionDataFormat.cs
View file @
23155235
using
System
;
using
Performance.DtoModels
;
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Text
;
namespace
Performance.Services
{
public
enum
DataFormat
{
/// <summary> 普通格式 </summary>
普通格式
,
/// <summary> 小数 </summary>
小数
,
/// <summary> 货币 </summary>
货币
,
/// <summary> 百分比 </summary>
百分比
,
/// <summary> 科学计数 </summary>
科学计数
,
/// <summary> 分数 </summary>
分数
,
/// <summary> 日期 </summary>
日期
}
public
class
RecognitionDataFormat
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment