var vms = Vue.component("amplify-sjgk", { template: `
`, props: { label:{ type:String }, projectid:{ type:Number } }, data() { return { show:false, fourClarificaiton:{ } } }, mounted(){ console.log(this.projectid) }, methods: { openAmplify(){ this.show = true this.getFourData() }, closeAmplify(){ this.show = false }, closeAmplifyAll(e){ if(e.target.className == 'amplify-fixed'){ this.show = false } }, //四级交底情况 getFourData(){ let that = this axios.get("//api-tmp.makalu.cc/szhjzgkpt/four/clarificaiton").then(res => { that.fourClarificaiton = res.data axios.post("/api/project/selectTechnicalDisclosureInformationList",{ projectId:this.projectid, }).then(res => { let zx = 0 let js = 0 that.fourDataList = res.data.data for(let tmp of res.data.data){ switch (tmp.type) { case 1: js++ tmp.sort = js break case 2: zx++ tmp.sort = zx break } } that.fourClarificaiton.zxfajd = zx that.fourClarificaiton.jsjd = js }) }) }, }, watch:{ projectId:function (n,o) { this.openAmplify() } }, })