Commit e319119e by yangxiaolei

节假日管理

parent 822d817a
import Api from '~/service/Api';
import { getTrnNameByInr } from "~/service/business/common";
import moment from 'moment';
export default {
methods: {
async handleSearch() {
let opndatfrom = this.model.infcon.opndatfrom;
if (!opndatfrom || opndatfrom == '') {
this.$notify.error({ title: '错误', message: '查询开始日期必输!' });
return;
}
let opndatto = this.model.infcon.opndatto;
if (!opndatto || opndatto == '') {
this.$notify.error({ title: '错误', message: '查询结束日期必输!' });
return;
}
let params = {
...this.model.infcon,
seadocflg: this.model.seadocflg,
seagodcod: this.model.seagodcod,
pageIndex: this.pagination.pageIndex,
pageSize: this.pagination.pageSize,
opndatfrom:moment(opndatfrom).format('YYYY-MM-DD'),
opndatto:moment(opndatto).format('YYYY-MM-DD'),
};
let rtnmsg = await Api.post('/service/infled/getList', params);
if (rtnmsg.respCode == SUCCESS) {
this.stmData.data = [];
this.stmData.data = rtnmsg.data.list;
// debugger
this.pagination.total = rtnmsg.data.total;
} else {
this.$notify.error({ title: '错误', message: '服务请求失败!' });
}
},
async handleReset() {
this.model.sealcrtyp = '';
this.model.infcon.opndatfrom = new Date();
this.model.infcon.opndatto = new Date();
this.model.infcon.seaownref = '';
this.model.infcon.seashgref = '';
this.model.infcon.seaamtfr = '';
this.model.infcon.seasta = '';
this.model.infcon.seacur = '';
this.model.infcon.pty.extkey = '';
this.model.infcon.pty.nam = '';
this.model.infcon.usr.extkey = '';
this.model.infcon.seaamtto = '';
this.model.infcon.searol = '';
this.model.infcon.nam = '';
this.model.infcon.seapty = '';
this.model.infcon.searef = '';
},
// pageSize改变
handleSizeChange(val) {
console.log(`每页 ${val} 条`);
this.pagination.pageIndex = 1;
this.pagination.pageSize = val;
this.handleSearch();
},
// 页码改变
handleCurrentChange(val) {
console.log(`当前页: ${val}`);
this.pagination.pageIndex = val;
this.handleSearch();
},
// 详情
async details(row) {
const params = {
//根据xx字段 查询详情表的数据
inr:row.inr,
userId: window.sessionStorage.userId || 'ZL',
ownref: row.ownref,
};
const res = await Api.post('/service/infled/getDetail', params);
if (res.respCode === SUCCESS) {
this.trnData.data = res.data;
}
},
// 关闭详情弹框
closeDetailsDialog(refId) {
this.$refs[refId].doClose();
console.log('close');
},
// 处理
async handler(row) {
this.initdialog = true;
this.currentHandleRow = row
const params = {
//根据xx字段 查询处理的数据
ownref: row.ownref,
};
const res = await Api.post('/service/infled/dealWithByOwnref', params);
if (res.respCode === SUCCESS) {
if (res.data) {
this.handlerDataList = []
Object.keys(res.data).map((item) => {
this.handlerDataList.push({
label: item,
value: res.data[item]
})
})
}
}
},
handleClick (btn) {
if (btn.value === 'N') {
return
}
let filterRoute = this.btnRouteMap.filter((item) => {
return item.label === btn.label
})
this.$router.history.push({
path: filterRoute[0].route,
query: {
inr: this.currentHandleRow.inr
}
});
this.initdialog = false;
},
// 关闭处理弹框
closeHandlerDialog() {
this.initdialog = false;
},
/**
* 打开详情页面
* @param {string} inr
*/
display(inr) {
getTrnNameByInr({ inr }).then((res) => {
if (res.respCode == SUCCESS) {
const trnName = res.data.toLowerCase();
let viewurl = "/#/display/" + trnName + "?trn=" + inr
window.open(viewurl, 'newwindow', 'height=1500,width=1200,top=100,left=100,toolbar=no,resizable=no,menubar=no,location=no, status=no');
}
});
},
toLetopn() {
// 点击开立,清空从待经办进来的时候带的行参数
localStorage.setItem('row_letopn', null)
localStorage.setItem('review_letopn',null)
this.$router.history.push('/business-new/letopn');
},
toLetnot() {
this.$router.history.push('/business-new/letnot');
},
toLetdrw() {
this.$router.history.push('/business-new/letdrw');
},
toLetrsv() {
this.$router.history.push('/business-new/letrsv');
},
},
};
export default class Currency {
constructor () {
this.data = {
currCode: '',//币种代码
custCurrCode: '',//自定义币种代码
currSymbol:'',//币种代码2
currEnName: '',
currCnName: '',
isOften: '',
currDecimalBit: '',
quotatConvtUCd: '',
exgRatMaxPermitChgPct: '',
}
}
}
\ No newline at end of file
export default class Holiday {
constructor() {
this.data = {
month: new Date(),//月份
currCode: '156',//币种代码
currSymbol: '',//币种符号
calendarDt: '',//日历日期
}
}
}
export default class OperateParams {
constructor() {
this.data = {
operateData: '', // 操作数据
operorNo: '', //操作人编号
operorName: '', //操作人姓名
txCode: '', //交易代码
oprTypeCode: '', //操作类型代码 A-新增 U-修改 D-删除
oprRecordPrKey: '', //操作记录主键
summary: '', //摘要
oprNo: '', //操作编号
}
}
}
export default class QueryRequest {//分页查询条件
constructor() {
this.data = {
current: 1, // 当前页
size: 20, // 每页的数量
orders:[], //排序信息
data: null
}
}
}
\ No newline at end of file
<!-- author cuibo -->
<template>
<c-select v-model="model" v-bind="$attrs" placeholder="请选择币种" filterable v-bind:disabled="isDisable" @change="handleChange"
popper-class="m-currency-dropdown">
<el-option v-for="item in codes" :key="item.value" :label="item.label" :value="item.value" :disabled="disabledList.indexOf(item.value)!== -1">
</el-option>
</c-select>
</template>
<script>
import QueryRequest from "../../model/QueryRequest";
import Currency from "../../model/Currency";
import Select from "../Select"
export default {
components: {
'c-select': Select
},
props: {
value: {
type: [String, Array, Number],
default: undefined
},
disabledList: {
type: Array,
default: function () {
return []
}
},
disabled: {
type: Boolean,
default: false
},
isOften: {
type: Boolean,
default: true
},
},
computed: {
model: {
get() {
return this.value;
},
set(newVal) {
this.$emit("input", newVal);
}
},
isDisable: {
get() {
return this.disabled
}
},
},
data: function() {
return {
codes: [],
list: [],
currencyMap: {}
}
},
created() {
this.handleSearch();
},
methods: {
listCurs(){
return Promise.resolve(null)
},
handleSearch() {
var params = new QueryRequest().data;
params.current = 0;
params.size = 0;
params.data = new Currency().data;
// console.log('this.isOften', this.isOften)
let key = 'curCache'
if (this.isOften === true) {
//查询条件——是常用币种
params.data.isOften = 'Y'
key = key + 'Y'
} else {
params.data = {};
}
let promise;
if (!window[key] || new Date() - window[key].lastTime > 30000) //30s内不超时
{
promise = listCurs(params)
window[key] = {
lastTime: new Date() - 0,
promise
}
} else {
promise = window[key].promise
}
promise
.then(res => {
if (res.code === SUCCESS) {
this.list = res.data;
console.log('list', this.list)
for (var i = 0; i < this.list.length; i++) {
this.codes.push({
value: this.list[i].currCode,
label: this.list[i].currSymbol + '-' + this.list[i].currCnName
});
//利用map遍历list
this.currencyMap[this.list[i].currCode] = JSON.parse(JSON.stringify(this.list[i]))
}
}
})
.catch(error => {
console.log(error);
});
},
handleChange(value) {
//根据value在currencyMap中找到list中的币种对象 返回
this.$emit('update-currency', this.currencyMap[value])
}
}
}
</script>
<template>
<el-select
ref="select"
:title = "tip"
:id="id" v-model="model" v-bind="$attrs" :size="size"
v-on="$listeners" v-bind:disabled="isDisable" :clearable="clearable" @click.native="handleClick" >
<slot></slot>
</el-select>
</template>
<script>
export default {
inject: {
disabledImport: {
default: false
}
},
props: {
value: {
type: [String, Array, Number],
default: undefined
},
disabled: {
type: Boolean,
default: false
},
clearable: {
type: Boolean,
default: true
},
id: {
type: String,
default: ''
},
size: {
type: String,
default: 'small'
}
},
data: function () {
return {
tip: ''
}
},
computed: {
model: {
get() {
return this.value
},
set(newVal) {
this.$emit('input', newVal)
}
},
mode() {
return this.$store.state.Status.mode
},
isDisable: {
get() {
if (this.disabledImport && !this.disabled) {
return false
}
return this.mode === 'display' || this.disabled
}
},
highlight () {
return this.$store.state.Status.highlights.indexOf(this.id) !== -1
}
},
created: function () {
this.updateTip()
},
watch: {
value: function () {
this.updateTip()
}
},
methods: {
updateTip: function () {
this.$nextTick(() => {
if (this.$refs.select) {
this.tip = this.$refs.select.selectedLabel || this.$refs.select.query || ''
}
})
},
handleClick: function (e) {
let ev = new Event("click", {"bubbles": true})
let node = e.target
if (node.parentElement) {
node.parentElement.dispatchEvent(ev)
}
}
}
}
</script>
<style>
/* .el-select.highlight .el-input .el-input__inner {
border-color: red;
} */
</style>
\ No newline at end of file
......@@ -19,6 +19,7 @@ import CustomComponent from "./components";
import vuefunc from "./utils/vuefunc";
import "./permission";
import EventService,{LOGIN,LOGOUT} from "~/service/EventService";
import Api from "./service/Api";
window.SUCCESS = "AAAAAA";
......@@ -40,6 +41,8 @@ EventService.on(LOGOUT,()=>{
resetCache();
});
Vue.prototype.$Api = Api
new Vue({
el: "#app",
store,
......@@ -47,3 +50,4 @@ new Vue({
router: RootRouter,
render: (h) => h(App),
});
......@@ -49,6 +49,7 @@ const Business = [
{ path: 'infbrd', component: () => import('~/business/infbrd/views'), name: 'Infbrd', meta: { title: '进口信用证单据入口交易' } },
{ path: 'inflid', component: () => import('~/business/inflid/views'), name: 'Inflid', meta: { title: '信用证入口交易' } },
{ path: 'infled', component: () => import('~/business/infled/views'), name: 'Infled', meta: { title: '出口信用证交易查询' } },
{ path: 'holiday', component: () => import('~/business/holiday/views'), name: 'holiday', meta: { title: '节假日管理' } },
{ path: 'letame', component: () => import('~/business/letame/views'), name: 'Letame', meta: { title: '出口信用证修改' } },
{ path: 'letcan', component: () => import('~/business/letcan/views'), name: 'Letcan', meta: { title: '出口信用证注销' } },
{ path: 'letnot', component: () => import('~/business/letnot/views'), name: 'Letnot', meta: { title: '出口信用证预通知' } },
......
......@@ -190,6 +190,7 @@ export default {
// { inifrm: "infpty", ininam: "客户信息查询", pntmiu: "10" },
// { inifrm: "infpta", ininam: "客户地址查询", pntmiu: "10" },
{ inifrm: "inholiday", ininam: "节假日管理", pntmiu: "10" },
{ inifrm: "infact", ininam: "账号信息查询", pntmiu: "10" },
{ inifrm: "infapf", ininam: "报文格式信息查询", pntmiu: "10" },
{ inifrm: "infatp", ininam: "交易模式配置查询", pntmiu: "10" },
......
......@@ -126,6 +126,7 @@ export default {
},
addTags() {
const { name } = this.$route;
console.log("this.$route=>",this.$route)
if (name) {
this.$store.dispatch("TagsView/addView", this.$route);
}
......
<template>
<el-container
style="background-color: #e8e8e8; margin: 0; padding-bottom: 8px"
style="background-color: #e8e8e8;height: 100%;
position: relative; margin: 0; padding-bottom: 8px"
>
<el-header style="padding: 0">
<headerCom></headerCom>
......@@ -102,7 +103,8 @@
v-show="dragStatus !== 0"
></div>
</vue-draggable-resizable>
<el-container>
<el-container style="height: 100%;
position: relative;">
<el-aside width="240px" style="background-color: white">
<sideMenu></sideMenu>
</el-aside>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment