TC 수정 반영

This commit is contained in:
kimre
2022-07-18 01:06:10 +09:00
parent e8328fef2c
commit 2bfa07c17f
30 changed files with 2446 additions and 2066 deletions

View File

@@ -52,7 +52,7 @@
<div class="info">
<div class="count"> <span>{{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }}</span>
<div class="select_box NumberSe">
<select name="" id="perPage" v-model="perPageCnt" @keyup.enter="search">
<select name="" id="perPage" v-model="perPageCnt" @change="changePerPage()">
<option value="20">20</option>
<option value="50">50</option>
<option value="100">100</option>
@@ -93,7 +93,6 @@ import customGrid from '@/components/CustomGrid';
import commonModal from "@/components/modal/commonModal";
import NumberRegPop from '../components/NumberRegPop';
import NumberDetailPop from "@/modules/sendNumMgt/components/NumberDetailPop";
// import sendNumMgtApi from "@/modules/sysMgt/service/sendNumMgtApi";
import sendNumMgtApi from '../service/sendNumMgtApi';
@@ -128,17 +127,16 @@ export default {
statType: [],
cate2Code: "",
totalItems: 0,
searchType5: '',
searchType4: 'regNo',
searchType3: '',
searchType2: '',
searchType1: '',
isFirst:true,
// 테이블 리스트 데이터
perPageCnt: 50,
grid: {
url: '/api/v1/bo/sendNumMgt/numberList',
perPage: 20,
pagePerRows: 50,
pagination: true,
isCheckbox: true,
initialRequest: false,
@@ -185,7 +183,6 @@ export default {
searchType2: '',
searchType3: '',
searchType4: '',
searchType5: '',
searchText1: '',
pagePerRows: '',
page: ''
@@ -201,7 +198,8 @@ export default {
commonModal,
},
created() {
// const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
// this.grid.pagePerRows = 50
this.isFirst=true
},
destroyed() {
this.$store.commit('searchcondition/updateSearchCondition', {
@@ -212,9 +210,7 @@ export default {
searchType2: '',
searchType3: '',
searchType4: '',
searchText1: '',
pagePerRows: '',
page: ''
searchText1: ''
}
});
},
@@ -222,6 +218,8 @@ export default {
let page = 1;
// 페이지 정보 및 검색 조건
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
console.log('getCondition : ' + getCondition);
// store에 저장된 페이지 정보 및 검색 조건을 불러오기
let isKeep = false;
if (getCondition) {
@@ -231,7 +229,6 @@ export default {
isKeep = true;
}
this.search(isKeep);
},
methods: {
search: function (isKeep) {
@@ -240,10 +237,13 @@ export default {
this.grid.params.searchType2 = this.searchType2
this.grid.params.searchType3 = this.searchType3
this.grid.params.searchType4 = this.searchType4
this.grid.params.searchType5 = this.searchType5
this.grid.pagePerRows = this.perPageCnt
console.log(this.$data)
if(this.isFirst){
this.grid.pagePerRows = 50
}
this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData();
this.isFirst=false
},
sendStoreData: function () {
const getP = this.$refs.table.getPagination();
@@ -254,7 +254,7 @@ export default {
params: this.grid.params
});
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
// const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
},
numberRegPopOpen: function () {
this.$refs.numberRegPop.numberRegPopopen();
@@ -321,18 +321,21 @@ export default {
this.numberDelete();
}
},
changePerPage: function () { // 페이지당 조회할 개수
this.grid.pagePerRows = this.perPageCnt;
},
},
// beforeRouteLeave(to, from, next) {
//
// const getP = this.$refs.table.getPagination();
// console.log("==========getP : " + getP._currentPage);
// this.$store.commit('searchcondition/updateSearchCondition', {
// page: getP._currentPage,
// perPage: this.perPageCnt,
// params: this.grid.params
// });
// // 라우트 하기전 실행
// next();
// }
beforeRouteLeave(to, from, next) {
const getP = this.$refs.table.getPagination();
console.log("==========getP : " + getP._currentPage);
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,
params: this.grid.params
});
// 라우트 하기전 실행
next();
}
};
</script>

View File

@@ -35,7 +35,7 @@
<div class="info">
<div class="count"> <span> {{ totalItems.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ',') }} </span>
<div class="select_box NumberSe">
<select name="" id="perpage" v-model="perPageCnt" @keyup.enter="search">
<select name="" id="perpage" v-model="perPageCnt" @change="changePerPage()">
<option v-for="option in options" v-bind:value="option.value" v-bind:key="option.value">{{
option.text
}}
@@ -79,7 +79,7 @@ export default {
searchType1: '',
searchType2: 'custNm',
// 테이블 리스트 데이터
perPageCnt: 20,
perPageCnt: 50,
options: [
{text: '20', value: 20},
{text: '50', value: 50},
@@ -87,7 +87,7 @@ export default {
],
grid: {
url: '/api/v1/bo/sendNumMgt/profileList',
perPage: 20,
pagePerRows: 50,
pagination: true,
isCheckbox: false,
initialRequest: false,
@@ -105,13 +105,13 @@ export default {
],
columns: [
{name: 'no', header: 'NO', align: 'center', width: 50},
{name: 'custNm', header: '고객사명', align: 'center', width: 200},
{name: 'bregNo', header: '사업자번호', align: 'center', width: 100},
{name: 'sendProfile', header: '발신프로필', align: 'center', width: 100},
{name: 'sendProfileKey', header: '발신프로필key', align: 'center', width: 100},
{name: 'stat', header: '상태', width: 100, cls: 'td_line'},
{name: 'regDt', header: '등록일', align: 'center', width: 150},
{name: 'no', header: 'NO', align: 'center', width: '5%'},
{name: 'custNm', header: '고객사명', align: 'center', width: '15%'},
{name: 'bregNo', header: '사업자번호', align: 'center', width: '15%'},
{name: 'sendProfile', header: '발신프로필', align: 'center', width: '15%'},
{name: 'sendProfileKey', header: '발신프로필key', align: 'center', width: '20%'},
{name: 'stat', header: '상태', width: '15%', cls: 'td_line'},
{name: 'regDt', header: '등록일', align: 'center', width: '15%'},
],
noDataStr: '검색 결과가 없습니다.',
params: {
@@ -139,14 +139,16 @@ export default {
},
created() {
},
mounted() {
let page = 1;
// 페이지 정보 및 검색 조건
const getCondition = this.$store.getters['searchcondition/getSearchCondition'];
console.log('getCondition : ' + getCondition);
// store에 저장된 페이지 정보 및 검색 조건을 불러오기
let isKeep = false;
if (getCondition) {
this.grid.pagePerRows = 50;
this.grid.pagePerRows = getCondition.perPage;
this.grid.params = getCondition.params;
page = getCondition.page;
isKeep = true;
@@ -155,17 +157,14 @@ export default {
},
methods: {
search: function (isKeep) {
console.log(this.grid.params);
this.grid.params.searchType1 = this.searchType1
this.grid.params.searchType2 = this.searchType2
// perPageCnt
this.grid.pagePerRows = this.perPageCnt;
this.$refs.table.search(this.grid.params, isKeep);
this.sendStoreData();
},
sendStoreData: function () {
const getP = this.$refs.table.getPagination();
console.log("==========getP : " + getP);
console.log("==========getP : " + getP._currentPage);
this.$store.commit('searchcondition/updateSearchCondition', {
page: getP._currentPage,
perPage: this.perPageCnt,