Browse Source

工作日志

pengjing 1 year ago
parent
commit
7de187e0fc
1 changed files with 12 additions and 11 deletions
  1. 12 11
      h5app/src/views/pages/work/log/edit.vue

+ 12 - 11
h5app/src/views/pages/work/log/edit.vue

@@ -54,7 +54,8 @@ export default defineComponent({
     const router = useRouter();
     const route = useRoute();
     const dataModel = ref<DataModel>({
-      name: ''
+      name: '',
+      logDate: null
     });
 
     const onSave = () => {
@@ -84,7 +85,7 @@ export default defineComponent({
     };
 
     const initData = (id: any) => {
-      dataModel.value = {name: '', statusVal: 1};
+      dataModel.value = {name: '', logDate: null};
       loadData(id);
     };
 
@@ -105,13 +106,13 @@ export default defineComponent({
       await alert.present();
     }
 
-   /* const inputBlur = (e: any) => {
-      if (dataModel.value.logDate == null)
-        e.target.setAttribute('placeholder', '出生年月日');
-    }
-    const inputFocus = (e: any) => {
-      e.target.removeAttribute('placeholder');
-    }*/
+    /* const inputBlur = (e: any) => {
+       if (dataModel.value.logDate == null)
+         e.target.setAttribute('placeholder', '出生年月日');
+     }
+     const inputFocus = (e: any) => {
+       e.target.removeAttribute('placeholder');
+     }*/
 
 
     return {
@@ -122,8 +123,8 @@ export default defineComponent({
       route,
       arrowBackOutline,
       router,
-     /* inputBlur,
-      inputFocus*/
+      /* inputBlur,
+       inputFocus*/
     }
   }
 });