quote1.vue 66 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164
  1. <template>
  2. <view :style="getHeight" style="background-color: #F5F5F5;">
  3. <!-- 头部 -->
  4. <view class="carInfo w-100 px-3 box-sizing">
  5. <view class="d-flex">
  6. <view class="icon iconfont icon-tree-round-car flex-shrink topLeft"></view>
  7. <view class="topRight d-flex flex-1 p-3 flex-column" style="color: #FFFFFF;">
  8. <view class="d-flex flex-1">
  9. <view class="font-lg d-flex a-center">{{this.carInfo.licenseNo}}
  10. <view class="icon iconfont icon-bianji1 ml-2" @tap="toCarInfo"></view>
  11. </view>
  12. </view>
  13. <view class="brandName">{{this.carInfo.modelcname}}</view>
  14. </view>
  15. </view>
  16. <view class="other d-flex j-sb px-3">
  17. <view class="d-flex flex-1 a-center">
  18. <view class="privilege d-flex a-center j-center flex-shrink px-2">特权</view>
  19. <view class="content">每月自动查违章,无违章领奖励</view>
  20. </view>
  21. <view class="flex-shrink icon iconfont icon-youjiantou d-flex a-center font-sm"></view>
  22. </view>
  23. </view>
  24. <!-- 报价方案 -->
  25. <view class="pageContent">
  26. <view class="quotePlan mx-3">
  27. <view class="header j-sb d-flex a-center px-3">
  28. <view class="title font-md">报价方案</view>
  29. <view class="adjustPlan main-text-color" @tap="toInsureItems">调整方案</view>
  30. </view>
  31. <view class="body">
  32. <view class="insurance">
  33. <template v-if="jqstartDate">
  34. <view class="row j-sb d-flex a-center">
  35. <view>交强险</view>
  36. <view>投保</view>
  37. </view>
  38. </template>
  39. <template v-if="systartDate">
  40. <block v-for="(item,index) in insureList" :key="index">
  41. <template v-if="item.amount!=0">
  42. <view class="row j-sb d-flex a-center">
  43. <view>{{item.kindName}}</view>
  44. <block v-for="(item2,index2) in item.amtList" :key="index2">
  45. <template v-if="item2.value == item.amount">
  46. <view>{{item2.label}}</view>
  47. </template>
  48. </block>
  49. </view>
  50. </template>
  51. </block>
  52. </template>
  53. <view class="dis j-s a-c" v-if="jqstartDate">
  54. <view style="margin-right: 40px;">交强起保日期:</view>
  55. <u-input type="select" :select-open="jqstartShow" v-model="jqstartDate"
  56. @click="jqstartShow = true" style="width: 100px;"></u-input>
  57. <u-picker v-model="jqstartShow" mode="time" :params="params"
  58. @confirm="jqstartconfirm"></u-picker>
  59. </view>
  60. <view class="dis j-s a-c" v-if="jqendDate">
  61. <view style="margin-right: 40px;">交强终保日期:</view>
  62. <u-input type="select" :select-open="jqendShow" v-model="jqendDate"
  63. @click="jqendShow = true" style="width: 100px;"></u-input>
  64. <u-picker v-model="jqendShow" mode="time" :params="params"
  65. @confirm="jqendconfirm"></u-picker>
  66. </view>
  67. <view class="dis j-s a-c" v-if="systartDate">
  68. <view style="margin-right: 40px;">商业起保日期:</view>
  69. <u-input type="select" :select-open="systartShow" v-model="systartDate"
  70. @click="systartShow = true" style="width: 100px;"></u-input>
  71. <u-picker v-model="systartShow" mode="time" :params="params"
  72. @confirm="systartconfirm"></u-picker>
  73. </view>
  74. <view class="dis j-s a-c" v-if="syendDate">
  75. <view style="margin-right: 40px;">商业终保日期:</view>
  76. <u-input type="select" :select-open="syendShow" v-model="syendDate"
  77. @click="syendShow = true" style="width: 100px;"></u-input>
  78. <u-picker v-model="syendShow" mode="time" :params="params"
  79. @confirm="syendconfirm"></u-picker>
  80. </view>
  81. </view>
  82. <!-- <view class="addedServices">
  83. <view class="row j-sb d-flex a-center">
  84. <view>增值服务</view>
  85. <view>赠送</view>
  86. </view>
  87. <view style="padding: 15upx;color: #A6A6A6;font-size: 24upx;background-color: #F8FAFC;">
  88. 注:包含道路救援/安全检测/代为驾驶/代为送检,投保以上商业主险免费赠送,各家保司各个地区旅游差异,具体以保单信息为准</view>
  89. </view> -->
  90. </view>
  91. </view>
  92. <view class="quoteCompany">
  93. <view class="header j-sb d-flex a-center">
  94. <view class="title d-flex">精选保险公司<view class="icon iconfont icon-Group-"></view>
  95. </view>
  96. </view>
  97. <block v-for="(totalitem,totalindex) in totalCompanyList" :key="index">
  98. <template>
  99. <view class="quoteCompanyItem">
  100. <view class="top dis f-c">
  101. <ls-loading v-show="totalitem.quoteCode==1" text="掌柜正在为您报价,请稍等......"
  102. :animation="animation" fontSize="22" />
  103. <view class="companyIcon dis j-s a-c">
  104. <view class="dis">
  105. <!-- 勾选框 -->
  106. <u-checkbox
  107. @change="event=>checkboxChange(event,totalitem.id,totalitem.cnName, totalindex)"
  108. v-model="totalitem.checked" active-color="rgb(250, 53, 52)"></u-checkbox>
  109. <!-- logo -->
  110. <image :src="totalitem.logo"></image>
  111. <!-- 名称 -->
  112. <view class="companyName">{{totalitem.namesimple}}</view>
  113. </view>
  114. <!-- 价格 -->
  115. <text v-show="totalitem.quoteCode==200"
  116. class="sum">¥{{totalitem.result.sumPermium}}</text>
  117. <text
  118. v-show="(totalitem.quoteCode != '200') && (totalitem.quoteCode != '0') && (totalitem.quoteCode != '1')"
  119. class="sum" style="color: #999;font-size: 12px;"
  120. @click="ErrorMsg(totalitem.msg,totalitem.namesimple)">报价失败,请点击查看</text>
  121. </view>
  122. <view v-show="totalitem.quoteCode==200" class="dis j-s"
  123. style="font-size: 12px;color: #ee7000;">
  124. <text v-if="totalitem.result.jqPremium">交强险:¥{{totalitem.result.jqPremium}}</text>
  125. <text v-if="totalitem.result.jqPremium"
  126. style="margin: 0 5px;">商业险:¥{{totalitem.result.syPremium}}</text>
  127. <text>车船税:¥{{totalitem.result.taxAmount}}</text>
  128. <text v-if="totalitem.result.jyPremium">驾意险:¥{{totalitem.result.jyPremium}}</text>
  129. </view>
  130. <view v-show="totalitem.quoteCode==200" class="dis f-c"
  131. style="font-size: 12px;color: #6495ed;border-top: 1px solid #f2f2f2;">
  132. <text
  133. v-if="totalitem.result.jqPremium">交强险:{{totalitem.result.startDateJq}}~{{totalitem.result.endDateJq}}
  134. </text>
  135. <text
  136. v-if="totalitem.result.startDateSy">商业险:{{totalitem.result.startDateSy}}~{{totalitem.result.endDateSy}}
  137. <u-icon style="color:#ee7000;margin-left: 20px;font-size: 16px;" name="clock"
  138. @click="syncData(totalitem.result)"></u-icon>
  139. </text>
  140. <text v-if="totalitem.namesimple == '永诚财险'">光博分:{{ totalitem.result.ilogPreUdwMess ?
  141. totalitem.result.ilogPreUdwMess : '无' }}</text>
  142. <text v-else>评分:{{ totalitem.result.ilogPreUdwMess ?
  143. totalitem.result.ilogPreUdwMess : '无' }}</text>
  144. <text v-if="totalitem.result.accidentInfoStr">出险信息:{{ totalitem.result.accidentInfoStr ?
  145. totalitem.result.accidentInfoStr : '无' }}</text>
  146. </view>
  147. <text v-if="totalitem.result.tips && totalitem.namesimple == '众安财险'"
  148. style="color: red;">{{ totalitem.result.tips}}</text>
  149. <view class="" v-if="totalitem.checked">
  150. <u-form-item label="报价协议选择" :prop="totalitem.agreementId" label-width="200"
  151. :border-bottom='false' style="width: 280px;padding: 0;">
  152. <u-input type="select" :select-open="totalitem.selectShow"
  153. v-model="totalitem.agreementName" placeholder="请选择协议"
  154. @click="totalitem.selectShow = true"></u-input>
  155. <u-select mode="single-column" :list="totalitem.agreement" value-name="id"
  156. label-name="agreementName" v-model="totalitem.selectShow"
  157. @confirm="val=>selectConfirm(val,totalindex)"></u-select>
  158. </u-form-item>
  159. </view>
  160. <template
  161. v-if="totalitem.namesimple == '中国人寿' && totalitem.checked && totalitem.agreementId && renshouaccidentalDrivingVo.id">
  162. <view class="accident-style dis f-c ">
  163. <view class=" accident-ins dis a-c j-s">
  164. <u-checkbox shape="circle" size="30" v-model="totalitem.jychecked"
  165. @change="RScheckboxChange($event,totalindex)"
  166. active-color="rgb(255, 170, 0)"></u-checkbox>
  167. <view class=" dis a-c j-s " @click="renshouPopupshow=true">
  168. <text
  169. style="font-size: 14px;">{{renshouaccidentalDrivingVo.productName}}</text>
  170. <u-icon name="arrow-right" style="color: #999;" size="24"></u-icon>
  171. </view>
  172. </view>
  173. <view class=" dis j-s a-c">
  174. <text style="font-size: 14px;">份数:</text>
  175. <u-number-box v-model="renshouaccidentalDrivingVo.quantity" :min="1"
  176. :max="100" :input-width="70" :input-height="44"
  177. size="26"></u-number-box>
  178. </view>
  179. </view>
  180. </template>
  181. <template
  182. v-if="totalitem.namesimple == '恒邦财险' && totalitem.checked && totalitem.agreementId && hengbangaccidentalDrivingVo.programcode">
  183. <view class="accident-style dis f-c ">
  184. <view class=" accident-ins dis a-c j-s">
  185. <u-checkbox shape="circle" size="30" v-model="totalitem.jychecked"
  186. @change="HBcheckboxChange($event,totalindex)"
  187. active-color="rgb(255, 170, 0)"></u-checkbox>
  188. <view class=" dis a-c j-s " @click="hengbangPopupshow=true">
  189. <text
  190. style="font-size: 14px;">{{hengbangaccidentalDrivingVo.programname}}</text>
  191. <u-icon name="arrow-right" style="color: #999;" size="24"></u-icon>
  192. </view>
  193. </view>
  194. <view class=" dis j-s a-c">
  195. <text style="font-size: 14px;">份数:</text>
  196. <u-number-box v-model="hengbangaccidentalDrivingVo.quantity" :min="1"
  197. :max="100" :input-width="70" :input-height="44"
  198. size="26"></u-number-box>
  199. </view>
  200. </view>
  201. </template>
  202. <template
  203. v-if="totalitem.namesimple == '众安财险' && totalitem.checked && totalitem.agreementId && zhonganaccidentalDrivingVo.combination">
  204. <view class="accident-style dis f-c ">
  205. <view class=" accident-ins dis a-c j-s">
  206. <u-checkbox shape="circle" size="30" v-model="totalitem.jychecked"
  207. @change="ZAcheckboxChange($event,totalindex)"
  208. active-color="rgb(255, 170, 0)"></u-checkbox>
  209. <view class=" dis a-c j-s " @click="zhonganPopupshow=true">
  210. <text
  211. style="font-size: 14px;">{{zhonganaccidentalDrivingVo.name}}</text>
  212. <u-icon name="arrow-right" style="color: #999;" size="24"></u-icon>
  213. </view>
  214. </view>
  215. <view class=" dis j-s a-c">
  216. <text style="font-size: 14px;">份数:</text>
  217. <u-number-box v-model="zhonganaccidentalDrivingVo.quantity" :min="1"
  218. :max="100" :input-width="70" :input-height="44"
  219. size="26"></u-number-box>
  220. </view>
  221. </view>
  222. </template>
  223. <view v-show="totalitem.quoteCode==200" class="dis j-end"
  224. style="border-top: 1px solid #f2f2f2;padding: 10px 0;">
  225. <u-button v-if="totalitem.lastYearMsg" size="mini " type="warning"
  226. :hair-line="false" @click="YearMsg(totalitem.lastYearMsg,totalitem.namesimple)"
  227. style="margin-left: 10px;">上年信息</u-button>
  228. <u-button size="mini " type="warning" :hair-line="false"
  229. @click="bjdpreview(totalitem.result.companyId)"
  230. style="margin-left: 10px;">报价单</u-button>
  231. <u-button size="mini" style="background-color: #ea552d;margin-left: 10px;"
  232. type="error" :hair-line="false" :disabled="totalitem.result.tips"
  233. @click="querydetial(totalitem.result.companyId)">查看详情</u-button>
  234. </view>
  235. </view>
  236. </view>
  237. </template>
  238. </block>
  239. </view>
  240. </view>
  241. <wyb-popup ref="lastYearMsgCI" type="center" mode="size-fixed" height="900" radius="6" :showCloseIcon="true">
  242. <view class="popupBody">
  243. <view class="popHeader d-flex a-center j-center">
  244. 投保方案建议
  245. </view>
  246. <scroll-view scroll-top="0" scroll-y="true" class="popupScroll">
  247. </scroll-view>
  248. <view class="popBottom d-flex a-center j-center main-text-color" @tap="adjustPopupInsureSubmit">我知道了
  249. </view>
  250. </view>
  251. </wyb-popup>
  252. <u-popup v-model="renshouPopupshow" mode="center" width="70%" border-radius="10">
  253. <view class="popContent dis f-c a-c">
  254. <u-radio-group v-model="popupvalue" size="30" active-color="rgb(255, 170, 0)">
  255. <u-radio style="margin: 4px 0;" @change="RSradioChange"
  256. v-for="(item, index) in renshouInsuranceData" :key="index" :name="item.id">
  257. {{item.productName}}
  258. </u-radio>
  259. </u-radio-group>
  260. </view>
  261. </u-popup>
  262. <u-popup v-model="hengbangPopupshow" mode="center" width="80%" border-radius="10">
  263. <view class="popContent dis f-c a-c">
  264. <u-radio-group v-model="popupvalue" size="30" active-color="rgb(255, 170, 0)">
  265. <u-radio style="margin: 4px 0;flex: auto;" @change="HBradioChange"
  266. v-for="(item, index) in hengbangInsuranceData" :key="index" :name="item.programcode">
  267. {{item.programname}}
  268. </u-radio>
  269. </u-radio-group>
  270. </view>
  271. </u-popup>
  272. <u-popup v-model="zhonganPopupshow" mode="center" width="50%" border-radius="10">
  273. <view class="popContent dis f-c a-c">
  274. <u-radio-group v-model="popupvalue" size="30" active-color="rgb(255, 170, 0)">
  275. <u-radio style="margin: 4px 0;flex: auto;" @change="ZAradioChange"
  276. v-for="(item, index) in zhonganInsuranceData" :key="index" :name="item.combination">
  277. {{item.name}}
  278. </u-radio>
  279. </u-radio-group>
  280. </view>
  281. </u-popup>
  282. <view class="infoBottom d-flex a-center j-center j-sb">
  283. <button type="default" class="d-flex a-center j-center" @tap="toNext">保费计算</button>
  284. </view>
  285. </view>
  286. </template>
  287. <script>
  288. import {
  289. mapState
  290. } from "vuex"
  291. import wybPopup from '@/components/common/wyb-popup/wyb-popup.vue'
  292. import lsLoading from '@/components/common/ls-loading/ls-loading.vue';
  293. export default {
  294. components: {
  295. wybPopup,
  296. lsLoading
  297. },
  298. computed: {
  299. ...mapState(['userInfo']),
  300. getHeight() {
  301. let height = uni.getSystemInfoSync().windowHeight;
  302. return `minHeight: ${height}px;`;
  303. }
  304. },
  305. // 监听导航栏的按钮
  306. onNavigationBarButtonTap(e) {
  307. if (e.index == 0) {
  308. this.navigate({
  309. url: '/pages/index/index'
  310. }, "switchTab", true);
  311. }
  312. },
  313. data() {
  314. return {
  315. popupvalue: 1,
  316. params: {
  317. year: true, //年
  318. month: true, //月
  319. day: true, //日
  320. hour: true, //时
  321. minute: true, //分
  322. second: true, //秒
  323. },
  324. zhonganPopupshow: false,
  325. zhonganInsuranceData: [], //-众安意外险list
  326. zhonganaccidentalDrivingVo: {}, //众安意外险
  327. hengbangPopupshow: false,
  328. hengbangInsuranceData: [], //-恒邦意外险list
  329. hengbangaccidentalDrivingVo: {}, //恒邦意外险
  330. renshouPopupshow: false,
  331. renshouInsuranceData: [], //-人寿意外险list
  332. renshouaccidentalDrivingVo: {}, //人寿意外险
  333. jqstartShow: false, //交强起保日期
  334. jqendShow: false, //交强终保日期
  335. systartShow: false, //商业起保日期
  336. syendShow: false, //商业终保日期
  337. content: ``,
  338. vehicleAndVesselTaxForm: {}, //车船税信息
  339. agreementList: [],
  340. zmDrivingForm: {}, //中煤驾意险
  341. zjaccidentalDrivingVo: [], //紫金驾意险
  342. carInfoPositiveList: [], //车辆影像
  343. ownerInfoPositiveList: [], //车主影像
  344. policyHolderInfoPositiveList: [], //投保人影像
  345. insuredPersonInfoPositiveList: [], //被保人影像
  346. orderno: "", //订单号
  347. show1: false, //华农
  348. animation: 'twinkle', //动画类型
  349. jqjishi: false,
  350. syjishi: false,
  351. timeArray: [],
  352. jqTimeIndex: 0,
  353. syTimeIndex: 0,
  354. time1: "",
  355. time2: "",
  356. carTypeList: [], //车辆品牌型号列表
  357. msg: "",
  358. quoteno: "", //报价编号
  359. hasKindCodeA: false, //是否含有车损险
  360. carInfo: {}, //车辆信息
  361. ownerInfo: {}, //车主信息
  362. policyHolderInfo: {}, //投保人信息
  363. insuredPersonInfo: {}, //被保人信息
  364. riskList: [], //险种大类信息
  365. kindList: [], //商业险险别
  366. showCarInfo: false, //控制车辆信息显示
  367. showInsureDate: true, //控制险种时间显示
  368. jqstartDate: "", //交强险日期
  369. jqendDate: " ", //交强险日期
  370. systartDate: "", //商业险日期
  371. syendDate: "", //商业险日期
  372. insureList: [{
  373. amount: "0",
  374. amountDesc: "投保",
  375. amtList: [{
  376. "label": "不投保",
  377. "value": "0"
  378. }, {
  379. "label": "投保",
  380. "value": "1"
  381. }],
  382. kindCode: "A",
  383. isMainRisk: true,
  384. kindName: "机动车损失险",
  385. desc: "保险期间内,被保险人或被保险机动车驾驶人在使用被保险机动车过程中,因自然灾害、意外事故、机动车被盗窃、抢劫、抢夺等情况(详见保险条款)造成被保险机动车直接损失,且不属于免除保险人责任的范围,保险人依照本保险合同的约定负责赔偿的险种。"
  386. },
  387. {
  388. amount: "0",
  389. amountDesc: "不投保",
  390. amtList: [{
  391. label: "不投保",
  392. value: "0"
  393. },
  394. {
  395. label: "50万",
  396. value: "500000"
  397. },
  398. {
  399. label: "100万",
  400. value: "1000000"
  401. },
  402. {
  403. label: "150万",
  404. value: "1500000"
  405. },
  406. {
  407. label: "200万",
  408. value: "2000000"
  409. },
  410. {
  411. label: "250万",
  412. value: "2500000"
  413. },
  414. {
  415. label: "300万",
  416. value: "3000000"
  417. },
  418. {
  419. label: "500万",
  420. value: "5000000"
  421. },
  422. {
  423. label: "1000万",
  424. value: "10000000"
  425. }
  426. ],
  427. kindCode: "B",
  428. isMainRisk: true,
  429. kindName: "第三者责任险",
  430. desc: "保险期间内,被保险人或其允许的驾驶人在使用被保险机动车过程中发生意外事故,致使第三者遭受人身伤亡或财产直接损毁,依法应当对第三者承担的损害赔偿责任,且不属于免除保险人责任的范围,保险人依照本保险合同的约定,对于超过机动车交通事故责任强制保险各分项赔偿限额的部分负责赔偿的险种。"
  431. },
  432. {
  433. amount: "0",
  434. amountDesc: "不投保",
  435. amtList: [{
  436. label: "不投保",
  437. value: "0"
  438. },
  439. {
  440. label: "1万",
  441. value: "10000"
  442. },
  443. {
  444. label: "2万",
  445. value: "20000"
  446. },
  447. {
  448. label: "3万",
  449. value: "30000"
  450. },
  451. {
  452. label: "4万",
  453. value: "40000"
  454. },
  455. {
  456. label: "5万",
  457. value: "50000"
  458. },
  459. {
  460. label: "6万",
  461. value: "60000"
  462. },
  463. {
  464. label: "7万",
  465. value: "70000"
  466. },
  467. {
  468. label: "8万",
  469. value: "80000"
  470. },
  471. {
  472. label: "9万",
  473. value: "90000"
  474. },
  475. {
  476. label: "10万",
  477. value: "100000"
  478. },
  479. {
  480. label: "15万",
  481. value: "150000"
  482. },
  483. {
  484. label: "20万",
  485. value: "200000"
  486. },
  487. {
  488. label: "25万",
  489. value: "250000"
  490. },
  491. {
  492. label: "30万",
  493. value: "300000"
  494. },
  495. {
  496. label: "35万",
  497. value: "350000"
  498. },
  499. {
  500. label: "40万",
  501. value: "400000"
  502. },
  503. {
  504. label: "45万",
  505. value: "450000"
  506. },
  507. {
  508. label: "50万",
  509. value: "500000"
  510. },
  511. ],
  512. kindCode: "D3",
  513. isMainRisk: true,
  514. kindName: "司机责任险",
  515. desc: "保险期间内,被保险人或其允许的驾驶人在使用被保险机动车过程中发生意外事故,致使车上人员遭受人身伤亡,且不属于免除保险人责任的范围,依法应当对车上人员承担的损害赔偿责任,保险人依照本保险合同的约定负责赔偿的险种。"
  516. },
  517. {
  518. amount: "0",
  519. amountDesc: "不投保",
  520. amtList: [{
  521. "label": "不投保",
  522. "value": "0"
  523. }, {
  524. "label": "1万",
  525. "value": "10000"
  526. }, {
  527. "label": "2万",
  528. "value": "20000"
  529. }, {
  530. "label": "4万",
  531. "value": "40000"
  532. }, {
  533. "label": "5万",
  534. "value": "50000"
  535. }, {
  536. "label": "10万",
  537. "value": "100000"
  538. }, {
  539. "label": "15万",
  540. "value": "150000"
  541. }, {
  542. "label": "20万",
  543. "value": "200000"
  544. }],
  545. kindCode: "D4",
  546. isMainRisk: true,
  547. kindName: "乘客责任险",
  548. desc: "保险期间内,被保险人或其允许的驾驶人在使用被保险机动车过程中发生意外事故,致使车上人员遭受人身伤亡,且不属于免除保险人责任的范围,依法应当对车上人员承担的损害赔偿责任,保险人依照本保险合同的约定负责赔偿的险种。"
  549. },
  550. {
  551. amount: "0",
  552. amountDesc: "不投保",
  553. amtList: [{
  554. "label": "不投保",
  555. "value": "0"
  556. }, {
  557. "label": "2000",
  558. "value": "2000"
  559. }, {
  560. "label": "5000",
  561. "value": "5000"
  562. }, {
  563. "label": "1万",
  564. "value": "10000"
  565. }],
  566. desc: "保险期间内,被保险机动车在被保险人或被保险机动车驾驶人使用过程中,发生无明显碰撞痕迹的车身划痕损失,保险人按照保险合同约定负责赔偿的险种",
  567. isMainRisk: true,
  568. kindCode: "L",
  569. kindName: "车身划痕险",
  570. mainRiskCodeList: "A"
  571. },
  572. {
  573. amount: "0",
  574. amountDesc: "不投保",
  575. amtList: [{
  576. "label": "不投保",
  577. "value": "0"
  578. }, {
  579. "label": "5%",
  580. "value": "5"
  581. }, {
  582. "label": "10%",
  583. "value": "10"
  584. }, {
  585. "label": "15%",
  586. "value": "15"
  587. }, {
  588. "label": "20%",
  589. "value": "20"
  590. }],
  591. desc: "被保险机动车发生主险约定的保险事故,保险人按照主险的约定计算赔款后,扣减本特约条款约定的免赔的险种。",
  592. isMainRisk: true,
  593. kindCode: "MJ1",
  594. kindName: "绝对免赔率特约险(车损)",
  595. mainRiskCodeList: "A"
  596. },
  597. {
  598. amount: "0",
  599. amountDesc: "不投保",
  600. amtList: [{
  601. "label": "不投保",
  602. "value": "0"
  603. }, {
  604. "label": "5%",
  605. "value": "5"
  606. }, {
  607. "label": "10%",
  608. "value": "10"
  609. }, {
  610. "label": "15%",
  611. "value": "15"
  612. }, {
  613. "label": "20%",
  614. "value": "20"
  615. }],
  616. desc: "被保险机动车发生主险约定的保险事故,保险人按照主险的约定计算赔款后,扣减本特约条款约定的免赔的险种。",
  617. isMainRisk: true,
  618. kindCode: "MJ2",
  619. kindName: "绝对免赔率特约险(三者)",
  620. mainRiskCodeList: "B"
  621. },
  622. {
  623. amount: "0",
  624. amountDesc: "不投保",
  625. amtList: [{
  626. "label": "不投保",
  627. "value": "0"
  628. }, {
  629. "label": "5%",
  630. "value": "5"
  631. }, {
  632. "label": "10%",
  633. "value": "10"
  634. }, {
  635. "label": "15%",
  636. "value": "15"
  637. }, {
  638. "label": "20%",
  639. "value": "20"
  640. }],
  641. desc: "被保险机动车发生主险约定的保险事故,保险人按照主险的约定计算赔款后,扣减本特约条款约定的免赔的险种。",
  642. isMainRisk: true,
  643. kindCode: "MJ3",
  644. kindName: "绝对免赔率特约险(司机)",
  645. mainRiskCodeList: "D3"
  646. },
  647. {
  648. amount: "0",
  649. amountDesc: "不投保",
  650. amtList: [{
  651. "label": "不投保",
  652. "value": "0"
  653. }, {
  654. "label": "5%",
  655. "value": "5"
  656. }, {
  657. "label": "10%",
  658. "value": "10"
  659. }, {
  660. "label": "15%",
  661. "value": "15"
  662. }, {
  663. "label": "20%",
  664. "value": "20"
  665. }],
  666. desc: "被保险机动车发生主险约定的保险事故,保险人按照主险的约定计算赔款后,扣减本特约条款约定的免赔的险种。",
  667. isMainRisk: true,
  668. kindCode: "MJ4",
  669. kindName: "绝对免赔率特约险(乘客)",
  670. mainRiskCodeList: "D4"
  671. },
  672. {
  673. amount: "0",
  674. amountDesc: "不投保",
  675. coveragePremium: 0,
  676. amtList: [{
  677. label: "不投保",
  678. value: "0"
  679. },
  680. {
  681. label: "1万",
  682. value: "10000"
  683. },
  684. {
  685. label: "2万",
  686. value: "20000"
  687. },
  688. {
  689. label: "4万",
  690. value: "40000"
  691. },
  692. {
  693. label: "5万",
  694. value: "50000"
  695. },
  696. {
  697. label: "8万",
  698. value: "80000"
  699. },
  700. {
  701. label: "10万",
  702. value: "100000"
  703. },
  704. {
  705. label: "20万",
  706. value: "200000"
  707. },
  708. {
  709. label: "30万",
  710. value: "300000"
  711. },
  712. {
  713. label: "50万",
  714. value: "500000"
  715. },
  716. {
  717. label: "100万",
  718. value: "1000000"
  719. },
  720. {
  721. label: "200万",
  722. value: "2000000"
  723. },
  724. {
  725. label: "300万",
  726. value: "3000000"
  727. },
  728. ],
  729. kindCode: "SY_FJ_YBW1",
  730. isMainRisk: true,
  731. kindName: "附加医保-三者",
  732. desc: "附加医保外医疗费用责任险(机动车第三者责任保险)"
  733. },
  734. {
  735. amount: "0",
  736. amountDesc: "不投保",
  737. coveragePremium: 0,
  738. amtList: [{
  739. label: "不投保",
  740. value: "0"
  741. },
  742. {
  743. label: "1万",
  744. value: "10000"
  745. },
  746. {
  747. label: "2万",
  748. value: "20000"
  749. },
  750. {
  751. label: "5万",
  752. value: "50000"
  753. },
  754. {
  755. label: "10万",
  756. value: "100000"
  757. }
  758. ],
  759. kindCode: "SY_FJ_YBW2",
  760. isMainRisk: true,
  761. kindName: "附加医保-座位险(乘客)",
  762. desc: "附加医保外医疗费用责任险(机动车第三者责任保险)"
  763. },
  764. {
  765. amount: "0",
  766. amountDesc: "不投保",
  767. coveragePremium: 0,
  768. amtList: [{
  769. label: "不投保",
  770. value: "0"
  771. },
  772. {
  773. label: "1万",
  774. value: "10000"
  775. },
  776. {
  777. label: "2万",
  778. value: "20000"
  779. },
  780. {
  781. label: "5万",
  782. value: "50000"
  783. },
  784. {
  785. label: "10万",
  786. value: "100000"
  787. }
  788. ],
  789. kindCode: "SY_FJ_YBW3",
  790. isMainRisk: true,
  791. kindName: "附加医保-座位险(司机)",
  792. desc: "附加医保外医疗费用责任险(机动车第三者责任保险)"
  793. },
  794. {
  795. amount: "0",
  796. amountDesc: "不投保",
  797. amtList: [{
  798. label: "不投保",
  799. value: "0"
  800. },
  801. {
  802. label: "50万",
  803. value: "500000"
  804. },
  805. {
  806. label: "100万",
  807. value: "1000000"
  808. },
  809. {
  810. label: "150万",
  811. value: "1500000"
  812. },
  813. {
  814. label: "200万",
  815. value: "2000000"
  816. },
  817. {
  818. label: "250万",
  819. value: "2500000"
  820. },
  821. {
  822. label: "300万",
  823. value: "3000000"
  824. },
  825. {
  826. label: "500万",
  827. value: "5000000"
  828. },
  829. {
  830. label: "1000万",
  831. value: "10000000"
  832. }
  833. ],
  834. desc: "保险期间内,被保险人或其允许的驾驶人在法定节假日期间使用被保险机动车发生机动车第三者责任保险范围内的事故,并经公安部门或保险人查勘确认的,被保险机动车第三者责任保险所适用的责任限额在保险单载明的基础上增加一倍的险种",
  835. isMainRisk: true,
  836. kindCode: "BD",
  837. kindName: "法定节假日限额翻倍险",
  838. mainRiskCodeList: "B"
  839. }
  840. ],
  841. accidentForm: {
  842. fen: "1"
  843. }, //意外险内容
  844. //永诚转保确认码
  845. cqryCdeJq: "",
  846. cqryCdeSy: "",
  847. renewalCodeJq: "", //交强确认码
  848. renewalCodeSy: "", //商业确认码
  849. //-----------------
  850. totalCompanyList: [], //保险公司列表
  851. notStartedQuote: true, //未开始报价(true表示未开始报价,false表示已经报价结束)
  852. quoteCompanyCount: 0,
  853. }
  854. },
  855. async onLoad() {
  856. const eventChannel = this.getOpenerEventChannel()
  857. // 监听acceptData事件,获取上一页面通过eventChannel传送到当前页面的数据
  858. eventChannel.on('acceptData', async (data) => {
  859. console.log(data)
  860. this.carInfo = data.carInfo; //车辆信息
  861. this.ownerInfo = data.ownerInfo; //车主信息
  862. this.policyHolderInfo = data.policyHolderInfo; //投保人信息
  863. this.insuredPersonInfo = data.insuredPersonInfo; //被保人信息
  864. this.riskList = data.riskList; //险种大类
  865. this.kindList = data.kindList; //商业险险别
  866. this.vehicleAndVesselTaxForm = data.vehicleAndVesselTaxForm; //车船税信息
  867. this.orderno = data.orderno;
  868. this.quoteno = data.quoteno;
  869. if (data.quoteno) {
  870. this.imageEcho(data.quoteno) // 影像获取完毕
  871. } else {
  872. this.carInfoPositiveList = data.carInfoPositiveList; //车辆
  873. this.ownerInfoPositiveList = data.ownerInfoPositiveList; //车主
  874. this.policyHolderInfoPositiveList = data.policyHolderInfoPositiveList; //投保
  875. this.insuredPersonInfoPositiveList = data.insuredPersonInfoPositiveList; //被保人
  876. }
  877. if (this.riskList.length > 0) {
  878. for (let i = 0; i < this.riskList.length; i++) {
  879. if (this.riskList[i].riskCode == '0507') {
  880. this.jqstartDate = this.riskList[i].startDate;
  881. this.jqendDate = this.riskList[i].endDate;
  882. }
  883. if (this.riskList[i].riskCode == '0510') {
  884. this.systartDate = this.riskList[i].startDate;
  885. this.syendDate = this.riskList[i].endDate;
  886. this.kindList.map(ele1 => {
  887. this.insureList.map(ele2 => {
  888. if (ele2.kindCode == ele1.kindCode) {
  889. switch (ele1.kindCode) {
  890. case 'D4':
  891. case 'SY_FJ_YBW2':
  892. ele2.amount = ele1.unitAmount;
  893. break;
  894. case "MJ1":
  895. case "MJ2":
  896. case "MJ3":
  897. case "MJ4":
  898. ele2.amount = ele1.deductibleRate;
  899. break;
  900. default:
  901. ele2.amount = ele1.amount;
  902. }
  903. }
  904. })
  905. })
  906. }
  907. }
  908. }
  909. })
  910. this.commpanyList();
  911. },
  912. methods: {
  913. jqstartconfirm(e) {
  914. this.jqstartDate = e.year + '-' + e.month + '-' + e.day + ' ' + e.hour + ':' + e.minute + ':' + e.second;
  915. this.jqendDate = this.oneYearPast(this.jqstartDate)
  916. },
  917. jqendconfirm(e) {
  918. this.jqendDate = e.year + '-' + e.month + '-' + e.day + ' ' + e.hour + ':' + e.minute + ':' + e.second;
  919. },
  920. systartconfirm(e) {
  921. this.systartDate = e.year + '-' + e.month + '-' + e.day + ' ' + e.hour + ':' + e.minute + ':' + e.second;
  922. this.syendDate = this.oneYearPast(this.systartDate)
  923. },
  924. syendconfirm(e) {
  925. this.syendDate = e.year + '-' + e.month + '-' + e.day + ' ' + e.hour + ':' + e.minute + ':' + e.second;
  926. },
  927. //影像查询
  928. async imageEcho(quotenos) {
  929. let imgres = await this.$http.get('/ins/taskImage/findByQuoteNo?quoteNo=' + quotenos);
  930. if (imgres.code == "200") {
  931. Object.keys(imgres.data).forEach((keys) => {
  932. if (imgres.data[keys].url) {
  933. imgres.data[keys].url = this.$base.baseUrl + imgres.data[keys].url;
  934. switch (keys) {
  935. case 'C01':
  936. this.carInfoPositiveList.push({
  937. imageId: imgres.data[keys].imageId,
  938. imageType: imgres.data[keys].imageType,
  939. })
  940. break;
  941. case 'D01':
  942. this.carInfoPositiveList.push({
  943. imageId: imgres.data[keys].imageId,
  944. imageType: imgres.data[keys].imageType,
  945. })
  946. break;
  947. case 'C02':
  948. this.ownerInfoPositiveList.push({
  949. imageId: imgres.data[keys].imageId,
  950. imageType: imgres.data[keys].imageType,
  951. });
  952. break;
  953. case 'D02':
  954. this.ownerInfoPositiveList.push({
  955. imageId: imgres.data[keys].imageId,
  956. imageType: imgres.data[keys].imageType,
  957. });
  958. break;
  959. case 'C03':
  960. this.policyHolderInfoPositiveList.push({
  961. imageId: imgres.data[keys].imageId,
  962. imageType: imgres.data[keys].imageType,
  963. });
  964. break;
  965. case 'D03':
  966. this.policyHolderInfoPositiveList.push({
  967. imageId: imgres.data[keys].imageId,
  968. imageType: imgres.data[keys].imageType,
  969. });
  970. break;
  971. case 'C04':
  972. this.insuredPersonInfoPositiveList.push({
  973. imageId: imgres.data[keys].imageId,
  974. imageType: imgres.data[keys].imageType,
  975. });
  976. break;
  977. case 'D04':
  978. this.insuredPersonInfoPositiveList.push({
  979. imageId: imgres.data[keys].imageId,
  980. imageType: imgres.data[keys].imageType,
  981. });
  982. break;
  983. default:
  984. break;
  985. }
  986. }
  987. });
  988. }
  989. },
  990. //查看详情
  991. querydetial(id) {
  992. this.navigate({
  993. url: "/pages/carInsure1/quoteDetail1?companyId=" + id
  994. },
  995. "navigateTo", true);
  996. },
  997. //报价单
  998. bjdpreview(id) {
  999. uni.navigateTo({
  1000. url: "/pages/orders/quotation?companyId=" + id
  1001. })
  1002. },
  1003. //选择协议
  1004. selectConfirm(e, index) {
  1005. this.totalCompanyList[index].agreementId = e[0].value;
  1006. this.totalCompanyList[index].agreementName = e[0].label;
  1007. this.totalCompanyList[index].apiType = e[0].extra;
  1008. },
  1009. /**
  1010. * 选择保险公司方法
  1011. * @param {String} event change选中事件
  1012. * @param {String} code 保险公司ID
  1013. * @param {String} name 保险公司主体全拼
  1014. * @param {String} index 选中下标
  1015. */
  1016. async checkboxChange(event, code, name, index) {
  1017. if (event.value) {
  1018. let ins = this.totalCompanyList[index].namesimple;
  1019. this.totalCompanyList[index].checked = event.value;
  1020. let arr = this.totalCompanyList[index].agreement;
  1021. let list = [];
  1022. list = arr.filter(item => {
  1023. return item.licenseNo.length > 0 ? item.licenseNo.includes(this.carInfo.licenseNo
  1024. .slice(
  1025. 0,
  1026. 2)) : "true"
  1027. })
  1028. list.map(ele => {
  1029. ele.extra = ele.apiType;
  1030. return ele;
  1031. })
  1032. this.totalCompanyList[index].agreement = list;
  1033. this.totalCompanyList[index].agreementId = this.totalCompanyList[index].agreement[0].id;
  1034. this.totalCompanyList[index].agreementName = this.totalCompanyList[index].agreement[0]
  1035. .agreementName;
  1036. this.totalCompanyList[index].apiType = this.totalCompanyList[index].agreement[0].extra;
  1037. switch (ins) {
  1038. case '安盛天平':
  1039. break;
  1040. case '永诚财险':
  1041. break;
  1042. case '紫金财险':
  1043. break;
  1044. case '中国人寿':
  1045. case '恒邦财险':
  1046. case '众安财险':
  1047. let Insuranceres = await this.$http.post('/insurance/crawler/getDrivingInsurance', {
  1048. agreementId: this.totalCompanyList[index].agreement[0].id
  1049. });
  1050. if (Insuranceres.code == 200) {
  1051. let data = Insuranceres.data;
  1052. data.map(ele => {
  1053. ele.quantity = 1;
  1054. return ele;
  1055. })
  1056. this[name + "InsuranceData"] = data;
  1057. this[name + 'accidentalDrivingVo'] = data[0];
  1058. }
  1059. break;
  1060. default:
  1061. break;
  1062. }
  1063. } else {}
  1064. },
  1065. //驾意险勾选框
  1066. RScheckboxChange(event, index) {
  1067. this.totalCompanyList[index].jychecked = event.value;
  1068. },
  1069. //驾意险勾选框
  1070. HBcheckboxChange(event, index) {
  1071. this.totalCompanyList[index].jychecked = event.value;
  1072. },
  1073. //驾意险勾选框
  1074. ZAcheckboxChange(event, index) {
  1075. this.totalCompanyList[index].jychecked = event.value;
  1076. },
  1077. //驾意险选择
  1078. RSradioChange(id) {
  1079. this.renshouaccidentalDrivingVo = this.renshouInsuranceData.find(val => val.id == id)
  1080. this.renshouPopupshow = false;
  1081. },
  1082. //驾意险选择
  1083. HBradioChange(id) {
  1084. this.renshouaccidentalDrivingVo = this.hengbangInsuranceData.find(val => val.programcode == id)
  1085. this.hengbangPopupshow = false;
  1086. },
  1087. //驾意险选择
  1088. ZAradioChange(id) {
  1089. this.zhonganaccidentalDrivingVo = this.zhonganInsuranceData.find(val => val.combination == id)
  1090. console.log(this.zhonganaccidentalDrivingVo)
  1091. this.zhonganPopupshow = false;
  1092. },
  1093. //获取保险公司列表
  1094. async commpanyList() {
  1095. let commpanykad = await this.$http.get('/insurance/order/getAgreementInsCompany');
  1096. commpanykad.data.map(ele => {
  1097. ele["result"] = {};
  1098. ele["quoteCode"] = 0;
  1099. ele["checked"] = false;
  1100. ele["jychecked"] = false;
  1101. ele["msg"] = "";
  1102. ele["agreementId"] = "";
  1103. ele["lastYearMsg"] = "";
  1104. ele["agreementName"] = "";
  1105. ele["apiType"] = "";
  1106. ele["selectShow"] = false;
  1107. })
  1108. this.totalCompanyList = commpanykad.data;
  1109. },
  1110. async toNext() {
  1111. if (this.quoteno) {
  1112. this.OrderStageProcessing();
  1113. } else {
  1114. let getquote = await this.$http.get('/ins/tool/getQuoteNo');
  1115. this.quoteno = getquote.data;
  1116. this.OrderStageProcessing();
  1117. }
  1118. },
  1119. async OrderStageProcessing() {
  1120. let mergedArray = [];
  1121. let mergedArrayList = mergedArray.concat(this.carInfoPositiveList, this.ownerInfoPositiveList, this
  1122. .policyHolderInfoPositiveList, this.insuredPersonInfoPositiveList)
  1123. if (mergedArrayList.length > 0) {
  1124. await this.$http.post('/ins/taskImage/uploadImages', {
  1125. imageList: mergedArrayList,
  1126. quoteNo: this.quoteno,
  1127. })
  1128. }
  1129. let param = {
  1130. userId: this.userInfo.sysUser.id,
  1131. quoteno: this.quoteno,
  1132. orderNo: this.orderno ? this.orderno : "",
  1133. carInfo: this.carInfo,
  1134. insuredPersonInfo: this.insuredPersonInfo,
  1135. ownerInfo: this.ownerInfo,
  1136. policyHolderInfo: this.policyHolderInfo,
  1137. kindList: this.kindList,
  1138. riskList: this.riskList,
  1139. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1140. };
  1141. let orders = await this.$http.post('/insurance/order/generateOrder', param);
  1142. if (orders.code == '200') {
  1143. this.orderno = orders.data.orderno;
  1144. this.totalCompanyList.map((ele, index) => {
  1145. if (ele.checked) {
  1146. //动态调用报价接口
  1147. ele.quoteCode = "1";
  1148. this.ToolClickFun(ele.cnName, index, ele.id);
  1149. }
  1150. });
  1151. }
  1152. },
  1153. //动态函数
  1154. ToolClickFun(MethodName, Parameter, companyId) {
  1155. this[`${MethodName}`](Parameter, companyId)
  1156. },
  1157. //永安报价
  1158. async yongan(num, id) {
  1159. let params = {
  1160. orderNo: this.orderno,
  1161. companyId: id
  1162. };
  1163. let quote = await this.$http('/order/yongAn/quote', params);
  1164. if (quote.msg == "重复投保" && quote.code == "501") {
  1165. if (!!quote.data.jqStartDate && !quote.data.syStartDate) {
  1166. this.jqstartDate = quote.data.jqStartDate;
  1167. this.jqendDate = quote.data.jqEndDate;
  1168. if (this.riskList.length > 0) {
  1169. for (let i = 0; i < this.riskList.length; i++) {
  1170. if (this.riskList[i].riskCode == "0507") {
  1171. this.riskList[i].startDate = quote.data.jqStartDate;
  1172. this.riskList[i].endDate = quote.data.jqEndDate;
  1173. }
  1174. }
  1175. }
  1176. let param = {
  1177. userId: this.userInfo.sysUser.id,
  1178. quoteno: this.quoteno,
  1179. orderNo: this.orderno,
  1180. carInfo: this.carInfo,
  1181. insuredPersonInfo: this.insuredPersonInfo,
  1182. ownerInfo: this.ownerInfo,
  1183. policyHolderInfo: this.policyHolderInfo,
  1184. kindList: this.kindList,
  1185. riskList: this.riskList,
  1186. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1187. };
  1188. await this.$http.post('/insurance/order/generateOrder', param);
  1189. return this.yongan(num, id);
  1190. } else if (!!quote.data.syStartDate && !quote.data.jqStartDate) {
  1191. } else if (!!quote.data.syStartDate && !!quote.data.jqStartDate) {
  1192. } else {
  1193. this.totalCompanyList[num].quoteCode = "3";
  1194. this.totalCompanyList[num].msg = "重复投保";
  1195. }
  1196. } else if (quote.code == "500" || quote.code == "502" || quote.code == "-9999") {
  1197. this.totalCompanyList[num].quoteCode = "-9999";
  1198. this.totalCompanyList[num].msg = quote.msg;
  1199. } else {
  1200. this.totalCompanyList[num].quoteCode = 200;
  1201. this.totalCompanyList[num].result = quote.data;
  1202. }
  1203. },
  1204. //中煤报价
  1205. async zhongmei(num, id) {
  1206. let params = {
  1207. accidentalDrivingVo: this.zmDrivingForm,
  1208. orderNo: this.orderno,
  1209. companyId: id,
  1210. agreementId: this.totalCompanyList[num].agreementId,
  1211. };
  1212. let res = await this.$http.post('/order/zhongMeiApi/quote', params);
  1213. this.totalCompanyList[num].msg = res.msg;
  1214. if (!!res.msg && res.msg.indexOf("不存在有效协议") >= 0) {
  1215. this.totalCompanyList[num].quoteCode = "4";
  1216. this.totalCompanyList[num].msg = res.msg;
  1217. return;
  1218. } else if (
  1219. res.data == null &&
  1220. res.msg.indexOf("交强险平台返回") > -1 &&
  1221. res.msg.indexOf(";终保日期") > -1
  1222. ) {
  1223. let time =
  1224. res.msg.substr(res.msg.indexOf(";终保日期 ") + 6, 16) + ":00";
  1225. this.jqstartDate = time;
  1226. this.jqendDate = this.oneYearPast(time);
  1227. if (this.riskList.length > 0) {
  1228. for (let i = 0; i < this.riskList.length; i++) {
  1229. if (this.riskList[i].riskCode == "0507") {
  1230. this.riskList[i].startDate = time;
  1231. this.riskList[i].endDate = this.oneYearPast(time);
  1232. }
  1233. }
  1234. }
  1235. let param = {
  1236. userId: this.userInfo.sysUser.id,
  1237. quoteno: this.quoteno,
  1238. orderNo: this.orderno,
  1239. carInfo: this.carInfo,
  1240. insuredPersonInfo: this.insuredPersonInfo,
  1241. ownerInfo: this.ownerInfo,
  1242. policyHolderInfo: this.policyHolderInfo,
  1243. kindList: this.kindList,
  1244. riskList: this.riskList,
  1245. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1246. };
  1247. await this.$http.post('/insurance/order/generateOrder', param);
  1248. return this.zhongmei(num, id);
  1249. } else if (res.code == '200') {
  1250. if (res.data.warnMessageList != null && res.data.warnMessageList[0] != null && res.data
  1251. .warnMessageList[
  1252. 0] != "") {
  1253. this.totalCompanyList[num].lastYearMsg = "";
  1254. let dat = res.data.warnMessageList;
  1255. dat.map(ele => {
  1256. this.totalCompanyList[num].lastYearMsg += ele + '<br>';
  1257. })
  1258. }
  1259. this.totalCompanyList[num].quoteCode = 200;
  1260. this.totalCompanyList[num].result = res.data;
  1261. } else {
  1262. this.totalCompanyList[num].quoteCode = "3";
  1263. this.totalCompanyList[num].msg = res.msg;
  1264. return;
  1265. }
  1266. },
  1267. //永诚报价
  1268. async yongcheng(num, id) {
  1269. let accidentalDrivingVo = {};
  1270. if (this.accidentForm.id) {
  1271. let data = this.accidentDataList.find(
  1272. val => val.id == this.accidentForm.accidentType
  1273. );
  1274. accidentalDrivingVo = {
  1275. rideRiskCode: data.code ? data.code : "",
  1276. rideRiskName: data.name ? data.name : "",
  1277. quantity: this.accidentForm.fen ? this.accidentForm.fen : ""
  1278. };
  1279. }
  1280. let params = {
  1281. accidentalDrivingVo,
  1282. orderNo: this.orderno,
  1283. companyId: id,
  1284. cqryCdeJq: this.cqryCdeJq,
  1285. cqryCdeSy: this.cqryCdeSy,
  1286. renewalCodeJq: this.renewalCodeJq,
  1287. renewalCodeSy: this.renewalCodeSy,
  1288. agreementId: this.totalCompanyList[num].agreementId,
  1289. };
  1290. let res = await this.$http.post('/api/yongCheng/quote', params);
  1291. this.totalCompanyList[num].msg = res.msg;
  1292. if (res.code == "200") {
  1293. if (res.data.warnMessageList != null && res.data.warnMessageList[0] != null && res.data
  1294. .warnMessageList[
  1295. 0] != "") {
  1296. this.totalCompanyList[num].lastYearMsg = "";
  1297. let dat = res.data.warnMessageList;
  1298. dat.map(ele => {
  1299. this.totalCompanyList[num].lastYearMsg += ele + '<br>';
  1300. })
  1301. }
  1302. this.totalCompanyList[num].quoteCode = 200;
  1303. this.totalCompanyList[num].result = res.data;
  1304. } else if (res.code == "101") {
  1305. this.totalCompanyList[num].quoteCode = "101";
  1306. this.totalCompanyList[num].msg = res.msg;
  1307. this.cqryCdeJq = res.data.cqryCdeJq;
  1308. this.cqryCdeSy = res.data.cqryCdeSy;
  1309. let jq = res.data.renewalCodeJq.replace(/[\r\n]/g, "");
  1310. let jqBase64 = `data:image/png;base64,${jq}`;
  1311. this.renewalCodeJqImg = jqBase64;
  1312. if (res.data.renewalCodeSy) {
  1313. let sy = res.data.renewalCodeSy.replace(/[\r\n]/g, "");
  1314. let syBase64 = `data:image/png;base64,${sy}`;
  1315. this.renewalCodeSyImg = syBase64;
  1316. }
  1317. this.renewalCodedialogVisible = true;
  1318. } else {
  1319. this.totalCompanyList[num].quoteCode = "3";
  1320. this.totalCompanyList[num].msg = res.msg;
  1321. return;
  1322. }
  1323. },
  1324. //紫金报价
  1325. async zijin(num, id) {
  1326. let params = {
  1327. accidentalDrivingVo: this.zjaccidentalDrivingVo,
  1328. orderNo: this.orderno,
  1329. companyId: id,
  1330. agreementId: this.totalCompanyList[num].agreementId,
  1331. };
  1332. let res = await this.$http.post('/order/zijin/quote', params);
  1333. this.totalCompanyList[num].msg = res.msg;
  1334. if (!!res.msg && res.msg.indexOf("不存在有效协议") >= 0) {
  1335. this.totalCompanyList[num].quoteCode = "4";
  1336. this.totalCompanyList[num].msg = res.msg;
  1337. return;
  1338. } else if (
  1339. res.data == null &&
  1340. res.msg.indexOf("交强险平台返回") > -1 &&
  1341. res.msg.indexOf(";终保日期") > -1
  1342. ) {
  1343. let time =
  1344. res.msg.substr(res.msg.indexOf(";终保日期 ") + 6, 16) + ":00";
  1345. this.jqstartDate = time;
  1346. this.jqendDate = this.oneYearPast(time);
  1347. this.systartDate = time;
  1348. this.syendDate = this.oneYearPast(time);
  1349. if (this.riskList.length > 0) {
  1350. for (let i = 0; i < this.riskList.length; i++) {
  1351. if (this.riskList[i].riskCode == "0507") {
  1352. this.riskList[i].startDate = time;
  1353. this.riskList[i].endDate = this.oneYearPast(time);
  1354. } else if (this.riskList[i].riskCode == "0510") {
  1355. this.riskList[i].startDate = time;
  1356. this.riskList[i].endDate = this.oneYearPast(time);
  1357. }
  1358. }
  1359. }
  1360. let param = {
  1361. userId: this.userInfo.sysUser.id,
  1362. quoteno: this.quoteno,
  1363. orderNo: this.orderno,
  1364. carInfo: this.carInfo,
  1365. insuredPersonInfo: this.insuredPersonInfo,
  1366. ownerInfo: this.ownerInfo,
  1367. policyHolderInfo: this.policyHolderInfo,
  1368. kindList: this.kindList,
  1369. riskList: this.riskList,
  1370. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1371. };
  1372. await this.$http.post('/insurance/order/generateOrder', param);
  1373. return this.zijin(num, id);
  1374. } else if (res.code == '200') {
  1375. if (res.data.warnMessageList != null && res.data.warnMessageList[0] != null && res.data
  1376. .warnMessageList[
  1377. 0] != "") {
  1378. this.totalCompanyList[num].lastYearMsg = "";
  1379. let dat = res.data.warnMessageList;
  1380. dat.map(ele => {
  1381. this.totalCompanyList[num].lastYearMsg += ele;
  1382. })
  1383. }
  1384. this.totalCompanyList[num].quoteCode = 200;
  1385. this.totalCompanyList[num].result = res.data;
  1386. } else {
  1387. this.totalCompanyList[num].quoteCode = "3";
  1388. this.totalCompanyList[num].msg = res.msg;
  1389. return;
  1390. }
  1391. },
  1392. //爬虫统一报价接口
  1393. async quoteInsurance(num, id, apiType, jychecked) {
  1394. let api = apiType === 2 ? "/insurance/crawler/quote" : "anshengquote";
  1395. let ccidenttype = this.totalCompanyList[num].cnName;
  1396. let namesimple = this.totalCompanyList[num].namesimple;
  1397. console.log(jychecked, ccidenttype)
  1398. let params = {
  1399. orderNo: this.orderno,
  1400. companyId: id,
  1401. agreementId: this.totalCompanyList[num].agreementId,
  1402. accidentalDrivingVo: jychecked ? this[ccidenttype + 'accidentalDrivingVo'] : {},
  1403. };
  1404. let res = await this.$http.post(`${api}`, params);
  1405. this.totalCompanyList[num].msg = res.msg;
  1406. switch (namesimple) {
  1407. case '安盛天平':
  1408. if (res.data == null && res.msg.indexOf("交强险重复投保") > -1 && res.msg.indexOf(";终保日期") > -1) {
  1409. let time = res.msg.substr(res.msg.indexOf(";终保日期 ") + 6, 16) + ":00";
  1410. this.jqstartDate = time;
  1411. this.jqendDate = this.oneYearPast(time);
  1412. if (this.riskList.length > 0) {
  1413. for (let i = 0; i < this.riskList.length; i++) {
  1414. if (this.riskList[i].riskCode == "0507") {
  1415. this.riskList[i].startDate = time;
  1416. this.riskList[i].endDate = this.oneYearPast(time);
  1417. }
  1418. }
  1419. }
  1420. let param = {
  1421. userId: this.userInfo.sysUser.id,
  1422. quoteno: this.quoteno,
  1423. orderNo: this.orderno,
  1424. carInfo: this.carInfo,
  1425. insuredPersonInfo: this.insuredPersonInfo,
  1426. ownerInfo: this.ownerInfo,
  1427. policyHolderInfo: this.policyHolderInfo,
  1428. kindList: this.kindList,
  1429. riskList: this.riskList,
  1430. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1431. };
  1432. await this.$http.post('/insurance/order/generateOrder', param);
  1433. return this.quoteInsurance(num, id, apiType);
  1434. } else if (res.data == null && res.msg.indexOf("上年保险止期(") > -1 && res.msg.indexOf("重复投保情况") > -
  1435. 1) {
  1436. let time = res.msg.substr(res.msg.indexOf("上年保险止期(") + 7, 17) + ":00";
  1437. time = time.substring(0, 4) + "-" + time.substring(5, 7) + "-" + time.substring(8, 10) +
  1438. " " + time.substring(12, 14) + ":" + time.substring(15, 17) + ":00"
  1439. this.systartDate = time;
  1440. this.syendDate = this.oneYearPast(time);
  1441. if (this.riskList.length > 0) {
  1442. for (let i = 0; i < this.riskList.length; i++) {
  1443. if (this.riskList[i].riskCode == "0510") {
  1444. this.riskList[i].startDate = time;
  1445. this.riskList[i].endDate = this.oneYearPast(time);
  1446. }
  1447. }
  1448. }
  1449. let param = {
  1450. userId: this.userInfo.sysUser.id,
  1451. quoteno: this.quoteno,
  1452. orderNo: this.orderno,
  1453. carInfo: this.carInfo,
  1454. insuredPersonInfo: this.insuredPersonInfo,
  1455. ownerInfo: this.ownerInfo,
  1456. policyHolderInfo: this.policyHolderInfo,
  1457. kindList: this.kindList,
  1458. riskList: this.riskList,
  1459. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1460. };
  1461. await this.$http.post('/insurance/order/generateOrder', param);
  1462. return this.quoteInsurance(num, id, apiType);
  1463. } else if (!!res.data) {
  1464. if (res.data.warnMessageList != null && res.data.warnMessageList[0] != null && res.data
  1465. .warnMessageList[
  1466. 0] != "") {
  1467. this.totalCompanyList[num].lastYearMsg = "";
  1468. let dat = res.data.warnMessageList;
  1469. dat.map(ele => {
  1470. this.totalCompanyList[num].lastYearMsg += ele;
  1471. })
  1472. }
  1473. this.totalCompanyList[num].quoteCode = 200;
  1474. this.totalCompanyList[num].result = res.data;
  1475. } else {
  1476. this.totalCompanyList[num].quoteCode = "3";
  1477. this.totalCompanyList[num].msg = res.msg;
  1478. return;
  1479. }
  1480. break;
  1481. case '中国人寿':
  1482. if (res.data == null && res.msg.indexOf("交强险") > -1 && res.msg.indexOf(";终保日期") > -1) {
  1483. let time = res.msg.substr(res.msg.indexOf(";终保日期") + 6, 16) + ":00";
  1484. this.jqstartDate = time;
  1485. this.jqendDate = this.oneYearPast(time);
  1486. if (this.riskList.length > 0) {
  1487. for (let i = 0; i < this.riskList.length; i++) {
  1488. if (this.riskList[i].riskCode == "0507") {
  1489. this.riskList[i].startDate = time;
  1490. this.riskList[i].endDate = this.oneYearPast(time);
  1491. }
  1492. }
  1493. }
  1494. let param = {
  1495. userId: this.userInfo.sysUser.id,
  1496. quoteno: this.quoteno,
  1497. orderNo: this.orderno,
  1498. carInfo: this.carInfo,
  1499. insuredPersonInfo: this.insuredPersonInfo,
  1500. ownerInfo: this.ownerInfo,
  1501. policyHolderInfo: this.policyHolderInfo,
  1502. kindList: this.kindList,
  1503. riskList: this.riskList,
  1504. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1505. };
  1506. await this.$http.post('/insurance/order/generateOrder', param);
  1507. return this.quoteInsurance(num, id, apiType);
  1508. } else if (res.data == null && res.msg.indexOf("商业险-平台返回") > -1 && res.msg.indexOf("保险期间:") > -
  1509. 1) {
  1510. let time = res.msg.substr(res.msg.indexOf("保险期间:") + 18, 12) + "00";
  1511. time = time.substring(0, 4) + "-" + time.substring(4, 6) + "-" + time.substring(6, 8) +
  1512. " " + time.substring(8, 10) + ":" + time.substring(10, 12) + ":" + time.substring(12,
  1513. 14);
  1514. this.systartDate = time;
  1515. this.syendDate = this.oneYearPast(time);
  1516. if (this.riskList.length > 0) {
  1517. for (let i = 0; i < this.riskList.length; i++) {
  1518. if (this.riskList[i].riskCode == "0510") {
  1519. this.riskList[i].startDate = time;
  1520. this.riskList[i].endDate = this.oneYearPast(time);
  1521. }
  1522. }
  1523. }
  1524. let param = {
  1525. userId: this.userInfo.sysUser.id,
  1526. quoteno: this.quoteno,
  1527. orderNo: this.orderno,
  1528. carInfo: this.carInfo,
  1529. insuredPersonInfo: this.insuredPersonInfo,
  1530. ownerInfo: this.ownerInfo,
  1531. policyHolderInfo: this.policyHolderInfo,
  1532. kindList: this.kindList,
  1533. riskList: this.riskList,
  1534. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1535. };
  1536. await this.$http.post('/insurance/order/generateOrder', param);
  1537. return this.quoteInsurance(num, id, apiType);
  1538. } else if (!!res.data) {
  1539. if (res.data.warnMessageList != null && res.data.warnMessageList[0] != null && res.data
  1540. .warnMessageList[
  1541. 0] != "") {
  1542. this.totalCompanyList[num].lastYearMsg = "";
  1543. let dat = res.data.warnMessageList;
  1544. dat.map(ele => {
  1545. this.totalCompanyList[num].lastYearMsg += ele;
  1546. })
  1547. }
  1548. this.totalCompanyList[num].quoteCode = 200;
  1549. this.totalCompanyList[num].result = res.data;
  1550. } else {
  1551. this.totalCompanyList[num].quoteCode = "3";
  1552. this.totalCompanyList[num].msg = res.msg;
  1553. return;
  1554. }
  1555. break;
  1556. case '恒邦财险':
  1557. if ((res.data == null && res.msg.indexOf("交强险平台返回") > -1 && res.msg.indexOf(";终保日期") > -1) || (
  1558. res.data == null && res.msg.indexOf("重复投保") > -1 && res.msg.indexOf(";终保日期") > -1)) {
  1559. let time = res.msg.substr(res.msg.indexOf(";终保日期") + 6, 16) + ":00";
  1560. this.jqstartDate = time;
  1561. this.jqendDate = this.oneYearPast(time);
  1562. if (this.riskList.length > 0) {
  1563. for (let i = 0; i < this.riskList.length; i++) {
  1564. if (this.riskList[i].riskCode == "0507") {
  1565. this.riskList[i].startDate = time;
  1566. this.riskList[i].endDate = this.oneYearPast(time);
  1567. }
  1568. }
  1569. }
  1570. let param = {
  1571. userId: this.userInfo.sysUser.id,
  1572. quoteno: this.quoteno,
  1573. orderNo: this.orderno,
  1574. carInfo: this.carInfo,
  1575. insuredPersonInfo: this.insuredPersonInfo,
  1576. ownerInfo: this.ownerInfo,
  1577. policyHolderInfo: this.policyHolderInfo,
  1578. kindList: this.kindList,
  1579. riskList: this.riskList,
  1580. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1581. };
  1582. await this.$http.post('/insurance/order/generateOrder', param);
  1583. return this.quoteInsurance(num, id, apiType);
  1584. } else if (res.data == null && res.msg.indexOf("平台校验,重复投保") > -1 && res.msg.indexOf("终保日期:") >
  1585. -1) {
  1586. let time = res.msg.substr(res.msg.indexOf("终保日期:") + 5, 10) + " 00:00:00";
  1587. this.systartDate = time;
  1588. this.syendDate = this.oneYearPast(time);
  1589. if (this.riskList.length > 0) {
  1590. for (let i = 0; i < this.riskList.length; i++) {
  1591. if (this.riskList[i].riskCode == "0510") {
  1592. this.riskList[i].startDate = time;
  1593. this.riskList[i].endDate = this.oneYearPast(time);
  1594. }
  1595. }
  1596. }
  1597. let param = {
  1598. userId: this.userInfo.sysUser.id,
  1599. quoteno: this.quoteno,
  1600. orderNo: this.orderno,
  1601. carInfo: this.carInfo,
  1602. insuredPersonInfo: this.insuredPersonInfo,
  1603. ownerInfo: this.ownerInfo,
  1604. policyHolderInfo: this.policyHolderInfo,
  1605. kindList: this.kindList,
  1606. riskList: this.riskList,
  1607. vehicleAndVesselTax: this.vehicleAndVesselTaxForm,
  1608. };
  1609. await this.$http.post('/insurance/order/generateOrder', param);
  1610. return this.quoteInsurance(num, id, apiType);
  1611. } else if (!!res.data) {
  1612. if (res.data.warnMessageList != null && res.data.warnMessageList[0] != null && res.data
  1613. .warnMessageList[
  1614. 0] != "") {
  1615. this.totalCompanyList[num].lastYearMsg = "";
  1616. let dat = res.data.warnMessageList;
  1617. dat.map(ele => {
  1618. this.totalCompanyList[num].lastYearMsg += ele;
  1619. })
  1620. }
  1621. this.totalCompanyList[num].quoteCode = 200;
  1622. this.totalCompanyList[num].result = res.data;
  1623. } else {
  1624. this.totalCompanyList[num].quoteCode = "3";
  1625. this.totalCompanyList[num].msg = res.msg;
  1626. return;
  1627. }
  1628. break;
  1629. case '众安财险':
  1630. if (!!res.data) {
  1631. if (res.data.warnMessageList != null && res.data.warnMessageList[0] != null && res.data
  1632. .warnMessageList[
  1633. 0] != "") {
  1634. this.totalCompanyList[num].lastYearMsg = "";
  1635. let dat = res.data.warnMessageList;
  1636. dat.map(ele => {
  1637. this.totalCompanyList[num].lastYearMsg += ele;
  1638. })
  1639. }
  1640. this.totalCompanyList[num].quoteCode = 200;
  1641. this.totalCompanyList[num].result = res.data;
  1642. } else {
  1643. this.totalCompanyList[num].quoteCode = "3";
  1644. this.totalCompanyList[num].msg = res.msg;
  1645. return;
  1646. }
  1647. break;
  1648. default:
  1649. break;
  1650. }
  1651. },
  1652. //安盛天平
  1653. ansheng(num, id) {
  1654. this.quoteInsurance(num, id, this.totalCompanyList[num].apiType, this.totalCompanyList[num].jychecked);
  1655. },
  1656. //众安
  1657. zhongan(num, id) {
  1658. this.quoteInsurance(num, id, this.totalCompanyList[num].apiType, this.totalCompanyList[num].jychecked);
  1659. },
  1660. //人寿
  1661. renshou(num, id) {
  1662. this.quoteInsurance(num, id, this.totalCompanyList[num].apiType, this.totalCompanyList[num].jychecked);
  1663. },
  1664. //恒邦
  1665. hengbang(num, id) {
  1666. this.quoteInsurance(num, id, this.totalCompanyList[num].apiType, this.totalCompanyList[num].jychecked);
  1667. },
  1668. Lastyear() {
  1669. this.$refs.lastYearMsgCI.show() // 显示
  1670. },
  1671. adjustPopupInsureSubmit() {
  1672. this.$refs.lastYearMsgCI.hide() // 显示
  1673. },
  1674. // 重新选择车型
  1675. toCarInfo() {
  1676. this.navigate({
  1677. url: '/pages/carInsure1/carInfo1',
  1678. success: (res) => {
  1679. res.eventChannel.emit("acceptData", {
  1680. carInfo: this.carInfo,
  1681. ownerInfo: this.ownerInfo,
  1682. policyHolderInfo: this.policyHolderInfo,
  1683. insuredPersonInfo: this.insuredPersonInfo,
  1684. riskList: this.riskList,
  1685. kindList: this.kindList,
  1686. carInfoPositiveList: this.carInfoPositiveList, //车辆
  1687. ownerInfoPositiveList: this.ownerInfoPositiveList, //车主
  1688. policyHolderInfoPositiveList: this.policyHolderInfoPositiveList, //投保
  1689. insuredPersonInfoPositiveList: this.insuredPersonInfoPositiveList, //被保人
  1690. })
  1691. }
  1692. }, "navigateTo", true);
  1693. },
  1694. // 重新选择方案
  1695. toInsureItems() {
  1696. this.navigate({
  1697. url: '/pages/carInsure1/insureItems1',
  1698. success: (res) => {
  1699. res.eventChannel.emit("acceptData", {
  1700. carInfo: this.carInfo,
  1701. ownerInfo: this.ownerInfo,
  1702. policyHolderInfo: this.policyHolderInfo,
  1703. insuredPersonInfo: this.insuredPersonInfo,
  1704. riskList: this.riskList,
  1705. kindList: this.kindList,
  1706. carInfoPositiveList: this.carInfoPositiveList, //车辆
  1707. ownerInfoPositiveList: this.ownerInfoPositiveList, //车主
  1708. policyHolderInfoPositiveList: this.policyHolderInfoPositiveList, //投保
  1709. insuredPersonInfoPositiveList: this.insuredPersonInfoPositiveList, //被保人
  1710. vehicleModel: this.vehicleModel,
  1711. })
  1712. }
  1713. }, "navigateTo", true);
  1714. },
  1715. // 显示报错信息
  1716. ErrorMsg(msg, title) {
  1717. uni.showModal({
  1718. title: title + "报价提示",
  1719. content: msg,
  1720. showCancel: false,
  1721. confirmText: "关闭"
  1722. })
  1723. },
  1724. //上年信息
  1725. YearMsg(msg, title) {
  1726. uni.showModal({
  1727. title: title + "上年信息",
  1728. content: msg,
  1729. showCancel: false,
  1730. confirmText: "关闭"
  1731. })
  1732. },
  1733. //使用此时间
  1734. syncData(item) {
  1735. this.jqstartDate = item.startDateJq ? item.startDateJq : this.jqstartDate
  1736. this.jqendDate = item.endDateJq ? item.endDateJq : this.endDateJq
  1737. this.systartDate = item.startDateSy ? item.startDateSy : this.systartDate
  1738. this.syendDate = item.endDateSy ? item.endDateSy : this.syendDate
  1739. uni.showToast({
  1740. title: '时间已替换',
  1741. icon: 'none',
  1742. duration: 1000
  1743. });
  1744. },
  1745. oneYearPast(time) {
  1746. var date = new Date(time);
  1747. date.setSeconds(date.getSeconds() - 1);
  1748. date.setFullYear(date.getFullYear() + 1); //一年后
  1749. date.setTime(date.getTime()); //一年后的前一天
  1750. var strYear = date.getFullYear();
  1751. var strDay = date.getDate();
  1752. var strMonth = date.getMonth() + 1;
  1753. var hh = date.getHours();
  1754. var minutes = date.getMinutes(); // 分
  1755. var Seconds = date.getSeconds();
  1756. if (hh < 10) {
  1757. hh = "0" + hh;
  1758. }
  1759. if (minutes < 10) {
  1760. minutes = "0" + minutes;
  1761. }
  1762. if (Seconds < 10) {
  1763. Seconds = "0" + Seconds;
  1764. }
  1765. if (strMonth < 10) {
  1766. strMonth = "0" + strMonth;
  1767. }
  1768. if (strDay < 10) {
  1769. strDay = "0" + strDay;
  1770. }
  1771. var datastr =
  1772. strYear + "-" + strMonth + "-" + strDay + " " + hh + ":" + minutes + ":" + Seconds;
  1773. return datastr;
  1774. },
  1775. }
  1776. }
  1777. </script>
  1778. <style lang="scss" scoped>
  1779. @import '@/style/mixin.scss';
  1780. /* 头部车辆信息和特权Start */
  1781. .carInfo {
  1782. height: 330upx;
  1783. background: -webkit-linear-gradient(0deg, rgba($themeColor, 0.6), rgba($themeColor, 0.8));
  1784. background-size: 100% 100%;
  1785. }
  1786. .carInfo .topLeft {
  1787. width: 120upx;
  1788. font-size: 90upx;
  1789. color: #FFFFFF;
  1790. }
  1791. .carInfo .topRight .brandName {
  1792. width: 400upx;
  1793. overflow: hidden;
  1794. text-overflow: ellipsis;
  1795. white-space: nowrap;
  1796. }
  1797. .carInfo .other {
  1798. background-color: #FFFFFF;
  1799. height: 80upx;
  1800. border-radius: 15upx;
  1801. box-sizing: border-box;
  1802. }
  1803. .carInfo .other .privilege {
  1804. background-color: rgba($themeColor, 0.6);
  1805. font-size: 24upx;
  1806. color: #FFFFFF;
  1807. font-weight: bold;
  1808. }
  1809. .carInfo .other .content {
  1810. width: 460upx;
  1811. margin-left: 15upx;
  1812. overflow: hidden;
  1813. text-overflow: ellipsis;
  1814. white-space: nowrap;
  1815. }
  1816. .carInfo .other .icon {
  1817. width: 30upx;
  1818. }
  1819. /* 头部车辆信息和特权End */
  1820. .pageContent {
  1821. position: relative;
  1822. top: -50upx;
  1823. padding-bottom: 100px;
  1824. }
  1825. /* 报价方案Start */
  1826. .quotePlan {
  1827. background: #FFFFFF;
  1828. position: relative;
  1829. border-radius: 20upx;
  1830. }
  1831. .quotePlan .header {
  1832. height: 80upx;
  1833. position: relative;
  1834. border-bottom: 1px solid #E6E8EA;
  1835. }
  1836. .quotePlan .header .title {
  1837. // font-size: 30upx;
  1838. font-weight: bold;
  1839. padding-left: 25upx;
  1840. }
  1841. .quotePlan .header .title:before {
  1842. content: "";
  1843. position: absolute;
  1844. left: 30upx;
  1845. top: 25upx;
  1846. width: 8upx;
  1847. height: 30upx;
  1848. background-color: $themeColor;
  1849. }
  1850. .quotePlan .body {
  1851. padding: 0 30upx 10upx;
  1852. }
  1853. .quotePlan .body .insurance {
  1854. padding-bottom: 20upx;
  1855. border-bottom: 1px dashed #E6E8EA;
  1856. }
  1857. .accident-style {
  1858. padding: 20px;
  1859. >view {
  1860. margin-bottom: 15px;
  1861. }
  1862. .accident-ins {
  1863. text {
  1864. margin-right: 10px;
  1865. }
  1866. }
  1867. }
  1868. .popContent {
  1869. padding: 10px;
  1870. max-height: 400px;
  1871. }
  1872. .carTypeItem {
  1873. padding: 0 30upx 20upx;
  1874. border-bottom: 1px solid #e5e5e5;
  1875. margin-top: 20upx;
  1876. width: 100%;
  1877. box-sizing: border-box;
  1878. }
  1879. .carTypeItem .nav .carseriesName {
  1880. font-size: 34upx;
  1881. width: 360upx;
  1882. font-family: PingFangSC-Medium, PingFangSC;
  1883. color: #4a4a4a;
  1884. overflow: hidden;
  1885. text-overflow: ellipsis;
  1886. white-space: nowrap;
  1887. }
  1888. .carTypeItem .nav .modelName {
  1889. font-size: 26upx;
  1890. width: 400upx;
  1891. font-family: PingFangSC-Medium, PingFangSC;
  1892. overflow: hidden;
  1893. text-overflow: ellipsis;
  1894. white-space: nowrap;
  1895. }
  1896. .carTypeItem .nav .nav_box {
  1897. margin: 10upx 0;
  1898. }
  1899. .carTypeItem .nav .nav_box .zid {
  1900. display: inline-block;
  1901. padding: 6upx 10upx;
  1902. font-size: 24upx;
  1903. height: 40upx;
  1904. background: #AFC9F7;
  1905. border-radius: 25upx;
  1906. color: #007AFF;
  1907. font-weight: bold;
  1908. line-height: 40upx;
  1909. }
  1910. .carTypeItem .nav .nav_box>p {
  1911. margin-left: 30upx;
  1912. color: #999;
  1913. font-size: 24upx;
  1914. }
  1915. .carTypeItem .price {
  1916. font-size: 16px;
  1917. width: 200upx;
  1918. flex-shrink: 0;
  1919. font-family: PingFangSC-Regular, PingFangSC;
  1920. font-weight: 400;
  1921. color: #007AFF;
  1922. }
  1923. .quotePlan .body .row {
  1924. height: 70upx;
  1925. }
  1926. .quotePlan .body .date {
  1927. background-color: $themeColor;
  1928. color: $themeColor;
  1929. font-size: 22upx;
  1930. padding: 0upx 7upx;
  1931. border-radius: 3upx;
  1932. margin: 10upx;
  1933. margin-right: 10upx;
  1934. }
  1935. /* 报价方案End */
  1936. /* 报价公司Start */
  1937. .quoteCompany {
  1938. margin: 20upx 30upx;
  1939. box-sizing: border-box;
  1940. /* background:#FFFFFF; */
  1941. position: relative;
  1942. border-radius: 20upx;
  1943. }
  1944. .quoteCompany .header {
  1945. height: 80upx;
  1946. padding: 0 30upx;
  1947. position: relative;
  1948. }
  1949. .quoteCompany .header .title {
  1950. font-size: 30upx;
  1951. font-weight: bold;
  1952. padding-left: 25upx;
  1953. }
  1954. .quoteCompany .header .title:before {
  1955. content: "";
  1956. position: absolute;
  1957. left: 30upx;
  1958. top: 25upx;
  1959. width: 8upx;
  1960. height: 30upx;
  1961. background-color: rgba($themeColor, 0.6);
  1962. }
  1963. .quoteCompany .header .title .icon {
  1964. color: rgba($themeColor, 0.6);
  1965. margin-left: 15upx;
  1966. }
  1967. .quoteCompanyItem {
  1968. margin-bottom: 20upx;
  1969. background: #FFFFFF;
  1970. border-radius: 15upx;
  1971. padding: 10px 20px 0 20px;
  1972. box-sizing: border-box;
  1973. cursor: pointer;
  1974. }
  1975. .quoteCompanyItem>view>view {
  1976. padding: 5px 0;
  1977. }
  1978. .quoteCompanyItem .top {
  1979. position: relative;
  1980. }
  1981. .quoteCompanyItem .top .companyIcon {
  1982. flex-shrink: 0;
  1983. }
  1984. .quoteCompanyItem .top .companyIcon image {
  1985. width: 34px;
  1986. height: 34px;
  1987. margin-right: 10px;
  1988. }
  1989. .quoteCompanyItem .top .companyName {
  1990. font-size: 32upx;
  1991. font-weight: bold;
  1992. width: 180upx;
  1993. overflow: hidden;
  1994. text-overflow: ellipsis;
  1995. white-space: nowrap;
  1996. }
  1997. .quoteCompanyItem .top .totalMoney {
  1998. font-size: 40upx;
  1999. font-weight: bold;
  2000. color: $themeColor;
  2001. position: absolute;
  2002. top: -15upx;
  2003. right: 0;
  2004. }
  2005. .quoteCompanyItem .top .tip {
  2006. font-size: 26upx;
  2007. font-weight: bold;
  2008. color: #999;
  2009. position: absolute;
  2010. top: 0upx;
  2011. right: 0;
  2012. }
  2013. .sum {
  2014. color: #ea552d;
  2015. font-size: 22px;
  2016. font-weight: bold;
  2017. }
  2018. .quoteCompanyItem .top .signs {
  2019. width: 500upx;
  2020. overflow: hidden;
  2021. text-overflow: ellipsis;
  2022. white-space: nowrap;
  2023. }
  2024. .quoteCompanyItem .top .sign {
  2025. height: 40upx;
  2026. margin: 0upx 10upx;
  2027. background: rgba($themeColor, 0.6);
  2028. color: $themeColor;
  2029. font-size: 20upx;
  2030. margin-right: 10upx;
  2031. border-radius: 6upx;
  2032. padding: 0 2px;
  2033. line-height: 40upx;
  2034. }
  2035. .jqsign {
  2036. height: 20px;
  2037. background: rgba(255, 177, 177, 0.55);
  2038. color: #fd0a0a;
  2039. font-size: 20upx;
  2040. border-radius: 6upx;
  2041. padding: 0 10px;
  2042. box-sizing: border-box;
  2043. }
  2044. .quoteCompanyItem .body {
  2045. padding: 20upx 0;
  2046. flex-wrap: wrap;
  2047. }
  2048. .quoteCompanyItem .body>view {
  2049. flex-shrink: 0;
  2050. width: 50%;
  2051. overflow: hidden;
  2052. text-overflow: ellipsis;
  2053. white-space: nowrap;
  2054. }
  2055. .quoteCompanyItem .body .icon-exchange {
  2056. margin-right: 15upx;
  2057. display: inline-block;
  2058. }
  2059. /* 报价公司End */
  2060. /* 查看详情按钮Start */
  2061. .btn {
  2062. font-size: 16px;
  2063. color: #fff;
  2064. background-color: #ea552d;
  2065. margin-top: 10px;
  2066. }
  2067. /* 底部的样式Start */
  2068. .infoBottom {
  2069. height: 140upx;
  2070. position: fixed;
  2071. bottom: 0;
  2072. left: 0;
  2073. right: 0;
  2074. background: #FFFFFF;
  2075. border-top: 1upx solid #EEEEEE;
  2076. z-index: 99;
  2077. }
  2078. .infoBottom>button {
  2079. // font-size: 30upx;
  2080. background: $themeColor;
  2081. color: #FFFFFF;
  2082. flex: 1;
  2083. margin: 0upx 30upx;
  2084. }
  2085. /* 查看详情按钮End */
  2086. </style>