Commit 3f28eccd authored by godwithdh's avatar godwithdh

status

parent f6ab81bf
......@@ -134,11 +134,11 @@
</div>
<div class="list">
<div class="tip">9. 出行明细</div>
<textarea :placeholder="readOnly ? '' : '请输入'" :disabled="status==2" autoHeight="true" v-model="value.sHaveBeenDetail"/>
<textarea :placeholder="status==2 ? '' : '请输入'" :disabled="status==2" autoHeight="true" v-model="value.sHaveBeenDetail"/>
</div>
<div class="list">
<div class="tip">10. 其他情况</div>
<textarea :placeholder="readOnly ? '' : '请输入'" :disabled="status==2" autoHeight="true" v-model="value.sRemark"/>
<textarea :placeholder="status==2 ? '' : '请输入'" :disabled="status==2" autoHeight="true" v-model="value.sRemark"/>
</div>
<button @click="upData" v-if="status!=2">{{!status?'提交':'修改'}}</button>
</div>
......@@ -177,7 +177,6 @@ export default {
iStatus:1,
},
status:0,//0 新增,1 修改,2 只读
readOnly:false,//是否只读
}
},
computed:{
......@@ -186,14 +185,8 @@ export default {
})
},
async activated(){
this.status = this.$route.query.readOnly == 'true' ? 2 : 0;
if(this.$route.query.readOnly == 'true'){
this.status=2
var date=new Date(Number(this.$route.query.dDate))
if(util.dateFormat(date,"yyyy-MM-dd")==util.dateFormat(new Date(),"yyyy-MM-dd")){
this.status=1
}
}
this.status = parseInt(this.$route.query.readOnly)||0
this.value.sCreateAppid=this.$route.params.openId
if(this.status>0){
await this.getHealthDate();
......
......@@ -537,7 +537,7 @@ export default {
this.$router.push({name:'healthCardStatisticsList',params:{type:type}});
},
routerToPunchClockDetail(item){
this.$router.push({name:'punchClockDetail',params:{id:'1',address:'1',openId:item.sCreateAppid},query:{readOnly:'true',dDate:new Date(Util.dateFormat(this.hdr.dDate,'yyyy-MM-dd')).getTime()}})
this.$router.push({name:'punchClockDetail',params:{id:'1',address:'1',openId:item.sCreateAppid},query:{readOnly:'2',dDate:new Date(Util.dateFormat(this.hdr.dDate,'yyyy-MM-dd')).getTime()}})
}
}
}
......
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