feiyue.teng

申报数据编辑页面开发

......@@ -143,5 +143,46 @@ export function exportDeclareData(data) {
});
}
//获取客户列表
export function getCustomerList(data) {
return request({
url: '/bus-customer/customers/getCustomerList',
method: 'post',
data:{
"pageIndex": 1,
"pageSize": 1000,
},
})
}
//获取口岸表数据
export function getPortList(data) {
return request({
url: '/bus-customer/portInfo/getPortList',
method: 'post',
data:{
"pageIndex": 1,
"pageSize": 1000,
},
})
}
//获取申报信息
export function getDeclareData(data) {
return request({
url: '/bus-customer/declareData/get/'+data.declareId,
method: 'get',
params: data,
})
}
//更新申报信息
export function updateDeclareData(data) {
return request({
url: '/bus-customer/declareData/update',
method: 'post',
data
})
}
......
......@@ -303,7 +303,9 @@ export default {
},
pageSizes: {
type: Array,
default: [10, 20, 30, 40, 50, 100],
default(){
return [10, 20, 30, 40, 50, 100]
},
},
expandRowKeys: {
type: Array,
......@@ -436,8 +438,10 @@ export default {
}
this.$nextTick(() => {
if (table) {
console.log('debug==',tableBody.clientHeight,this.maxHeight);
table.style.maxHeight = this.maxHeight;
tableBody.clientHeight >= this.maxHeight
tableBody.clientHeight >= parseInt(this.maxHeight)
? (table.style.height = this.maxHeight - 40 + "px")
: (table.style.height = tableBody.clientHeight + "px");
this.$refs.tables.doLayout();
......
......@@ -24,7 +24,7 @@ router.beforeEach((to, from, next) => {
store.dispatch('GetInfo').then((res) => {
// if (res.success) {
store.dispatch('GenerateRoutes').then(accessRoutes => {
store.dispatch("GetDict", ['DECLARE_F_FLAG', 'MEASUREMENT_UNIT', 'RECEIPT_STATUS', 'DECLARE_APPTYPE', 'CURRENCY', 'DECLARE_STATISTICS_FLAG', 'ORDER_DECLARATION_PARTY','APP_STATUS']);
store.dispatch("GetDict", ['DECLARE_F_FLAG', 'MEASUREMENT_UNIT','PACKAGE_TYPE_CODE', 'RECEIPT_STATUS', 'DECLARE_APPTYPE', 'CURRENCY','COUNTRY_REGION_CODE', 'DECLARE_STATISTICS_FLAG', 'ORDER_DECLARATION_PARTY','APP_STATUS']);
// 根据roles权限生成可访问的路由表
router.addRoutes(accessRoutes) // 动态添加可访问路由表
next({ ...to, replace: true }) // hack方法 确保addRoutes已完成
......
......@@ -94,7 +94,13 @@ export const constantRoutes = [
name: 'ReportingData',
meta: { title: '申报数据管理', icon: 'upload' }
},
{
path: '/editReportingData',
component: (resolve) => require(['@/views/editReportingData/index'], resolve),
hidden: true,
name: 'EditReportingData',
meta: { title: '申报数据编辑', icon: 'edit' }
},
]
},
{
......
This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
......@@ -310,6 +310,13 @@
</div>
</TablePopover>
</template>
<template slot="optionColumn">
<el-table-column align="left" label="操作" width="100">
<template slot-scope="scope">
<el-button type="text" @click="update(scope.row)"> 修改 </el-button>
</template>
</el-table-column>
</template>
</Table>
<DialogVue
:outerVisible="outerVisible"
......@@ -463,7 +470,7 @@ export default {
exportDeclareLoading:false,
},
textareaVisible: {},
tableMaxheight: 653,
tableMaxheight: null,
outerVisible: false,
dropdownName: "一键申报",
dropdownCode: "full",
......@@ -477,7 +484,10 @@ export default {
// this.getCancellationReasons()
},
mounted() {
this.tableMaxheight = window.innerHeight - 300;
this.tableMaxheight = window.innerHeight - 355;
window.addEventListener('resize',()=>{
this.tableMaxheight = window.innerHeight - 355;
},false)
},
watch: {
$route(val, oldval) {
......@@ -639,10 +649,8 @@ export default {
// }
this.search(1);
this.outerVisible = false;
this.$nextTick(()=>{
window.location.reload()
})
this.tableMaxheight = window.innerHeight - 355;
this.$forceUpdate()
},
popoverChange(val) {
console.log(val);
......@@ -785,8 +793,13 @@ export default {
cancelRevoke(){
this.loadings.dropDownLoading = false;
this.revokeVisible = false
}
},
update(val) {
this.$router.push({
name: "EditReportingData",
params: { data: val },
});
},
},
};
......