Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
group-buy-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
ui
group-buy-ui
Commits
7e6ee66d
Commit
7e6ee66d
authored
Sep 26, 2021
by
beisir
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:更改打开小程序方式
parent
fdde41eb
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
31 additions
and
14 deletions
+31
-14
groupBuy.js
src/api/groupBuy.js
+8
-0
utils.service.js
src/service/utils.service.js
+11
-10
module.js
src/store/module.js
+3
-3
List.vue
src/views/orderList/components/List.vue
+3
-1
index.vue
src/views/orderList/index.vue
+6
-0
No files found.
src/api/groupBuy.js
View file @
7e6ee66d
...
@@ -60,5 +60,13 @@ export default {
...
@@ -60,5 +60,13 @@ export default {
},
},
getGroupShareInfo
(
orderNo
)
{
getGroupShareInfo
(
orderNo
)
{
return
http
.
get
(
`
${
talosHost
}
/api/kdsp/groupShareInfo?orderNo=
${
orderNo
}
`
);
return
http
.
get
(
`
${
talosHost
}
/api/kdsp/groupShareInfo?orderNo=
${
orderNo
}
`
);
},
getPlayBillUrl
(
m
)
{
return
http
.
get
(
`http://192.168.25.122/api/kdsp/playBill/getPlayBillUrl?m=
${
m
}
`
);
},
makePlayBillPicUrl
(
activityInfoId
)
{
return
http
.
get
(
`http://192.168.25.122/api/kdsp/activity/activity-info/makePlayBillPicUrl?activityInfoId=
${
activityInfoId
}
`
);
}
}
};
};
src/service/utils.service.js
View file @
7e6ee66d
...
@@ -4,6 +4,7 @@ const jsBridge = new Bridge();
...
@@ -4,6 +4,7 @@ const jsBridge = new Bridge();
import
Vue
from
'
vue
'
;
import
Vue
from
'
vue
'
;
import
config
from
'
@/config
'
;
import
config
from
'
@/config
'
;
export
const
EventBus
=
new
Vue
();
export
const
EventBus
=
new
Vue
();
import
qs
from
'
qs
'
;
/**
/**
* 替换邮箱字符
* 替换邮箱字符
* @param {String} email 输入字符串
* @param {String} email 输入字符串
...
@@ -366,15 +367,15 @@ export function setAppTitleColor(bgcolor = '#fff') {
...
@@ -366,15 +367,15 @@ export function setAppTitleColor(bgcolor = '#fff') {
}
}
export
function
paramsParentheses
(
pointer
)
{
export
function
paramsParentheses
(
pointer
)
{
cons
t
params
=
pointer
.
$route
.
query
;
le
t
params
=
pointer
.
$route
.
query
;
const
path
=
pointer
.
$route
.
path
;
const
path
=
pointer
.
$route
.
path
;
let
tempString
=
''
;
const
paramsString
=
qs
.
stringify
(
params
)
;
for
(
let
key
in
params
)
{
//
for (let key in params) {
let
option
=
`
${
key
}
=
${
params
[
key
]}
`
;
//
let option = `${key}=${params[key]}`;
tempString
+=
`$
${
option
}
`
;
//
tempString += `$${option}`;
}
//
}
if
(
tempString
.
length
)
{
//
if (tempString.length) {
tempString
=
`
${
config
.
localHost
}${
path
}
!`
+
tempString
.
slice
(
1
);
//
tempString = `${config.localHost}${path}!` + tempString.slice(1);
}
//
}
return
temp
String
;
return
`
${
config
.
localHost
}${
path
}
?`
+
params
String
;
}
}
src/store/module.js
View file @
7e6ee66d
...
@@ -104,10 +104,10 @@ const mutations = {
...
@@ -104,10 +104,10 @@ const mutations = {
// todo 跳转到小程序
// todo 跳转到小程序
let
getScheme
=
async
function
()
{
let
getScheme
=
async
function
()
{
const
[
res
]
=
await
groupBuy
.
getScheme
({
const
[
res
]
=
await
groupBuy
.
getScheme
({
miniUrl
:
'
pages/groupbuy/webview
'
,
//
miniUrl: 'pages/groupbuy/webview',
//
miniUrl: 'pages/product/goodDetail',
miniUrl
:
'
pages/product/goodDetail
'
,
params
:
`from=groupBuy&url=
${
encodeURIComponent
(
params
:
`from=groupBuy&url=
${
encodeURIComponent
(
JSON
.
stringify
(
paramsParentheses
(
pointer
))
JSON
.
stringify
(
paramsParentheses
(
pointer
)
+
'
&vccToken={token}
'
)
)}
`
)}
`
});
});
const
url
=
res
;
const
url
=
res
;
...
...
src/views/orderList/components/List.vue
View file @
7e6ee66d
...
@@ -164,7 +164,9 @@ export default {
...
@@ -164,7 +164,9 @@ export default {
else
if
(
isWxMp
)
this
.
nativeBridge
=
new
MpBridge
();
else
if
(
isWxMp
)
this
.
nativeBridge
=
new
MpBridge
();
},
},
methods
:
{
methods
:
{
finishTimeChange
()
{},
finishTimeChange
()
{
this
.
$emit
(
'
finish-time
'
);
},
goGroupBuyList
(
itemInfo
)
{
goGroupBuyList
(
itemInfo
)
{
this
.
$router
.
replace
({
this
.
$router
.
replace
({
path
:
'
/groupBuy/list
'
,
path
:
'
/groupBuy/list
'
,
...
...
src/views/orderList/index.vue
View file @
7e6ee66d
...
@@ -15,6 +15,7 @@
...
@@ -15,6 +15,7 @@
:finished=
"item.finished"
:finished=
"item.finished"
@
load=
"handleLoad"
@
load=
"handleLoad"
@
option-click=
"handleOptionClick"
@
option-click=
"handleOptionClick"
@
finish-time=
"finishTimeChange"
/>
/>
</cr-tab>
</cr-tab>
</cr-tabs>
</cr-tabs>
...
@@ -68,6 +69,11 @@ export default {
...
@@ -68,6 +69,11 @@ export default {
this
.
getList
();
this
.
getList
();
},
},
methods
:
{
methods
:
{
finishTimeChange
()
{
// 倒计时结束之后刷新
window
.
location
.
reload
();
// this.getList();
},
getstatusQuery
()
{
getstatusQuery
()
{
const
{
status
}
=
this
.
$route
.
params
||
{};
const
{
status
}
=
this
.
$route
.
params
||
{};
status
&&
(
this
.
currentTab
=
Number
(
status
));
status
&&
(
this
.
currentTab
=
Number
(
status
));
...
...
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