Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
Kivii.Third.Finances.Seeyon.V4.5
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
陶然
Kivii.Third.Finances.Seeyon.V4.5
Commits
b6533944
Commit
b6533944
authored
Nov 08, 2024
by
Neo Turing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化
parent
bc1b9cf2
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
36 additions
and
6 deletions
+36
-6
ApplyExtension.cs
Src/ApplyExtension.cs
+8
-4
OaEntity.cs
Src/Entities/OaEntity.cs
+2
-0
AssemblyInfo.cs
Src/Properties/AssemblyInfo.cs
+2
-2
RestfulOA.cs
Src/RestfulOA.cs
+24
-0
No files found.
Src/ApplyExtension.cs
View file @
b6533944
...
@@ -419,14 +419,16 @@ namespace Kivii.Finances.Seeyon.Extensions
...
@@ -419,14 +419,16 @@ namespace Kivii.Finances.Seeyon.Extensions
#
endregion
#
endregion
#
region
推送部门收入相关
#
region
推送部门收入相关
public
static
string
RequestGetFormXml
(
this
JsonServiceClient
client
,
ResponseToken
token
)
public
static
string
RequestGetFormXml
(
this
JsonServiceClient
client
,
ResponseToken
token
,
DateTime
?
beginTime
=
null
,
DateTime
?
endTime
=
null
)
{
{
if
(
client
==
null
)
throw
new
ArgumentNullException
(
"client"
);
if
(
client
==
null
)
throw
new
ArgumentNullException
(
"client"
);
if
(
beginTime
==
null
)
beginTime
=
DateTime
.
Now
;
if
(
endTime
==
null
)
endTime
=
DateTime
.
Now
;
try
try
{
{
var
rtns
=
client
.
Get
<
string
>(
$"
{
Configs
.
RouteFormExport
}{
Configs
.
templateCodeIncome
}
?token=
{
token
.
id
}
&beginDateTime=
{
DateTime
.
Now
:
yyyy
-
MM
-
dd
}
&endDateTime=
{
DateTime
.
Now
:
yyyy
-
MM
-
dd
}
"
);
var
rtns
=
client
.
Get
<
string
>(
$"
{
Configs
.
RouteFormExport
}{
Configs
.
templateCodeIncome
}
?token=
{
token
.
id
}
&beginDateTime=
{
beginTime
:
yyyy
-
MM
-
dd
}
&endDateTime=
{
endTime
:
yyyy
-
MM
-
dd
}
"
);
return
rtns
;
return
rtns
;
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
...
@@ -476,10 +478,12 @@ namespace Kivii.Finances.Seeyon.Extensions
...
@@ -476,10 +478,12 @@ namespace Kivii.Finances.Seeyon.Extensions
{
{
StringBuilder
sb
=
new
StringBuilder
();
StringBuilder
sb
=
new
StringBuilder
();
sb
.
Append
(
"<forms version=\"2.1\"><formExport><summary id=\"-8487669074587464173\" name=\"formmain_0928\"/><definitions><column id=\"field0005\" type=\"4\" name=\"年份\" isNullable=\"false\" length=\"20\"/><column id=\"field0006\" type=\"0\" name=\"部门\" isNullable=\"false\" length=\"20\"/><column id=\"field0007\" type=\"4\" name=\"核算业务总收入\" isNullable=\"false\" length=\"20\"/><column id=\"field0008\" type=\"4\" name=\"年度业务目标\" isNullable=\"false\" length=\"20\"/><column id=\"field0009\" type=\"4\" name=\"完成率\" isNullable=\"false\" length=\"20\"/><column id=\"field0050\" type=\"3\" name=\"日期\" isNullable=\"false\" length=\"255\"/></definitions><values>"
);
//sb.Append("<forms version=\"2.1\"><formExport><summary id=\"-8487669074587464173\" name=\"formmain_0928\"/><definitions><column id=\"field0005\" type=\"4\" name=\"年份\" isNullable=\"false\" length=\"20\"/><column id=\"field0006\" type=\"0\" name=\"部门\" isNullable=\"false\" length=\"20\"/><column id=\"field0007\" type=\"4\" name=\"核算业务总收入\" isNullable=\"false\" length=\"20\"/><column id=\"field0008\" type=\"4\" name=\"年度业务目标\" isNullable=\"false\" length=\"20\"/><column id=\"field0009\" type=\"4\" name=\"完成率\" isNullable=\"false\" length=\"20\"/><column id=\"field0050\" type=\"3\" name=\"日期\" isNullable=\"false\" length=\"255\"/></definitions><values>");
sb
.
Append
(
"<forms version=\"2.1\"><formExport><summary id=\"-8487669074587464173\" name=\"formmain_0928\"/><definitions><column id=\"field0005\" type=\"4\" name=\"年份\" isNullable=\"false\" length=\"20\"/><column id=\"field0006\" type=\"0\" name=\"部门\" isNullable=\"false\" length=\"20\"/><column id=\"field0007\" type=\"4\" name=\"核算业务总收入\" isNullable=\"false\" length=\"20\"/><column id=\"field0008\" type=\"4\" name=\"年度业务目标\" isNullable=\"false\" length=\"20\"/><column id=\"field0009\" type=\"4\" name=\"完成率\" isNullable=\"false\" length=\"20\"/><column id=\"field0050\" type=\"3\" name=\"日期\" isNullable=\"false\" length=\"255\"/><column id=\"field0057\" type=\"0\" name=\"部门简称\" isNullable=\"false\" length=\"255\"/><column id=\"field0058\" type=\"0\" name=\"部门排序\" isNullable=\"false\" length=\"255\"/><column id=\"field0059\" type=\"4\" name=\"待认领流水条数\" isNullable=\"false\" length=\"20\"/><column id=\"field0060\" type=\"4\" name=\"待认领流水金额\" isNullable=\"false\" length=\"20\"/></definitions><values>"
);
sb
.
Append
(
$"<column name=\"年份\"><value><![CDATA[
{
item
.
Year
}
]]></value></column><column name=\"部门\"><value><![CDATA[
{
item
.
DepartId
}
]]></value></column><column name=\"核算业务总收入\"><value><![CDATA[
{
item
.
AmountTotal
}
]]></value></column><column name=\"年度业务目标\"><value><![CDATA[
{
item
.
AmountTarget
}
]]></value></column><column name=\"完成率\"><value><![CDATA[
{
item
.
Rate
}
]]></value></column><column name=\"日期\"><value><![CDATA[
{
item
.
OperateTime
:
yyyy
-
MM
-
dd
}
]]></value></column>"
);
//sb.Append($"<column name=\"年份\"><value><![CDATA[{item.Year}]]></value></column><column name=\"部门\"><value><![CDATA[{item.DepartId}]]></value></column><column name=\"核算业务总收入\"><value><![CDATA[{item.AmountTotal}]]></value></column><column name=\"年度业务目标\"><value><![CDATA[{item.AmountTarget}]]></value></column><column name=\"完成率\"><value><![CDATA[{item.Rate}]]></value></column><column name=\"日期\"><value><![CDATA[{item.OperateTime:yyyy-MM-dd}]]></value></column>");
sb
.
Append
(
$"<column name=\"年份\"><value><![CDATA[
{
item
.
Year
}
]]></value></column><column name=\"部门\"><value><![CDATA[
{
item
.
DepartId
}
]]></value></column><column name=\"核算业务总收入\"><value><![CDATA[
{
item
.
AmountTotal
}
]]></value></column><column name=\"年度业务目标\"><value><![CDATA[
{
item
.
AmountTarget
}
]]></value></column><column name=\"完成率\"><value><![CDATA[
{
item
.
Rate
}
]]></value></column><column name=\"日期\"><value><![CDATA[
{
item
.
OperateTime
:
yyyy
-
MM
-
dd
}
]]></value></column><column name=\"部门简称\"><value><![CDATA[
{
item
.
Depart
}
]]></value></column><column name=\"部门排序\"><value><![CDATA[0]]></value></column><column name=\"待认领流水条数\"><value>
{
item
.
QuantityUnSplit
}
</value></column><column name=\"待认领流水金额\"><value>
{
item
.
AmountUnSplit
}
</value></column>"
);
sb
.
Append
(
"</values><subForms><subForm><definitions><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/></definitions><values>"
);
sb
.
Append
(
"</values><subForms><subForm><definitions><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/><column id=\"field0051\" type=\"4\" name=\"序号\" isNullable=\"false\" length=\"20\"/><column id=\"field0056\" type=\"4\" name=\"收入类型\" isNullable=\"false\" length=\"20\"/><column id=\"field0052\" type=\"4\" name=\"认领\" isNullable=\"false\" length=\"20\"/><column id=\"field0053\" type=\"4\" name=\"划入\" isNullable=\"false\" length=\"20\"/><column id=\"field0054\" type=\"4\" name=\"划出\" isNullable=\"false\" length=\"20\"/><column id=\"field0055\" type=\"4\" name=\"小计\" isNullable=\"false\" length=\"20\"/></definitions><values>"
);
...
...
Src/Entities/OaEntity.cs
View file @
b6533944
...
@@ -15,6 +15,8 @@ namespace Kivii.Finances.Seeyon.Entities
...
@@ -15,6 +15,8 @@ namespace Kivii.Finances.Seeyon.Entities
public
string
DepartId
{
get
;
set
;
}
public
string
DepartId
{
get
;
set
;
}
public
decimal
AmountTotal
{
get
;
set
;
}
public
decimal
AmountTotal
{
get
;
set
;
}
public
decimal
AmountTarget
{
get
;
set
;
}
public
decimal
AmountTarget
{
get
;
set
;
}
public
int
QuantityUnSplit
{
get
;
set
;
}
public
decimal
AmountUnSplit
{
get
;
set
;
}
public
string
Rate
{
get
;
set
;
}
public
string
Rate
{
get
;
set
;
}
public
DateTime
OperateTime
{
get
;
set
;
}
public
DateTime
OperateTime
{
get
;
set
;
}
public
List
<
OaDepartIncomeDetail
>
Details
{
get
;
set
;
}
public
List
<
OaDepartIncomeDetail
>
Details
{
get
;
set
;
}
...
...
Src/Properties/AssemblyInfo.cs
View file @
b6533944
...
@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
...
@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
//通过使用 "*",如下所示:
//通过使用 "*",如下所示:
// [assembly: AssemblyVersion("1.0.*")]
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("5.4.2024.
729
0")]
[assembly: AssemblyVersion("5.4.2024.
1108
0")]
[assembly: AssemblyFileVersion("5.4.2024.
729
0")]
[assembly: AssemblyFileVersion("5.4.2024.
1108
0")]
Src/RestfulOA.cs
View file @
b6533944
...
@@ -28,6 +28,30 @@ namespace Kivii.Finances.Seeyon
...
@@ -28,6 +28,30 @@ namespace Kivii.Finances.Seeyon
}
}
}
}
public
class
OaDepartIncomeGetFormXml
:
RestfulExecution
<
OaDepartIncome
>
{
public
string
loginName
{
get
;
set
;
}
public
DateTime
?
BeginTime
{
get
;
set
;
}
public
DateTime
?
EndTime
{
get
;
set
;
}
public
override
object
OnExecution
(
IRequest
req
,
IResponse
res
)
{
var
client
=
new
JsonServiceClient
(
Configs
.
BaseUrl
);
var
token
=
client
.
RequestRestToken
(
loginName
);
var
reps
=
client
.
RequestGetFormXml
(
token
,
BeginTime
,
EndTime
);
var
rtns
=
new
HttpResult
{
Response
=
reps
};
//var rtns = new RestfulExecutionResponse<string>();
//rtns.Results = new List<string>();
//rtns.Results.Add(reps);
return
rtns
;
}
}
[
RequiresAnyRole
(
SystemRoles
.
Everyone
)]
[
RequiresAnyRole
(
SystemRoles
.
Everyone
)]
public
class
ContractGetFromOa
:
RestfulExecution
<
Contract
>
public
class
ContractGetFromOa
:
RestfulExecution
<
Contract
>
{
{
...
...
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