test
wj 1 year ago
parent 9500470cd2
commit c2c4c4ea09

@ -18,7 +18,7 @@ export default {
}
}
</script>
<style>
<style lang="scss">
/* 滚动条样式 */
::-webkit-scrollbar {
@ -73,10 +73,30 @@ export default {
.d-block{
display: block;
}
</style>
<style lang="scss">
//tabel
//tabel
.el-table th.gutter {
display: table-cell !important;
}
.form-w-90{
.el-form .el-form-item__label {
word-break: keep-all; /* 不换行 */
white-space: nowrap;
}
.el-date-editor.el-input, .el-date-editor.el-input__inner, .el-range-editor.el-input__inner, .el-range-editor--mini.el-input__inner {
width: 100%;
}
.el-form .el-input,.el-select,.el-form .el-input-number,.el-form .el-textarea {
width: 90%;
}
.el-form .el-input-number .el-input {
width: 100%;
}
}
</style>
<style lang="scss">
</style>

@ -56,6 +56,13 @@ Vue.prototype.selectDictLabels = selectDictLabels
Vue.prototype.download = download
Vue.prototype.handleTree = handleTree
//自定义组件
import invSelect from "@/views/components/invSelect/invSelect.vue";
import mainActionSelect from "@/views/components/mainActionSelect/index.vue";
import thirdSysSelect from "@/views/components/thirdSysSelect/index.vue";
import actionSelect from "@/views/components/actionSelect/index.vue";
import deptSelect from "@/views/components/deptSelect/index.vue";
// 全局组件挂载
Vue.component('DictTag', DictTag)
Vue.component('Pagination', Pagination)
@ -65,6 +72,11 @@ Vue.component('FileUpload', FileUpload)
Vue.component('ImageUpload', ImageUpload)
Vue.component('ImagePreview', ImagePreview)
Vue.component("cusEditor", cusEditor)
Vue.component("invSelect", invSelect)
Vue.component("mainActionSelect", mainActionSelect)
Vue.component("thirdSysSelect", thirdSysSelect)
Vue.component("actionSelect", actionSelect)
Vue.component("deptSelect", deptSelect)
Vue.use(directive)
Vue.use(plugins)
@ -82,7 +94,25 @@ DictData.install()
*/
// 修改 el-dialog 默认点击遮照为不关闭
Element.Dialog.props.closeOnClickModal.default = false
Element.Dialog.props.closeOnClickModal = {type: Boolean, default: false}
Element.Dialog.props.appendToBody = {type: Boolean, default: true}
Element.Table.props.border = {type: Boolean, default: true}
Element.Table.props.minHeight = {type: String | Number, default: "250"}
Element.Table.props.fit = {type: Boolean, default: true}
Element.TableColumn.props.showOverflowTooltip = {type: Boolean, default: true}
Element.DatePicker.props.firstDayOfWeek = {type: Number, default: 1}
Element.Select.methods.deleteSelected =
function deleteSelected(event) {
event.stopPropagation();
// 改动在这,原始的是这样 var value = this.multiple ? [] : '';
var value = this.multiple ? [] : null;
this.$emit("input", value);
this.emitChange(value);
this.visible = false;
this.$emit("clear");
};
Vue.use(Element, {
size: Cookies.get('size') || 'mini' // set element-ui default size

@ -0,0 +1,19 @@
export const msgType = {
PUT_IN_APPLY: {key: "PUT_IN_APPLY", value: 1, desc: "入院物资申请"},
ORDER_AUDIT: {key: "ORDER_AUDIT", value: 2, desc: "单据审核"},
INVOICE_CONFIRM: {key: "INVOICE_CONFIRM", value: 3, desc: "单据发票确认"},
CERT_AUDIT: {key: "CERT_AUDIT", value: 5, desc: "资质审核"},
USE_AUDIT: {key: "USE_AUDIT", value: 6, desc: "领用单审核"},
BUY_APPLY_AUDIT: {key: "USE_AUDIT", value: 7, desc: "申购单审核"},
PROCUREMENT_AUDIT: {key: "USE_AUDIT", value: 8, desc: "采购单审核"},
}
export const pushStatus = {
NOT_PUSHED: {key: "NOT_PUSHED", value: 1, desc: "未推送"},
PUSH_SUCCESS: {key: "PUSH_SUCCESS", value: 2, desc: "推送成功"},
PUSH_FAIL: {key: "PUSH_FAIL", value: 3, desc: "推送失败"},
}
export const dealStatus = {
NOT_CONFIRMED: {key: "NOT_CONFIRMED", value: 1, desc: "未处理"},
CONFIRMED: {key: "CONFIRMED", value: 2, desc: "已处理"},
}

@ -60,7 +60,7 @@ service.interceptors.request.use(config => {
const s_url = sessionObj.url; // 请求地址
const s_data = sessionObj.data; // 请求数据
const s_time = sessionObj.time; // 请求时间
const interval = 1000; // 间隔时间(ms),小于此时间视为重复提交
const interval = 300; // 间隔时间(ms),小于此时间视为重复提交
if (s_data === requestObj.data && requestObj.time - s_time < interval && s_url === requestObj.url) {
const message = '数据正在处理,请勿重复提交';
console.warn(`[${s_url}]: ` + message)
@ -98,7 +98,7 @@ service.interceptors.response.use(res => {
isRelogin.show = false;
store.dispatch('LogOut').then(() => {
Cookies.remove()
location.href = process.env.VUE_APP_CONTEXT_PATH;
location.href = process.env.VUE_APP_CONTEXT_PATH;
})
}).catch(() => {
isRelogin.show = false;

@ -0,0 +1,52 @@
import {getLocalJoinByUser} from "@/api/basic/busType";
export default {
name: "actionSelect",
props: {value:"",invCode:{required:true},mainAction:null},
data() {
return {
val: '',
list:[],
}
},
watch: {
mainAction(){
this.val = null
this.getList()
},
invCode(){
this.val = null
this.getList()
},
val(newVal) {
this.$emit('update:value', newVal);
},
value(newVal) {
this.val = newVal
},
},
created() {
this.val=this.value
this.getList()
},
methods: {
getList(){
if(!this.invCode){
return
}
let query = {
code: this.invCode,
enable: true,
mainAction: this.mainAction,
vueType: "supInvoice",
};
getLocalJoinByUser(query)
.then((response) => {
this.list = response.data.list || [];
})
.catch(() => {
});
}
}
}

@ -0,0 +1,16 @@
<template>
<el-select v-model="val" :disabled="!invCode" placeholder="请选择单据类型"
style="width: 90%"
clearable>
<el-option
v-for="item in list"
:key="item.name"
:label="item.name"
:value="item.action">
<span style="float: left">{{ item.name }}</span>
</el-option>
</el-select>
</template>
<script src="./index.js">
</script>

@ -0,0 +1,34 @@
import {filterList} from "@/api/system/invWarehouse";
export default {
name: "deptSelect",
props: {value:""},
data() {
return {
val: '',
list:[],
}
},
watch: {
val(newVal) {
this.$emit('update:value', newVal);
},
value(newVal) {
this.val = newVal
},
},
created() {
this.val=this.value
this.getList()
},
methods: {
getList(){
filterList({enable: true}).then(res=>{
if(res.code==20000){
this.list = res.data.list||[]
}
})
}
}
}

@ -0,0 +1,9 @@
<template>
<el-select v-model="val" placeholder="请选择部门" style="width: 90%" clearable>
<el-option v-for="item in list" :key="item.id" :label="item.name" :value="item.code"/>
</el-select>
</template>
<script src="./index.js">
</script>

@ -0,0 +1,48 @@
import {getInvListByUser} from "@/api/system/invWarehouse";
export default {
name: "invSelect",
props: {value: {required: true}, deptCode: null},
data() {
return {
val: '',
list: [],
}
},
watch: {
deptCode() {
this.val = null
this.getList()
},
val(newVal) {
this.$emit('update:value', newVal);
},
value(newVal) {
this.val = newVal
},
},
methods: {
invChange() {
this.$emit('update:value', this.val);
// this.changeValue(this.invCode)
},
getList() {
let query = {
advanceType: 1,
deptCode: this.deptCode
};
getInvListByUser(query)
.then((response) => {
this.list = response.data || [];
})
.catch(() => {
});
},
},
created() {
this.val = this.value
this.getList()
}
}

@ -0,0 +1,16 @@
<template>
<el-select v-model="val" placeholder="请选择所属仓库" clearable
style="width: 90%"
@change="invChange"
>
<el-option
v-for="item in list"
:key="item.name"
:label="item.name"
:value="item.code">
<span style="float: left">{{ item.name }}</span>
</el-option>
</el-select>
</template>
<script src="./invSelect.js"/>

@ -0,0 +1,28 @@
export default {
name: "mainActionSelect",
props: {value:""},
data() {
return {
mainAction: ''
}
},
watch: {
mainAction(newVal) {
this.$emit('update:value', newVal);
},
value(newVal) {
this.mainAction = newVal
},
},
created() {
if(this.value==null){
this.$emit('update:value', '');
}
this.mainAction=this.value
},
methods: {
}
}

@ -0,0 +1,11 @@
<template>
<el-select v-model="mainAction" placeholder="请选择出入库类型" clearable style="width: 90%">
<el-option label="全部" value=""></el-option>
<el-option label="入库" value="WareHouseIn"></el-option>
<el-option label="出库" value="WareHouseOut"></el-option>
</el-select>
</template>
<script src="./index.js">
</script>

@ -0,0 +1,34 @@
import {getBasicThirdSys} from "@/api/basic/basicThirdSys";
export default {
name: "thirdSysSelect",
props: {value:""},
data() {
return {
val: '',
list:[],
}
},
watch: {
val(newVal) {
this.$emit('update:value', newVal);
},
value(newVal) {
this.val = newVal
},
},
created() {
this.val=this.value
this.getList()
},
methods: {
getList(){
getBasicThirdSys({enable: true}).then(res=>{
if(res.code==20000){
this.list = res.data.list||[]
}
})
}
}
}

@ -0,0 +1,9 @@
<template>
<el-select v-model="val" placeholder="请选择第三方系统" style="width: 90%" clearable>
<el-option v-for="item in list" :key="item.id" :label="item.thirdName" :value="item.id"/>
</el-select>
</template>
<script src="./index.js">
</script>

@ -41,7 +41,7 @@
<span class="header d-block">
库存预警
</span>
<span class="d-block mt10" :style="{'font-size': '32px','font-weight': 'bolder',color:'#ef5c3b'}">
<span class="d-block mt10" :style="{'font-size': '32px','font-weight': 'bolder',color:'#FF0000'}">
{{ invMsgCount }}
</span>
</div>
@ -62,7 +62,7 @@
<span class="header d-block">
资质预警
</span>
<span class="d-block mt10" :style="{'font-size': '32px','font-weight': 'bolder',color:'#ef5c3b'}">
<span class="d-block mt10" :style="{'font-size': '32px','font-weight': 'bolder',color:'#FF0000'}">
{{ invMsgCount }}
</span>
</div>
@ -81,7 +81,7 @@
重新加载
</el-button>
<el-button type="text" style="font-size: 15px;color: unset"
@click.stop="linkPage('/pur/auditDelivery')">
@click.stop="linkPage('/system/msg/sysMsgTodo')">
更多
<el-icon class="el-icon-d-arrow-right"/>
</el-button>
@ -111,7 +111,19 @@
width="280"/>
<el-table-column
label="处理状态"
prop="dealStatus"
prop="dealStatusName"
width="120"/>
<el-table-column
label="推送状态"
prop="pushStatusName"
width="120"/>
<el-table-column
label="仓库"
prop="invName"
width="120"/>
<el-table-column
label="部门"
prop="deptName"
width="120"/>
<el-table-column
label="创建时间"
@ -121,7 +133,7 @@
<template slot-scope="scope">
<el-button
type="text"
@click="linkPage('/pur/auditDelivery')"
@click="linkPage('/system/msg/sysMsgTodo')"
>处理
</el-button>
</template>

@ -0,0 +1,68 @@
import {msgType, pushStatus, dealStatus} from "@/utils/enums";
import {sysMsgTodoPage} from "@/api/system/sysMsgTodoApi";
let formQuery = {
page: 1,
limit: 10,
msgType: null,
pushStatus: null,
dealStatus: null,
invCode: null,
deptCode: null,
}
export default {
computed: {
dealStatus() {
return dealStatus
},
pushStatus() {
return pushStatus
},
msgType() {
return msgType
},
},
data() {
return {
showSearch: true,
loading: false,
list: [],
total: 0,
formQuery: {...formQuery}
}
},
created() {
this.getList()
},
methods: {
onSubmit() {
this.formQuery.page = 1
this.getList()
},
onReset() {
this.formQuery = {...formQuery}
this.showSearch = true
this.getList()
},
getList() {
this.loading = true
sysMsgTodoPage(this.formQuery).then(res => {
this.loading = false
if (res.code != 20000) {
this.$message.error(res.message)
return
}
this.list = res.data.list || []
this.total = res.data.total || 0
}).catch(e => {
this.loading = false
this.list = []
this.total = 0
})
}
}
}

@ -0,0 +1,114 @@
<template>
<div>
<el-card>
<el-form v-show="showSearch" class="form-w-90" :model="formQuery" label-width="auto">
<el-row :gutter="20">
<el-col :span="8">
<el-form-item label="消息类型:">
<el-select v-model="formQuery.msgType" clearable>
<el-option v-for="item in msgType" :label="item.desc" :value="item.key"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="推送状态:">
<el-select v-model="formQuery.pushStatus" clearable>
<el-option v-for="item in pushStatus" :label="item.desc" :value="item.key"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="确认状态:">
<el-select v-model="formQuery.dealStatus" clearable>
<el-option v-for="item in dealStatus" :label="item.desc" :value="item.key"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="部门:">
<deptSelect :value.sync="formQuery.deptCode"/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="仓库:">
<invSelect :deptCode="formQuery.deptCode" :value.sync="formQuery.invCode"/>
</el-form-item>
</el-col>
<!-- <el-col :span="8">-->
<!-- <el-form-item label="部门:">-->
<!-- <invSelect :value.sync="formQuery.deptCode"/>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
</el-row>
</el-form>
<div class="top-right-btn">
<el-button-group>
<el-button icon="el-icon-view" type="primary" @click="showSearch = !showSearch">显示/隐藏搜索栏</el-button>
<el-button
type="primary"
icon="el-icon-refresh"
@click="onReset"
>重置
</el-button>
<el-button type="primary" icon="el-icon-search" @click="onSubmit"
>查询
</el-button
>
</el-button-group>
</div>
<el-divider style="margin: 15px"></el-divider>
<el-table
v-loading="loading"
:data="list"
>
<el-table-column label="序号" type="index" width="50"/>
<el-table-column
label="消息编码"
prop="code"
width="120"/>
<el-table-column
label="消息类型"
prop="msgTypeName"
width="120"/>
<el-table-column
label="消息内容"
prop="msgContent"
width="280"/>
<el-table-column
label="处理状态"
prop="dealStatusName"
width="120"/>
<el-table-column
label="推送状态"
prop="pushStatusName"
width="120"/>
<el-table-column
label="仓库"
prop="invName"
width="120"/>
<el-table-column
label="部门"
prop="deptName"
width="120"/>
<el-table-column
label="创建时间"
prop="createTime"
width="140"/>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="formQuery.page"
:limit.sync="formQuery.limit"
@pagination="getList"
/>
</el-card>
</div>
</template>
<script src="./sysMsgTodo.js"/>
<style lang="scss" scoped>
</style>
Loading…
Cancel
Save