Browse Source

table组件左右侧操作列区分

noToken
安虹睿 1 year ago
parent
commit
87416e1480
  1. 2
      PC/InterFace.Dash/README.md
  2. 10
      PC/InterFace.Dash/src/components/commonTabel-drawer copy/index.vue
  3. 10
      PC/InterFace.Dash/src/components/commonTabel-drawer/index.vue
  4. 10
      PC/InterFace.Dash/src/components/tablePagination/index.vue
  5. 48
      PC/InterFace.Dash/src/components/umyTable/index.vue
  6. 2
      PC/InterFace.Dash/src/mixins/TableMixins.js
  7. 6
      PC/InterFace.Dash/src/views/basicConfig/ExportCustomUserSetting.vue
  8. 4
      PC/InterFace.Dash/src/views/demo/demo_detail_addbase.vue
  9. 6
      PC/InterFace.Dash/src/views/menuList/AsnMstr.vue
  10. 6
      PC/InterFace.Dash/src/views/menuList/ExportCustomUserSetting.vue
  11. 6
      PC/InterFace.Dash/src/views/menuList/OutgoingDataHistory.vue
  12. 6
      PC/InterFace.Dash/src/views/menuList/PoMstr.vue
  13. 6
      PC/InterFace.Dash/src/views/menuList/ReceiptMstr.vue
  14. 6
      PC/InterFace.Dash/src/views/menuList/ReturnMstr.vue

2
PC/InterFace.Dash/README.md

@ -46,7 +46,7 @@ alertoldSkipCount 主列表-分页-当前页条数
alterResultCount 主列表-分页-每页最大页数 alterResultCount 主列表-分页-每页最大页数
handleSelectionChange 主列表-选择-行数据方法 tablePagination ==> currenTable handleSelectionChange 主列表-选择-行数据方法 tablePagination ==> currenTable
<----20230207添加 begin----> <----20230207添加 begin---->
buttonOperationClick 主列表-操作列按钮点击事件 buttonOperationClick_left 主列表-操作列按钮点击事件
currentPageProps 主列表-当前页码值 currentPageProps 主列表-当前页码值
使用的是@/mixins/TableMixins的oldSkipCount值 使用的是@/mixins/TableMixins的oldSkipCount值
quicklySearchOption 主表查询-快速搜索数据配置 ==> 通用配置在@/utils/quicklySearchOption/index quicklySearchOption 主表查询-快速搜索数据配置 ==> 通用配置在@/utils/quicklySearchOption/index

10
PC/InterFace.Dash/src/components/commonTabel-drawer copy/index.vue

