EntryDetails.vue 171 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769
  1. <template>
  2. <div v-loading.fullscreen.lock="fullscreenLoading">
  3. <div class="Entry-all">
  4. <el-dialog :close-on-click-modal="false" title="实时汇率提示" :visible.sync="SSHLVisible">
  5. <el-table border :data="currencyss">
  6. <el-table-column property="currName" label="币种" width="150"></el-table-column>
  7. <el-table-column property="rate" label="汇率" width="200"></el-table-column>
  8. <el-table-column property="lastUpdateDt" label="更新时间"></el-table-column>
  9. </el-table>
  10. <div style="margin-top: 15px;text-align: right;">
  11. <el-button type="primary" @click="SSHLVisible=false">已知晓</el-button>
  12. </div>
  13. </el-dialog>
  14. <el-dialog width="400px" title="设置查看权限" class="permissionsbox" :visible.sync="setpermissions" :close-on-click-modal="false">
  15. <el-checkbox-group v-model="viewUsers" @change="handleCheckAllChange">
  16. <el-checkbox v-for="item in viewUsersarr" :label="item.id" :key="item.id">{{item.name}}</el-checkbox>
  17. </el-checkbox-group>
  18. <div style="text-align: right;margin-top: 15px;">
  19. <el-button size="mini" @click="EnterExitCostSetViewPermissiion" type="primary">分配</el-button>
  20. <el-button size="mini" @click="setpermissions=false">取消</el-button>
  21. </div>
  22. </el-dialog>
  23. <el-dialog width="1600px" title="交通费详细" :visible.sync="TransportationVisible" :close-on-click-modal="false">
  24. <div style="display: flex;justify-content: space-between;align-items: center;margin: 5px 0;">
  25. <div>接送机(合计):{{ numFilters(Transportationdatatotal) }}&nbsp;CNY</div>
  26. <div>
  27. <el-button size="mini" @click="RefreshInterval" type="primary">刷新城市区间费标准</el-button>
  28. <el-button size="mini" @click="addTransportationdata" type="primary">添加一行</el-button>
  29. </div>
  30. </div>
  31. <el-table border :data="Transportationdata">
  32. <el-table-column property="no" label="序号" width="50"></el-table-column>
  33. <el-table-column property="ovId" label="城市" width="150">
  34. <template slot-scope="scope">
  35. <el-select size="mini"
  36. @change="UrbanSelect(scope.row, $event, scope.$index)"
  37. v-model="scope.row.ovId" filterable placeholder="请选择">
  38. <el-option v-for="item in fulecao" :key="item.id" :label="item.area"
  39. :value="item.id">
  40. <span style="float: left">{{ item.area }}</span>
  41. <!-- <span style="float: right; color: #8492a6; font-size: 13px">{{item.city}}</span> -->
  42. </el-option>
  43. </el-select>
  44. <!-- <el-input disabled size="mini" v-model="scope.row.b"></el-input> -->
  45. </template>
  46. </el-table-column>
  47. <el-table-column property="cost" label="成本价(要除以团组人数)" width="180">
  48. <template slot-scope="scope">
  49. <div>{{reservetwo(scope.row.cost/Basicdata.groupSize)}}&nbsp;{{scope.row.currencyName}}&nbsp;({{scope.row.cost+'/'+Basicdata.groupSize}})</div>
  50. <!-- <el-input disabled size="mini" v-model="scope.row.c"></el-input> -->
  51. </template>
  52. </el-table-column>
  53. <el-table-column property="guideCost" label="接送机导游" width="140">
  54. <template slot-scope="scope">
  55. <el-input-number disabled style="width:100%" size="mini" :class-unit="scope.row.currencyName" :precision="2" class="inputNumberClass"
  56. :controls="false" v-model="scope.row.guideCost"></el-input-number>
  57. <!-- <el-input disabled size="mini" v-model="scope.row.guideCost">
  58. <i slot="suffix" style="font-style:normal;margin-right: 10px;line-height: 27px;color: #606266;">{{ scope.row.currencyName }}</i>
  59. </el-input> -->
  60. </template>
  61. </el-table-column>
  62. <el-table-column property="otherCost" label="其他费用(只有澳大利亚有这个数据)" width="150">
  63. <template slot-scope="scope">
  64. <el-input-number @blur="UrbanModify(scope.row,scope.row.currencyName)" style="width:100%" size="mini" :class-unit="scope.row.currencyName" :precision="2" class="inputNumberClass"
  65. :controls="false" v-model="scope.row.otherCost"></el-input-number>
  66. <!-- <el-input size="mini" v-model="scope.row.otherCost">
  67. <i slot="suffix" style="font-style:normal;margin-right: 10px;line-height: 27px;color: #606266;">{{ scope.row.currencyName }}</i>
  68. </el-input> -->
  69. </template>
  70. </el-table-column>
  71. <el-table-column property="serviceCount" label="服务次数(默认为1)" width="150">
  72. <template slot-scope="scope">
  73. <el-input-number @blur="UrbanModify(scope.row,scope.row.currencyName)" style="width:100%" size="mini" :precision="2" class="inputNumberClass"
  74. :controls="false" v-model="scope.row.serviceCount"></el-input-number>
  75. <!-- <el-input size="mini" v-model="scope.row.serviceCount"></el-input> -->
  76. </template>
  77. </el-table-column>
  78. <el-table-column property="coefficient" label="系数(默认2.5)" width="110">
  79. <template slot-scope="scope">
  80. <el-input-number @blur="UrbanModify(scope.row,scope.row.currencyName)" style="width:100%" size="mini" :precision="2" class="inputNumberClass"
  81. :controls="false" v-model="scope.row.coefficient"></el-input-number>
  82. <!-- <el-input size="mini" v-model="scope.row.coefficient"></el-input> -->
  83. </template>
  84. </el-table-column>
  85. <el-table-column property="quote" label="报价" width="200">
  86. <template slot-scope="scope">
  87. <el-input-number disabled style="width:100%" size="mini" class-unit="CNY" :precision="2" class="inputNumberClass"
  88. :controls="false" v-model="scope.row.quote"></el-input-number>
  89. <!-- <el-input size="mini" v-model="scope.row.quote">
  90. <i slot="suffix" style="font-style:normal;margin-right: 10px;line-height: 27px;color: #606266;">CNY</i>
  91. </el-input> -->
  92. </template>
  93. </el-table-column>
  94. <el-table-column property="remark" label="备注">
  95. <template slot-scope="scope">
  96. <el-input size="mini" v-model="scope.row.remark"></el-input>
  97. </template>
  98. </el-table-column>
  99. <el-table-column label="操作" width="100">
  100. <template slot-scope="scope">
  101. <el-button size="mini" @click.native.prevent="deleteRowJSJ(scope.$index, Transportationdata,scope.row)" type="danger">移除</el-button>
  102. </template>
  103. </el-table-column>
  104. </el-table>
  105. <div class="jiaotongfei-ul">
  106. <div class="jiaotongfei-li">
  107. <div style="display: flex;justify-content: space-between;align-items: center;margin: 5px 0;">
  108. <div>拉车(合计):{{ numFilters(pullCartFeeTotal) }}&nbsp;CNY</div>
  109. <el-button @click="addpullCartFeeDetails" size="mini" type="primary">添加一行</el-button>
  110. </div>
  111. <!-- <div>拉车(合计)</div> -->
  112. <el-table border :data="pullCartFeeDetails">
  113. <el-table-column property="cost" label="成本价" width="150">
  114. <template slot-scope="scope">
  115. <el-input-number @blur="UrbanModifyLC(scope.row)" style="width:100%" size="mini" :class-unit="scope.row.currencyName" :precision="2" class="inputNumberClass"
  116. :controls="false" v-model="scope.row.cost"></el-input-number>
  117. </template>
  118. </el-table-column>
  119. <el-table-column property="coefficient" label="系数" width="150">
  120. <template slot-scope="scope">
  121. <el-input-number @blur="UrbanModifyLC(scope.row)" style="width:100%" size="mini" :precision="2"
  122. :controls="false" v-model="scope.row.coefficient"></el-input-number>
  123. </template>
  124. </el-table-column>
  125. <el-table-column property="remark" label="备注">
  126. <template slot-scope="scope">
  127. <el-input size="mini" v-model="scope.row.remark"></el-input>
  128. </template>
  129. </el-table-column>
  130. <el-table-column label="操作" width="100">
  131. <template slot-scope="scope">
  132. <el-button size="mini"
  133. @click.native.prevent="deleteRowLC(scope.$index, pullCartFeeDetails, scope.row)"
  134. type="danger">移除</el-button>
  135. </template>
  136. </el-table-column>
  137. </el-table>
  138. </div>
  139. <div class="jiaotongfei-li">
  140. <div style="display: flex;justify-content: space-between;align-items: center;margin: 5px 0;">
  141. <div>火车(合计):{{ numFilters(trainFeeTotal) }}&nbsp;CNY</div>
  142. <el-button @click="addtrainFeeDetails" size="mini" type="primary">添加一行</el-button>
  143. </div>
  144. <el-table border :data="trainFeeDetails">
  145. <el-table-column property="cost" label="成本价" width="150">
  146. <template slot-scope="scope">
  147. <el-input-number @blur="UrbanModifyHC(scope.row)" style="width:100%" size="mini" :class-unit="scope.row.currencyName" :precision="2" class="inputNumberClass"
  148. :controls="false" v-model="scope.row.cost"></el-input-number>
  149. </template>
  150. </el-table-column>
  151. <el-table-column property="coefficient" label="系数" width="150">
  152. <template slot-scope="scope">
  153. <el-input-number @blur="UrbanModifyHC(scope.row)" style="width:100%" size="mini" :precision="2"
  154. :controls="false" v-model="scope.row.coefficient"></el-input-number>
  155. </template>
  156. </el-table-column>
  157. <el-table-column property="remark" label="备注">
  158. <template slot-scope="scope">
  159. <el-input size="mini" v-model="scope.row.remark"></el-input>
  160. </template>
  161. </el-table-column>
  162. <el-table-column label="操作" width="100">
  163. <template slot-scope="scope">
  164. <el-button size="mini"
  165. @click.native.prevent="deleteRowHC(scope.$index, trainFeeDetails, scope.row)"
  166. type="danger">移除</el-button>
  167. </template>
  168. </el-table-column>
  169. </el-table>
  170. </div>
  171. <div class="jiaotongfei-li">
  172. <div style="display: flex;justify-content: space-between;align-items: center;margin: 5px 0;">
  173. <div>城市机票(合计):{{ numFilters(cityAirTicketFeeTotal) }}&nbsp;CNY</div>
  174. <el-button @click="addcityAirTicketFeeDetails" size="mini" type="primary">添加一行</el-button>
  175. </div>
  176. <el-table border :data="cityAirTicketFeeDetails">
  177. <el-table-column property="cost" label="成本价" width="150">
  178. <template slot-scope="scope">
  179. <el-input-number @blur="UrbanModifyJP(scope.row)" style="width:100%" size="mini" :class-unit="scope.row.currencyName" :precision="2" class="inputNumberClass"
  180. :controls="false" v-model="scope.row.cost"></el-input-number>
  181. </template>
  182. </el-table-column>
  183. <el-table-column property="coefficient" label="系数" width="150">
  184. <template slot-scope="scope">
  185. <el-input-number @blur="UrbanModifyJP(scope.row)" style="width:100%" size="mini" :precision="2"
  186. :controls="false" v-model="scope.row.coefficient"></el-input-number>
  187. </template>
  188. </el-table-column>
  189. <el-table-column property="remark" label="备注">
  190. <template slot-scope="scope">
  191. <el-input size="mini" v-model="scope.row.remark"></el-input>
  192. </template>
  193. </el-table-column>
  194. <el-table-column label="操作" width="100">
  195. <template slot-scope="scope">
  196. <el-button size="mini"
  197. @click.native.prevent="deleteRowJP(scope.$index, cityAirTicketFeeDetails, scope.row)"
  198. type="danger">移除</el-button>
  199. </template>
  200. </el-table-column>
  201. </el-table>
  202. </div>
  203. </div>
  204. <div style="margin-top: 20px;font-weight: 600;">
  205. 城市交通费合计:{{ numFilters(Transportationdatatotal + pullCartFeeTotal + trainFeeTotal + cityAirTicketFeeTotal) }}&nbsp;CNY
  206. </div>
  207. <div style="text-align: right;margin-top: 20px;">
  208. <el-button @click="TransportationVisible=false">取消</el-button>
  209. <el-button @click="GetEnterExitCostOVFeeSave" type="primary">保 存</el-button>
  210. </div>
  211. </el-dialog>
  212. <div class="Entry-head">
  213. <div class="Entry-head-li">
  214. <label>团组名称:</label>
  215. <el-select style="width:250px" @change="chengvalue" v-model="value" filterable :filter-method="advancedFilter" placeholder="请选择">
  216. <el-option v-for="item in filteredOptions" :key="item.id" :label="item.groupName" :value="item.id">
  217. <span v-if="item.isNull=='false'" style="color:#409EFF">{{ item.groupName }}</span>
  218. <span v-else style="color:gray">{{ item.groupName }}</span>
  219. </el-option>
  220. </el-select>
  221. </div>
  222. <div v-if="isSave" class="Entry-head-li">
  223. <!-- <el-button type="primary">计算费用</el-button> -->
  224. <el-button @click="NationalTravelFeeImportReceivables" type="primary">导出到收款账单</el-button>
  225. <el-button @click="cleanout" type="primary">全部清空</el-button>
  226. <el-button @click="storage()" type="primary">保存</el-button>
  227. <el-select style="width:202px" v-model="listvalue" placeholder="请选择">
  228. <el-option v-for="item in listvalueoptions" :key="item.id" :label="item.name" :value="item.id">
  229. </el-option>
  230. </el-select>
  231. <el-button @click="eptschedule(1)" type="primary">导出所选明细表</el-button>
  232. <el-select style="width:202px" v-model="tablevalue" placeholder="请选择">
  233. <el-option v-for="item in tablevalueoptions" :key="item.id" :label="item.name" :value="item.id">
  234. </el-option>
  235. </el-select>
  236. <el-button @click="eptschedule(2)" type="primary">导出下拉所选表格</el-button>
  237. <el-button v-if="isAssignPerm" @click="setpermissionsbtn" type="primary">设置权限</el-button>
  238. <el-button @click="eptschedule(3)" type="primary">团组成员名单</el-button>
  239. </div>
  240. </div>
  241. <div class="Entry-form">
  242. <div class="Entry-form-li">
  243. <div class="Entry-li-lables">
  244. <el-checkbox v-model="choiceOne"></el-checkbox>
  245. <div class="li-lable">一、境内费用(其他费用)</div>
  246. <div class="li-lable">
  247. <span class="redzhu">(注:填好数值鼠标点击其他区域计算合计)</span>
  248. <label>合计:</label>
  249. <div class="sub-boxs">
  250. {{ DomesticFees.total=(DomesticFees.visafees + DomesticFees.vaccinefees +
  251. DomesticFees.nucleicfees + DomesticFees.serviceCharge + DomesticFees.insurance +
  252. DomesticFees.ticketsExhibitionL) | numFilter }}
  253. </div>
  254. <span>元/人</span>
  255. </div>
  256. </div>
  257. <div class="Entry-li-inif">
  258. <div class="Entry-inif-box">
  259. <label>签证费:</label>
  260. <el-input-number size="mini" :controls="false" :precision="2"
  261. v-model="DomesticFees.visafees"></el-input-number>
  262. <span>元/人</span>
  263. </div>
  264. <div class="Entry-inif-box">
  265. <label>签证费用描述:</label>
  266. <el-input style="width:900px" size="mini"
  267. v-model="DomesticFees.visafeesDescription"></el-input>
  268. <span class="redzhu">{{ visabeizhu }}</span>
  269. </div>
  270. <el-button @click="Getnewvisafee" type="primary"
  271. size="mini">获取最新签证费用</el-button>
  272. </div>
  273. <div class="Entry-li-inif">
  274. <div class="Entry-inif-box">
  275. <label>疫苗费:</label>
  276. <el-input-number size="mini" :controls="false" :precision="2"
  277. v-model="DomesticFees.vaccinefees"></el-input-number>
  278. <span>元/人</span>
  279. </div>
  280. <div class="Entry-inif-box">
  281. <label>核酸检测费:</label>
  282. <el-input-number size="mini" :controls="false" :precision="2"
  283. v-model="DomesticFees.nucleicfees"></el-input-number>
  284. <span>元/人;</span>
  285. </div>
  286. <div class="Entry-inif-box">
  287. <label> 服务费:</label>
  288. <el-input-number size="mini" :controls="false" :precision="2"
  289. v-model="DomesticFees.serviceCharge"></el-input-number>
  290. <span>元/人;</span>
  291. </div>
  292. </div>
  293. <div class="Entry-li-inif">
  294. <div class="Entry-inif-box">
  295. <label>保险费:</label>
  296. <el-input-number size="mini" :controls="false" :precision="2"
  297. v-model="DomesticFees.insurance"></el-input-number>
  298. <span>元/人</span>
  299. </div>
  300. <div class="Entry-inif-box">
  301. <label>参展门票:</label>
  302. <el-input-number size="mini" :controls="false" :precision="2"
  303. v-model="DomesticFees.ticketsExhibitionL"></el-input-number>
  304. <span>元/人;</span>
  305. </div>
  306. <div class="Entry-inif-box">
  307. <label>备注:</label>
  308. <el-input style="width:900px" size="mini"
  309. v-model="DomesticFees.firstItemRemark"></el-input>
  310. </div>
  311. </div>
  312. </div>
  313. <div class="Entry-form-li">
  314. <div class="Entry-li-lables">
  315. <!-- <el-checkbox v-model="choiceTwo"></el-checkbox> -->
  316. <div class="li-lable">二、国际旅费合计:</div>
  317. <div style="display: flex;">
  318. <div class="li-lable">
  319. <el-checkbox style="margin-right: -10px;" v-model="sumJJC"></el-checkbox>
  320. <label>(经济舱)</label>
  321. <div class="sub-boxs">
  322. {{ TotalExpenses.EconomyClasstotal=(TotalExpenses.EconomyClass +
  323. TotalExpenses.TravellingExpensesJJ) | numFilter }}
  324. </div>
  325. <span>元/人</span>
  326. </div>
  327. &nbsp;&nbsp;&nbsp;&nbsp;
  328. <div class="li-lable">
  329. <el-checkbox style="margin-right: -10px;" v-model="sumGWC"></el-checkbox>
  330. <label>(公务舱)</label>
  331. <div class="sub-boxs">
  332. {{ TotalExpenses.BusinessClasstotal=(TotalExpenses.BusinessClass +
  333. TotalExpenses.TravellingExpensesGW) | numFilter }}
  334. </div>
  335. <span>元/人</span>
  336. </div>
  337. &nbsp;&nbsp;&nbsp;&nbsp;
  338. <div class="li-lable">
  339. <el-checkbox style="margin-right: -10px;" v-model="sumTDC"></el-checkbox>
  340. <label>(头等舱)</label>
  341. <div class="sub-boxs">
  342. {{ TotalExpenses.Firstclasstotal=(TotalExpenses.Firstclass +
  343. TotalExpenses.TravellingExpensesTD) | numFilter }}
  344. </div>
  345. <span>元/人</span>
  346. </div>
  347. </div>
  348. </div>
  349. <div class="Entry-li-inif">
  350. <label>国际机票:&nbsp; &nbsp; &nbsp; </label>
  351. <div class="Entry-inif-box">
  352. <label>(经济舱):</label>
  353. <el-input-number size="mini" :controls="false" :precision="2"
  354. v-model="TotalExpenses.EconomyClass"></el-input-number>
  355. <span>元/人</span>
  356. </div>
  357. <div class="Entry-inif-box">
  358. <label>(公务舱):</label>
  359. <el-input-number size="mini" :controls="false" :precision="2"
  360. v-model="TotalExpenses.BusinessClass"></el-input-number>
  361. <span>元/人;</span>
  362. </div>
  363. <div class="Entry-inif-box">
  364. <label>(头等舱):</label>
  365. <el-input-number size="mini" :controls="false" :precision="2"
  366. v-model="TotalExpenses.Firstclass"></el-input-number>
  367. <span>元/人;</span>
  368. </div>
  369. <span v-if="airDataArr.length<1" class="redzhu">(机票数据未录入)</span>
  370. <div v-else>
  371. <span class="redzhu">有多条机票费用数据请自行选择!!</span>&nbsp;&nbsp;
  372. <el-select style="width:400px" @change="Fillin" size="mini" v-model="airDataArrvalue" placeholder="请选择">
  373. <el-option
  374. v-for="item in airDataArr"
  375. :key="item.remark"
  376. :label="item.remark"
  377. :value="item.remark">
  378. <el-tooltip
  379. popper-class="custom-tooltip-style"
  380. effect="light"
  381. :content="item.tripDesc"
  382. placement="right">
  383. <span>{{ item.remark }}</span>
  384. </el-tooltip>
  385. </el-option>
  386. </el-select>
  387. <!-- <el-button type="primary" @click="Fillin" size="mini">填 入</el-button> -->
  388. </div>
  389. </div>
  390. <div class="Entry-li-inif">
  391. <label>城市区间交通费:&nbsp; &nbsp; &nbsp; </label>
  392. <div class="Entry-inif-box">
  393. <label>(经济舱):</label>
  394. <el-input-number size="mini" :controls="false" :precision="2"
  395. v-model="TotalExpenses.TravellingExpensesJJ"></el-input-number>
  396. <span>元/人;</span>
  397. </div>
  398. <div class="Entry-inif-box">
  399. <label>(公务舱):</label>
  400. <el-input-number size="mini" :controls="false" :precision="2"
  401. v-model="TotalExpenses.TravellingExpensesGW"></el-input-number>
  402. <span>元/人;</span>
  403. </div>
  404. <div class="Entry-inif-box">
  405. <label>(头等舱):</label>
  406. <el-input-number size="mini" :controls="false" :precision="2"
  407. v-model="TotalExpenses.TravellingExpensesTD"></el-input-number>
  408. <span>元/人;</span>
  409. </div>
  410. <div v-if="isView" class="Entry-inif-box">
  411. <el-button @click="openTransportation" type="primary" size="mini">交通费明细</el-button>
  412. </div>
  413. </div>
  414. <div class="Entry-li-inif">
  415. <div class="Entry-inif-box">
  416. <label>备注:</label>
  417. <el-input style="width:1000px" size="mini"
  418. v-model="TotalExpenses.twoItemRemark"></el-input>
  419. </div>
  420. </div>
  421. <div class="Entry-li-inif">
  422. <div v-for="(item, index) in currencys" :key="index" class="Entry-inif-box">
  423. <label>{{ item.currencyName }}汇率:</label>
  424. <el-input-number size="mini" :controls="false" :precision="4"
  425. v-model="item.rate"></el-input-number>
  426. </div>
  427. <span style="color:red;">* 若客户有意见,需要与财务商量后进行适当调整 </span>
  428. <el-popover
  429. placement="top"
  430. width="402"
  431. trigger="hover">
  432. <el-table border :data="currencyss">
  433. <el-table-column width="100" property="currName" label="币种"></el-table-column>
  434. <el-table-column width="100" property="rate" label="汇率"></el-table-column>
  435. <el-table-column width="200" property="lastUpdateDt" label="更新时间"></el-table-column>
  436. </el-table>
  437. <span style="color: #409EFF;" slot="reference" class="redzhu">{{CurrencysRemark}}</span>
  438. <div style="margin-top: 5px;text-align: right;">
  439. <el-button @click="adoptRealtime" type="primary" size="mini">采用最新汇率</el-button>
  440. </div>
  441. </el-popover>
  442. &nbsp;&nbsp;&nbsp;&nbsp;
  443. </div>
  444. </div>
  445. <div class="Entry-form-li">
  446. <div class="Entry-li-lable">
  447. <div style="display: flex;align-items: center;">
  448. <el-checkbox v-model="choiceThree"></el-checkbox>
  449. <div class="li-lable">三、住宿费:</div>
  450. <div style="display: flex;">
  451. <div class="li-lable">
  452. <label>合计:</label>
  453. <div class="sub-boxs">{{ TotalAccommodationFee | numFilter }}</div>
  454. <span>元/人</span>
  455. </div>
  456. </div>
  457. </div>
  458. <div class="btn-Entry">
  459. <el-button type="primary" @click="addlist('住宿费')" size="mini">新 增</el-button>
  460. </div>
  461. </div>
  462. <div class="Entry-li-inif">
  463. <el-table :data="quarterageData" border style="width: 100%">
  464. <el-table-column prop="days" label="第几晚" width="180">
  465. <template slot-scope="scope">
  466. <el-input-number size="mini" :controls="false"
  467. v-model="scope.row.days"></el-input-number>
  468. </template>
  469. </el-table-column>
  470. <el-table-column style="position: relative;" prop="city" label="城 市" width="180">
  471. <template slot-scope="scope">
  472. <el-select size="mini" @change="changeSelect(scope.row, $event, scope.$index)"
  473. v-model="scope.row.nationalTravelFeeId" filterable placeholder="请选择">
  474. <el-option v-for="item in placeinif" :key="item.id" :label="item.cityname"
  475. :value="item.id">
  476. <span style="float: left">{{ item.cityname }}</span>
  477. <!-- <span style="float: right; color: #8492a6; font-size: 13px">{{item.city}}</span> -->
  478. </el-option>
  479. </el-select>
  480. </template>
  481. </el-table-column>
  482. <el-table-column prop="cost" label=" 费用标准" width="180">
  483. <template slot-scope="scope">
  484. <el-input-number @input="zhusuinput(scope.row)" size="mini" :precision="2"
  485. :controls="false" v-model="scope.row.cost"></el-input-number>
  486. </template>
  487. </el-table-column>
  488. <el-table-column prop="currencyName" label=" 币 种" width="180">
  489. <template slot-scope="scope">
  490. <el-input disabled size="mini" v-model="scope.row.currencyName"></el-input>
  491. </template>
  492. </el-table-column>
  493. <el-table-column prop="subTotal" label="费用小计" width="180">
  494. <template slot-scope="scope">
  495. <div class="sub-boxs">{{ scope.row.subTotal | numFilter }}</div>&nbsp;CNY
  496. </template>
  497. </el-table-column>
  498. <el-table-column prop="address" label="操 作">
  499. <template slot-scope="scope">
  500. <el-button v-if="isSave" style="color: #fff;" size="mini" type="danger"
  501. @click="deleteRow(scope.$index, scope.row, quarterageData, 1)">删除</el-button>
  502. </template>
  503. </el-table-column>
  504. </el-table>
  505. </div>
  506. </div>
  507. <div class="Entry-form-li">
  508. <div class="Entry-li-lable">
  509. <div style="display: flex;align-items: center;">
  510. <el-checkbox v-model="choiceFour"></el-checkbox>
  511. <div class="li-lable">四、伙食费:</div>
  512. <div style="display: flex;">
  513. <div class="li-lable">
  514. <label>合计:</label>
  515. <div class="sub-boxs">{{ TotalMeals | numFilter }}</div>
  516. <span>元/人</span>
  517. </div>
  518. </div>
  519. </div>
  520. <div class="btn-Entry">
  521. <el-button type="primary" @click="addlist('伙食费')" size="mini">新 增</el-button>
  522. </div>
  523. </div>
  524. <div class="Entry-li-inif">
  525. <el-table :data="boardWagesData" border style="width: 100%">
  526. <el-table-column prop="days" label="第几晚" width="180">
  527. <template slot-scope="scope">
  528. <el-input-number size="mini" :controls="false"
  529. v-model="scope.row.days"></el-input-number>
  530. </template>
  531. </el-table-column>
  532. <el-table-column style="position: relative;" prop="city" label="城 市" width="180">
  533. <!-- <template slot-scope="scope">
  534. <el-input size="mini" v-model="scope.row.city"></el-input>
  535. </template> -->
  536. <template slot-scope="scope">
  537. <el-select size="mini" @change="mealschangeSelect(scope.row, $event, scope.$index)"
  538. v-model="scope.row.nationalTravelFeeId" filterable placeholder="请选择">
  539. <el-option v-for="item in placeinif" :key="item.id" :label="item.cityname"
  540. :value="item.id">
  541. <span style="float: left">{{ item.cityname }}</span>
  542. <!-- <span style="float: right; color: #8492a6; font-size: 13px">{{item.city}}</span> -->
  543. </el-option>
  544. </el-select>
  545. </template>
  546. </el-table-column>
  547. <el-table-column prop="cost" label=" 费用标准" width="180">
  548. <template slot-scope="scope">
  549. <el-input-number size="mini" @input="mealsinput(scope.row)" :precision="2"
  550. :controls="false" v-model="scope.row.cost"></el-input-number>
  551. </template>
  552. </el-table-column>
  553. <el-table-column prop="currencyName" label=" 币 种" width="180">
  554. <template slot-scope="scope">
  555. <el-input disabled size="mini" v-model="scope.row.currencyName"></el-input>
  556. </template>
  557. </el-table-column>
  558. <el-table-column prop="subTotal" label="费用小计" width="180">
  559. <template slot-scope="scope">
  560. <div class="sub-boxs">{{ scope.row.subTotal | numFilter }}</div>&nbsp;CNY
  561. </template>
  562. </el-table-column>
  563. <el-table-column prop="address" label="操 作">
  564. <template slot-scope="scope">
  565. <el-button v-if="isSave" style="color: #fff;" size="mini" type="danger"
  566. @click="deleteRow(scope.$index, scope.row, boardWagesData, 2)">删除</el-button>
  567. </template>
  568. </el-table-column>
  569. </el-table>
  570. </div>
  571. </div>
  572. <div class="Entry-form-li">
  573. <div class="Entry-li-lable">
  574. <div style="display: flex;align-items: center;">
  575. <el-checkbox v-model="choiceFive"></el-checkbox>
  576. <div class="li-lable">五、公杂费:</div>
  577. <div style="display: flex;">
  578. <div class="li-lable">
  579. <label>合计:</label>
  580. <div class="sub-boxs">{{ TotalMiscellaneous | numFilter }}</div>
  581. <span>元/人</span>
  582. </div>
  583. </div>
  584. </div>
  585. <div class="btn-Entry">
  586. <el-button type="primary" @click="addlist('公杂费')" size="mini">新 增</el-button>
  587. </div>
  588. </div>
  589. <div class="Entry-li-inif">
  590. <el-table :data="miscellaneousFeeData" border style="width: 100%">
  591. <el-table-column prop="days" label="第几晚" width="180">
  592. <template slot-scope="scope">
  593. <el-input-number size="mini" :controls="false"
  594. v-model="scope.row.days"></el-input-number>
  595. </template>
  596. </el-table-column>
  597. <el-table-column style="position: relative;" prop="city" label="城 市" width="180">
  598. <!-- <template slot-scope="scope">
  599. <el-input size="mini" v-model="scope.row.city"></el-input>
  600. </template> -->
  601. <template slot-scope="scope">
  602. <el-select @change="MiscellaneouschangeSelect(scope.row, $event)" size="mini"
  603. v-model="scope.row.nationalTravelFeeId" filterable placeholder="请选择">
  604. <el-option v-for="item in placeinif" :key="item.id" :label="item.cityname"
  605. :value="item.id">
  606. <span style="float: left">{{ item.cityname }}</span>
  607. <!-- <span style="float: right; color: #8492a6; font-size: 13px">{{item.city}}</span> -->
  608. </el-option>
  609. </el-select>
  610. </template>
  611. </el-table-column>
  612. <el-table-column prop="cost" label=" 费用标准" width="180">
  613. <template slot-scope="scope">
  614. <el-input-number @input="Miscellaneousinput(scope.row)" size="mini" :precision="2"
  615. :controls="false" v-model="scope.row.cost"></el-input-number>
  616. </template>
  617. </el-table-column>
  618. <el-table-column prop="currencyName" label=" 币 种" width="180">
  619. <template slot-scope="scope">
  620. <el-input disabled size="mini" v-model="scope.row.currencyName"></el-input>
  621. </template>
  622. </el-table-column>
  623. <el-table-column prop="subTotal" label="费用小计" width="180">
  624. <template slot-scope="scope">
  625. <div class="sub-boxs">{{ scope.row.subTotal | numFilter }}</div>&nbsp;CNY
  626. </template>
  627. </el-table-column>
  628. <el-table-column prop="address" label="操 作">
  629. <template slot-scope="scope">
  630. <el-button v-if="isSave" style="color: #fff;" size="mini" type="danger"
  631. @click="deleteRow(scope.$index, scope.row, miscellaneousFeeData, 3)">删除</el-button>
  632. </template>
  633. </el-table-column>
  634. </el-table>
  635. </div>
  636. </div>
  637. <div class="Entry-form-li">
  638. <div class="Entry-li-lable">
  639. <div style="display: flex;align-items: center;">
  640. <el-checkbox v-model="choiceSix"></el-checkbox>
  641. <div class="li-lable">六、培训费:</div>
  642. <div style="display: flex;">
  643. <div class="li-lable">
  644. <label>合计:</label>
  645. <div class="sub-boxs">{{ trainingExpense | numFilter }}</div>
  646. <span>元/人</span>
  647. </div>
  648. </div>
  649. </div>
  650. <div class="btn-Entry">
  651. <el-button type="primary" @click="addlist('培训费')" size="mini">新 增</el-button>
  652. </div>
  653. </div>
  654. <div class="Entry-li-inif">
  655. <el-table :data="trainingExpenseData" border style="width: 100%">
  656. <el-table-column prop="days" label="第几晚" width="180">
  657. <template slot-scope="scope">
  658. <el-input-number size="mini" :controls="false"
  659. v-model="scope.row.days"></el-input-number>
  660. </template>
  661. </el-table-column>
  662. <el-table-column style="position: relative;" prop="city" label="城 市" width="180">
  663. <!-- <template slot-scope="scope">
  664. <el-input size="mini" v-model="scope.row.city"></el-input>
  665. </template> -->
  666. <template slot-scope="scope">
  667. <el-select @change="TrainingExpenseDataSelect(scope.row, $event, scope.$index)" size="mini"
  668. v-model="scope.row.nationalTravelFeeId" filterable placeholder="请选择">
  669. <el-option v-for="item in placeinif" :key="item.id" :label="item.cityname"
  670. :value="item.id">
  671. <span style="float: left">{{ item.cityname }}</span>
  672. <!-- <span style="float: right; color: #8492a6; font-size: 13px">{{item.city}}</span> -->
  673. </el-option>
  674. </el-select>
  675. </template>
  676. </el-table-column>
  677. <el-table-column prop="cost" label=" 费用标准" width="180">
  678. <template slot-scope="scope">
  679. <el-input-number @input="Traininginput(scope.row)" size="mini" :precision="2"
  680. :controls="false" v-model="scope.row.cost"></el-input-number>
  681. </template>
  682. </el-table-column>
  683. <el-table-column prop="currencyName" label=" 币 种" width="180">
  684. <template slot-scope="scope">
  685. <el-input disabled size="mini" v-model="scope.row.currencyName"></el-input>
  686. </template>
  687. </el-table-column>
  688. <el-table-column prop="subTotal" label="费用小计" width="180">
  689. <template slot-scope="scope">
  690. <div class="sub-boxs">{{ scope.row.subTotal | numFilter }}</div>&nbsp;CNY
  691. </template>
  692. </el-table-column>
  693. <el-table-column prop="address" label="操 作">
  694. <template slot-scope="scope">
  695. <el-button v-if="isSave" style="color: #fff;" size="mini" type="danger"
  696. @click="deleteRow(scope.$index, scope.row, trainingExpenseData, 4)">删除</el-button>
  697. </template>
  698. </el-table-column>
  699. </el-table>
  700. </div>
  701. </div>
  702. <div class="Entry-form-li">
  703. <div class="Entry-li-lable">
  704. <div style="display: flex;align-items: center;">
  705. <el-checkbox v-model="choiceSeven"></el-checkbox>
  706. <div class="li-lable">七、其他:</div>
  707. <div style="display: flex;">
  708. <div class="li-lable">
  709. <label>合计:</label>
  710. <div class="sub-boxs">{{ otherExpense | numFilter }}</div>
  711. <span>元/人</span>
  712. </div>
  713. </div>
  714. <div style="color:red">
  715. &nbsp;注:特殊情况才在这里填写,如:要计算车导费、备用金费用等
  716. </div>
  717. </div>
  718. <div class="btn-Entry">
  719. <el-button type="primary" @click="addlist('其他')" size="mini">新 增</el-button>
  720. </div>
  721. </div>
  722. <div class="Entry-li-inif">
  723. <el-table :data="otherData" border style="width: 100%">
  724. <el-table-column prop="index" label="第几项" width="180">
  725. <template slot-scope="scope">
  726. <el-input-number size="mini" :controls="false"
  727. v-model="scope.row.index"></el-input-number>
  728. </template>
  729. </el-table-column>
  730. <el-table-column style="position: relative;" prop="setDataId" label="费用类型" width="180">
  731. <!-- <template slot-scope="scope">
  732. <el-input size="mini" v-model="scope.row.city"></el-input>
  733. </template> -->
  734. <template slot-scope="scope">
  735. <el-select size="mini" v-model="scope.row.setDataId" filterable placeholder="请选择">
  736. <el-option v-for="item in otherfylx" :key="item.id" :label="item.name"
  737. :value="item.id">
  738. <span style="float: left">{{ item.name }}</span>
  739. <!-- <span style="float: right; color: #8492a6; font-size: 13px">{{item.city}}</span> -->
  740. </el-option>
  741. </el-select>
  742. </template>
  743. </el-table-column>
  744. <el-table-column prop="cost" label=" 费用标准" width="180">
  745. <template slot-scope="scope">
  746. <el-input-number @input="otherinput(scope.row)" size="mini" :precision="2"
  747. :controls="false" v-model="scope.row.cost"></el-input-number>
  748. </template>
  749. </el-table-column>
  750. <el-table-column prop="currencyName" label=" 币 种" width="180">
  751. <template slot-scope="scope">
  752. <el-select @change="othercurrencychange(scope.row.currency, scope.row)" size="mini"
  753. v-model="scope.row.currency" filterable placeholder="请选择">
  754. <el-option v-for="item in othercurrencys" :key="item.currencyId"
  755. :label="item.currencyCode" :value="item.currencyId">
  756. <span style="float: left">{{ item.currencyCode + ' 汇率:' + item.rate
  757. }}</span>
  758. </el-option>
  759. </el-select>
  760. <!-- <el-input size="mini" v-model="scope.row.currencyName"></el-input> -->
  761. </template>
  762. </el-table-column>
  763. <el-table-column prop="subTotal" label="费用小计" width="180">
  764. <template slot-scope="scope">
  765. <div class="sub-boxs">{{ scope.row.subTotal | numFilter }}</div>&nbsp;CNY
  766. </template>
  767. </el-table-column>
  768. <el-table-column prop="remark" label="备注" width="450">
  769. <template slot-scope="scope">
  770. <el-input size="mini" v-model="scope.row.remark"></el-input>
  771. </template>
  772. </el-table-column>
  773. <el-table-column prop="address" label="操 作">
  774. <template slot-scope="scope">
  775. <el-button v-if="isSave" style="color: #fff;" size="mini" type="danger"
  776. @click="DeleteOtherExpenses(scope.$index, scope.row, otherData)">删除</el-button>
  777. </template>
  778. </el-table-column>
  779. </el-table>
  780. </div>
  781. </div>
  782. <div class="Entry-form-li">
  783. <div class="Entry-li-lables">
  784. <div class="li-lable">费用总计:</div>
  785. <div style="display: flex;">
  786. <div class="li-lable">
  787. <!-- <el-checkbox style="margin-right: -10px;" v-model="airJJC_Checked"></el-checkbox> -->
  788. <label>(经济舱)</label>
  789. <div class="sub-boxs">{{ jjctotal | numFilter }}</div>
  790. <span>元/人</span>
  791. </div>
  792. &nbsp;&nbsp;&nbsp;&nbsp;
  793. <div class="li-lable">
  794. <!-- <el-checkbox style="margin-right: -10px;" v-model="airGWC_Checked"></el-checkbox> -->
  795. <label>(公务舱)</label>
  796. <div class="sub-boxs">{{ gwctotal | numFilter }}</div>
  797. <span>元/人</span>
  798. </div>
  799. &nbsp;&nbsp;&nbsp;&nbsp;
  800. <div class="li-lable">
  801. <!-- <el-checkbox style="margin-right: -10px;" v-model="airGWC_Checked"></el-checkbox> -->
  802. <label>(头等舱)</label>
  803. <div class="sub-boxs">{{ tdctotal | numFilter }}</div>
  804. <span>元/人</span>
  805. </div>
  806. </div>
  807. </div>
  808. </div>
  809. </div>
  810. </div>
  811. </div>
  812. </template>
  813. <script>
  814. import { Decimal } from 'decimal.js'
  815. import { debounce } from '../../store/statice'
  816. import { number } from 'echarts';
  817. export default {
  818. data() {
  819. return {
  820. fullscreenLoading: false,
  821. options: [],
  822. filteredOptions: [],
  823. searchMode: 'character', // 'character': 字符匹配, 'fuzzy': 模糊匹配
  824. listvalue: 1005,
  825. tablevalue: '',
  826. listvalueoptions: [],
  827. tablevalueoptions: [],
  828. //是否计算Checkbox
  829. choiceOne: false,//境内费用(其他费用)选择框
  830. choiceTwo: false,//国际旅费合计选择框
  831. choiceThree: false,//住宿费合计选择框
  832. choiceFour: false,//伙食费合计选择框
  833. choiceFive: false,//公杂费合计选择框
  834. choiceSix: false,//培训费用选择框
  835. choiceSeven: false,//其他费用选择框
  836. sumJJC: false,//经济舱小计选择框
  837. sumGWC: false,//公务舱小计选择框
  838. sumTDC: false,//头等舱小计选择框
  839. airJJC_Checked: false,//经济舱选择框
  840. airGWC_Checked: false,//公务舱选择框
  841. airTDC_Checked: false,//公务舱选择框
  842. isAssignPerm:false,
  843. provinceId:'',
  844. userId: '',
  845. token: '',
  846. value: '',
  847. options: [],
  848. Visafees: '',
  849. Visadepicted: '',
  850. currencys: [],
  851. currencyss: [],
  852. DomesticFees: {
  853. visafees: '',//签证费
  854. visafeesDescription: '',//签证费用描述
  855. vaccinefees: 0,//疫苗费
  856. nucleicfees: 0,//核酸检测费
  857. serviceCharge: 0,//服务费
  858. insurance: 500,//保险费
  859. ticketsExhibitionL: 0,//参展门票
  860. total: 0,
  861. firstItemRemark:''//备注
  862. },
  863. TotalExpenses: {
  864. EconomyClass: 0,//经济舱
  865. BusinessClass: 0,//公务舱
  866. Firstclass: 0,//头等舱
  867. TravellingExpensesJJ: 0,//城市区间交通费JJ
  868. TravellingExpensesGW: 0,//城市区间交通费GW
  869. TravellingExpensesTD: 0,//城市区间交通费TD
  870. EconomyClasstotal: 0,//经济舱合计
  871. BusinessClasstotal: 0,//公务舱合计
  872. Firstclasstotal: 0,//头等舱合计
  873. twoItemRemark:''//备注
  874. },
  875. TotalAccommodationFee: 0,//住宿费合计
  876. TotalMeals: 0,//伙食费合计
  877. TotalMiscellaneous: 0,//公杂费合计
  878. trainingExpense: 0,//培训费合计
  879. otherExpense: 0,//其他费用合计
  880. quarterageData: [],
  881. boardWagesData: [],
  882. miscellaneousFeeData: [],
  883. trainingExpenseData: [],
  884. otherData: [],
  885. placeinif: [],
  886. //下拉框
  887. treeData: "",
  888. treeDataValue: "",
  889. data: [],
  890. defaultProps: {
  891. children: "cityData",
  892. label: "city",
  893. // label: "country",
  894. },
  895. jjctotal: 0,//经济舱合计
  896. gwctotal: 0,//公务舱合计
  897. tdctotal: 0,//公务舱合计
  898. storageid: 0,
  899. visabeizhu: "",
  900. ID: '',
  901. TicketJudgment: {},
  902. CurrencysRemark: '',
  903. //监听币种数组
  904. watchedPrice: null,
  905. cubtn: false,
  906. getvisafeebtn: false,
  907. visainfo: {},
  908. //其他币种
  909. othercurrencys: [],
  910. otherfylx: [],
  911. //设置权限
  912. setpermissions:false,
  913. isSave:false,
  914. isView:false,
  915. viewUsers:[],
  916. viewUsersby:[],
  917. viewUsersarr:[],
  918. //又憋两坨
  919. airDataArr:[],
  920. airDataArrvalue:'',
  921. //实时汇率
  922. liveRateInfos:[],
  923. SSHLVisible:false,
  924. //交通费弹窗
  925. Transportationdata:[
  926. {
  927. coefficient: 2.5,
  928. cost: 0,
  929. currencyName: "CNY",
  930. guideCost: 0,
  931. no: 1,
  932. otherCost: 0,
  933. ovId: '',
  934. quote: 0,
  935. remark: "",
  936. serviceCount: 1
  937. }
  938. ],
  939. Transportationdatatotal:0,
  940. TransportationVisible:false,
  941. currencies:[],
  942. lache:[
  943. {
  944. a:1,
  945. b:"",
  946. c:"",
  947. }
  948. ],
  949. huoche:[
  950. {
  951. a:1,
  952. b:"",
  953. c:"",
  954. }
  955. ],
  956. chengshijipiao:[
  957. {
  958. a:1,
  959. b:"",
  960. c:"",
  961. }
  962. ],
  963. Basicdata:{},
  964. fulecao:[],
  965. pullCartFeeTotal:0,
  966. pullCartFeeDetails:[
  967. {
  968. no: 1,
  969. cost: 0,
  970. coefficient: 2.50,
  971. currencyName: "",
  972. quote: 0,
  973. remark: ""
  974. }
  975. ],
  976. trainFeeTotal:0,
  977. trainFeeDetails:[
  978. {
  979. no: 1,
  980. cost: 0,
  981. coefficient: 2.50,
  982. currencyName: "",
  983. quote: 0,
  984. remark: ""
  985. }
  986. ],
  987. cityAirTicketFeeTotal:0,
  988. cityAirTicketFeeDetails:[
  989. {
  990. no: 1,
  991. cost: 0,
  992. coefficient: 2.50,
  993. currencyName: "",
  994. quote: 0,
  995. remark: ""
  996. }
  997. ],
  998. lastUpdateUserName:'',
  999. lastUpdateTime:'',
  1000. createUserName:'',
  1001. createTime:'',
  1002. }
  1003. },
  1004. methods: {
  1005. advancedFilter(query) {
  1006. if (!query || query.trim() === '') {
  1007. this.filteredOptions = [...this.options];
  1008. return;
  1009. }
  1010. const trimmedQuery = query.trim();
  1011. if (this.searchMode === 'character') {
  1012. // 字符匹配模式:每个字都必须包含
  1013. this.characterMatchFilter(trimmedQuery);
  1014. } else {
  1015. // 模糊匹配模式(默认的filterable行为)
  1016. this.fuzzyMatchFilter(trimmedQuery);
  1017. }
  1018. },
  1019. /*** 严格的字符匹配 - 每个查询字符都必须出现*/
  1020. characterMatchFilter(query) {
  1021. const queryChars = query.split('').filter(char => char.trim() !== '');
  1022. this.filteredOptions = this.options.filter(item => {
  1023. const groupName = item.groupName || '';
  1024. return queryChars.every(char => groupName.includes(char));
  1025. });
  1026. },
  1027. /*** 模糊匹配 - 包含整个查询字符串即可*/
  1028. fuzzyMatchFilter(query) {
  1029. const lowerQuery = query.toLowerCase();
  1030. this.filteredOptions = this.options.filter(item => {
  1031. const groupName = (item.groupName || '').toLowerCase();
  1032. return groupName.includes(lowerQuery);
  1033. });
  1034. },
  1035. //baoliuliangweixiaoshu
  1036. reservetwo(value) {
  1037. // 截取当前数据到小数点后两位
  1038. let realVal = new Decimal(value).toFixed(2)
  1039. return realVal
  1040. },
  1041. //获取团组
  1042. GetEnterExitCostDataSource() {
  1043. var url = "/api/Groups/GetEnterExitCostDataSource"
  1044. var that = this
  1045. this.$axios({
  1046. method: 'post',
  1047. url: url,
  1048. headers: {
  1049. Authorization: 'Bearer ' + this.token
  1050. },
  1051. data: {
  1052. portType: 1
  1053. }
  1054. }).then(function (res) {
  1055. if (res.data.code == 200) {
  1056. that.options = res.data.data.groupNameData;
  1057. that.filteredOptions = that.options;
  1058. that.currencys = res.data.data.currencyInit;
  1059. that.viewUsersarr= res.data.data.viewPermissionData;
  1060. if (that.value == null) {
  1061. that.value = res.data.data.groupNameData[0].id;
  1062. that.provinceId = res.data.data.groupNameData[0].provinceId;
  1063. }
  1064. that.GetEnterExitCostInfobyDiId();
  1065. that.PostGroupTeamRateByDiIdAndCTableId();
  1066. }
  1067. })
  1068. },
  1069. //获取币种
  1070. PostGroupTeamRateByDiIdAndCTableId() {
  1071. this.othercurrencys = [];
  1072. var url = "/api/Business/PostGroupTeamRateByDiIdAndCTableId"
  1073. var that = this
  1074. this.$axios({
  1075. method: 'post',
  1076. url: url,
  1077. headers: {
  1078. Authorization: 'Bearer ' + this.token
  1079. },
  1080. data: {
  1081. portType: 1,
  1082. diId: that.value,
  1083. cTable: 98
  1084. }
  1085. }).then(function (res) {
  1086. if (res.data.code == 200) {
  1087. that.othercurrencys = res.data.data.teamRates;
  1088. for (let sr = 0; sr < that.othercurrencys.length; sr++) {
  1089. if (that.othercurrencys[sr].currencyCode != 'CNY') {
  1090. that.othercurrencys[sr].rate = new Decimal(that.othercurrencys[sr].rate * 1.03).toFixed(4)
  1091. }
  1092. for (let y = 0; y < that.currencys.length; y++) {
  1093. if (that.currencys[y].currencyCode == that.othercurrencys[sr].currencyCode) {
  1094. that.othercurrencys[sr].rate = that.currencys[y].rate;
  1095. }
  1096. }
  1097. }
  1098. } else {
  1099. that.$message.error(res.data.msg);
  1100. }
  1101. })
  1102. },
  1103. //获取类型
  1104. QuerySetData() {
  1105. var url = "/api/System/QuerySetData"
  1106. var that = this
  1107. this.$axios({
  1108. method: 'post',
  1109. url: url,
  1110. headers: {
  1111. Authorization: 'Bearer ' + this.token
  1112. },
  1113. data: {
  1114. dataType: 92
  1115. }
  1116. }).then(function (res) {
  1117. if (res.data.code == 200) {
  1118. that.otherfylx = res.data.data;
  1119. } else {
  1120. that.$message.error(res.data.msg);
  1121. }
  1122. })
  1123. },
  1124. //获取签证标注
  1125. GetEnterExitCostCorrelationTips(val) {
  1126. this.airDataArr=[]
  1127. this.getvisafeebtn = false;
  1128. if (val == 1) {
  1129. // this.TotalExpenses.EconomyClass = 0;
  1130. // this.TotalExpenses.BusinessClass = 0;
  1131. // this.TotalExpenses.Firstclass = 0;
  1132. this.DomesticFees.visafees = 0;
  1133. this.DomesticFees.visafeesDescription = "";
  1134. var url = "/api/Groups/GetEnterExitCostCorrelationTips"
  1135. var that = this
  1136. this.$axios({
  1137. method: 'post',
  1138. url: url,
  1139. headers: {
  1140. Authorization: 'Bearer ' + this.token
  1141. },
  1142. data: {
  1143. portType: 1,
  1144. diId: that.value
  1145. }
  1146. }).then(function (res) {
  1147. if (res.data.code == 200) {
  1148. // that.TotalExpenses.EconomyClass = res.data.data.airData[0].jjcCurrentRate;
  1149. // that.TotalExpenses.BusinessClass = res.data.data.airData[0].gwcCurrentRate;
  1150. // that.TotalExpenses.Firstclass = res.data.data.airData[0].tdcCurrentRate;
  1151. that.airDataArr=res.data.data.airData;
  1152. that.DomesticFees.visafees = res.data.data.visaData.feeTotal;
  1153. that.DomesticFees.visafeesDescription = res.data.data.visaData.remark;
  1154. } else {
  1155. that.$message.error(res.data.msg);
  1156. }
  1157. })
  1158. } else {
  1159. var url = "/api/Groups/GetEnterExitCostCorrelationTips"
  1160. var that = this
  1161. this.$axios({
  1162. method: 'post',
  1163. url: url,
  1164. headers: {
  1165. Authorization: 'Bearer ' + this.token
  1166. },
  1167. data: {
  1168. portType: 1,
  1169. diId: that.value
  1170. }
  1171. }).then(function (res) {
  1172. if (res.data.code == 200) {
  1173. that.TicketJudgment = res.data.data.airData;
  1174. that.airDataArr=res.data.data.airData;
  1175. // if (that.TotalExpenses.EconomyClass==0) {
  1176. // that.TotalExpenses.EconomyClass = that.airDataArr[0].jjcCurrentRate;
  1177. // }
  1178. // if (that.TotalExpenses.BusinessClass==0) {
  1179. // that.TotalExpenses.BusinessClass = that.airDataArr[0].gwcCurrentRate;
  1180. // }
  1181. // if (that.TotalExpenses.Firstclass==0) {
  1182. // that.TotalExpenses.Firstclass = that.airDataArr[0].tdcCurrentRate;
  1183. // }
  1184. that.visainfo = res.data.data.visaData;
  1185. that.currencyss = res.data.data.reteInfos;
  1186. that.SSHLVisible=true;
  1187. if (that.DomesticFees.visafees != res.data.data.visaData.feeTotal && res.data.data.visaData.feeTotal != 0) {
  1188. that.getvisafeebtn = true;
  1189. }
  1190. for (let s = 0; s < that.currencys.length; s++) {
  1191. if (that.currencys[s].rate != that.currencyss[s].rate) {
  1192. that.cubtn = true;
  1193. that.CurrencysRemark = '移上查看实时汇率'
  1194. return
  1195. } else {
  1196. that.cubtn = false;
  1197. }
  1198. }
  1199. } else {
  1200. that.$message.error(res.data.msg);
  1201. }
  1202. })
  1203. }
  1204. },
  1205. //机票费用填入
  1206. Fillin(val) {
  1207. var obj = {}
  1208. obj = this.airDataArr.find(function (i,indexs) {
  1209. return i.remark === val
  1210. });
  1211. this.TotalExpenses.EconomyClass = obj.jjcCurrentRate;
  1212. this.TotalExpenses.BusinessClass = obj.gwcCurrentRate;
  1213. this.TotalExpenses.Firstclass = obj.tdcCurrentRate;
  1214. //添加城市交通费
  1215. },
  1216. //获取文件
  1217. EnterExitCostFileOwner() {
  1218. this.listvalueoptions=[];
  1219. this.tablevalueoptions=[];
  1220. var url = "/api/Groups/EnterExitCostFileOwner/"+this.provinceId
  1221. var that = this
  1222. this.$axios({
  1223. method: 'get',
  1224. url: url,
  1225. }).then(function (res) {
  1226. if (res.data.code == 200) {
  1227. that.listvalueoptions = res.data.data.wordTypeData;
  1228. that.tablevalueoptions = res.data.data.excelTypeData;
  1229. }else {
  1230. that.$message.error(res.data.msg);
  1231. }
  1232. })
  1233. },
  1234. //获取费用标注
  1235. GetNationalTravelFeeData() {
  1236. var url = "/api/Groups/GetNationalTravelFeeData"
  1237. var that = this
  1238. this.$axios({
  1239. method: 'post',
  1240. url: url,
  1241. headers: {
  1242. Authorization: 'Bearer ' + this.token
  1243. },
  1244. data: {
  1245. portType: 1,
  1246. provinceId:that.provinceId,
  1247. }
  1248. }).then(function (res) {
  1249. let placeinifarr = [];
  1250. that.placeinif=[];
  1251. if (res.data.code == 200) {
  1252. for (let i = 0; i < res.data.data.length; i++) {
  1253. res.data.data[i]['cityname'] = res.data.data[i].country + '-' + res.data.data[i].city;
  1254. placeinifarr.push(res.data.data[i]);
  1255. }
  1256. that.placeinif = placeinifarr;
  1257. console.log(that.placeinif);
  1258. }
  1259. })
  1260. },
  1261. GetEnterExitCostInfobyDiId() {
  1262. //初始化数据
  1263. this.ID = '';
  1264. // this.currencys=[]
  1265. this.viewUsers=[];
  1266. this.viewUsersby=[];
  1267. this.TotalAccommodationFee = 0;//住宿费合计
  1268. this.TotalMeals = 0;//伙食费合计
  1269. this.TotalMiscellaneous = 0;//公杂费合计
  1270. this.trainingExpense = 0;//培训费合计
  1271. this.otherExpense = 0;//其他费合计
  1272. this.DomesticFees = {
  1273. visafees: '',//签证费
  1274. visafeesDescription: '',//签证费用描述
  1275. vaccinefees: 0,//疫苗费
  1276. nucleicfees: 0,//核酸检测费
  1277. serviceCharge: 0,//服务费
  1278. insurance: 500,//保险费
  1279. ticketsExhibitionL: 0,//参展门票
  1280. total: 0,
  1281. firstItemRemark:''//备注
  1282. }
  1283. this.TotalExpenses = {
  1284. EconomyClass: 0,//经济舱
  1285. BusinessClass: 0,//公务舱
  1286. Firstclass: 0,//TD舱
  1287. TravellingExpensesJJ: 0,//城市区间交通费JJ
  1288. TravellingExpensesGW: 0,//城市区间交通费GW
  1289. TravellingExpensesTD: 0,//城市区间交通费TD
  1290. EconomyClasstotal: 0,//经济舱合计
  1291. BusinessClasstotal: 0,//公务舱合计
  1292. Firstclasstotal: 0,//TD舱合计
  1293. twoItemRemark:''//备注
  1294. }
  1295. this.choiceOne = false//境内费用(其他费用)选择框
  1296. this.choiceTwo = false//国际旅费合计选择框
  1297. this.choiceThree = false//住宿费合计选择框
  1298. this.choiceFour = false//伙食费合计选择框
  1299. this.choiceFive = false//公杂费合计选择框
  1300. this.choiceSix = false//培训费用选择框
  1301. this.choiceSeven = false//其他费用选择框
  1302. this.sumJJC = false//经济舱小计选择框
  1303. this.sumGWC = false//公务舱小计选择框
  1304. this.sumTDC = false//公务舱小计选择框
  1305. this.airJJC_Checked = false//经济舱选择框
  1306. this.airGWC_Checked = false//公务舱选择框
  1307. this.isSave = false//保存权限
  1308. this.isView = false//查看权限
  1309. this.storageid = 0
  1310. this.quarterageData = [
  1311. {
  1312. id: 0,
  1313. diId: this.value,
  1314. type: 1,
  1315. days: 1,
  1316. nationalTravelFeeId: '',
  1317. cost: 0,
  1318. currency: 0,
  1319. subTotal: 0,
  1320. remark: '',
  1321. },
  1322. {
  1323. id: 0,
  1324. diId: this.value,
  1325. type: 1,
  1326. days: 2,
  1327. nationalTravelFeeId: '',
  1328. cost: 0,
  1329. currency: 0,
  1330. subTotal: 0,
  1331. remark: '',
  1332. },
  1333. {
  1334. id: 0,
  1335. diId: this.value,
  1336. type: 1,
  1337. days: 3,
  1338. nationalTravelFeeId: '',
  1339. cost: 0,
  1340. currency: 0,
  1341. subTotal: 0,
  1342. remark: '',
  1343. },
  1344. {
  1345. id: 0,
  1346. diId: this.value,
  1347. type: 1,
  1348. days: 4,
  1349. nationalTravelFeeId: '',
  1350. cost: 0,
  1351. currency: 0,
  1352. subTotal: 0,
  1353. remark: '',
  1354. },
  1355. {
  1356. id: 0,
  1357. diId: this.value,
  1358. type: 1,
  1359. days: 5,
  1360. nationalTravelFeeId: '',
  1361. cost: 0,
  1362. currency: 0,
  1363. subTotal: 0,
  1364. remark: '',
  1365. },
  1366. {
  1367. id: 0,
  1368. diId: this.value,
  1369. type: 1,
  1370. days: 6,
  1371. nationalTravelFeeId: '',
  1372. cost: 0,
  1373. currency: 0,
  1374. subTotal: 0,
  1375. remark: '',
  1376. },
  1377. {
  1378. id: 0,
  1379. diId: this.value,
  1380. type: 1,
  1381. days: 7,
  1382. nationalTravelFeeId: '',
  1383. cost: 0,
  1384. currency: 0,
  1385. subTotal: 0,
  1386. remark: '',
  1387. },
  1388. {
  1389. id: 0,
  1390. diId: this.value,
  1391. type: 1,
  1392. days: 8,
  1393. nationalTravelFeeId: '',
  1394. cost: 0,
  1395. currency: 0,
  1396. subTotal: 0,
  1397. remark: '',
  1398. },
  1399. ]
  1400. this.boardWagesData = [
  1401. {
  1402. id: 0,
  1403. diId: this.value,
  1404. type: 2,
  1405. days: 1,
  1406. nationalTravelFeeId: '',
  1407. cost: 0,
  1408. currency: 0,
  1409. subTotal: 0,
  1410. remark: '',
  1411. },
  1412. {
  1413. id: 0,
  1414. diId: this.value,
  1415. type: 2,
  1416. days: 2,
  1417. nationalTravelFeeId: '',
  1418. cost: 0,
  1419. currency: 0,
  1420. subTotal: 0,
  1421. remark: '',
  1422. },
  1423. {
  1424. id: 0,
  1425. diId: this.value,
  1426. type: 2,
  1427. days: 3,
  1428. nationalTravelFeeId: '',
  1429. cost: 0,
  1430. currency: 0,
  1431. subTotal: 0,
  1432. remark: '',
  1433. },
  1434. {
  1435. id: 0,
  1436. diId: this.value,
  1437. type: 2,
  1438. days: 4,
  1439. nationalTravelFeeId: '',
  1440. cost: 0,
  1441. currency: 0,
  1442. subTotal: 0,
  1443. remark: '',
  1444. },
  1445. {
  1446. id: 0,
  1447. diId: this.value,
  1448. type: 2,
  1449. days: 5,
  1450. nationalTravelFeeId: '',
  1451. cost: 0,
  1452. currency: 0,
  1453. subTotal: 0,
  1454. remark: '',
  1455. },
  1456. {
  1457. id: 0,
  1458. diId: this.value,
  1459. type: 2,
  1460. days: 6,
  1461. nationalTravelFeeId: '',
  1462. cost: 0,
  1463. currency: 0,
  1464. subTotal: 0,
  1465. remark: '',
  1466. },
  1467. {
  1468. id: 0,
  1469. diId: this.value,
  1470. type: 2,
  1471. days: 7,
  1472. nationalTravelFeeId: '',
  1473. cost: 0,
  1474. currency: 0,
  1475. subTotal: 0,
  1476. remark: '',
  1477. },
  1478. {
  1479. id: 0,
  1480. diId: this.value,
  1481. type: 2,
  1482. days: 8,
  1483. nationalTravelFeeId: '',
  1484. cost: 0,
  1485. currency: 0,
  1486. subTotal: 0,
  1487. remark: '',
  1488. },
  1489. ]
  1490. this.miscellaneousFeeData = [
  1491. {
  1492. id: 0,
  1493. diId: this.value,
  1494. type: 3,
  1495. days: 1,
  1496. nationalTravelFeeId: '',
  1497. cost: 0,
  1498. currency: 0,
  1499. subTotal: 0,
  1500. remark: '',
  1501. },
  1502. {
  1503. id: 0,
  1504. diId: this.value,
  1505. type: 3,
  1506. days: 2,
  1507. nationalTravelFeeId: '',
  1508. cost: 0,
  1509. currency: 0,
  1510. subTotal: 0,
  1511. remark: '',
  1512. },
  1513. {
  1514. id: 0,
  1515. diId: this.value,
  1516. type: 3,
  1517. days: 3,
  1518. nationalTravelFeeId: '',
  1519. cost: 0,
  1520. currency: 0,
  1521. subTotal: 0,
  1522. remark: '',
  1523. },
  1524. {
  1525. id: 0,
  1526. diId: this.value,
  1527. type: 3,
  1528. days: 4,
  1529. nationalTravelFeeId: '',
  1530. cost: 0,
  1531. currency: 0,
  1532. subTotal: 0,
  1533. remark: '',
  1534. },
  1535. {
  1536. id: 0,
  1537. diId: this.value,
  1538. type: 3,
  1539. days: 5,
  1540. nationalTravelFeeId: '',
  1541. cost: 0,
  1542. currency: 0,
  1543. subTotal: 0,
  1544. remark: '',
  1545. },
  1546. {
  1547. id: 0,
  1548. diId: this.value,
  1549. type: 3,
  1550. days: 6,
  1551. nationalTravelFeeId: '',
  1552. cost: 0,
  1553. currency: 0,
  1554. subTotal: 0,
  1555. remark: '',
  1556. },
  1557. {
  1558. id: 0,
  1559. diId: this.value,
  1560. type: 3,
  1561. days: 7,
  1562. nationalTravelFeeId: '',
  1563. cost: 0,
  1564. currency: 0,
  1565. subTotal: 0,
  1566. remark: '',
  1567. },
  1568. {
  1569. id: 0,
  1570. diId: this.value,
  1571. type: 3,
  1572. days: 8,
  1573. nationalTravelFeeId: '',
  1574. cost: 0,
  1575. currency: 0,
  1576. subTotal: 0,
  1577. remark: '',
  1578. },
  1579. ]
  1580. this.trainingExpenseData = [
  1581. {
  1582. id: 0,
  1583. diId: this.value,
  1584. type: 4,
  1585. days: 1,
  1586. nationalTravelFeeId: '',
  1587. cost: 0,
  1588. currency: 0,
  1589. subTotal: 0,
  1590. remark: '',
  1591. },
  1592. {
  1593. id: 0,
  1594. diId: this.value,
  1595. type: 4,
  1596. days: 2,
  1597. nationalTravelFeeId: '',
  1598. cost: 0,
  1599. currency: 0,
  1600. subTotal: 0,
  1601. remark: '',
  1602. },
  1603. {
  1604. id: 0,
  1605. diId: this.value,
  1606. type: 4,
  1607. days: 3,
  1608. nationalTravelFeeId: '',
  1609. cost: 0,
  1610. currency: 0,
  1611. subTotal: 0,
  1612. remark: '',
  1613. },
  1614. {
  1615. id: 0,
  1616. diId: this.value,
  1617. type: 4,
  1618. days: 4,
  1619. nationalTravelFeeId: '',
  1620. cost: 0,
  1621. currency: 0,
  1622. subTotal: 0,
  1623. remark: '',
  1624. },
  1625. {
  1626. id: 0,
  1627. diId: this.value,
  1628. type: 4,
  1629. days: 5,
  1630. nationalTravelFeeId: '',
  1631. cost: 0,
  1632. currency: 0,
  1633. subTotal: 0,
  1634. remark: '',
  1635. },
  1636. {
  1637. id: 0,
  1638. diId: this.value,
  1639. type: 4,
  1640. days: 6,
  1641. nationalTravelFeeId: '',
  1642. cost: 0,
  1643. currency: 0,
  1644. subTotal: 0,
  1645. remark: '',
  1646. },
  1647. {
  1648. id: 0,
  1649. diId: this.value,
  1650. type: 4,
  1651. days: 7,
  1652. nationalTravelFeeId: '',
  1653. cost: 0,
  1654. currency: 0,
  1655. subTotal: 0,
  1656. remark: '',
  1657. },
  1658. {
  1659. id: 0,
  1660. diId: this.value,
  1661. type: 4,
  1662. days: 8,
  1663. nationalTravelFeeId: '',
  1664. cost: 0,
  1665. currency: 0,
  1666. subTotal: 0,
  1667. remark: '',
  1668. },
  1669. ]
  1670. this.otherData = [
  1671. {
  1672. id: 0,
  1673. diId: this.value,
  1674. setDataId: '',
  1675. index: 1,
  1676. cost: '',
  1677. cost: 0,
  1678. currency: '',
  1679. subTotal: 0,
  1680. remark:'',
  1681. },
  1682. {
  1683. id: 0,
  1684. diId: this.value,
  1685. setDataId: '',
  1686. index: 2,
  1687. cost: '',
  1688. cost: 0,
  1689. currency: '',
  1690. subTotal: 0,
  1691. remark:'',
  1692. },
  1693. {
  1694. id: 0,
  1695. diId: this.value,
  1696. setDataId: '',
  1697. index: 3,
  1698. cost: '',
  1699. cost: 0,
  1700. currency: '',
  1701. subTotal: 0,
  1702. remark:'',
  1703. },
  1704. {
  1705. id: 0,
  1706. diId: this.value,
  1707. setDataId: '',
  1708. index: 4,
  1709. cost: '',
  1710. cost: 0,
  1711. currency: '',
  1712. subTotal: 0,
  1713. remark:'',
  1714. },
  1715. {
  1716. id: 0,
  1717. diId: this.value,
  1718. setDataId: '',
  1719. index: 5,
  1720. cost: '',
  1721. cost: 0,
  1722. currency: '',
  1723. subTotal: 0,
  1724. remark:'',
  1725. },
  1726. {
  1727. id: 0,
  1728. diId: this.value,
  1729. setDataId: '',
  1730. index: 6,
  1731. cost: '',
  1732. cost: 0,
  1733. currency: '',
  1734. subTotal: 0,
  1735. remark:'',
  1736. },
  1737. {
  1738. id: 0,
  1739. diId: this.value,
  1740. setDataId: '',
  1741. index: 7,
  1742. cost: '',
  1743. cost: 0,
  1744. currency: '',
  1745. subTotal: 0,
  1746. remark:'',
  1747. },
  1748. {
  1749. id: 0,
  1750. diId: this.value,
  1751. setDataId: '',
  1752. index: 8,
  1753. cost: '',
  1754. cost: 0,
  1755. currency: '',
  1756. subTotal: 0,
  1757. remark:'',
  1758. },
  1759. ]
  1760. this.isAssignPerm=false;
  1761. var url = "/api/Groups/GetEnterExitCostInfobyDiId"
  1762. var that = this
  1763. this.$axios({
  1764. method: 'post',
  1765. url: url,
  1766. headers: {
  1767. Authorization: 'Bearer ' + this.token
  1768. },
  1769. data: {
  1770. portType: 1,
  1771. diId: that.value,
  1772. currUserId:that.userId
  1773. }
  1774. }).then(function (res) {
  1775. if (res.data.code == 200) {
  1776. that.ID = res.data.data.id;
  1777. that.provinceId=res.data.data.provinceId;
  1778. //汇率
  1779. that.currencys = res.data.data.currencys;
  1780. that.isAssignPerm=res.data.data.isAssignPerm;
  1781. //权限
  1782. that.isSave=res.data.data.isSave;
  1783. that.isView=res.data.data.isView;
  1784. that.viewUsers=res.data.data.viewUsers;
  1785. that.viewUsersby=res.data.data.viewUsers;
  1786. //境内费用
  1787. that.DomesticFees.visafees = res.data.data.visa;
  1788. that.DomesticFees.visafeesDescription = res.data.data.visaRemark;
  1789. that.DomesticFees.vaccinefees = res.data.data.yiMiao;
  1790. that.DomesticFees.nucleicfees = res.data.data.heSuan;
  1791. that.DomesticFees.serviceCharge = res.data.data.service;
  1792. that.DomesticFees.insurance = res.data.data.safe;
  1793. that.DomesticFees.ticketsExhibitionL = res.data.data.ticket;
  1794. that.DomesticFees.firstItemRemark = res.data.data.firstItemRemark;
  1795. //国际旅费
  1796. that.TotalExpenses.EconomyClass = res.data.data.airJJ;
  1797. that.TotalExpenses.BusinessClass = res.data.data.airGW;
  1798. that.TotalExpenses.Firstclass = res.data.data.airTD;
  1799. that.TotalExpenses.TravellingExpensesJJ = res.data.data.cityTranffic;
  1800. that.TotalExpenses.TravellingExpensesGW = res.data.data.cityTranffic1;
  1801. that.TotalExpenses.TravellingExpensesTD = res.data.data.cityTranffic2;
  1802. that.TotalExpenses.twoItemRemark = res.data.data.twoItemRemark;
  1803. //是否计算Checkbox
  1804. that.choiceOne = res.data.data.choiceOne == 1 ? true : false;
  1805. that.choiceTwo = res.data.data.choiceTwo == 1 ? true : false;
  1806. that.choiceThree = res.data.data.choiceThree == 1 ? true : false;
  1807. that.choiceFour = res.data.data.choiceFour == 1 ? true : false;
  1808. that.choiceFive = res.data.data.choiceFive == 1 ? true : false;
  1809. that.choiceSix = res.data.data.choiceSix == 1 ? true : false;
  1810. that.choiceSeven = res.data.data.otherExpenses_Checked == 1 ? true : false;
  1811. that.sumJJC = res.data.data.sumJJC == 1 ? true : false;
  1812. that.sumGWC = res.data.data.sumGWC == 1 ? true : false;
  1813. that.sumTDC = res.data.data.sumTDC == 1 ? true : false;
  1814. that.airJJC_Checked = res.data.data.airJJC_Checked == 1 ? true : false;
  1815. that.airGWC_Checked = res.data.data.airGWC_Checked == 1 ? true : false;
  1816. //住宿费
  1817. that.quarterageData = res.data.data.quarterageData;
  1818. for (let a = 0; a < res.data.data.quarterageData.length; a++) {
  1819. that.TotalAccommodationFee += Number(res.data.data.quarterageData[a].subTotal)
  1820. }
  1821. //伙食费
  1822. that.boardWagesData = res.data.data.boardWagesData;
  1823. for (let b = 0; b < res.data.data.boardWagesData.length; b++) {
  1824. that.TotalMeals += res.data.data.boardWagesData[b].subTotal
  1825. }
  1826. //公杂费
  1827. that.miscellaneousFeeData = res.data.data.miscellaneousFeeData;
  1828. for (let c = 0; c < res.data.data.miscellaneousFeeData.length; c++) {
  1829. that.TotalMiscellaneous += res.data.data.miscellaneousFeeData[c].subTotal
  1830. }
  1831. //培训费
  1832. that.trainingExpenseData = res.data.data.trainingExpenseData;
  1833. for (let d = 0; d < res.data.data.trainingExpenseData.length; d++) {
  1834. that.trainingExpense += res.data.data.trainingExpenseData[d].subTotal
  1835. }
  1836. //其他费
  1837. that.otherData = res.data.data.dayOtherPriceData;
  1838. for (let e = 0; e < res.data.data.dayOtherPriceData.length; e++) {
  1839. that.otherExpense += res.data.data.dayOtherPriceData[e].subTotal
  1840. }
  1841. that.storageid = res.data.data.id;
  1842. // that.GetNationalTravelFeeData();
  1843. that.fullscreenLoading = false;
  1844. that.GetEnterExitCostCorrelationTips(2)
  1845. that.EnterExitCostFileOwner();
  1846. that.GetNationalTravelFeeData();
  1847. } else {
  1848. that.fullscreenLoading = false;
  1849. that.provinceId=res.data.data.provinceId;
  1850. // that.EnterExitCostFileOwner();
  1851. that.GetNationalTravelFeeData();
  1852. that.GetEnterExitCostCorrelationTips(1);
  1853. that.$message.warning(res.data.msg);
  1854. if (res.data.msg=='未查询出数据!可操作该条数据!') {
  1855. that.isSave=true;
  1856. that.isView=true;
  1857. }
  1858. }
  1859. })
  1860. },
  1861. //全部清空
  1862. cleanout() {
  1863. this.fullscreenLoading = true
  1864. this.$confirm('此操作将全部清空, 是否继续?', '提示', {
  1865. confirmButtonText: '确定',
  1866. cancelButtonText: '取消',
  1867. type: 'warning'
  1868. }).then(() => {
  1869. var url = "/api/Groups/PostEnterExitCostOneClickClear"
  1870. var that = this
  1871. this.$axios({
  1872. method: 'post',
  1873. url: url,
  1874. headers: {
  1875. Authorization: 'Bearer ' + this.token
  1876. },
  1877. data: {
  1878. portType: 1,
  1879. diId: that.value,
  1880. userId: that.userId,
  1881. id: that.ID
  1882. }
  1883. }).then(function (res) {
  1884. if (res.data.code == 200) {
  1885. that.$message({
  1886. type: 'success',
  1887. message: res.data.msg
  1888. });
  1889. that.GetEnterExitCostInfobyDiId()
  1890. } else {
  1891. that.fullscreenLoading = false;
  1892. that.$message.error(res.data.msg);
  1893. }
  1894. })
  1895. }).catch(() => {
  1896. this.fullscreenLoading = false;
  1897. this.$message({
  1898. type: 'info',
  1899. message: '已取消清空'
  1900. });
  1901. });
  1902. },
  1903. //下拉
  1904. handNodeClick(data, node, e) {
  1905. this.treeDataValue = data.name
  1906. this.treeData = data.name
  1907. },
  1908. //sr需求
  1909. SRrequirement(obj) {
  1910. var currencyinfo = {}
  1911. var rate = 0
  1912. currencyinfo = this.othercurrencys.find(function (i) {
  1913. return i.currencyId === obj.currency
  1914. });
  1915. console.log(this.othercurrencys);
  1916. rate = currencyinfo.rate;
  1917. this.otherExpense = 0;
  1918. for (let l = 0; l < this.otherData.length; l++) {
  1919. this.otherData[l].currency = obj.currency
  1920. this.otherData[l].subTotal = Number(this.otherData[l].cost) * Number(rate);
  1921. this.otherExpense += this.otherData[l].subTotal;
  1922. }
  1923. },
  1924. //住宿地区选择
  1925. changeSelect(val, item, index) {
  1926. var xiabiao=0
  1927. var rate = 0
  1928. var obj = {}
  1929. obj = this.placeinif.find(function (i,indexs) {
  1930. xiabiao=indexs
  1931. return i.id === item
  1932. });
  1933. this.placeinif.splice(xiabiao,1);
  1934. this.placeinif.unshift(obj);
  1935. this.SRrequirement(obj)
  1936. //在change中获取到整条对象数据
  1937. val.currencyName = obj.currencyName;
  1938. val.currency = obj.currency;
  1939. val.cost = obj.roomCost;
  1940. for (let j = 0; j < this.currencys.length; j++) {
  1941. if (this.currencys[j].currencyCode == obj.currencyCode) {
  1942. rate = this.currencys[j].rate;
  1943. }
  1944. }
  1945. val.subTotal = Number(val.cost) * Number(rate);
  1946. this.TotalAccommodationFee = 0;
  1947. for (let a = 0; a < this.quarterageData.length; a++) {
  1948. this.TotalAccommodationFee += Number(new Decimal(this.quarterageData[a].subTotal).toFixed(2));
  1949. }
  1950. // this.mealschangeSelect(this.boardWagesData,item,index)
  1951. },
  1952. //住宿费费用标准值改变
  1953. zhusuinput(val) {
  1954. var rate = 0
  1955. for (let j = 0; j < this.currencys.length; j++) {
  1956. if (this.currencys[j].currencyName == val.currencyName) {
  1957. rate = this.currencys[j].rate;
  1958. }
  1959. }
  1960. val.subTotal = Number(val.cost) * Number(rate);
  1961. this.TotalAccommodationFee = 0;
  1962. for (let a = 0; a < this.quarterageData.length; a++) {
  1963. this.TotalAccommodationFee += Number(new Decimal(this.quarterageData[a].subTotal).toFixed(2));
  1964. }
  1965. },
  1966. //伙食费费用标准值改变
  1967. mealsinput(val) {
  1968. var rate = 0
  1969. for (let j = 0; j < this.currencys.length; j++) {
  1970. if (this.currencys[j].currencyName == val.currencyName) {
  1971. rate = this.currencys[j].rate;
  1972. }
  1973. }
  1974. val.subTotal = Number(val.cost) * Number(rate);
  1975. this.TotalMeals = 0;
  1976. for (let a = 0; a < this.boardWagesData.length; a++) {
  1977. // this.TotalMeals += this.boardWagesData[a].subTotal
  1978. this.TotalMeals += Number(new Decimal(this.boardWagesData[a].subTotal).toFixed(2));
  1979. }
  1980. },
  1981. //伙食地区选择
  1982. mealschangeSelect(val, item, index) {
  1983. var xiabiao=0
  1984. var rate = 0
  1985. var obj = {}
  1986. obj = this.placeinif.find(function (i,indexs) {
  1987. xiabiao=indexs
  1988. return i.id === item
  1989. });
  1990. this.placeinif.splice(xiabiao,1);
  1991. this.placeinif.unshift(obj);
  1992. //在change中获取到整条对象数据
  1993. // if(index!=undefined){
  1994. // val[index].currencyName=obj.currencyName;
  1995. // val[index].currency=obj.currency;
  1996. // val[index].cost=obj.foodCost;
  1997. // val[index].nationalTravelFeeId=obj.id;
  1998. // for(let j=0;j<this.currencys.length;j++){
  1999. // if(this.currencys[j].currencyCode==obj.currencyCode){
  2000. // rate=this.currencys[j].rate;
  2001. // }
  2002. // }
  2003. // val[index].subTotal=Number(val[index].cost)*Number(rate);
  2004. // this.TotalMeals=0;
  2005. // for(let a=0;a<this.boardWagesData.length;a++){
  2006. // this.TotalMeals+=this.boardWagesData[a].subTotal
  2007. // }
  2008. // }
  2009. val.currencyName = obj.currencyName;
  2010. val.currency = obj.currency;
  2011. val.cost = obj.foodCost;
  2012. for (let j = 0; j < this.currencys.length; j++) {
  2013. if (this.currencys[j].currencyCode == obj.currencyCode) {
  2014. rate = this.currencys[j].rate;
  2015. }
  2016. }
  2017. val.subTotal = Number(val.cost) * Number(rate);
  2018. this.TotalMeals = 0;
  2019. for (let a = 0; a < this.boardWagesData.length; a++) {
  2020. this.TotalMeals += this.boardWagesData[a].subTotal
  2021. }
  2022. this.MiscellaneouschangeSelect(this.miscellaneousFeeData, item, index)
  2023. },
  2024. //公杂费费用标准值改变
  2025. Miscellaneousinput(val) {
  2026. var rate = 0
  2027. for (let j = 0; j < this.currencys.length; j++) {
  2028. if (this.currencys[j].currencyName == val.currencyName) {
  2029. rate = this.currencys[j].rate;
  2030. }
  2031. }
  2032. val.subTotal = Number(val.cost) * Number(rate);
  2033. this.TotalMiscellaneous = 0;
  2034. for (let a = 0; a < this.miscellaneousFeeData.length; a++) {
  2035. // this.TotalMiscellaneous += this.miscellaneousFeeData[a].subTotal
  2036. this.TotalMiscellaneous += Number(new Decimal(this.miscellaneousFeeData[a].subTotal).toFixed(2));
  2037. }
  2038. },
  2039. //公杂费地区选择
  2040. MiscellaneouschangeSelect(val, item, index) {
  2041. var xiabiao=0
  2042. var rate = 0
  2043. var obj = {}
  2044. obj = this.placeinif.find(function (i,indexs) {
  2045. xiabiao=indexs
  2046. return i.id === item
  2047. });
  2048. this.placeinif.splice(xiabiao,1);
  2049. this.placeinif.unshift(obj);
  2050. //在change中获取到整条对象数据
  2051. if (index != undefined) {
  2052. val[index].currencyName = obj.currencyName;
  2053. val[index].currency = obj.currency;
  2054. val[index].cost = obj.publicCost;
  2055. val[index].nationalTravelFeeId = obj.id;
  2056. for (let j = 0; j < this.currencys.length; j++) {
  2057. if (this.currencys[j].currencyCode == obj.currencyCode) {
  2058. rate = this.currencys[j].rate;
  2059. }
  2060. }
  2061. val[index].subTotal = Number(val[index].cost) * Number(rate);
  2062. this.TotalMiscellaneous = 0;
  2063. for (let a = 0; a < this.miscellaneousFeeData.length; a++) {
  2064. this.TotalMiscellaneous += this.miscellaneousFeeData[a].subTotal
  2065. }
  2066. }
  2067. val.currencyName = obj.currencyName;
  2068. val.currency = obj.currency;
  2069. val.cost = obj.publicCost;
  2070. for (let j = 0; j < this.currencys.length; j++) {
  2071. if (this.currencys[j].currencyCode == obj.currencyCode) {
  2072. rate = this.currencys[j].rate;
  2073. }
  2074. }
  2075. val.subTotal = Number(val.cost) * Number(rate);
  2076. this.TotalMiscellaneous = 0;
  2077. for (let a = 0; a < this.miscellaneousFeeData.length; a++) {
  2078. this.TotalMiscellaneous += this.miscellaneousFeeData[a].subTotal
  2079. }
  2080. },
  2081. //培训费费用标准值改变
  2082. Traininginput(val) {
  2083. var rate = 0
  2084. for (let j = 0; j < this.currencys.length; j++) {
  2085. if (this.currencys[j].currencyName == val.currencyName) {
  2086. rate = this.currencys[j].rate;
  2087. }
  2088. }
  2089. val.subTotal = Number(val.cost) * Number(rate);
  2090. this.trainingExpense = 0;
  2091. for (let a = 0; a < this.trainingExpenseData.length; a++) {
  2092. // this.trainingExpense += this.trainingExpenseData[a].subTotal
  2093. this.trainingExpense += Number(new Decimal(this.trainingExpenseData[a].subTotal).toFixed(2));
  2094. }
  2095. },
  2096. //培训费地区选择
  2097. TrainingExpenseDataSelect(val, item,index) {
  2098. var xiabiao=0
  2099. var rate = 0//汇率
  2100. var obj = {}
  2101. obj = this.placeinif.find(function (i,indexs) {
  2102. xiabiao=indexs
  2103. return i.id === item
  2104. });
  2105. this.placeinif.splice(xiabiao,1);
  2106. this.placeinif.unshift(obj);
  2107. //在change中获取到整条对象数据
  2108. // if (index != undefined) {
  2109. // val[index].currencyName = obj.currencyName;
  2110. // val[index].currency = obj.currency;
  2111. // val[index].cost = obj.trainCost;
  2112. // val[index].nationalTravelFeeId = obj.id;
  2113. // for (let j = 0; j < this.currencys.length; j++) {
  2114. // if (this.currencys[j].currencyCode == obj.currencyCode) {
  2115. // rate = this.currencys[j].rate;
  2116. // }
  2117. // }
  2118. // val[index].subTotal = Number(val[index].cost) * Number(rate);
  2119. // this.trainingExpense=0;
  2120. // for (let a = 0; a < this.trainingExpenseData.length; a++) {
  2121. // this.trainingExpense += this.trainingExpenseData[a].subTotal
  2122. // }
  2123. // }
  2124. val.currencyName = obj.currencyName;
  2125. val.currency = obj.currency;
  2126. val.cost=obj.trainCost;
  2127. for (let j = 0; j < this.currencys.length; j++) {
  2128. if (this.currencys[j].currencyCode == obj.currencyCode) {
  2129. rate = this.currencys[j].rate;
  2130. }
  2131. }
  2132. val.subTotal = Number(val.cost) * Number(rate);
  2133. this.trainingExpense=0;
  2134. for (let a = 0; a < this.trainingExpenseData.length; a++) {
  2135. this.trainingExpense += this.trainingExpenseData[a].subTotal
  2136. }
  2137. },
  2138. //其他币种值改变
  2139. othercurrencychange(val, row) {
  2140. var obj = {};
  2141. var rate = 0;
  2142. obj = this.othercurrencys.find(function (i) {
  2143. return i.currencyId === val;
  2144. });
  2145. rate = obj.rate
  2146. row.subTotal = Number(row.cost) * Number(rate);
  2147. this.otherExpense = 0;
  2148. for (let a = 0; a < this.otherData.length; a++) {
  2149. this.otherExpense += this.otherData[a].subTotal;
  2150. }
  2151. },
  2152. //其他费用标准值改变
  2153. otherinput(val) {
  2154. if (val.currency == '' || this.othercurrencys == '') {
  2155. return
  2156. }
  2157. var obj = {}
  2158. var rate = 0
  2159. obj = this.othercurrencys.find(function (i) {
  2160. return i.currencyId === val.currency
  2161. });
  2162. rate = obj.rate
  2163. val.subTotal = Number(val.cost) * Number(rate);
  2164. this.otherExpense = 0;
  2165. for (let a = 0; a < this.otherData.length; a++) {
  2166. // this.otherExpense += this.otherData[a].subTotal
  2167. this.otherExpense += Number(new Decimal(this.otherData[a].subTotal).toFixed(2));
  2168. }
  2169. },
  2170. //新增list
  2171. addlist(text) {
  2172. if (text == "住宿费") {
  2173. this.quarterageData.push({
  2174. id: 0,
  2175. diId: this.value,
  2176. type: 1,
  2177. days: this.quarterageData.length != 0 ? (this.quarterageData[this.quarterageData.length - 1].days) + 1 : 1,
  2178. nationalTravelFeeId: '',
  2179. cost: 0,
  2180. currency: 0,
  2181. subTotal: 0,
  2182. remark: '',
  2183. })
  2184. // this.boardWagesData.push({
  2185. // id:0,
  2186. // diId:this.value,
  2187. // type:2,
  2188. // days:this.boardWagesData.length!=0?(this.boardWagesData[this.boardWagesData.length-1].days)+1:1,
  2189. // nationalTravelFeeId:'',
  2190. // cost:0,
  2191. // currency:0,
  2192. // subTotal:0,
  2193. // remark:'',
  2194. // })
  2195. }
  2196. if (text == "伙食费") {
  2197. this.boardWagesData.push({
  2198. id: 0,
  2199. diId: this.value,
  2200. type: 2,
  2201. days: this.boardWagesData.length != 0 ? (this.boardWagesData[this.boardWagesData.length - 1].days) + 1 : 1,
  2202. nationalTravelFeeId: '',
  2203. cost: 0,
  2204. currency: 0,
  2205. subTotal: 0,
  2206. remark: '',
  2207. })
  2208. this.miscellaneousFeeData.push({
  2209. id: 0,
  2210. diId: this.value,
  2211. type: 3,
  2212. days: this.miscellaneousFeeData.length != 0 ? (this.miscellaneousFeeData[this.miscellaneousFeeData.length - 1].days) + 1 : 1,
  2213. nationalTravelFeeId: '',
  2214. cost: 0,
  2215. currency: 0,
  2216. subTotal: 0,
  2217. remark: '',
  2218. })
  2219. }
  2220. if (text == "公杂费") {
  2221. this.miscellaneousFeeData.push({
  2222. id: 0,
  2223. diId: this.value,
  2224. type: 3,
  2225. days: this.miscellaneousFeeData.length != 0 ? (this.miscellaneousFeeData[this.miscellaneousFeeData.length - 1].days) + 1 : 1,
  2226. nationalTravelFeeId: '',
  2227. cost: 0,
  2228. currency: 0,
  2229. subTotal: 0,
  2230. remark: '',
  2231. })
  2232. }
  2233. if (text == "培训费") {
  2234. this.trainingExpenseData.push({
  2235. id: 0,
  2236. diId: this.value,
  2237. type: 4,
  2238. days: this.trainingExpenseData.length != 0 ? (this.trainingExpenseData[this.trainingExpenseData.length - 1].days) + 1 : 1,
  2239. nationalTravelFeeId: '',
  2240. cost: 0,
  2241. currency: 0,
  2242. subTotal: 0,
  2243. remark: '',
  2244. })
  2245. }
  2246. if (text == "其他") {
  2247. this.otherData.push({
  2248. id: 0,
  2249. diId: this.value,
  2250. setDataId: '',
  2251. index: this.otherData.length != 0 ? (this.otherData[this.otherData.length - 1].index) + 1 : 1,
  2252. cost: '',
  2253. cost: 0,
  2254. currency: 0,
  2255. subTotal: 0,
  2256. remark:'',
  2257. })
  2258. }
  2259. },
  2260. //保存
  2261. storage: debounce(function () {
  2262. return new Promise((resolve, reject) => {
  2263. //已使用币种
  2264. let usedCurrencys = [];
  2265. //住宿费
  2266. this.fullscreenLoading = true
  2267. var quarterageDatas = [];
  2268. for (let m = 0; m < this.quarterageData.length; m++) {
  2269. usedCurrencys.push(this.quarterageData[m].curremcyCode);
  2270. if (this.quarterageData[m].nationalTravelFeeId != '') {
  2271. quarterageDatas.push({
  2272. id: this.quarterageData[m].id,
  2273. diId: this.quarterageData[m].diId,
  2274. type: this.quarterageData[m].type,
  2275. days: this.quarterageData[m].days,
  2276. nationalTravelFeeId: this.quarterageData[m].nationalTravelFeeId,
  2277. cost: this.quarterageData[m].cost,
  2278. currency: this.quarterageData[m].currency,
  2279. subTotal: this.quarterageData[m].subTotal,
  2280. remark: this.quarterageData[m].remark,
  2281. })
  2282. }
  2283. }
  2284. //伙食费
  2285. var boardWagesDatas = [];
  2286. for (let n = 0; n < this.boardWagesData.length; n++) {
  2287. usedCurrencys.push(this.boardWagesData[n].curremcyCode);
  2288. if (this.boardWagesData[n].nationalTravelFeeId != '') {
  2289. boardWagesDatas.push({
  2290. id: this.boardWagesData[n].id,
  2291. diId: this.boardWagesData[n].diId,
  2292. type: this.boardWagesData[n].type,
  2293. days: this.boardWagesData[n].days,
  2294. nationalTravelFeeId: this.boardWagesData[n].nationalTravelFeeId,
  2295. cost: this.boardWagesData[n].cost,
  2296. currency: this.boardWagesData[n].currency,
  2297. subTotal: this.boardWagesData[n].subTotal,
  2298. remark: this.boardWagesData[n].remark,
  2299. })
  2300. }
  2301. }
  2302. //公杂费miscellaneousFeeData
  2303. var miscellaneousFeeDatas = [];
  2304. for (let b = 0; b < this.miscellaneousFeeData.length; b++) {
  2305. usedCurrencys.push(this.miscellaneousFeeData[b].curremcyCode);
  2306. if (this.miscellaneousFeeData[b].nationalTravelFeeId != '') {
  2307. miscellaneousFeeDatas.push({
  2308. id: this.miscellaneousFeeData[b].id,
  2309. diId: this.miscellaneousFeeData[b].diId,
  2310. type: this.miscellaneousFeeData[b].type,
  2311. days: this.miscellaneousFeeData[b].days,
  2312. nationalTravelFeeId: this.miscellaneousFeeData[b].nationalTravelFeeId,
  2313. cost: this.miscellaneousFeeData[b].cost,
  2314. currency: this.miscellaneousFeeData[b].currency,
  2315. subTotal: this.miscellaneousFeeData[b].subTotal,
  2316. remark: this.miscellaneousFeeData[b].remark,
  2317. })
  2318. }
  2319. }
  2320. //培训费
  2321. var trainingExpenseDatas = [];
  2322. for (let p = 0; p < this.trainingExpenseData.length; p++) {
  2323. usedCurrencys.push(this.trainingExpenseData[p].curremcyCode);
  2324. if (this.trainingExpenseData[p].nationalTravelFeeId != '') {
  2325. trainingExpenseDatas.push({
  2326. id: this.trainingExpenseData[p].id,
  2327. diId: this.trainingExpenseData[p].diId,
  2328. type: this.trainingExpenseData[p].type,
  2329. days: this.trainingExpenseData[p].days,
  2330. nationalTravelFeeId: this.trainingExpenseData[p].nationalTravelFeeId,
  2331. cost: this.trainingExpenseData[p].cost,
  2332. currency: this.trainingExpenseData[p].currency,
  2333. subTotal: this.trainingExpenseData[p].subTotal,
  2334. remark: this.trainingExpenseData[p].remark,
  2335. })
  2336. }
  2337. }
  2338. //其他费
  2339. var otherDatas = [];
  2340. for (let c = 0; c < this.otherData.length; c++) {
  2341. //usedCurrencys.push(this.otherData[c].curremcyCode);
  2342. if (this.otherData[c].setDataId != '') {
  2343. otherDatas.push({
  2344. id: this.otherData[c].id,
  2345. diId: this.otherData[c].diId,
  2346. index: this.otherData[c].index,
  2347. setDataId: this.otherData[c].setDataId,
  2348. cost: this.otherData[c].cost,
  2349. currency: this.otherData[c].currency,
  2350. subTotal: this.otherData[c].subTotal,
  2351. remark: this.otherData[c].remark,
  2352. })
  2353. }
  2354. }
  2355. this.storageAPI(quarterageDatas, boardWagesDatas, miscellaneousFeeDatas, trainingExpenseDatas, otherDatas)
  2356. // let uniqueUsedCurrencys = [...new Set(usedCurrencys)];
  2357. // let confirmText='';
  2358. // for(let i = 0;i < this.currencyss.length;i++)
  2359. // {
  2360. // let rate = this.currencyss[i];
  2361. // if(uniqueUsedCurrencys.includes(rate.currCode)) {
  2362. // confirmText += rate.currName + "("+ rate.currCode +"):"+ rate.rate +"\t\t";
  2363. // }
  2364. // }
  2365. // const h = this.$createElement;
  2366. // this.$confirm("实时汇率提示",{
  2367. // title:'实时汇率提示',
  2368. // message: h('p', null, [
  2369. // h('div', null, confirmText),
  2370. // //h('div', { style: 'color: red' }, '是否前往编辑!')
  2371. // ]),
  2372. // iconClass: "el-icon-warning-outline colorGreen",//自定义图标样式
  2373. // confirmButtonText: "已知晓",//确认按钮文字更换
  2374. // showCancelButton: false,
  2375. // //cancelButtonText: "取消",//取消按钮文字更换
  2376. // showClose: false,//是否显示右上角关闭按钮
  2377. // type: "warning",//提示类型 success/info/warning/error
  2378. // }).then(()=>{
  2379. // //确认操作
  2380. // //this.fullscreenLoading = false;
  2381. // this.storageAPI(quarterageDatas, boardWagesDatas, miscellaneousFeeDatas, trainingExpenseDatas, otherDatas)
  2382. // }).catch(() => {
  2383. // //取消操作
  2384. // });
  2385. });
  2386. }, 1000, true),
  2387. //导出保存
  2388. //保存API
  2389. storageAPI(arrthre, arrfour, arrfive, arrsix, arrSeven) {
  2390. var url = "/api/Groups/PostEnterExitCostOperate"
  2391. var that = this
  2392. this.$axios({
  2393. method: 'post',
  2394. url: url,
  2395. headers: {
  2396. Authorization: 'Bearer ' + this.token,
  2397. contentType: 'application/json'
  2398. },
  2399. data: {
  2400. portType: 1,
  2401. userId: that.userId,
  2402. id: that.storageid,
  2403. diId: that.value,
  2404. choiceOne: that.choiceOne ? 1 : 0,
  2405. insidePay: that.DomesticFees.total,
  2406. visa: that.DomesticFees.visafees,
  2407. visaRemark: that.DomesticFees.visafeesDescription,
  2408. yiMiao: that.DomesticFees.vaccinefees,
  2409. heSuan: that.DomesticFees.nucleicfees,
  2410. service: that.DomesticFees.serviceCharge,
  2411. ticket: that.DomesticFees.ticketsExhibitionL,
  2412. safe: that.DomesticFees.insurance,
  2413. firstItemRemark:that.DomesticFees.firstItemRemark,
  2414. choiceTwo: that.choiceTwo ? 1 : 0,
  2415. otherExpenses_Checked: that.choiceSeven ? 1 : 0,
  2416. sumJJC: that.sumJJC ? 1 : 0,
  2417. sumGWC: that.sumGWC ? 1 : 0,
  2418. sumTDC: that.sumTDC ? 1 : 0,
  2419. outsideJJPay: that.TotalExpenses.EconomyClasstotal,
  2420. outsideGWPay: that.TotalExpenses.BusinessClasstotal,
  2421. outsideTDPay: that.TotalExpenses.Firstclasstotal,
  2422. twoItemRemark:that.TotalExpenses.twoItemRemark,
  2423. airJJ: that.TotalExpenses.EconomyClass,
  2424. airGW: that.TotalExpenses.BusinessClass,
  2425. airTD: that.TotalExpenses.Firstclass,
  2426. cityTranffic: that.TotalExpenses.TravellingExpensesJJ,
  2427. cityTranffic1: that.TotalExpenses.TravellingExpensesGW,
  2428. cityTranffic2: that.TotalExpenses.TravellingExpensesTD,
  2429. dayOtherPriceData: arrSeven,
  2430. currencys: that.currencys,
  2431. choiceThree: that.choiceThree ? 1 : 0,
  2432. quarterageData: arrthre,
  2433. choiceFour: that.choiceFour ? 1 : 0,
  2434. boardWagesData: arrfour,
  2435. choiceFive: that.choiceFive ? 1 : 0,
  2436. miscellaneousFeeData: arrfive,
  2437. choiceSix: that.choiceSix ? 1 : 0,
  2438. //加参数
  2439. trainingExpenseData: arrsix,
  2440. airJJC_Checked: that.airJJC_Checked ? 1 : 0,
  2441. airGWC_Checked: that.airGWC_Checked ? 1 : 0,
  2442. airTDC_Checked: that.airTDC_Checked ? 1 : 0,
  2443. }
  2444. }).then(function (res) {
  2445. if (res.data.code == 200) {
  2446. that.$message({
  2447. type: 'success',
  2448. message: res.data.msg
  2449. });
  2450. that.GetEnterExitCostInfobyDiId()
  2451. } else {
  2452. that.fullscreenLoading = false;
  2453. that.$message.error(res.data.msg);
  2454. }
  2455. }).catch(function (error) {
  2456. that.$message.error(error.message);
  2457. });
  2458. },
  2459. //选择团组名称调用
  2460. chengvalue(val) {
  2461. window.localStorage.setItem('sgvalue', this.value);
  2462. for(let i=0;i<this.options.length;i++){
  2463. if (val==this.options[i].id) {
  2464. console.log(this.options[i]);
  2465. this.provinceId=this.options[i].provinceId
  2466. }
  2467. }
  2468. this.airDataArrvalue='';
  2469. this.fullscreenLoading = true;
  2470. // this.EnterExitCostFileOwner();
  2471. // this.GetNationalTravelFeeData();
  2472. this.GetEnterExitCostInfobyDiId();
  2473. this.PostGroupTeamRateByDiIdAndCTableId();
  2474. },
  2475. eptschedule: debounce(function (val) {
  2476. return new Promise((resolve, reject) => {
  2477. //住宿费
  2478. this.fullscreenLoading = true
  2479. var quarterageDatas = [];
  2480. for (let m = 0; m < this.quarterageData.length; m++) {
  2481. if (this.quarterageData[m].nationalTravelFeeId != '') {
  2482. quarterageDatas.push({
  2483. id: this.quarterageData[m].id,
  2484. diId: this.quarterageData[m].diId,
  2485. type: this.quarterageData[m].type,
  2486. days: this.quarterageData[m].days,
  2487. nationalTravelFeeId: this.quarterageData[m].nationalTravelFeeId,
  2488. cost: this.quarterageData[m].cost,
  2489. currency: this.quarterageData[m].currency,
  2490. subTotal: this.quarterageData[m].subTotal,
  2491. remark: this.quarterageData[m].remark,
  2492. })
  2493. }
  2494. }
  2495. //伙食费
  2496. var boardWagesDatas = [];
  2497. for (let n = 0; n < this.boardWagesData.length; n++) {
  2498. if (this.boardWagesData[n].nationalTravelFeeId != '') {
  2499. boardWagesDatas.push({
  2500. id: this.boardWagesData[n].id,
  2501. diId: this.boardWagesData[n].diId,
  2502. type: this.boardWagesData[n].type,
  2503. days: this.boardWagesData[n].days,
  2504. nationalTravelFeeId: this.boardWagesData[n].nationalTravelFeeId,
  2505. cost: this.boardWagesData[n].cost,
  2506. currency: this.boardWagesData[n].currency,
  2507. subTotal: this.boardWagesData[n].subTotal,
  2508. remark: this.boardWagesData[n].remark,
  2509. })
  2510. }
  2511. }
  2512. //公杂费miscellaneousFeeData
  2513. var miscellaneousFeeDatas = [];
  2514. for (let b = 0; b < this.miscellaneousFeeData.length; b++) {
  2515. if (this.miscellaneousFeeData[b].nationalTravelFeeId != '') {
  2516. miscellaneousFeeDatas.push({
  2517. id: this.miscellaneousFeeData[b].id,
  2518. diId: this.miscellaneousFeeData[b].diId,
  2519. type: this.miscellaneousFeeData[b].type,
  2520. days: this.miscellaneousFeeData[b].days,
  2521. nationalTravelFeeId: this.miscellaneousFeeData[b].nationalTravelFeeId,
  2522. cost: this.miscellaneousFeeData[b].cost,
  2523. currency: this.miscellaneousFeeData[b].currency,
  2524. subTotal: this.miscellaneousFeeData[b].subTotal,
  2525. remark: this.miscellaneousFeeData[b].remark,
  2526. })
  2527. }
  2528. }
  2529. //培训费
  2530. var trainingExpenseDatas = [];
  2531. for (let p = 0; p < this.trainingExpenseData.length; p++) {
  2532. if (this.trainingExpenseData[p].nationalTravelFeeId != '') {
  2533. trainingExpenseDatas.push({
  2534. id: this.trainingExpenseData[p].id,
  2535. diId: this.trainingExpenseData[p].diId,
  2536. type: this.trainingExpenseData[p].type,
  2537. days: this.trainingExpenseData[p].days,
  2538. nationalTravelFeeId: this.trainingExpenseData[p].nationalTravelFeeId,
  2539. cost: this.trainingExpenseData[p].cost,
  2540. currency: this.trainingExpenseData[p].currency,
  2541. subTotal: this.trainingExpenseData[p].subTotal,
  2542. remark: this.trainingExpenseData[p].remark,
  2543. })
  2544. }
  2545. }
  2546. //其他费
  2547. var otherDatas = [];
  2548. for (let c = 0; c < this.otherData.length; c++) {
  2549. if (this.otherData[c].setDataId != '') {
  2550. otherDatas.push({
  2551. id: this.otherData[c].id,
  2552. diId: this.otherData[c].diId,
  2553. index: this.otherData[c].index,
  2554. setDataId: this.otherData[c].setDataId,
  2555. cost: this.otherData[c].cost,
  2556. currency: this.otherData[c].currency,
  2557. subTotal: this.otherData[c].subTotal,
  2558. remark: this.otherData[c].remark,
  2559. })
  2560. }
  2561. }
  2562. var url = "/api/Groups/PostEnterExitCostOperate"
  2563. var that = this
  2564. this.$axios({
  2565. method: 'post',
  2566. url: url,
  2567. headers: {
  2568. Authorization: 'Bearer ' + this.token,
  2569. contentType: 'application/json'
  2570. },
  2571. data: {
  2572. portType: 1,
  2573. userId: that.userId,
  2574. id: that.storageid,
  2575. diId: that.value,
  2576. choiceOne: that.choiceOne ? 1 : 0,
  2577. insidePay: that.DomesticFees.total,
  2578. visa: that.DomesticFees.visafees,
  2579. visaRemark: that.DomesticFees.visafeesDescription,
  2580. yiMiao: that.DomesticFees.vaccinefees,
  2581. heSuan: that.DomesticFees.nucleicfees,
  2582. service: that.DomesticFees.serviceCharge,
  2583. ticket: that.DomesticFees.ticketsExhibitionL,
  2584. safe: that.DomesticFees.insurance,
  2585. firstItemRemark: that.DomesticFees.firstItemRemark,
  2586. choiceTwo: that.choiceTwo ? 1 : 0,
  2587. otherExpenses_Checked: that.choiceSeven ? 1 : 0,
  2588. sumJJC: that.sumJJC ? 1 : 0,
  2589. sumGWC: that.sumGWC ? 1 : 0,
  2590. sumTDC: that.sumTDC ? 1 : 0,
  2591. outsideJJPay: that.TotalExpenses.EconomyClasstotal,
  2592. outsideGWPay: that.TotalExpenses.BusinessClasstotal,
  2593. outsideTDPay: that.TotalExpenses.Firstclasstotal,
  2594. twoItemRemark: that.TotalExpenses.twoItemRemark,
  2595. airJJ: that.TotalExpenses.EconomyClass,
  2596. airGW: that.TotalExpenses.BusinessClass,
  2597. airTD: that.TotalExpenses.Firstclass,
  2598. cityTranffic: that.TotalExpenses.TravellingExpensesJJ,
  2599. cityTranffic1: that.TotalExpenses.TravellingExpensesGW,
  2600. cityTranffic2: that.TotalExpenses.TravellingExpensesTD,
  2601. dayOtherPriceData: otherDatas,
  2602. currencys: that.currencys,
  2603. choiceThree: that.choiceThree ? 1 : 0,
  2604. quarterageData: quarterageDatas,
  2605. choiceFour: that.choiceFour ? 1 : 0,
  2606. boardWagesData: boardWagesDatas,
  2607. choiceFive: that.choiceFive ? 1 : 0,
  2608. miscellaneousFeeData: miscellaneousFeeDatas,
  2609. choiceSix: that.choiceSix ? 1 : 0,
  2610. //加参数
  2611. trainingExpenseData: trainingExpenseDatas,
  2612. airJJC_Checked: that.airJJC_Checked ? 1 : 0,
  2613. airGWC_Checked: that.airGWC_Checked ? 1 : 0,
  2614. airTDC_Checked: that.airTDC_Checked ? 1 : 0,
  2615. }
  2616. }).then(function (res) {
  2617. if (res.data.code == 200) {
  2618. that.$message({
  2619. type: 'success',
  2620. message: res.data.msg
  2621. });
  2622. that.GetEnterExitCostInfobyDiId()
  2623. var subTypeId = 0
  2624. if (val == 1) {
  2625. subTypeId = that.listvalue
  2626. } else if (val == 2) {
  2627. subTypeId = that.tablevalue
  2628. } else {
  2629. subTypeId = 1
  2630. }
  2631. if (subTypeId == "") {
  2632. that.$message.error('请选择需要导出的表格');
  2633. return
  2634. }
  2635. var url = "/api/Groups/PostEnterExitCostDownload"
  2636. that.$axios({
  2637. method: 'post',
  2638. url: url,
  2639. headers: {
  2640. Authorization: 'Bearer ' + that.token
  2641. },
  2642. data: {
  2643. portType: 1,
  2644. diId: that.value,
  2645. exportType: val,
  2646. subTypeId: subTypeId
  2647. }
  2648. }).then(function (res) {
  2649. if (res.data.code == 200) {
  2650. that.$message({
  2651. type: 'success',
  2652. message: res.data.msg
  2653. });
  2654. window.open(res.data.data.url);
  2655. } else {
  2656. that.$message.error(res.data.msg);
  2657. }
  2658. })
  2659. } else {
  2660. that.fullscreenLoading = false;
  2661. that.$message.error(res.data.msg);
  2662. }
  2663. }).catch(function (error) {
  2664. that.$message.error(error.message);
  2665. });
  2666. // this.storageAPI(quarterageDatas, boardWagesDatas, miscellaneousFeeDatas, trainingExpenseDatas, otherDatas)
  2667. })
  2668. // this.storage().then(function () {
  2669. // });
  2670. }, 500, true),
  2671. //
  2672. calculation() {
  2673. var jnfy
  2674. var jjcxj
  2675. var gwcxj
  2676. var tdcxj
  2677. var zsf
  2678. var hsf
  2679. var gzf
  2680. var pxf
  2681. var qtfy
  2682. if (this.choiceOne == true) {
  2683. jnfy = this.DomesticFees.total;
  2684. } else {
  2685. jnfy = 0;
  2686. }
  2687. if (this.choiceThree == true) {
  2688. zsf = this.TotalAccommodationFee;
  2689. } else {
  2690. zsf = 0;
  2691. }
  2692. if (this.choiceFour == true) {
  2693. hsf = this.TotalMeals;
  2694. } else {
  2695. hsf = 0;
  2696. }
  2697. if (this.choiceFive == true) {
  2698. gzf = this.TotalMiscellaneous;
  2699. } else {
  2700. gzf = 0;
  2701. }
  2702. if (this.choiceSix == true) {
  2703. pxf = this.trainingExpense;
  2704. } else {
  2705. pxf = 0;
  2706. }
  2707. if (this.choiceSeven == true) {
  2708. qtfy = this.otherExpense;
  2709. } else {
  2710. qtfy = 0;
  2711. }
  2712. if (this.sumJJC == true) {
  2713. jjcxj = this.TotalExpenses.EconomyClasstotal;
  2714. this.jjctotal = jnfy + jjcxj + zsf + hsf + gzf + pxf + qtfy;
  2715. } else {
  2716. jjcxj = 0;
  2717. this.jjctotal = 0;
  2718. }
  2719. if (this.sumGWC == true) {
  2720. gwcxj = this.TotalExpenses.BusinessClasstotal;
  2721. this.gwctotal = jnfy + gwcxj + zsf + hsf + gzf + pxf + qtfy;
  2722. } else {
  2723. gwcxj = 0;
  2724. this.gwctotal = 0;
  2725. }
  2726. if (this.sumTDC == true) {
  2727. tdcxj = this.TotalExpenses.Firstclasstotal;
  2728. this.tdctotal = jnfy + tdcxj + zsf + hsf + gzf + pxf + qtfy;
  2729. } else {
  2730. tdcxj = 0;
  2731. this.tdctotal = 0;
  2732. }
  2733. },
  2734. //其他删除
  2735. DeleteOtherExpenses(index, row, rows) {
  2736. this.$confirm('此操作将永久删除该文件, 是否继续?', '提示', {
  2737. confirmButtonText: '确定',
  2738. cancelButtonText: '取消',
  2739. type: 'warning'
  2740. }).then(() => {
  2741. {
  2742. if (row.id == 0) {
  2743. this.$message({
  2744. type: 'success',
  2745. message: '删除成功'
  2746. });
  2747. rows.splice(index, 1);
  2748. this.otherExpense = 0;
  2749. for (let a = 0; a < rows.length; a++) {
  2750. this.otherExpense += rows[a].subTotal;
  2751. }
  2752. return;
  2753. }
  2754. var url = "/api/Groups/DeleteOtherExpenses"
  2755. var that = this
  2756. this.$axios({
  2757. method: 'post',
  2758. url: url,
  2759. headers: {
  2760. Authorization: 'Bearer ' + that.token
  2761. },
  2762. data: {
  2763. portType: 1,
  2764. id: row.id,
  2765. deleteUserId: that.userId
  2766. }
  2767. }).then(function (res) {
  2768. if (res.data.code == 200) {
  2769. that.$message({
  2770. type: 'success',
  2771. message: res.data.msg
  2772. });
  2773. rows.splice(index, 1);
  2774. this.otherExpense = 0;
  2775. for (let a = 0; a < rows.length; a++) {
  2776. this.otherExpense += rows[a].subTotal;
  2777. }
  2778. } else {
  2779. that.$message.error(res.data.msg);
  2780. }
  2781. })
  2782. }
  2783. }).catch(() => {
  2784. this.$message({
  2785. type: 'info',
  2786. message: '已取消删除'
  2787. });
  2788. });
  2789. },
  2790. //删除
  2791. deleteRow(index, row, rows, val) {
  2792. this.$confirm('此操作将永久删除该文件, 是否继续?', '提示', {
  2793. confirmButtonText: '确定',
  2794. cancelButtonText: '取消',
  2795. type: 'warning'
  2796. }).then(() => {
  2797. if (row.id == 0) {
  2798. this.$message({
  2799. type: 'success',
  2800. message: '删除成功'
  2801. });
  2802. rows.splice(index, 1);
  2803. if (val == 1) {
  2804. this.TotalAccommodationFee = 0;
  2805. for (let a = 0; a < rows.length; a++) {
  2806. this.TotalAccommodationFee += rows[a].subTotal;
  2807. }
  2808. }
  2809. if (val == 2) {
  2810. this.TotalMeals = 0;
  2811. for (let a = 0; a < rows.length; a++) {
  2812. this.TotalMeals += rows[a].subTotal;
  2813. }
  2814. }
  2815. if (val == 3) {
  2816. this.TotalMiscellaneous = 0;
  2817. for (let a = 0; a < rows.length; a++) {
  2818. this.TotalMiscellaneous += rows[a].subTotal;
  2819. }
  2820. }
  2821. if (val == 4) {
  2822. this.trainingExpense = 0;
  2823. for (let a = 0; a < rows.length; a++) {
  2824. this.trainingExpense += rows[a].subTotal;
  2825. }
  2826. }
  2827. return;
  2828. }
  2829. var url = "/api/Groups/PostEnterExitCostSubItemDel"
  2830. var that = this
  2831. this.$axios({
  2832. method: 'post',
  2833. url: url,
  2834. headers: {
  2835. Authorization: 'Bearer ' + that.token
  2836. },
  2837. data: {
  2838. portType: 1,
  2839. id: row.id,
  2840. deleteUserId: that.userId
  2841. }
  2842. }).then(function (res) {
  2843. if (res.data.code == 200) {
  2844. that.$message({
  2845. type: 'success',
  2846. message: res.data.msg
  2847. });
  2848. rows.splice(index, 1);
  2849. if (val == 1) {
  2850. that.TotalAccommodationFee = 0;
  2851. for (let a = 0; a < rows.length; a++) {
  2852. that.TotalAccommodationFee += rows[a].subTotal;
  2853. }
  2854. }
  2855. if (val == 2) {
  2856. that.TotalMeals = 0;
  2857. for (let a = 0; a < rows.length; a++) {
  2858. that.TotalMeals += rows[a].subTotal;
  2859. }
  2860. }
  2861. if (val == 3) {
  2862. that.TotalMiscellaneous = 0;
  2863. for (let a = 0; a < rows.length; a++) {
  2864. that.TotalMiscellaneous += rows[a].subTotal;
  2865. }
  2866. }
  2867. if (val == 4) {
  2868. that.trainingExpense = 0;
  2869. for (let a = 0; a < rows.length; a++) {
  2870. that.trainingExpense += rows[a].subTotal;
  2871. }
  2872. }
  2873. } else {
  2874. that.$message.error(res.data.msg);
  2875. }
  2876. })
  2877. }).catch(() => {
  2878. this.$message({
  2879. type: 'info',
  2880. message: '已取消删除'
  2881. });
  2882. });
  2883. },
  2884. //填入实时汇率
  2885. adoptRealtime() {
  2886. for (let at = 0; at < this.currencys.length; at++) {
  2887. for (let rt = 0; rt < this.currencyss.length; rt++) {
  2888. if (this.currencys[at].currencyCode == this.currencyss[rt].currCode) {
  2889. this.currencys[at].rate = this.currencyss[rt].rate
  2890. }
  2891. }
  2892. }
  2893. this.cubtn = false;
  2894. },
  2895. Getnewvisafee() {
  2896. this.DomesticFees.visafees = this.visainfo.feeTotal;
  2897. this.DomesticFees.visafeesDescription = this.visainfo.remark;
  2898. this.getvisafeebtn = false;
  2899. },
  2900. //导出到收款账单
  2901. NationalTravelFeeImportReceivables() {
  2902. var url = "/api/Groups/NationalTravelFeeImportReceivables/" + this.value
  2903. var that = this
  2904. this.$axios({
  2905. method: 'get',
  2906. url: url,
  2907. headers: {
  2908. Authorization: 'Bearer ' + that.token
  2909. },
  2910. }).then(function (res) {
  2911. if (res.data.code == 200) {
  2912. that.$message({
  2913. type: 'success',
  2914. message: res.data.msg
  2915. });
  2916. } else {
  2917. that.$message.error(res.data.msg);
  2918. }
  2919. }).catch(function (error) {
  2920. that.$message.error("操作错误,联系信息部!");
  2921. });
  2922. },
  2923. //设置权限按钮
  2924. setpermissionsbtn(){
  2925. this.viewUsers=this.viewUsersby;
  2926. this.setpermissions=true;
  2927. },
  2928. handleCheckAllChange(val) {
  2929. },
  2930. //分配查看权限
  2931. EnterExitCostSetViewPermissiion() {
  2932. var url = "/api/Groups/EnterExitCostSetViewPermissiion"
  2933. var that = this
  2934. this.$axios({
  2935. method: 'post',
  2936. url: url,
  2937. headers: {
  2938. Authorization: 'Bearer ' + that.token
  2939. },
  2940. data:{
  2941. portType:1,
  2942. groupId:that.value,
  2943. userIds:that.viewUsers,
  2944. currUserId:that.userId,
  2945. }
  2946. }).then(function (res) {
  2947. if (res.data.code == 200) {
  2948. that.$message({
  2949. type: 'success',
  2950. message: res.data.msg
  2951. });
  2952. that.setpermissions=false;
  2953. that.GetEnterExitCostInfobyDiId();
  2954. } else {
  2955. that.setpermissions=false;
  2956. that.$message.error(res.data.msg);
  2957. }
  2958. }).catch(function (error) {
  2959. that.$message.error("操作错误,联系信息部!");
  2960. });
  2961. },
  2962. //交通费基础费用
  2963. GetEnterExitCostOVByGroupId() {
  2964. var url = "/api/Groups/GetEnterExitCostOVByGroupId/"+this.value
  2965. var that = this
  2966. this.$axios({
  2967. method: 'get',
  2968. url: url,
  2969. headers: {
  2970. Authorization: 'Bearer ' + this.token
  2971. },
  2972. }).then(function (res) {
  2973. that.fulecao=[];
  2974. that.Basicdata={};
  2975. that.currencies=[];
  2976. if (res.data.code == 200) {
  2977. that.Basicdata=res.data.data;
  2978. that.currencies=res.data.data.currencies;
  2979. that.fulecao=res.data.data.data;
  2980. }else {
  2981. that.$message.error(res.data.msg);
  2982. }
  2983. })
  2984. },
  2985. //交通费详细
  2986. GetEnterExitCostOVFeeDetails() {
  2987. var url = "/api/Groups/GetEnterExitCostOVFeeDetails/"+this.value+"?currUserId="+this.userId
  2988. var that = this
  2989. this.$axios({
  2990. method: 'get',
  2991. url: url,
  2992. headers: {
  2993. Authorization: 'Bearer ' + this.token
  2994. },
  2995. }).then(function (res) {
  2996. that.Transportationdata=[];
  2997. that.Transportationdatatotal=0;
  2998. that.pullCartFeeDetails=[];
  2999. that.pullCartFeeTotal=0;
  3000. that.trainFeeDetails=[];
  3001. that.trainFeeTotal=0;
  3002. that.cityAirTicketFeeDetails=[];
  3003. that.cityAirTicketFeeTotal=0;
  3004. that.lastUpdateUserName="";
  3005. that.lastUpdateTime="";
  3006. that.createUserName="";
  3007. that.createTime="";
  3008. if (res.data.code == 200) {
  3009. that.Transportationdata=res.data.data.aptFeeDetails;
  3010. that.Transportationdatatotal=res.data.data.aptFeeTotal;
  3011. that.pullCartFeeDetails=res.data.data.pullCartFeeDetails;
  3012. that.pullCartFeeTotal=res.data.data.pullCartFeeTotal;
  3013. that.trainFeeDetails=res.data.data.trainFeeDetails;
  3014. that.trainFeeTotal=res.data.data.trainFeeTotal;
  3015. that.cityAirTicketFeeDetails=res.data.data.cityAirTicketFeeDetails;
  3016. that.cityAirTicketFeeTotal=res.data.data.cityAirTicketFeeTotal;
  3017. that.lastUpdateUserName=res.data.data.lastUpdateUserName;
  3018. that.lastUpdateTime=res.data.data.lastUpdateTime;
  3019. that.createUserName=res.data.data.createUserName;
  3020. that.createTime=res.data.data.createTime;
  3021. that.GetEnterExitCostOVByGroupId();
  3022. }else {
  3023. that.$message.error(res.data.msg);
  3024. }
  3025. })
  3026. },
  3027. //交通费弹窗
  3028. openTransportation(){
  3029. this.GetEnterExitCostOVFeeDetails();
  3030. this.TransportationVisible=true;
  3031. },
  3032. //选择城市交通费
  3033. UrbanSelect(val, item, index) {
  3034. var obj = {}
  3035. obj = this.fulecao.find(function (i,indexs) {
  3036. return i.id === item
  3037. });
  3038. val.cost=obj.price;
  3039. val.otherCost=obj.otherPrice;
  3040. val.guideCost=obj.guidePrice;
  3041. val.currencyName=obj.currencyName
  3042. this.UrbanModify(val,val.currencyName)
  3043. },
  3044. numFilters(value) {
  3045. // 截取当前数据到小数点后两位
  3046. let tempVal = parseFloat(value).toFixed(3);
  3047. let realVal = tempVal.substring(0, tempVal.length - 1);
  3048. return realVal;
  3049. },
  3050. deleteRowJSJ(index, rows,row) {
  3051. this.$confirm('此操作只是移除该条数据做出计算并未保存,如要删除该条数据请点击保存!', '提示', {
  3052. confirmButtonText: '确定',
  3053. cancelButtonText: '取消',
  3054. type: 'warning'
  3055. }).then(() => {
  3056. rows.splice(index, 1);
  3057. this.UrbanTotal();
  3058. }).catch(() => {
  3059. this.$message({
  3060. type: 'info',
  3061. message: '操作已取消!'
  3062. });
  3063. });
  3064. },
  3065. deleteRowLC(index, rows,row) {
  3066. this.$confirm('此操作只是移除该条数据做出计算并未保存,如要删除该条数据请点击保存!', '提示', {
  3067. confirmButtonText: '确定',
  3068. cancelButtonText: '取消',
  3069. type: 'warning'
  3070. }).then(() => {
  3071. rows.splice(index, 1);
  3072. this.UrbanTotalLC();
  3073. }).catch(() => {
  3074. this.$message({
  3075. type: 'info',
  3076. message: '操作已取消!'
  3077. });
  3078. });
  3079. },
  3080. deleteRowHC(index, rows,row) {
  3081. this.$confirm('此操作只是移除该条数据做出计算并未保存,如要删除该条数据请点击保存!', '提示', {
  3082. confirmButtonText: '确定',
  3083. cancelButtonText: '取消',
  3084. type: 'warning'
  3085. }).then(() => {
  3086. rows.splice(index, 1);
  3087. this.UrbanTotalHC();
  3088. }).catch(() => {
  3089. this.$message({
  3090. type: 'info',
  3091. message: '操作已取消!'
  3092. });
  3093. });
  3094. },
  3095. deleteRowJP(index, rows,row) {
  3096. this.$confirm('此操作只是移除该条数据做出计算并未保存,如要删除该条数据请点击保存!', '提示', {
  3097. confirmButtonText: '确定',
  3098. cancelButtonText: '取消',
  3099. type: 'warning'
  3100. }).then(() => {
  3101. rows.splice(index, 1);
  3102. this.UrbanTotalJP();
  3103. }).catch(() => {
  3104. this.$message({
  3105. type: 'info',
  3106. message: '操作已取消!'
  3107. });
  3108. });
  3109. },
  3110. //改值计算
  3111. UrbanModify(val,bizhong){
  3112. var total=0
  3113. var obj = {}
  3114. obj = this.currencies.find(function (i,indexs) {
  3115. return i.currencyCode === bizhong
  3116. });
  3117. total=(Number(val.cost/this.Basicdata.groupSize)+Number(val.otherCost)+Number(val.guideCost))*val.serviceCount*val.coefficient*obj.rate;
  3118. val.quote=this.numFilters(total)
  3119. this.UrbanTotal();
  3120. },
  3121. //改值计算LC
  3122. UrbanModifyLC(val){
  3123. var total=0
  3124. val.currencyName="CNY"
  3125. total=Number(val.cost)*val.coefficient;
  3126. val.quote=this.numFilters(total)
  3127. this.UrbanTotalLC();
  3128. },
  3129. //计算总价LC
  3130. UrbanTotalLC(){
  3131. this.pullCartFeeTotal=0
  3132. for(let i=0;i<this.pullCartFeeDetails.length;i++){
  3133. this.pullCartFeeTotal+=Number(this.pullCartFeeDetails[i].quote)
  3134. }
  3135. },
  3136. //改值计算HC
  3137. UrbanModifyHC(val){
  3138. var total=0
  3139. val.currencyName="CNY"
  3140. total=Number(val.cost)*val.coefficient;
  3141. val.quote=this.numFilters(total)
  3142. this.UrbanTotalHC();
  3143. },
  3144. //计算总价HC
  3145. UrbanTotalHC(){
  3146. this.trainFeeTotal=0
  3147. for(let i=0;i<this.trainFeeDetails.length;i++){
  3148. this.trainFeeTotal+=Number(this.trainFeeDetails[i].quote)
  3149. }
  3150. },
  3151. //改值计算JP
  3152. UrbanModifyJP(val){
  3153. var total=0
  3154. val.currencyName="CNY"
  3155. total=Number(val.cost)*val.coefficient;
  3156. val.quote=this.numFilters(total)
  3157. this.UrbanTotalJP();
  3158. },
  3159. //计算总价JP
  3160. UrbanTotalJP(){
  3161. this.cityAirTicketFeeTotal=0
  3162. for(let i=0;i<this.cityAirTicketFeeDetails.length;i++){
  3163. this.cityAirTicketFeeTotal+=Number(this.cityAirTicketFeeDetails[i].quote)
  3164. }
  3165. },
  3166. //计算总价
  3167. UrbanTotal(){
  3168. this.Transportationdatatotal=0
  3169. for(let i=0;i<this.Transportationdata.length;i++){
  3170. this.Transportationdatatotal+=Number(this.Transportationdata[i].quote)
  3171. }
  3172. // console.log(total);
  3173. // this.TotalExpenses.TravellingExpensesJJ=this.numFilters(total)
  3174. // this.TotalExpenses.TravellingExpensesGW=this.numFilters(total)
  3175. // this.TotalExpenses.TravellingExpensesTD=this.numFilters(total)
  3176. // this.calculation();
  3177. },
  3178. //添加一行接送机
  3179. addTransportationdata(){
  3180. this.Transportationdata.push({
  3181. coefficient: 2.5,
  3182. cost: 0,
  3183. currencyName: "CNY",
  3184. guideCost: 0,
  3185. no: this.Transportationdata.length + 1,
  3186. otherCost: 0,
  3187. ovId: '',
  3188. quote: 0,
  3189. remark: "",
  3190. serviceCount: 1
  3191. });
  3192. },
  3193. //添加一行拉车
  3194. addpullCartFeeDetails(){
  3195. this.pullCartFeeDetails.push({
  3196. no: this.pullCartFeeDetails.length + 1,
  3197. cost: 0,
  3198. coefficient: 2.50,
  3199. currencyName: "",
  3200. quote: 0,
  3201. remark: ""
  3202. });
  3203. },
  3204. //添加一行火车
  3205. addtrainFeeDetails(){
  3206. this.trainFeeDetails.push({
  3207. no: this.trainFeeDetails.length + 1,
  3208. cost: 0,
  3209. coefficient: 2.50,
  3210. currencyName: "",
  3211. quote: 0,
  3212. remark: ""
  3213. });
  3214. },
  3215. //添加一行城市机票(
  3216. addcityAirTicketFeeDetails(){
  3217. this.cityAirTicketFeeDetails.push({
  3218. no: this.cityAirTicketFeeDetails.length + 1,
  3219. cost: 0,
  3220. coefficient: 2.50,
  3221. currencyName: "",
  3222. quote: 0,
  3223. remark: ""
  3224. });
  3225. },
  3226. //刷新城市区间费标准(保存后刷新,数据修改重新赋值计算)
  3227. RefreshInterval(){
  3228. this.GetEnterExitCostOVByGroupId();
  3229. var that=this;
  3230. this.$confirm('刷新可能标准会有修改与之前的金额会有不同请注意查看!且刷新只是重新计算并未保存重新计算后的值!是否继续操作?', '提示', {
  3231. confirmButtonText: '确定',
  3232. cancelButtonText: '取消',
  3233. type: 'warning'
  3234. }).then(() => {
  3235. for (let i = 0; i < that.Transportationdata.length; i++) {
  3236. var obj = {}
  3237. obj = that.fulecao.find(function (item, indexs) {
  3238. return item.id === that.Transportationdata[i].ovId
  3239. })
  3240. this.Transportationdata[i].cost = obj.price;
  3241. this.Transportationdata[i].otherCost = obj.otherPrice;
  3242. this.Transportationdata[i].guideCost = obj.guidePrice;
  3243. this.Transportationdata[i].currencyName = obj.currencyName
  3244. this.UrbanModify(this.Transportationdata[i], this.Transportationdata[i].currencyName)
  3245. }
  3246. }).catch(() => {
  3247. this.$message({
  3248. type: 'info',
  3249. message: '已取消操作'
  3250. });
  3251. });
  3252. },
  3253. //城市交通费保存
  3254. GetEnterExitCostOVFeeSave() {
  3255. for(let i=0;i<this.Transportationdata.length;i++){
  3256. if(this.Transportationdata[i].ovId==""){
  3257. this.$message.error("请查看是否除备注外的必填项均已填写!");
  3258. return;
  3259. }
  3260. }
  3261. var url = "/api/Groups/GetEnterExitCostOVFeeSave"
  3262. var that = this
  3263. this.$axios({
  3264. method: 'post',
  3265. url: url,
  3266. headers: {
  3267. Authorization: 'Bearer ' + this.token
  3268. },
  3269. data:{
  3270. aptFeeTotal:that.Transportationdatatotal,
  3271. aptFeeDetails:that.Transportationdata,
  3272. pullCartFeeTotal:that.pullCartFeeTotal,
  3273. pullCartFeeDetails:that.pullCartFeeDetails,
  3274. trainFeeTotal:that.trainFeeTotal,
  3275. trainFeeDetails:that.trainFeeDetails,
  3276. cityAirTicketFeeTotal:that.cityAirTicketFeeTotal,
  3277. cityAirTicketFeeDetails:that.cityAirTicketFeeDetails,
  3278. currencies:that.currencies,
  3279. lastUpdateUserName:that.lastUpdateUserName,
  3280. lastUpdateTime:that.lastUpdateTime,
  3281. createUserName:that.createUserName,
  3282. createTime:that.createTime,
  3283. groupId:that.value,
  3284. currUserId:that.userId,
  3285. }
  3286. }).then(function (res) {
  3287. if (res.data.code == 200) {
  3288. that.TotalExpenses.TravellingExpensesJJ=that.numFilters(that.Transportationdatatotal + that.pullCartFeeTotal + that.trainFeeTotal + that.cityAirTicketFeeTotal);
  3289. that.TotalExpenses.TravellingExpensesGW=that.numFilters(that.Transportationdatatotal + that.pullCartFeeTotal + that.trainFeeTotal + that.cityAirTicketFeeTotal);
  3290. that.TotalExpenses.TravellingExpensesTD=that.numFilters(that.Transportationdatatotal + that.pullCartFeeTotal + that.trainFeeTotal + that.cityAirTicketFeeTotal);
  3291. if (that.TotalExpenses.twoItemRemark=='') {
  3292. that.TotalExpenses.twoItemRemark=res.data.data.label;
  3293. }else{
  3294. if (that.TotalExpenses.twoItemRemark.split("、").length > 1) {
  3295. that.TotalExpenses.twoItemRemark.split("、")[1] = res.data.data.label;
  3296. that.TotalExpenses.twoItemRemark = that.TotalExpenses.twoItemRemark.split("、")[0] + '、' + that.TotalExpenses.twoItemRemark.split("、")[1];
  3297. that.TransportationVisible = false;
  3298. that.$message.success(res.data.msg);
  3299. return;
  3300. }
  3301. if (that.TotalExpenses.twoItemRemark.includes('接送机')) {
  3302. console.log(1);
  3303. that.TotalExpenses.twoItemRemark=res.data.data.label
  3304. }else{
  3305. that.TotalExpenses.twoItemRemark=that.TotalExpenses.twoItemRemark+'、'+res.data.data.label;
  3306. }
  3307. }
  3308. that.TransportationVisible=false;
  3309. that.$message.success(res.data.msg);
  3310. }else {
  3311. that.$message.error(res.data.msg);
  3312. }
  3313. })
  3314. },
  3315. },
  3316. filters: {
  3317. numFilter(value) {
  3318. // 截取当前数据到小数点后两位
  3319. let realVal = new Decimal(value).toFixed(2)
  3320. return realVal
  3321. }
  3322. },
  3323. watch: {
  3324. Transportationdata: {
  3325. handler(newVal, oldVal) {
  3326. // this.UrbanTotal();
  3327. }
  3328. },
  3329. choiceOne(val) {//境内费用(其他费用)选择框
  3330. this.calculation();
  3331. },
  3332. choiceThree(val) {//住宿费合计选择框
  3333. this.calculation();
  3334. },
  3335. choiceFour(val) {//伙食费合计选择框
  3336. this.calculation();
  3337. },
  3338. choiceFive(val) {//公杂费合计选择框
  3339. this.calculation();
  3340. },
  3341. choiceSix(val) {//培训费用选择框
  3342. this.calculation();
  3343. },
  3344. choiceSeven(val) {//其他费用选择框
  3345. this.calculation();
  3346. },
  3347. //加参数
  3348. sumJJC(val) {//经济舱小计选择框
  3349. this.calculation();
  3350. },
  3351. sumGWC(val) {//公务舱小计选择框
  3352. this.calculation();
  3353. },
  3354. sumTDC(val) {//公务舱小计选择框
  3355. this.calculation();
  3356. },
  3357. 'DomesticFees.total': {
  3358. handler(newVal, oldVal) {
  3359. this.calculation();
  3360. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3361. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3362. },
  3363. },
  3364. TotalAccommodationFee: {
  3365. handler(newVal, oldVal) {
  3366. this.calculation();
  3367. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3368. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3369. },
  3370. },
  3371. TotalMeals: {
  3372. handler(newVal, oldVal) {
  3373. this.calculation();
  3374. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3375. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3376. },
  3377. },
  3378. TotalMiscellaneous: {
  3379. handler(newVal, oldVal) {
  3380. this.calculation();
  3381. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3382. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3383. },
  3384. },
  3385. trainingExpense: {
  3386. handler(newVal, oldVal) {
  3387. this.calculation();
  3388. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3389. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3390. },
  3391. },
  3392. otherExpense: {
  3393. handler(newVal, oldVal) {
  3394. this.calculation();
  3395. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3396. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3397. },
  3398. },
  3399. 'TotalExpenses.EconomyClasstotal': {
  3400. handler(newVal, oldVal) {
  3401. this.calculation();
  3402. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3403. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3404. },
  3405. },
  3406. 'TotalExpenses.BusinessClasstotal': {
  3407. handler(newVal, oldVal) {
  3408. this.calculation();
  3409. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3410. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3411. },
  3412. },
  3413. 'TotalExpenses.Firstclasstotal': {
  3414. handler(newVal, oldVal) {
  3415. this.calculation();
  3416. // this.jjctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.EconomyClasstotal;
  3417. // this.gwctotal=this.DomesticFees.total+this.TotalAccommodationFee+this.TotalMeals+this.TotalMiscellaneous+this.trainingExpense+this.TotalExpenses.BusinessClasstotal;
  3418. },
  3419. },
  3420. //境内费用非空处理
  3421. DomesticFees: {
  3422. handler(newVal, oldVal) {
  3423. if (newVal.insurance == undefined) {
  3424. newVal.insurance = 0
  3425. }
  3426. if (newVal.nucleicfees == undefined) {
  3427. newVal.nucleicfees = 0
  3428. }
  3429. if (newVal.serviceCharge == undefined) {
  3430. newVal.serviceCharge = 0
  3431. }
  3432. if (newVal.ticketsExhibitionL == undefined) {
  3433. newVal.ticketsExhibitionL = 0
  3434. }
  3435. if (newVal.vaccinefees == undefined) {
  3436. newVal.vaccinefees = 0
  3437. }
  3438. if (newVal.visafees == undefined) {
  3439. newVal.visafees = 0
  3440. }
  3441. },
  3442. immediate: true,
  3443. deep: true // 可以深度检测到 person 对象的属性值的变化
  3444. },
  3445. //国际旅费非空处理
  3446. TotalExpenses: {
  3447. handler(newVal, oldVal) {
  3448. if (newVal.EconomyClass == undefined) {
  3449. newVal.EconomyClass = 0
  3450. }
  3451. if (newVal.BusinessClass == undefined) {
  3452. newVal.BusinessClass = 0
  3453. }
  3454. if (newVal.TravellingExpensesJJ == undefined) {
  3455. newVal.TravellingExpensesJJ = 0
  3456. }
  3457. if (newVal.TravellingExpensesGW == undefined) {
  3458. newVal.TravellingExpensesGW = 0
  3459. }
  3460. if (newVal.TravellingExpensesTD == undefined) {
  3461. newVal.TravellingExpensesTD = 0
  3462. }
  3463. },
  3464. immediate: true,
  3465. deep: true // 可以深度检测到 person 对象的属性值的变化
  3466. },
  3467. //监听汇率数组是否变化
  3468. currencys: {
  3469. handler(val) {
  3470. this.TotalAccommodationFee = 0
  3471. for (let q = 0; q < this.quarterageData.length; q++) {
  3472. for (let qc = 0; qc < this.currencys.length; qc++) {
  3473. if (this.currencys[qc].currencyCode == this.quarterageData[q].curremcyCode||this.currencys[qc].currencyName == this.quarterageData[q].currencyName) {
  3474. this.quarterageData[q].subTotal = new Decimal(this.currencys[qc].rate * this.quarterageData[q].cost).toFixed(2)
  3475. }
  3476. }
  3477. this.TotalAccommodationFee += Number(this.quarterageData[q].subTotal);
  3478. }
  3479. //伙食费
  3480. this.TotalMeals = 0
  3481. for (let b = 0; b < this.boardWagesData.length; b++) {
  3482. for (let bc = 0; bc < this.currencys.length; bc++) {
  3483. if (this.currencys[bc].currencyCode == this.boardWagesData[b].curremcyCode||this.currencys[bc].currencyName == this.boardWagesData[b].currencyName) {
  3484. this.boardWagesData[b].subTotal = new Decimal(this.currencys[bc].rate * this.boardWagesData[b].cost).toFixed(2)
  3485. }
  3486. }
  3487. this.TotalMeals += Number(this.boardWagesData[b].subTotal);
  3488. }
  3489. //公杂费
  3490. this.TotalMiscellaneous = 0
  3491. for (let m = 0; m < this.miscellaneousFeeData.length; m++) {
  3492. for (let mc = 0; mc < this.currencys.length; mc++) {
  3493. if (this.currencys[mc].currencyCode == this.miscellaneousFeeData[m].curremcyCode||this.currencys[mc].currencyName == this.miscellaneousFeeData[m].currencyName) {
  3494. this.miscellaneousFeeData[m].subTotal = this.currencys[mc].rate * this.miscellaneousFeeData[m].cost
  3495. }
  3496. }
  3497. this.TotalMiscellaneous += this.miscellaneousFeeData[m].subTotal
  3498. }
  3499. //培训费
  3500. this.trainingExpense = 0
  3501. for (let t = 0; t < this.trainingExpenseData.length; t++) {
  3502. for (let tc = 0; tc < this.currencys.length; tc++) {
  3503. if (this.currencys[tc].currencyCode == this.trainingExpenseData[t].curremcyCode||this.currencys[tc].currencyName == this.trainingExpenseData[t].currencyName) {
  3504. this.trainingExpenseData[t].subTotal = this.currencys[tc].rate * this.trainingExpenseData[t].cost
  3505. }
  3506. }
  3507. this.trainingExpense += this.trainingExpenseData[t].subTotal
  3508. }
  3509. //其他费用
  3510. for (let nc = 0; nc < this.currencys.length; nc++) {
  3511. for (let nt = 0; nt < this.othercurrencys.length; nt++) {
  3512. if (this.currencys[nc].currencyCode == this.othercurrencys[nt].currencyCode||this.currencys[nc].currencyName == this.othercurrencys[nt].currencyName) {
  3513. this.othercurrencys[nt].rate = this.currencys[nc].rate;
  3514. }
  3515. }
  3516. }
  3517. this.otherExpense = 0;
  3518. for (let wm = 0; wm < this.otherData.length; wm++) {
  3519. for (let cj = 0; cj < this.othercurrencys.length; cj++) {
  3520. if (this.otherData[wm].currency == this.othercurrencys[cj].currencyId) {
  3521. this.otherData[wm].rate = this.othercurrencys[cj].rate
  3522. }
  3523. }
  3524. this.otherExpense += this.otherData[wm].subTotal;
  3525. if (this.otherData[wm].rate) {
  3526. this.otherData[wm].subTotal = this.otherData[wm].cost * this.otherData[wm].rate;
  3527. }
  3528. }
  3529. },
  3530. deep: true
  3531. }
  3532. },
  3533. created() {
  3534. this.QuerySetData();
  3535. },
  3536. mounted() {
  3537. this.token = JSON.parse(localStorage.getItem('userinif')).token;
  3538. this.userId = JSON.parse(localStorage.getItem('userinif')).userInfo.userId;
  3539. this.value = JSON.parse(localStorage.getItem('sgvalue'))
  3540. this.GetEnterExitCostDataSource();
  3541. // this.GetNationalTravelFeeData();
  3542. },
  3543. destroyed() {
  3544. window.localStorage.removeItem('sgvalue');
  3545. },
  3546. }
  3547. </script>
  3548. <style>
  3549. /* .el-message-box__status {
  3550. color: greenyellow;
  3551. } */
  3552. .Entry-all {
  3553. background-color: #fff;
  3554. padding: 10px;
  3555. box-shadow: 0 0 5px #0005;
  3556. border-radius: 10px;
  3557. height: 100%;
  3558. min-height: 830px;
  3559. }
  3560. .Entry-head-li label {
  3561. color: #606266;
  3562. font-size: 15px;
  3563. font-weight: 600;
  3564. }
  3565. .Entry-head {
  3566. display: flex;
  3567. justify-content: space-between;
  3568. }
  3569. .Entry-form {
  3570. margin-top: 10px;
  3571. border-top: 2px solid #409EFF;
  3572. }
  3573. .Entry-li-inif {
  3574. display: flex;
  3575. align-items: center;
  3576. width: 100%;
  3577. border-top: 1px solid #ebeef5;
  3578. padding: 5px 0;
  3579. }
  3580. .Entry-li-inif:last-child {
  3581. border-bottom: 1px solid #ebeef5;
  3582. }
  3583. .Entry-li-lable {
  3584. display: flex;
  3585. justify-content: space-between;
  3586. align-items: center;
  3587. margin: 10px 0;
  3588. margin-top: 20px;
  3589. }
  3590. .Entry-li-lables {
  3591. display: flex;
  3592. align-items: center;
  3593. margin: 10px 0;
  3594. margin-top: 20px;
  3595. }
  3596. .Entry-inif-box .depipt {
  3597. display: inline-block;
  3598. width: 240px;
  3599. }
  3600. .Entry-inif-box {
  3601. margin-right: 20px;
  3602. }
  3603. .Entry-li-inif label {
  3604. font-size: 14px;
  3605. color: #606266;
  3606. }
  3607. .Entry-form .redzhu {
  3608. margin-left: 25px;
  3609. font-size: 14px;
  3610. color: red;
  3611. }
  3612. .sub-boxs {
  3613. -ms-user-select: none;
  3614. -khtml-user-select: none;
  3615. -webkit-user-select: none;
  3616. -moz-user-select: none;
  3617. font-size: 12px;
  3618. font-family: "微软雅黑";
  3619. user-select: none;
  3620. background-color: #FFF;
  3621. background-image: none;
  3622. border-radius: 4px;
  3623. border: 1px solid #DCDFE6;
  3624. -webkit-box-sizing: border-box;
  3625. box-sizing: border-box;
  3626. color: #606266;
  3627. display: inline-block;
  3628. height: 28px;
  3629. line-height: 28px;
  3630. outline: 0;
  3631. padding: 0 15px;
  3632. -webkit-transition: border-color .2s cubic-bezier(.645, .045, .355, 1);
  3633. transition: border-color .2s cubic-bezier(.645, .045, .355, 1);
  3634. }
  3635. .btn-Entry {
  3636. text-align: right;
  3637. }
  3638. .Entry-all .el-checkbox__inner {
  3639. width: 18px;
  3640. height: 18px;
  3641. margin-right: 10px;
  3642. }
  3643. .Entry-all .el-checkbox__inner::after {
  3644. height: 10px;
  3645. left: 6px;
  3646. }
  3647. .Entry-all .el-table th.el-table__cell>.cell {
  3648. text-align: center;
  3649. }
  3650. .Entry-all .el-button+.el-button{
  3651. margin-left: 0px;
  3652. }
  3653. .Entry-all .permissionsbox .el-checkbox-group{
  3654. display: flex;
  3655. flex-wrap: wrap;
  3656. justify-content: space-between;
  3657. }
  3658. .Entry-all .permissionsbox .el-checkbox{
  3659. width: 150px;
  3660. margin-right: 0;
  3661. }
  3662. .custom-tooltip-style {
  3663. max-width: 400px;
  3664. white-space: pre-line; /* 保留换行符 */
  3665. font-size: 13px;
  3666. line-height: 25px;
  3667. color: #606266;
  3668. }
  3669. .jiaotongfei-ul{
  3670. margin-top: 20px;
  3671. display: flex;
  3672. justify-content: space-between;
  3673. }
  3674. .jiaotongfei-li{
  3675. width: 32.5%;
  3676. }
  3677. .inputNumberClass[class-unit] {
  3678. --el-input-number-unit-offset-x: 35px;
  3679. position: relative;
  3680. }
  3681. .inputNumberClass[class-unit]::after {
  3682. content: attr(class-unit);
  3683. height: 100%;
  3684. display: flex;
  3685. align-items: center;
  3686. position: absolute;
  3687. top: 0;
  3688. right: 5px;
  3689. color: #C0C4CC;
  3690. }
  3691. .inputNumberClass[class-unit] .el-input__inner {
  3692. padding-right:25px;
  3693. }
  3694. </style>