Commit 4bc8013e by huangqy

111

parent afb273a6
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
<script> <script>
window._CONFIG = {}; window._CONFIG = {};
window._CONFIG['serviceURL'] = 'http://192.168.3.1:5000'; window._CONFIG['serviceURL'] = 'http://192.168.3.1:5000';
window._CONFIG['userURL'] = 'http://192.168.3.101:10004'; window._CONFIG['userURL'] = 'http://192.168.2.112:10004';
</script> </script>
</head> </head>
<body> <body>
......
import request from '@/utils/request' import request from '@/utils/request'
import md5 from 'js-md5'
export function get() { export function get() {
return request({ return request({
......
import request from '@/utils/request' import request from '@/utils/request'
import md5 from 'js-md5'
export function add(data) { export function add(data) {
return request({ return request({
......
import request from '@/utils/request' import request from '@/utils/request'
import { transform } from '@/utils/index'
export function getPageBag(data) { export function getPageBag(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/GetPageBag', url: window._CONFIG['serviceURL'] + '/api/Mission/GetPageBag',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -12,7 +13,7 @@ export function addOrUpdateBag(data) { ...@@ -12,7 +13,7 @@ export function addOrUpdateBag(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/AddOrUpdateBag', url: window._CONFIG['serviceURL'] + '/api/Mission/AddOrUpdateBag',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -20,7 +21,7 @@ export function deleteBag(data) { ...@@ -20,7 +21,7 @@ export function deleteBag(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/DeleteBag', url: window._CONFIG['serviceURL'] + '/api/Mission/DeleteBag',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -28,7 +29,7 @@ export function bindBag(data) { ...@@ -28,7 +29,7 @@ export function bindBag(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/BindBag', url: window._CONFIG['serviceURL'] + '/api/Mission/BindBag',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -36,7 +37,7 @@ export function releaseBag(data) { ...@@ -36,7 +37,7 @@ export function releaseBag(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/ReleaseBag', url: window._CONFIG['serviceURL'] + '/api/Mission/ReleaseBag',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -44,7 +45,7 @@ export function reBindBag(data) { ...@@ -44,7 +45,7 @@ export function reBindBag(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/ReBindBag', url: window._CONFIG['serviceURL'] + '/api/Mission/ReBindBag',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -53,7 +54,7 @@ export function addOrUpdateModel(data) { ...@@ -53,7 +54,7 @@ export function addOrUpdateModel(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/AddOrUpdateModel', url: window._CONFIG['serviceURL'] + '/api/Mission/AddOrUpdateModel',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -61,6 +62,47 @@ export function deleteModel(data) { ...@@ -61,6 +62,47 @@ export function deleteModel(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/DeleteModel', url: window._CONFIG['serviceURL'] + '/api/Mission/DeleteModel',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
export function getPageModel(data) {
return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/GetPageModel',
method: 'post',
data: transform(data)
})
}
export function addOrUpdateMission(data) {
return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/AddOrUpdateMission',
method: 'post',
data: transform(data)
})
}
export function changeWorkState(data) {
return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/changeWorkState',
method: 'post',
data: transform(data)
})
}
export function getMissionInOutInfo(data) {
return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/GetMissionInOutInfo',
method: 'post',
data: transform(data)
})
}
export function getMissionOrderInfo(data) {
return request({
url: window._CONFIG['serviceURL'] + '/api/Mission/getMissionOrderInfo',
method: 'post',
data: transform(data)
})
}
\ No newline at end of file
import request from '@/utils/request' import request from '@/utils/request'
import md5 from 'js-md5' import { transform } from '@/utils/index'
// 充电台 // 充电台
export function getPageChargeList(data) { export function getPageChargeList(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/BaseCharge/GetPageChargeList', url: window._CONFIG['serviceURL'] + '/api/BaseCharge/GetPageChargeList',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
import request from '@/utils/request' import request from '@/utils/request'
import md5 from 'js-md5' import { transform } from '@/utils/index'
// 获取装备列表 // 获取装备列表
export function getListEquipmentDetail(data) { export function getListEquipmentDetail(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/GetListEquipmentDetail', url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/GetListEquipmentDetail',
method: 'post', method: 'post',
data data: transform(data)
}) })
} }
...@@ -15,14 +15,7 @@ export function getPageEquipmentDetail(data) { ...@@ -15,14 +15,7 @@ export function getPageEquipmentDetail(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] +'/api/EquipmentDetail/GetPageEquipmentDetail', url: window._CONFIG['serviceURL'] +'/api/EquipmentDetail/GetPageEquipmentDetail',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -31,14 +24,7 @@ export function addOrUpdateEquipmentDetail(data) { ...@@ -31,14 +24,7 @@ export function addOrUpdateEquipmentDetail(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/AddOrUpdateEquipmentDetail', url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/AddOrUpdateEquipmentDetail',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -47,14 +33,7 @@ export function deleteEquipmentDetail(data) { ...@@ -47,14 +33,7 @@ export function deleteEquipmentDetail(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/DeleteEquipmentDetail', url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/DeleteEquipmentDetail',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -63,14 +42,7 @@ export function addSizeDetailSupplier(data) { ...@@ -63,14 +42,7 @@ export function addSizeDetailSupplier(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/AddSizeDetailSupplier', url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/AddSizeDetailSupplier',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -78,13 +50,6 @@ export function approverSizeDetailSupplier(data) { ...@@ -78,13 +50,6 @@ export function approverSizeDetailSupplier(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/ApproverSizeDetailSupplier', url: window._CONFIG['serviceURL'] + '/api/EquipmentDetail/ApproverSizeDetailSupplier',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
import request from '@/utils/request' import request from '@/utils/request'
import md5 from 'js-md5' import { transform } from '@/utils/index'
export function getListEquipmentSize(data) { export function getListEquipmentSize(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/GetListEquipmentSize', url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/GetListEquipmentSize',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -21,14 +14,7 @@ export function getPageEquipmentSize(data) { ...@@ -21,14 +14,7 @@ export function getPageEquipmentSize(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/GetPageEquipmentSize', url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/GetPageEquipmentSize',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -37,14 +23,7 @@ export function addOrUpdateEquipmentSize(data) { ...@@ -37,14 +23,7 @@ export function addOrUpdateEquipmentSize(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/AddOrUpdateEquipmentSize', url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/AddOrUpdateEquipmentSize',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -52,13 +31,6 @@ export function deleteEquipmentSize(data) { ...@@ -52,13 +31,6 @@ export function deleteEquipmentSize(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/DeleteEquipmentSize', url: window._CONFIG['serviceURL'] + '/api/EquipmentSize/DeleteEquipmentSize',
method: 'post', method: 'post',
data: { data: transform(data)
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
...@@ -55,7 +55,14 @@ export function getAllFixs(data) { ...@@ -55,7 +55,14 @@ export function getAllFixs(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/FixReceiveApply/GetWzByEpc', url: window._CONFIG['serviceURL'] + '/api/FixReceiveApply/GetWzByEpc',
method: 'post', method: 'post',
data data: {
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
......
import request from '@/utils/request' import request from '@/utils/request'
import md5 from 'js-md5' import md5 from 'js-md5'
import { transform } from '@/utils/index'
//获取组织机构及下级的所有库存 //获取组织机构及下级的所有库存
export function getOrgListEquipmentDetail(data) { export function getOrgListEquipmentDetail(data) {
...@@ -179,7 +180,15 @@ export function getOrgListEquipmentDetail(data) { ...@@ -179,7 +180,15 @@ export function getOrgListEquipmentDetail(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Inventory/GetInfoByID', url: window._CONFIG['serviceURL'] + '/api/Inventory/GetInfoByID',
method: 'post', method: 'post',
data data: transform(data)
})
}
export function getBagInfoByID(data) {
return request({
url: window._CONFIG['serviceURL'] + '/api/Inventory/GetBagInfoByID',
method: 'post',
data: transform(data)
}) })
} }
......
...@@ -85,7 +85,14 @@ export function getListOrgWarehouse(data) { ...@@ -85,7 +85,14 @@ export function getListOrgWarehouse(data) {
return request({ return request({
url: window._CONFIG['serviceURL'] + '/api/Warehouse/GetListOrgWarehouse', url: window._CONFIG['serviceURL'] + '/api/Warehouse/GetListOrgWarehouse',
method: 'post', method: 'post',
data data: {
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
}) })
} }
......
...@@ -57,6 +57,22 @@ export function controlDev(data) { ...@@ -57,6 +57,22 @@ export function controlDev(data) {
  })   })
} }
export function updateHumid(data) {
  return request({
    url: window._CONFIG['serviceURL'] + '/api/WarehouseDev/UpdateHumid',
    method: 'post',
    data: {
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
  })
}
// 获取物资 // 获取物资
export function getWarehouseInfo(data) { export function getWarehouseInfo(data) {
  return request({   return request({
......
...@@ -33,15 +33,15 @@ export default { ...@@ -33,15 +33,15 @@ export default {
} }
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
this.loading = true this.loading = true
// var jydata = { var jydata = {
// appKey: 'odykzzWm1GASj15K1AGxwQ==', appKey: 'odykzzWm1GASj15K1AGxwQ==',
// orgId: '', orgId: '',
// version: '1.0', version: '1.0',
// timestamp: parseInt(new Date().getTime()/1000), timestamp: parseInt(new Date().getTime()/1000),
// body: escape(JSON.stringify(this.params)), body: escape(JSON.stringify(this.params)),
// sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(this.params))) sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(this.params)))
// } }
initPdata(this.url, this.params).then(res => { initPdata(this.url, jydata).then(res => {
if (res.code === '10000') { if (res.code === '10000') {
this.total = res.data.totalElements this.total = res.data.totalElements
this.data = res.data.content this.data = res.data.content
......
/** /**
* Created by jiachenpan on 16/11/18. * Created by jiachenpan on 16/11/18.
*/ */
import md5 from 'js-md5'
export function parseTime(time) { export function parseTime(time) {
if (time) { if (time) {
...@@ -164,6 +165,19 @@ export function removeClass(ele, cls) { ...@@ -164,6 +165,19 @@ export function removeClass(ele, cls) {
} }
} }
export function transform(data) {
let k = {
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(data)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(data)))
}
return k;
}
export function downloadFile(obj, name, suffix) { export function downloadFile(obj, name, suffix) {
const url = window.URL.createObjectURL(new Blob([obj])) const url = window.URL.createObjectURL(new Blob([obj]))
const link = document.createElement('a') const link = document.createElement('a')
......
...@@ -107,6 +107,7 @@ export default { ...@@ -107,6 +107,7 @@ export default {
this.epcList = [] this.epcList = []
if (value) { if (value) {
let obj = this.bagList.find(i => i.id === this.form.bagId) let obj = this.bagList.find(i => i.id === this.form.bagId)
console.log(obj)
this.bagReadList = obj.bagList this.bagReadList = obj.bagList
} }
}, },
...@@ -184,6 +185,8 @@ export default { ...@@ -184,6 +185,8 @@ export default {
}, 1000) }, 1000)
} }
}) })
if (!this.form.warehouseId) { return this.$message.warning('请选择仓库') }
if (this.form.equipmentList.length === 0) { return this.$message.warning('未绑定装备') }
if(flag) return; if(flag) return;
bindBag(this.form).then(res => { bindBag(this.form).then(res => {
if (res.code === '10000') { if (res.code === '10000') {
......
...@@ -65,6 +65,8 @@ ...@@ -65,6 +65,8 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-divider></el-divider>
<el-table :data="bottomData" stripe border style="width: 100%;margin-top: 20px;"> <el-table :data="bottomData" stripe border style="width: 100%;margin-top: 20px;">
<el-table-column type="index" label="序号" align="center" width="50"/> <el-table-column type="index" label="序号" align="center" width="50"/>
<el-table-column prop="name" label="装备名称" align="center"/> <el-table-column prop="name" label="装备名称" align="center"/>
...@@ -93,6 +95,7 @@ import { initPdata } from '@/api/data' ...@@ -93,6 +95,7 @@ import { initPdata } from '@/api/data'
import { getWzByEpc } from '@/api/fixReceiveApply' import { getWzByEpc } from '@/api/fixReceiveApply'
import eForm from './form' import eForm from './form'
import infoForm from '../../warehouse/maintenance/form' import infoForm from '../../warehouse/maintenance/form'
import md5 from 'js-md5'
export default { export default {
name: 'Person', name: 'Person',
components: { eForm, infoForm }, components: { eForm, infoForm },
...@@ -133,7 +136,15 @@ export default { ...@@ -133,7 +136,15 @@ export default {
} }
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
this.loading = true this.loading = true
initPdata(this.url, this.params).then(res => { var jydata = {
appKey: 'odykzzWm1GASj15K1AGxwQ==',
orgId: '',
version: '1.0',
timestamp: parseInt(new Date().getTime()/1000),
body: escape(JSON.stringify(this.params)),
sign: md5('a1dca4cf35a6d460128f5e4ad401b1c1'+parseInt(new Date().getTime()/1000)+'1.0'+escape(JSON.stringify(this.params)))
}
initPdata(this.url, jydata).then(res => {
if (res.code === '10000') { if (res.code === '10000') {
this.total = res.data.totalElements this.total = res.data.totalElements
this.data = res.data.content this.data = res.data.content
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
</template> </template>
<script> <script>
import { controlDev } from '@/api/warehouseDev' import { controlDev, updateHumid } from '@/api/warehouseDev'
export default { export default {
data() { data() {
return { return {
...@@ -45,6 +45,7 @@ export default { ...@@ -45,6 +45,7 @@ export default {
this.resetForm() this.resetForm()
}, },
doSubmit(){ doSubmit(){
updateHumid(this.form)
controlDev(this.form).then(res => { controlDev(this.form).then(res => {
if (res.code == '10000') { if (res.code == '10000') {
this.dialog = false this.dialog = false
......
...@@ -144,7 +144,7 @@ export default { ...@@ -144,7 +144,7 @@ export default {
} }
}, },
handleDelete(index, row) { handleDelete(index, row) {
this.form.bagList.splice(index, 1) this.form.modelList.splice(index, 1)
}, },
cancel() { cancel() {
this.resetForm() this.resetForm()
......
...@@ -11,15 +11,7 @@ ...@@ -11,15 +11,7 @@
<eForm ref="form" :is-add="isAdd" @ok="handeleInit"/> <eForm ref="form" :is-add="isAdd" @ok="handeleInit"/>
<!--表格渲染--> <!--表格渲染-->
<el-table ref="table" v-loading="loading" :data="data" highlight-current-row border style="width: 100%;"> <el-table ref="table" v-loading="loading" :data="data" highlight-current-row border style="width: 100%;">
<el-table-column type="expand" align="center"> <el-table-column type="index" align="center" width="50"></el-table-column>
<template slot-scope="props">
<el-table :data="props.row.bagList" stripe border style="width: 100%;">
<el-table-column type="index" label="序号" align="center" width="50"/>
<el-table-column prop="name" label="装备名称" align="center"/>
<el-table-column prop="count" label="数量" align="center"/>
</el-table>
</template>
</el-table-column>
<el-table-column prop="orgName" label="组织机构名称" align="center"/> <el-table-column prop="orgName" label="组织机构名称" align="center"/>
<el-table-column prop="name" label="装备包名称" align="center"/> <el-table-column prop="name" label="装备包名称" align="center"/>
<el-table-column label="操作" width="150" align="center" fixed="right"> <el-table-column label="操作" width="150" align="center" fixed="right">
......
...@@ -102,8 +102,9 @@ ...@@ -102,8 +102,9 @@
<el-table-column prop="insideRealCount" align="center" label="已归还数量"/> <el-table-column prop="insideRealCount" align="center" label="已归还数量"/>
<el-table-column prop="state" label="出入库状态" align="center"> <el-table-column prop="state" label="出入库状态" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.quantity == scope.row.realCount && scope.row.realCount == scope.row.insideRealCount" type="success">已完成</el-tag> <el-tag v-if="scope.row.state === 2" type="success">已完成</el-tag>
<el-tag v-else type="warning">未完成</el-tag> <el-tag v-else-if="scope.row.state === 1" type="primary">进行中</el-tag>
<el-tag v-else-if="scope.row.state === 0" type="warning">未完成</el-tag>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
......
...@@ -40,14 +40,14 @@ ...@@ -40,14 +40,14 @@
</div> </div>
</el-dialog> </el-dialog>
<!--表格开始--> <!--表格开始-->
<el-table v-loading="loading" :data="data" style="width: 100%;" stripe border :header-cell-style="{'text-align':'center'}"> <el-table v-loading="loading" :data="data" style="width: 100%;" stripe border :header-cell-style="{'text-align':'center'}" row-key="key" :tree-props="{children: 'bagIncludeList'}">
<el-table-column type="index" label="序号" width="50" align="center"/> <el-table-column type="index" label="序号" width="50" align="center"/>
<el-table-column label="订单编号" :show-overflow-tooltip="true" align="center" v-if="actionState!=13" width="200"> <el-table-column label="订单编号" :show-overflow-tooltip="true" align="center" v-if="actionState!=13" width="200">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" @click="showOrder(scope.row)">{{ scope.row.order }}</el-link> <el-link type="primary" @click="showOrder(scope.row)">{{ scope.row.order }}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="warehouseName" label="仓库名称" align="center"/> <el-table-column prop="warehouseName" label="仓库名称" align="center" width="180" :show-overflow-tooltip="true"/>
<el-table-column prop="equipmentName" label="装备名称" align="center"/> <el-table-column prop="equipmentName" label="装备名称" align="center"/>
<el-table-column prop="sizeName" label="装备型号名称" align="center"/> <el-table-column prop="sizeName" label="装备型号名称" align="center"/>
<el-table-column prop="policeName" label="操作人员" align="center"/> <el-table-column prop="policeName" label="操作人员" align="center"/>
...@@ -65,6 +65,7 @@ ...@@ -65,6 +65,7 @@
<el-tag v-else-if="scope.row.actionState === 15 || scope.row.actionState === 16" type="warning">跨仓库借用</el-tag> <el-tag v-else-if="scope.row.actionState === 15 || scope.row.actionState === 16" type="warning">跨仓库借用</el-tag>
<el-tag v-else-if="scope.row.actionState === 17 || scope.row.actionState === 18" type="success">跨仓库归还</el-tag> <el-tag v-else-if="scope.row.actionState === 17 || scope.row.actionState === 18" type="success">跨仓库归还</el-tag>
<el-tag v-else-if="scope.row.actionState === 19" type="success">装备回库</el-tag> <el-tag v-else-if="scope.row.actionState === 19" type="success">装备回库</el-tag>
<el-tag v-else-if="scope.row.actionState === 20 || scope.row.actionState === 21" type="success">出警任务</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="安全等级" align="center" width="150px"> <el-table-column label="安全等级" align="center" width="150px">
...@@ -97,6 +98,7 @@ ...@@ -97,6 +98,7 @@
@current-change="postPageChange"/> @current-change="postPageChange"/>
<!--表单组件--> <!--表单组件-->
<equ-info-detail ref="equInfoDetail"/> <equ-info-detail ref="equInfoDetail"/>
<bag-info-detail ref="bagInfoDetail"/>
<borrow-detail ref="p2"/> <borrow-detail ref="p2"/>
<receive-detail ref='p3'/> <receive-detail ref='p3'/>
...@@ -118,7 +120,8 @@ import initData from '@/mixins/initData' ...@@ -118,7 +120,8 @@ import initData from '@/mixins/initData'
import { parseTimes } from '@/utils/index' import { parseTimes } from '@/utils/index'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
import equInfoDetail from '@/views/warehouse/maintenance/form' import equInfoDetail from '@/views/warehouse/maintenance/form'
import { getInfoByID } from '@/api/inventory' import bagInfoDetail from '@/views/warehouse/maintenance/bagForm'
import { getInfoByID, getBagInfoByID } from '@/api/inventory'
import { initPdata } from '@/api/data' import { initPdata } from '@/api/data'
import md5 from 'js-md5' import md5 from 'js-md5'
import BorrowDetail from '@/views/warehouse/borrow/list/form' import BorrowDetail from '@/views/warehouse/borrow/list/form'
...@@ -134,7 +137,7 @@ export default { ...@@ -134,7 +137,7 @@ export default {
name: 'WarehouseLog', name: 'WarehouseLog',
mixins: [initData], mixins: [initData],
props: ['orgList', 'warehouseList', 'actionState'], props: ['orgList', 'warehouseList', 'actionState'],
components: { equInfoDetail,BorrowDetail, PurseDetail, RmDetail, ScrapDetail, BorrowOtherDetail, ReturnOtherDetail, TransferDetail, ReceiveDetail, InventoryReturnDetail }, components: { equInfoDetail ,bagInfoDetail, BorrowDetail, PurseDetail, RmDetail, ScrapDetail, BorrowOtherDetail, ReturnOtherDetail, TransferDetail, ReceiveDetail, InventoryReturnDetail },
data() { data() {
return { return {
loading: false, loading: false,
...@@ -213,7 +216,7 @@ export default { ...@@ -213,7 +216,7 @@ export default {
}, },
beforeInit() { beforeInit() {
this.url = window._CONFIG['serviceURL'] + '/api/Inventory/GetAllInOutHistory' this.url = window._CONFIG['serviceURL'] + '/api/Inventory/GetAllInOutHistory'
this.params = {page: this.page,size: this.size, orgId: this.orgId || this.$store.state.user.user.baseJpOrganization.id,actionState: this.actionState } this.params = {page: this.page,size: this.size, orgId: this.orgId || this.$store.state.user.user.baseJpOrganization.id, actionState: this.actionState }
const warehouseId = this.warehouseId // 仓库 const warehouseId = this.warehouseId // 仓库
const date = this.date const date = this.date
const equipmentName = this.equipmentName const equipmentName = this.equipmentName
...@@ -239,17 +242,31 @@ export default { ...@@ -239,17 +242,31 @@ export default {
this.dialogVisible = true this.dialogVisible = true
}, },
show(data) { show(data) {
const _this = this.$refs.equInfoDetail if (data.bagInventoryId) {
getInfoByID({id: data.equipmentId}).then(res => { const _this = this.$refs.bagInfoDetail
if(res.code == '10000') { getBagInfoByID({id: data.bagInventoryId}).then(res => {
_this.form = res.data if(res.code == '10000') {
_this.stateList = res.data.stateList.slice(0, 3) _this.form = res.data
_this.total = res.data.stateList.length _this.stateList = res.data.stateList.slice(0, 3)
} else { _this.total = res.data.stateList.length
this.$message.error(res.msg) } else {
} this.$message.error(res.msg)
}) }
_this.dialog = true })
_this.dialog = true
} else {
const _this = this.$refs.equInfoDetail
getInfoByID({id: data.equipmentId}).then(res => {
if(res.code == '10000') {
_this.form = res.data
_this.stateList = res.data.stateList.slice(0, 3)
_this.total = res.data.stateList.length
} else {
this.$message.error(res.msg)
}
})
_this.dialog = true
}
}, },
showOrder(data) { showOrder(data) {
const _this = this.$refs['p' + data.actionState] const _this = this.$refs['p' + data.actionState]
......
<template>
<el-dialog :append-to-body="true" :close-on-click-modal="false" :before-close="cancel" :visible.sync="dialog" title="查看详情" width="1200px">
<!-- 弹出的图片窗口 -->
<el-dialog :append-to-body="true" :close-on-click-modal="false" :visible.sync="dialogVisible" title="图片预览" width="50%">
<img :src="picUrl" width="100%"/>
      <div slot="footer" class="dialog-footer">
<el-button type="info" plain @click="dialogVisible = false">关闭</el-button>
</div>
</el-dialog>
<el-form ref="form" :model="form" :inline="true" size="small" label-width="80px">
<el-card style="margin-bottom: 15px">
<div slot="header" class="clearfix">
<span style="cursor:pointer" @click="show=!show">基本信息 &nbsp;&nbsp;&nbsp; </span> <span v-show="show"> [{{form.epc}}] </span>
</div>
<div style="border:1px solid #e8e8e8;">
<table style="table-layout:auto; width:100%;border-collapse:collapse;box-sizing:border-box;">
<tbody>
<tr style="border-bottom:1px solid #e8e8e8;">
<th class="textHeader">所属组织机构</th>
<td class="textContent">{{form.name}}</td>
<th class="textHeader">所属仓库</th>
<td class="textContent">
{{form.warehouseName}}
</td>
<th class="textHeader">装备包状态</th>
<td class="textContentLast" style="padding-top:8px;padding-bottom:8px;">
<el-tag v-if="[0,3].includes(form.currentState)" type="success">在库</el-tag>
<el-tag v-else-if="[6].includes(form.currentState)" type="danger">已报废</el-tag>
<el-tag v-else type="warning">出库</el-tag>
</td>
</tr>
<tr style="border-bottom:1px solid #e8e8e8;">
<th class="textHeader">装备包名称</th>
<td class="textContent">{{form.equipmentName}}</td>
<th class="textHeader">使用次数</th>
<td class="textContent">{{form.useCount}}</td>
<th class="textHeader">维修次数</th>
<td class="textContentLast">{{form.fixCount}}</td>
</tr>
</tbody>
</table>
</div>
</el-card>
<el-card style="margin-bottom: 15px">
<div slot="header" class="clearfix">
<span>历史出入库信息</span>
</div>
<el-table :data="stateList" style="width: 100%" border>
<el-table-column type="index" label="序号" align="center" width="50"/>
<el-table-column prop="policeName" align="center" label="操作人员"/>
<el-table-column prop="name" align="center" label="仓库名称"/>
<el-table-column prop="createTime" align="center" label="出入库时间" />
<el-table-column align="center" label="出入库状态">
<template slot-scope="scope">
<span v-if="scope.row.actionState == 1">采购</span>
<span v-else-if="scope.row.actionState == 2">借用</span>
<span v-else-if="scope.row.actionState == 3">领用</span>
<span v-else-if="scope.row.actionState == 4">调拨</span>
<span v-else-if="scope.row.actionState == 6">维修</span>
<span v-else-if="scope.row.actionState == 7">报废</span>
<span v-else-if="scope.row.actionState == 13 || scope.row.actionState == 14">本仓库借用</span>
<span v-else-if="scope.row.actionState == 15 || scope.row.actionState == 16">跨仓库借用</span>
<span v-else-if="scope.row.actionState == 17 || scope.row.actionState == 18">跨仓库归还</span>
<span v-else-if="scope.row.actionState == 19">装备回库</span>
{{scope.row.outInState == 0 ? '出库': '入库'}}
</template>
</el-table-column>
<el-table-column label="操作" align="center" fixed="right">
<template slot-scope="scope">
<el-button size="mini" type="warning" v-if="scope.row.picUrl" @click="previewPic(encodeURI(baseApi2 + scope.row.picUrl))">预览</el-button>
</template>
</el-table-column>
</el-table>
<!--分页组件-->
<el-pagination style="margin-top: 8px;" layout="prev, pager, next" :total="total" :page-size="3" :current-page="currentPage" @current-change="handleCurrentChange"/>
</el-card>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel" type="info" plain>关闭</el-button>
</div>
</el-dialog>
</template>
<script>
import { mapGetters } from 'vuex'
import { parseTimes } from '@/utils/index'
export default {
data() {
return {
loading: false, dialog: false, total: 0,
dialogVisible: false,
picUrl: '',
currentPage: 1, stateList: [],
form: {},
show: false
}
},
computed: {
...mapGetters([
'baseApi2'
])
},
methods: {
parseTimes,
cancel() {
this.resetForm()
},
previewPic(url) { //预览出入库的图片
this.picUrl = url
this.dialogVisible = true
},
resetForm() {
this.dialog = false
},
handleCurrentChange(currentPage) {
this.currentPage = currentPage
this.stateList = this.form.stateList.slice((this.currentPage-1)*3, this.currentPage*3)
}
}
}
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
/deep/ .el-input-number .el-input__inner {
text-align: left;
}
/deep/.el-card .el-card__header{
background:#ffffff;
color:#000000;
font-size: 16px;
}
.textHeader{
background-color:#fafafa;
padding:16px 24px;
border-right:1px solid #e8e8e8;
text-align:center;
}
.textContent{
background-color:#ffffff;
padding:16px 24px;
border-right:1px solid #e8e8e8;
text-align:left;
}
.textContentLast{
background-color:#ffffff;
padding:16px 24px;
text-align:left;
}
/deep/ .el-dialog{
display: flex;
flex-direction: column;
margin:0 !important;
position:absolute;
top:50%;
left:50%;
transform:translate(-50%,-50%);
/*height:600px;*/
max-height:calc(100% - 30px);
max-width:calc(100% - 30px);
}
/deep/ .el-dialog .el-dialog__body{
flex:1;
overflow: auto;
}
</style>
<template>
<el-dialog :append-to-body="true" :close-on-click-modal="false" :before-close="cancel" :visible.sync="dialog" title="查看详情" width="1200px">
<!-- 弹出的图片窗口 -->
<el-dialog :append-to-body="true" :close-on-click-modal="false" :visible.sync="dialogVisible" title="图片预览" width="50%">
<img :src="picUrl" width="100%"/>
<div slot="footer" class="dialog-footer">
<el-button type="info" plain @click="dialogVisible = false">关闭</el-button>
</div>
</el-dialog>
<el-form ref="form" :model="form" :inline="true" size="small" label-width="80px">
<el-tabs v-model="active" tab-position="left">
<el-tab-pane name="first" style="margin-left: 20px">
<span slot="label"><i class="el-icon-document"></i>&nbsp;任务信息</span>
<el-card style="margin-bottom: 15px">
<div slot="header" class="clearfix">
<span style="cursor:pointer" @click="show=!show">基本信息 &nbsp;&nbsp;&nbsp; </span>
</div>
<div style="border:1px solid #e8e8e8;">
<table style="table-layout:auto; width:100%;border-collapse:collapse;box-sizing:border-box;">
<tbody>
<tr style="border-bottom:1px solid #e8e8e8;">
<th class="textHeader">任务名称</th>
<td class="textContent">{{form.name}}</td>
<th class="textHeader">仓库名称</th>
<td class="textContent">
{{form.warehouseName}}
</td>
<th class="textHeader">任务状态</th>
<td class="textContentLast" style="padding-top:8px;padding-bottom:8px;">
<el-tag type="warning" v-if="form.state == 0">未开始</el-tag>
<el-tag type="primary" v-if="form.state == 1">进行中</el-tag>
<el-tag type="success" v-if="form.state == 2">已完成</el-tag>
</td>
</tr>
<tr style="border-bottom:1px solid #e8e8e8;">
<th class="textHeader">工作状态</th>
<td class="textContent">
<el-tag type="primary" v-if="!form.isWork">未工作</el-tag>
<el-tag type="success" v-if="form.isWork">工作中</el-tag>
</td>
<th class="textHeader">任务时间</th>
<td class="textContentLast">{{form.createTime}}</td>
</tr>
</tbody>
</table>
</div>
</el-card>
<el-card style="margin-bottom: 15px">
<div slot="header" class="clearfix">
<span>模块信息</span>
</div>
<el-tabs v-model="activeName">
<el-tab-pane :label="item.name" :name="index.toString()" v-for="(item,index) in form.missionChild" :key="item.modelId">
<el-table :data="item.modelList" style="width: 100%" border row-key="name" :tree-props="{children: 'bagList'}">
<el-table-column type="index" label="序号" align="center" width="50"/>
<el-table-column align="center" label="类别">
<template slot-scope="scope">
{{scope.row.type === 'bag' ? '装备包' : scope.row.type === 'equipment' ? '装备' : ''}}
</template>
</el-table-column>
<el-table-column prop="name" align="center" label="名称"/>
<el-table-column prop="count" align="center" label="数量"/>
</el-table>
</el-tab-pane>
</el-tabs>
</el-card>
</el-tab-pane>
<el-tab-pane name="third" style="margin-left: 20px">
<span slot="label"><i class="el-icon-tickets"></i>&nbsp;通道信息</span>
<el-card style="margin-bottom: 15px">
<div slot="header" class="clearfix">
<span>查看出入库状态</span>
</div>
<el-tabs v-model="activethree">
<el-tab-pane :label="item.name" :name="index.toString()" v-for="(item,index) in inoutList" :key="item.id">
<el-table :data="item.modelBagList" style="width: 100%" border>
<el-table-column type="index" label="序号" align="center" width="50"/>
<el-table-column prop="type" align="center" label="类型">
<template slot-scope="scope">
{{scope.row.type === 'bag' ? '装备包' : scope.row.type === 'equipment' ? '装备' : ''}}
</template>
</el-table-column>
<el-table-column prop="name" align="center" label="名称"/>
<el-table-column prop="count" align="center" label="计划数量"/>
<el-table-column prop="realOutCount" align="center" label="实际出库数量"/>
<el-table-column prop="realInCount" align="center" label="实际回库数量"/>
<!-- <el-table-column prop="state" label="出入库状态" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.realInCount == scope.row.realOutCount" type="success">已完成</el-tag>
<el-tag v-else type="warning">未完成</el-tag>
</template>
</el-table-column> -->
</el-table>
</el-tab-pane>
</el-tabs>
</el-card>
</el-tab-pane>
</el-tabs>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel" type="info" plain>关闭</el-button>
</div>
</el-dialog>
</template>
<script>
import { mapGetters } from 'vuex'
import { parseTimes } from '@/utils/index'
import {getMissionInOutInfo} from '@/api/bag'
export default {
data() {
return {
loading: false, dialog: false, total: 0,
dialogVisible: false,
picUrl: '',
currentPage: 1, stateList: [],
form: {},
show: false,
active: 'first',
activeName: "0",
activethree: '0',
inoutList: [],
inOutdetailList: []
}
},
computed: {
...mapGetters([
'baseApi2'
])
},
methods: {
parseTimes,
cancel() {
this.resetForm()
},
previewPic(url) { //预览出入库的图片
this.picUrl = url
this.dialogVisible = true
},
resetForm() {
this.dialog = false
},
getMissionInOutInfo(id) {
getMissionInOutInfo({id:id}).then(res => {
if (res.code == '10000') {
this.inoutList = res.data
} else {
this.$message.error(res.message)
}
})
},
handleCurrentChange(currentPage) {
this.currentPage = currentPage
this.stateList = this.form.stateList.slice((this.currentPage-1)*3, this.currentPage*3)
}
}
}
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
/deep/ .el-input-number .el-input__inner {
text-align: left;
}
/deep/.el-card .el-card__header{
background:#ffffff;
color:#000000;
font-size: 16px;
}
.textHeader{
background-color:#fafafa;
padding:16px 24px;
border-right:1px solid #e8e8e8;
text-align:center;
}
.textContent{
background-color:#ffffff;
padding:16px 24px;
border-right:1px solid #e8e8e8;
text-align:left;
}
.textContentLast{
background-color:#ffffff;
padding:16px 24px;
text-align:left;
}
/deep/ .el-dialog{
display: flex;
flex-direction: column;
margin:0 !important;
position:absolute;
top:50%;
left:50%;
transform:translate(-50%,-50%);
/*height:600px;*/
max-height:calc(100% - 30px);
max-width:calc(100% - 30px);
}
/deep/ .el-dialog .el-dialog__body{
flex:1;
overflow: auto;
}
</style>
...@@ -116,9 +116,9 @@ ...@@ -116,9 +116,9 @@
<el-table-column prop="insideRealCount" align="center" label="已入库数量"/> <el-table-column prop="insideRealCount" align="center" label="已入库数量"/>
<el-table-column prop="state" label="出入库状态" align="center"> <el-table-column prop="state" label="出入库状态" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.quantity == scope.row.realCount && scope.row.realCount == scope.row.insideRealCount" type="success">已完成</el-tag> <el-tag v-if="scope.row.state === 2" type="success">已完成</el-tag>
<el-tag v-else-if="scope.row.quantity == scope.row.realCount" type="primary">进行中</el-tag> <el-tag v-else-if="scope.row.state === 1" type="primary">进行中</el-tag>
<el-tag v-else type="warning">未完成</el-tag> <el-tag v-else-if="scope.row.state === 0" type="warning">未完成</el-tag>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论