Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
A
admin-base
Project
Project
Details
Activity
Releases
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
new-sing
admin-base
Commits
44007863
Commit
44007863
authored
Nov 01, 2018
by
王
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
对外投放
parent
44fd0fbc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
34 deletions
+21
-34
index.vue
src/components/promotion/index.vue
+18
-31
api.js
src/service/api.js
+3
-3
No files found.
src/components/promotion/index.vue
View file @
44007863
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
<div
class=
"index"
>
<div
class=
"index"
>
<el-form
ref=
"searchFrom"
:model=
"searchFrom"
label-width=
"80px"
>
<el-form
ref=
"searchFrom"
:model=
"searchFrom"
label-width=
"80px"
>
<el-row>
<el-row>
<el-col
:
span=
"10
"
>
<el-col
:
lg=
"10"
:sm=
"24"
:md=
"24
"
>
<el-form-item
label=
"购买时间"
>
<el-form-item
label=
"购买时间"
>
<el-date-picker
<el-date-picker
v-model=
"searchFrom.time"
v-model=
"searchFrom.time"
...
@@ -17,13 +17,13 @@
...
@@ -17,13 +17,13 @@
</el-date-picker>
</el-date-picker>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
<el-col
:
span=
"4
"
>
<el-col
:
lg=
"4"
:sm=
"24"
:md=
"12
"
>
<el-form-item
label=
"来源"
>
<el-form-item
label=
"来源"
>
<el-input
v-model=
"searchFrom.source"
placeholder=
"名称"
<el-input
v-model=
"searchFrom.source"
placeholder=
"名称"
size=
"small"
></el-input>
size=
"small"
></el-input>
</el-form-item>
</el-form-item>
</el-col>
</el-col>
<el-col
:
span=
"4
"
>
<el-col
:
lg=
"4"
:sm=
"24"
:md=
"12
"
>
<el-form-item>
<el-form-item>
<el-button
type=
"primary"
plain
size=
"small"
@
click=
"initPage"
>
<el-button
type=
"primary"
plain
size=
"small"
@
click=
"initPage"
>
搜索
搜索
...
@@ -36,35 +36,26 @@
...
@@ -36,35 +36,26 @@
:data=
"tableData"
:data=
"tableData"
style=
"width: 100%"
>
style=
"width: 100%"
>
<el-table-column
<el-table-column
prop=
"id"
prop=
"user_name"
label=
"id"
>
</el-table-column>
<el-table-column
prop=
"nickname"
label=
"宝贝名称"
>
label=
"宝贝名称"
>
</el-table-column>
</el-table-column>
<el-table-column
<el-table-column
prop=
"宝贝年龄"
prop=
"create_at"
label=
"age"
>
label=
"添加时间"
>
</el-table-column>
<el-table-column
prop=
"address"
sortable
label=
"城市"
>
</el-table-column>
</el-table-column>
<el-table-column
<el-table-column
prop=
"source"
prop=
"source"
sortable
label=
"来源"
>
label=
"来源"
>
</el-table-column>
</el-table-column>
</el-table>
</el-table>
<page
:total=
"total"
:limit=
"limit"
@
pageChange=
"onPageChange"
/>
<page
:total=
"total"
:limit=
"limit"
@
pageChange=
"onPageChange"
@
sizeChange=
"onSizeChange"
/>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
page
from
'../framework/page'
import
page
from
'../framework/page'
import
CommonJs
from
'../../util/common'
;
import
CommonJs
from
'../../util/common'
;
import
{
getAdsListApi
}
from
"../../service/api"
;
export
default
{
export
default
{
name
:
"index"
,
name
:
"index"
,
components
:{
components
:{
...
@@ -97,26 +88,22 @@
...
@@ -97,26 +88,22 @@
json
.
source
=
this
.
searchFrom
.
source
json
.
source
=
this
.
searchFrom
.
source
}
}
if
(
this
.
searchFrom
.
time
&&
this
.
searchFrom
.
time
.
length
>
0
){
if
(
this
.
searchFrom
.
time
&&
this
.
searchFrom
.
time
.
length
>
0
){
json
.
pay_start_a
t
=
CommonJs
.
dateFmt
(
this
.
searchFrom
.
time
[
0
],
"yyyy-MM-dd hh:mm:ss"
);
json
.
date_star
t
=
CommonJs
.
dateFmt
(
this
.
searchFrom
.
time
[
0
],
"yyyy-MM-dd hh:mm:ss"
);
json
.
pay_end_at
=
CommonJs
.
dateFmt
(
this
.
searchFrom
.
time
[
1
],
"yyyy-MM-dd hh:mm:ss"
)
json
.
date_end
=
CommonJs
.
dateFmt
(
this
.
searchFrom
.
time
[
1
],
"yyyy-MM-dd hh:mm:ss"
)
}
}
this
.
tableData
=
[
getAdsListApi
(
json
).
then
((
res
)
=>
{
{
this
.
tableData
=
res
.
list
;
id
:
1
,
this
.
total
=
res
.
total
nickname
:
'xiaoming'
,
})
age
:
'3'
,
mobile
:
17326578909
,
address
:
'上海'
,
source
:
'fff_123'
}
]
},
},
onPageChange
(
val
){
onPageChange
(
val
){
this
.
nowPage
=
val
this
.
nowPage
=
val
this
.
initPage
()
this
.
initPage
()
},
},
changeShow
()
{
onSizeChange
(
val
){
this
.
nowPage
=
1
this
.
limit
=
val
this
.
initPage
()
}
}
}
}
}
}
...
...
src/service/api.js
View file @
44007863
...
@@ -580,7 +580,7 @@ export const updateQrCodeApi = function (id, json) {
...
@@ -580,7 +580,7 @@ export const updateQrCodeApi = function (id, json) {
return
Vue
.
prototype
.
$put
(
`
${
updateQrCodeUrl
}
/
${
id
}
`
,
json
)
return
Vue
.
prototype
.
$put
(
`
${
updateQrCodeUrl
}
/
${
id
}
`
,
json
)
};
};
// 获取二维码列表详情
// 获取二维码列表详情
const
get
QrCodeDetailUrl
=
'api/admin/wechat/qrcode
'
;
const
get
AdsListlUrl
=
'api/public/ads/list
'
;
export
const
get
QrCodeDetailUrlApi
=
function
(
id
)
{
export
const
get
AdsListApi
=
function
(
json
)
{
return
Vue
.
prototype
.
$fetch
(
`
${
getQrCodeDetailUrl
}
/
${
id
}
`
)
return
Vue
.
prototype
.
$fetch
(
getAdsListlUrl
,
json
)
};
};
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