不等比缩放
This commit is contained in:
@@ -34,6 +34,7 @@
|
||||
|
||||
<div class="admin_table_content" ref="historyTable">
|
||||
<a-table
|
||||
@resizeColumn="handleResizeColumn"
|
||||
:columns="columns"
|
||||
:data-source="dataList"
|
||||
:scroll="{ y: historyTableHeight }"
|
||||
@@ -146,6 +147,10 @@ export default defineComponent({
|
||||
title: 'Create Time',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
// width: 150,
|
||||
// minWidth: 100,
|
||||
// maxWidth: 200,
|
||||
// resizable: true,
|
||||
dataIndex: "createTime",
|
||||
key: "createTime",
|
||||
},
|
||||
@@ -153,6 +158,10 @@ export default defineComponent({
|
||||
title: 'Occupation',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
// width: 150,
|
||||
// minWidth: 100,
|
||||
// maxWidth: 200,
|
||||
// resizable: true,
|
||||
dataIndex: "occupation",
|
||||
key: "occupation",
|
||||
},
|
||||
@@ -160,6 +169,8 @@ export default defineComponent({
|
||||
title: 'Trial Order Id',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
// width: 150,
|
||||
// resizable: true,
|
||||
dataIndex: "trialOrderId",
|
||||
key: "trialOrderId",
|
||||
},
|
||||
@@ -202,6 +213,9 @@ export default defineComponent({
|
||||
pageSize: 10,
|
||||
total: 0,
|
||||
historyTableHeight: 0,
|
||||
handleResizeColumn: (w:any, col:any) => {
|
||||
col.width = w;
|
||||
},
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
:data-source="dataList"
|
||||
:scroll="{ y: historyTableHeight}"
|
||||
@change="changePage"
|
||||
@resizeColumn="handleResizeColumn"
|
||||
:pagination="{
|
||||
showSizeChanger: true,
|
||||
current: currentPage,
|
||||
@@ -30,27 +31,28 @@
|
||||
<script lang="ts">
|
||||
import { defineComponent, ref, createVNode, computed } from "vue";
|
||||
import { Https } from "@/tool/https";
|
||||
import type { TableColumnsType } from 'ant-design-vue';
|
||||
import { setCookie, getCookie, WriteCookie } from "@/tool/cookie";
|
||||
export default defineComponent({
|
||||
components: {
|
||||
},
|
||||
setup() {
|
||||
let renameData: any = ref({}); //修改名字选中的数据
|
||||
const columns: any = computed(() => {
|
||||
return [
|
||||
const columns: any = ref<TableColumnsType>([
|
||||
{
|
||||
title: 'Email',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
width: 30,
|
||||
width: 50,
|
||||
|
||||
dataIndex: "email",
|
||||
key: "email",
|
||||
fixed: 'left',
|
||||
},
|
||||
{
|
||||
title: 'User Id',
|
||||
align: "center",
|
||||
width: 30,
|
||||
width: 50,
|
||||
|
||||
dataIndex: "id",
|
||||
key: "id",
|
||||
},
|
||||
@@ -58,7 +60,8 @@ export default defineComponent({
|
||||
title: 'User Name',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
width: 30,
|
||||
width: 50,
|
||||
|
||||
dataIndex: "userName",
|
||||
key: "userName",
|
||||
},
|
||||
@@ -66,14 +69,16 @@ export default defineComponent({
|
||||
title: 'Given Name',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
width: 30,
|
||||
width: 50,
|
||||
|
||||
dataIndex: "givenName",
|
||||
key: "givenName",
|
||||
},
|
||||
{
|
||||
title: 'Create Time',
|
||||
align: "center",
|
||||
width: 30,
|
||||
width: 50,
|
||||
|
||||
dataIndex: "createTime",
|
||||
key: "createTime",
|
||||
},
|
||||
@@ -81,7 +86,8 @@ export default defineComponent({
|
||||
title: 'Title',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
width: 30,
|
||||
width: 50,
|
||||
//
|
||||
dataIndex: "title",
|
||||
key: "title",
|
||||
},
|
||||
@@ -89,14 +95,12 @@ export default defineComponent({
|
||||
title: 'Country',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
width: 30,
|
||||
dataIndex: "country",
|
||||
key: "country",
|
||||
fixed: 'right',
|
||||
},
|
||||
|
||||
];
|
||||
});
|
||||
]
|
||||
);
|
||||
let dataList: any = ref([]);
|
||||
let userInfo: any = {};
|
||||
return {
|
||||
@@ -104,6 +108,11 @@ export default defineComponent({
|
||||
dataList,
|
||||
renameData,
|
||||
userInfo,
|
||||
handleResizeColumn: (w:any, col:any) => {
|
||||
console.log(col,w);
|
||||
|
||||
col.width = w;
|
||||
},
|
||||
};
|
||||
},
|
||||
data() {
|
||||
|
||||
@@ -81,6 +81,7 @@ export default defineComponent({
|
||||
title: 'Email',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
|
||||
width: 100,
|
||||
dataIndex: "email",
|
||||
key: "email",
|
||||
@@ -90,6 +91,7 @@ export default defineComponent({
|
||||
align: "center",
|
||||
width: 70,
|
||||
dataIndex: "updateTime",
|
||||
|
||||
key: "updateTime",
|
||||
// customRender: (record: any) => {
|
||||
// let time = formatTime(
|
||||
@@ -103,6 +105,7 @@ export default defineComponent({
|
||||
title: 'State',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
|
||||
width: 70,
|
||||
dataIndex: "status",
|
||||
key: "status",
|
||||
@@ -122,6 +125,7 @@ export default defineComponent({
|
||||
title: 'Address',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
|
||||
width: 70,
|
||||
dataIndex: "country",
|
||||
key: "country",
|
||||
@@ -130,6 +134,7 @@ export default defineComponent({
|
||||
title: 'Surname',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
|
||||
width: 70,
|
||||
dataIndex: "surname",
|
||||
key: "surname",
|
||||
@@ -138,6 +143,7 @@ export default defineComponent({
|
||||
title: 'Name',
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
|
||||
width: 70,
|
||||
dataIndex: "userName",
|
||||
key: "userName",
|
||||
@@ -150,6 +156,7 @@ export default defineComponent({
|
||||
width: 70,
|
||||
// slots:{customRender:'action'}
|
||||
Operations: true,
|
||||
|
||||
},
|
||||
];
|
||||
});
|
||||
|
||||
@@ -278,6 +278,7 @@ export default defineComponent({
|
||||
watch:{
|
||||
designItemDetail:{
|
||||
handler: async function(newVal,oldVal) {
|
||||
|
||||
let designItemDetail = JSON.parse(JSON.stringify(this.store.state.DesignDetailModule.designItemDetail))
|
||||
this.ifSubmit = designItemDetail.ifSubmit?designItemDetail.ifSubmit:false
|
||||
if(newVal.clothes.length == 0){
|
||||
@@ -866,10 +867,11 @@ export default defineComponent({
|
||||
// if(this.designItemDetail.clothes[this.designItemDetail.clothes.legnth-1] && !this.designItemDetail.clothes[this.designItemDetail.clothes.legnth-1].id){
|
||||
// this.designItemDetail.clothes.split(this.designItemDetail.clothes.legnth-1,1)
|
||||
// }
|
||||
if(data.clothes[data.clothes.legnth-1] && !data.clothes[data.clothes.legnth-1].id){
|
||||
data.clothes.split(data.clothes.legnth-1,1)
|
||||
if(data.designSingleItemDTOList[data.designSingleItemDTOList.legnth-1] && !data.designSingleItemDTOList[data.designSingleItemDTOList.legnth-1].id){
|
||||
data.designSingleItemDTOList.split(data.designSingleItemDTOList.legnth-1,1)
|
||||
}
|
||||
this.store.commit("setDesignItemDetail", designItemDetail);
|
||||
console.log(123);
|
||||
this.store.commit("setDesignPreviewData", data);
|
||||
this.setRevocation(designItemDetail,data)
|
||||
this.deleteItemShow = false
|
||||
|
||||
Reference in New Issue
Block a user