问题修改

master
lion 1 year ago
parent 91502ba9c3
commit 6bed2b8ad6

@ -2,15 +2,15 @@
ENV='development'
# base api
#VUE_APP_BASE_API = http://192.168.60.99:9004/
#VUE_APP_UPLOAD_API = http://192.168.60.99:9004/api/admin/upload-file
#VUE_APP_OA_URL = http://192.168.60.18:2021
#VUE_APP_OA_URL_TYPE = '{"领用":"37","处置":"38","应急":"39"}'
VUE_APP_BASE_API = http://192.168.60.99:9004/
VUE_APP_UPLOAD_API = http://192.168.60.99:9004/api/admin/upload-file
VUE_APP_OA_URL = http://192.168.60.18:2021
VUE_APP_OA_URL_TYPE = '{"领用":"37","处置":"38","应急":"39"}'
VUE_APP_BASE_API = http://192.168.60.99:8004/
VUE_APP_UPLOAD_API = http://192.168.60.99:8004/api/admin/upload-file
VUE_APP_OA_URL= http://suzhouhedaooa.langye.net
VUE_APP_OA_URL_TYPE = '{"领用":"31","处置":"32","应急":"33"}'
#VUE_APP_BASE_API = http://192.168.60.99:8004/
#VUE_APP_UPLOAD_API = http://192.168.60.99:8004/api/admin/upload-file
#VUE_APP_OA_URL= http://suzhouhedaooa.langye.net
#VUE_APP_OA_URL_TYPE = '{"领用":"31","处置":"32","应急":"33"}'

@ -24,6 +24,7 @@
"element-ui": "2.15.13",
"file-saver": "^2.0.5",
"js-cookie": "2.2.0",
"less": "^3.13.1",
"less-loader": "^5.0.0",
"moment": "^2.29.2",
"normalize.css": "7.0.0",

@ -2,8 +2,18 @@
<div>
<div class="map" id="map" :style="{'height':mapHeight+'px'}">
<div class="tabs">
<div :class="!addCur?'tabcur':''" @click="changeMask(1)"></div>
<div :class="addCur?'tabcur':''" @click="changeMask(2)"></div>
<div :class="!addCur?'tabcur':''" @click="changeMask(1)"></div>
<div :class="addCur?'tabcur':''">
<el-dropdown @command="clickQuyu" :show-timeout="100" >
<span class="el-dropdown-link" @click="changeMask(2)">
防汛仓库<i class="el-icon-arrow-down el-icon--right"></i>
</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item v-for="item in areaList" :command="item.id">{{item.value}}</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</div>
</div>
<div ref='infoWindow' id="infoWindow">
@ -62,7 +72,10 @@
import {
index,
destroy
} from "@/api/system/baseForm.js"
} from "@/api/system/baseForm.js"
import {
getparameteritem
} from "@/api/system/dictionary.js"
export default {
data() {
return {
@ -74,10 +87,12 @@
makerObj: {
teams: [],
storages: []
},
},
areaList:[],
infoWindow: null,
openData: [],
materList: [],
materList: [],
quyu_id:'',
loading: true,
total: 0,
addCur: false,
@ -205,13 +220,19 @@
]
}
},
created() {
created() {
this.getArea()
this.initHeight()
this.$nextTick(function() {
this.mapInit()
})
},
methods: {
methods: {
getArea(){
getparameteritem("area").then(res=>{
this.areaList = res.detail
})
},
initHeight() {
let winHeight = document.body.clientHeight
this.mapHeight = winHeight - 50 - 20
@ -239,7 +260,7 @@
offset: new AMap.Pixel(-10, -10)
})
this.getTeams()
this.getStorages()
// this.getStorages()
// this.setMapMarker()
},
changeMask(type) {
@ -247,8 +268,10 @@
this.addCur = false
this.setMapMarker("teams", this.makerObj.teams)
} else if (type == 2) {
this.addCur = true
this.setMapMarker("storages", this.makerObj.storages)
this.addCur = true
this.quyu_id = ''
this.getStorages()
// this.setMapMarker("storages", this.makerObj.storages)
}
},
async getTeams() {
@ -268,14 +291,32 @@
...item
})
})
this.setMapMarker("teams", this.makerObj.teams)
this.setMapMarker("teams", this.makerObj.teams)
this.loadingFull.close();
})
},
clickQuyu(e){
console.log("e",e)
this.quyu_id = e
this.getStorages()
},
async getStorages() {
async getStorages() {
this.loadingFull = this.$loading({
lock: true,
text: '',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
this.makerObj.storages = []
await index({
page: 1,
page_size: 9999,
table_name: 'flood_storages'
table_name: 'flood_storages',
filter: [{
key:'quyu_id',
op:'eq',
value:this.quyu_id
}],
}).then(res => {
let markers = []
if (res.data.length < 1) {
@ -288,6 +329,7 @@
...item
})
})
this.setMapMarker("storages", this.makerObj.storages)
this.loadingFull.close();
})
},
@ -363,7 +405,7 @@
}
</script>
<style>
<style lang="scss" scoped>
.tabs {
position: absolute;
z-index: 99;
@ -379,7 +421,11 @@
background-color: #fff;
color: #333;
}
::v-deep .el-dropdown{
font-size: 16px;
color: #333;
}
.tabs>div:first-child {
border-radius: 20px 0 0 20px;
@ -393,6 +439,10 @@
.tabs>div.tabcur {
background: #0077CC;
color: #fff
}
::v-deep .tabs>div.tabcur .el-dropdown{
color: #fff;
}
#infoWindow {
@ -439,7 +489,7 @@
width: 50%
}
/deep/ #infoWindow .el-icon-close {
::v-deep #infoWindow .el-icon-close {
position: absolute;
top: 5px;
right: 5px;

