Browse Source

2025/6/16

master
Aoi_Tori 9 months ago
parent
commit
123fbb7b26
  1. 180
      src/views/common/filterSearch.vue
  2. 17
      src/views/modules/project/projectInfo/projectInfo.vue
  3. 17
      src/views/modules/project/projectPart/searchProjectPart.vue
  4. 17
      src/views/modules/proofing/requestForProofing.vue
  5. 17
      src/views/modules/quotation/requestForQuote.vue
  6. 19
      src/views/modules/quotation/toBeQuoted.vue
  7. 17
      src/views/modules/quote/index.vue
  8. 17
      src/views/modules/sampleManagement/technicalSpecificationList.vue
  9. 17
      src/views/modules/test/requestForTest.vue

180
src/views/common/filterSearch.vue

@ -80,7 +80,6 @@ export default {
searchUserSettingRecordList(params).then(({data})=>{
if (data && data.code === 0){
this.selectList = data.rows
console.log(this.selectList)
}else {
this.$message.warning(data.msg)
}
@ -200,7 +199,6 @@ export default {
moveSetting(index,direction){
let arr = [...this.tableList]
let temp = arr[index+direction]
console.log(temp)
arr[index+direction] = arr[index]
arr[index] = temp
this.tableList = arr
@ -375,8 +373,7 @@ export default {
</div>
<div style="display: flex;gap: 5px">
<div style="width: 85%;height: 400px" v-loading="loadingTableList" element-loading-text="加载中">
<!-- TODO 之后回来把filter去掉-->
<el-table :data="tableList.filter(row => row.dataType !== 'D')" @select="selectRow" ref="settingTable" border height="100%" v-show="showSetting">
<el-table :data="tableList" @select="selectRow" ref="settingTable" border height="100%" v-show="showSetting">
<el-table-column
type="selection"
width="40" align="center">
@ -388,80 +385,56 @@ export default {
</template>
</el-table-column>
<el-table-column label="属性名称" align="left" header-align="center" show-overflow-tooltip width="120" prop="fieldCaption"></el-table-column>
<!-- <el-table-column label="条件" align="center" width="240">-->
<!-- <template slot-scope="{row,$index}">-->
<!-- <div v-if="row.dataType === 'D'" style="width: 100%">-->
<!-- <el-date-picker-->
<!-- v-model="row.formula"-->
<!-- type="date"-->
<!-- placeholder="选择日期"-->
<!-- value-format="yyyy-MM-dd" style="width: 100%;"-->
<!-- />-->
<!-- </div>-->
<!-- <div v-else>-->
<!-- <el-input v-model="row.formula" clearable>-->
<!-- <el-select slot="prepend" clearable v-model="row.symbol" style="width: 100px;cursor:pointer;">-->
<!-- &lt;!&ndash; <el-option value="eq" label="等于"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="gt" label="大于"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="ge" label="大于等于"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="lt" label="小于"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="le" label="小于等于"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="between" label="之间"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="in" label="或者"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="ne" label="不等于"></el-option>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-option value="like" label="LIKE"></el-option>&ndash;&gt;-->
<!-- </el-select>-->
<!-- </el-input>-->
<!-- </div>-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column label="条件" align="center" width="240">
<el-table-column label="条件" align="center" header-align="center" width="240">
<template slot-scope="{row,$index}">
<!-- 情况一日期类型 D -->
<div v-if="row.dataType === 'D'">
<el-input v-model="row.formula" clearable>
<el-date-picker
v-model="row.formula"
type="datetime"
placeholder="选择日期"
value-format="yyyy-MM-dd"
style="width: 100%; margin-bottom: 5px;"
/>
<el-select v-model="row.symbol" style="width: 100px; cursor: pointer;" clearable>
<el-option value="eq" label="等于"></el-option>
<el-option value="gt" label="大于"></el-option>
<el-option value="ge" label="大于等于"></el-option>
<el-option value="lt" label="小于"></el-option>
<el-option value="le" label="小于等于"></el-option>
<el-option value="between" label="之间"></el-option>
<el-option value="ne" label="不等于"></el-option>
</el-select>
</el-input>
</div>
<!-- 情况二数字类型 N -->
<div v-else-if="row.dataType === 'N'" style="width: 100%">
<el-input v-model="row.formula" style="width: 100%" type="number" clearable />
<el-select v-model="row.symbol" style="width: 100px; cursor: pointer; margin-top: 5px;" clearable>
<div v-if="row.dataType === 'D'" style="display: flex; align-items: center;">
<el-select v-model="row.symbol" style="color:#f5f7fa; width: 82px; cursor: pointer;" clearable>
<el-option value="eq" label="等于"></el-option>
<el-option value="gt" label="大于"></el-option>
<el-option value="ge" label="大于等于"></el-option>
<el-option value="lt" label="小于"></el-option>
<el-option value="le" label="小于等于"></el-option>
<el-option value="between" label="之间"></el-option>
<el-option value="in" label="或者"></el-option>
<el-option value="ne" label="不等于"></el-option>
</el-select>
<el-date-picker
v-model="row.formula"
type="datetime"
placeholder="选择日期时间"
value-format="yyyy-MM-dd HH:mm:ss" style="margin-left: -1px; flex: 1;"
/>
</div>
<div v-if="row.dataType === 'S'" style="display: flex; align-items: center;">
<el-select slot="prepend" clearable v-model="row.symbol" style="width: 80px; cursor: pointer;">
<el-option
value="in"
label="属于"
v-if="(row.menuId === '102001' && row.fieldName === 'createBy') ||
(row.menuId === '102004' && row.fieldName === 'createBy') ||
(row.menuId === '107001' && row.fieldName === 'createBy') ||
(row.menuId === '103001' && row.fieldName === 'createBy')"
/>
<el-option value="eq" label="等于" v-else />
<el-option value="ne" label="不等于" v-else />
<el-option value="like" label="LIKE" v-else />
</el-select>
<el-input v-model="row.formula" clearable style="margin-left: -1px; flex: 1;" />
</div>
<!-- 情况三字符串类型 S -->
<div v-else-if="row.dataType === 'S'" style="width: 100%">
<el-input v-model="row.formula" clearable />
<el-select v-model="row.symbol" style="width: 100px; cursor: pointer; margin-top: 5px;" clearable>
<div v-else-if="row.dataType === 'N'" style="display: flex; align-items: center;">
<el-select slot="prepend" clearable v-model="row.symbol" style="width: 80px; cursor: pointer;">
<el-option value="eq" label="等于"></el-option>
<el-option value="gt" label="大于"></el-option>
<el-option value="ge" label="大于等于"></el-option>
<el-option value="lt" label="小于"></el-option>
<el-option value="le" label="小于等于"></el-option>
<el-option value="ne" label="不等于"></el-option>
<el-option value="like" label="LIKE"></el-option>
<el-option value="in" label="或者"></el-option>
</el-select>
<el-input v-model="row.formula"
type="text"
clearable style="margin-left: -1px; flex: 1;"
oninput="this.value = this.value.replace(/[^0-9.]/g, '')"
onafterpaste="this.value = this.value.replace(/[^0-9.]/g, '')" />
</div>
</template>
</el-table-column>
@ -479,43 +452,60 @@ export default {
<el-input-number v-model="row.orderSeq" clearable style="width: 100%;" :controls="false"></el-input-number>
</template>
</el-table-column>
<el-table-column label="数据库字段" align="center" prop="originalField" show-overflow-tooltip width="120"></el-table-column>
</el-table>
<!-- TODO 暂时用filter之后再处理-->
<el-table :data="copyTableList.filter(row => row.dataType !== 'D')" border height="100%" v-show="!showSetting">
<el-table :data="copyTableList" border height="100%" v-show="!showSetting">
<el-table-column label="属性名称" align="left" header-align="center" show-overflow-tooltip width="120" prop="fieldCaption"></el-table-column>
<el-table-column label="条件" align="center" header-align="center" width="240">
<template slot-scope="{row,$index}">
<el-input v-model="row.formula" clearable>
<el-select slot="prepend" clearable v-model="row.symbol" style="width: 80px;cursor:pointer;">
<!-- <el-option value="eq" label="等于"></el-option>
<el-option value="gt" label="大于"></el-option>
<el-option value="ge" label="大于等于"></el-option>
<el-option value="lt" label="小于"></el-option>
<el-option value="le" label="小于等于"></el-option>
<el-option value="between" label="之间"></el-option>
<el-option value="in" label="或者"></el-option>
<el-option value="ne" label="不等于"></el-option>
<el-option value="like" label="LIKE"></el-option>-->
<!-- 数字类型支持的条件 -->
<el-option value="eq" label="等于" v-if="row.dataType === 'N' || row.dataType === 'D'"></el-option>
<el-option value="gt" label="大于" v-if="row.dataType === 'N' || row.dataType === 'D'"></el-option>
<el-option value="ge" label="大于等于" v-if="row.dataType === 'N' || row.dataType === 'D'"></el-option>
<el-option value="lt" label="小于" v-if="row.dataType === 'N' || row.dataType === 'D'"></el-option>
<el-option value="le" label="小于等于" v-if="row.dataType === 'N' || row.dataType === 'D'"></el-option>
<el-option value="between" label="之间" v-if="row.dataType === 'N' || row.dataType === 'D'"></el-option>
<div v-if="row.dataType === 'D'" style="display: flex; align-items: center;">
<el-select v-model="row.symbol" style="color:#f5f7fa; width: 82px; cursor: pointer;" clearable>
<el-option value="eq" label="等于"></el-option>
<el-option value="gt" label="大于"></el-option>
<el-option value="ge" label="大于等于"></el-option>
<el-option value="lt" label="小于"></el-option>
<el-option value="le" label="小于等于"></el-option>
<el-option value="ne" label="不等于"></el-option>
</el-select>
<el-date-picker
v-model="row.formula"
type="datetime"
placeholder="选择日期时间"
value-format="yyyy-MM-dd HH:mm:ss" style="margin-left: -1px; flex: 1;"
/>
</div>
<!-- 字符串类型支持的条件 -->
<el-option value="eq" label="等于" v-if="row.dataType === 'S'"></el-option>
<el-option value="ne" label="不等于" v-if="row.dataType === 'S'"></el-option>
<el-option value="like" label="LIKE" v-if="row.dataType === 'S'"></el-option>
<el-option value="in" label="或者" v-if="row.dataType === 'S'"></el-option>
<div v-if="row.dataType === 'S'" style="display: flex; align-items: center;">
<el-select slot="prepend" clearable v-model="row.symbol" style="width: 80px; cursor: pointer;">
<el-option
value="in"
label="属于"
v-if="(row.menuId === '102001' && row.fieldName === 'createBy') ||
(row.menuId === '102004' && row.fieldName === 'createBy') ||
(row.menuId === '107001' && row.fieldName === 'createBy') ||
(row.menuId === '103001' && row.fieldName === 'createBy')"
/>
<el-option value="eq" label="等于" v-else />
<el-option value="ne" label="不等于" v-else />
<el-option value="like" label="LIKE" v-else />
</el-select>
<el-input v-model="row.formula" clearable style="margin-left: -1px; flex: 1;" />
</div>
<!-- 通用条件 -->
<el-option value="ne" label="不等于" v-if="row.dataType !== 'S'"></el-option>
<el-option value="in" label="或者" v-if="row.dataType === 'N'"></el-option>
<div v-else-if="row.dataType === 'N'" style="display: flex; align-items: center;">
<el-select slot="prepend" clearable v-model="row.symbol" style="width: 80px; cursor: pointer;">
<el-option value="eq" label="等于"></el-option>
<el-option value="gt" label="大于"></el-option>
<el-option value="ge" label="大于等于"></el-option>
<el-option value="lt" label="小于"></el-option>
<el-option value="le" label="小于等于"></el-option>
<el-option value="ne" label="不等于"></el-option>
</el-select>
</el-input>
<el-input v-model="row.formula"
type="text"
clearable style="margin-left: -1px; flex: 1;"
oninput="this.value = this.value.replace(/[^0-9.]/g, '')"
onafterpaste="this.value = this.value.replace(/[^0-9.]/g, '')" />
</div>
</template>
</el-table-column>
<el-table-column label="排序" align="center" prop="sortBy" show-overflow-tooltip width="140">

17
src/views/modules/project/projectInfo/projectInfo.vue

@ -453,6 +453,8 @@
activeName: 'info',
addOrUpdateVisible:false,
filterVisible:false,
isFilterSearch: false,
filterSearchData: {},
searchData:{
page: 1,
limit: 100,
@ -1434,6 +1436,7 @@
}
}
this.dataListLoading = false
this.isFilterSearch = false
})
},
//
@ -1687,12 +1690,20 @@
sizeChangeHandle (val) {
this.pageSize = val
this.pageIndex = 1
this.search()
if ( this.isFilterSearch === false){
this.search()
} else {
this.projectInfoSearchByAnyField(this.filterSearchData)
}
},
//
currentChangeHandle (val) {
this.pageIndex = val
this.search()
if ( this.isFilterSearch === false){
this.search()
} else {
this.projectInfoSearchByAnyField(this.filterSearchData)
}
},
//
async getTableUserColumn(tableId, columnId) {
@ -2011,7 +2022,9 @@
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.filterVisible = false
this.isFilterSearch = true
},
},

17
src/views/modules/project/projectPart/searchProjectPart.vue

@ -265,6 +265,8 @@
height: 200,
dataListLoading: false,
filterVisible: false,
isFilterSearch: false,
filterSearchData: {},
// start
exportData: [],
exportName: "项目物料清单" + this.dayjs().format('YYYYMMDDHHmmss'),
@ -868,12 +870,20 @@
sizeChangeHandle (val) {
this.pageSize = val
this.pageIndex = 1
this.search()
if ( this.isFilterSearch === false){
this.search()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
//
currentChangeHandle (val) {
this.pageIndex = val
this.search()
if ( this.isFilterSearch === false){
this.search()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
//
@ -937,6 +947,7 @@
this.changeData(this.dataList1[0])
}
}
this.isFilterSearch = false
this.dataListLoading = false
})
},
@ -1050,6 +1061,8 @@
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.isFilterSearch = true
this.filterVisible = false
},

17
src/views/modules/proofing/requestForProofing.vue

@ -2084,6 +2084,8 @@ export default {
proofingCurrentRow: {},
// ======== ========
filterVisible: false,
isFilterSearch: false,
filterSearchData: {},
modalFlag: false,
modalDisableFlag: false,
enterResultModalFlag: false,
@ -2273,7 +2275,11 @@ export default {
sizeChangeHandle(val) {
this.pageSize = val
this.pageIndex = 1
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
/**
* 当前页
@ -2281,7 +2287,11 @@ export default {
*/
currentChangeHandle(val) {
this.pageIndex = val
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
// ======== ========
@ -2400,6 +2410,7 @@ export default {
this.testClickRow({})
}
}
this.isFilterSearch = false
this.dataListLoading = false
})
},
@ -3789,6 +3800,8 @@ export default {
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.isFilterSearch = true
this.filterVisible = false
},
}