@ -117,8 +117,8 @@
@handleSelectionChange="handleSelectionChange" @handleSelectionChange="handleSelectionChange"
@inlineDialog="inlineDialog" @inlineDialog="inlineDialog"
@buttonClick="buttonClick" @buttonClick="buttonClick"
:buttonOperationList="buttonOperationList" :buttonOperationList_left="buttonOperationList_left"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
> >
<template> <template>
<slot></slot> <slot></slot>
@ -257,7 +257,7 @@ export default {
], ],
props: { props: {
// //
buttonOperationList:{ buttonOperationList_left:{
type: Array, type: Array,
default: null, default: null,
}, },
@ -479,7 +479,7 @@ export default {
this.displayDialog.detailInfoDialog = val || false this.displayDialog.detailInfoDialog = val || false
}, },
// - // -
buttonOperationClick(row, item, index){ buttonOperationClick_left(row, item, index){
// //
if(item.name == "info"){ if(item.name == "info"){
this.displayDialog.detailInfoDialog = true this.displayDialog.detailInfoDialog = true
@ -487,7 +487,7 @@ export default {
let _name = allUrlOption[this.$route.name].detailInfoName let _name = allUrlOption[this.$route.name].detailInfoName
this.detailInfoTitle = _name ? row[_name] + ' 详情' : '详情' this.detailInfoTitle = _name ? row[_name] + ' 详情' : '详情'
} }
this.$emit('buttonOperationClick',row, item, index) this.$emit('buttonOperationClick_left',row, item, index)
}, },
rowDrop(data,type) { rowDrop(data,type) {
this.$emit('rowDrop',data,type) this.$emit('rowDrop',data,type)

10
PC/InterFace.Dash/src/components/commonTabel-drawer/index.vue

@ -78,8 +78,8 @@
:currentPageProps="oldSkipCount" :currentPageProps="oldSkipCount"
@overallSearchFormClick="overallSearchClickForDetail" @overallSearchFormClick="overallSearchClickForDetail"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:buttonOperationList="buttonOperationList" :buttonOperationList_left="buttonOperationList_left"
:tableLoading="Loading.tableLoading" :tableLoading="Loading.tableLoading"
></tablePagination> ></tablePagination>
<!-- 新增汇总 表头 区分明细表头使用 summaryTableColumns --> <!-- 新增汇总 表头 区分明细表头使用 summaryTableColumns -->
@ -205,7 +205,7 @@ export default {
], ],
props: { props: {
// //
buttonOperationList:{ buttonOperationList_left:{
type: Array, type: Array,
default: null, default: null,
}, },
@ -531,7 +531,7 @@ export default {
this.displayDialog.detailInfoDialog = val || false this.displayDialog.detailInfoDialog = val || false
}, },
// - // -
buttonOperationClick(row, item, index){ buttonOperationClick_left(row, item, index){
// //
if(item.name == "info"){ if(item.name == "info"){
this.displayDialog.detailInfoDialog = true this.displayDialog.detailInfoDialog = true
@ -539,7 +539,7 @@ export default {
let _name = allUrlOption[this.$route.name].detailInfoName let _name = allUrlOption[this.$route.name].detailInfoName
this.detailInfoTitle = _name ? row[_name] + ' 详情' : '详情' this.detailInfoTitle = _name ? row[_name] + ' 详情' : '详情'
} }
this.$emit('buttonOperationClick',row, item, index) this.$emit('buttonOperationClick_left',row, item, index)
}, },
rowDrop(data,type) { rowDrop(data,type) {
this.$emit('rowDrop',data,type) this.$emit('rowDrop',data,type)

10
PC/InterFace.Dash/src/components/tablePagination/index.vue

@ -51,8 +51,8 @@
@sortChange="sortChange" @sortChange="sortChange"
@handleSelectionChange="handleSelectionChange" @handleSelectionChange="handleSelectionChange"
@inlineDialog="inlineDialog" @inlineDialog="inlineDialog"
:buttonOperationList="buttonOperationList" :buttonOperationList_left="buttonOperationList_left"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:tableBorder="true" :tableBorder="true"
:firstFixed="true" :firstFixed="true"
:cellStyle = "cellStyle" :cellStyle = "cellStyle"
@ -116,7 +116,7 @@ export default {
} }
}, },
// //
buttonOperationList:{ buttonOperationList_left:{
type: Array, type: Array,
default: null, default: null,
}, },
@ -342,8 +342,8 @@ export default {
this.$emit('sortChange', data) this.$emit('sortChange', data)
}, },
//table //table
buttonOperationClick(row, item, index) { buttonOperationClick_left(row, item, index) {
this.$emit("buttonOperationClick", row, item, index); this.$emit("buttonOperationClick_left", row, item, index);
}, },
// //
// /showSearchOverall // /showSearchOverall

48
PC/InterFace.Dash/src/components/umyTable/index.vue

@ -19,9 +19,9 @@
header-row-class-name="uTableHeader" header-row-class-name="uTableHeader"
> >
<!-- :tree-props="treeProps" height 不能共存 此组件暂不支持tree的格式--> <!-- :tree-props="treeProps" height 不能共存 此组件暂不支持tree的格式-->
<!-- 操作列 --> <!-- 操作列 左侧-->
<u-table-column <u-table-column
v-if="buttonOperationList" v-if="buttonOperationList_left"
:fixed="'left'" :fixed="'left'"
:width="120" :width="120"
:align="'center'" :align="'center'"
@ -32,11 +32,32 @@
</template> </template>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-for="(itemButton, indexButton) in buttonOperationList" v-for="(itemButton, indexButton) in buttonOperationList_left"
:key="indexButton" :key="indexButton"
type="text" type="text"
size="mini" size="mini"
@click="buttonOperationClick(scope.row, itemButton, indexButton)" @click="buttonOperationClick_left(scope.row, itemButton, indexButton)"
>{{itemButton.label}}</el-button>
</template>
</u-table-column>
<!-- 操作列 右侧-->
<u-table-column
v-if="buttonOperationList_right"
:fixed="'right'"
:width="120"
:align="'center'"
:header-align="'center'"
>
<template #header>
<span>操作</span>
</template>
<template slot-scope="scope">
<el-button
v-for="(itemButton, indexButton) in buttonOperationList_right"
:key="indexButton"
type="text"
size="mini"
@click="buttonOperationClick_right(scope.row, itemButton, indexButton)"
>{{itemButton.label}}</el-button> >{{itemButton.label}}</el-button>
</template> </template>
</u-table-column> </u-table-column>
@ -442,8 +463,13 @@ export default {
}, },
}, },
props: { props: {
// //
buttonOperationList:{ buttonOperationList_left:{
type: Array,
default: null,
},
// ()
buttonOperationList_right:{
type: Array, type: Array,
default: null, default: null,
}, },
@ -881,9 +907,13 @@ export default {
buttonClick(row, index, label) { buttonClick(row, index, label) {
this.$emit("buttonClick", row, index, label); this.$emit("buttonClick", row, index, label);
}, },
//table //table()
buttonOperationClick(row, item, index) { buttonOperationClick_left(row, item, index) {
this.$emit("buttonOperationClick", row, item, index); this.$emit("buttonOperationClick_left", row, item, index);
},
//table()
buttonOperationClick_right(row, item, index) {
this.$emit("buttonOperationClick_right", row, item, index);
}, },
}, },
}; };

