From a3716f72066d25d745f4d5103ff23a553c3e102b Mon Sep 17 00:00:00 2001 From: wayne <wayne8692wayne8692@gmail.com> Date: 星期四, 17 二月 2022 11:41:19 +0800 Subject: [PATCH] Merge branch 'sit' into uat --- PAMapp/pages/recommendConsultant/index.vue | 766 +++++++++++++++++++++++++++++----------------------------- 1 files changed, 381 insertions(+), 385 deletions(-) diff --git a/PAMapp/pages/recommendConsultant/index.vue b/PAMapp/pages/recommendConsultant/index.vue index e313313..0a405f6 100644 --- a/PAMapp/pages/recommendConsultant/index.vue +++ b/PAMapp/pages/recommendConsultant/index.vue @@ -1,9 +1,10 @@ <template> - <div class="pam-rec-cosultant-page"> + <div class="pam-rec-consultant-page"> <div class="pb-10 mdTxt">憿批��批</div> - <SingleSelectBtn :singleSelected.sync="strictQueryDto.gender" :options="genderOptions"/> + <SingleSelectBtn :singleSelected.sync="strictQueryDto.gender" + :options="genderOptions" /> <div class="pam-paragraph"> - <div class="pb-10 mdTxt required">憿批������</div> + <div class="pb-10 mdTxt required">憿批�����</div> <div class="job-pick" @click="showAddress = true"> <input class="text--middle cursor--pointer input pl-10" @@ -12,10 +13,8 @@ readonly> <i class="icon-down down-icon"></i> </div> - <PopUpFrame :isOpen.sync="showAddress" - > - <AddressPicker - @confirm="confirmAddress" /> + <PopUpFrame :isOpen.sync="showAddress"> + <AddressPicker @confirm="confirmAddress" /> </PopUpFrame> </div> <div class="pam-paragraph"> @@ -24,16 +23,20 @@ <span class="hint text--bold"> (�銴) </span> - <i class="icon-information text--bold fix-chrome-click--issue" @click="showDialog = true"></i> + <i class="icon-information text--bold fix-chrome-click--issue" + @click="showDialog = true"></i> </div> - <MultiSelectBtn :mutiSelect.sync="strictQueryDto.requirements" :options="requirementOptions" class="rec-multi-select" /> + <MultiSelectBtn :mutiSelect.sync="strictQueryDto.requirements" + :options="requirementOptions" + class="rec-multi-select" /> </div> <div class="pam-paragraph"> <div class="pb-10 mdTxt">憿批�僑鞈�</div> - <SingleSelectBtn :singleSelected.sync="strictQueryDto.seniority" :options="seniorityOptions"/> + <SingleSelectBtn :singleSelected.sync="strictQueryDto.seniority" + :options="seniorityOptions" /> </div> - <div class="pam-paragraph"> - <div class="pb-10 mdTxt">靽憿批�遛��漲</div> + <div class="pam-paragraph" v-if="!hideReviews"> + <div class="pb-10 mdTxt">憿批�遛��漲</div> <el-rate class="pam-consultant-rate" v-model="strictQueryDto.avgScore"> </el-rate> </div> @@ -43,10 +46,12 @@ <div class="hint text--bold ml-10">(�銴)</div> </div> <div class="rec-pop-container"> - <MultiSelectBtn :mutiSelect.sync="strictQueryDto.popularTags" - :options="popularOptions" - :nameOfOtherOption="'#�隞�'" :otherSelect.sync="strictQueryDto.otherPopularTags" class="rec-pop-options"/> - </div> + <MultiSelectBtn :mutiSelect.sync="strictQueryDto.popularTags" + :options="popularOptions" + :nameOfOtherOption="'#�隞�'" + :otherSelect.sync="strictQueryDto.otherPopularTags" + class="rec-pop-options" /> + </div> </div> <div class="rec-footer pam-paragraph"> <el-button type="primary" @@ -54,8 +59,7 @@ @click="makePair">擐砌����</el-button> </div> - <PopUpFrame :isOpen.sync="showDialog" - > + <PopUpFrame :isOpen.sync="showDialog"> <div class="qaTextTitle mdTxt"> <strong>�閬岷������</strong> </div> @@ -69,119 +73,112 @@ </div> </div> <div class="text--center mdTxt mt-30"> - <el-button type="primary" @click="showDialog = false">������</el-button> + <el-button type="primary" + @click="showDialog = false">������</el-button> </div> </PopUpFrame> <PopUpFrame :isOpen.sync="isVisiblePopUp"> <div class="text--center mdTxt"> - <p class="mb-50">撠��鞈��</p> - <div class="text--center mdTxt"> - <el-button type="primary" @click="isVisiblePopUp = false">������</el-button> - </div> + <p class="mb-50">撠��鞈��</p> + <div class="text--center mdTxt"> + <el-button type="primary" + @click="isVisiblePopUp = false">������</el-button> </div> + </div> </PopUpFrame> </div> </template> <script lang="ts"> - import { - Vue, - Component, - Mutation, - namespace, - Action, - State - } from 'nuxt-property-decorator'; - import * as _ from 'lodash'; - import { Seniority } from '~/assets/ts/models/enum/seniority'; - import { setRequestQuestionToStorage } from '~/assets/ts/storageRequests'; + import { Action, Component, Mutation, namespace ,State,Vue } from "nuxt-property-decorator"; + import { StrictQueryDto } from "~/shared/models/strictQueryDto.model"; + import { Gender } from "~/shared/models/enum/Gender"; + import { Seniority } from "~/shared/models/enum/seniority"; + import { hideReviews } from '~/shared/const/hide-reviews'; + const localStorage = namespace('localStorage'); - @Component export default class RecommendConsultant extends Vue { isVisiblePopUp = false; - strictQueryDto: StrictQueryDto ={ - gender:'', - area:'', - status:'', + hideReviews = hideReviews; + strictQueryDto: StrictQueryDto = { + gender: '', + area: '', + status: '', requirements: [], - otherRequirement:'', - seniority:'', - avgScore:0, + otherRequirement: '', + seniority: '', + avgScore: 0, popularTags: [], - otherPopularTags:'', + otherPopularTags: '', }; - genderOptions=[ - { - title:'���', - label:Gender.MALE, + genderOptions = [{ + title: '���', + label: Gender.MALE, }, { - title:'憟單��', - label:Gender.FEMALE, + title: '憟單��', + label: Gender.FEMALE, } ]; - requirementOptions=[ - { - title:'�摨瑁����', - label:'�摨瑁����', + requirementOptions = [{ + title: '�摨瑁����', + label: '�摨瑁����', }, { - title:'摮戊��', - label:'摮戊��', + title: '摮戊��', + label: '摮戊��', }, { - title:'鞈閬��', - label:'鞈閬��', + title: '鞈閬��', + label: '鞈閬��', }, { - title:'璅暑��隡�', - label:'璅暑��隡�', + title: '璅暑��隡�', + label: '璅暑��隡�', }, { - title:'靽�瑼�/閬��', - label:'靽�瑼�/閬��', + title: '靽�瑼�/閬��', + label: '靽�瑼�/閬��', }, { - title:'����', - label:'����', + title: '����', + label: '����', }, ]; - seniorityOptions=[ - { - title:'銝��', - subTitle:'撟湧翩銝����', - label:Seniority.UNLIMITED, + seniorityOptions = [{ + title: '銝��', + subTitle: '撟湧翩銝����', + label: Seniority.UNLIMITED, }, { - title:'撟渲��', - subTitle:'蝯血僑頛犖銝�����', - label:Seniority.YOUNG, + title: '撟渲��', + subTitle: '蝯血僑頛犖銝�����', + label: Seniority.YOUNG, }, { - title:'鞈楛', - subTitle:'����麾', - label:Seniority.SENIOR, + title: '鞈楛', + subTitle: '����麾', + label: Seniority.SENIOR, } ]; - popularOptions=[ - { + popularOptions = [{ title: '#��', - label:'��' + label: '��' }, { title: '#憭梯', - label:'憭梯' + label: '憭梯' }, { title: '#����', - label:'����' + label: '����' }, { title: '#����', - label:'����' + label: '����' }, { title: '#憯賡', @@ -189,19 +186,18 @@ }, { title: '#����', - label:'����' + label: '����' }, { title: '#����', - label:'����' + label: '����' }, { title: '#����', - label:'����' + label: '����' } ]; - queaAboutList = [ - { + queaAboutList = [{ title: '�摨瑁����', content: '����澈擃憿批末嚗�靽�兢蝳�嚗��������嚗��飩������摮拙��粥銝��頝荔�犖����迤閬����' }, @@ -223,26 +219,34 @@ }, { title: '����', - content: '���� ���������憸券�����鈭怒�����嚗���摰帘摰漲嚗��隞亙��澈��ˊ�靽���嚗�' + content: '���������憸券�����鈭怒�����嚗���摰帘摰漲嚗��隞亙��澈��ˊ�靽���嚗�' } ]; showDialog = false; showAddress = false; - @Mutation updateStrictQueryList!: (data: any) => void; - @Action storeStrictQueryList!: (data: any) => Promise<number>; - @State strictQueryList!: any; - @localStorage.State recommendConsultantItem!: string; + @Mutation + updateStrictQueryList!: (data: any) => void; + @Action + storeStrictQueryList!: (data: any) => Promise < number > ; + + @State + strictQueryList!: any; + + @localStorage.State + recommendConsultantItem!: string; + + ////////////////////////////////////////////////////////////////////// mounted() { if (!!this.recommendConsultantItem) { this.strictQueryDto = JSON.parse(this.recommendConsultantItem); } } + + ////////////////////////////////////////////////////////////////////// async makePair() { await this.storeStrictQueryList(this.strictQueryDto).then(dataLength => { - const questions = this.strictQueryDto.requirements.length ? this.strictQueryDto.requirements : []; - setRequestQuestionToStorage(questions); if (dataLength === 0) { this.isVisiblePopUp = true; return; @@ -250,329 +254,321 @@ this.$router.push('/recommendConsultant/result'); }); } - get notFinishByRequireRules():boolean{ - const area = this.strictQueryDto.area; - const requirementLength = this.strictQueryDto.requirements - ? this.strictQueryDto.requirements.length - : 0; - return !(area && requirementLength >0) - } confirmAddress(area: string) { this.strictQueryDto.area = area; this.showAddress = false; } - } - enum Gender{ - MALE="male", - FEMALE="female", + ////////////////////////////////////////////////////////////////////// + get notFinishByRequireRules(): boolean { + const area = this.strictQueryDto.area; + const requirementLength = this.strictQueryDto.requirements + ? this.strictQueryDto.requirements.length + : 0; + return !(area && requirementLength > 0) + } } - export interface StrictQueryDto { - gender: string, - area: string, - status: string, - requirements: string[], - otherRequirement: string, - seniority: string, - avgScore: number, - popularTags: string[], - otherPopularTags: string - } </script> <style lang="scss"> + .pam-rec-consultant-page { + .rec-pop-container { + width: 310px; -.pam-rec-cosultant-page { - .rec-pop-container{ - width:310px; - .rec-pop-options{ - .el-checkbox-group{ - display: flex; - flex-wrap: wrap; - flex-direction: row; - .el-checkbox{ - width:90px; - height: 50px; - padding:0; - .el-checkbox__label{ - justify-content: center; - align-items: center; - display: flex; - padding:15px 20px; - text-align: center; + .rec-pop-options { + .el-checkbox-group { + display: flex; + flex-wrap: wrap; + flex-direction: row; + + .el-checkbox { + width: 90px; + height: 50px; + padding: 0; + + .el-checkbox__label { + justify-content: center; + align-items: center; + display: flex; + padding: 15px 20px; + text-align: center; + } } - } - .pam-selectAll-btn{ - margin-top: 60px; - margin-left:-203px; - height: 50px; - width: 90px; - padding: 10px; - } + .pam-selectAll-btn { + margin-top: 60px; + margin-left: -203px; + height: 50px; + width: 90px; + padding: 10px; + } + + } + } + + } + + .rec-multi-select { + .el-checkbox-group { + display: flex; + flex-direction: column; + align-items: flex-start; } } - } - .rec-multi-select{ - .el-checkbox-group { + input:focus, + textarea:focus { + outline: none; + } + + .input { + border: none; + width: 90%; + border-radius: 10px; + } + + .job-pick { + height: 50px; + border-radius: 10px; + border: 1px solid #D0D0CE; display: flex; - flex-direction: column; - align-items: flex-start; + justify-content: space-between; + background-color: #FFFFFF; } - } - input:focus, - textarea:focus { - outline: none; - } - - .input { - border: none; - width: 90%; - border-radius: 10px; - } - - .job-pick { - height: 50px; - border-radius: 10px; - border: 1px solid #D0D0CE; - display: flex; - justify-content: space-between; - background-color: #FFFFFF; - } - - .down-icon { - color: #ED1B2E; - font-size: 25px; - align-self: center; - margin-right: 15px; - } - - .popOtherBtn { - margin-left: -190px; - margin-top: 45px; - } - - .genderBtn { - width: 80px; - height: 47px; - display: contents; - } - - .qa-dialog { - overflow-y: auto; - height: 60vh; - margin-top: 20px; - text-align: justify; - } - - .qaTextTitle { - margin-top: 30px - } - - .qa-dialog-footer { - display: flex; - justify-content: center; - margin-bottom: 81px; - color: #ED1B2E; - cursor: pointer; - } - - .el-drawer__container ::-webkit-scrollbar { - display: none; - } - .el-button+.el-button { - margin-left: 0; - } - - .seniority-choice { - display: flex; - flex-wrap: wrap; - } - - .area-choice { - height: 50px; - border-radius: 10px; - border: 1px solid #D0D0CE; - display: flex; - justify-content: space-between; - background-color: #FFFFFF; - } - - .area-icon { - color: #ED1B2E; - font-size: 25px; - display: flex; - justify-content: flex-end; - padding-right: 16px; - padding-top: 11px; - } - - input::-webkit-input-placeholder { - font-size: 20px; - padding-left: 10px; - } - - .el-button.is-disabled { - font-size: 20px; - border-radius: 20px; - color: #FFFFFF; - background-color: #A7A8AA; - border: 1px solid #A7A8AA; - } - - .rec-footer { - height: 70px; - display: flex; - justify-content: center; - align-items: center; - } - - .other-PopBtn { - width: 90px; - height: 47px; - margin-top: 10px; - } - - - - .rec-ques-location { - display: flex; - align-items: center; - } - - .pop-tag { - display: flex; - flex-wrap: wrap; - margin: -10px; - - } - - .rec-popular { - display: flex; - align-items: baseline; - padding-top: 10px; - margin-bottom: 10px; - } - - .rec-btn-type { - padding-bottom: 10px; - } - - .rec-question { - display: flex; - flex-direction: column; - - } - - .rec-banner { - height: 120px; - background-color: #D0D0CE; - - } - - .rec-btn { - font-size: 20px; - border-radius: 20px; - color: black; - border: 1px solid #D0D0CE; - } - - .rec-pop-btn { - font-size: 20px; - border-radius: 20px; - color: black; - margin: 0px 0px 10px 10px; - border: 1px solid #D0D0CE; - width: 90px; - height: 47px; - } - - .el-progress__text { - display: none; - } - - .el-progress-bar { - padding-right: 0; - } - - .el-progress-bar__inner { - background-color: #ED1B2E; - } - - .required { - position: relative; - - &::before { - content: '*'; - position: absolute; - color: #FF0000; - transform: translate(-12px, 0); - z-index: 5; - } - } - - .area-txt { - display: flex; - align-items: center; - margin-left: 18px; - } - - @include desktop { - - .desktopBtn { - margin-right: 10px; - height: 47px + .down-icon { + margin-right: 15px; } .popOtherBtn { - margin-left: 10px; - margin-top: -10px; + margin-left: -190px; + margin-top: 45px; } - .rec-pop-container{ - width:auto; - .rec-pop-options{ - .el-checkbox-group{ - display: flex; - flex-wrap:wrap; - flex-direction: none; - .el-checkbox{ - width:90px; - height: 50px; - padding:0; - .el-checkbox__label{ - justify-content: center; - align-items: center; - display: flex; - padding:15px 20px; - text-align: center; - } - } - .pam-selectAll-btn{ - margin-top:0px; - margin-left:0px; - height: 50px; - width: 90px; - padding: 10px; - } + .genderBtn { + width: 80px; + height: 47px; + display: contents; + } + + .qa-dialog { + overflow-y: auto; + height: 60vh; + margin-top: 20px; + text-align: justify; + } + + .qaTextTitle { + margin-top: 30px + } + + .qa-dialog-footer { + display: flex; + justify-content: center; + margin-bottom: 81px; + color: #ED1B2E; + cursor: pointer; + } + + .el-drawer__container ::-webkit-scrollbar { + display: none; + } + + .el-button+.el-button { + margin-left: 0; + } + + .seniority-choice { + display: flex; + flex-wrap: wrap; + } + + .area-choice { + height: 50px; + border-radius: 10px; + border: 1px solid #D0D0CE; + display: flex; + justify-content: space-between; + background-color: #FFFFFF; + } + + .area-icon { + color: #ED1B2E; + font-size: 25px; + display: flex; + justify-content: flex-end; + padding-right: 16px; + padding-top: 11px; + } + + input::-webkit-input-placeholder { + font-size: 20px; + padding-left: 10px; + } + + .el-button.is-disabled { + font-size: 20px; + border-radius: 20px; + color: #FFFFFF; + background-color: #A7A8AA; + border: 1px solid #A7A8AA; + } + + .rec-footer { + height: 70px; + display: flex; + justify-content: center; + align-items: center; + } + + .other-PopBtn { + width: 90px; + height: 47px; + margin-top: 10px; + } + + + + .rec-ques-location { + display: flex; + align-items: center; + } + + .pop-tag { + display: flex; + flex-wrap: wrap; + margin: -10px; + + } + + .rec-popular { + display: flex; + align-items: baseline; + padding-top: 10px; + margin-bottom: 10px; + } + + .rec-btn-type { + padding-bottom: 10px; + } + + .rec-question { + display: flex; + flex-direction: column; + + } + + .rec-banner { + height: 120px; + background-color: #D0D0CE; + + } + + .rec-btn { + font-size: 20px; + border-radius: 20px; + color: black; + border: 1px solid #D0D0CE; + } + + .rec-pop-btn { + font-size: 20px; + border-radius: 20px; + color: black; + margin: 0px 0px 10px 10px; + border: 1px solid #D0D0CE; + width: 90px; + height: 47px; + } + + .el-progress__text { + display: none; + } + + .el-progress-bar { + padding-right: 0; + } + + .el-progress-bar__inner { + background-color: #ED1B2E; + } + + .required { + position: relative; + + &::before { + content: '*'; + position: absolute; + color: #FF0000; + transform: translate(-12px, 0); + z-index: 5; } } - } - - .rec-multi-select{ - .el-checkbox-group { + .area-txt { display: flex; - flex-direction: row; - align-items: flex-start; - flex-wrap: wrap; + align-items: center; + margin-left: 18px; + } + + @include desktop { + + .desktopBtn { + margin-right: 10px; + height: 47px + } + + .popOtherBtn { + margin-left: 10px; + margin-top: -10px; + } + + .rec-pop-container { + width: auto; + + .rec-pop-options { + .el-checkbox-group { + display: flex; + flex-wrap: wrap; + flex-direction: none; + + .el-checkbox { + width: 90px; + height: 50px; + padding: 0; + + .el-checkbox__label { + justify-content: center; + align-items: center; + display: flex; + padding: 15px 20px; + text-align: center; + } + } + + .pam-selectAll-btn { + margin-top: 0px; + margin-left: 0px; + height: 50px; + width: 90px; + padding: 10px; + } + } + } + + } + + .rec-multi-select { + .el-checkbox-group { + display: flex; + flex-direction: row; + align-items: flex-start; + flex-wrap: wrap; + } + } } } - } -} </style> -- Gitblit v1.8.0