Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
foreign
/
customer-service
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
8d620d11
authored
Dec 21, 2021
by
Sixong.Zhu
Browse files
Options
_('Browse Files')
Download
Plain Diff
Merge branch 'master' into pre
parents
d1c3f11e
0822f25b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
34 additions
and
7 deletions
components/message.vue
model/order.ts
service/order.ts
components/message.vue
View file @
8d620d11
...
...
@@ -7,6 +7,7 @@
'justify-content-center': isWithdrawMessage,
'offset-bottom': matchKeywords,
}"
@mouseenter="hoverWithdraw"
>
<div
class=
"msg-content"
:class=
"
{ 'algin-left': !isMyMessage }">
<div
...
...
@@ -101,7 +102,6 @@
!isQuestionAnswerMessage &&
isChatMember
"
@
mouseenter=
"hoverWithdraw"
@
click=
"withdraw"
>
撤回此消息
</span
>
...
...
@@ -171,6 +171,7 @@
import
Xim
from
"@/customer-service/xim"
;
const
twoMinutes
=
2
*
60
*
1000
;
const
twoHours
=
2
*
60
*
60
*
1000
;
const
messageMapping
=
new
Map
<
dto
.
MessageType
,
string
>
([
[
dto
.
MessageType
.
Image
,
"image-message"
],
...
...
@@ -266,7 +267,10 @@
private
get
canWithdraw
()
{
if
(
this
.
backend
&&
this
.
data
)
{
return
new
Date
().
valueOf
()
-
this
.
data
.
ts
*
1000
<
twoMinutes
;
if
(
this
.
needReadTip
)
{
return
new
Date
().
valueOf
()
-
this
.
data
.
ts
*
1000
<
twoMinutes
;
}
return
new
Date
().
valueOf
()
-
this
.
data
.
ts
*
1000
<
twoHours
;
}
return
false
;
}
...
...
@@ -276,7 +280,8 @@
this
.
data
.
type
!==
dto
.
MessageType
.
Pay
&&
this
.
data
.
type
!==
dto
.
MessageType
.
Refund
&&
this
.
data
.
type
!==
dto
.
MessageType
.
PayV1
&&
this
.
data
.
type
!==
dto
.
MessageType
.
RefundV1
this
.
data
.
type
!==
dto
.
MessageType
.
RefundV1
&&
this
.
data
.
type
!==
dto
.
MessageType
.
PayResult
);
}
...
...
@@ -496,8 +501,12 @@
}
private
hoverWithdraw
()
{
this
.
isWithdraw
=
new
Date
().
valueOf
()
-
this
.
data
.
ts
*
1000
<
twoMinutes
;
if
(
!
this
.
isWithdraw
||
!
this
.
isMyMessage
)
{
return
;
}
this
.
isWithdraw
=
this
.
needReadTip
?
new
Date
().
valueOf
()
-
this
.
data
.
ts
*
1000
<
twoMinutes
:
new
Date
().
valueOf
()
-
this
.
data
.
ts
*
1000
<
twoHours
;
}
private
openReaderList
(
e
:
MouseEvent
)
{
...
...
model/order.ts
View file @
8d620d11
...
...
@@ -135,6 +135,7 @@ export interface OrderPayItem {
OpenningBankName
?:
string
;
bankAccountNo
?:
string
;
paymentItemId
?:
number
;
paymentDate
:
string
;
}
export
interface
OrderComment
{
...
...
@@ -153,7 +154,7 @@ export const orderPayItemPredict = {
method
:
"PaymentFunction_label"
,
type
:
"ItemName"
,
desc
:
"PaymentDesc"
,
agent
:
"ProviderCollectId#provider_agent.AgentTrueName"
,
agent
:
"ProviderCollectId#provider_a
ll_a
gent.AgentTrueName"
,
id
:
"ID"
,
v
:
"uniplat_version"
,
title
:
"ItemName"
,
...
...
@@ -163,6 +164,7 @@ export const orderPayItemPredict = {
OpenningBankName
:
"ProviderHandleId#ServiceProviderBank.OpenningBankName"
,
bankAccountNo
:
"ProviderHandleId#ServiceProviderBank.AccountNo"
,
paymentItemId
:
"PaymentItemId"
,
paymentDate
:
"PaymentDate"
,
};
export
const
enum
ChatOpenDirection
{
...
...
@@ -190,6 +192,8 @@ export const enum OperationType {
}
export
interface
UploadImageItem
{
id
:
number
;
v
:
number
;
url
:
string
;
fileName
:
string
;
time
:
string
;
...
...
service/order.ts
View file @
8d620d11
...
...
@@ -17,6 +17,7 @@ class OrderService {
public
readonly
generalOrder
=
"general_order_info"
;
public
readonly
generalOrderPaymentModel
=
"general_order_payment_info"
;
private
readonly
commentModel
=
"uniplat_model_remark@general_order"
;
private
readonly
fileModel
=
"general_order_payment_file_info"
;
private
readonly
handler
=
new
UniplatSdkExtender
();
private
innerSdk
:
UniplatSdk
|
null
=
null
;
...
...
@@ -171,7 +172,7 @@ class OrderService {
public
getImages4Payment
(
payment
:
number
)
{
return
this
.
getSdk
()
.
model
(
"general_order_payment_file_info"
)
.
model
(
this
.
fileModel
)
.
list
()
.
addPrefilter
({
PaymentId
:
payment
})
.
query
({
item_size
:
10
,
pageIndex
:
1
})
...
...
@@ -181,10 +182,23 @@ class OrderService {
fileSize
:
"FileSize"
,
fileName
:
"FileName"
,
url
:
"Url"
,
id
:
"ID"
,
v
:
"uniplat_version"
,
})
);
}
public
deleteImage
(
payment
:
number
,
image
:
number
,
v
:
number
)
{
return
this
.
getSdk
()
.
model
(
this
.
fileModel
)
.
action
(
"delete"
)
.
updateInitialParams
({
selected_list
:
[{
v
,
id
:
image
}],
prefilters
:
[{
property
:
"PaymentId"
,
value
:
payment
}],
})
.
execute
();
}
public
buildOrder
(
o
:
metaRow
)
{
return
this
.
handler
.
buildRow
<
OrderTableListItem
>
(
o
,
orderPredict
);
}
...
...
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