diff --git a/sgzb-ui/src/api/scrap/forecastWaste.js b/sgzb-ui/src/api/scrap/forecastWaste.js index d0fa89ab..1229286a 100644 --- a/sgzb-ui/src/api/scrap/forecastWaste.js +++ b/sgzb-ui/src/api/scrap/forecastWaste.js @@ -12,5 +12,5 @@ export const getDialogListApi = (data) => { /* 预报废审核接口 */ export const auditingScrapApi = (data) => { - return request.post('/material/scrap/audit', data) + return request.post('/material/scrap/forecastWasteAudit', data) } diff --git a/sgzb-ui/src/store/modules/user.js b/sgzb-ui/src/store/modules/user.js index 75583aef..5bf670e6 100644 --- a/sgzb-ui/src/store/modules/user.js +++ b/sgzb-ui/src/store/modules/user.js @@ -1,4 +1,4 @@ -import { login, logout, getInfo, refreshToken,checkCode,loginByMall } from '@/api/login' +import { login, logout, getInfo, refreshToken, checkCode, loginByMall } from '@/api/login' import { getToken, setToken, setExpiresIn, removeToken } from '@/utils/auth' import { Notification, MessageBox, Message, Loading } from 'element-ui' const user = { @@ -60,13 +60,13 @@ const user = { textLogin({ commit }, userInfo) { console.log(userInfo) let params = { - phone:userInfo.phone, - code:userInfo.textCode + phone: userInfo.phone, + code: userInfo.textCode } return new Promise((resolve, reject) => { checkCode(params).then(res => { console.log(res) - if(res.code==200){ + if (res.code == 200) { let data = res.data setToken(data.access_token) commit('SET_TOKEN', data.access_token) @@ -81,19 +81,19 @@ const user = { }) }, //机具租赁平台跳转登录---南网 - ssoLogin({ commit }, param) { + ssoLogin({ commit }, param) { return new Promise((resolve, reject) => { loginByMall(param).then(res => { console.log(res) let data = res.data - if(res.code==200){ + if (res.code == 200) { // console.log('登录成功1111111') setToken(data.access_token) commit('SET_TOKEN', data.access_token) localStorage.setItem('token', data.access_token) setExpiresIn(data.expires_in) commit('SET_EXPIRES_IN', data.expires_in) - }else{ + } else { // console.log('登录失败22222222') this.$modal.msgError('登录失败'); } @@ -110,6 +110,8 @@ const user = { return new Promise((resolve, reject) => { getInfo().then(res => { const user = res.user + /* 存储当前登录用户的userId */ + sessionStorage.setItem('userId', user.userId) const avatar = (user.avatar == "" || user.avatar == null) ? require("@/assets/images/profile.jpg") : user.avatar; if (res.roles && res.roles.length > 0) { // 验证返回的roles是否是一个非空数组 commit('SET_ROLES', res.roles) @@ -128,7 +130,7 @@ const user = { }, // 刷新token - RefreshToken({commit, state}) { + RefreshToken({ commit, state }) { return new Promise((resolve, reject) => { refreshToken(state.token).then(res => { setExpiresIn(res.data) @@ -139,7 +141,7 @@ const user = { }) }) }, - + // 退出系统 LogOut({ commit, state }) { return new Promise((resolve, reject) => { diff --git a/sgzb-ui/src/views/scrapManage/component/formModel.vue b/sgzb-ui/src/views/scrapManage/component/formModel.vue index 19267ead..5c1eb711 100644 --- a/sgzb-ui/src/views/scrapManage/component/formModel.vue +++ b/sgzb-ui/src/views/scrapManage/component/formModel.vue @@ -75,7 +75,7 @@ - + diff --git a/sgzb-ui/src/views/scrapManage/component/tableModel.vue b/sgzb-ui/src/views/scrapManage/component/tableModel.vue index 1d6395e0..81f90172 100644 --- a/sgzb-ui/src/views/scrapManage/component/tableModel.vue +++ b/sgzb-ui/src/views/scrapManage/component/tableModel.vue @@ -6,7 +6,8 @@ :exportShow="exportShow" > 操作
+
全选
123 123 123 @@ -155,6 +157,7 @@ pageNum: 1, pageSize: 10, }, + columCheckList: [], } }, created() { @@ -182,8 +185,11 @@ this.sendParams, ) const res = await this.sendApi(this.pageParams) - this.tableList = res.rows - this.total = res.total + + if (res.code == 200) { + this.tableList = res.rows + this.total = res.total + } }, /* 表格复选框 */ @@ -199,4 +205,9 @@ } - + diff --git a/sgzb-ui/src/views/scrapManage/forecastWaste/auditing.vue b/sgzb-ui/src/views/scrapManage/forecastWaste/auditing.vue index f52cc4a1..2f874786 100644 --- a/sgzb-ui/src/views/scrapManage/forecastWaste/auditing.vue +++ b/sgzb-ui/src/views/scrapManage/forecastWaste/auditing.vue @@ -8,6 +8,7 @@ :exportShow="true" :pageShow="true" :isSelShow="true" + ref="tableRef" @getTableSelectionChange="getTableSelChangeOuter" > @@ -30,12 +31,31 @@ 待审核 + 审核中 + 已驳回 + 已通过 @@ -129,8 +149,7 @@ + + diff --git a/sgzb-ui/src/views/scrapManage/forecastWaste/index.js b/sgzb-ui/src/views/scrapManage/forecastWaste/index.js index d67d41e4..d019b039 100644 --- a/sgzb-ui/src/views/scrapManage/forecastWaste/index.js +++ b/sgzb-ui/src/views/scrapManage/forecastWaste/index.js @@ -8,7 +8,7 @@ import { getProjectList } from '@/api/claimAndRefund/receive' let unitList = [] //单位下拉数据 let proList = [] //工程下拉数据 let typeList = [] //类型下拉数据 -const config = { +export const config = { /* 预报废审核主页 列表参数 */ tableProps: [ { t_width: '55px', t_props: '', t_label: '序号' }, @@ -86,6 +86,23 @@ const config = { { t_width: '', t_props: '', t_label: '报废图片' }, { t_width: '', t_props: '', t_label: '备注' }, ], + /* 预报废页面驳回退料 列表参数 */ + returnTableProps: [ + { t_width: '55px', t_props: '', t_label: '序号' }, + { t_width: '', t_props: 'demo', t_label: '类型名称' }, + { t_width: '', t_props: '', t_label: '规格型号' }, + { t_width: '', t_props: '', t_label: '数量' }, + { t_width: '', t_props: '', t_label: '合格数量' }, + { t_width: '', t_props: '', t_label: '维修数量' }, + { t_width: '', t_props: '', t_label: '预报废数量' }, + { t_width: '', t_props: '', t_label: '状态' }, + ], + /* 预报废页面驳回退料 查询参数 */ + returnFormLabel: [ + { f_label: '关键字', f_model: 'keywords', f_type: 'ipt' }, + { f_label: '类型名称', f_model: 'backUnit', f_type: 'sel', f_selList: [] }, + { f_label: '规格型号', f_model: 'backPro', f_type: 'sel', f_selList: [] }, + ], } export const getSelList = () => { @@ -128,4 +145,3 @@ export const getSelList = () => { } -export default config \ No newline at end of file diff --git a/sgzb-ui/src/views/scrapManage/forecastWaste/listing.vue b/sgzb-ui/src/views/scrapManage/forecastWaste/listing.vue index 869eb8eb..0ece0712 100644 --- a/sgzb-ui/src/views/scrapManage/forecastWaste/listing.vue +++ b/sgzb-ui/src/views/scrapManage/forecastWaste/listing.vue @@ -1,7 +1,15 @@