Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Z
zhichan
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
蒋勇
zhichan
Commits
d16db55d
Commit
d16db55d
authored
Apr 29, 2020
by
孙亚楠
Browse files
Options
Browse Files
Download
Plain Diff
dd
parents
836e0b7e
f525e656
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
91 additions
and
34 deletions
+91
-34
xgg-deliver/app/base/controller/impl/invoice/invoiceCtl.js
+28
-2
xgg-deliver/app/base/system.js
+2
-3
xgg-deliver/app/front/entry/public/apidoc/invoice/invoice.md
+61
-29
No files found.
xgg-deliver/app/base/controller/impl/invoice/invoiceCtl.js
View file @
d16db55d
...
@@ -4,6 +4,15 @@ class InvoiceCtl extends CtlBase {
...
@@ -4,6 +4,15 @@ class InvoiceCtl extends CtlBase {
constructor
()
{
constructor
()
{
super
();
super
();
this
.
invoiceSve
=
system
.
getObject
(
"service.invoice.invoiceSve"
);
this
.
invoiceSve
=
system
.
getObject
(
"service.invoice.invoiceSve"
);
this
.
pageType
=
{
"0"
:
[
"2020"
,
"2030"
],
// 我的业务发票
"1"
:
[
"2010"
],
// 发票办理
};
}
getPageStatus
(
type
)
{
type
=
this
.
trim
(
type
||
"0"
);
return
this
.
pageType
[
type
];
}
}
/**
/**
...
@@ -33,15 +42,32 @@ class InvoiceCtl extends CtlBase {
...
@@ -33,15 +42,32 @@ class InvoiceCtl extends CtlBase {
}
}
}
}
setRoleAuth
(
pobj
,
loginUser
)
{
if
(
loginUser
.
isManager
)
{
// 暂时先什么都不做
}
else
if
(
loginUser
.
isMain
)
{
if
(
!
loginUser
.
org_path
)
{
return
system
.
getResultSuccess
({
count
:
0
,
rows
:
[]});
}
pobj
.
operator_path_like
=
loginUser
.
org_path
+
"%"
;
}
else
{
pobj
.
operator_id
=
loginUser
.
id
||
0
;
}
}
/**
/**
* 发票申请列表-业务员
* 发票申请列表-业务员
* @param {*} pobj
* @param {*} pobj
*/
*/
async
myInvoicePage
(
pobj
,
pobj2
,
req
)
{
async
myInvoicePage
(
pobj
,
pobj2
,
req
)
{
try
{
try
{
pobj
.
operator_id
=
req
.
loginUser
.
id
;
pobj
.
assigned
=
true
;
pobj
.
statuses
=
this
.
getPageStatus
(
pobj
.
pageType
);
this
.
setRoleAuth
(
pobj
,
req
.
loginUser
);
this
.
doTimeCondition
(
pobj
,
[
"createTimeBegin"
,
"createTimeEnd"
]);
this
.
doTimeCondition
(
pobj
,
[
"createTimeBegin"
,
"createTimeEnd"
]);
return
await
this
.
invoiceSve
.
invoicePage
(
pobj
);
return
await
this
.
invoiceSve
.
invoicePage
(
pobj
);
}
catch
(
error
)
{
}
catch
(
error
)
{
console
.
log
(
error
);
console
.
log
(
error
);
return
system
.
getResultFail
(
500
,
`接口错误 错误信息
${
error
}
`
);
return
system
.
getResultFail
(
500
,
`接口错误 错误信息
${
error
}
`
);
...
...
xgg-deliver/app/base/system.js
View file @
d16db55d
...
@@ -194,11 +194,10 @@ class System {
...
@@ -194,11 +194,10 @@ class System {
// 订单服务
// 订单服务
// order: domain2 + ":3103" + path,
// order: domain2 + ":3103" + path,
order
:
domain
+
":3103"
+
path
,
order
:
domain
2
+
":3103"
+
path
,
// 发票服务
// 发票服务
// invoice: domain2 + ":3105" + path,
invoice
:
domain
+
":3105"
+
path
,
invoice
:
"http://127.0.0.1:3105"
+
path
,
// 发票服务
// 发票服务
uc
:
domain2
+
":3106"
+
path
,
uc
:
domain2
+
":3106"
+
path
,
...
...
xgg-deliver/app/front/entry/public/apidoc/invoice/invoice.md
View file @
d16db55d
<a
name=
"menu"
>
目录
</a>
<a
name=
"menu"
>
目录
</a>
1.
[
业务进度字典
](
#processList
)
1.
[
业务进度字典
](
#processList
)
2.
[
发票申请页
](
#invoicePage
)
2.
[
发票申请
](
#invoicePage
)
-- 改
1.
[
申请列表页
](
#myInvoicePage
)
1.
[
发票办理
](
#myInvoicePage0
)
-- 改
1.
[
我的业务发票
](
#myInvoicePage1
)
-- 改
1.
[
分配业务员
](
#deliverAssignSalesman
)
1.
[
分配业务员
](
#deliverAssignSalesman
)
1.
[
开具发票
](
#invoiced
)
1.
[
开具发票
](
#invoiced
)
1.
[
提交审核
](
#submitAudit
)
1.
[
提交审核
](
#submitAudit
)
...
@@ -42,7 +43,7 @@
...
@@ -42,7 +43,7 @@
```
```
## **<a name="invoicePage"> 发票申请
页
</a>**
## **<a name="invoicePage"> 发票申请 </a>**
[
返回到目录
](
#menu
)
[
返回到目录
](
#menu
)
##### URL
##### URL
[
/web/invoice/invoiceCtl/invoicePage
]
[
/web/invoice/invoiceCtl/invoicePage
]
...
@@ -54,13 +55,61 @@
...
@@ -54,13 +55,61 @@
说明:
说明:
操作按钮显示
操作按钮显示
查看详情
全部转态都显示
查看详情
全部转态都显示
业务分配
status
=
1030
业务分配
status
=
2000
提交审核
status
=
1050
{
业务交付
status
=
1070
"currentPage"
:
1
,
"pageSize"
:
2
,
"apply_no"
:
""
,
// 申请编号
"status"
:
""
,
// 进度状态
"invoice_type"
:
""
,
// 发票类型 10 增值税专用发票 20 增值税普通发票 30 普通发票
"createTimeBegin"
:
""
,
// 申请时间-开始
"createTimeEnd"
:
""
// 申请时间-结束
}
```
#### 返回结果
```
javascript
{
{
"count"
:
5
,
"rows"
:
[
{
"id"
:
"11855671564003193"
,
"channel_id"
:
"1"
,
"product_id"
:
"50010000"
,
"apply_no"
:
"GONGSIBAO20200213"
,
// 申请编号
"invoice_type"
:
"10"
,
// 发票类型
"invoice_amount"
:
5000
,
// 价税合计总额
"created_at"
:
"2020-03-12 10:46:00"
,
// 申请时间
"status"
:
"2000"
,
// 进度状态
"status_name"
:
"交付商分配"
,
// 进度状态名称
"merchant_name"
:
"汉唐信通(北京)科技有限公司"
,
// 发票抬头
"businessmen_name"
:
"北京创知厚德科技有限公司"
,
// 开票方
"deliver_name"
:
"1"
,
// 交付商名称
"oproduct"
:
{
// 产品
"name"
:
"发票申请"
,
"desc"
:
"发票申请,发票红冲"
,
}
},
],
"requestid"
:
"dc53b7fb2151425e8366edfe317bb8b5"
}
```
## **<a name="myInvoicePage0"> 发票办理 </a>**
[
返回到目录
](
#menu
)
##### URL
[
/web/invoice/invoiceCtl/myInvoicePage
]
#### 参数格式 `JSON`
#### HTTP请求方式 `POST`
```
javascript
{
"currentPage"
:
1
,
"currentPage"
:
1
,
"pageSize"
:
2
,
"pageSize"
:
2
,
"pageType"
:
"0"
,
--
改
// 发票办理 此处传0
"apply_no"
:
""
,
// 申请编号
"apply_no"
:
""
,
// 申请编号
"status"
:
""
,
// 进度状态
"status"
:
""
,
// 进度状态
"invoice_type"
:
""
,
// 发票类型 10 增值税专用发票 20 增值税普通发票 30 普通发票
"invoice_type"
:
""
,
// 发票类型 10 增值税专用发票 20 增值税普通发票 30 普通发票
...
@@ -71,6 +120,7 @@
...
@@ -71,6 +120,7 @@
#### 返回结果
#### 返回结果
```
javascript
```
javascript
一直显示发票开具按钮
{
{
"count"
:
5
,
"count"
:
5
,
...
@@ -85,13 +135,6 @@
...
@@ -85,13 +135,6 @@
"created_at"
:
"2020-03-12 10:46:00"
,
// 申请时间
"created_at"
:
"2020-03-12 10:46:00"
,
// 申请时间
"status"
:
"1110"
,
// 进度状态
"status"
:
"1110"
,
// 进度状态
"status_name"
:
"业务完成"
,
// 进度状态名称
"status_name"
:
"业务完成"
,
// 进度状态名称
"next_status"
:
[
// 下一个进度
{
"next_status"
:
"1010"
,
// 状态码
"next_name"
:
"待完善"
// 状态名称
}
],
"merchant_name"
:
"汉唐信通(北京)科技有限公司"
,
// 发票抬头
"merchant_name"
:
"汉唐信通(北京)科技有限公司"
,
// 发票抬头
"businessmen_name"
:
"北京创知厚德科技有限公司"
,
// 开票方
"businessmen_name"
:
"北京创知厚德科技有限公司"
,
// 开票方
"invoice_deliver"
:
{
// 交付商对象
"invoice_deliver"
:
{
// 交付商对象
...
@@ -109,24 +152,21 @@
...
@@ -109,24 +152,21 @@
```
```
## **<a name="myInvoicePage1"> 我的业务发票 </a>**
## **<a name="myInvoicePage"> 申请列表页 </a>**
[
返回到目录
](
#menu
)
[
返回到目录
](
#menu
)
##### URL
##### URL
[
/web/invoice/invoiceCtl/myInvoicePage
]
[
/web/invoice/invoiceCtl/myInvoicePage
]
#### 参数格式 `JSON`
#### 参数格式 `JSON`
#### HTTP请求方式 `POST`
#### HTTP请求方式 `POST`
```
javascript
按钮规则
status == 2020时,显示客户交付按钮
说明:
操作按钮显示
查看详情
全部转态都显示
新建进度
status
=
1040
||
1080
,显示当前
status_name
```
javascript
{
{
"currentPage"
:
1
,
"currentPage"
:
1
,
"pageSize"
:
2
,
"pageSize"
:
2
,
"pageType"
:
"1"
,
--
改
// 我的业务发票
"apply_no"
:
""
,
// 申请编号
"apply_no"
:
""
,
// 申请编号
"status"
:
""
,
// 进度状态
"status"
:
""
,
// 进度状态
"invoice_type"
:
""
,
// 发票类型 10 增值税专用发票 20 增值税普通发票 30 普通发票
"invoice_type"
:
""
,
// 发票类型 10 增值税专用发票 20 增值税普通发票 30 普通发票
...
@@ -151,13 +191,6 @@
...
@@ -151,13 +191,6 @@
"created_at"
:
"2020-03-12 10:46:00"
,
// 申请时间
"created_at"
:
"2020-03-12 10:46:00"
,
// 申请时间
"status"
:
"1110"
,
// 进度状态
"status"
:
"1110"
,
// 进度状态
"status_name"
:
"业务完成"
,
// 进度状态名称
"status_name"
:
"业务完成"
,
// 进度状态名称
"next_status"
:
[
// 下一个进度
{
"next_status"
:
"1010"
,
// 状态码
"next_name"
:
"待完善"
// 状态名称
}
],
"merchant_name"
:
"汉唐信通(北京)科技有限公司"
,
// 发票抬头
"merchant_name"
:
"汉唐信通(北京)科技有限公司"
,
// 发票抬头
"businessmen_name"
:
"北京创知厚德科技有限公司"
,
// 开票方
"businessmen_name"
:
"北京创知厚德科技有限公司"
,
// 开票方
"invoice_deliver"
:
{
// 交付商对象
"invoice_deliver"
:
{
// 交付商对象
...
@@ -174,7 +207,6 @@
...
@@ -174,7 +207,6 @@
```
```
## **<a name="invoice"> 查询详细信息 </a>**
## **<a name="invoice"> 查询详细信息 </a>**
[
返回到目录
](
#menu
)
[
返回到目录
](
#menu
)
##### URL
##### URL
...
...
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