Commit 3d4c003b by lichengming

修改了统计分析搜索按钮

parent dace1969
......@@ -26,7 +26,7 @@
</el-date-picker>
</Form-item>
<Form-item class="marginLeft-70" style="margin-left: -60px;">
<Button type="primary" class="width-80" @click="_search">搜索</Button>
<Button type="primary" class="width-80" @click="_getData">搜索</Button>
</Form-item>
</Form>
</div>
......@@ -99,11 +99,15 @@ export default {
this.tempData.endDate = data[1]
this.pieData.beginDate = data[0]
this.pieData.endDate = data[1]
this.forObject.edateBegin = data[0]
this.forObject.edateEnd = data[1]
} else {
this.tempData.beginDate = ''
this.tempData.endDate = ''
this.pieData.beginDate = ''
this.pieData.endDate = ''
this.forObject.edateBegin = ''
this.forObject.edateEnd = ''
}
this.$refs.contractTableModal._changeDate(this.tempData)
},
......@@ -111,14 +115,15 @@ export default {
this.$refs.contractTableModal._pieOpen(res)
},
_getData: async function() {
console.log('753951')
console.log('选择时间后的请求', this.forObject)
const result = await meterSample.pageCertificateRateStatistics(
this.forObject
)
if (result) {
console.log('result=>', result)
this._open(result)
}
this._search()
},
_open(result) {
......@@ -129,10 +134,10 @@ export default {
beginDate: this.tempData.beginDate,
endDate: this.tempData.endDate
})
this.$refs.contractPieModal._searchPie({
beginDate: this.pieData.beginDate,
endDate: this.pieData.endDate
})
// this.$refs.contractPieModal._searchPie({
// beginDate: this.pieData.beginDate,
// endDate: this.pieData.endDate
// })
},
_export() {
this.$refs.contractTableModal._exportSampleForm()
......
......@@ -57,7 +57,6 @@ export default {
methods: {
// 日期变化时,将时间赋值,导出根据查询条件
_changeDate(data) {
console.log(123456)
console.log(data)
$('input[name=beginDate]').val(data.beginDate)
$('input[name=endDate]').val(data.endDate)
......
......@@ -21,7 +21,7 @@
</el-date-picker>
</Form-item>
<Form-item class="search-btn">
<Button @click="_search" type="primary" class="width-80">搜索</Button>
<Button @click="_getData" type="primary" class="width-80">搜索</Button>
</Form-item>
</Form>
</div>
......@@ -119,6 +119,10 @@ export default {
getPage: {
records: []
},
formObj: {
edateBegin: undefined,
edateEnd: undefined
},
tempData: {
groupId: '',
groupName: '',
......@@ -138,6 +142,8 @@ export default {
},
mounted() {
this.$refs.pageTable._hideLoading()
this.formObj.edateBegin = this.tempData.beginDate
this.formObj.edateEnd = this.tempData.endDate
// this._contHide()
// this._getUserGroup()
this._getData()
......@@ -146,7 +152,9 @@ export default {
methods: {
// 服务类型
_getData: async function() {
const result = await meterSample.pageSampleQuantityStatistics()
const result = await meterSample.pageSampleQuantityStatistics(
this.formObj
)
if (result) {
this.getPage.records = result
this.$refs.testPieModal._openPie(this.getPage.records)
......@@ -167,9 +175,13 @@ export default {
if (data) {
this.tempData.beginDate = data[0]
this.tempData.endDate = data[1]
this.formObj.edateBegin = data[0]
this.formObj.edateEnd = data[1]
} else {
this.tempData.beginDate = ''
this.tempData.endDate = ''
this.formObj.edateBegin = undefined
this.formObj.edateEnd = undefined
}
},
_contHide() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment