From ab9d102ce99644f73ff365a1e70afbda1e14276d Mon Sep 17 00:00:00 2001 From: Tomas <tomasysh@gmail.com> Date: 星期五, 28 七月 2023 12:03:32 +0800 Subject: [PATCH] Update: 顧問諮詢方式欄位(畫面) --- PAMapp/components/Consultant/ConsultantCard.vue | 1 + PAMapp/pages/questionnaire/_agentNo.vue | 20 +++++++++++++++++++- PAMapp/pages/index.vue | 2 ++ PAMapp/components/Client/ClientCard.vue | 1 + PAMapp/plugins/filters/consult-type.filter.ts | 15 +++++++++++++++ PAMapp/shared/models/appointment.model.ts | 3 ++- PAMapp/nuxt.config.js | 5 +++-- PAMapp/pages/appointment/_appointmentId/index.vue | 5 +++++ 8 files changed, 48 insertions(+), 4 deletions(-) diff --git a/PAMapp/components/Client/ClientCard.vue b/PAMapp/components/Client/ClientCard.vue index 3ab3c19..2ac0c38 100644 --- a/PAMapp/components/Client/ClientCard.vue +++ b/PAMapp/components/Client/ClientCard.vue @@ -118,6 +118,7 @@ <p>�批嚗�<span>{{gender}}</span></p> <p>撟湧翩嚗�<span>{{client.age | toAgeLabel }}</span></p> <p>�璆哨��<span>{{client.job}}</span></p> + <p>隢株岷�撘��<span>{{client.consultantMode }}</span></p> <p>��瘙��<span>{{ client.requirement ? client.requirement.split(',').join('��') : '--' }}</span></p> <p v-for="(item, index) in hopeContactTime" :key="index" diff --git a/PAMapp/components/Consultant/ConsultantCard.vue b/PAMapp/components/Consultant/ConsultantCard.vue index 464c572..a4d80be 100644 --- a/PAMapp/components/Consultant/ConsultantCard.vue +++ b/PAMapp/components/Consultant/ConsultantCard.vue @@ -76,6 +76,7 @@ <p>�批嚗{gender}}</p> <p>撟湧翩嚗{appointmentDetail.age | toAgeLabel }}</p> <p>�璆哨�{appointmentDetail.job}}</p> + <p>隢株岷�撘�{appointmentDetail.consultantMode }}</p> <p>��瘙�{appointmentDetail.requirement ? appointmentDetail.requirement.split(',').join('��') : '--'}}</p> <p v-for="(item, index) in hopeContactTime" diff --git a/PAMapp/nuxt.config.js b/PAMapp/nuxt.config.js index 0bc5544..a5bf824 100644 --- a/PAMapp/nuxt.config.js +++ b/PAMapp/nuxt.config.js @@ -39,6 +39,7 @@ '~/plugins/vue-scroll-picker', '~/plugins/filters/date.filter.ts', '~/plugins/filters/age.filter.ts', + '~/plugins/filters/consult-type.filter.ts', '~/plugins/filters/appointment-fail-reason.filter.ts', '~/plugins/filters/serve-area.filter.ts', ], @@ -62,7 +63,7 @@ // modules: [ // '@nuxtjs/gtm', // ], - + // plugins: [ // '~/plugins/gtm' // ], @@ -71,7 +72,7 @@ enabled: true, /* see below */ debug: false, - id: process.env.ENV === 'prod' + id: process.env.ENV === 'prod' ? 'GTM-TFKVGTH' : process.env.ENV === 'uat' ? 'GTM-W2XMVJZT' : 'GTM_XXXXXXX', layer: 'dataLayer', diff --git a/PAMapp/pages/appointment/_appointmentId/index.vue b/PAMapp/pages/appointment/_appointmentId/index.vue index 2a6d46e..4bb95b0 100644 --- a/PAMapp/pages/appointment/_appointmentId/index.vue +++ b/PAMapp/pages/appointment/_appointmentId/index.vue @@ -38,6 +38,11 @@ <div class="client-detail-demand mt-10"> <div class="client-detail-demand__demand-list mb-10"> + <div class="client-detail-demand__demand-list-label">隢株岷<br />�撘�</div> + <div class="client-detail-demand__demand-list-content">{{ appointmentDetail.consultantMode | toConsulType }}</div> + </div> + + <div class="client-detail-demand__demand-list mb-10"> <div class="client-detail-demand__demand-list-label">��瘙�</div> <div class="client-detail-demand__demand-list-content">{{ appointmentDetail.requirement || '--' }}</div> </div> diff --git a/PAMapp/pages/index.vue b/PAMapp/pages/index.vue index 0826e0c..22cbb6f 100644 --- a/PAMapp/pages/index.vue +++ b/PAMapp/pages/index.vue @@ -59,6 +59,7 @@ <p>�批嚗{gender}}</p> <p>撟湧翩嚗{appointmentDetail.age | toAgeLabel }}</p> <p>�璆哨�{appointmentDetail.job}}</p> + <p>隢株岷�撘�{appointmentDetail.consultantMode }}</p> <p>��瘙�{ appointmentDetail.requirement ? appointmentDetail.requirement.split(',').join('��') : '--'}}</p> <p v-for="(item, index) in hopeContactTime" @@ -244,6 +245,7 @@ phone : '', requirement : '', satisfactionScore : 0, + consultantMode : '' }; agentInfo: Consultant = { diff --git a/PAMapp/pages/questionnaire/_agentNo.vue b/PAMapp/pages/questionnaire/_agentNo.vue index 553ccee..0c0c815 100644 --- a/PAMapp/pages/questionnaire/_agentNo.vue +++ b/PAMapp/pages/questionnaire/_agentNo.vue @@ -78,6 +78,12 @@ :options="requirementOptions" /> </div> <div class="pam-paragraph"> + <div class="mdTxt">隢株岷�撘�</div> + <SingleSelectBtn class="mt-10" + :singleSelected.sync="myRequest.consultantMode" + :options="consultantModeOptions" /> + </div> + <div class="pam-paragraph"> <div class="mdTxt">����批</div> <SingleSelectBtn class="mt-10" :singleSelected.sync="myRequest.gender" @@ -201,6 +207,17 @@ } ]; + consultantModeOptions = [ + { + title: '蝺��', + label: 'ONLINE' + }, + { + title: '蝺��', + label: 'OFFLINE' + } + ]; + requirementOptions=[ { title:'�摨瑁����', @@ -300,6 +317,7 @@ selectTimesOptions: [], }], agentNo: '', + consultantMode: '', }; showDrawer= false; @@ -416,7 +434,7 @@ return { ...appointmentInfo, hopeContactTime: hopeContactTime, - requirement: appointmentInfo.requirement + requirement: appointmentInfo.requirement ? appointmentInfo.requirement.split(',') : [] } diff --git a/PAMapp/plugins/filters/consult-type.filter.ts b/PAMapp/plugins/filters/consult-type.filter.ts new file mode 100644 index 0000000..8eb65ab --- /dev/null +++ b/PAMapp/plugins/filters/consult-type.filter.ts @@ -0,0 +1,15 @@ +import Vue from 'vue' + +Vue.filter('toConsulType', (value: string): string => { + + if (!value || typeof value !== 'string') { + return '--'; + }; + + const consultantTypeLabel = { + 'ONLINE': '蝺��', + 'OFFLINE': '蝺��', + }; + + return consultantTypeLabel[value]; +}) diff --git a/PAMapp/shared/models/appointment.model.ts b/PAMapp/shared/models/appointment.model.ts index 9bb43ba..4342486 100644 --- a/PAMapp/shared/models/appointment.model.ts +++ b/PAMapp/shared/models/appointment.model.ts @@ -40,6 +40,7 @@ phone : string; requirement : string; satisfactionScore : number; + consultantMode : string; }; export interface AppointmentClosedInfo { @@ -123,8 +124,8 @@ job : string; phone : string; requirement : string[]; + consultantMode : string; } - export interface ContactTime { selectTimesOptions: string[]; selectWeekOptions : string[]; -- Gitblit v1.8.0