@@ -73,6 +73,7 @@ export default {
visible(val){
if(!this.visible){
this.clear();
+ this.$emit('close')
}
},
@@ -770,7 +770,11 @@ export default {
saveTask(data).then(res => {
this.$toast('提交成功')
- this.$router.go(-1)
+ this.$router.replace({
+ path: '/resumption',
+ name: 'resumption',
+ params:{event:'refresh'}
+ });
})
}catch(e){
this.nfcs = bakNfcs;
@@ -141,7 +141,7 @@ import {getDict} from "@/api/toConsult";
import DateCell from "@/components/dateCell/index.vue";
export default {
- name: 'lvzhi',
components:{DateCell, NavBar,DatePicker,Empty},
data(){
return{
@@ -184,7 +184,9 @@ export default {
beforeRouteEnter(to,from,next){
next(vm=>{
- vm.getDatalist();
+ if(to.params.event === 'refresh'){
+ vm.getDatalist();
+ }
methods:{
@@ -136,7 +136,7 @@
<!-- </van-image-preview>-->
<!-- nfc弹窗 -->
- <nfc-popup v-if="enable" ref="NfcPopup" @checkNFC="checkNFC" @change="changeNfcImg"></nfc-popup>
+ <nfc-popup v-if="enable" ref="NfcPopup" @checkNFC="checkNFC" @close="onClose" @change="changeNfcImg"></nfc-popup>
</div>
<!-- 添加检查内容 -->
@@ -237,6 +237,10 @@ export default {
window.openNFCScanCallBack = null;
methods: {
+ onClose(){
+ window.openCameraCallBack = null;
+ window.openNFCScanCallBack = null;
+ },
//长度校验
validator(val) {
let len = val.length;