@ -68,7 +68,8 @@
<span style="color: red;font-weight: 600;padding-right: 4px;"></span>入库数量
</div>
<div class="xy-table-item-content">
<el-input v-model="form.rukushuliang" placeholder="请填写入库数量" clearable style="width: 300px;"></el-input>
{{form.rukushuliang}}
<!-- <el-input v-model="form.rukushuliang" placeholder="请填写入库数量" clearable style="width: 300px;"></el-input> -->
</div>
</div>
</template>
@ -78,7 +79,7 @@
<span style="color: red;font-weight: 600;padding-right: 4px;"></span>在库数量
</div>
<div class="xy-table-item-content">
<el-input v-model="form.zaikushuliang" placeholder="请填写在库数量" clearable style="width: 300px;"></el-input>
<el-input v-model="form.zaikushuliang" placeholder="请填写在库数量" clearable style="width: 300px;"></el-input>
</div>
</div>
</template>
@ -88,7 +89,8 @@
<span style="color: red;font-weight: 600;padding-right: 4px;"></span>入库批次
</div>
<div class="xy-table-item-content">
<el-input v-model="form.rukupici" placeholder="请填写入库批次" clearable style="width: 300px;"></el-input>
{{form.rukupici}}
<!-- <el-input v-model="form.rukupici" placeholder="请填写入库批次" clearable style="width: 300px;"></el-input> -->
</div>
</div>
</template>

