luochenyi 3 years ago
parent a711dccad7
commit 656666aab8

@ -21,7 +21,7 @@
>{{ option.name }}</a-select-option
>
</a-select>
<a-range-picker v-else-if="item.type === 'time'" v-model="form[item.prop]" value-format="YYYY/MM/DD HH:mm:ss" @change="changeTime($event,item.start,item.end)" />
<a-range-picker v-else-if="item.type === 'time'" v-model="form[item.prop]" value-format="YYYY/MM/DD HH:mm:ss" />
</a-form-model-item>
</a-form-model>
<div class="btn-box"><a-button type="primary" @click="getSearch"> </a-button>
@ -62,18 +62,17 @@ export default {
},
methods: {
getSearch() {
console.log(this.form);
this.$emit('getSearch', this.form)
},
resetForm() {
this.$refs.ruleForm.resetFields();
this.$emit('getSearch', this.form)
this.$emit('getSearch', this.form,'clear')
},
changeTime(data,start,end){
this.$emit('changeTime', data,start,end)
this.form[start] = data[0]
this.form[end] = data[1]
}
// changeTime(data,start,end){
// this.$emit('changeTime', data,start,end)
// this.form[start] = data[0]
// this.form[end] = data[1]
// }
},
};
</script>

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">活动管理</div>
<searchForm :formItem="formItem" @getSearch="getData($event)" @changeTime='changeTime'></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增活动</a-button
>
@ -39,7 +39,8 @@
</span>
<span slot="switch" slot-scope="switchV, row">
<a-switch
checked-children="开" un-checked-children="关"
checked-children="开"
un-checked-children="关"
:checked="switchV === 1"
@change="handleEnable(row)"
></a-switch>
@ -64,7 +65,11 @@
@addClose="addClose"
:editId="editId"
></addForm>
<detailForm :detailId="detailId" :show="drawer.detail" @detailClose="detailClose"></detailForm>
<detailForm
:detailId="detailId"
:show="drawer.detail"
@detailClose="detailClose"
></detailForm>
</div>
</template>
@ -76,16 +81,16 @@ import detailForm from "./depend/detail.vue";
export default {
components: {
addForm,
detailForm
detailForm,
},
data() {
return {
drawer: {
show: false,
detail:false
detail: false,
},
editId: null,
detailId:null,
detailId: null,
tableData: [],
searchForm: {
activityAddress: undefined,
@ -110,27 +115,53 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
search(data,type) {
if(type ==='clear'){
this.searchForm = {
activityAddress: undefined,
organizerName: undefined,
activityContact: undefined,
activityTel: undefined,
title: undefined,
status: undefined,
registrationStartTime: undefined,
registrationEndTime: undefined,
activityStartTime: undefined,
activityEndTime: undefined,
}
}else{
let obj = {}
for(let k in data) {
if(Array.isArray(data[k])) {
console.log(data[k]);
let start = k + 'StartTime'
obj[start] = data[k][0]
let end = k + 'EndTime'
obj[end] = data[k][1]
}else{
obj[k] = data[k]
}
}
console.log(obj);
this.searchForm = obj;
}
this.getData()
},
async getData() {
let res = await activityList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
...this.searchForm
...this.searchForm,
});
this.tableData = res.data.rows;
this.pagination.total = res.data.total;
this.selectedRowKeys=[]
},
changeTime(data,start,end){
console.log(start);
this.searchForm[start] = data[0]
this.searchForm[end] = data[1]
console.log(this.searchForm);
this.selectedRowKeys = [];
},
// changeTime(data,start,end){
// this.searchForm[start] = data[0]
// this.searchForm[end] = data[1]
// console.log(this.searchForm);
// },
edit(id) {
this.editId = id;
this.drawer.show = true;
@ -177,14 +208,14 @@ export default {
success() {
this.getData();
},
detail(id){
detail(id) {
this.drawer.detail = true;
this.detailId = id;
},
detailClose(){
detailClose() {
this.detailId = null;
this.drawer.detail = false;
}
},
},
computed: {
hasSelected() {

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">活动主办方</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增主办方</a-button
>
@ -85,12 +85,11 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await organizerList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">公告</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增公告</a-button
>
@ -83,12 +83,11 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await announcementList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">社区话题</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增话题</a-button
>
@ -99,12 +99,7 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await topicList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -113,6 +108,10 @@ export default {
this.tableData = res.data.rows;
this.pagination.total = res.data.total;
},
search(data){
this.searchForm = data;
this.getData()
},
edit(id) {
this.editId = id;
this.drawer.show = true;

@ -3,7 +3,7 @@
<div class="cardTitle">巡检记录</div>
<searchForm
:formItem="formItem"
@getSearch="getData($event)"
@getSearch="search($event)"
></searchForm>
<a-table
:columns="columns"
@ -54,12 +54,11 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await inspectionExecute({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">巡检计划</div>
<searchForm :formItem="formItem" @getSearch="getData($event)" @changeTime='changeTime'></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)" @changeTime='changeTime'></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增计划</a-button
>
@ -93,12 +93,7 @@ export default {
let res = await routeSelect()
this.formItem[3].option = res.data
},
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await planList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -108,6 +103,10 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys = []
},
search(data){
this.searchForm = data;
this.getData()
},
changeTime(data, start, end) {
console.log(start);
this.searchForm[start] = data[0];

@ -3,8 +3,7 @@
<div class="cardTitle">巡检点</div>
<searchForm
:formItem="formItem"
@getSearch="getData($event)"
@changeTime="changeTime"
@getSearch="search($event)"
></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增巡更点</a-button
@ -100,12 +99,7 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await pointList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -115,11 +109,9 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys = [];
},
changeTime(data, start, end) {
console.log(start);
this.searchForm[start] = data[0];
this.searchForm[end] = data[1];
console.log(this.searchForm);
search(data){
this.searchForm = data;
this.getData()
},
edit(id) {
this.editId = id;

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">巡检路线</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增路线</a-button
>
@ -81,12 +81,7 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await routeList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -96,6 +91,10 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys = []
},
search(data){
this.searchForm = data;
this.getData()
},
edit(id) {
this.editId = id;
this.drawer.show = true;

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">资讯分类</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增分类</a-button
>
@ -82,12 +82,7 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await newsItemList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -97,6 +92,10 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys=[]
},
search(data){
this.searchForm = data;
this.getData()
},
edit(data) {
this.editData = data;
this.drawer.show = true;

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">资讯管理</div>
<searchForm :formItem="formItem" @getSearch="getData($event)" @changeTime='changeTime'></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)" @changeTime='changeTime'></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增资讯</a-button
>
@ -95,12 +95,7 @@ export default {
this.getItem();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await newsList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -110,6 +105,10 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys=[]
},
search(data){
this.searchForm = data;
this.getData()
},
async getItem(){
let res = await itemSelect()
this.formItem[0].option = res.data

@ -71,7 +71,7 @@
<div class="drawer-content">
<searchForm
:formItem="formItem"
@getSearch="getData($event)"
@getSearch="search($event)"
></searchForm>
<a-table
:columns="tableColumns"
@ -152,12 +152,7 @@ export default {
this.treeData = res.data;
deleteIds(this.treeData);
},
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await chargesList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -167,6 +162,10 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys = [];
},
search(data){
this.searchForm = data;
this.getData()
},
addBind() {
if (this.estateIds.length === 0) {
this.$message.error("请选择房屋");

@ -7,7 +7,7 @@
<a-tab-pane :key="3" tab="车位收费标准"> </a-tab-pane>
<a-tab-pane :key="4" tab="临时收费标准"> </a-tab-pane>
</a-tabs>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true">添加费用</a-button>
<a-table
:columns="columns"
@ -81,12 +81,7 @@ export default {
changeType(data){
this.getData()
},
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
async getData() {
let res = await chargesList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -96,6 +91,10 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys = [];
},
search(data){
this.searchForm = data;
this.getData()
},
edit(id) {
this.drawer = {
editId:id,

@ -12,7 +12,7 @@
<a-divider></a-divider>
<searchForm
:formItem="formItem"
@getSearch="getData($event)"
@getSearch="search($event)"
></searchForm>
<a-table
:columns="columns"
@ -66,10 +66,7 @@ export default {
};
},
methods: {
async getData(data) {
if (data !== undefined) {
this.searchForm = data;
}
async getData() {
let res = await rechargeList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,
@ -79,6 +76,10 @@ export default {
this.pagination.total = res.data.total;
this.selectedRowKeys = [];
},
search(data){
this.searchForm = data;
this.getData()
},
selectionChoosed() {},
close(){
this.$emit('close');

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">预缴管理</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-table
:columns="columns"
:data-source="tableData"
@ -109,10 +109,11 @@ export default {
let res = await allBuilding();
this.formItem[2].option = res.data;
},
async getData(data) {
if (data !== undefined) {
this.searchForm = data;
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await prepaymentList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">品牌管理</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增品牌</a-button
>
@ -108,12 +108,11 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await brandList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

@ -3,7 +3,7 @@
<div class="cardTitle">
<span>商品管理</span>
</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-table
:columns="columns"
:data-source="tableData"
@ -83,12 +83,7 @@ export default {
this.getData();
},
methods: {
getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
getData() {
shopPushList({
...this.searchForm,
pageNum: this.pagination.current,
@ -98,6 +93,10 @@ export default {
this.pagination.total = res.data.total;
});
},
search(data){
this.searchForm = data;
this.getData()
},
selectionChoosed(data) {
console.log(data);
this.selectedRowKeys = data;

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">jcook商品库</div>
<searchForm :formItem="formItem" @getSearch="getData($event)" ></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)" ></searchForm>
<a-table
:columns="columns"
:data-source="tableData"
@ -87,12 +87,11 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await jcookGoodsList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">店铺管理</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增店铺</a-button
>
@ -108,12 +108,11 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await shopList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

@ -1,7 +1,7 @@
<template>
<div>
<div class="cardTitle">供应商管理</div>
<searchForm :formItem="formItem" @getSearch="getData($event)"></searchForm>
<searchForm :formItem="formItem" @getSearch="search($event)"></searchForm>
<a-button style="margin: 10px" class="add-btn" @click="drawer.show = true"
>新增供应商</a-button
>
@ -108,12 +108,11 @@ export default {
this.getData();
},
methods: {
async getData(data) {
if (data !== undefined) {
console.log(data);
this.searchForm = data;
console.log(this.searchForm);
}
search(data){
this.searchForm = data;
this.getData()
},
async getData() {
let res = await vendorList({
pageNum: this.pagination.current,
size: this.pagination.pageSize,

Loading…
Cancel
Save