Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-pay
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit ae323571
authored
Dec 28, 2021
by
cwq0219
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
导出
1 parent
7c4a85ce
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
59 additions
and
28 deletions
src/common/constant.js
src/views/couponManage/index.vue
src/views/couponManage/writeOffDetail.vue
src/views/memberCenter/order.vue
src/views/memberCenter/record.vue
src/views/orderManage/index.vue
src/common/constant.js
View file @
ae32357
...
@@ -31,6 +31,52 @@ function limitPrice(newValue, oldValue, intergerDigit, pointDigit, minValue, max
...
@@ -31,6 +31,52 @@ function limitPrice(newValue, oldValue, intergerDigit, pointDigit, minValue, max
}
}
}
}
function
getExplorer
()
{
var
ua
=
navigator
.
userAgent
.
toLocaleLowerCase
()
var
browserType
=
null
if
(
ua
.
match
(
/msie/
)
!=
null
||
ua
.
match
(
/trident/
)
!=
null
)
{
browserType
=
'IE'
}
else
if
(
ua
.
match
(
/firefox/
)
!=
null
)
{
browserType
=
'火狐'
}
else
if
(
ua
.
match
(
/ubrowser/
)
!=
null
)
{
browserType
=
'UC'
}
else
if
(
ua
.
match
(
/opera/
)
!=
null
)
{
browserType
=
'欧朋'
}
else
if
(
ua
.
match
(
/bidubrowser/
)
!=
null
)
{
browserType
=
'百度'
}
else
if
(
ua
.
match
(
/metasr/
)
!=
null
)
{
browserType
=
'搜狗'
}
else
if
(
ua
.
match
(
/tencenttraveler/
)
!=
null
||
ua
.
match
(
/qqbrowse/
)
!=
null
)
{
browserType
=
'QQ'
}
else
if
(
ua
.
match
(
/maxthon/
)
!=
null
)
{
browserType
=
'遨游'
}
else
{
browserType
=
'谷歌'
}
return
browserType
}
function
exportFn
(
url
)
{
let
browserType
=
getExplorer
()
if
(
browserType
==
'QQ'
)
{
window
.
open
(
url
)
return
}
let
iframe
=
document
.
createElement
(
'iframe'
)
iframe
.
style
.
display
=
'none'
iframe
.
src
=
url
document
.
body
.
appendChild
(
iframe
)
}
// function aToExport(url) {
// var a = document.createElement('a')
// a.setAttribute('id', 'exportToExport')
// a.setAttribute('href', url)
// a.setAttribute('target', '_blank')
// document.body.appendChild(a)
// a.click()
// }
const
orderManageStatusList
=
[
const
orderManageStatusList
=
[
{
confId
:
'1'
,
confName
:
'未支付'
},
{
confId
:
'1'
,
confName
:
'未支付'
},
{
confId
:
'2'
,
confName
:
'已支付'
},
{
confId
:
'2'
,
confName
:
'已支付'
},
...
@@ -151,6 +197,9 @@ const stateList = [{
...
@@ -151,6 +197,9 @@ const stateList = [{
export
{
export
{
limitPrice
,
limitPrice
,
getExplorer
,
exportFn
,
// aToExport,
orderManageStatusList
,
orderManageStatusList
,
orderSourceList
,
orderSourceList
,
deliveryTypeList
,
deliveryTypeList
,
...
...
src/views/couponManage/index.vue
View file @
ae32357
...
@@ -45,6 +45,7 @@
...
@@ -45,6 +45,7 @@
<
script
>
<
script
>
import
url
from
'@/assets/empty.png'
import
url
from
'@/assets/empty.png'
import
{
exportFn
}
from
'@/common/constant'
export
default
{
export
default
{
name
:
'coupon'
,
name
:
'coupon'
,
data
()
{
data
()
{
...
@@ -349,11 +350,7 @@ export default {
...
@@ -349,11 +350,7 @@ export default {
handleExport
(
row
)
{
handleExport
(
row
)
{
var
params
=
this
.
getParams
()
var
params
=
this
.
getParams
()
this
.
$apis
.
couponManage
.
couponExportApi
(
params
).
then
(
res
=>
{
this
.
$apis
.
couponManage
.
couponExportApi
(
params
).
then
(
res
=>
{
var
a
=
document
.
createElement
(
'a'
)
exportFn
(
res
)
a
.
setAttribute
(
'href'
,
res
)
a
.
setAttribute
(
'target'
,
'_blank'
)
document
.
body
.
appendChild
(
a
)
a
.
click
()
})
})
},
},
...
...
src/views/couponManage/writeOffDetail.vue
View file @
ae32357
...
@@ -55,6 +55,7 @@
...
@@ -55,6 +55,7 @@
<
script
>
<
script
>
import
*
as
dayjs
from
'dayjs'
import
*
as
dayjs
from
'dayjs'
import
url
from
'@/assets/empty.png'
import
url
from
'@/assets/empty.png'
import
{
exportFn
}
from
'@/common/constant'
export
default
{
export
default
{
name
:
'writeOffDetail'
,
name
:
'writeOffDetail'
,
data
()
{
data
()
{
...
@@ -258,11 +259,7 @@ export default {
...
@@ -258,11 +259,7 @@ export default {
handleExport
(
row
)
{
handleExport
(
row
)
{
var
params
=
this
.
getParams
()
var
params
=
this
.
getParams
()
this
.
$apis
.
couponManage
.
verificationExportApi
(
params
).
then
(
res
=>
{
this
.
$apis
.
couponManage
.
verificationExportApi
(
params
).
then
(
res
=>
{
var
a
=
document
.
createElement
(
'a'
)
exportFn
(
res
)
a
.
setAttribute
(
'href'
,
res
)
a
.
setAttribute
(
'target'
,
'_blank'
)
document
.
body
.
appendChild
(
a
)
a
.
click
()
})
})
},
},
...
...
src/views/memberCenter/order.vue
View file @
ae32357
...
@@ -53,7 +53,7 @@
...
@@ -53,7 +53,7 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
orderTypesList
,
orderStatusList
}
from
'@/common/constant'
import
{
orderTypesList
,
orderStatusList
,
exportFn
}
from
'@/common/constant'
import
url
from
'@/assets/empty.png'
import
url
from
'@/assets/empty.png'
import
{
getOrderListApi
,
orderExportApi
}
from
'@/api/modules/order'
import
{
getOrderListApi
,
orderExportApi
}
from
'@/api/modules/order'
export
default
{
export
default
{
...
@@ -215,11 +215,7 @@ export default {
...
@@ -215,11 +215,7 @@ export default {
handleExport
(
row
)
{
handleExport
(
row
)
{
var
params
=
this
.
getParams
()
var
params
=
this
.
getParams
()
orderExportApi
(
params
).
then
(
res
=>
{
orderExportApi
(
params
).
then
(
res
=>
{
var
a
=
document
.
createElement
(
'a'
)
exportFn
(
res
)
a
.
setAttribute
(
'href'
,
res
)
a
.
setAttribute
(
'target'
,
'_blank'
)
document
.
body
.
appendChild
(
a
)
a
.
click
()
})
})
},
},
...
...
src/views/memberCenter/record.vue
View file @
ae32357
...
@@ -63,6 +63,7 @@ import glsxDialog from '@/components/glsx-dialog'
...
@@ -63,6 +63,7 @@ import glsxDialog from '@/components/glsx-dialog'
import
{
getRecordListApi
,
getVerificationCode
,
verificationExportApi
}
from
'@/api/modules/record'
import
{
getRecordListApi
,
getVerificationCode
,
verificationExportApi
}
from
'@/api/modules/record'
import
url
from
"@/assets/empty.png"
import
url
from
"@/assets/empty.png"
import
{
dateFormat
}
from
'@/utils/index.js'
import
{
dateFormat
}
from
'@/utils/index.js'
import
{
exportFn
}
from
'@/common/constant'
export
default
{
export
default
{
name
:
'record'
,
name
:
'record'
,
components
:
{
components
:
{
...
@@ -241,11 +242,7 @@ export default {
...
@@ -241,11 +242,7 @@ export default {
handleExport
(
row
)
{
handleExport
(
row
)
{
var
params
=
this
.
getParams
()
var
params
=
this
.
getParams
()
verificationExportApi
(
params
).
then
(
res
=>
{
verificationExportApi
(
params
).
then
(
res
=>
{
var
a
=
document
.
createElement
(
'a'
)
exportFn
(
res
)
a
.
setAttribute
(
'href'
,
res
)
a
.
setAttribute
(
'target'
,
'_blank'
)
document
.
body
.
appendChild
(
a
)
a
.
click
()
})
})
},
},
...
...
src/views/orderManage/index.vue
View file @
ae32357
...
@@ -112,7 +112,7 @@
...
@@ -112,7 +112,7 @@
<
script
>
<
script
>
import
*
as
dayjs
from
'dayjs'
import
*
as
dayjs
from
'dayjs'
import
url
from
"@/assets/empty.png"
import
url
from
"@/assets/empty.png"
import
{
orderManageStatusList
,
orderSourceList
,
deliveryTypeList
}
from
'@/common/constant'
import
{
orderManageStatusList
,
orderSourceList
,
deliveryTypeList
,
exportFn
}
from
'@/common/constant'
export
default
{
export
default
{
name
:
'orderManage'
,
name
:
'orderManage'
,
data
()
{
data
()
{
...
@@ -654,12 +654,7 @@ export default {
...
@@ -654,12 +654,7 @@ export default {
handleExport
(
row
)
{
handleExport
(
row
)
{
var
params
=
this
.
getParams
()
var
params
=
this
.
getParams
()
this
.
$apis
.
orderManage
.
orderExportApi
(
params
).
then
(
res
=>
{
this
.
$apis
.
orderManage
.
orderExportApi
(
params
).
then
(
res
=>
{
// window.open(res)
exportFn
(
res
)
var
a
=
document
.
createElement
(
'a'
)
a
.
setAttribute
(
'href'
,
res
)
a
.
setAttribute
(
'target'
,
'_blank'
)
document
.
body
.
appendChild
(
a
)
a
.
click
()
})
})
},
},
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment