Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mallapp
Project
Project
Details
Activity
Releases
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
viitto
mallapp
Commits
86c98add
Commit
86c98add
authored
Aug 18, 2020
by
Mac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
微店参数的提交
parent
8ba08fca
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
41 additions
and
11 deletions
+41
-11
index.vue
components/auth/index.vue
+4
-1
goods.vue
pages/goods/goods.vue
+10
-2
index.vue
pages/index/index.vue
+11
-2
index.vue
pages/live/index.vue
+7
-1
index.vue
pages/microShop/index/index.vue
+3
-2
api.js
plugin/api.js
+6
-3
No files found.
components/auth/index.vue
View file @
86c98add
...
...
@@ -118,6 +118,7 @@ export default {
getLogin
(
obj
)
{
var
that
=
this
;
let
pid
=
uni
.
getStorageSync
(
"pid"
)?
uni
.
getStorageSync
(
"pid"
).
pid
:
0
;
let
SmallShopId
=
uni
.
getStorageSync
(
"SmallShopId"
)?
uni
.
getStorageSync
(
"SmallShopId"
).
SmallShopId
:
0
;
that
.
request2
(
{
url
:
'/api/AppletLogin/Login'
,
...
...
@@ -127,7 +128,8 @@ export default {
Name
:
obj
.
Name
,
Photo
:
obj
.
Photo
,
Moblie
:
''
,
SuperiorId
:
pid
SuperiorId
:
pid
,
SmallShopId
:
SmallShopId
,
}
},
res
=>
{
...
...
@@ -140,6 +142,7 @@ export default {
this
.
couponMessage
=
res
.
couponMessage
;
}
uni
.
removeStorageSync
(
'pid'
);
uni
.
removeStorageSync
(
'SmallShopId'
);
}
}
);
...
...
pages/goods/goods.vue
View file @
86c98add
...
...
@@ -355,10 +355,14 @@ export default {
if
(
option
&&
option
.
user_id
)
{
uni
.
setStorageSync
(
"pid"
,
{
pid
:
option
.
user_id
});
}
if
(
option
&&
option
.
SmallShopId
)
{
uni
.
setStorageSync
(
"SmallShopId"
,
{
SmallShopId
:
option
.
SmallShopId
});
}
if
(
uni
.
getStorageSync
(
"AnchorName"
))
{
//如果有主播名称了先清除
uni
.
removeStorageSync
(
"AnchorName"
);
}
if
(
option
&&
option
.
AnchorName
)
{
//当传过来有主播名称的时候 存入缓存
uni
.
setStorageSync
(
"AnchorName"
,
{
AnchorName
:
option
.
AnchorName
});
...
...
@@ -395,6 +399,9 @@ export default {
let
uid
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserId
:
0
;
let
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
SmallShopId
:
0
;
let
title
=
this
.
g
.
app_share_title
!=
null
&&
this
.
g
.
app_share_title
!=
""
?
this
.
g
.
app_share_title
...
...
@@ -406,7 +413,7 @@ export default {
let
id
=
this
.
id
;
return
{
title
:
title
,
query
:
"id="
+
this
.
id
+
"&user_id="
+
uid
,
query
:
"id="
+
this
.
id
+
"&user_id="
+
uid
+
"&SmallShopId="
+
SmallShopId
,
imageUrl
:
imageUrl
,
};
},
...
...
@@ -417,12 +424,13 @@ export default {
},
2500
);
let
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
let
uid
=
u
.
UserId
?
u
.
UserId
:
0
;
let
SmallShopId
=
u
.
SmallShopId
?
u
.
SmallShopId
:
0
;
return
{
title
:
this
.
g
.
app_share_title
!=
null
&&
this
.
g
.
app_share_title
!=
""
?
this
.
g
.
app_share_title
:
this
.
g
.
name
,
path
:
"/pages/goods/goods?id="
+
this
.
id
+
"&user_id="
+
uid
,
path
:
"/pages/goods/goods?id="
+
this
.
id
+
"&user_id="
+
uid
+
"&SmallShopId="
+
SmallShopId
,
imageUrl
:
this
.
g
.
app_share_pic
!=
null
&&
this
.
g
.
app_share_pic
!=
""
?
this
.
g
.
app_share_pic
...
...
pages/index/index.vue
View file @
86c98add
...
...
@@ -192,6 +192,9 @@ export default {
if
(
options
&&
options
.
user_id
)
{
uni
.
setStorageSync
(
"pid"
,
{
pid
:
options
.
user_id
});
}
if
(
options
&&
options
.
SmallShopId
)
{
uni
.
setStorageSync
(
"SmallShopId"
,
{
SmallShopId
:
options
.
SmallShopId
});
}
if
(
options
&&
options
.
scene
)
{
//兼容之前小程序的调转
...
...
@@ -242,10 +245,13 @@ export default {
let
uid
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserId
:
0
;
let
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
SmallShopId
:
0
;
console
.
log
(
uid
);
return
{
title
:
""
,
query
:
"user_id="
+
uid
,
query
:
"user_id="
+
uid
+
"&SmallShopId="
+
SmallShopId
,
imageUrl
:
""
,
};
},
...
...
@@ -257,11 +263,14 @@ export default {
let
uid
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserId
:
0
;
let
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
SmallShopId
:
0
;
return
{
title
:
this
.
setting
.
share_title
?
this
.
setting
.
share_title
:
uni
.
getStorageSync
(
"basedata"
).
mall
.
name
,
path
:
"/pages/index/index?user_id="
+
uid
,
path
:
"/pages/index/index?user_id="
+
uid
+
"&SmallShopId="
+
SmallShopId
,
imageUrl
:
this
.
setting
.
share_pic
?
this
.
setting
.
share_pic
:
""
,
};
},
...
...
pages/live/index.vue
View file @
86c98add
...
...
@@ -154,6 +154,9 @@ export default {
if
(
option
.
user_id
)
{
uni
.
setStorageSync
(
"pid"
,
{
pid
:
option
.
user_id
});
}
if
(
option
.
SmallShopId
)
{
uni
.
setStorageSync
(
"SmallShopId"
,
{
SmallShopId
:
option
.
SmallShopId
});
}
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
if
(
!
this
.
u
)
{
this
.
u
=
{
...
...
@@ -189,7 +192,10 @@ export default {
let
uid
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
UserId
:
0
;
let
customParams
=
encodeURIComponent
(
JSON
.
stringify
({
user_id
:
uid
}));
let
SmallShopId
=
uni
.
getStorageSync
(
"mall_UserInfo"
)
?
uni
.
getStorageSync
(
"mall_UserInfo"
).
SmallShopId
:
0
;
let
customParams
=
encodeURIComponent
(
JSON
.
stringify
({
user_id
:
uid
,
SmallShopId
:
SmallShopId
}));
wx
.
navigateTo
({
url
:
`plugin-private://wx2b03c6e691cd7370/pages/live-player-plugin?room_id=
${
cx
.
roomid
}
&custom_params=
${
customParams
}
`
,
});
...
...
pages/microShop/index/index.vue
View file @
86c98add
...
...
@@ -448,13 +448,13 @@
this
.
QRcodeShow
=
true
;
let
that
=
this
let
UserInfo
=
uni
.
getStorageSync
(
'mall_UserInfo'
)
?
uni
.
getStorageSync
(
'mall_UserInfo'
):{};
let
wdUserId
=
this
.
SmallShops
.
UserInfo
.
UserId
uni
.
showNavigationBarLoading
();
that
.
request2
(
{
url
:
'/api/AppletUser/GetWeiXinQRCodeForAppletSmallShops'
,
data
:
{
Path
:
'pages/index/index?user_id='
+
UserInfo
.
UserId
+
'&
wdUserId='
+
wdUser
Id
,
Path
:
'pages/index/index?user_id='
+
UserInfo
.
UserId
+
'&
SmallShopId='
+
UserInfo
.
SmallShop
Id
,
With
:
212
,
}
},
...
...
@@ -463,6 +463,7 @@
that
.
fenxqrcode
=
that
.
host2
+
res
.
data
;
// that.fenxqrcode = 'http://192.168.2.16:8088/upfile/temporary/d259ce3f-eee3-4c20-976d-4d054f6f16b3.jpg';
console
.
log
(
that
.
fenxqrcode
)
console
.
log
(
'pages/index/index?user_id='
+
UserInfo
.
UserId
+
'&SmallShopId='
+
UserInfo
.
SmallShopId
)
}
);
},
...
...
plugin/api.js
View file @
86c98add
...
...
@@ -2,8 +2,8 @@ export default {
install
(
Vue
,
options
)
{
Vue
.
prototype
.
host
=
"https://wx.weibaoge.cn/web/index.php?_mall_id=1285"
// Vue.prototype.host2 = "http://192.168.0.110:8200"
Vue
.
prototype
.
host2
=
"https://mallApi.oytour.com"
//
Vue.prototype.host2 = "http://192.168.2.16:8088"
//
Vue.prototype.host2 = "https://mallApi.oytour.com"
Vue
.
prototype
.
host2
=
"http://192.168.2.16:8088"
// Vue.prototype.host2 = "http://192.168.2.65"
Vue
.
prototype
.
request
=
function
(
param
,
success
,
failed
)
{
//网络请求
...
...
@@ -86,6 +86,7 @@ export default {
// token失效再次登录接口
Vue
.
prototype
.
getLogin_t
=
function
(
obj
)
{
let
pid
=
uni
.
getStorageSync
(
"pid"
)?
uni
.
getStorageSync
(
"pid"
).
pid
:
0
;
let
SmallShopId
=
uni
.
getStorageSync
(
"SmallShopId"
)?
uni
.
getStorageSync
(
"SmallShopId"
).
SmallShopId
:
0
;
this
.
request2
(
{
url
:
'/api/AppletLogin/Login'
,
...
...
@@ -95,13 +96,15 @@ export default {
Name
:
obj
.
Name
,
Photo
:
obj
.
Photo
,
Moblie
:
''
,
SuperiorId
:
pid
SuperiorId
:
pid
,
SmallShopId
:
SmallShopId
,
}
},
res
=>
{
if
(
res
.
resultCode
==
1
)
{
uni
.
setStorageSync
(
'mall_UserInfo'
,
res
.
data
);
uni
.
removeStorageSync
(
'pid'
);
uni
.
removeStorageSync
(
'SmallShopId'
);
}
}
);
...
...
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