Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
jamesyang1999
ShopXO
提交
0fe424b2
ShopXO
项目概览
jamesyang1999
/
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,发现更多精彩内容 >>
提交
0fe424b2
编写于
10月 05, 2019
作者:
D
Devil
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
api附件
上级
97af3f47
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
118 addition
and
27 deletion
+118
-27
application/api/controller/Ueditor.php
application/api/controller/Ueditor.php
+22
-19
public/appmini/old/weixin/app.js
public/appmini/old/weixin/app.js
+1
-1
public/appmini/old/weixin/app.json
public/appmini/old/weixin/app.json
+3
-3
public/appmini/old/weixin/app.wxss
public/appmini/old/weixin/app.wxss
+25
-2
public/appmini/old/weixin/images/default-upload-icon.png
public/appmini/old/weixin/images/default-upload-icon.png
+0
-0
public/appmini/old/weixin/pages/user-orderaftersale-detail/user-orderaftersale-detail.js
.../user-orderaftersale-detail/user-orderaftersale-detail.js
+53
-0
public/appmini/old/weixin/pages/user-orderaftersale-detail/user-orderaftersale-detail.wxml
...ser-orderaftersale-detail/user-orderaftersale-detail.wxml
+14
-2
未找到文件。
application/api/controller/Ueditor.php
浏览文件 @
0fe424b2
...
...
@@ -11,6 +11,7 @@
namespace
app\api\controller
;
use
app\service\UeditorService
;
use
app\service\ResourcesService
;
/**
* 附件上传
...
...
@@ -21,21 +22,18 @@ use app\service\UeditorService;
*/
class
Ueditor
extends
Common
{
/**
* 构造方法
* @author Devil
* @blog http://gong.gg/
* @version 0.0.1
* @datetime 2016-12-03T12:39:08+0800
*/
public
function
__construct
()
{
// 调用父类前置方法
parent
::
__construct
();
// 是否登录
$this
->
IsLogin
();
}
/**
* 构造方法
* @author Devil
* @blog http://gong.gg/
* @version 0.0.1
* @datetime 2016-12-03T12:39:08+0800
*/
public
function
__construct
()
{
// 调用父类前置方法
parent
::
__construct
();
}
/**
* 运行入口
...
...
@@ -45,9 +43,14 @@ class Ueditor extends Common
* @date 2019-08-06
* @desc description
*/
public
function
Index
()
{
return
DataReturn
(
'api附件上传接口开发中'
,
0
);
}
public
function
Index
()
{
$ret
=
UeditorService
::
Run
(
$this
->
data_post
);
if
(
$ret
[
'code'
]
==
0
&&
!
empty
(
$ret
[
'data'
][
'url'
]))
{
$ret
[
'data'
][
'url'
]
=
ResourcesService
::
AttachmentPathViewHandle
(
$ret
[
'data'
][
'url'
]);
}
return
$ret
;
}
}
?>
\ No newline at end of file
public/appmini/old/weixin/app.js
浏览文件 @
0fe424b2
...
...
@@ -64,7 +64,7 @@ App({
// 请求地址
request_url
:
"
{{request_url}}
"
,
request_url
:
'
http://tp5-dev.com/
'
,
request_url
:
'
https://test.shopxo.net/
'
,
//
request_url: 'https://test.shopxo.net/',
// 基础信息
application_title
:
"
{{application_title}}
"
,
...
...
public/appmini/old/weixin/app.json
浏览文件 @
0fe424b2
{
"pages"
:
[
"pages/user
/user
"
,
"pages/user-order/user-order"
,
"pages/user-orderaftersale-detail/user-orderaftersale-detail"
,
"pages"
:
[
"pages/user
-orderaftersale-detail/user-orderaftersale-detail
"
,
"pages/user-order/user-order"
,
"pages/user/user"
,
"pages/index/index"
,
"pages/goods-category/goods-category"
,
"pages/cart/cart"
,
...
...
public/appmini/old/weixin/app.wxss
浏览文件 @
0fe424b2
...
...
@@ -361,11 +361,34 @@ button[disabled].bg-primary {
.form-gorup picker view.picker {
border-bottom: 1px solid #eee;
border-radius: 0;
width: 100%;
padding: 0 10rpx;
}
.form-gorup input,
.form-gorup picker view.picker {
height: 70rpx;
line-height: 70rpx;
padding: 0 10rpx;
}
.form-gorup textarea {
padding:
17rpx 10rpx
;
padding:
0
;
min-height: 70rpx;
}
/**
* 表单图片上传
*/
.form-container-upload .form-upload-data .item {
padding: 10rpx;
}
.form-container-upload .form-upload-data image {
width: 200rpx;
height: 200rpx;
padding: 5rpx;
border: 1px solid #eee;
}
.form-container-upload .upload-icon {
margin: 10rpx 0 0 10rpx;
width: 210rpx;
height: 210rpx;
border: 1px dashed #eee;
}
\ No newline at end of file
public/appmini/old/weixin/images/default-upload-icon.png
0 → 100644
浏览文件 @
0fe424b2
822 字节
public/appmini/old/weixin/pages/user-orderaftersale-detail/user-orderaftersale-detail.js
浏览文件 @
0fe424b2
...
...
@@ -20,6 +20,7 @@ Page({
form_price
:
''
,
form_msg
:
''
,
form_number
:
0
,
form_images_list
:
[],
},
onLoad
(
params
)
{
...
...
@@ -129,6 +130,58 @@ Page({
});
},
// 文件上传
file_upload_event
(
e
)
{
var
self
=
this
;
wx
.
chooseImage
({
count
:
3
,
success
(
res
)
{
var
success
=
0
;
var
fail
=
0
;
var
length
=
res
.
tempFilePaths
.
length
;
var
count
=
0
;
self
.
upload_one_by_one
(
res
.
tempFilePaths
,
success
,
fail
,
count
,
length
);
}
});
},
// 采用递归的方式上传多张
upload_one_by_one
(
img_paths
,
success
,
fail
,
count
,
length
)
{
var
self
=
this
;
if
(
self
.
data
.
form_images_list
.
length
<
3
)
{
wx
.
uploadFile
({
url
:
app
.
get_request_url
(
"
index
"
,
"
ueditor
"
),
filePath
:
img_paths
[
count
],
name
:
'
upfile
'
,
formData
:
{
action
:
'
uploadimage
'
,
},
success
:
function
(
res
)
{
success
++
;
if
(
res
.
statusCode
==
200
)
{
var
data
=
(
typeof
(
res
.
data
)
==
'
object
'
)
?
res
.
data
:
JSON
.
parse
(
res
.
data
);
var
list
=
self
.
data
.
form_images_list
;
list
.
push
(
data
.
data
.
url
);
self
.
setData
({
form_images_list
:
list
});
}
},
fail
:
function
(
e
)
{
fail
++
;
},
complete
:
function
(
e
)
{
count
++
;
// 下一张
if
(
count
>=
length
)
{
// 上传完毕,作一下提示
//app.showToast('上传成功' + success +'张', 'success');
}
else
{
// 递归调用,上传下一张
self
.
upload_one_by_one
(
img_paths
,
success
,
fail
,
count
,
length
);
}
}
});
}
},
// 下拉刷新
onPullDownRefresh
()
{
this
.
init
();
...
...
public/appmini/old/weixin/pages/user-orderaftersale-detail/user-orderaftersale-detail.wxml
浏览文件 @
0fe424b2
...
...
@@ -37,7 +37,7 @@
<view class="form-gorup-title">退款原因<text class="form-group-tips-must">必选</text></view>
<picker bindchange="form_reason_event" value="{{form_reason_index}}" range="{{reason_data_list}}">
<view class="picker {{form_reason_index == -1 ? 'cr-ccc' : 'cr-666'}} arrow-right">
{{form_reason_index == -1 ? '请选择原因
...
' : reason_data_list[form_reason_index]}}
{{form_reason_index == -1 ? '请选择原因' : reason_data_list[form_reason_index]}}
</view>
</picker>
</view>
...
...
@@ -54,11 +54,23 @@
<view class="form-gorup">
<view class="form-gorup-title">退款说明<text class="form-group-tips-must">必填</text></view>
<textarea bindinput="form_msg_event" placeholder-class="cr-ccc" class="cr-666" placeholder="退款说明 5~200 个字符之间" maxlength="200"
fixed="{{true}}"
auto-height="{{true}}" value="{{form_msg}}" />
<textarea bindinput="form_msg_event" placeholder-class="cr-ccc" class="cr-666" placeholder="退款说明 5~200 个字符之间" maxlength="200" auto-height="{{true}}" value="{{form_msg}}" />
</view>
<view class="form-gorup form-container-upload">
<view class="form-gorup-title">退款说明<text class="form-group-tips-must">必填</text></view>
<view class="form-upload-data fl">
<block wx:for="{{form_images_list}}" wx:key="item">
<view class="item fl">
<image src="{{item}}" mode="aspectFill" />
</view>
</block>
</view>
<image class="upload-icon" src="/images/default-upload-icon.png" mode="aspectFill" bindtap="file_upload_event" />
</view>
</view>
<import src="/pages/common/bottom_line.wxml" />
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录