Commit 7a90468e authored by renjintao's avatar renjintao

pro

parent 2e4f3489
...@@ -428,12 +428,18 @@ export default { ...@@ -428,12 +428,18 @@ export default {
DipartLocation: { DipartLocation: {
name: "部门", name: "部门",
organizationType: "组织类型", organizationType: "组织类型",
status: '是否生产班组', // status: '是否生产班组',
status: '属性',
departcode: '部门编号', departcode: '部门编号',
department: '部门名称', department: '部门名称',
cityName: '省市县', cityName: '省市县',
creationTime: '创建时间', creationTime: '创建时间',
upMent: '上级部门', upMent: '上级部门',
code:'部门编号',
location:'省市县',
parent_Id:'上级部门',
property:'属性',
parentTitle:'上级部门'
}, },
instance: { instance: {
id: '主键', id: '主键',
......
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
<Upload action :before-upload="beforeUpload" ref="uploadfile" :format="formatList"> <Upload action :before-upload="beforeUpload" ref="uploadfile" :format="formatList">
<Button icon="ios-cloud-upload-outline" @click="resetParms">重新上传</Button> <Button icon="ios-cloud-upload-outline" @click="resetParms">重新上传</Button>
</Upload> </Upload>
<Cascader :data="citys" v-show="false"></Cascader>
</div> </div>
</FormItem> </FormItem>
</Form> </Form>
...@@ -81,6 +82,7 @@ ...@@ -81,6 +82,7 @@
<script> <script>
import Api from "./api"; import Api from "./api";
import BaseColums from "./baseColums"; import BaseColums from "./baseColums";
import citys from "@/libs/citys";
import XLSX from "xlsx"; import XLSX from "xlsx";
import { import {
Switch Switch
...@@ -121,6 +123,10 @@ export default { ...@@ -121,6 +123,10 @@ export default {
treeData: [], //物料管理左侧类别树 treeData: [], //物料管理左侧类别树
codeRuleData: [], //物料编码等信息 codeRuleData: [], //物料编码等信息
routingHeaderData: [], //工艺规程列表信息 routingHeaderData: [], //工艺规程列表信息
//部门管理
treeList: [],
citys: citys(),
cityDatas: [], //省市县在一起
}; };
}, },
props: { props: {
...@@ -144,6 +150,7 @@ export default { ...@@ -144,6 +150,7 @@ export default {
this.getcodeRuleData(); this.getcodeRuleData();
//获取工艺规程信息 //获取工艺规程信息
this.getRoutingHeaderData(); this.getRoutingHeaderData();
this.formatCity();
window.onresize = () => { window.onresize = () => {
///浏览器窗口大小变化 ///浏览器窗口大小变化
return (() => { return (() => {
...@@ -602,6 +609,41 @@ export default { ...@@ -602,6 +609,41 @@ export default {
}); });
} }
}, },
//获取省市县信息
formatCity() {
let list = this.$u.clone(this.treeList);
let cityData = this.$u.clone(this.citys);
let temp = this.$u.treeToList1(cityData);
this.cityDatas = [];
temp.forEach(ele => {
let objTem = {
label: ele.__label.replace(/\s*/g, ""),
value: ele.__value
}
this.cityDatas.push(objTem)
})
},
//根据value获取当前cityname
getCityName(val) {
let cities = this.$u.clone(this.cityDatas)
let label = "";
cities.forEach(ele => {
if (val == ele.value) {
label = ele.label
}
})
return label
},
getCityValue(val) {
let cities = this.$u.clone(this.cityDatas)
let value = "";
cities.forEach(ele => {
if (val == ele.label) {
value = ele.value
}
})
return value
},
//批量插入制造资源 //批量插入制造资源
importResource() { importResource() {
let tempData = this.$u.clone(this.dataIm); let tempData = this.$u.clone(this.dataIm);
......
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