Commit fb1541e8 authored by huangjie's avatar huangjie

*

parent 9fc65833
...@@ -173,11 +173,11 @@ export function projectVolume(data) { ...@@ -173,11 +173,11 @@ export function projectVolume(data) {
} }
//措施费-获取实际成本月份列表 //措施费-获取实际成本月份列表
export function actualMonths(data) { export function actualMonths(params) {
return request({ return request({
url: '/cb/cost/measures/actual/months', url: '/cb/cost/measures/actual/months',
method: 'GET', method: 'GET',
params:data params
}); });
} }
......
...@@ -261,10 +261,10 @@ ...@@ -261,10 +261,10 @@
}, },
//可访问data属性 //可访问data属性
created() { created() {
let month = new Date().getMonth() +1 // let month = new Date().getMonth() +1
let year = new Date().getFullYear() // let year = new Date().getFullYear()
this.expenseDate = year + (month>= 9? month:'0'+ month) // this.expenseDate = year + (month>= 9? month:'0'+ month)
this.actualMonths() this.getactualMonths()
}, },
//计算集 //计算集
computed: { computed: {
...@@ -272,16 +272,20 @@ ...@@ -272,16 +272,20 @@
}, },
//方法集 //方法集
methods: { methods: {
actualMonths(){ getactualMonths(){
const formData = new FormData(); const formDatas = new FormData();
formData.append("projectId", this.projectId); formDatas.append("projectId", this.projectId);
formData.append("id", this.id); formDatas.append("id", this.id);
actualMonths(formData).then(res=>{ console.log(formDatas.get('projectId'))
console.log(formDatas.get('id'))
actualMonths(formDatas).then(res=>{
let data = res.data let data = res.data
data.forEach(item=>{ data.forEach(item=>{
item.value = item item.value = item
item.label = item.substring(1,4)+'-'+item.substring(5,6) item.label = item.substring(1,4)+'-'+item.substring(5,6)
}) })
if(data&&data.length>0)
this.expenseDate = data[0].value
}) })
}, },
select(menuPath){ select(menuPath){
...@@ -305,7 +309,7 @@ ...@@ -305,7 +309,7 @@
this.tableData = res.data this.tableData = res.data
}) })
} }
this.actualMonths() this.getactualMonths()
}, },
async init(detail = '') { async init(detail = '') {
try { try {
......
...@@ -283,6 +283,7 @@ ...@@ -283,6 +283,7 @@
uploadtype:0,//上传的版块类型 uploadtype:0,//上传的版块类型
visible:false, visible:false,
issub:false,//已填完数据可以开始解析 issub:false,//已填完数据可以开始解析
isclick:true,
} }
}, },
created() { created() {
...@@ -327,7 +328,7 @@ ...@@ -327,7 +328,7 @@
}) })
}, },
uplpro(type){ uplpro(type){
if(!this.prodetail){ if(!this.prodetail && this.isclick){
this.uploadtype = type this.uploadtype = type
this.$refs.uploadpro.$el.querySelector('input').click() this.$refs.uploadpro.$el.querySelector('input').click()
} }
...@@ -359,6 +360,7 @@ ...@@ -359,6 +360,7 @@
}); });
}, },
handleFileListChange(file, fileList) { handleFileListChange(file, fileList) {
this.isclick = false
var testmsg = file.name.substring(file.name.lastIndexOf(".") + 1); var testmsg = file.name.substring(file.name.lastIndexOf(".") + 1);
const extension = testmsg === "xlsx"; const extension = testmsg === "xlsx";
const extension1 = testmsg === "xls"; const extension1 = testmsg === "xls";
...@@ -408,6 +410,7 @@ ...@@ -408,6 +410,7 @@
default: default:
break break
} }
this.isclick = true
} }
}) })
}, },
......
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