Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
纵之格
ShopXO
提交
1a0c9a59
ShopXO
项目概览
纵之格
/
ShopXO
通知
394
Star
16
Fork
11
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
ShopXO
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
1a0c9a59
编写于
4月 06, 2023
作者:
G
gongfuxiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
细节优化
上级
c1248eed
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
29 addition
and
18 deletion
+29
-18
app/admin/form/Goodscomments.php
app/admin/form/Goodscomments.php
+0
-1
app/admin/view/default/goodscomments/module/images.html
app/admin/view/default/goodscomments/module/images.html
+1
-1
app/admin/view/default/goodscomments/save_info.html
app/admin/view/default/goodscomments/save_info.html
+3
-3
app/index/controller/User.php
app/index/controller/User.php
+1
-1
app/index/view/default/goods/comments.html
app/index/view/default/goods/comments.html
+1
-1
app/service/AdminService.php
app/service/AdminService.php
+10
-3
app/service/GoodsCommentsService.php
app/service/GoodsCommentsService.php
+1
-1
app/service/OrderService.php
app/service/OrderService.php
+1
-1
app/service/UserService.php
app/service/UserService.php
+6
-5
public/static/admin/default/css/goodscomments.css
public/static/admin/default/css/goodscomments.css
+5
-1
未找到文件。
app/admin/form/Goodscomments.php
浏览文件 @
1a0c9a59
...
...
@@ -117,7 +117,6 @@ class GoodsComments
'label'
=>
$lang
[
'images'
],
'view_type'
=>
'module'
,
'view_key'
=>
'goodscomments/module/images'
,
'is_list'
=>
0
,
],
[
'label'
=>
$lang
[
'rating'
],
...
...
app/admin/view/default/goodscomments/module/images.html
浏览文件 @
1a0c9a59
<!-- 评论图片 -->
{{if !empty($module_data) and !empty($module_data['images'])}}
<div
data-am-widget=
"slider"
class=
"am-slider am-slider-default images-slider"
data-am-slider=
'{"controlNav":false}'
>
<div
data-am-widget=
"slider"
class=
"am-slider am-slider-default images-slider
am-margin-bottom-0
"
data-am-slider=
'{"controlNav":false}'
>
<ul
class=
"am-slides"
>
{{foreach $module_data.images as $ik=>$iv}}
<li>
...
...
app/admin/view/default/goodscomments/save_info.html
浏览文件 @
1a0c9a59
...
...
@@ -11,12 +11,12 @@
</legend>
<div
class=
"am-cf"
>
<div
class=
"am-u-md-6 am-padding-horizontal-0"
>
<div
class=
"am-alert am-alert-secondary goods-info"
data-am-alert
>
<div
class=
"am-alert am-alert-secondary goods-info"
>
<p
class=
"am-text-sm"
>
{{:MyLang('common_service.goodscomments.form_item_goods_info_title')}}
</p>
{{if !empty($data['goods'])}}
<div
class=
"base am-nbfc"
>
<a
href=
"{{$data.goods.goods_url}}"
target=
"_blank"
>
<img
src=
"{{$data.goods.images}}"
alt=
"{{$data.goods.title}}"
class=
"am-img-thumbnail am-radius am-align-left am-margin-right-xs am-
fl"
width=
"60"
height=
"60
"
/>
<img
src=
"{{$data.goods.images}}"
alt=
"{{$data.goods.title}}"
class=
"am-img-thumbnail am-radius am-align-left am-margin-right-xs am-
margin-bottom-0 am-fl"
width=
"57"
height=
"57
"
/>
</a>
<a
class=
"am-text-top"
href=
"{{$data.goods.goods_url}}"
target=
"_blank"
>
{{$data.goods.title}}
</a>
</div>
...
...
@@ -27,7 +27,7 @@
</div>
</div>
<div
class=
"am-u-md-6 am-padding-horizontal-0"
>
<div
class=
"am-alert am-alert-secondary user-info"
data-am-alert
>
<div
class=
"am-alert am-alert-secondary user-info"
>
<p
class=
"am-text-sm"
>
{{:MyLang('common_service.goodscomments.form_item_user_info_title')}}
</p>
{{if !empty($data['user'])}}
<img
src=
"{{$data.user.avatar}}"
alt=
"{{$data.user.user_name_view}}"
class=
"am-img-thumbnail am-radius am-align-left am-margin-right-xs am-margin-bottom-0"
width=
"35"
height=
"35"
/>
...
...
app/index/controller/User.php
浏览文件 @
1a0c9a59
...
...
@@ -456,7 +456,7 @@ class User extends Common
// 调用服务层
$ret
=
UserService
::
Logout
();
//
登录
返回
//
退出
返回
$body_html
=
(
!
empty
(
$ret
[
'data'
][
'body_html'
])
&&
is_array
(
$ret
[
'data'
][
'body_html'
]))
?
implode
(
' '
,
$ret
[
'data'
][
'body_html'
])
:
$ret
[
'data'
][
'body_html'
];
MyViewAssign
([
'body_html'
=>
$body_html
,
...
...
app/index/view/default/goods/comments.html
浏览文件 @
1a0c9a59
...
...
@@ -7,7 +7,7 @@
<div
class=
"am-comment-meta"
>
<span
class=
"am-comment-author"
>
{{$v.user.user_name_view}}
</span>
<span>
{{:MyLang('goods.comments_first_name')}}
</span>
<time>
{{$v.add_time_
hour
}}
</time>
<time>
{{$v.add_time_
date
}}
</time>
</div>
</header>
<div
class=
"am-comment-bd"
>
...
...
app/service/AdminService.php
浏览文件 @
1a0c9a59
...
...
@@ -472,7 +472,14 @@ class AdminService
*/
public
static
function
LoginInfo
()
{
return
MyCookie
(
self
::
$admin_login_key
);
// 获取管理员信息
$admin
=
MySession
(
self
::
$admin_login_key
);
// 非退出则重新设置管理员信息
if
(
RequestAction
()
!=
'logout'
)
{
self
::
LoginSession
(
$admin
);
}
return
$admin
;
}
/**
...
...
@@ -487,7 +494,7 @@ class AdminService
public
static
function
LoginSession
(
$admin
)
{
unset
(
$admin
[
'login_pwd'
],
$admin
[
'login_salt'
]);
My
Cookie
(
self
::
$admin_login_key
,
$admin
);
My
Session
(
self
::
$admin_login_key
,
$admin
);
return
true
;
}
...
...
@@ -501,7 +508,7 @@ class AdminService
*/
public
static
function
LoginLogout
()
{
return
My
Cookie
(
self
::
$admin_login_key
,
null
);
return
My
Session
(
self
::
$admin_login_key
,
null
);
}
/**
...
...
app/service/GoodsCommentsService.php
浏览文件 @
1a0c9a59
...
...
@@ -261,7 +261,7 @@ class GoodsCommentsService
if
(
!
isset
(
$params
[
'is_public'
])
||
$params
[
'is_public'
]
==
1
)
{
$v
[
'user'
]
=
[
'avatar'
=>
empty
(
$user
[
'avatar'
]
)
?
$default_avatar
:
$user
[
'avatar'
],
'avatar'
=>
((
isset
(
$v
[
'is_anonymous'
])
&&
$v
[
'is_anonymous'
]
==
1
)
||
empty
(
$user
[
'avatar'
])
)
?
$default_avatar
:
$user
[
'avatar'
],
'user_name_view'
=>
(
!
isset
(
$v
[
'is_anonymous'
])
||
$v
[
'is_anonymous'
]
==
1
||
empty
(
$user
[
'user_name_view'
]))
?
$username_default
:
mb_substr
(
$user
[
'user_name_view'
],
0
,
1
,
'utf-8'
)
.
'***'
.
mb_substr
(
$user
[
'user_name_view'
],
-
1
,
null
,
'utf-8'
),
];
}
else
{
...
...
app/service/OrderService.php
浏览文件 @
1a0c9a59
...
...
@@ -127,7 +127,7 @@ class OrderService
}
// 订单支付前校验订单商品
$ret
=
BuyService
::
MoreOrderPayBeginCheck
(
[
'order_data'
=>
$order_data
]
);
$ret
=
BuyService
::
MoreOrderPayBeginCheck
(
array_merge
(
$params
,
[
'order_data'
=>
$order_data
])
);
if
(
$ret
[
'code'
]
!=
0
)
{
return
$ret
;
...
...
app/service/UserService.php
浏览文件 @
1a0c9a59
...
...
@@ -239,7 +239,8 @@ class UserService
{
$user_login_info
=
self
::
CacheLoginUserInfo
();
}
if
(
!
empty
(
$user_login_info
))
// 非退出操作则重新设置用户信息
if
(
!
empty
(
$user_login_info
)
&&
RequestAction
()
!=
'logout'
)
{
// 是否缓存读取
if
(
$is_cache
)
...
...
@@ -306,7 +307,7 @@ class UserService
if
(
APPLICATION
==
'web'
)
{
// web用户session
$user_cache_login_info
=
My
Cookie
(
self
::
$user_login_key
);
$user_cache_login_info
=
My
Session
(
self
::
$user_login_key
);
// 用户信息为空,指定了token则设置登录信息
if
(
empty
(
$user_cache_login_info
))
...
...
@@ -826,7 +827,7 @@ class UserService
if
(
APPLICATION
==
'web'
)
{
// 存储session
My
Cookie
(
self
::
$user_login_key
,
$user
);
My
Session
(
self
::
$user_login_key
,
$user
);
}
return
true
;
}
...
...
@@ -3013,10 +3014,10 @@ class UserService
public
static
function
Logout
(
$params
=
[])
{
// 用户信息
$user
=
self
::
LoginUserInfo
();
$user
=
self
::
Cache
LoginUserInfo
();
// 清除session
My
Cookie
(
self
::
$user_login_key
,
null
);
My
Session
(
self
::
$user_login_key
,
null
);
// html代码
$body_html
=
[];
...
...
public/static/admin/default/css/goodscomments.css
浏览文件 @
1a0c9a59
/**
* 列表
*/
.content-right
table
.am-table
.reply-content
{
.content-right
table
.am-table
.reply-content
,
.content-right
table
.am-table
.images-slider
img
{
max-height
:
58px
;
}
.content-right
table
.am-table
.images-slider
.am-direction-nav
.am-prev
,
.content-right
table
.am-table
.images-slider
.am-direction-nav
.am-next
{
z-index
:
1
;
}
.content-right
table
.am-table
.images-slider
.am-slider-desc
{
padding
:
1px
5px
;
}
/**
* 编辑
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录