2
PC/InterFace.Dash/src/mixins/TableMixins.js

@ -240,7 +240,7 @@ export const tableMixins = {
* @param {*} item 按钮信息 * @param {*} item 按钮信息
* @param {*} index 按钮索引 * @param {*} index 按钮索引
*/ */
buttonOperationClick(row, item, index) { buttonOperationClick_left(row, item, index) {
// 获取当前行数据,赋值给 propsData // 获取当前行数据,赋值给 propsData
this.propsData = row this.propsData = row
// 查看详情 // 查看详情

6
PC/InterFace.Dash/src/views/basicConfig/ExportCustomUserSetting.vue

@ -17,7 +17,7 @@
@alertoldSkipCount="alertoldSkipCount" @alertoldSkipCount="alertoldSkipCount"
@alterResultCount="alterResultCount" @alterResultCount="alterResultCount"
@handleSelectionChange="handleSelectionChange" @handleSelectionChange="handleSelectionChange"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:currentPageProps="oldSkipCount" :currentPageProps="oldSkipCount"
:quicklySearchOption="quicklySearchOption" :quicklySearchOption="quicklySearchOption"
@quicklySearchClick="quicklySearchClick" @quicklySearchClick="quicklySearchClick"
@ -25,7 +25,7 @@
:primarySearchOption="primarySearchOption" :primarySearchOption="primarySearchOption"
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
:buttonOperationList="operationButtonsTable" :buttonOperationList_left="operationButtonsTable"
> >
<!-- <div slot="tableTopSlot"> <!-- <div slot="tableTopSlot">
上方按钮插槽位置预留 上方按钮插槽位置预留
@ -101,7 +101,7 @@
:MaxResultCount="MaxResultCountDetails" :MaxResultCount="MaxResultCountDetails"
@alterResultCountDetails="alterResultCountDetails" @alterResultCountDetails="alterResultCountDetails"
@alertoldSkipCountDetails="alertoldSkipCountDetails" @alertoldSkipCountDetails="alertoldSkipCountDetails"
:buttonOperationList="operationButtonsDetail" :buttonOperationList_left="operationButtonsDetail"
></curren-Drawer> ></curren-Drawer>
<!-- <curren-Drawer <!-- <curren-Drawer
:title="apiColumns_DesTions" :title="apiColumns_DesTions"

4
PC/InterFace.Dash/src/views/demo/demo_detail_addbase.vue

@ -24,8 +24,8 @@
:primarySearchOption="primarySearchOption" :primarySearchOption="primarySearchOption"
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:buttonOperationList="operationButtonsTable" :buttonOperationList_left="operationButtonsTable"
></tablePagination> ></tablePagination>
<curren-Drawer <curren-Drawer
:title="apiColumns_DesTions" :title="apiColumns_DesTions"

6
PC/InterFace.Dash/src/views/menuList/AsnMstr.vue

@ -23,8 +23,8 @@
:primarySearchOption="primarySearchOption" :primarySearchOption="primarySearchOption"
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:buttonOperationList="operationButtonsTable" :buttonOperationList_left="operationButtonsTable"
></tablePagination> ></tablePagination>
<curren-Drawer <curren-Drawer
ref="currenDrawer_Ref" ref="currenDrawer_Ref"
@ -45,7 +45,7 @@
:MaxResultCount="MaxResultCountDetails" :MaxResultCount="MaxResultCountDetails"
@alterResultCountDetails="alterResultCountDetails" @alterResultCountDetails="alterResultCountDetails"
@alertoldSkipCountDetails="alertoldSkipCountDetails" @alertoldSkipCountDetails="alertoldSkipCountDetails"
:buttonOperationList="operationButtonsDetail" :buttonOperationList_left="operationButtonsDetail"
></curren-Drawer> ></curren-Drawer>
<!-- 明细查询页面 --> <!-- 明细查询页面 -->
<filterForDetailPage <filterForDetailPage

6
PC/InterFace.Dash/src/views/menuList/ExportCustomUserSetting.vue

@ -17,7 +17,7 @@
@alertoldSkipCount="alertoldSkipCount" @alertoldSkipCount="alertoldSkipCount"
@alterResultCount="alterResultCount" @alterResultCount="alterResultCount"
@handleSelectionChange="handleSelectionChange" @handleSelectionChange="handleSelectionChange"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:currentPageProps="oldSkipCount" :currentPageProps="oldSkipCount"
:quicklySearchOption="quicklySearchOption" :quicklySearchOption="quicklySearchOption"
@quicklySearchClick="quicklySearchClick" @quicklySearchClick="quicklySearchClick"
@ -25,7 +25,7 @@
:primarySearchOption="primarySearchOption" :primarySearchOption="primarySearchOption"
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
:buttonOperationList="operationButtonsTable" :buttonOperationList_left="operationButtonsTable"
> >
<!-- <div slot="tableTopSlot"> <!-- <div slot="tableTopSlot">
上方按钮插槽位置预留 上方按钮插槽位置预留
@ -101,7 +101,7 @@
:MaxResultCount="MaxResultCountDetails" :MaxResultCount="MaxResultCountDetails"
@alterResultCountDetails="alterResultCountDetails" @alterResultCountDetails="alterResultCountDetails"
@alertoldSkipCountDetails="alertoldSkipCountDetails" @alertoldSkipCountDetails="alertoldSkipCountDetails"
:buttonOperationList="operationButtonsDetail" :buttonOperationList_left="operationButtonsDetail"
></curren-Drawer> ></curren-Drawer>
<!-- <curren-Drawer <!-- <curren-Drawer
:title="apiColumns_DesTions" :title="apiColumns_DesTions"

6
PC/InterFace.Dash/src/views/menuList/OutgoingDataHistory.vue

@ -24,8 +24,8 @@
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
></tablePagination> ></tablePagination>
<!-- @buttonOperationClick="buttonOperationClick" <!-- @buttonOperationClick_left="buttonOperationClick_left"
:buttonOperationList="operationButtonsTable" --> :buttonOperationList_left="operationButtonsTable" -->
<curren-Drawer <curren-Drawer
ref="currenDrawer_Ref" ref="currenDrawer_Ref"
:title="apiColumns_DesTions" :title="apiColumns_DesTions"
@ -45,7 +45,7 @@
:MaxResultCount="MaxResultCountDetails" :MaxResultCount="MaxResultCountDetails"
@alterResultCountDetails="alterResultCountDetails" @alterResultCountDetails="alterResultCountDetails"
@alertoldSkipCountDetails="alertoldSkipCountDetails" @alertoldSkipCountDetails="alertoldSkipCountDetails"
:buttonOperationList="operationButtonsDetail" :buttonOperationList_left="operationButtonsDetail"
></curren-Drawer> ></curren-Drawer>
<!-- 导出弹窗 --> <!-- 导出弹窗 -->
<exportDrop <exportDrop

6
PC/InterFace.Dash/src/views/menuList/PoMstr.vue

@ -23,8 +23,8 @@
:primarySearchOption="primarySearchOption" :primarySearchOption="primarySearchOption"
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:buttonOperationList="operationButtonsTable" :buttonOperationList_left="operationButtonsTable"
></tablePagination> ></tablePagination>
<curren-Drawer <curren-Drawer
ref="currenDrawer_Ref" ref="currenDrawer_Ref"
@ -45,7 +45,7 @@
:MaxResultCount="MaxResultCountDetails" :MaxResultCount="MaxResultCountDetails"
@alterResultCountDetails="alterResultCountDetails" @alterResultCountDetails="alterResultCountDetails"
@alertoldSkipCountDetails="alertoldSkipCountDetails" @alertoldSkipCountDetails="alertoldSkipCountDetails"
:buttonOperationList="operationButtonsDetail" :buttonOperationList_left="operationButtonsDetail"
></curren-Drawer> ></curren-Drawer>
<!-- 明细查询页面 --> <!-- 明细查询页面 -->
<filterForDetailPage <filterForDetailPage

6
PC/InterFace.Dash/src/views/menuList/ReceiptMstr.vue

@ -23,8 +23,8 @@
:primarySearchOption="primarySearchOption" :primarySearchOption="primarySearchOption"
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:buttonOperationList="operationButtonsTable" :buttonOperationList_left="operationButtonsTable"
></tablePagination> ></tablePagination>
<curren-Drawer <curren-Drawer
ref="currenDrawer_Ref" ref="currenDrawer_Ref"
@ -45,7 +45,7 @@
:MaxResultCount="MaxResultCountDetails" :MaxResultCount="MaxResultCountDetails"
@alterResultCountDetails="alterResultCountDetails" @alterResultCountDetails="alterResultCountDetails"
@alertoldSkipCountDetails="alertoldSkipCountDetails" @alertoldSkipCountDetails="alertoldSkipCountDetails"
:buttonOperationList="operationButtonsDetail" :buttonOperationList_left="operationButtonsDetail"
></curren-Drawer> ></curren-Drawer>
<!-- 明细查询页面 --> <!-- 明细查询页面 -->
<filterForDetailPage <filterForDetailPage

6
PC/InterFace.Dash/src/views/menuList/ReturnMstr.vue

@ -23,8 +23,8 @@
:primarySearchOption="primarySearchOption" :primarySearchOption="primarySearchOption"
@overallSearchFormClick="overallSearchFormClick" @overallSearchFormClick="overallSearchFormClick"
:httpOverallSearchData="httpOverallSearchData" :httpOverallSearchData="httpOverallSearchData"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick_left="buttonOperationClick_left"
:buttonOperationList="operationButtonsTable" :buttonOperationList_left="operationButtonsTable"
></tablePagination> ></tablePagination>
<curren-Drawer <curren-Drawer
ref="currenDrawer_Ref" ref="currenDrawer_Ref"
@ -45,7 +45,7 @@
:MaxResultCount="MaxResultCountDetails" :MaxResultCount="MaxResultCountDetails"
@alterResultCountDetails="alterResultCountDetails" @alterResultCountDetails="alterResultCountDetails"
@alertoldSkipCountDetails="alertoldSkipCountDetails" @alertoldSkipCountDetails="alertoldSkipCountDetails"
:buttonOperationList="operationButtonsDetail" :buttonOperationList_left="operationButtonsDetail"
></curren-Drawer> ></curren-Drawer>
<!-- 明细查询页面 --> <!-- 明细查询页面 -->
<filterForDetailPage <filterForDetailPage

Loading…
Cancel
Save