Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
occloud-server
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
yangjiarong
occloud-server
Commits
671fe0c3
Commit
671fe0c3
authored
Aug 01, 2022
by
liuliufashi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
166b631d
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
55 additions
and
24 deletions
+55
-24
index.vue
web-vue-admin/src/views/goods-cabinet/index.vue
+40
-17
index.vue
web-vue-admin/src/views/home/index.vue
+3
-3
index.vue
web-vue-admin/src/views/pay-bind/index.vue
+6
-1
index.vue
web-vue-admin/src/views/pay-list/index.vue
+6
-3
No files found.
web-vue-admin/src/views/goods-cabinet/index.vue
View file @
671fe0c3
...
...
@@ -71,17 +71,25 @@
:label-col=
"{ span: 2 }"
>
<div
class=
"clearfix"
>
<div
style=
"display: flex;"
>
<a-upload
v-model:file-list=
"fileList"
:maxCount=
"1"
action=
"http://43.142.42.187:8899/file/upload"
list-type=
"picture-card"
@
preview=
"handlePreview"
@
change=
"handleChange"
>
<div
v-if=
"fileList.length < 8"
>
<plus-outlined
/>
<div
style=
"margin-top: 8px"
>
Upload
</div>
<a-upload
v-model:file-list=
"fileList"
list-type=
"picture-card"
:show-upload-list=
"false"
action=
"http://43.142.42.187:8899/file/upload"
:before-upload=
"beforeUpload"
@
change=
"handleChange"
>
<img
v-if=
"imageUrl"
:src=
"imageUrl"
alt=
"avatar"
style=
"width: 102px;height: 102px;"
/>
<div
v-else
>
<loading-outlined
v-if=
"loading"
></loading-outlined>
<plus-outlined
v-else
></plus-outlined>
<div
class=
"ant-upload-text"
>
Upload
</div>
</div>
</a-upload>
</div>
<div>
<p
class=
"warin"
>
建议图片比例为4:3,大小不超过2
0
M,图片仅支持JPG、JPEG、PNG格式
建议图片比例为4:3,大小不超过2M,图片仅支持JPG、JPEG、PNG格式
</p>
</div>
</div>
...
...
@@ -95,7 +103,6 @@
style=
"font-size:28px;"
></i>
</div>
</a-upload>
</div>
<QuillEditor
style=
"height:200px"
ref=
"myQuillEditor"
:options=
"options"
:content=
"modelRef.body"
content-type=
"html"
@
update:content=
"textChange"
@
focus=
"onEditorFocus($event)"
@
blur=
"onEditorBlur($event)"
@
change=
"onEditorChange($event)"
>
...
...
@@ -105,7 +112,7 @@
<div
class=
"editor-text"
>
<p>
1、商品描述需符合《中华人民共和国广告法》
</p>
<p>
2、详情图片宽度750,高度不超过5000,每张图片最大不超过
1
M,图片仅支持JPG、JPEG、PNG格式。
2、详情图片宽度750,高度不超过5000,每张图片最大不超过
2
M,图片仅支持JPG、JPEG、PNG格式。
</p>
</div>
</a-form-item>
...
...
@@ -153,6 +160,8 @@ import GoodsBagSubs from "./components/goodsubs/index.vue";
const
useForm
=
Form
.
useForm
;
const
myQuillEditor
=
ref
<
any
>
(
null
);
const
imageUrl
=
ref
<
any
>
(
''
)
const
loading
=
ref
<
any
>
(
''
)
const
textarea
=
ref
<
any
>
(
''
)
let
upImage
=
ref
<
any
>
(
null
)
const
columns
=
[
...
...
@@ -272,7 +281,7 @@ const handleOk = async () => {
goods_package_id
:
modelRef
.
value
.
parent
,
subject
:
modelRef
.
value
.
subject
,
shortname
:
modelRef
.
value
.
shortname
,
picurl
:
fileList
.
value
[
0
].
url
,
picurl
:
imageUrl
.
value
,
body
:
modelRef
.
value
.
body
,
price
:
modelRef
.
value
.
price
*
100
,
markingprice
:
modelRef
.
value
.
markingprice
*
100
,
...
...
@@ -357,7 +366,7 @@ const onEdit = (e: any) => {
visible
.
value
=
!
visible
.
value
;
modelRef
.
value
.
parent
=
e
.
parent
modelRef
.
value
.
goodsid
=
e
.
goodsid
modelRef
.
value
.
picurl
=
e
.
picurl
imageUrl
.
value
=
e
.
picurl
modelRef
.
value
.
sellamount
=
e
.
sellamount
modelRef
.
value
.
sellcount
=
e
.
sellcount
modelRef
.
value
.
shortname
=
e
.
shortname
...
...
@@ -466,13 +475,9 @@ const handlePreview = async (file: any) => {
previewTitle
.
value
=
file
.
name
||
file
.
url
.
substring
(
file
.
url
.
lastIndexOf
(
"/"
)
+
1
);
};
const
beforeUpload
:
UploadProps
[
'beforeUpload'
]
=
file
=>
{
if
(
!
(
file
.
type
.
includes
(
'png'
)
||
file
.
type
.
includes
(
'jpeg'
)
||
file
.
type
.
includes
(
'jpg'
)))
{
message
.
error
(
`
${
file
.
name
}
不是png/jpef/jpg格式`
);
return
Upload
.
LIST_IGNORE
;
}
};
const
handleChange
=
(
info
:
any
)
=>
{
const
size
=
info
.
file
.
size
/
1024
if
(
size
<
2000
){
let
resFileList
=
[...
info
.
fileList
];
// 1. Limit the number of uploaded files
...
...
@@ -482,12 +487,28 @@ const handleChange = (info: any) => {
// 2. read from response and show file link
resFileList
=
resFileList
.
map
((
file
)
=>
{
if
(
file
.
response
)
{
console
.
log
(
fileList
,
'fileList'
);
// Component will show file.url as link
imageUrl
.
value
=
file
.
response
.
data
;
modelRef
.
value
.
picurl
=
imageUrl
.
value
}
return
file
;
});
fileList
.
value
=
resFileList
;
}
else
{
}
};
const
beforeUpload
:
UploadProps
[
'beforeUpload'
]
=
file
=>
{
const
size
=
file
.
size
/
1024
if
(
size
<
2000
){
if
(
!
(
file
.
type
.
includes
(
'png'
)
||
file
.
type
.
includes
(
'jpeg'
)
||
file
.
type
.
includes
(
'jpg'
)))
{
message
.
error
(
`
${
file
.
name
}
不是png/jpef/jpg格式`
);
return
Upload
.
LIST_IGNORE
;
}
}
else
{
message
.
info
(
'图片最大为2M'
)
}
};
watch
(
isEditfileList
,
(
newVal
,
old
)
=>
{
if
(
newVal
[
0
])
{
...
...
@@ -517,6 +538,8 @@ defineExpose({
textarea
,
upImage
,
pagination
,
imageUrl
,
loading
,
tableChange
,
onPush
,
textChange
,
...
...
web-vue-admin/src/views/home/index.vue
View file @
671fe0c3
...
...
@@ -3,7 +3,7 @@
<a-layout
class=
"home-page"
>
<a-layout-header
class=
"header"
>
<div
class=
"header-right"
>
<bell-outlined
/>
<bell-outlined
style=
"font-size: 18px;color: white;"
/>
</div>
<a-dropdown>
<template
#
overlay
>
...
...
@@ -15,11 +15,11 @@
</a-menu>
</
template
>
<div
class=
"header-right"
>
<RadarChartOutlined
/><span
>
{{ info.name }}
</span>
<RadarChartOutlined
style=
"font-size: 18px;color: white;"
/><span
style=
"font-size: 16px;color: white;"
>
{{ info.name }}
</span>
</div>
</a-dropdown>
<div
class=
"header-right"
>
<DashOutlined
/>
<DashOutlined
style=
"color: white;"
/>
</div>
</a-layout-header>
<a-layout>
...
...
web-vue-admin/src/views/pay-bind/index.vue
View file @
671fe0c3
...
...
@@ -233,12 +233,12 @@ const { resetFields, validate, validateInfos } = useForm(modelRef, rulesRef);
const
onSubmit
=
async
()
=>
{
validate
()
.
then
(
async
()
=>
{
const
uid
=
getUid
()
let
data
:
any
=
{};
if
(
status
.
value
===
1
)
{
let
prarms
:
any
=
{
}
if
(
query
.
value
.
paytype
==
"1"
){
prarms
=
{
amount
:
dataFrom
.
value
.
amount
,
id
:
dataFrom
.
value
.
id
,
...
...
@@ -249,6 +249,7 @@ const onSubmit = async () => {
mchid
:
toRaw
(
modelRef
).
privatekey
,
mchkey
:
toRaw
(
modelRef
).
alipaypublickey
,
...
toRaw
(
modelRef
),
uid
};
}
else
{
prarms
=
{
...
...
@@ -261,6 +262,7 @@ const onSubmit = async () => {
mchid
:
toRaw
(
modelRef
).
mchid
,
mchkey
:
toRaw
(
modelRef
).
mchkey
,
...
toRaw
(
modelRef
),
uid
};
}
...
...
@@ -291,6 +293,7 @@ const onSubmit = async () => {
mchid
:
toRaw
(
modelRef
).
privatekey
,
mchkey
:
toRaw
(
modelRef
).
alipaypublickey
,
...
toRaw
(
modelRef
),
uid
,
};
}
else
{
prarms
=
{
...
...
@@ -303,6 +306,7 @@ const onSubmit = async () => {
mchid
:
toRaw
(
modelRef
).
mchid
,
mchkey
:
toRaw
(
modelRef
).
mchkey
,
...
toRaw
(
modelRef
),
uid
,
};
}
if
(
query
.
value
.
paytype
==
1
)
{
...
...
@@ -317,6 +321,7 @@ const onSubmit = async () => {
message
.
warning
(
data
.
message
,
10
);
}
await
init
();
status
.
value
=
0
}
})
.
catch
((
err
)
=>
{
...
...
web-vue-admin/src/views/pay-list/index.vue
View file @
671fe0c3
...
...
@@ -177,7 +177,7 @@ const columns = [
width
:
100
,
},
{
title
:
'创
始
人'
,
title
:
'创
建
人'
,
dataIndex
:
'userid'
,
key
:
'userid'
,
},
...
...
@@ -233,6 +233,8 @@ const onGetSearch= async() => {
pagination
.
total
=
data
.
data
.
count
}
const
onEdit
=
(
e
:
any
)
=>
{
console
.
log
(
e
,
'e'
);
formState
.
value
=
{
...
e
}
...
...
@@ -241,7 +243,8 @@ const onEdit = (e: any) => {
value4
.
value
=
dayjs
(
moment
(
e
.
expireendtime
).
format
((
'YYYY-MM-DD'
)),
dateFormat
)
value5
.
value
=
dayjs
(
moment
(
e
.
expireendtime
).
format
((
'HH:mm'
)),
'HH:mm'
)
formState
.
value
.
payment
=
formState
.
value
.
payment
/
100
formState
.
value
.
paymentmodel
=
formState
.
value
.
paymentmodel
+
''
formState
.
value
.
paymentmodel
=
'1'
formState
.
value
.
fullphone
=
formState
.
value
.
fullphone
?
true
:
false
showModal
()
}
const
onSearch
=
async
()
=>
{
...
...
@@ -329,7 +332,7 @@ const onSelect =(e:any,opt:any)=>{
id
}
formState
.
value
.
price
=
formState
.
value
.
price
/
100
formState
.
value
.
paymentmodel
=
'
0
'
formState
.
value
.
paymentmodel
=
'
1
'
}
const
onSubSearch
=
async
(
value
:
any
)
=>
{
...
...
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