17
src/views/modules/quotation/requestForQuote.vue

@ -990,6 +990,8 @@ export default {
totalPage: 0,
selectedDataNum: 0,
filterVisible: false,
isFilterSearch: false,
filterSearchData: {},
//
searchData: {
site: this.$store.state.user.site,
@ -2188,7 +2190,11 @@ export default {
sizeChangeHandle(val) {
this.pageSize = val
this.pageIndex = 1
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
/**
* 当前页
@ -2196,7 +2202,11 @@ export default {
*/
currentChangeHandle(val) {
this.pageIndex = val
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
// ======== ========
@ -2297,6 +2307,7 @@ export default {
this.quotationCurrentRow = {}
}
}
this.isFilterSearch = false
this.dataListLoading = false
})
},
@ -3595,6 +3606,8 @@ export default {
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.isFilterSearch = true
this.filterVisible = false
},
}

19
src/views/modules/quotation/toBeQuoted.vue

@ -241,6 +241,8 @@ export default {
//
saveBatchQuotationLoading:false,
filterVisible: false,
isFilterSearch: false,
filterSearchData: {},
// ======== ========
columnList: [
{
@ -589,17 +591,26 @@ export default {
this.totalPage = data.page.totalCount
this.$refs.selectDiv.setLengthAll(this.dataList.length)
}
this.dataListLoading = false;
this.isFilterSearch = false
this.dataListLoading = false
})
},
sizeChangeHandle (val) {
this.pageSize = val
this.pageIndex = 1
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
currentChangeHandle (val) {
this.pageIndex = val
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
//
quotationClickRow (row) {
@ -664,6 +675,8 @@ export default {
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.isFilterSearch = true
this.filterVisible = false
},
},

17
src/views/modules/quote/index.vue

@ -392,6 +392,8 @@ export default {
quoterVisible:false,
purchaseVisible:false,
filterVisible:false,
isFilterSearch: false,
filterSearchData: {},
currentQuote:{
},
@ -527,6 +529,7 @@ export default {
this.$message.error(error)
this.searchLoading = false
})
this.isFilterSearch = false
},
handleSelect(row){
if (row){
@ -559,11 +562,19 @@ export default {
},
handleSizeChange(size){
this.size = size
this.handleSearch();
if ( this.isFilterSearch === false){
this.handleSearch()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
handlePageChange(no) {
this.no = no
this.handleSearch();
if ( this.isFilterSearch === false){
this.handleSearch()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
handleQueryBu(){
let params = {
@ -1000,6 +1011,8 @@ export default {
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.isFilterSearch = true
this.filterVisible = false
},
},

17
src/views/modules/sampleManagement/technicalSpecificationList.vue

@ -564,6 +564,8 @@
activeName: 'info',
addOrUpdateVisible: false,
filterVisible: false,
isFilterSearch: false,
filterSearchData: {},
height: 200,
dataList1: [],
partList: [],
@ -1187,13 +1189,21 @@
sizeChangeHandle (val) {
this.pageSize = val
this.pageIndex = 1
this.search()
if ( this.isFilterSearch === false){
this.search()
} else {
this.queryByAnyField(this.filterSearchData)
}
},
//
currentChangeHandle (val) {
this.pageIndex = val
this.search()
if ( this.isFilterSearch === false){
this.search()
} else {
this.queryByAnyField(this.filterSearchData)
}
},
//
@ -1229,6 +1239,7 @@
this.$message.error(error)
this.dataListLoading = false
})
this.isFilterSearch = false
},
changeData (row) {
@ -1578,6 +1589,8 @@
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.isFilterSearch = true
this.filterVisible = false
},

17
src/views/modules/test/requestForTest.vue

@ -1110,6 +1110,8 @@ export default {
activeTabList: ['attribute'],
clickTestRow: false,
filterVisible: false,
isFilterSearch: false,
filterSearchData: {},
//
exportData: [],
exportName: '设备分类' + this.dayjs().format('YYYYMMDDHHmmss'),
@ -2376,7 +2378,11 @@ export default {
sizeChangeHandle(val) {
this.pageSize = val
this.pageIndex = 1
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
/**
* 当前页
@ -2384,7 +2390,11 @@ export default {
*/
currentChangeHandle(val) {
this.pageIndex = val
this.getDataList()
if ( this.isFilterSearch === false){
this.getDataList()
} else {
this.searchByAnyField(this.filterSearchData)
}
},
// ======== ========
@ -2532,6 +2542,7 @@ export default {
this.testClickRow({})
}
}
this.isFilterSearch = false
this.dataListLoading = false
})
},
@ -3770,6 +3781,8 @@ export default {
}).catch((error)=>{
this.$message.error(error)
})
this.filterSearchData = params
this.isFilterSearch = true
this.filterVisible = false
},
},

Loading…
Cancel
Save