From ae3aac1ee250fd8207ff41a0f6a9f38f82a18a58 Mon Sep 17 00:00:00 2001
From: Mila <Mila@pollex.com.tw>
Date: 星期六, 22 一月 2022 17:06:14 +0800
Subject: [PATCH] fixed TODO#134587 未聯絡狀態發送約訪通知後,未顯示於約訪中列表

---
 PAMapp/components/Interview/InterviewMsg.vue |   26 ++++++++++++++++++++++++--
 1 files changed, 24 insertions(+), 2 deletions(-)

diff --git a/PAMapp/components/Interview/InterviewMsg.vue b/PAMapp/components/Interview/InterviewMsg.vue
index 7ed83ca..be4a0b9 100644
--- a/PAMapp/components/Interview/InterviewMsg.vue
+++ b/PAMapp/components/Interview/InterviewMsg.vue
@@ -9,7 +9,6 @@
         <div class="subTitle msg-dialog-title">蝝赤�</div>
       <div class="send-msg-nav">
         <div class="mdTxt">��摰�</div>
-        <div class="mdTxt text--primary text--underline">蝺刻摩</div>
       </div>
 
       <el-input
@@ -21,9 +20,11 @@
         </el-input>
 
       <div v-if="client.phone">
-        <div class="mdTxt mt-30 mb-10">����赤��挾</div>
+        <div class="mdTxt mt-30 mb-10 required">����赤��挾</div>
         <DateTimePicker
           @changeDateTime="interviewTime = $event"
+          :isPastDateDisabled="true"
+          :defaultValue="defaultValue"
         ></DateTimePicker>
       </div>
 
@@ -50,12 +51,19 @@
 import { AgentInfo } from '~/shared/models/agent-info.model';
 
 const loginStore = namespace('login.store');
+const appointmentStore = namespace('appointment.store');
 
 @Component
 export default class InterviewMsg extends Vue {
 
     @Action
     storeMyAppointmentList!: () => Promise<number>;
+
+    @appointmentStore.Action
+    updateAppointmentDetail!: (id: number) => Appointment;
+
+    @appointmentStore.Action
+    getMyAppointmentList!: () => Promise<Appointment[]>;
 
     @PropSync('isVisible')
     dialogVisible!: boolean;
@@ -65,6 +73,9 @@
 
     @Prop()
     client!: Appointment;
+
+    @Prop()
+    defaultValue!: string;
 
     @Emit('closeDialog')
     closeDialog() {
@@ -94,6 +105,8 @@
       };
       appointmentService.informAppointment(appointmentInformation).then((_) => {
         this.isShowSuccessAlert = true ;
+        this.updateAppointmentDetail(this.client.id);
+        this.getMyAppointmentList();
       });
     }
 
@@ -114,6 +127,15 @@
 <style lang="scss" >
 .interview-msg-component{
 
+  .required {
+  position: relative;
+  &::before {
+      content: '*';
+      position: absolute;
+      color: #FF0000;
+      transform: translate(-12px, 0);
+    }
+  }
   .msg-dialog-title{
     display: flex;
     justify-content: center;

--
Gitblit v1.8.0