Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
starsw001
ShopXO
提交
82da920b
ShopXO
项目概览
starsw001
/
ShopXO
与 Fork 源项目一致
Fork自
纵之格 / ShopXO
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
ShopXO
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
82da920b
编写于
4月 11, 2021
作者:
D
Devil
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
站点类型优化+细节 优化
上级
dc653a2b
变更
38
隐藏空白更改
内联
并排
Showing
38 changed file
with
298 addition
and
146 deletion
+298
-146
application/admin/controller/Common.php
application/admin/controller/Common.php
+3
-0
application/admin/controller/Goods.php
application/admin/controller/Goods.php
+2
-2
application/admin/controller/Site.php
application/admin/controller/Site.php
+4
-0
application/admin/view/default/admin/login_info.html
application/admin/view/default/admin/login_info.html
+1
-1
application/admin/view/default/public/header.html
application/admin/view/default/public/header.html
+1
-1
application/admin/view/default/public/nav.html
application/admin/view/default/public/nav.html
+1
-1
application/admin/view/default/site/siteset/discount.html
application/admin/view/default/site/siteset/discount.html
+38
-0
application/api/controller/Answer.php
application/api/controller/Answer.php
+2
-2
application/api/controller/Banner.php
application/api/controller/Banner.php
+2
-2
application/api/controller/Base.php
application/api/controller/Base.php
+2
-2
application/api/controller/Buy.php
application/api/controller/Buy.php
+2
-2
application/api/controller/Cart.php
application/api/controller/Cart.php
+2
-2
application/api/controller/Goods.php
application/api/controller/Goods.php
+4
-4
application/api/controller/Index.php
application/api/controller/Index.php
+2
-2
application/api/controller/Message.php
application/api/controller/Message.php
+2
-2
application/api/controller/Navigation.php
application/api/controller/Navigation.php
+2
-2
application/api/controller/Order.php
application/api/controller/Order.php
+4
-4
application/api/controller/Orderaftersale.php
application/api/controller/Orderaftersale.php
+3
-3
application/api/controller/Region.php
application/api/controller/Region.php
+2
-2
application/api/controller/Search.php
application/api/controller/Search.php
+2
-2
application/api/controller/Toutiao.php
application/api/controller/Toutiao.php
+2
-2
application/api/controller/User.php
application/api/controller/User.php
+2
-2
application/api/controller/Useraddress.php
application/api/controller/Useraddress.php
+3
-3
application/api/controller/Usergoodsbrowse.php
application/api/controller/Usergoodsbrowse.php
+2
-2
application/api/controller/Usergoodsfavor.php
application/api/controller/Usergoodsfavor.php
+2
-2
application/api/controller/Userintegral.php
application/api/controller/Userintegral.php
+2
-2
application/common.php
application/common.php
+2
-2
application/index/controller/Buy.php
application/index/controller/Buy.php
+2
-2
application/index/controller/Common.php
application/index/controller/Common.php
+8
-2
application/index/view/default/public/footer_nav.html
application/index/view/default/public/footer_nav.html
+2
-6
application/index/view/default/user/login_content.html
application/index/view/default/user/login_content.html
+15
-1
application/service/BuyService.php
application/service/BuyService.php
+3
-3
application/service/GoodsService.php
application/service/GoodsService.php
+2
-2
application/service/PluginsService.php
application/service/PluginsService.php
+1
-1
application/service/SystemBaseService.php
application/service/SystemBaseService.php
+161
-2
application/tags.php
application/tags.php
+0
-72
changelog.txt
changelog.txt
+8
-4
public/static/common/images/default-company-license.jpg
public/static/common/images/default-company-license.jpg
+0
-0
未找到文件。
application/admin/controller/Common.php
浏览文件 @
82da920b
...
...
@@ -263,6 +263,9 @@ class Common extends Controller
// 默认不加载百度地图api
$this
->
assign
(
'is_load_baidu_map_api'
,
0
);
// 站点名称
$this
->
assign
(
'admin_theme_site_name'
,
MyC
(
'admin_theme_site_name'
,
'ShopXO'
,
true
));
}
/**
...
...
application/admin/controller/Goods.php
浏览文件 @
82da920b
...
...
@@ -11,7 +11,7 @@
namespace
app\admin\controller
;
use
think\facade\Hook
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsService
;
use
app\service\RegionService
;
use
app\service\BrandService
;
...
...
@@ -198,7 +198,7 @@ class Goods extends Common
// 站点类型
$this
->
assign
(
'common_site_type_list'
,
lang
(
'common_site_type_list'
));
// 当前系统设置的站点类型
$this
->
assign
(
'common_site_type'
,
BaseService
::
SiteTypeValue
());
$this
->
assign
(
'common_site_type'
,
System
BaseService
::
SiteTypeValue
());
// 商品参数类型
$this
->
assign
(
'common_goods_parameters_type_list'
,
lang
(
'common_goods_parameters_type_list'
));
...
...
application/admin/controller/Site.php
浏览文件 @
82da920b
...
...
@@ -245,6 +245,10 @@ class Site extends Common
'name'
=>
'订单'
,
'type'
=>
'order'
,
],
[
'name'
=>
'优惠'
,
'type'
=>
'discount'
,
],
[
'name'
=>
'扩展'
,
'type'
=>
'extends'
,
...
...
application/admin/view/default/admin/login_info.html
浏览文件 @
82da920b
...
...
@@ -4,7 +4,7 @@
<div
class=
"account-pages"
>
<div
class=
"wrapper-page"
>
<div
class=
"am-text-center"
>
<span
class=
"logo"
>
ShopXO
</span>
<span
class=
"logo"
>
{{$admin_theme_site_name}}
</span>
</div>
<div
class=
"am-margin-top-lg am-nbfc admin-login"
>
{{if count($admin_login_type) gt 0}}
...
...
application/admin/view/default/public/header.html
浏览文件 @
82da920b
...
...
@@ -4,7 +4,7 @@
<meta
charset=
"{{:config('shopxo.default_charset', 'utf-8')}}"
/>
<link
rel=
"shortcut icon"
type=
"image/x-icon"
href=
"{{$public_host}}favicon.ico"
/>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1.0, minimum-scale=1, maximum-scale=1"
/>
<title>
ShopXO
后台管理系统
</title>
<title>
{{$admin_theme_site_name}}
后台管理系统
</title>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"{{$public_host}}static/common/lib/assets/css/amazeui.css?v={{:MyC('home_static_cache_version')}}"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"{{$public_host}}static/common/lib/amazeui-switch/amazeui.switch.css?v={{:MyC('home_static_cache_version')}}"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"{{$public_host}}static/common/lib/amazeui-chosen/amazeui.chosen.css?v={{:MyC('home_static_cache_version')}}"
/>
...
...
application/admin/view/default/public/nav.html
浏览文件 @
82da920b
<header
class=
"am-topbar am-topbar-inverse admin-header"
>
<div
class=
"am-topbar-brand"
>
<a
href=
"{{:MyUrl('admin/index/index')}}"
>
<h2>
ShopXO
<span
class=
"admin-site-vice-name am-margin-left-xs"
>
后台管理系统
</span></h2>
<h2>
{{$admin_theme_site_name}}
<span
class=
"admin-site-vice-name am-margin-left-xs"
>
后台管理系统
</span></h2>
</a>
</div>
<button
class=
"am-topbar-btn am-topbar-toggle am-btn am-btn-xs am-btn-success am-show-sm-only am-radius header-nav-submit"
data-am-collapse=
"{target: '#topbar-collapse'}"
>
...
...
application/admin/view/default/site/siteset/discount.html
0 → 100644
浏览文件 @
82da920b
{{include file="public/header" /}}
<!-- right content start -->
<div
class=
"content-right"
>
<!-- second nav start -->
{{include file="site/public/nav" /}}
<!-- second nav end -->
<div
class=
"content"
>
<!-- nav start -->
{{include file="site/public/siteset_nav" /}}
<!-- nav end -->
<!-- form start -->
<form
class=
"am-form form-validation view-save"
action=
"{{:MyUrl('admin/site/save')}}"
method=
"POST"
request-type=
"ajax-url"
request-value=
"{{:MyUrl('admin/site/index', ['nav_type'=>$nav_type, 'view_type'=>$view_type])}}"
enctype=
"multipart/form-data"
>
<div
class=
"am-form-group"
>
<label>
{{$data.is_close_goods_discount_overlap.name}}
<span
class=
"am-form-group-label-tips"
>
{{$data.is_close_goods_discount_overlap.describe}}
</span></label>
<select
name=
"{{$data.is_close_goods_discount_overlap.only_tag}}"
class=
"am-radius chosen-select"
data-validation-message=
"{{$data.is_close_goods_discount_overlap.error_tips}}"
required
>
{{foreach $common_is_text_list as $v}}
<option
value=
"{{$v.id}}"
{{
if
isset
($
data
['
is_close_goods_discount_overlap
']['
value
'])
and
$
data
['
is_close_goods_discount_overlap
']['
value
']
eq
$
v
['
id
']}}
selected
{{/
if
}}
>
{{$v.name}}
</option>
{{/foreach}}
</select>
</div>
<div
class=
"am-form-group am-form-group-refreshing am-margin-top-lg am-padding-left-0"
>
<input
type=
"hidden"
name=
"nav_type"
value=
"{{$nav_type}}"
/>
<input
type=
"hidden"
name=
"view_type"
value=
"{{$view_type}}"
/>
<button
type=
"submit"
class=
"am-btn am-btn-primary am-radius btn-loading-example am-btn-sm am-btn-block"
data-am-loading=
"{loadingText:'处理中...'}"
>
保存
</button>
</div>
</form>
<!-- form end -->
</div>
</div>
<!-- right content end -->
<!-- footer start -->
{{include file="public/footer" /}}
<!-- footer end -->
\ No newline at end of file
application/api/controller/Answer.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\AnswerService
;
/**
...
...
@@ -77,7 +77,7 @@ class Answer extends Common
'page_total'
=>
$page_total
,
'data'
=>
$data
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
application/api/controller/Banner.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\BannerService
;
/**
...
...
@@ -46,7 +46,7 @@ class Banner extends Common
{
// 获取轮播
$result
=
BannerService
::
Banner
();
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
}
?>
\ No newline at end of file
application/api/controller/Base.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
/**
* 基础公共接口
...
...
@@ -35,7 +35,7 @@ class Base extends Common
// 参数
$params
=
$this
->
data_post
;
$params
[
'user'
]
=
$this
->
user
;
return
BaseService
::
Common
(
$params
);
return
System
BaseService
::
Common
(
$params
);
}
}
?>
\ No newline at end of file
application/api/controller/Buy.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsService
;
use
app\service\UserService
;
use
app\service\PaymentService
;
...
...
@@ -73,7 +73,7 @@ class Buy extends Common
'common_site_type'
=>
(
int
)
$buy_base
[
'common_site_type'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
return
$buy_ret
;
}
...
...
application/api/controller/Cart.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\BuyService
;
/**
...
...
@@ -53,7 +53,7 @@ class Cart extends Common
'common_cart_total'
=>
BuyService
::
UserCartTotal
([
'user'
=>
$this
->
user
]),
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
application/api/controller/Goods.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsService
;
use
app\service\BuyService
;
use
app\service\GoodsCommentsService
;
...
...
@@ -115,7 +115,7 @@ class Goods extends Common
'common_cart_total'
=>
BuyService
::
UserCartTotal
([
'user'
=>
$this
->
user
]),
'buy_button'
=>
$buy_button
,
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
@@ -190,7 +190,7 @@ class Goods extends Common
$result
=
[
'category'
=>
GoodsService
::
GoodsCategoryAll
(
$this
->
data_post
),
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
@@ -256,7 +256,7 @@ class Goods extends Common
'page_total'
=>
$page_total
,
'data'
=>
$ret
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
}
?>
\ No newline at end of file
application/api/controller/Index.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsService
;
use
app\service\BannerService
;
use
app\service\AppHomeNavService
;
...
...
@@ -54,7 +54,7 @@ class Index extends Common
'data_list'
=>
GoodsService
::
HomeFloorList
(),
'common_cart_total'
=>
BuyService
::
UserCartTotal
([
'user'
=>
$this
->
user
]),
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
}
?>
\ No newline at end of file
application/api/controller/Message.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\MessageService
;
/**
...
...
@@ -80,7 +80,7 @@ class Message extends Common
'page_total'
=>
$page_total
,
'data'
=>
$data
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
}
?>
\ No newline at end of file
application/api/controller/Navigation.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\AppHomeNavService
;
/**
...
...
@@ -46,7 +46,7 @@ class Navigation extends Common
{
// 获取轮播
$result
=
AppHomeNavService
::
AppHomeNav
();
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
}
?>
\ No newline at end of file
application/api/controller/Order.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\PaymentService
;
use
app\service\OrderService
;
use
app\service\GoodsCommentsService
;
...
...
@@ -87,7 +87,7 @@ class Order extends Common
'data'
=>
$data
[
'data'
],
'payment_list'
=>
$payment_list
,
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
@@ -133,7 +133,7 @@ class Order extends Common
$site_fictitious
=
ConfigService
::
SiteFictitiousConfig
();
$result
[
'site_fictitious'
]
=
$site_fictitious
[
'data'
];
}
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
return
DataReturn
(
'数据不存在或已删除'
,
-
100
);
}
...
...
@@ -180,7 +180,7 @@ class Order extends Common
'data'
=>
$data
[
'data'
][
0
],
'editor_path_type'
=>
ResourcesService
::
EditorPathTypeValue
(
'order_comments-'
.
$this
->
user
[
'id'
]
.
'-'
.
$data
[
'data'
][
0
][
'id'
]),
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
return
DataReturn
(
'没有相关数据'
,
-
100
);
}
...
...
application/api/controller/Orderaftersale.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\OrderAftersaleService
;
use
app\service\ResourcesService
;
...
...
@@ -81,7 +81,7 @@ class Orderaftersale extends Common
'page_total'
=>
$page_total
,
'data'
=>
$data
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
@@ -141,7 +141,7 @@ class Orderaftersale extends Common
'return_goods_address'
=>
MyC
(
'home_order_aftersale_return_goods_address'
,
'管理员未填写'
,
true
),
'editor_path_type'
=>
ResourcesService
::
EditorPathTypeValue
(
OrderAftersaleService
::
EditorAttachmentPathType
(
$this
->
user
[
'id'
],
$order_id
,
$order_detail_id
)),
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
return
DataReturn
(
$ret
[
'msg'
],
-
1
);
}
...
...
application/api/controller/Region.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\RegionService
;
/**
...
...
@@ -52,7 +52,7 @@ class Region extends Common
],
];
$result
=
RegionService
::
RegionNode
(
$params
);
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
application/api/controller/Search.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\SearchService
;
/**
...
...
@@ -71,7 +71,7 @@ class Search extends Common
// 商品规格
$result
[
'goods_spec_list'
]
=
SearchService
::
SearchGoodsSpecValueList
(
$this
->
data_request
);
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
}
?>
\ No newline at end of file
application/api/controller/Toutiao.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\ToutiaoService
;
/**
...
...
@@ -52,7 +52,7 @@ class Toutiao extends Common
$params
=
$this
->
data_post
;
$params
[
'user'
]
=
$this
->
user
;
$ret
=
ToutiaoService
::
Pay
(
$params
);
return
BaseService
::
DataReturn
(
$ret
[
'data'
]);
return
System
BaseService
::
DataReturn
(
$ret
[
'data'
]);
}
}
?>
\ No newline at end of file
application/api/controller/User.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\UserService
;
use
app\service\OrderService
;
use
app\service\GoodsService
;
...
...
@@ -638,7 +638,7 @@ class User extends Common
);
// 返回数据
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
application/api/controller/Useraddress.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\ConfigService
;
use
app\service\UserAddressService
;
use
app\service\ResourcesService
;
...
...
@@ -54,7 +54,7 @@ class UserAddress extends Common
$result
=
[
'data'
=>
$ret
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
@@ -76,7 +76,7 @@ class UserAddress extends Common
'data'
=>
empty
(
$data
[
'data'
])
?
null
:
$data
[
'data'
],
'editor_path_type'
=>
ResourcesService
::
EditorPathTypeValue
(
UserAddressService
::
EditorAttachmentPathType
(
$this
->
user
[
'id'
])),
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
application/api/controller/Usergoodsbrowse.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsBrowseService
;
/**
...
...
@@ -78,7 +78,7 @@ class UserGoodsBrowse extends Common
'page_total'
=>
$page_total
,
'data'
=>
$data
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
application/api/controller/Usergoodsfavor.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsFavorService
;
/**
...
...
@@ -77,7 +77,7 @@ class UserGoodsFavor extends Common
'page_total'
=>
$page_total
,
'data'
=>
$data
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
/**
...
...
application/api/controller/Userintegral.php
浏览文件 @
82da920b
...
...
@@ -10,7 +10,7 @@
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\IntegralService
;
/**
...
...
@@ -78,7 +78,7 @@ class UserIntegral extends Common
'page_total'
=>
$page_total
,
'data'
=>
$data
[
'data'
],
];
return
BaseService
::
DataReturn
(
$result
);
return
System
BaseService
::
DataReturn
(
$result
);
}
}
...
...
application/common.php
浏览文件 @
82da920b
...
...
@@ -358,7 +358,7 @@ function ArrayKeys($data)
*/
function
GoodsSalesModelType
(
$site_type
)
{
return
(
$site_type
==
-
1
)
?
\
app\service\BaseService
::
SiteTypeValue
()
:
$site_type
;
return
(
$site_type
==
-
1
)
?
\
app\service\
System
BaseService
::
SiteTypeValue
()
:
$site_type
;
}
/**
...
...
@@ -380,7 +380,7 @@ function IsGoodsSiteTypeConsistent($site_type)
}
// 系统站点类型
$common_site_type
=
\
app\service\BaseService
::
SiteTypeValue
();
$common_site_type
=
\
app\service\
System
BaseService
::
SiteTypeValue
();
// 是否一致
if
(
$common_site_type
==
$site_type
)
...
...
application/index/controller/Buy.php
浏览文件 @
82da920b
...
...
@@ -11,7 +11,7 @@
namespace
app\index\controller
;
use
think\facade\Hook
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsService
;
use
app\service\UserService
;
use
app\service\UserAddressService
;
...
...
@@ -59,7 +59,7 @@ class Buy extends Common
return
redirect
(
MyUrl
(
'index/buy/index'
));
}
else
{
// 站点类型,是否开启了展示型
if
(
BaseService
::
SiteTypeValue
()
==
1
)
if
(
System
BaseService
::
SiteTypeValue
()
==
1
)
{
$this
->
assign
(
'msg'
,
'展示型不允许提交订单'
);
return
$this
->
fetch
(
'public/tips_error'
);
...
...
application/index/controller/Common.php
浏览文件 @
82da920b
...
...
@@ -14,7 +14,7 @@ use think\Controller;
use
think\facade\Hook
;
use
app\module\FormHandleModule
;
use
app\service\SystemService
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\ResourcesService
;
use
app\service\GoodsService
;
use
app\service\NavigationService
;
...
...
@@ -169,6 +169,9 @@ class Common extends Controller
// 用户登录页面顶部钩子
$this
->
assign
(
'plugins_view_user_login_info_top_data'
,
Hook
::
listen
(
'plugins_view_user_login_info_top'
,
[
'hook_name'
=>
'plugins_view_user_login_info_top'
,
'is_backend'
=>
false
,
'user'
=>
$this
->
user
]));
// 用户登录内容页面底部钩子
$this
->
assign
(
'plugins_view_user_login_content_bottom_data'
,
Hook
::
listen
(
'plugins_view_user_login_content_bottom'
,
[
'hook_name'
=>
'plugins_view_user_login_content_bottom'
,
'is_backend'
=>
false
,
'user'
=>
$this
->
user
]));
// 用户注册页面钩子
$this
->
assign
(
'plugins_view_user_reg_info_data'
,
Hook
::
listen
(
'plugins_view_user_reg_info'
,
[
'hook_name'
=>
'plugins_view_user_reg_info'
,
'is_backend'
=>
false
,
'user'
=>
$this
->
user
]));
...
...
@@ -300,7 +303,7 @@ class Common extends Controller
$this
->
assign
(
'currency_symbol'
,
ResourcesService
::
CurrencyDataSymbol
());
// 站点类型
$this
->
assign
(
'common_site_type'
,
BaseService
::
SiteTypeValue
());
$this
->
assign
(
'common_site_type'
,
System
BaseService
::
SiteTypeValue
());
// 预约模式
$this
->
assign
(
'common_order_is_booking'
,
MyC
(
'common_order_is_booking'
,
0
,
true
));
...
...
@@ -420,6 +423,9 @@ class Common extends Controller
// 登录/注册方式
$this
->
assign
(
'home_user_login_type'
,
MyC
(
'home_user_login_type'
,
[],
true
));
$this
->
assign
(
'home_user_reg_type'
,
MyC
(
'home_user_reg_type'
,
[],
true
));
// 底部信息
$this
->
assign
(
'home_theme_footer_bottom_powered'
,
htmlspecialchars_decode
(
MyC
(
'home_theme_footer_bottom_powered'
)));
}
/**
...
...
application/index/view/default/public/footer_nav.html
浏览文件 @
82da920b
...
...
@@ -84,9 +84,7 @@
{{/if}}
<p
class=
"powered"
>
Powered by
<a
href=
"http://shopxo.net/"
title=
"ShopXO电商系统"
target=
"_blank"
>
<span
class=
"b"
>
Shop
</span><span
class=
"o"
>
XO
</span>
</a>
{{$Think.APPLICATION_VERSION}}
{{$home_theme_footer_bottom_powered|raw}} {{$Think.APPLICATION_VERSION}}
</p>
{{if !empty($home_site_icp)}}
<p
class=
"footer-icp"
>
...
...
@@ -112,9 +110,7 @@
<!-- 页脚信息 -->
<div
class=
"am-footer-miscs"
>
<p
class=
"powered"
>
Powered by
<a
href=
"http://shopxo.net/"
title=
"ShopXO电商系统"
target=
"_blank"
>
<span
class=
"b"
>
Shop
</span><span
class=
"o"
>
XO
</span>
</a>
{{$Think.APPLICATION_VERSION}}
{{$home_theme_footer_bottom_powered|raw}} {{$Think.APPLICATION_VERSION}}
</p>
</div>
</footer>
...
...
application/index/view/default/user/login_content.html
浏览文件 @
82da920b
...
...
@@ -112,4 +112,18 @@
<a
href=
"{{:MyUrl('index/user/forgetpwdinfo')}}"
target=
"_blank"
class=
"am-fr"
>
忘记密码?
</a>
</div>
</div>
</div>
\ No newline at end of file
</div>
<!-- 用户登录内容页面底部钩子 -->
{{if isset($shopxo_is_develop) and $shopxo_is_develop eq true}}
<div
class=
"plugins-tag"
>
<span>
plugins_view_user_login_content_bottom
</span>
</div>
{{/if}}
{{if !empty($plugins_view_user_login_content_bottom_data) and is_array($plugins_view_user_login_content_bottom_data)}}
{{foreach $plugins_view_user_login_content_bottom_data as $hook}}
{{if is_string($hook) or is_int($hook)}}
{{$hook|raw}}
{{/if}}
{{/foreach}}
{{/if}}
\ No newline at end of file
application/service/BuyService.php
浏览文件 @
82da920b
...
...
@@ -12,7 +12,7 @@ namespace app\service;
use
think\Db
;
use
think\facade\Hook
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\GoodsService
;
use
app\service\UserService
;
use
app\service\UserAddressService
;
...
...
@@ -698,7 +698,7 @@ class BuyService
// 站点模式 0销售, 2自提, 4销售+自提, 则其它正常模式
$user_site_model
=
isset
(
$params
[
'site_model'
])
?
intval
(
$params
[
'site_model'
])
:
0
;
$common_site_type
=
BaseService
::
SiteTypeValue
();
$common_site_type
=
System
BaseService
::
SiteTypeValue
();
$site_model
=
(
$common_site_type
==
4
)
?
$user_site_model
:
$common_site_type
;
// 商品销售模式
...
...
@@ -952,7 +952,7 @@ class BuyService
public
static
function
OrderInsert
(
$params
=
[])
{
// 站点类型,是否开启了展示型
$common_site_type
=
BaseService
::
SiteTypeValue
();
$common_site_type
=
System
BaseService
::
SiteTypeValue
();
if
(
$common_site_type
==
1
)
{
return
DataReturn
(
'展示型不允许提交订单'
,
-
1
);
...
...
application/service/GoodsService.php
浏览文件 @
82da920b
...
...
@@ -12,7 +12,7 @@ namespace app\service;
use
think\Db
;
use
think\facade\Hook
;
use
app\service\BaseService
;
use
app\service\
System
BaseService
;
use
app\service\ResourcesService
;
use
app\service\BrandService
;
use
app\service\RegionService
;
...
...
@@ -2692,7 +2692,7 @@ class GoodsService
$path
=
'static'
.
DS
.
'upload'
.
DS
.
'images'
.
DS
.
'goods_qrcode'
.
DS
.
APPLICATION_CLIENT_TYPE
.
DS
.
date
(
'Y'
,
$add_time
)
.
DS
.
date
(
'm'
,
$add_time
)
.
DS
.
date
(
'd'
,
$add_time
)
.
DS
;
// 名称增加站点模式(站点模式不一样商品url地址也会不一样)
$filename
=
$goods_id
.
BaseService
::
SiteTypeValue
()
.
'.png'
;
$filename
=
$goods_id
.
System
BaseService
::
SiteTypeValue
()
.
'.png'
;
// 二维码处理参数
$params
=
[
...
...
application/service/PluginsService.php
浏览文件 @
82da920b
...
...
@@ -53,7 +53,7 @@ class PluginsService
self
::
PluginsCacheStorage
(
$plugins
,
$data
);
}
}
return
DataReturn
(
'处理成功'
,
0
,
$data
);
return
DataReturn
(
'处理成功'
,
0
,
empty
(
$data
)
?
[]
:
$data
);
}
/**
...
...
application/service/BaseService.php
→
application/service/
System
BaseService.php
浏览文件 @
82da920b
...
...
@@ -10,21 +10,25 @@
// +----------------------------------------------------------------------
namespace
app\service
;
use
think\Db
;
use
think\facade\Hook
;
use
app\service\ResourcesService
;
use
app\service\QuickNavService
;
use
app\service\PluginsService
;
/**
* 基础公共信息服务层
*
系统
基础公共信息服务层
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2020-09-12
* @desc description
*/
class
BaseService
class
System
BaseService
{
// 商品优惠使用记录key
public
static
$plugins_goods_discount_record_key
=
'plugins_use_goods_discount_record_'
;
/**
* 公共配置信息
* @author Devil
...
...
@@ -169,5 +173,160 @@ class BaseService
return
$value
;
}
/**
* 是否使用商品优化记录
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2021-04-09
* @desc description
* @param [int] $goods_id [商品id]
* @param [string] $plugins [插件名称]
*/
public
static
function
IsGoodsDiscountRecord
(
$goods_id
,
$plugins
)
{
// 获取记录
$data
=
self
::
GetGoodsDiscountRecord
(
$goods_id
);
// 当前插件是否存在优惠记录
return
in_array
(
$plugins
,
$data
);
}
/**
* 商品优化记录
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2021-04-09
* @desc description
* @param [int] $goods_id [商品id]
* @param [string] $plugins [插件名称]
* @param [int] $is_use [是否使用(0否, 1是)]
*/
public
static
function
GoodsDiscountRecord
(
$goods_id
,
$plugins
,
$is_use
=
0
)
{
// 记录key
$key
=
self
::
$plugins_goods_discount_record_key
.
$goods_id
;
// 获取记录
$data
=
self
::
GetGoodsDiscountRecord
(
$goods_id
);
// 是否存在
$index
=
array_search
(
$plugins
,
$data
);
// 是否使用优惠
if
(
$is_use
==
1
)
{
// 存储记录
if
(
$index
===
false
)
{
$data
[]
=
$plugins
;
}
session
(
$key
,
$data
);
}
else
{
if
(
$index
!==
false
)
{
unset
(
$data
[
$index
]);
sort
(
$data
);
}
}
session
(
$key
,
empty
(
$data
)
?
null
:
$data
);
return
true
;
}
/**
* 获取使用商品优化记录
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2021-04-09
* @desc description
* @param [int] $goods_id [商品id]
*/
public
static
function
GetGoodsDiscountRecord
(
$goods_id
)
{
$res
=
session
(
self
::
$plugins_goods_discount_record_key
.
$goods_id
);
return
empty
(
$res
)
?
[]
:
$res
;
}
/**
* 商品是否支持折扣
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2021-04-08
* @desc description
* @param [array] $params [输入参数]
* @param [string] $plugins [插件名称]
*/
public
static
function
IsGoodsDiscount
(
$params
=
[],
$plugins
=
''
)
{
// 默认支持
$status
=
true
;
// 是否关闭商品优惠重叠
// 采用钩子进行处理
if
(
MyC
(
'is_close_goods_discount_overlap'
,
0
)
==
1
&&
!
empty
(
$params
)
&&
!
empty
(
$params
[
'hook_name'
]))
{
switch
(
$params
[
'hook_name'
])
{
// 商品处理结束
case
'plugins_service_goods_handle_end'
:
if
(
!
empty
(
$params
[
'goods'
])
&&
!
empty
(
$params
[
'goods'
][
'id'
]))
{
$old
=
Db
::
name
(
'Goods'
)
->
field
(
'price,min_price,max_price'
)
->
find
(
$params
[
'goods'
][
'id'
]);
if
(
!
empty
(
$old
))
{
// 展示销售价格
if
(
$status
&&
isset
(
$params
[
'goods'
][
'price'
]))
{
$temp
=
explode
(
'-'
,
$params
[
'goods'
][
'price'
]);
$temp_old
=
explode
(
'-'
,
$old
[
'price'
]);
if
(
$temp
[
count
(
$temp
)
-
1
]
<
$temp_old
[
count
(
$temp_old
)
-
1
])
{
$status
=
false
;
}
}
// 最低价
if
(
$status
&&
isset
(
$params
[
'goods'
][
'min_price'
]))
{
if
(
$params
[
'goods'
][
'min_price'
]
<
$old
[
'min_price'
])
{
$status
=
false
;
}
}
// 最高价
if
(
$status
&&
isset
(
$params
[
'goods'
][
'max_price'
]))
{
if
(
$params
[
'goods'
][
'max_price'
]
<
$old
[
'max_price'
])
{
$status
=
false
;
}
}
}
}
break
;
// 获取规格详情
case
'plugins_service_goods_spec_base'
:
if
(
!
empty
(
$params
[
'data'
])
&&
!
empty
(
$params
[
'data'
][
'spec_base'
])
&&
!
empty
(
$params
[
'data'
][
'spec_base'
][
'id'
])
&&
!
empty
(
$params
[
'data'
][
'spec_base'
][
'goods_id'
])
&&
isset
(
$params
[
'data'
][
'spec_base'
][
'price'
]))
{
$price_old
=
Db
::
name
(
'GoodsSpecBase'
)
->
where
([
'id'
=>
$params
[
'data'
][
'spec_base'
][
'id'
]])
->
value
(
'price'
);
if
(
$status
&&
$params
[
'data'
][
'spec_base'
][
'price'
]
<
$price_old
)
{
$status
=
false
;
}
}
break
;
}
}
// 返回状态、默认支持
return
$status
;
}
}
?>
\ No newline at end of file
application/tags.php
浏览文件 @
82da920b
...
...
@@ -32,77 +32,5 @@ return array (
'log_write'
=>
array
(
),
'plugins_css'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_navigation_header_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_goods_handle_end'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_goods_spec_base'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_buy_group_goods_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_user_login_success_record'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_goods_spec_extends_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_view_admin_user_save'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_user_save_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_goods_save_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_view_goods_detail_panel_price_top'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_view_home_goods_inside_bottom'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_view_search_goods_inside_bottom'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_goods_spec_type'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_users_center_left_menu_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_header_navigation_top_right_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_module_form_admin_user_index'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_module_form_admin_user_detail'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
);
?>
\ No newline at end of file
changelog.txt
浏览文件 @
82da920b
...
...
@@ -3,19 +3,23 @@
+=========================================================+
全局
1. 公共图片上传重绘加开关
2. 搜索模块多个关键字[或|并且]关系的控制
2. 搜索多个关键字[或|并且]关系的控制
3. 新增商品优惠重叠开关控制
web端
1. 修复编辑器粘贴数据图片重复存储
2. 修复web端用户注册图片验证码过期问题
3. 修复微信小程序用户授权基础信息丢失问题
4. 新增多商户插件、支持用户入驻开店销售产品、商品/订单/结算/数据统计管理
4. 新增多商户插件、支持用户入驻开店销售产品、
独立首页、独立卖家中心、
商品/订单/结算/数据统计管理
小程序
1.
无更新
插件
1. 多商户
1. 新增多商户
2. 会员等级增强版(放开商品规格扩展的数据、支持多商户、适配优惠重叠)
3. 分销(放开商品规格扩展的数据、支持多商户、适配优惠重叠)
4. 限时秒杀(适配优惠重叠)
+=========================================================+
...
...
public/static/common/images/default-company-license.jpg
0 → 100644
浏览文件 @
82da920b
27.8 KB
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录