| | |
| | | |
| | | <i class="icon-down down-icon " style="margin-right:18px" @click="showJobDrawer = true" ></i> |
| | | </div> |
| | | |
| | | <div class="ques-footer pt-30"> |
| | | <el-button type="primary" @click="sentDemand">送出</el-button> |
| | | <el-button type="primary" |
| | | :disabled=" isInitScheduleDisabled || !isSelected" |
| | | @click="sentDemand">送出</el-button> |
| | | </div> |
| | | |
| | | <PopUpFrame :isOpen.sync="showDrawer" :drawerSize=" '95%' "> |
| | |
| | | <PopUpFrame :isOpen.sync="showJobDrawer" drawerSize='60%'> |
| | | <div class="job-drawerTxt fz-20"> |
| | | <div class="subTitle mt-18">職業</div> |
| | | <!-- <p class="mt-30 fz-20" @click="staff ='內勤'" :class="{'jobBtn':staff === '內勤' }">內勤</p> --> |
| | | |
| | | <div class="radio-btn"> |
| | | <el-radio-group class="pam-radio-group--col" v-model="staff"> |
| | | <el-radio-button style="margin-top:30px" text-color='#F09491' label="外勤"></el-radio-button> |
| | |
| | | <div class="fz-20 sendReserve-txt">儘速與您聯絡!</div> |
| | | <div class="qa-dialog-footer mdTxt" @click="closeReservePopUp"><p>我知道了</p></div> |
| | | </PopUpFrame> |
| | | |
| | | </div> |
| | | </template> |
| | | <script lang="ts"> |
| | | import { Vue, Component } from 'vue-property-decorator'; |
| | | import { appointmentDemand } from '~/assets/ts/api/consultant'; |
| | | |
| | | |
| | | @Component |
| | | export default class Questionnaire extends Vue { |
| | | |
| | | gender: 'male'|'female' = 'male'; |
| | | // connectTarget:'mobile'|'email'='mobile'; |
| | | connectDevices = ['1111']; |
| | | connectDevices = new Array(); |
| | | mobileNumber = ''; |
| | | email = ''; |
| | | inputValue=''; |
| | | selectedQuestion: SelectedQuestion[] = []; |
| | | // staff:'in'|'out'|'jobOther'='in'; |
| | | staff = '外勤'; |
| | | |
| | | |
| | | age:'20'|'30'|'40'|'50'|'55'|'60'|'70'|'71' = '20'; |
| | | showDrawer= false; |
| | | showJobDrawer = false; |
| | | sendReserve = false; |
| | | // datepicker Dto |
| | | initScheduleList=[{ |
| | | selectWeekOptions:[], |
| | | selectTimesOptions:[], |
| | | }] |
| | | |
| | | // editJob(targetJob: string): void { |
| | | // const isExist = this.jobList.find((job) => job === targetJob); |
| | | // if (isExist) { |
| | | // const jobIndex = this.jobList.findIndex((job) => job === targetJob); |
| | | // this.jobList.splice(jobIndex, 1); |
| | | // } else { |
| | | // this.jobList.push(targetJob); |
| | | // } |
| | | // } |
| | | queaAboutList=[ |
| | | { |
| | | title:'健康與保障', |
| | |
| | | return true; |
| | | }; |
| | | |
| | | |
| | | get isConnectMobile(): boolean { |
| | | return this.connectDevices.includes('mobile'); |
| | | } |
| | |
| | | mounted() { |
| | | this.agentNo = this.$route.params.agentNo; |
| | | } |
| | | get isSelected() { |
| | | return this.selectedQuestion.findIndex(i => i.selected)>=0 |
| | | } |
| | | |
| | | toggleConnectDevice(selectDevice: 'mobile' | 'email'): void { |
| | | const deviceSelected = this.connectDevices.includes(selectDevice); |
| | | if (deviceSelected) { |
| | | const deviceIndex = this.connectDevices.findIndex((device) => device === selectDevice); |
| | | this.connectDevices.splice(deviceIndex, 1); |
| | | |
| | | if (selectDevice === 'mobile') { |
| | | this.initScheduleList = [{ |
| | | selectWeekOptions:[], |
| | | selectTimesOptions:[], |
| | | }] |
| | | } |
| | | |
| | | if (selectDevice === 'email') { |
| | | this.email = ''; |
| | | } |
| | | return; |
| | | } |
| | | this.connectDevices.push(selectDevice); |
| | | |
| | | } |
| | | |
| | | sentDemand() { |
| | |
| | | closeReservePopUp() { |
| | | this.sendReserve = false; |
| | | this.$router.push('/') |
| | | } |
| | | |
| | | get isInitScheduleDisabled() { |
| | | console.log(this.isConnectMobile) |
| | | if (this.isConnectMobile && this.isConnectEmail) { |
| | | return !this.initScheduleList[0].selectWeekOptions.length || !this.initScheduleList[0].selectTimesOptions.length || !this.email |
| | | } else if (this.isConnectMobile) { |
| | | return !this.initScheduleList[0].selectWeekOptions.length || !this.initScheduleList[0].selectTimesOptions.length |
| | | } else if (this.isConnectEmail) { |
| | | return !this.email |
| | | } |
| | | return true; |
| | | } |
| | | } |
| | | |
| | |
| | | .ques-footer{ |
| | | display: flex; |
| | | justify-content: center; |
| | | |
| | | } |
| | | .job-inputDiv{ |
| | | height:90px; |