Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
jcy2004x
ShopXO
提交
df516781
ShopXO
项目概览
jcy2004x
/
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,发现更多精彩内容 >>
提交
df516781
编写于
7月 06, 2021
作者:
D
Devil
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
微信小程序支持页面可视化拖拽
上级
d7a98927
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
347 addition
and
3 deletion
+347
-3
application/api/controller/Design.php
application/api/controller/Design.php
+74
-0
sourcecode/weixin/default/app.js
sourcecode/weixin/default/app.js
+1
-1
sourcecode/weixin/default/app.json
sourcecode/weixin/default/app.json
+1
-0
sourcecode/weixin/default/pages/design/design.js
sourcecode/weixin/default/pages/design/design.js
+95
-0
sourcecode/weixin/default/pages/design/design.json
sourcecode/weixin/default/pages/design/design.json
+6
-0
sourcecode/weixin/default/pages/design/design.wxml
sourcecode/weixin/default/pages/design/design.wxml
+14
-0
sourcecode/weixin/default/pages/design/design.wxss
sourcecode/weixin/default/pages/design/design.wxss
+155
-0
sourcecode/weixin/default/pages/plugins/shop/design/design.js
...cecode/weixin/default/pages/plugins/shop/design/design.js
+1
-2
未找到文件。
application/api/controller/Design.php
0 → 100644
浏览文件 @
df516781
<?php
// +----------------------------------------------------------------------
// | ShopXO 国内领先企业级B2C免费开源电商系统
// +----------------------------------------------------------------------
// | Copyright (c) 2011~2099 http://shopxo.net All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( https://opensource.org/licenses/mit-license.php )
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
namespace
app\api\controller
;
use
app\service\DesignService
;
use
app\service\SystemBaseService
;
use
app\layout\service\BaseLayout
;
/**
* 页面设计
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2020-09-10
* @desc description
*/
class
Design
extends
Common
{
/**
* 首页
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2020-09-10
* @desc description
*/
public
function
Index
()
{
$data
=
[];
$layout_data
=
[];
if
(
!
empty
(
$this
->
data_request
[
'id'
]))
{
$data_params
=
[
'where'
=>
[
'id'
=>
intval
(
$this
->
data_request
[
'id'
]),
],
'm'
=>
0
,
'n'
=>
1
,
];
$ret
=
DesignService
::
DesignList
(
$data_params
);
if
(
$ret
[
'code'
]
==
0
&&
!
empty
(
$ret
[
'data'
])
&&
!
empty
(
$ret
[
'data'
][
0
]))
{
$data
=
$ret
[
'data'
][
0
];
}
}
if
(
!
empty
(
$data
))
{
// 访问统计
DesignService
::
DesignAccessCountInc
([
'design_id'
=>
$data
[
'id'
]]);
// 配置处理
$layout_data
=
BaseLayout
::
ConfigHandle
(
$data
[
'config'
]);
// 去除布局配置数据、避免很多配置数据造成带宽浪费
unset
(
$data
[
'config'
]);
}
// 返回数据
$result
=
[
'data'
=>
$data
,
'layout_data'
=>
$layout_data
,
];
return
SystemBaseService
::
DataReturn
(
$result
);
}
}
?>
\ No newline at end of file
sourcecode/weixin/default/app.js
浏览文件 @
df516781
...
...
@@ -74,7 +74,7 @@ App({
// 请求地址
request_url
:
"
{{request_url}}
"
,
request_url
:
'
http://shopxo.com/
'
,
request_url
:
'
https://dev.shopxo.net/
'
,
//
request_url: 'https://dev.shopxo.net/',
// 基础信息
application_title
:
"
{{application_title}}
"
,
...
...
sourcecode/weixin/default/app.json
浏览文件 @
df516781
...
...
@@ -27,6 +27,7 @@
"pages/user-orderaftersale-detail/user-orderaftersale-detail"
,
"pages/extraction-address/extraction-address"
,
"pages/common/open-setting-location/open-setting-location"
,
"pages/design/design"
,
"pages/plugins/coupon/index/index"
,
"pages/plugins/coupon/user/user"
,
"pages/plugins/membershiplevelvip/index/index"
,
...
...
sourcecode/weixin/default/pages/design/design.js
0 → 100644
浏览文件 @
df516781
const
app
=
getApp
();
Page
({
data
:
{
data_bottom_line_status
:
false
,
data_list_loding_status
:
1
,
data_list_loding_msg
:
''
,
params
:
null
,
data
:
null
,
layout_data
:
[]
},
onLoad
(
params
)
{
params
[
'
id
'
]
=
1
;
this
.
setData
({
params
:
params
,
});
},
onShow
()
{
this
.
get_data
();
// 显示分享菜单
app
.
show_share_menu
();
},
// 获取数据
get_data
()
{
var
self
=
this
;
wx
.
request
({
url
:
app
.
get_request_url
(
"
index
"
,
"
design
"
),
method
:
"
POST
"
,
data
:
{
"
id
"
:
this
.
data
.
params
.
id
||
0
},
dataType
:
"
json
"
,
success
:
res
=>
{
wx
.
stopPullDownRefresh
();
if
(
res
.
data
.
code
==
0
)
{
var
data
=
res
.
data
.
data
;
self
.
setData
({
data
:
data
.
data
||
null
,
layout_data
:
data
.
layout_data
||
[],
data_list_loding_msg
:
''
,
data_list_loding_status
:
0
,
data_bottom_line_status
:
true
,
});
// 标题名称
if
((
this
.
data
.
data
||
null
)
!=
null
)
{
wx
.
setNavigationBarTitle
({
title
:
this
.
data
.
data
.
name
});
}
}
else
{
self
.
setData
({
data_bottom_line_status
:
false
,
data_list_loding_status
:
2
,
data_list_loding_msg
:
res
.
data
.
msg
,
});
}
},
fail
:
()
=>
{
wx
.
stopPullDownRefresh
();
self
.
setData
({
data_bottom_line_status
:
false
,
data_list_loding_status
:
2
,
data_list_loding_msg
:
'
服务器请求出错
'
,
});
app
.
showToast
(
"
服务器请求出错
"
);
}
});
},
// 下拉刷新
onPullDownRefresh
()
{
this
.
get_data
();
},
// 自定义分享
onShareAppMessage
()
{
var
user_id
=
app
.
get_user_cache_info
(
'
id
'
,
0
)
||
0
;
return
{
title
:
this
.
data
.
data
.
name
||
this
.
data
.
data
.
seo_title
||
app
.
data
.
application_title
,
desc
:
this
.
data
.
data
.
seo_desc
||
app
.
data
.
application_describe
,
path
:
'
/pages/design/design?id=
'
+
this
.
data
.
data
.
id
+
'
&referrer=
'
+
user_id
};
},
// 分享朋友圈
onShareTimeline
()
{
var
user_id
=
app
.
get_user_cache_info
(
'
id
'
,
0
)
||
0
;
return
{
title
:
this
.
data
.
data
.
name
||
this
.
data
.
data
.
seo_title
||
app
.
data
.
application_title
,
query
:
'
id=
'
+
this
.
data
.
data
.
id
+
'
&referrer=
'
+
user_id
,
imageUrl
:
this
.
data
.
data
.
logo
||
''
};
},
});
\ No newline at end of file
sourcecode/weixin/default/pages/design/design.json
0 → 100644
浏览文件 @
df516781
{
"enablePullDownRefresh"
:
true
,
"usingComponents"
:
{
"component-layout"
:
"/components/layout/layout"
}
}
\ No newline at end of file
sourcecode/weixin/default/pages/design/design.wxml
0 → 100644
浏览文件 @
df516781
<view wx:if="{{(data || null) != null}}">
<!-- 拖拽模式、引入拖拽数据模块 -->
<component-layout prop-data="{{layout_data}}"></component-layout>
<!-- 结尾 -->
<block wx:if="{{(data.is_footer || 0) == 1}}">
<import src="/pages/common/bottom_line.wxml" />
<template is="bottom_line" data="{{status: data_bottom_line_status}}"></template>
</block>
</view>
<view wx:else>
<import src="/pages/common/nodata.wxml" />
<template is="nodata" data="{{status: data_list_loding_status, msg: data_list_loding_msg}}"></template>
</view>
\ No newline at end of file
sourcecode/weixin/default/pages/design/design.wxss
0 → 100644
浏览文件 @
df516781
/**
* 搜索
*/
.search {
background: #d2364c;
padding: 20rpx 10rpx 25rpx 20rpx;
position: relative;
}
.search input {
width: calc(100% - 328rpx);
padding-left: 15rpx;
font-size: 24rpx;
border-top-right-radius: 0;
border-bottom-right-radius: 0;
}
.search input,.search-btn button {
height: 52rpx;
line-height: 52rpx;
border-radius: 6rpx;
}
.search-btn {
position: absolute;
top: 20rpx;
right: 20rpx;
}
.search-btn button {
color: #fff;
width: 150rpx;
font-size: 24rpx;
}
.search-btn button:first-child {
background: #ff8c00;
border: 1px solid #ff8c00;
border-top-left-radius: 0;
border-bottom-left-radius: 0;
}
.search-btn button:last-child {
background: #483E39;
border: 1px solid #483E39;
margin-left: 10rpx;
}
/**
* 头部
*/
.header {
padding: 20rpx 10rpx;
}
.shop-logo {
width: 280rpx;
margin-top: 5rpx;
}
.base-bottom image {
width: 28rpx;
height: 28rpx;
margin-right: 5rpx;
}
.header .base {
width: calc(100% - 320rpx);
}
.shop-title {
font-size: 32rpx;
font-weight: bold;
line-height: 40rpx;
}
.shop-auth-icon {
background-color: #f4c985;
border: 1px solid #e7ba77;
border-radius: 6rpx;
color: #856651;
text-align: center;
padding: 2rpx 12rpx;
font-size: 24rpx;
font-weight: bold;
margin-right: 10rpx;
}
/**
* 客服
*/
.header-service {
width: 390rpx;
position: absolute;
left: 80rpx;
top: 210rpx;
z-index: 2;
font-size: 24rpx;
-webkit-box-shadow: 0 10px 10px rgb(0 0 0 / 30%);
box-shadow: 0 10px 10px rgb(0 0 0 / 30%);
}
.header-service image {
width: 260rpx;
height: 260rpx;
}
.header-service .item {
padding: 20rpx;
}
/**
* 滚动
*/
.nav-roll {
width: 100%;
white-space: nowrap;
box-sizing: border-box;
}
.nav-roll .item {
display: inline-block;
}
/**
* 导航
*/
.nav {
height: 70rpx;
border-bottom: 1px solid #d2364c;
}
.nav .nav-scroll {
float: right;
width: calc(100% - 230rpx);
}
.nav .item {
padding: 0 20rpx;
font-weight: bold;
}
.nav-shop-category {
padding-right: 38rpx !important;
background-size: 14px 14px;
}
/**
* 导航商品分类
*/
.nav-category {
background: #d2364c;
width: 220rpx;
z-index: 1;
position: absolute;
margin-top: 50rpx;
border: 1px solid #d2364c;
-webkit-box-shadow: 0 10px 10px rgb(0 0 0 / 30%);
box-shadow: 0 10px 10px rgb(0 0 0 / 30%);
}
.nav-category .category-scroll {
max-height: 600rpx;
}
.nav-category .item {
padding: 15rpx 20rpx;
display: block;
font-weight: inherit;
color: #f1f1f1;
}
.nav-category .item:not(:last-child) {
border-bottom: 1px solid #c72e44;
}
\ No newline at end of file
sourcecode/weixin/default/pages/plugins/shop/design/design.js
浏览文件 @
df516781
...
...
@@ -27,7 +27,6 @@ Page({
},
onLoad
(
params
)
{
params
[
'
id
'
]
=
1
;
this
.
setData
({
params
:
params
,
user
:
app
.
get_user_cache_info
(),
...
...
@@ -207,7 +206,7 @@ Page({
return
{
title
:
this
.
data
.
data
.
name
||
this
.
data
.
data
.
seo_title
||
app
.
data
.
application_title
,
query
:
'
id=
'
+
this
.
data
.
data
.
id
+
'
&referrer=
'
+
user_id
,
imageUrl
:
''
imageUrl
:
this
.
data
.
data
.
logo
||
''
};
},
});
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录