Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
黄成意
/
yunxin
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
e714b5e0
authored
May 16, 2019
by
PRY5YKGJ82EZEPX\Administrator
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
更新添加联营上传物料
parent
502cb3d8
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
9 deletions
app/Http/Controllers/WebController.php
app/Http/Middleware/CheckLogin.php
public/pc/js/controller/GoodsComList.js
public/pc/js/public.js
app/Http/Controllers/WebController.php
View file @
e714b5e0
...
...
@@ -14,7 +14,7 @@ class WebController extends Controller
{
public
function
info
(
Request
$request
,
$id
=
''
){
if
(
empty
(
$id
)){
return
redirect
(
'/web/Order
List'
);
return
$request
->
supplier_id
>
0
?
redirect
(
'/web/GoodsList'
)
:
redirect
(
'/web/GoodsCom
List'
);
}
$data
[
'id'
]
=
$id
;
$data
[
'URL_YUNXIN'
]
=
config
(
"website.URL_YUNXIN"
);
...
...
app/Http/Middleware/CheckLogin.php
View file @
e714b5e0
...
...
@@ -31,11 +31,12 @@ class CheckLogin
return
redirect
(
'/web/login'
);
}
}
else
{
if
(
strpos
(
$nowUrl
,
'/web/login'
)
!==
false
){
//如果已经登录,跳到登录页
return
redirect
(
'/web/GoodsList'
);
}
Redis
::
expire
(
'yunxin_login_'
.
$yunxin_token
,
7200
);
//延长登录时间
$userInfoArr
=
json_decode
(
$userInfo
,
true
);
if
(
strpos
(
$nowUrl
,
'/web/login'
)
!==
false
){
//如果已经登录,跳到登录页
return
$userInfoArr
[
'supplier_id'
]
>
0
?
redirect
(
'/web/GoodsList'
)
:
redirect
(
'/web/GoodsComList'
);
}
$request
->
mobile
=
$userInfoArr
[
'mobile'
];
$request
->
account_id
=
$userInfoArr
[
'account_id'
];
//自营id
$request
->
supplier_id
=
$userInfoArr
[
'supplier_id'
];
...
...
public/pc/js/controller/GoodsComList.js
View file @
e714b5e0
...
...
@@ -102,9 +102,11 @@
var
t2
=
window
.
setInterval
(
function
()
{
var
res
=
ajax_push2
(
'/api/ApiComImportResult'
,{
"id"
:
logid
})
if
(
res
.
code
==
0
){
layer
.
closeAll
();
window
.
location
.
href
=
res
.
msg
window
.
clearInterval
(
t2
)
layer
.
closeAll
();
alert_succ
(
"导入成功"
,
function
()
{
window
.
location
.
reload
()
})
}
if
(
res
.
code
==
1
){
layer
.
closeAll
();
...
...
public/pc/js/public.js
View file @
e714b5e0
...
...
@@ -52,9 +52,6 @@ function ajax_push2(url,data){
if
(
resp
){
result
=
resp
;
}
},
error
:
function
(
res
)
{
alert_err
(
'网络阻塞,请重试!'
)
}
})
return
result
;
...
...
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