@ -28,8 +28,8 @@
<Button type="primary" style="margin-left: 10px;" @click="getindex"></Button>
<Button type="primary" style="margin-left: 10px;" @click="toprint"></Button>
<Button type="primary" style="margin-left: 10px;"
@click="exportExcel(new Date().getTime().toString())">导出</Button>
<!-- <Button type="primary" style="margin-left: 10px;"
@click="exportExcel(new Date().getTime().toString())">导出</Button> -->
</div>
@ -39,16 +39,17 @@
<xy-table :list="list" v-loading="loading" :total="total" @selection-change="selectionChange"
@pageSizeChange="e => select.pageSize = e" @pageIndexChange="pageChange" :table-item="table" :auths='[]'>
<template v-slot:btns >
<template v-slot:btns>
<!-- <div></div> -->
<el-table-column v-if="isCkName=='仓库管理员'||roleName=='系统管理员'" fixed="right" label="操作" width="180" header-align="center">
<el-table-column v-if="isPandian==='pandian' && (isCkName=='仓库管理员'||roleName=='系统管理员')" fixed="right" align="center" label="操作" width="120" header-align="center">
<template slot-scope="scope">
<Button type="primary" size="small" @click="editorIn(scope.row.id,'editor')"></Button>
<!-- <Poptip transfer confirm title="确认要删除吗?" @on-ok="deleteIn(scope.row)">
<Button type="primary" style="margin-left: 10px;" size="small" ghost>删除</Button>
</Poptip> -->
</template>
</el-table-column>
</el-table-column>
<div v-else></div>
</template>
</xy-table>
@ -100,7 +101,8 @@
userName:'',
authName:'',
roleName:'',
isCkName:'',
isCkName:'',
isPandian:'',
select: {
pageSize: 10,
pageIndex: 1,
@ -272,9 +274,16 @@
}
},
mounted() {
if (this.$route.path) {
let path = this.$route.path.split("_")
if(path[1]){
this.isPandian = 'pandian'
}
}
this.getField()
this.getindex()
this.getUserName()
},
methods: {
async getUserName(){

@ -13,7 +13,7 @@
<span class="selector-item__label">资产名称</span>
<Input v-model="select.keyword" style="width: 120px;margin-right: 10px;" placeholder="资产名称搜索" />
</div>
<!-- <DatePicker @on-change="changeDate" type="daterange" split-panels placeholder="请选择日期" style="width: 200px"></DatePicker> -->
<Button type="primary" style="margin-left: 10px;" @click="getindex"></Button>
<Button type="primary" style="margin-left: 10px;"
@click="exportExcel(new Date().getTime().toString())">导出</Button>
@ -88,7 +88,8 @@
},
form: [],
total: 0,
list: [],
list: [],
dateRanges:'',
table: [{
label: '序号',
type: 'index',
@ -199,7 +200,18 @@
this.getindex()
},
methods: {
changeDate(e){
console.log(e)
if(e.length>0){
if(e[0]){
this.dateRanges = e.join(",")
}else{
this.dateRanges = ''
}
}else{
this.dateRanges = ''
}
},
async exportExcel(sheetName) {
this.loading = true
const res = await index(Object.assign('', {

@ -13,7 +13,7 @@
<span class="selector-item__label">资产名称</span>
<Input v-model="select.keyword" style="width: 120px;margin-right: 10px;" placeholder="资产名称搜索" />
</div>
<!-- <DatePicker @on-change="changeDate" type="daterange" split-panels placeholder="请选择日期" style="width: 200px"></DatePicker> -->
<Button type="primary" style="margin-left: 10px;" @click="getindex"></Button>
<Button type="primary" style="margin-left: 10px;"
@click="exportExcel(new Date().getTime().toString())">导出</Button>
@ -88,7 +88,8 @@
},
form: [],
total: 0,
list: [],
list: [],
dateRanges:'',
table: [{
label: '序号',
type: 'index',
@ -242,7 +243,18 @@
this.getindex()
},
methods: {
changeDate(e){
console.log(e)
if(e.length>0){
if(e[0]){
this.dateRanges = e.join(",")
}else{
this.dateRanges = ''
}
}else{
this.dateRanges = ''
}
},
async exportExcel(sheetName) {
this.loading = true
const res = await index(Object.assign('', {

@ -5,7 +5,10 @@
<lx-header icon="md-apps" text="物资档案管理" style="margin-bottom: 10px; border: 0px; margin-top: 15px">
<slot>
<div style="display: flex;justify-content: flex-start;flex-wrap: wrap;">
<Input v-model="select.keyword" style="width: 200px;margin-right: 10px;" placeholder="关键词搜索" />
<Input v-model="select.keyword" style="width: 200px;margin-right: 10px;" placeholder="关键词搜索" />
<Select v-model="select.suozaicangku" style="width: 200px;margin-right: 10px;" placeholder="所在仓库" clearable>
<Option v-for="item in cangkuList" :key="item.id" :value="item.cangkumingcheng">{{ item.cangkumingcheng }}</Option>
</Select>
<Button type="primary" @click="getindex"></Button>
<Button icon="ios-add" type="primary" style="margin-left: 10px;"
@click="$refs['addMater'].isShow = true,$refs['addMater'].type = 'add'">添加</Button>
@ -111,8 +114,10 @@
select: {
pageSize: 10,
pageIndex: 1,
keyword: ""
},
keyword: "",
suozaicangku:''
},
cangkuList:[],
customForm: {
customFormId: 1,
tableName: "material_infos"
@ -219,8 +224,21 @@
}
]
}
},
mounted() {
this.getCangku()
this.getField()
this.getindex()
},
methods: {
methods: {
async getCangku() {
let res = await index({
page_size: 999,
page: 1,
table_name: 'materialstorages',
})
this.cangkuList = res.data
},
async getindex() {
this.loading = true
const res = await index({
@ -231,7 +249,14 @@
"key": "zichanmingcheng",
"op": "like",
"value": this.select.keyword
}],
},
{
"key": "suozaicangku",
"op": "eq",
"value": this.select.suozaicangku
},
],
})
this.list = res.data
this.total = res.total
@ -368,11 +393,6 @@
})
},
},
mounted() {
this.getField()
this.getindex()
}
}
</script>

@ -29,7 +29,7 @@
<span style="color: red;font-weight: 600;padding-right: 4px;"></span>所在区域
</div>
<div class="xy-table-item-content">
<el-select v-model="form.suozaiquyu" style="width:300px" placeholder="请选择">
<el-select v-model="form.suozaiquyu" @change="changeQuyu" style="width:300px" placeholder="请选择">
<el-option
v-for="item in areaList"
:key="item.id"
@ -164,7 +164,8 @@
cangkudizhi: '',
jingdu: '',
weidu: '',
cangkujianjie: ''
cangkujianjie: '',
quyu_id:''
},
rules: {
cangkumingcheng: [{
@ -184,6 +185,19 @@
this.areaList = res.detail
})
},
changeQuyu(e){
if(e){
this.areaList.map(item=>{
if(e===item.value){
this.form.suozaiquyu = item.value
this.form.quyu_id = item.id
}
})
}else{
this.form.suozaiquyu = ''
this.form.quyu_id = ''
}
},
setTableName(e){
this.tableName = e?e:'materialstorages'
},

@ -11,8 +11,11 @@
:value="item.cangkumingcheng">
</el-option>
</el-select> -->
<Select v-model="select.guanliancangku" style="width:200px;margin-right: 10px;">
<Option v-for="item in cangkuList" :value="item.id" :key="item.value">{{ item.cangkumingcheng }}</Option>
<Select v-model="select.guanliancangku" style="width:200px;margin-right: 10px;" placeholder="所在仓库" clearable>
<Option v-for="item in cangkuList" :value="item.id" :key="item.value">{{ item.cangkumingchengquyu }}</Option>
</Select>
<Select @on-change="clearArea" v-model="select.area" style="width: 200px;margin-right: 10px;" placeholder="所在区域" clearable>
<Option v-for="item in areaList" :key="item.id" :value="item.id">{{ item.value }}</Option>
</Select>
<Button type="primary" @click="getindex"></Button>
<Button type="primary" style="margin-left: 10px;"
@ -60,7 +63,10 @@
import {
Message
} from 'element-ui'
import imports from "@/views/component/imports.vue"
import imports from "@/views/component/imports.vue"
import {
getparameteritem
} from "@/api/system/dictionary.js"
export default {
components: {
addMater,
@ -73,8 +79,10 @@
pageSize: 10,
pageIndex: 1,
keyword: "",
guanliancangku:''
},
guanliancangku:'',
area:''
},
areaList:[],
customForm: {
tableName: "flood_materials"
},
@ -100,6 +108,12 @@
width: 220,
prop: 'cangkumingcheng',
align: 'left',
},
{
label: "所在区域",
width: 120,
prop: 'suozaiquyu',
align: 'center',
},
{
label: "物资代码",
@ -206,7 +220,8 @@
]
}
},
mounted() {
mounted() {
this.getArea()
this.getCangku()
this.getindex()
this.table.map(item => {
@ -217,7 +232,19 @@
})
console.log("importForm", this.importForm)
},
methods: {
methods: {
getArea(){
getparameteritem("area").then(res=>{
this.areaList = res.detail
})
},
clearArea(e){
if(e){
this.select.area = e
}else{
this.select.area = ''
}
},
async getCangku() {
let res = await index({
page_size: 999,
@ -240,6 +267,10 @@
"key": "guanliancangku",
"op": "eq",
"value": this.select.guanliancangku
},{
key:'quyu_id',
op:'eq',
value:this.select.area
}],
})
this.list = res.data

@ -4,7 +4,10 @@
<lx-header icon="md-apps" text="防汛仓库" style="margin-bottom: 10px; border: 0px; margin-top: 15px">
<slot>
<div style="display: flex;justify-content: flex-start;flex-wrap: wrap;">
<Input v-model="select.keyword" style="width: 200px;margin-right: 10px;" placeholder="名称搜索" />
<Input v-model="select.keyword" style="width: 200px;margin-right: 10px;" placeholder="名称搜索" />
<Select @on-change="clearArea" v-model="select.area" style="width: 200px;margin-right: 10px;" placeholder="所在区域" clearable>
<Option v-for="item in areaList" :key="item.id" :value="item.id">{{ item.value }}</Option>
</Select>
<Button type="primary" @click="getList"></Button>
<Button type="primary" style="margin-left: 10px;" @click="$refs['addStorage'].type='add',
$refs['addStorage'].setTableName('flood_storages')
@ -19,7 +22,7 @@
<xy-table :list="list" :total="total" @pageSizeChange="pageSizeChange" @pageIndexChange="pageChange"
:table-item="table">
<template v-slot:btns>
<el-table-column fixed="right" label="操作" width="260" header-align="center">
<el-table-column fixed="right" label="操作" align="center" width="120" header-align="center">
<template slot-scope="scope">
<div>
<Button type="primary" size="small" @click="$refs['addStorage'].type='editor',
@ -45,7 +48,10 @@
index,
destroy
} from "@/api/system/baseForm.js"
import addStorage from './components/addStorage.vue'
import addStorage from './components/addStorage.vue'
import {
getparameteritem
} from "@/api/system/dictionary.js"
export default {
components: {
addStorage,
@ -57,8 +63,10 @@
page: 1,
page_size: 10,
keyword: '',
table_name: 'flood_storages'
},
table_name: 'flood_storages',
area:''
},
areaList:[],
total: 0,
list: [],
table: [{
@ -69,7 +77,6 @@
}, {
label: '仓库名称',
prop: 'cangkumingcheng',
width: 240,
align: 'left',
fixed: 'left'
},
@ -89,8 +96,9 @@
width: 120,
}, {
label: '仓库地址',
prop: 'cangkudizhi',
width: 120,
prop: 'cangkudizhi',
width: 360,
align:'left'
}, {
label: '仓库面积',
prop: 'cangkumianji',
@ -113,10 +121,23 @@
}],
}
},
created() {
created() {
this.getArea()
this.getList()
},
methods: {
methods: {
getArea(){
getparameteritem("area").then(res=>{
this.areaList = res.detail
})
},
clearArea(e){
if(e){
this.select.area = e
}else{
this.select.area = ''
}
},
async getList() {
const res = await index({
...this.select,
@ -124,6 +145,10 @@
key:'cangkumingcheng',
op:'like',
value:this.select.keyword
},{
key:'quyu_id',
op:'eq',
value:this.select.area
}],
})
this.list = res.data

@ -4,7 +4,10 @@
<lx-header icon="md-apps" text="仓库管理" style="margin-bottom: 10px; border: 0px; margin-top: 15px">
<slot>
<div style="display: flex;justify-content: flex-start;flex-wrap: wrap;">
<Input v-model="select.keyword" style="width: 200px;margin-right: 10px;" placeholder="名称搜索" />
<Input v-model="select.keyword" style="width: 200px;margin-right: 10px;" placeholder="名称搜索" />
<Select @on-change="clearArea" v-model="select.area" style="width: 200px;margin-right: 10px;" placeholder="所在区域" clearable>
<Option v-for="item in areaList" :key="item.id" :value="item.id">{{ item.value }}</Option>
</Select>
<Button type="primary" @click="getList"></Button>
<Button type="primary" style="margin-left: 10px;" @click="$refs['addStorage'].type='add',
$refs['addStorage'].isShow=true">添加</Button>
@ -18,7 +21,7 @@
<xy-table :list="list" :total="total" @pageSizeChange="pageSizeChange" @pageIndexChange="pageChange"
:table-item="table">
<template v-slot:btns>
<el-table-column fixed="right" label="操作" width="260" header-align="center">
<el-table-column fixed="right" label="操作" align="center" width="120" header-align="center">
<template slot-scope="scope">
<div>
<Button type="primary" size="small" @click="$refs['addStorage'].type='editor',
@ -43,7 +46,10 @@
index,
destroy
} from "@/api/system/baseForm.js"
import addStorage from './components/addStorage.vue'
import addStorage from './components/addStorage.vue'
import {
getparameteritem
} from "@/api/system/dictionary.js"
export default {
components: {
addStorage,
@ -55,8 +61,10 @@
page: 1,
page_size: 10,
keyword: '',
table_name: 'materialstorages'
},
table_name: 'materialstorages',
area:''
},
areaList:[],
total: 0,
list: [],
table: [{
@ -67,15 +75,17 @@
}, {
label: '仓库名称',
prop: 'cangkumingcheng',
width: 240,
align: 'left',
fixed: 'left'
}, {
label: '仓库编码',
prop: 'cangkubianma',
align: 'left',
width: 240
}, {
},
// {
// label: '',
// prop: 'cangkubianma',
// align: 'left',
// width: 240
// },
{
label: '所在区域',
prop: 'suozaiquyu',
width: 120,
@ -86,7 +96,8 @@
}, {
label: '仓库地址',
prop: 'cangkudizhi',
width: 120,
width: 360,
align:'left'
}, {
label: '仓库面积',
prop: 'cangkumianji',
@ -109,10 +120,23 @@
}],
}
},
created() {
created() {
this.getArea()
this.getList()
},
methods: {
methods: {
getArea(){
getparameteritem("area").then(res=>{
this.areaList = res.detail
})
},
clearArea(e){
if(e){
this.select.area = e
}else{
this.select.area = ''
}
},
async getList() {
const res = await index({
...this.select,
@ -120,6 +144,10 @@
key:'cangkumingcheng',
op:'like',
value:this.select.keyword
},{
key:'quyu_id',
op:'like',
value:this.select.area
}],
})
this.list = res.data

Loading…
Cancel
Save