Cost.vue 160 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624
  1. <template>
  2. <div class="cost-all" v-loading="costloading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading"
  3. element-loading-background="rgba(0, 0, 0, 0.8)">
  4. <div class="cost-box">
  5. <div class="cost-haed">
  6. <div class="ser-btn">
  7. <div class="ser-btn-li Cost_topFlex" style="display: flex;">
  8. <el-select v-model="diid" filterable placeholder="请选择" @change="groupChange">
  9. <el-option v-for="item in options" :key="item.id" :label="item.groupName" :value="item.id">
  10. <span v-if="item.isTrue == 'True'" style="color:green">{{ item.groupName }}</span>
  11. <span v-else style="color:gray">{{ item.groupName }}</span>
  12. </el-option>
  13. </el-select>
  14. <div style="line-height: 40px;width: 90px;text-align: right;padding-right: 12px;">
  15. 分段类型:
  16. </div>
  17. <el-select v-model="costTypevalue" placeholder="请选择" @change="costTypeSelect">
  18. <el-option v-for="item in costType" :key="item.value" :label="item.label" :value="item.value">
  19. </el-option>
  20. </el-select>
  21. </div>
  22. <div class="ser-btn-li">
  23. <el-button type="primary">导入收款账单</el-button>
  24. <el-button type="primary">生成收款账单</el-button>
  25. <el-button type="primary">导出客户报表</el-button>
  26. <el-button type="primary">导出成本</el-button>
  27. <el-button type="primary" @click="save">保存设置</el-button>
  28. <el-button type="primary">一键复制</el-button>
  29. <el-button type="primary">成本通知</el-button>
  30. </div>
  31. </div>
  32. <div class="cost-input">
  33. <el-form :inline="true" class="demo-form-inline" :model='AGroupCostParameter' ref="inputs"
  34. :rules="rules">
  35. <el-form-item label="税率:" prop="tax">
  36. <el-input v-model="AGroupCostParameter.tax" placeholder="税率"></el-input>
  37. </el-form-item>
  38. <el-form-item label="货币:">
  39. <el-select v-model="AGroupCostParameter.currency" placeholder="请选择">
  40. <el-option v-for="item in currencyOption" :key="item.value" :label="item.label"
  41. :value="item.value">
  42. </el-option>
  43. </el-select>
  44. </el-form-item>
  45. <el-form-item label="汇率:" prop="rate">
  46. <el-input v-model="AGroupCostParameter.rate" placeholder="汇率"></el-input>
  47. </el-form-item>
  48. </el-form>
  49. <div v-show="costTypevalue == 'A'">
  50. <el-form :inline="true" class="demo-form-inline" :rules="HotelRules" ref="DHotel"
  51. :model="costTypeHotelNumbers.filter(item => item.type == 'Default')[0]">
  52. <el-form-item label="TBR:" prop="tbr">
  53. <el-input
  54. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'Default')[0].tbr"
  55. placeholder="TBR"><i slot="suffix"
  56. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  57. </el-form-item>
  58. <el-form-item label="SGR:" prop="sgr">
  59. <el-input
  60. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'Default')[0].sgr"
  61. placeholder="SGR"><i slot="suffix"
  62. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  63. </el-form-item>
  64. <el-form-item label="JS/ES:" prop="jses">
  65. <el-input
  66. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'Default')[0].jses"
  67. placeholder="JS/ES"><i slot="suffix"
  68. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  69. </el-form-item>
  70. <el-form-item label="SUITE:" prop="suite">
  71. <el-input
  72. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'Default')[0].suite"
  73. placeholder="SUITE"><i slot="suffix"
  74. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  75. </el-form-item>
  76. </el-form>
  77. </div>
  78. <div v-show="costTypevalue == 'B'" class="CostBShow">
  79. <el-row>
  80. <el-form ref="Asection" :inline="true" class="demo-form-inline" :rules="CostTimeRules"
  81. :model="AGroupCostParameter">
  82. <el-col :span="5">
  83. <div> <el-form-item label="第一段开始时间:" prop="costTypeStartTime">
  84. <el-date-picker v-model="AGroupCostParameter.costTypeStartTime" type="date"
  85. placeholder="第一段开始时间" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd">
  86. </el-date-picker>
  87. </el-form-item>
  88. </div>
  89. </el-col>
  90. <el-col :span="4">
  91. <div> <el-form-item label="结束时间:" prop="costTypeendTime"><el-date-picker
  92. v-model="AGroupCostParameter.costTypeendTime" type="date" placeholder="结束时间"
  93. format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd">
  94. </el-date-picker>
  95. </el-form-item>
  96. </div>
  97. </el-col>
  98. <el-col :span="3">
  99. <div>
  100. <el-form-item label="人数:" prop="costTypenumber"><el-input placeholder="人数"
  101. v-model.number="AGroupCostParameter.costTypenumber" clearable>
  102. </el-input>
  103. </el-form-item>
  104. </div>
  105. </el-col>
  106. </el-form>
  107. <el-form ref="AHotel" :inline="true" class="demo-form-inline" :rules="HotelRules"
  108. :model="costTypeHotelNumbers.filter(item => item.type == 'A')[0]">
  109. <el-col :span="3">
  110. <div><el-form-item label="TBR:" prop="tbr">
  111. <el-input
  112. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'A')[0].tbr"
  113. placeholder="TBR"><i slot="suffix"
  114. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  115. </el-form-item></div>
  116. </el-col>
  117. <el-col :span="3">
  118. <div> <el-form-item label="SGR:" prop="sgr">
  119. <el-input
  120. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'A')[0].sgr"
  121. placeholder="SGR"><i slot="suffix"
  122. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  123. </el-form-item></div>
  124. </el-col>
  125. <el-col :span="3">
  126. <div><el-form-item label="JS/ES:" prop="jses">
  127. <el-input
  128. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'A')[0].jses"
  129. placeholder="JS/ES"><i slot="suffix"
  130. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  131. </el-form-item></div>
  132. </el-col>
  133. <el-col :span="3">
  134. <div><el-form-item label="SUITE:" prop="suite">
  135. <el-input
  136. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'A')[0].suite"
  137. placeholder="SUITE"><i slot="suffix"
  138. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  139. </el-form-item></div>
  140. </el-col>
  141. </el-form>
  142. </el-row>
  143. <el-row>
  144. <el-form ref="Bsection" :inline="true" class="demo-form-inline" :rules="CostTimeRules"
  145. :model="BGroupCostParameter">
  146. <el-col :span="5">
  147. <div> <el-form-item label="第二段开始时间:" prop="costTypeStartTime">
  148. <el-date-picker v-model="BGroupCostParameter.costTypeStartTime" type="date"
  149. placeholder="第二段开始时间" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd">
  150. </el-date-picker>
  151. </el-form-item>
  152. </div>
  153. </el-col>
  154. <el-col :span="4">
  155. <div> <el-form-item label="结束时间:" prop="costTypeendTime"><el-date-picker
  156. v-model="BGroupCostParameter.costTypeendTime" type="date" placeholder="结束时间"
  157. format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd">
  158. </el-date-picker>
  159. </el-form-item>
  160. </div>
  161. </el-col>
  162. <el-col :span="3">
  163. <div>
  164. <el-form-item label="人数:" prop="costTypenumber"><el-input placeholder="人数"
  165. v-model.number="BGroupCostParameter.costTypenumber" clearable>
  166. </el-input>
  167. </el-form-item>
  168. </div>
  169. </el-col>
  170. </el-form>
  171. <el-form ref="BHotel" :inline="true" class="demo-form-inline" :rules="HotelRules"
  172. :model="costTypeHotelNumbers.filter(item => item.type == 'B')[0]">
  173. <el-col :span="3">
  174. <div>
  175. <el-form-item label="TBR:" prop="tbr">
  176. <el-input
  177. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'B')[0].tbr"
  178. placeholder="TBR"><i slot="suffix"
  179. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  180. </el-form-item>
  181. </div>
  182. </el-col>
  183. <el-col :span="3">
  184. <div> <el-form-item label="SGR:" prop="sgr">
  185. <el-input
  186. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'B')[0].sgr"
  187. placeholder="SGR"><i slot="suffix"
  188. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  189. </el-form-item></div>
  190. </el-col>
  191. <el-col :span="3">
  192. <div><el-form-item label="JS/ES:" prop="jses">
  193. <el-input
  194. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'B')[0].jses"
  195. placeholder="JS/ES"><i slot="suffix"
  196. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  197. </el-form-item></div>
  198. </el-col>
  199. <el-col :span="3">
  200. <div><el-form-item label="SUITE:" prop="suite">
  201. <el-input
  202. v-model.number="costTypeHotelNumbers.filter(item => item.type == 'B')[0].suite"
  203. placeholder="SUITE"><i slot="suffix"
  204. style="font-style:normal;margin-right: 10px;">间</i></el-input>
  205. </el-form-item></div>
  206. </el-col>
  207. </el-form>
  208. </el-row>
  209. </div>
  210. </div>
  211. <div class="cost-info">
  212. <div class="cost-info-li">
  213. <label>团 号:</label>
  214. <span>{{ grouptitleinfo.tourCode }}</span>
  215. </div>
  216. <div class="cost-info-li">
  217. <label>客 户:</label>
  218. <span>{{ grouptitleinfo.clientName }}</span>
  219. </div>
  220. <div class="cost-info-li">
  221. <label>出访国家:</label>
  222. <span>{{ grouptitleinfo.visitCountry }}</span>
  223. </div>
  224. <div class="cost-info-li">
  225. <label>起止日期:</label>
  226. <span>{{ grouptitleinfo.visitStartDate }} -
  227. {{ grouptitleinfo.visitEndDate
  228. }}</span>
  229. </div>
  230. <div class="cost-info-li">
  231. <label>天数/人数:</label>
  232. <span>{{ grouptitleinfo.visitDays }}天/{{ grouptitleinfo.visitPNumber }}人</span>
  233. </div>
  234. </div>
  235. </div>
  236. <div style="color: #606266;font-size: 15px;font-weight: 600;">请选择要显示的项:</div>
  237. <el-checkbox-group class="form-ss" v-model="CheckBoxListSelect.filter(item => item.cbType == 'Top')[0].cbValues"
  238. @change="TopChange">
  239. <el-checkbox v-for="( item, index ) in checkOptions " :key="index" :title="item.tips"
  240. :label="item.label"></el-checkbox>
  241. </el-checkbox-group>
  242. <el-table :summary-method="getSummaries" show-summary :data="tableData" :border="true" size="small"
  243. row-class-name="row" cell-class-name="column" :highlight-current-row="true" :fit="true"
  244. :height="centerheight">
  245. <template v-for="( item, index ) in tableLabel ">
  246. <el-table-column :key="index" :prop="item.prop" :width="item.width == 150 ? columnWidth : item.width"
  247. :label="item.label"
  248. v-if="CheckBoxListSelect.filter(item => item.cbType == 'Top')[0].cbValues.includes(item.label)">
  249. <!-- eslint-disable-next-line -->
  250. <template slot="header" slot-scope="scope">
  251. <el-tooltip effect="dark" :content="item.describe" placement="top">
  252. <span class="rapAddress">{{ item.label }}</span>
  253. </el-tooltip>
  254. </template>
  255. <template slot-scope="scope">
  256. <div v-if="item.prop === 'sales'">
  257. <el-input :ref="'el-input-' + index" v-model="scope.row[item.prop]" show-word-limit />
  258. </div>
  259. <div v-else-if="item.prop === 'day'">
  260. <el-input :ref="'el-input-' + index" v-model="scope.row[item.prop]" type="number" min="0"
  261. @change="NumberSetTime(scope.row[item.prop], scope.$index)" />
  262. </div>
  263. <div v-else-if="item.prop === 'sale'">
  264. <el-row class="figures-btn">
  265. <el-button @click="handleEdit(scope.$index, scope.row, 1)" size="mini"
  266. type="primary">司兼导</el-button>
  267. <el-button @click="handleEdit(scope.$index, scope.row, 2)" size="mini" type="primary">导
  268. 游</el-button>
  269. <el-button @click="handleEdit(scope.$index, scope.row, 3)" size="mini"
  270. type="primary">车数据</el-button>
  271. <el-button @click="handleEdit(scope.$index, scope.row, 4)" size="mini" type="primary">景
  272. 点</el-button>
  273. </el-row>
  274. </div>
  275. <div v-else-if="item.width == 200">
  276. <el-input type="textarea" :rows="5" placeholder="请输入内容" v-model="scope.row[item.prop]">
  277. </el-input>
  278. </div>
  279. <span v-else :title="scope.row[item.prop]"><el-input placeholder="请输入内容"
  280. v-model="scope.row[item.prop]" clearable>
  281. </el-input></span>
  282. </template>
  283. </el-table-column>
  284. </template>
  285. <el-table-column label="操作" :width="200">
  286. <!-- eslint-disable-next-line -->
  287. <template slot-scope="scope">
  288. <el-button size="mini" @click="handleDelete(scope.$index, scope.row, tableData)" type="danger"><i
  289. class="el-icon-delete"></i></el-button>
  290. </template>
  291. </el-table-column>
  292. </el-table>
  293. <div style="text-align: center;padding: 10px 0;"><el-button @click="addStrip" type="primary">添 加 <i
  294. class="el-icon-plus"></i></el-button></div>
  295. <div class="sheet-box">
  296. <div class="sheet-li">
  297. <div style="color: #606266;font-size: 15px;font-weight: 600;">请选择要显示的项:</div>
  298. <el-checkbox-group v-model="CheckBoxListSelect.filter(item => item.cbType == 'Left')[0].cbValues">
  299. <el-checkbox v-for="( item, index ) in sheetoneOptions " :key="index"
  300. :label="item"></el-checkbox>
  301. </el-checkbox-group>
  302. <div style="display: flex;">
  303. <div :style="{ 'width': costTypevalue == 'A' ? '100%' : '49%' }">
  304. <div v-for="( sheetitem, index ) in sheetDatal " :key="index">
  305. <div class="biaoge"
  306. v-if="CheckBoxListSelect.filter(item => item.cbType == 'Left')[0].cbValues.includes(sheetitem.label)">
  307. <el-table :data="[{ a: 1 }]" border style="width: 100%">
  308. <el-table-column v-for="( itemsheetone, index ) in sheetitem.childList "
  309. :key="index" :prop="itemsheetone.prop" :label="itemsheetone.childLabel">
  310. <template slot-scope="scope">
  311. <div v-if="itemsheetone.prop.indexOf(sheetitem.EnLabel) != -1">
  312. <div v-if="itemsheetone.isBind">
  313. {{ AGroupCostParameter[itemsheetone.prop] }}
  314. </div>
  315. <div v-else>
  316. <el-input v-model="AGroupCostParameter[itemsheetone.prop]"
  317. show-word-limit />
  318. </div>
  319. </div>
  320. <div v-else-if="itemsheetone.prop === 'ZCB'">
  321. {{ calculateZCB(sheetitem.EnLabel) }}
  322. </div>
  323. <div v-else-if="itemsheetone.prop === 'DRBJ'">
  324. {{ calculateDRBJ(sheetitem.EnLabel) }}
  325. </div>
  326. <div v-else-if="itemsheetone.prop === 'ZBJ'">
  327. {{ calculateZBJ(sheetitem.EnLabel) }}
  328. </div>
  329. <div v-else-if="itemsheetone.prop === 'DRLR'">
  330. {{ calculateDRLR(sheetitem.EnLabel) }}
  331. </div>
  332. <div v-else-if="itemsheetone.prop === 'ZLR'">
  333. {{ calculateZLR(sheetitem.EnLabel) }}
  334. </div>
  335. <!-- 绑定对象属性的值 -->
  336. </template>
  337. </el-table-column>
  338. </el-table>
  339. </div>
  340. </div>
  341. </div>
  342. <div style="width: 2%;" v-show="costTypevalue != 'A'"></div>
  343. <div style="width: 49%;" v-show="costTypevalue != 'A'">
  344. <div v-for="( sheetitem, index ) in sheetDatal " :key="index">
  345. <div class="biaoge"
  346. v-if="CheckBoxListSelect.filter(item => item.cbType == 'Left')[0].cbValues.includes(sheetitem.label)">
  347. <el-table :data="[{ a: 1 }]" border style="width: 100%"
  348. :class="{ 'hiddenElement': (sheetitem.EnLabel == 'visa' || sheetitem.EnLabel == 'bx') ? true : false }">
  349. <el-table-column v-for="( itemsheetone, index ) in sheetitem.childList "
  350. :key="index" :prop="itemsheetone.prop" :label="itemsheetone.childLabel">
  351. <template slot-scope="scope">
  352. <div v-if="itemsheetone.prop.indexOf(sheetitem.EnLabel) != -1">
  353. <div v-if="itemsheetone.isBind">
  354. {{ BGroupCostParameter[itemsheetone.prop] }}
  355. </div>
  356. <div v-else>
  357. <el-input v-model="BGroupCostParameter[itemsheetone.prop]"
  358. show-word-limit />
  359. </div>
  360. </div>
  361. <div v-else-if="itemsheetone.prop === 'ZCB'">
  362. {{ BcalculateZCB(sheetitem.EnLabel) }}
  363. </div>
  364. <div v-else-if="itemsheetone.prop === 'DRBJ'">
  365. {{ BcalculateDRBJ(sheetitem.EnLabel) }}
  366. </div>
  367. <div v-else-if="itemsheetone.prop === 'ZBJ'">
  368. {{ BcalculateZBJ(sheetitem.EnLabel) }}
  369. </div>
  370. <div v-else-if="itemsheetone.prop === 'DRLR'">
  371. {{ BcalculateDRLR(sheetitem.EnLabel) }}
  372. </div>
  373. <div v-else-if="itemsheetone.prop === 'ZLR'">
  374. {{ BcalculateZLR(sheetitem.EnLabel) }}
  375. </div>
  376. <!-- 绑定对象属性的值 -->
  377. </template>
  378. </el-table-column>
  379. </el-table>
  380. </div>
  381. </div>
  382. </div>
  383. </div>
  384. </div>
  385. </div>
  386. <div class="cabin-box">
  387. <div class="cabin-li">
  388. <div style="color: #606266;font-size: 15px;font-weight: 600;">请选择要显示的项:</div>
  389. <el-checkbox-group v-model="CheckBoxListSelect.filter(item => item.cbType == 'Right')[0].cbValues">
  390. <el-checkbox v-for="( item, index ) in cabinoneOptions " :key="index"
  391. :label="item"></el-checkbox>
  392. </el-checkbox-group>
  393. <div style="display: flex;">
  394. <div :style="{ 'width': costTypevalue == 'A' ? '100%' : '49%' }">
  395. <div v-for="( cabinitem, index ) in cabinDatal " :key="index">
  396. <div class="biaoge"
  397. v-if="CheckBoxListSelect.filter(item => item.cbType == 'Right')[0].cbValues.includes(cabinitem.label)">
  398. <div style=" color: rgb(96, 98, 102);font-size: 15px;font-weight: 600;">{{
  399. cabinitem.label }}
  400. </div>
  401. <el-table :data="cabinitem.sheetInfo" border style="width: 100%">
  402. <el-table-column v-for="( itemcabinone, index ) in cabinitem.childList "
  403. :key="index" :prop="itemcabinone.prop" :label="itemcabinone.childLabel">
  404. <template slot-scope="scope">
  405. <div v-if="itemcabinone.prop === 'toll'">
  406. <el-input :ref="'el-input-' + index"
  407. v-model="scope.row[itemcabinone.prop]" show-word-limit disabled />
  408. </div>
  409. <span
  410. v-else-if="itemcabinone.prop === 'costPerson' || itemcabinone.prop === 'singleQuote'"
  411. :title="scope.row[itemcabinone.prop]">{{
  412. scope.row[itemcabinone.prop]
  413. }}</span>
  414. <span v-else-if="itemcabinone.prop === 'totalCost'"
  415. :title="scope.row[itemcabinone.prop]">{{
  416. (scope.row['toll'] * scope.row['costPerson']).toFixed(2)
  417. }}</span>
  418. <span v-else-if="itemcabinone.prop === 'totalQuote'"
  419. :title="scope.row[itemcabinone.prop]">{{
  420. (scope.row['toll'] * scope.row['singleQuote']).toFixed(2)
  421. }}</span>
  422. <span v-else-if="itemcabinone.prop === 'singleProfit'"
  423. :title="scope.row[itemcabinone.prop]">{{
  424. ((scope.row['singleQuote'] - scope.row['costPerson'])).toFixed(2)
  425. }}</span>
  426. <span v-else-if="itemcabinone.prop === 'totalProfit'"
  427. :title="scope.row[itemcabinone.prop]">{{
  428. ((scope.row['singleQuote'] - scope.row['costPerson']) *
  429. scope.row['toll']).toFixed(2)
  430. }}</span>
  431. <span v-else :title="scope.row[itemcabinone.prop]">{{
  432. scope.row[itemcabinone.prop]
  433. }}</span>
  434. </template>
  435. </el-table-column>
  436. </el-table>
  437. </div>
  438. </div>
  439. </div>
  440. <div style="width: 2%;" v-show="costTypevalue != 'A'"></div>
  441. <div style="width: 49%;" v-show="costTypevalue != 'A'">
  442. <div v-for="( cabinitem, index ) in BcabinDatal " :key="index">
  443. <div class="biaoge"
  444. v-if="CheckBoxListSelect.filter(item => item.cbType == 'Right')[0].cbValues.includes(cabinitem.label)">
  445. <div style=" color: rgb(96, 98, 102);font-size: 15px;font-weight: 600;">{{
  446. cabinitem.label }}
  447. </div>
  448. <el-table :data="cabinitem.sheetInfo" border style="width: 100%">
  449. <el-table-column v-for="( itemcabinone, index ) in cabinitem.childList "
  450. :key="index" :prop="itemcabinone.prop" :label="itemcabinone.childLabel">
  451. <template slot-scope="scope">
  452. <div v-if="itemcabinone.prop === 'toll'">
  453. <el-input :ref="'el-input-' + index"
  454. v-model="scope.row[itemcabinone.prop]" show-word-limit disabled />
  455. </div>
  456. <span
  457. v-else-if="itemcabinone.prop === 'costPerson' || itemcabinone.prop === 'singleQuote'"
  458. :title="scope.row[itemcabinone.prop]">{{
  459. scope.row[itemcabinone.prop]
  460. }}</span>
  461. <span v-else-if="itemcabinone.prop === 'totalCost'"
  462. :title="scope.row[itemcabinone.prop]">{{
  463. (scope.row['toll'] * scope.row['costPerson']).toFixed(2)
  464. }}</span>
  465. <span v-else-if="itemcabinone.prop === 'totalQuote'"
  466. :title="scope.row[itemcabinone.prop]">{{
  467. (scope.row['toll'] * scope.row['singleQuote']).toFixed(2)
  468. }}</span>
  469. <span v-else-if="itemcabinone.prop === 'singleProfit'"
  470. :title="scope.row[itemcabinone.prop]">{{
  471. (scope.row['singleQuote'] - scope.row['costPerson']).toFixed(2)
  472. }}</span>
  473. <span v-else-if="itemcabinone.prop === 'totalProfit'"
  474. :title="scope.row[itemcabinone.prop]">{{
  475. ((scope.row['singleQuote'] - scope.row['costPerson']) *
  476. scope.row['toll']).toFixed(2)
  477. }}</span>
  478. <span v-else :title="scope.row[itemcabinone.prop]">{{
  479. scope.row[itemcabinone.prop]
  480. }}</span>
  481. </template>
  482. </el-table-column>
  483. </el-table>
  484. </div>
  485. </div>
  486. </div>
  487. </div>
  488. </div>
  489. </div>
  490. </div>
  491. <el-dialog :title="DialogTitle" :visible.sync="outerVisible" :width="'60%'" :close-on-click-modal="false">
  492. <div>
  493. <div style="display: flex;">
  494. <div style="width: 30%;">
  495. <el-input v-model="dialogSearchInput" placeholder="请输入城市名称"></el-input>
  496. </div>
  497. <div style="width: 2%;"></div>
  498. <!-- <div><el-button type="primary" @click="dialogSearchMethon">搜索</el-button></div> -->
  499. </div>
  500. <br />
  501. <el-table ref="singleTable" border @current-change="SelChange"
  502. :data="filterdialogSearchInput.slice((currentPage - 1) * pageSize, currentPage * pageSize)"
  503. highlight-current-row style="width: 100%">
  504. <el-table-column v-for=" item, index in SeldialogColumn " :key="index" :prop="item.prop"
  505. :label="item.title">
  506. <template slot-scope="scope">
  507. <div>
  508. {{ scope.row[item.prop] }}
  509. </div>
  510. </template>
  511. </el-table-column>
  512. </el-table>
  513. <div class="block">
  514. <el-pagination align='center' @current-change="handleCurrentChange" :current-page="currentPage"
  515. :page-sizes="[5, 10]" :page-size="pageSize" layout="total, sizes, prev, pager, next"
  516. @size-change="handleSizeChange" :total="filterdialogSearchInput.length">
  517. </el-pagination>
  518. </div>
  519. </div>
  520. <!-- <el-dialog width="30%" title="内层 Dialog" :visible.sync="innerVisible" append-to-body>
  521. </el-dialog> -->
  522. <!-- <div slot="footer" class="dialog-footer">
  523. <el-button @click="outerVisible = false">取 消</el-button>
  524. <el-button type="primary" @click="innerVisible = true">打开内层 Dialog</el-button>
  525. </div> -->
  526. <div slot="footer" class="dialog-footer">
  527. <el-button @click="outerVisible = false">取 消</el-button>
  528. <el-button type="primary" @click="outerVisible = false">确定</el-button>
  529. </div>
  530. </el-dialog>
  531. </div>
  532. </template>
  533. <script>
  534. export default {
  535. data() {
  536. return {
  537. costloading: true,
  538. outerVisible: false,
  539. innerVisible: false,
  540. //checkList: ['DAY', 'ITIN', 'VA', 'VF', 'VRD', 'T/G S', 'DATE'], //列表默认选中
  541. checkOptions: [
  542. { label: 'DAY', tips: '时间(DATE)' },
  543. { label: 'DATE', tips: '行程描述(ITINERARY)' },
  544. { label: 'ITIN', tips: '行程描述(ITINERARY)' },
  545. { label: 'VA', tips: '车服务区域(Vehicle Area)' },
  546. { label: 'VT', tips: '车型(VEHICLE TYPE)' },
  547. { label: 'VF', tips: '车费用(VEHICLE FEES)' },
  548. { label: 'VN', tips: '车数量(VEHICLE Number)' },
  549. { label: 'VRD', tips: '用车时间(VEHICLE RENTAL DURATION)' },
  550. { label: 'T/G S', tips: '导游工资(TOUR GUIDE SALARY)' },
  551. { label: 'T/G N', tips: '导游数量(TOUR GUIDE Number)' },
  552. { label: 'T/G WH', tips: '导游工作时间(导游工作时间)' },
  553. { label: 'T/G OF', tips: '导游超时费用(TOUR GUIDE OVERTIME FEES)' },
  554. { label: 'T/G M', tips: '导游餐补(TOUR GUIDE MEALS)' },
  555. { label: 'T/G A', tips: '导游房补(TOUR GUIDE ACCOMMODATION)' },
  556. { label: 'T/G TF', tips: '导游交通费(TOUR GUIDE TRANSPORATION FEES)' },
  557. { label: 'T/G EF', tips: '导游景点费(TOUR GUIDE ENTRANCE FEES)' },
  558. { label: 'C/F M', tips: '司机餐补(CHAUFFEUR MEALS)' },
  559. { label: 'C/F OF', tips: '司机超时费用(CHAUFFEUR OVERTIME FEES)' },
  560. { label: 'B', tips: '早餐(BREAKFAST) #个人成本' },
  561. { label: 'L', tips: '午餐(LUNCH) #个人成本' },
  562. { label: 'D', tips: '晚餐(DINNER) #个人成本' },
  563. { label: 'TBR', tips: '双人间(TWIN BED ROOM) #个人成本' },
  564. { label: 'SGR', tips: '单间(SINGLE ROOM) #个人成本' },
  565. { label: 'JS/ES', tips: '小套房/豪华套房(JUNIOR SUITE/EXECUTIVE SUITE) #个人成本' },
  566. { label: 'SUITE', tips: '套房(SUITE) #个人成本' },
  567. { label: 'ACCO N', tips: '住宿地名称(ACCOMMODATION NAME)' },
  568. { label: 'T/V', tips: '公务活动费用(T/V)' },
  569. { label: '1/L', tips: '公务活动费用(1/L)' },
  570. { label: 'I/F', tips: '公务翻译费用(INTERPRETER FEES)' },
  571. { label: 'EF', tips: '景点门票(ENTRANCE FEE) #个人成本' },
  572. { label: 'B/R/F', tips: '饮料零食水果(BEVERAGE/RRESHMENT/FRUIT)' },
  573. { label: 'TE', tips: '出行物资(TRAVELLLING ESSENTIALS) #个人成本' },
  574. { label: 'T/G T', tips: '导游小费(T/G TIPS) #个人成本' },
  575. { label: 'DRV T', tips: '司机小费(DRIVER TIPS #个人成本)' },
  576. { label: 'P/C', tips: '零用金(PETTY CASH) #个人成本' },
  577. { label: 'T/L F', tips: '领队费(TOUR LEADER FEES)' },
  578. { label: 'E/C T', tips: '会务费(EXPO/CONFERENCE TICKET)' }
  579. ],
  580. tableLabel: [
  581. { label: 'DAY', width: '90', prop: 'day', describe: '天数(DAY)' },
  582. { label: 'DATE', width: '150', prop: 'date', describe: '时间(DATE)' },
  583. { label: 'ITIN', width: '200', prop: 'itin', describe: '行程描述(ITINERARY)' },
  584. { label: 'VA', width: '85', prop: 'sale', describe: '车服务区域(Vehicle Area)' }, // ??????????????
  585. { label: 'VT', width: '200', prop: 'carType', describe: '车型(VEHICLE TYPE)' },
  586. { label: 'VF', width: '150', prop: 'carCost', describe: '车费用(VEHICLE FEES)' },
  587. { label: 'VN', width: '150', prop: 'carNumber', describe: '车数量(VEHICLE Number)' },
  588. { label: 'VRD', width: '150', prop: 'carTiming', describe: '用车时间(VEHICLE RENTAL DURATION)' },
  589. { label: 'T/G S', width: '150', prop: 'tgs', describe: '导游工资(TOUR GUIDE SALARY)' },
  590. { label: 'T/G N', width: '150', prop: 'tgn', describe: '导游数量(TOUR GUIDE Number' },
  591. { label: 'T/G WH', width: '150', prop: 'tgwh', describe: '导游工作时间(导游工作时间)' },
  592. { label: 'T/G OF', width: '150', prop: 'tgof', describe: '导游超时费用(TOUR GUIDE OVERTIME FEES)' },
  593. { label: 'T/G M', width: '150', prop: 'tgm', describe: '导游餐补(TOUR GUIDE MEALS)' },
  594. { label: 'T/G A', width: '150', prop: 'tga', describe: '导游房补(TOUR GUIDE ACCOMMODATION)' },
  595. { label: 'T/G TF', width: '150', prop: 'tgtf', describe: '导游交通费(TOUR GUIDE TRANSPORATION FEES)' },
  596. { label: 'T/G EF', width: '150', prop: 'tgef', describe: '导游景点费(TOUR GUIDE ENTRANCE FEES)' },
  597. { label: 'C/F M', width: '150', prop: 'cfm', describe: '司机餐补(CHAUFFEUR MEALS)' },
  598. { label: 'C/F OF', width: '150', prop: 'cfof', describe: '司机超时费用(CHAUFFEUR OVERTIME FEES)' },
  599. { label: 'B', width: '150', prop: 'b', describe: '早餐(BREAKFAST) #个人成本' },
  600. { label: 'L', width: '150', prop: 'l', describe: '午餐(LUNCH) #个人成本' },
  601. { label: 'D', width: '150', prop: 'd', describe: '晚餐(DINNER) #个人成本' },
  602. { label: 'TBR', width: '150', prop: 'tbr', describe: '双人间(TWIN BED ROOM) #个人成本' },
  603. { label: 'SGR', width: '150', prop: 'sgr', describe: '单间(SINGLE ROOM) #个人成本' },
  604. { label: 'JS/ES', width: '150', prop: 'jS_ES', describe: '小套房/豪华套房(JUNIOR SUITE/EXECUTIVE SUITE) #个人成本' },
  605. { label: 'SUITE', width: '150', prop: 'suite', describe: '套房(SUITE) #个人成本' },
  606. { label: 'ACCO N', width: '200', prop: 'accon', describe: '住宿地名称(ACCOMMODATION NAME)' },
  607. { label: 'T/V', width: '150', prop: 'tv', describe: '公务活动费用(T/V)' },
  608. { label: '1/L', width: '150', prop: 'iL', describe: '邀请函相关费用(1/L)' },
  609. { label: 'I/F', width: '150', prop: 'if', describe: '公务翻译费用(INTERPRETER FEES)' },
  610. { label: 'EF', width: '150', prop: 'ef', describe: '景点门票(ENTRANCE FEE) #个人成本' },
  611. { label: 'B/R/F', width: '150', prop: 'b_R_F', describe: '饮料零食水果(BEVERAGE/RRESHMENT/FRUIT)' },
  612. { label: 'TE', width: '150', prop: 'te', describe: '出行物资(TRAVELLLING ESSENTIALS) #个人成本' },
  613. { label: 'T/G T', width: '150', prop: 'tgTips', describe: '导游小费(T/G TIPS) #个人成本' },
  614. { label: 'DRV T', width: '150', prop: 'drvTips', describe: '司机小费(DRIVER TIPS #个人成本)' },
  615. { label: 'P/C', width: '150', prop: 'pc', describe: '零用金(PETTY CASH) #个人成本' },
  616. { label: 'T/L F', width: '150', prop: 'tlf', describe: '领队费(TOUR LEADER FEES)' },
  617. { label: 'E/C T', width: '150', prop: 'ect', describe: '会务费(EXPO/CONFERENCE TICKET)' }
  618. ],
  619. statisticsArr: [
  620. { label: 'DAY', total: '', individual: '' },
  621. { label: 'DATE', total: '', individual: '' },
  622. { label: 'ITIN', total: '', individual: '' },
  623. { label: 'VA', total: '', individual: '' },
  624. { label: 'VT', total: '', individual: '' },
  625. { label: 'VF', total: '车费', individual: '车费人均' },
  626. { label: 'VN', total: '', individual: '' },
  627. { label: 'VRD', total: '', individual: '' },
  628. { label: 'T/G S', total: '导游工资', individual: '导游工资人均' },
  629. { label: 'T/G N', total: '', individual: '' },
  630. { label: 'T/G WH', total: '', individual: '' },
  631. { label: 'T/G OF', total: '', individual: '' },
  632. { label: 'T/G M', total: '', individual: '' },
  633. { label: 'T/G A', total: '', individual: '' },
  634. { label: 'T/G TF', total: '', individual: '' }
  635. ],
  636. tableData: [], //列表数据
  637. options: [],
  638. diid: '',
  639. currencyOption: [{
  640. value: 'CNY',
  641. label: 'CNY'
  642. }, {
  643. value: 'CAD',
  644. label: 'CAD'
  645. }, {
  646. value: 'EGP',
  647. label: 'EGP'
  648. }, {
  649. value: 'EUR',
  650. label: 'EUR'
  651. }, {
  652. value: 'USD',
  653. label: 'USD'
  654. }],
  655. currencyValueL: 'CNY',
  656. formInline: {
  657. user: '',
  658. region: ''
  659. },
  660. //sheetoneList: ['签证', '机票', '核酸检测',],
  661. sheetoneOptions: ['签证', '保险', '机票', '火车票', '船票', '核酸检测', '酒店TBR', '酒店SGR', '酒店JSES', '酒店SUITE', '地接', '公务', '零用金'],
  662. sheetDatal: [
  663. {
  664. label: '签证',
  665. EnLabel: 'visa',
  666. childList: [
  667. {
  668. childLabel: '签证单人成本(CNY)',
  669. prop: 'visaCB'
  670. },
  671. {
  672. childLabel: '人数',
  673. prop: 'visaRS'
  674. },
  675. {
  676. childLabel: '签证系数',
  677. prop: 'visaXS'
  678. },
  679. {
  680. childLabel: '签证总成本(CNY)',
  681. prop: 'ZCB'
  682. },
  683. {
  684. childLabel: '签证单人报价(CNY)',
  685. prop: 'DRBJ' // 系数 * 单价
  686. },
  687. {
  688. childLabel: '签证总报价(CNY)',
  689. prop: 'ZBJ' // 系数 * 单价 * 人数
  690. },
  691. {
  692. childLabel: '签证单人利润(CNY)',
  693. prop: 'DRLR' //系数 * 单价 - 单价
  694. },
  695. {
  696. childLabel: '签证总利润(CNY)',
  697. prop: 'ZLR' //(系数 * 单价 - 单价) * 人数
  698. },
  699. ],
  700. },
  701. {
  702. label: '保险',
  703. EnLabel: 'bx',
  704. childList: [
  705. {
  706. childLabel: '保险单人成本(CNY)',
  707. prop: 'bxcb'
  708. },
  709. {
  710. childLabel: '人数',
  711. prop: 'bxrs'
  712. },
  713. {
  714. childLabel: '保险系数',
  715. prop: 'bxxs'
  716. },
  717. {
  718. childLabel: '保险总成本(CNY)',
  719. prop: 'ZCB'
  720. },
  721. {
  722. childLabel: '保险单人报价(CNY)',
  723. prop: 'DRBJ'
  724. },
  725. {
  726. childLabel: '保险总报价(CNY)',
  727. prop: 'ZBJ'
  728. },
  729. {
  730. childLabel: '保险单人利润(CNY)',
  731. prop: 'DRLR'
  732. },
  733. {
  734. childLabel: '保险总利润(CNY)',
  735. prop: 'ZLR'
  736. },
  737. ],
  738. },
  739. {
  740. label: '火车票',
  741. EnLabel: 'hcp',
  742. childList: [
  743. {
  744. childLabel: '火车票单人成本(CNY)',
  745. prop: 'hcpcb'
  746. },
  747. {
  748. childLabel: '人数',
  749. prop: 'hcprs'
  750. },
  751. {
  752. childLabel: '火车票系数',
  753. prop: 'hcpxs'
  754. },
  755. {
  756. childLabel: '火车票总成本(CNY)',
  757. prop: 'ZCB'
  758. },
  759. {
  760. childLabel: '火车票单人报价(CNY)',
  761. prop: 'DRBJ'
  762. },
  763. {
  764. childLabel: '火车票总报价(CNY)',
  765. prop: 'ZBJ'
  766. },
  767. {
  768. childLabel: '火车票单人利润(CNY)',
  769. prop: 'DRLR'
  770. },
  771. {
  772. childLabel: '火车票总利润(CNY)',
  773. prop: 'ZLR'
  774. },
  775. ],
  776. },
  777. {
  778. label: '机票',
  779. EnLabel: 'jjc',
  780. childList: [
  781. {
  782. childLabel: '经济舱单人成本(CNY)',
  783. prop: 'jjccb'
  784. },
  785. {
  786. childLabel: '人数',
  787. prop: 'jjcrs'
  788. },
  789. {
  790. childLabel: '经济舱系数',
  791. prop: 'jjcxs'
  792. },
  793. {
  794. childLabel: '经济舱总成本(CNY)',
  795. prop: 'ZCB'
  796. },
  797. {
  798. childLabel: '经济舱单人报价(CNY)',
  799. prop: 'DRBJ'
  800. },
  801. {
  802. childLabel: '经济舱总报价(CNY)',
  803. prop: 'ZBJ'
  804. },
  805. {
  806. childLabel: '经济舱单人利润(CNY)',
  807. prop: 'DRLR'
  808. },
  809. {
  810. childLabel: '经济舱总利润(CNY)',
  811. prop: 'ZLR'
  812. },
  813. ],
  814. },
  815. {
  816. label: '机票',
  817. EnLabel: 'gwc',
  818. childList: [
  819. {
  820. childLabel: '公务舱单人成本(CNY)',
  821. prop: 'gwccb'
  822. },
  823. {
  824. childLabel: '人数',
  825. prop: 'gwcrs'
  826. },
  827. {
  828. childLabel: '公务舱系数',
  829. prop: 'gwcxs'
  830. },
  831. {
  832. childLabel: '公务舱总成本(CNY)',
  833. prop: 'ZCB'
  834. },
  835. {
  836. childLabel: '公务舱单人报价(CNY)',
  837. prop: 'DRBJ'
  838. },
  839. {
  840. childLabel: '公务舱总报价(CNY)',
  841. prop: 'ZBJ'
  842. },
  843. {
  844. childLabel: '公务舱单人利润(CNY)',
  845. prop: 'DRLR'
  846. },
  847. {
  848. childLabel: '公务舱总利润(CNY)',
  849. prop: 'ZLR'
  850. },
  851. ],
  852. },
  853. {
  854. label: '船票',
  855. EnLabel: 'cp',
  856. childList: [
  857. {
  858. childLabel: '船票单人成本(CNY)',
  859. prop: 'cpcb'
  860. },
  861. {
  862. childLabel: '人数',
  863. prop: 'cprs'
  864. },
  865. {
  866. childLabel: '船票系数',
  867. prop: 'cpxs'
  868. },
  869. {
  870. childLabel: '船票总成本(CNY)',
  871. prop: 'ZCB'
  872. },
  873. {
  874. childLabel: '船票单人报价(CNY)',
  875. prop: 'DRBJ'
  876. },
  877. {
  878. childLabel: '船票总报价(CNY)',
  879. prop: 'ZBJ'
  880. },
  881. {
  882. childLabel: '船票单人利润(CNY)',
  883. prop: 'DRLR'
  884. },
  885. {
  886. childLabel: '船票总利润(CNY)',
  887. prop: 'ZLR'
  888. },
  889. ],
  890. },
  891. {
  892. label: '核酸检测',
  893. EnLabel: 'hs',
  894. childList: [
  895. {
  896. childLabel: '核酸检测单人成本(CNY)',
  897. prop: 'hscb'
  898. },
  899. {
  900. childLabel: '人数',
  901. prop: 'hsrs'
  902. },
  903. {
  904. childLabel: '核酸检测系数',
  905. prop: 'hsxs'
  906. },
  907. {
  908. childLabel: '核酸检测总成本(CNY)',
  909. prop: 'ZCB'
  910. },
  911. {
  912. childLabel: '核酸检测单人报价(CNY)',
  913. prop: 'DRBJ'
  914. },
  915. {
  916. childLabel: '核酸检测总报价(CNY)',
  917. prop: 'ZBJ'
  918. },
  919. {
  920. childLabel: '核酸检测单人利润(CNY)',
  921. prop: 'DRLR'
  922. },
  923. {
  924. childLabel: '核酸检测总利润(CNY)',
  925. prop: 'ZLR'
  926. },
  927. ],
  928. },
  929. //---
  930. {
  931. label: '酒店TBR',
  932. EnLabel: 'tbr',
  933. childList: [
  934. {
  935. childLabel: '酒店TBR单人成本(CNY)',
  936. prop: 'tbrcb',
  937. isBind: true
  938. },
  939. {
  940. childLabel: '人数',
  941. prop: 'tbrNumber'
  942. },
  943. {
  944. childLabel: '酒店TBR系数',
  945. prop: 'tbrxs'
  946. },
  947. {
  948. childLabel: '酒店TBR总成本(CNY)',
  949. prop: 'ZCB'
  950. },
  951. {
  952. childLabel: '酒店TBR单人报价(CNY)',
  953. prop: 'DRBJ'
  954. },
  955. {
  956. childLabel: '酒店TBR总报价(CNY)',
  957. prop: 'ZBJ'
  958. },
  959. {
  960. childLabel: '酒店TBR单人利润(CNY)',
  961. prop: 'DRLR'
  962. },
  963. {
  964. childLabel: '酒店TBR总利润(CNY)',
  965. prop: 'ZLR'
  966. },
  967. ],
  968. },
  969. {
  970. label: '酒店SGR',
  971. EnLabel: 'sgr',
  972. childList: [
  973. {
  974. childLabel: '酒店SGR单人成本(CNY)',
  975. prop: 'sgrcb',
  976. isBind: true
  977. },
  978. {
  979. childLabel: '人数',
  980. prop: 'sgrNumber'
  981. },
  982. {
  983. childLabel: '酒店SGR系数',
  984. prop: 'sgrxs'
  985. },
  986. {
  987. childLabel: '酒店SGR总成本(CNY)',
  988. prop: 'ZCB'
  989. },
  990. {
  991. childLabel: '酒店SGR单人报价(CNY)',
  992. prop: 'DRBJ'
  993. },
  994. {
  995. childLabel: '酒店SGR总报价(CNY)',
  996. prop: 'ZBJ'
  997. },
  998. {
  999. childLabel: '酒店SGR单人利润(CNY)',
  1000. prop: 'DRLR'
  1001. },
  1002. {
  1003. childLabel: '酒店SGR总利润(CNY)',
  1004. prop: 'ZLR'
  1005. },
  1006. ],
  1007. },
  1008. {
  1009. label: '酒店JSES',
  1010. EnLabel: 'jses',
  1011. childList: [
  1012. {
  1013. childLabel: '酒店JSES单人成本(CNY)',
  1014. prop: 'jsescb',
  1015. isBind: true
  1016. },
  1017. {
  1018. childLabel: '人数',
  1019. prop: 'jsesNumber'
  1020. },
  1021. {
  1022. childLabel: '酒店JSES系数',
  1023. prop: 'jsesxs'
  1024. },
  1025. {
  1026. childLabel: '酒店JSES总成本(CNY)',
  1027. prop: 'ZCB'
  1028. },
  1029. {
  1030. childLabel: '酒店JSES单人报价(CNY)',
  1031. prop: 'DRBJ'
  1032. },
  1033. {
  1034. childLabel: '酒店JSES总报价(CNY)',
  1035. prop: 'ZBJ'
  1036. },
  1037. {
  1038. childLabel: '酒店JSES单人利润(CNY)',
  1039. prop: 'DRLR'
  1040. },
  1041. {
  1042. childLabel: '酒店JSES总利润(CNY)',
  1043. prop: 'ZLR'
  1044. },
  1045. ],
  1046. },
  1047. {
  1048. label: '酒店SUITE',
  1049. EnLabel: 'suite',
  1050. childList: [
  1051. {
  1052. childLabel: '酒店SUITE单人成本(CNY)',
  1053. prop: 'suitecb',
  1054. isBind: true
  1055. },
  1056. {
  1057. childLabel: '人数',
  1058. prop: 'suiteNumber'
  1059. },
  1060. {
  1061. childLabel: '酒店SUITE系数',
  1062. prop: 'suitexs'
  1063. },
  1064. {
  1065. childLabel: '酒店SUITE总成本(CNY)',
  1066. prop: 'ZCB'
  1067. },
  1068. {
  1069. childLabel: '酒店SUITE单人报价(CNY)',
  1070. prop: 'DRBJ'
  1071. },
  1072. {
  1073. childLabel: '酒店SUITE总报价(CNY)',
  1074. prop: 'ZBJ'
  1075. },
  1076. {
  1077. childLabel: '酒店SUITE单人利润(CNY)',
  1078. prop: 'DRLR'
  1079. },
  1080. {
  1081. childLabel: '酒店SUITE总利润(CNY)',
  1082. prop: 'ZLR'
  1083. },
  1084. ],
  1085. },
  1086. {
  1087. label: '地接',
  1088. EnLabel: 'dj',
  1089. childList: [
  1090. {
  1091. childLabel: '地接单人成本(CNY)',
  1092. prop: 'djcb',
  1093. isBind: true
  1094. },
  1095. {
  1096. childLabel: '人数', //实体类无地接人数
  1097. prop: 'djrs'
  1098. },
  1099. {
  1100. childLabel: '地接系数',
  1101. prop: 'djxs'
  1102. },
  1103. {
  1104. childLabel: '地接总成本(CNY)',
  1105. prop: 'ZCB'
  1106. },
  1107. {
  1108. childLabel: '地接单人报价(CNY)',
  1109. prop: 'DRBJ'
  1110. },
  1111. {
  1112. childLabel: '地接总报价(CNY)',
  1113. prop: 'ZBJ'
  1114. },
  1115. {
  1116. childLabel: '地接单人利润(CNY)',
  1117. prop: 'DRLR'
  1118. },
  1119. {
  1120. childLabel: '地接总利润(CNY)',
  1121. prop: 'ZLR'
  1122. },
  1123. ],
  1124. },
  1125. {
  1126. label: '公务',
  1127. EnLabel: 'gw',
  1128. childList: [
  1129. {
  1130. childLabel: '公务单人成本(CNY)',
  1131. prop: 'gwcb',
  1132. isBind: true
  1133. },
  1134. {
  1135. childLabel: '人数',
  1136. prop: 'gwrs'
  1137. },
  1138. {
  1139. childLabel: '公务系数',
  1140. prop: 'gwxs'
  1141. },
  1142. {
  1143. childLabel: '公务总成本(CNY)',
  1144. prop: 'ZCB'
  1145. },
  1146. {
  1147. childLabel: '公务单人报价(CNY)',
  1148. prop: 'DRBJ'
  1149. },
  1150. {
  1151. childLabel: '公务总报价(CNY)',
  1152. prop: 'ZBJ'
  1153. },
  1154. {
  1155. childLabel: '公务单人利润(CNY)',
  1156. prop: 'DRLR'
  1157. },
  1158. {
  1159. childLabel: '公务总利润(CNY)',
  1160. prop: 'ZLR'
  1161. },
  1162. ],
  1163. },
  1164. {
  1165. label: '零用金',
  1166. EnLabel: 'lyj',
  1167. childList: [
  1168. {
  1169. childLabel: '零用金单人成本(CNY)',
  1170. prop: 'lyjcb',
  1171. isBind: true
  1172. },
  1173. {
  1174. childLabel: '人数',
  1175. prop: 'lyjrs'
  1176. },
  1177. {
  1178. childLabel: '零用金系数',
  1179. prop: 'lyjxs'
  1180. },
  1181. {
  1182. childLabel: '零用金总成本(CNY)',
  1183. prop: 'ZCB'
  1184. },
  1185. {
  1186. childLabel: '零用金单人报价(CNY)',
  1187. prop: 'DRBJ'
  1188. },
  1189. {
  1190. childLabel: '零用金总报价(CNY)',
  1191. prop: 'ZBJ'
  1192. },
  1193. {
  1194. childLabel: '零用金单人利润(CNY)',
  1195. prop: 'DRLR'
  1196. },
  1197. {
  1198. childLabel: '零用金总利润(CNY)',
  1199. prop: 'ZLR'
  1200. },
  1201. ],
  1202. },
  1203. ],
  1204. //cabinoneList: ['经济舱 TBR', '经济舱 SGR', '核酸检测', '团组预算明细'],
  1205. cabinoneOptions: ['经济舱 TBR', '经济舱 SGR', '公务舱 SGR', '公务舱 JS/ES', '公务舱 SUITE', '经济舱 SUITE'],
  1206. cabinDatal: [
  1207. {
  1208. label: '经济舱 TBR',
  1209. childList: [
  1210. {
  1211. childLabel: '单人成本(CNY)',
  1212. prop: 'costPerson'
  1213. },
  1214. {
  1215. childLabel: '人数',
  1216. prop: 'toll'
  1217. },
  1218. {
  1219. childLabel: '总成本(CNY)',
  1220. prop: 'totalCost'
  1221. },
  1222. {
  1223. childLabel: '单人报价(CNY)',
  1224. prop: 'singleQuote'
  1225. },
  1226. {
  1227. childLabel: '总报价(CNY)',
  1228. prop: 'totalQuote'
  1229. },
  1230. {
  1231. childLabel: '单人利润(CNY)',
  1232. prop: 'singleProfit'
  1233. },
  1234. {
  1235. childLabel: '总利润(CNY)',
  1236. prop: 'totalProfit'
  1237. },
  1238. ],
  1239. sheetInfo: [
  1240. {
  1241. costPerson: 1,
  1242. toll: 11,
  1243. totalCost: 137597.76,
  1244. singleQuote: 102203.71,
  1245. totalQuote: 35394.05,
  1246. singleProfit: 35394.05,
  1247. totalProfit: 35394.05
  1248. },
  1249. ]
  1250. },
  1251. {
  1252. label: '经济舱 SGR',
  1253. childList: [
  1254. {
  1255. childLabel: '单人成本(CNY)',
  1256. prop: 'costPerson'
  1257. },
  1258. {
  1259. childLabel: '人数',
  1260. prop: 'toll'
  1261. },
  1262. {
  1263. childLabel: '总成本(CNY)',
  1264. prop: 'totalCost'
  1265. },
  1266. {
  1267. childLabel: '单人报价(CNY)',
  1268. prop: 'singleQuote'
  1269. },
  1270. {
  1271. childLabel: '总报价(CNY)',
  1272. prop: 'totalQuote'
  1273. },
  1274. {
  1275. childLabel: '单人利润(CNY)',
  1276. prop: 'singleProfit'
  1277. },
  1278. {
  1279. childLabel: '总利润(CNY)',
  1280. prop: 'totalProfit'
  1281. },
  1282. ],
  1283. sheetInfo: [
  1284. {
  1285. costPerson: 1,
  1286. toll: 11,
  1287. totalCost: 137597.76,
  1288. singleQuote: 102203.71,
  1289. totalQuote: 35394.05,
  1290. singleProfit: 35394.05,
  1291. totalProfit: 35394.05
  1292. },
  1293. ]
  1294. },
  1295. {
  1296. label: '公务舱 SGR',
  1297. childList: [
  1298. {
  1299. childLabel: '单人成本(CNY)',
  1300. prop: 'costPerson'
  1301. },
  1302. {
  1303. childLabel: '人数',
  1304. prop: 'toll'
  1305. },
  1306. {
  1307. childLabel: '总成本(CNY)',
  1308. prop: 'totalCost'
  1309. },
  1310. {
  1311. childLabel: '单人报价(CNY)',
  1312. prop: 'singleQuote'
  1313. },
  1314. {
  1315. childLabel: '总报价(CNY)',
  1316. prop: 'totalQuote'
  1317. },
  1318. {
  1319. childLabel: '单人利润(CNY)',
  1320. prop: 'singleProfit'
  1321. },
  1322. {
  1323. childLabel: '总利润(CNY)',
  1324. prop: 'totalProfit'
  1325. },
  1326. ],
  1327. sheetInfo: [
  1328. {
  1329. costPerson: 1,
  1330. toll: 11,
  1331. totalCost: 137597.76,
  1332. singleQuote: 102203.71,
  1333. totalQuote: 35394.05,
  1334. singleProfit: 35394.05,
  1335. totalProfit: 35394.05
  1336. },
  1337. ]
  1338. },
  1339. {
  1340. label: '公务舱 JS/ES',
  1341. childList: [
  1342. {
  1343. childLabel: '单人成本(CNY)',
  1344. prop: 'costPerson'
  1345. },
  1346. {
  1347. childLabel: '人数',
  1348. prop: 'toll'
  1349. },
  1350. {
  1351. childLabel: '总成本(CNY)',
  1352. prop: 'totalCost'
  1353. },
  1354. {
  1355. childLabel: '单人报价(CNY)',
  1356. prop: 'singleQuote'
  1357. },
  1358. {
  1359. childLabel: '总报价(CNY)',
  1360. prop: 'totalQuote'
  1361. },
  1362. {
  1363. childLabel: '单人利润(CNY)',
  1364. prop: 'singleProfit'
  1365. },
  1366. {
  1367. childLabel: '总利润(CNY)',
  1368. prop: 'totalProfit'
  1369. },
  1370. ],
  1371. sheetInfo: [
  1372. {
  1373. costPerson: 1,
  1374. toll: 11,
  1375. totalCost: 137597.76,
  1376. singleQuote: 102203.71,
  1377. totalQuote: 35394.05,
  1378. singleProfit: 35394.05,
  1379. totalProfit: 35394.05
  1380. },
  1381. ]
  1382. },
  1383. {
  1384. label: '公务舱 SUITE',
  1385. childList: [
  1386. {
  1387. childLabel: '单人成本(CNY)',
  1388. prop: 'costPerson'
  1389. },
  1390. {
  1391. childLabel: '人数',
  1392. prop: 'toll'
  1393. },
  1394. {
  1395. childLabel: '总成本(CNY)',
  1396. prop: 'totalCost'
  1397. },
  1398. {
  1399. childLabel: '单人报价(CNY)',
  1400. prop: 'singleQuote'
  1401. },
  1402. {
  1403. childLabel: '总报价(CNY)',
  1404. prop: 'totalQuote'
  1405. },
  1406. {
  1407. childLabel: '单人利润(CNY)',
  1408. prop: 'singleProfit'
  1409. },
  1410. {
  1411. childLabel: '总利润(CNY)',
  1412. prop: 'totalProfit'
  1413. },
  1414. ],
  1415. sheetInfo: [
  1416. {
  1417. costPerson: 1,
  1418. toll: 11,
  1419. totalCost: 137597.76,
  1420. singleQuote: 102203.71,
  1421. totalQuote: 35394.05,
  1422. singleProfit: 35394.05,
  1423. totalProfit: 35394.05
  1424. },
  1425. ]
  1426. }
  1427. ,
  1428. {
  1429. label: '经济舱 SUITE',
  1430. childList: [
  1431. {
  1432. childLabel: '单人成本(CNY)',
  1433. prop: 'costPerson'
  1434. },
  1435. {
  1436. childLabel: '人数',
  1437. prop: 'toll'
  1438. },
  1439. {
  1440. childLabel: '总成本(CNY)',
  1441. prop: 'totalCost'
  1442. },
  1443. {
  1444. childLabel: '单人报价(CNY)',
  1445. prop: 'singleQuote'
  1446. },
  1447. {
  1448. childLabel: '总报价(CNY)',
  1449. prop: 'totalQuote'
  1450. },
  1451. {
  1452. childLabel: '单人利润(CNY)',
  1453. prop: 'singleProfit'
  1454. },
  1455. {
  1456. childLabel: '总利润(CNY)',
  1457. prop: 'totalProfit'
  1458. },
  1459. ],
  1460. sheetInfo: [
  1461. {
  1462. costPerson: 1,
  1463. toll: 11,
  1464. totalCost: 137597.76,
  1465. singleQuote: 102203.71,
  1466. totalQuote: 35394.05,
  1467. singleProfit: 35394.05,
  1468. totalProfit: 35394.05
  1469. },
  1470. ]
  1471. },
  1472. {
  1473. label: '团组预算明细',
  1474. childList: [
  1475. {
  1476. childLabel: '团组成本(CNY)',
  1477. prop: 'groupCosts'
  1478. },
  1479. {
  1480. childLabel: '团组报价(CNY)',
  1481. prop: 'gtroupQuotes'
  1482. },
  1483. {
  1484. childLabel: '团组利润(CNY)',
  1485. prop: 'groupProfit'
  1486. }
  1487. ],
  1488. sheetInfo: [
  1489. {
  1490. groupCosts: 1,
  1491. gtroupQuotes: 11,
  1492. groupProfit: 137597.76,
  1493. },
  1494. ]
  1495. }
  1496. ],
  1497. BcabinDatal: [
  1498. {
  1499. label: '经济舱 TBR',
  1500. childList: [
  1501. {
  1502. childLabel: '单人成本(CNY)',
  1503. prop: 'costPerson'
  1504. },
  1505. {
  1506. childLabel: '人数',
  1507. prop: 'toll'
  1508. },
  1509. {
  1510. childLabel: '总成本(CNY)',
  1511. prop: 'totalCost'
  1512. },
  1513. {
  1514. childLabel: '单人报价(CNY)',
  1515. prop: 'singleQuote'
  1516. },
  1517. {
  1518. childLabel: '总报价(CNY)',
  1519. prop: 'totalQuote'
  1520. },
  1521. {
  1522. childLabel: '单人利润(CNY)',
  1523. prop: 'singleProfit'
  1524. },
  1525. {
  1526. childLabel: '总利润(CNY)',
  1527. prop: 'totalProfit'
  1528. },
  1529. ],
  1530. sheetInfo: [
  1531. {
  1532. costPerson: 0,
  1533. toll: 0,
  1534. totalCost: 137597.76,
  1535. singleQuote: 102203.71,
  1536. totalQuote: 35394.05,
  1537. singleProfit: 35394.05,
  1538. totalProfit: 35394.05
  1539. },
  1540. ]
  1541. },
  1542. {
  1543. label: '经济舱 SGR',
  1544. childList: [
  1545. {
  1546. childLabel: '单人成本(CNY)',
  1547. prop: 'costPerson'
  1548. },
  1549. {
  1550. childLabel: '人数',
  1551. prop: 'toll'
  1552. },
  1553. {
  1554. childLabel: '总成本(CNY)',
  1555. prop: 'totalCost'
  1556. },
  1557. {
  1558. childLabel: '单人报价(CNY)',
  1559. prop: 'singleQuote'
  1560. },
  1561. {
  1562. childLabel: '总报价(CNY)',
  1563. prop: 'totalQuote'
  1564. },
  1565. {
  1566. childLabel: '单人利润(CNY)',
  1567. prop: 'singleProfit'
  1568. },
  1569. {
  1570. childLabel: '总利润(CNY)',
  1571. prop: 'totalProfit'
  1572. },
  1573. ],
  1574. sheetInfo: [
  1575. {
  1576. costPerson: 1,
  1577. toll: 11,
  1578. totalCost: 137597.76,
  1579. singleQuote: 102203.71,
  1580. totalQuote: 35394.05,
  1581. singleProfit: 35394.05,
  1582. totalProfit: 35394.05
  1583. },
  1584. ]
  1585. },
  1586. {
  1587. label: '公务舱 SGR',
  1588. childList: [
  1589. {
  1590. childLabel: '单人成本(CNY)',
  1591. prop: 'costPerson'
  1592. },
  1593. {
  1594. childLabel: '人数',
  1595. prop: 'toll'
  1596. },
  1597. {
  1598. childLabel: '总成本(CNY)',
  1599. prop: 'totalCost'
  1600. },
  1601. {
  1602. childLabel: '单人报价(CNY)',
  1603. prop: 'singleQuote'
  1604. },
  1605. {
  1606. childLabel: '总报价(CNY)',
  1607. prop: 'totalQuote'
  1608. },
  1609. {
  1610. childLabel: '单人利润(CNY)',
  1611. prop: 'singleProfit'
  1612. },
  1613. {
  1614. childLabel: '总利润(CNY)',
  1615. prop: 'totalProfit'
  1616. },
  1617. ],
  1618. sheetInfo: [
  1619. {
  1620. costPerson: 1,
  1621. toll: 11,
  1622. totalCost: 137597.76,
  1623. singleQuote: 102203.71,
  1624. totalQuote: 35394.05,
  1625. singleProfit: 35394.05,
  1626. totalProfit: 35394.05
  1627. },
  1628. ]
  1629. },
  1630. {
  1631. label: '公务舱 JS/ES',
  1632. childList: [
  1633. {
  1634. childLabel: '单人成本(CNY)',
  1635. prop: 'costPerson'
  1636. },
  1637. {
  1638. childLabel: '人数',
  1639. prop: 'toll'
  1640. },
  1641. {
  1642. childLabel: '总成本(CNY)',
  1643. prop: 'totalCost'
  1644. },
  1645. {
  1646. childLabel: '单人报价(CNY)',
  1647. prop: 'singleQuote'
  1648. },
  1649. {
  1650. childLabel: '总报价(CNY)',
  1651. prop: 'totalQuote'
  1652. },
  1653. {
  1654. childLabel: '单人利润(CNY)',
  1655. prop: 'singleProfit'
  1656. },
  1657. {
  1658. childLabel: '总利润(CNY)',
  1659. prop: 'totalProfit'
  1660. },
  1661. ],
  1662. sheetInfo: [
  1663. {
  1664. costPerson: 1,
  1665. toll: 11,
  1666. totalCost: 137597.76,
  1667. singleQuote: 102203.71,
  1668. totalQuote: 35394.05,
  1669. singleProfit: 35394.05,
  1670. totalProfit: 35394.05
  1671. },
  1672. ]
  1673. },
  1674. {
  1675. label: '公务舱 SUITE',
  1676. childList: [
  1677. {
  1678. childLabel: '单人成本(CNY)',
  1679. prop: 'costPerson'
  1680. },
  1681. {
  1682. childLabel: '人数',
  1683. prop: 'toll'
  1684. },
  1685. {
  1686. childLabel: '总成本(CNY)',
  1687. prop: 'totalCost'
  1688. },
  1689. {
  1690. childLabel: '单人报价(CNY)',
  1691. prop: 'singleQuote'
  1692. },
  1693. {
  1694. childLabel: '总报价(CNY)',
  1695. prop: 'totalQuote'
  1696. },
  1697. {
  1698. childLabel: '单人利润(CNY)',
  1699. prop: 'singleProfit'
  1700. },
  1701. {
  1702. childLabel: '总利润(CNY)',
  1703. prop: 'totalProfit'
  1704. },
  1705. ],
  1706. sheetInfo: [
  1707. {
  1708. costPerson: 1,
  1709. toll: 11,
  1710. totalCost: 137597.76,
  1711. singleQuote: 102203.71,
  1712. totalQuote: 35394.05,
  1713. singleProfit: 35394.05,
  1714. totalProfit: 35394.05
  1715. },
  1716. ]
  1717. }
  1718. ,
  1719. {
  1720. label: '经济舱 SUITE',
  1721. childList: [
  1722. {
  1723. childLabel: '单人成本(CNY)',
  1724. prop: 'costPerson'
  1725. },
  1726. {
  1727. childLabel: '人数',
  1728. prop: 'toll'
  1729. },
  1730. {
  1731. childLabel: '总成本(CNY)',
  1732. prop: 'totalCost'
  1733. },
  1734. {
  1735. childLabel: '单人报价(CNY)',
  1736. prop: 'singleQuote'
  1737. },
  1738. {
  1739. childLabel: '总报价(CNY)',
  1740. prop: 'totalQuote'
  1741. },
  1742. {
  1743. childLabel: '单人利润(CNY)',
  1744. prop: 'singleProfit'
  1745. },
  1746. {
  1747. childLabel: '总利润(CNY)',
  1748. prop: 'totalProfit'
  1749. },
  1750. ],
  1751. sheetInfo: [
  1752. {
  1753. costPerson: 1,
  1754. toll: 11,
  1755. totalCost: 137597.76,
  1756. singleQuote: 102203.71,
  1757. totalQuote: 35394.05,
  1758. singleProfit: 35394.05,
  1759. totalProfit: 35394.05
  1760. },
  1761. ]
  1762. }
  1763. ],
  1764. costType: [
  1765. {
  1766. value: 'A',
  1767. label: '单段模式'
  1768. },
  1769. {
  1770. value: 'B',
  1771. label: '双段模式'
  1772. }
  1773. ],
  1774. userId: 0,
  1775. token: '',
  1776. costTypevalue: 'A',
  1777. grouptitleinfo: {},
  1778. costTypeHotelNumbers: [{
  1779. "sgr": 0,
  1780. "tbr": 0,
  1781. "jses": 0,
  1782. "suite": 0,
  1783. "type": "Default",
  1784. "diid": 0,
  1785. id: 0,
  1786. },
  1787. {
  1788. "sgr": 0,
  1789. "tbr": 0,
  1790. "jses": 0,
  1791. "suite": 0,
  1792. "type": "A",
  1793. "diid": 0,
  1794. id: 0,
  1795. },
  1796. {
  1797. "sgr": 0,
  1798. "tbr": 0,
  1799. "jses": 0,
  1800. "suite": 0,
  1801. "type": "B",
  1802. "diid": 0,
  1803. id: 0,
  1804. }],
  1805. CheckBoxListSelect: [
  1806. {
  1807. "diid": 0,
  1808. "cbType": "Top",
  1809. "cbValues": ['DAY', 'ITIN', 'VA', 'VF', 'VRD', 'T/G S', 'DATE'] //"string"
  1810. },
  1811. {
  1812. "diid": 0,
  1813. "cbType": "Left",
  1814. "cbValues": ['签证', '机票', '核酸检测',] //"string"
  1815. },
  1816. {
  1817. "diid": 0,
  1818. "cbType": "Right",
  1819. "cbValues": ['经济舱 TBR', '经济舱 SGR', '团组预算明细'] //"string"
  1820. }
  1821. ],
  1822. AGroupCostParameter: {
  1823. "id": 0,
  1824. "diId": 0,
  1825. "currency": "CNY",
  1826. "rate": 0,
  1827. "tax": 0,
  1828. "ffys": 0,
  1829. "hotelXS": 0,
  1830. "jjccb": 0,
  1831. "jjcxs": 0,
  1832. "jjcrs": 0,
  1833. "gwccb": 0,
  1834. "gwcxs": 0,
  1835. "gwcrs": 0,
  1836. "hcpcb": 0,
  1837. "hcpxs": 0,
  1838. "hcprs": 0,
  1839. "cpcb": 0,
  1840. "cpxs": 0,
  1841. "cprs": 0,
  1842. "bxcb": 0,
  1843. "bxxs": 0,
  1844. "bxrs": 0,
  1845. "hscb": 0,
  1846. "hsxs": 0,
  1847. "hsrs": 0,
  1848. "visaCB": 0,
  1849. "visaXS": 0,
  1850. "visaRS": 0,
  1851. "gwcb": 0,
  1852. "gwxs": 0,
  1853. "gwrs": 0,
  1854. "djcb": 0,
  1855. "djrs": 0,
  1856. "djxs": 0,
  1857. "sgrcb": 0,
  1858. "sgrNumber": 0,
  1859. "sgrxs": 0,
  1860. "tbrcb": 0,
  1861. "tbrNumber": 0,
  1862. "tbrxs": 0,
  1863. "jsescb": 0,
  1864. "jsesNumber": 0,
  1865. "jsesxs": 0,
  1866. "suitecb": 0,
  1867. "suiteNumber": 0,
  1868. "suitexs": 0,
  1869. "lyjcb": 0,
  1870. "lyjxs": 0,
  1871. "lyjrs": 0,
  1872. "isShare": 0,
  1873. "costType": "A",
  1874. "costTypeStartTime": "",
  1875. "costTypeendTime": "",
  1876. "costTypenumber": 0
  1877. },
  1878. BGroupCostParameter: {
  1879. "id": 0,
  1880. "diId": 0,
  1881. "currency": "",
  1882. "rate": 0,
  1883. "tax": 0,
  1884. "ffys": 0,
  1885. "hotelXS": 0,
  1886. "jjccb": 0,
  1887. "jjcxs": 0,
  1888. "jjcrs": 0,
  1889. "gwccb": 0,
  1890. "gwcxs": 0,
  1891. "gwcrs": 0,
  1892. "hcpcb": 0,
  1893. "hcpxs": 0,
  1894. "hcprs": 0,
  1895. "cpcb": 0,
  1896. "cpxs": 0,
  1897. "cprs": 0,
  1898. "bxcb": 0,
  1899. "bxxs": 0,
  1900. "bxrs": 0,
  1901. "hscb": 0,
  1902. "hsxs": 0,
  1903. "hsrs": 0,
  1904. "visaCB": 0,
  1905. "visaXS": 0,
  1906. "visaRS": 0,
  1907. "gwcb": 0,
  1908. "gwxs": 0,
  1909. "gwrs": 0,
  1910. "djcb": 0,
  1911. "djxs": 0,
  1912. "djrs": 0,
  1913. "sgrcb": 0,
  1914. "sgrNumber": 0,
  1915. "sgrxs": 0,
  1916. "tbrcb": 0,
  1917. "tbrNumber": 0,
  1918. "tbrxs": 0,
  1919. "jsescb": 0,
  1920. "jsesNumber": 0,
  1921. "jsesxs": 0,
  1922. "suitecb": 0,
  1923. "suiteNumber": 0,
  1924. "suitexs": 0,
  1925. "lyjcb": 0,
  1926. "lyjxs": 0,
  1927. "lyjrs": 0,
  1928. "isShare": 0,
  1929. "costType": "B",
  1930. "costTypeStartTime": "",
  1931. "costTypeendTime": "",
  1932. "costTypenumber": 0
  1933. },
  1934. dialogColumn: [
  1935. {
  1936. index: 1, data: [
  1937. { title: "国家", prop: "country" },
  1938. { title: "城市", prop: "city" },
  1939. { title: "服务类型", prop: "serviceType" },
  1940. { title: "用车类型", prop: "carType" },
  1941. { title: "用车报价", prop: "offer" },
  1942. { title: "车兼导费用", prop: "cgCost" },
  1943. { title: "用车时长", prop: "runingTime" },
  1944. { title: "车超时费用/时", prop: "overtimeFee" },
  1945. { title: "司兼导超时费/时", prop: "cgOvertimeFee" },
  1946. { title: "币种", prop: "currency" },
  1947. { title: "备注", prop: "remark" }
  1948. ]
  1949. },
  1950. {
  1951. index: 2, data: [
  1952. { title: "国家", prop: "country" },
  1953. { title: "城市", prop: "city" },
  1954. { title: "导游服务类型", prop: "serviceType" },
  1955. { title: "导游工资", prop: "price" },
  1956. { title: "翻译工资", prop: "translationPrice" },
  1957. { title: "超时费用", prop: "overtimeFee" },
  1958. { title: "币种", prop: "currency" },
  1959. { title: "备注", prop: "remark" }
  1960. ]
  1961. },
  1962. {
  1963. index: 3, data: [
  1964. { title: "国家", prop: "country" },
  1965. { title: "城市", prop: "city" },
  1966. { title: "车类型", prop: "carType" },
  1967. { title: "服务类型", prop: "serviceType" },
  1968. { title: "用车时间", prop: "when" },
  1969. { title: "工资", prop: "price" },
  1970. { title: "超时费用", prop: "overtimeFee" },
  1971. { title: "币种", prop: "currency" },
  1972. { title: "备注", prop: "remark" }
  1973. ]
  1974. },
  1975. {
  1976. index: 4, data: [
  1977. { title: "国家", prop: "country" },
  1978. { title: "城市", prop: "city" },
  1979. { title: "景点", prop: "scenicSpot" },
  1980. { title: "景点项目描述", prop: "scenicSpotDetail" },
  1981. { title: "景点价格", prop: "price" },
  1982. { title: "币种", prop: "currency" },
  1983. { title: "景点地址", prop: "address" }
  1984. ]
  1985. }
  1986. // 司兼导
  1987. // 导游
  1988. // 车数据
  1989. // 景点
  1990. ],
  1991. dialogTableData: [],
  1992. SeldialogColumn: [],
  1993. DialogTitle: '',
  1994. pageSize: 5,
  1995. currentPage: 1,
  1996. dialogSearchInput: '',
  1997. selectRow: {},
  1998. rowIndex: 0,
  1999. sumTopPrice: [],
  2000. DJLables: ['VF', 'T/G S', 'T/G OF', 'T/G M', 'T/G A', 'T/G TF', 'T/G EF', 'C/F M', 'C/F OF', 'B', 'L', 'D', 'EF', 'B/R/F', 'TE', 'T/G T', 'DRV T', 'T/L F'],
  2001. GwLables: ['T/V', 'E/C T', 'I/F', '1/L'],
  2002. OtherCostProperty: ['visaCB', 'hcpcb', 'cpcb', 'bxcb', 'hscb', 'djcb', 'gwcb', 'lyjcb'],
  2003. OtherCostPropertyBJ: ['visa', 'hcp', 'cp', 'bx', 'hs', 'dj', 'gw', 'lyj'],
  2004. peopleNumber: 1,
  2005. centerheight: 700,
  2006. defaultheight: 50,
  2007. rules: {
  2008. rate: [
  2009. { pattern: /^-?\d+\.?\d*$/, message: '请输入正确数据', trigger: 'blur', required: true, }
  2010. ],
  2011. tax: [
  2012. { pattern: /^-?\d+\.?\d*$/, message: '请输入正确数据', trigger: 'blur', required: true, }
  2013. ],
  2014. },
  2015. HotelRules: {
  2016. sgr: [
  2017. { type: 'number', min: 0, message: '请输入整数', trigger: 'blur', required: true, },
  2018. ],
  2019. tbr: [
  2020. { type: 'number', min: 0, message: '请输入整数', trigger: 'blur', required: true, },
  2021. ],
  2022. suite: [
  2023. { type: 'number', min: 0, message: '请输入整数', trigger: 'blur', required: true, },
  2024. ],
  2025. jses: [
  2026. { type: 'number', min: 0, message: '请输入整数', trigger: 'blur', required: true, },
  2027. ],
  2028. },
  2029. CostTimeRules: {
  2030. costTypeendTime: [
  2031. { message: '请输入结束时间', trigger: 'blur', required: true, },
  2032. ],
  2033. costTypenumber: [
  2034. { type: 'number', min: 0, message: '请输入整数', trigger: 'blur', required: true, },
  2035. ],
  2036. costTypeStartTime: [
  2037. { message: '请输入开始时间', trigger: 'blur', required: true, },
  2038. ],
  2039. }
  2040. };
  2041. },
  2042. watch: {
  2043. // 此处监听variable变量,当期有变化时执行
  2044. // checkList(item1, item2) {
  2045. // // console.log(item1)
  2046. // // console.log(item2)
  2047. // // item1为新值,item2为旧值
  2048. // },
  2049. 'tableData.length': {
  2050. handler(newValue, oldValue) {
  2051. if (newValue !== oldValue) {
  2052. if (this.tableData.length > 3) {
  2053. this.centerheight = 700;
  2054. } else {
  2055. this.centerheight = this.defaultheight + (this.tableData.length * 220);
  2056. }
  2057. console.log('高度' + this.centerheight);
  2058. }
  2059. }
  2060. }
  2061. },
  2062. methods: {
  2063. getSummaries(param) {
  2064. var that = this;
  2065. //console.log(param)
  2066. const { columns, data } = param;
  2067. const sums = [];
  2068. const sums1 = [];
  2069. var prices = [];
  2070. var thisData = data;
  2071. var ATime = { start: that.addOneDay(that.AGroupCostParameter.costTypeStartTime, 0), end: that.addOneDay(that.AGroupCostParameter.costTypeendTime, 0) };
  2072. var BTime = { start: that.addOneDay(that.BGroupCostParameter.costTypeStartTime, 0), end: that.addOneDay(that.BGroupCostParameter.costTypeendTime, 0) };
  2073. console.log('ATime,BTime', ATime, BTime);
  2074. var data1 = [];
  2075. var data2 = [];
  2076. console.log('datas', data);
  2077. if (that.costTypevalue == 'B') {
  2078. for (var i = 0; i < thisData.length; i++) {
  2079. var forTime = thisData[i].date;
  2080. if (forTime == '' && i != 0) {
  2081. forTime = thisData[i - 1].date;
  2082. }
  2083. if (forTime >= ATime.start && forTime <= ATime.end) {
  2084. data1.push(thisData[i])
  2085. }
  2086. if (forTime >= BTime.start && forTime <= BTime.end) {
  2087. data2.push(thisData[i])
  2088. }
  2089. }
  2090. thisData = data1;
  2091. if (isNaN(Number(that.AGroupCostParameter.costTypenumber)) || Number(that.AGroupCostParameter.costTypenumber) < 1) {
  2092. that.peopleNumber = 1;
  2093. } else {
  2094. that.peopleNumber = Number(that.AGroupCostParameter.costTypenumber);
  2095. }
  2096. }
  2097. console.log('3data', thisData, data1, data2);
  2098. columns.forEach((column, index) => {
  2099. if (index === 0) {
  2100. prices[index] = "总计:";
  2101. return;
  2102. }
  2103. if (column.label == 'DATE' || column.label == 'ITIN' || column.label == 'VT' || column.label == 'VN' || column.label == 'ACCO N' || column.label == 'VA' || column.label == 'VRD' || column.label == 'T/G N' || column.label == 'T/G WH' || column.label == '操作') {
  2104. prices[index] = "——";
  2105. return;
  2106. }
  2107. const values = thisData.map(item => Number(item[column.property]));
  2108. if (!values.every(value => isNaN(value))) {
  2109. sums[index] = values.reduce((prev, curr) => {
  2110. const value = Number(curr);
  2111. if (!isNaN(value)) {
  2112. return prev + curr;
  2113. } else {
  2114. return prev;
  2115. }
  2116. }, 0);
  2117. if (column.label == 'SGR' || column.label == 'JS/ES' || column.label == 'SUITE' || column.label == 'TBR' || column.label == 'B' || column.label == 'L' || column.label == 'D' || column.label == 'EF' || column.label == 'TE' || column.label == 'T/G T' || column.label == 'P/C' || column.label == ' DRV T') {
  2118. prices[index] = '共' + (sums[index] * that.peopleNumber).toFixed(2) + ' ' + this.AGroupCostParameter.currency + '\r\n人均' + (sums[index]).toFixed(2) + " " + this.AGroupCostParameter.currency //sums[index] + '(' + this.AGroupCostParameter.currency + ')' + ' 人均(' + sums[index] + ')';
  2119. } else {
  2120. prices[index] = '共' + sums[index].toFixed(2) + ' ' + this.AGroupCostParameter.currency + '\r\n人均' + (sums[index] / that.peopleNumber).toFixed(2) + " " + this.AGroupCostParameter.currency //sums[index] + '(' + this.AGroupCostParameter.currency + ')' + ' 人均(' + sums[index] + ')';
  2121. sums[index] = parseFloat((sums[index] / that.peopleNumber).toFixed(2));
  2122. }
  2123. } else {
  2124. prices[index] = 'N/A';
  2125. }
  2126. if (that.costTypevalue == 'B') {
  2127. const values1 = data2.map(item => Number(item[column.property]));
  2128. if (!values1.every(value => isNaN(value))) {
  2129. sums1[index] = values1.reduce((prev, curr) => {
  2130. const value = Number(curr);
  2131. if (!isNaN(value)) {
  2132. return prev + curr;
  2133. } else {
  2134. return prev;
  2135. }
  2136. }, 0);
  2137. if (column.label == 'SGR' || column.label == 'JS/ES' || column.label == 'SUITE' || column.label == 'TBR' || column.label == 'B' || column.label == 'L' || column.label == 'D' || column.label == 'EF' || column.label == 'TE' || column.label == 'T/G T' || column.label == 'P/C' || column.label == ' DRV T') {
  2138. prices[index] = 'A段费用' + prices[index] + '\r\nB段费用共' + (sums1[index] * that.BGroupCostParameter.costTypenumber).toFixed(2) + " " + this.AGroupCostParameter.currency + '\r\n人均' + sums1[index] + " " + this.AGroupCostParameter.currency //sums[index] + '(' + this.AGroupCostParameter.currency + ')' + ' 人均(' + sums[index] + ')';
  2139. } else {
  2140. prices[index] = 'A段费用' + prices[index] + '\r\nB段费用共' + sums1[index].toFixed(2) + " " + this.AGroupCostParameter.currency + '\r\n人均' + (sums1[index] / that.BGroupCostParameter.costTypenumber).toFixed(2) + " " + this.AGroupCostParameter.currency //sums[index] + '(' + this.AGroupCostParameter.currency + ')' + ' 人均(' + sums[index] + ')';
  2141. sums1[index] = ((sums1[index] / that.BGroupCostParameter.costTypenumber).toFixed(2));
  2142. }
  2143. } else {
  2144. prices[index] = 'A段费用' + prices[index] + ' B段费用' + 'N/A';
  2145. }
  2146. }
  2147. var fliterList = that.sumTopPrice.filter(function (x) {
  2148. return x.name == column.property;
  2149. })
  2150. if (fliterList.length == 0) {
  2151. that.sumTopPrice.push({ name: column.property, label: column.label, Aprice: sums[index], Bprice: sums1[index] == undefined ? 0 : sums1[index] });
  2152. } else {
  2153. fliterList[0].Aprice = sums[index];
  2154. fliterList[0].Bprice = sums1[index];
  2155. }
  2156. });
  2157. console.log(that.sumTopPrice, 'sumTopPrice---------------');
  2158. this.CalculatedPrice();
  2159. //console.log(that.sumTopPrice, '------------');
  2160. return prices;
  2161. },
  2162. handleEdit(index, row, buttonIndex) {
  2163. //console.log(index, row, buttonIndex);
  2164. this.rowIndex = index; // 行的索引
  2165. var api = '';
  2166. switch (buttonIndex) {
  2167. case 1:
  2168. api = 'GetCarGuides';
  2169. this.DialogTitle = '选择车导数据';
  2170. break;
  2171. case 2:
  2172. api = 'GetGuidesInfo';
  2173. this.DialogTitle = '导游信息';
  2174. break;
  2175. case 3:
  2176. api = 'GetCarInfo';
  2177. this.DialogTitle = '选择车数据';
  2178. break;
  2179. case 4:
  2180. api = 'GetScenicSpotInfo';
  2181. this.DialogTitle = '景点信息';
  2182. break;
  2183. }
  2184. if (api == '') {
  2185. this.$message.error('程序异常!');
  2186. return;
  2187. }
  2188. var dataC = this.dialogColumn.filter(x => x.index == buttonIndex);
  2189. if (dataC.length == 0) {
  2190. this.SeldialogColumn = [];
  2191. } else {
  2192. this.SeldialogColumn = dataC[0].data;
  2193. }
  2194. var that = this;
  2195. this.$axios.post('/api/Groups/' + api, {}, {
  2196. headers: {
  2197. 'Authorization': that.token,
  2198. }
  2199. }).then(resp => {
  2200. console.log(resp.data.data, '------------------------------------');
  2201. that.outerVisible = true;
  2202. if (resp.data.code == 200) {
  2203. that.dialogTableData = resp.data.data;
  2204. } else {
  2205. that.$message.error('获取数据失败!' + resp.data.msg);
  2206. }
  2207. })
  2208. },
  2209. handleDelete(index, row, rows) {
  2210. console.log(index, row, rows);
  2211. this.$confirm('此操作将删除该条信息, 是否继续?', '提示', {
  2212. confirmButtonText: '确定',
  2213. cancelButtonText: '取消',
  2214. type: 'warning'
  2215. }).then(() => {
  2216. this.$message({
  2217. message: '已删除',
  2218. type: 'success',
  2219. offset: 50
  2220. });
  2221. rows.splice(index, 1);
  2222. }).catch(() => {
  2223. this.$message({
  2224. type: 'info',
  2225. message: '已取消删除'
  2226. });
  2227. });
  2228. },
  2229. addStrip() {
  2230. this.tableData.push(
  2231. {
  2232. "diid": this.diid,
  2233. "day": "-",
  2234. "date": "",
  2235. "itin": "",
  2236. "carType": "",
  2237. "carCost": 0,
  2238. "carNumber": 0,
  2239. "carTiming": 0,
  2240. "tgs": 0,
  2241. "tgwh": 0,
  2242. "tgn": 0,
  2243. "tgof": 0,
  2244. "tgm": 0,
  2245. "tga": 0,
  2246. "tgtf": 0,
  2247. "tgef": 0,
  2248. "cfs": 0,
  2249. "cfm": 0,
  2250. "cfof": 0,
  2251. "b": 0,
  2252. "l": 0,
  2253. "d": 0,
  2254. "tbr": 0,
  2255. "sgr": 0,
  2256. "jS_ES": 0,
  2257. "suite": 0,
  2258. "accon": "",
  2259. "tv": 0,
  2260. "iL": 0,
  2261. "if": 0,
  2262. "ef": 0,
  2263. "b_R_F": 0,
  2264. "te": 0,
  2265. "tgTips": 0,
  2266. "drvTips": 0,
  2267. "pc": 0,
  2268. "tlf": 0,
  2269. "ect": 0,
  2270. "id": 1,
  2271. }
  2272. )
  2273. },
  2274. loadData(id) {
  2275. this.costloading = true;
  2276. this.tableData = [];
  2277. var that = this;
  2278. this.$axios.post('/api/Groups/GroupCostInit', {
  2279. Diid: id
  2280. }, {
  2281. headers: {
  2282. 'Authorization': that.token,
  2283. }
  2284. }).then(resp => {
  2285. console.log(resp.data.data, '------------------------------------');
  2286. if (resp.data.code == 200) {
  2287. that.options = resp.data.data.groupList;
  2288. that.grouptitleinfo = resp.data.data.groupInfo.data;
  2289. that.diid = that.grouptitleinfo.id;
  2290. for (var i = 0; i < that.CheckBoxListSelect.length; i++) {
  2291. that.CheckBoxListSelect[i].diid = that.diid;
  2292. }
  2293. if (resp.data.data.groupChecks.length > 0) {
  2294. resp.data.data.groupChecks.forEach(item => {
  2295. for (var i = 0; i < that.CheckBoxListSelect.length; i++) {
  2296. if (item.cbType == that.CheckBoxListSelect[i].cbType) {
  2297. that.CheckBoxListSelect[i].cbValues = item.cbValues.split(',');
  2298. console.log(item.cbValues.split(','));
  2299. break;
  2300. }
  2301. if (that.CheckBoxListSelect[i].diid == 0) {
  2302. that.CheckBoxListSelect[i].diid = that.diid;
  2303. }
  2304. }
  2305. })
  2306. } else {
  2307. that.CheckBoxListSelect = [
  2308. {
  2309. "diid": that.diid,
  2310. "cbType": "Top",
  2311. "cbValues": ['DAY', 'ITIN', 'VA', 'VF', 'VRD', 'T/G S', 'DATE'] //"string"
  2312. },
  2313. {
  2314. "diid": that.diid,
  2315. "cbType": "Left",
  2316. "cbValues": ['签证', '机票', '核酸检测',] //"string"
  2317. },
  2318. {
  2319. "diid": that.diid,
  2320. "cbType": "Right",
  2321. "cbValues": ['经济舱 TBR', '经济舱 SGR', '团组预算明细'] //"string"
  2322. }
  2323. ]
  2324. }
  2325. that.grouptitleinfo.visitStartDate = that.grouptitleinfo.visitStartDate.split(' ')[0];
  2326. that.grouptitleinfo.visitEndDate = that.grouptitleinfo.visitEndDate.split(' ')[0];
  2327. that.peopleNumber = that.grouptitleinfo.visitPNumber > 0 ? that.grouptitleinfo.visitPNumber : 1;
  2328. if (resp.data.data.groupCost.length > 0) {
  2329. that.tableData = resp.data.data.groupCost;
  2330. } else {
  2331. that.tableData = [
  2332. {
  2333. "diid": that.diid,
  2334. "day": "-",
  2335. "date": "",
  2336. "itin": "",
  2337. "carType": "",
  2338. "carCost": 0,
  2339. "carNumber": 0,
  2340. "carTiming": 0,
  2341. "tgs": 0,
  2342. "tgwh": 0,
  2343. "tgn": 0,
  2344. "tgof": 0,
  2345. "tgm": 0,
  2346. "tga": 0,
  2347. "tgtf": 0,
  2348. "tgef": 0,
  2349. "cfs": 0,
  2350. "cfm": 0,
  2351. "cfof": 0,
  2352. "b": 0,
  2353. "l": 0,
  2354. "d": 0,
  2355. "tbr": 0,
  2356. "sgr": 0,
  2357. "jS_ES": 0,
  2358. "suite": 0,
  2359. "accon": "",
  2360. "tv": 0,
  2361. "iL": 0,
  2362. "if": 0,
  2363. "ef": 0,
  2364. "b_R_F": 0,
  2365. "te": 0,
  2366. "tgTips": 0,
  2367. "drvTips": 0,
  2368. "pc": 0,
  2369. "tlf": 0,
  2370. "ect": 0,
  2371. "id": 1,
  2372. }
  2373. ]
  2374. }
  2375. if (resp.data.data.groupCostParameter.length > 0) {
  2376. var acostvalue = resp.data.data.groupCostParameter.filter(x => x.costType == 'A')[0];
  2377. if (acostvalue != undefined) {
  2378. that.AGroupCostParameter = acostvalue;
  2379. } else {
  2380. that.AGroupCostParameter = {
  2381. "id": 0,
  2382. "diId": 0,
  2383. "currency": "CNY",
  2384. "rate": 0,
  2385. "tax": 0,
  2386. "ffys": 0,
  2387. "hotelXS": 0,
  2388. "jjccb": 0,
  2389. "jjcxs": 0,
  2390. "jjcrs": 0,
  2391. "gwccb": 0,
  2392. "gwcxs": 0,
  2393. "gwcrs": 0,
  2394. "hcpcb": 0,
  2395. "hcpxs": 0,
  2396. "hcprs": 0,
  2397. "cpcb": 0,
  2398. "cpxs": 0,
  2399. "cprs": 0,
  2400. "bxcb": 0,
  2401. "bxxs": 0,
  2402. "bxrs": 0,
  2403. "hscb": 0,
  2404. "hsxs": 0,
  2405. "hsrs": 0,
  2406. "visaCB": 0,
  2407. "visaXS": 0,
  2408. "visaRS": 0,
  2409. "gwcb": 0,
  2410. "gwxs": 0,
  2411. "gwrs": 0,
  2412. "djcb": 0,
  2413. "djrs": 0,
  2414. "djxs": 0,
  2415. "sgrcb": 0,
  2416. "sgrNumber": 0,
  2417. "sgrxs": 0,
  2418. "tbrcb": 0,
  2419. "tbrNumber": 0,
  2420. "tbrxs": 0,
  2421. "jsescb": 0,
  2422. "jsesNumber": 0,
  2423. "jsesxs": 0,
  2424. "suitecb": 0,
  2425. "suiteNumber": 0,
  2426. "suitexs": 0,
  2427. "lyjcb": 0,
  2428. "lyjxs": 0,
  2429. "lyjrs": 0,
  2430. "isShare": 0,
  2431. "costType": "A",
  2432. "costTypeStartTime": "",
  2433. "costTypeendTime": "",
  2434. "costTypenumber": 0
  2435. };
  2436. }
  2437. var bcostvalue = resp.data.data.groupCostParameter.filter(x => x.costType == 'B')[0];
  2438. if (bcostvalue != undefined) {
  2439. that.BGroupCostParameter = bcostvalue;
  2440. } else {
  2441. that.BGroupCostParameter = {
  2442. "id": 0,
  2443. "diId": 0,
  2444. "currency": "",
  2445. "rate": 0,
  2446. "tax": 0,
  2447. "ffys": 0,
  2448. "hotelXS": 0,
  2449. "jjccb": 0,
  2450. "jjcxs": 0,
  2451. "jjcrs": 0,
  2452. "gwccb": 0,
  2453. "gwcxs": 0,
  2454. "gwcrs": 0,
  2455. "hcpcb": 0,
  2456. "hcpxs": 0,
  2457. "hcprs": 0,
  2458. "cpcb": 0,
  2459. "cpxs": 0,
  2460. "cprs": 0,
  2461. "bxcb": 0,
  2462. "bxxs": 0,
  2463. "bxrs": 0,
  2464. "hscb": 0,
  2465. "hsxs": 0,
  2466. "hsrs": 0,
  2467. "visaCB": 0,
  2468. "visaXS": 0,
  2469. "visaRS": 0,
  2470. "gwcb": 0,
  2471. "gwxs": 0,
  2472. "gwrs": 0,
  2473. "djcb": 0,
  2474. "djxs": 0,
  2475. "djrs": 0,
  2476. "sgrcb": 0,
  2477. "sgrNumber": 0,
  2478. "sgrxs": 0,
  2479. "tbrcb": 0,
  2480. "tbrNumber": 0,
  2481. "tbrxs": 0,
  2482. "jsescb": 0,
  2483. "jsesNumber": 0,
  2484. "jsesxs": 0,
  2485. "suitecb": 0,
  2486. "suiteNumber": 0,
  2487. "suitexs": 0,
  2488. "lyjcb": 0,
  2489. "lyjxs": 0,
  2490. "lyjrs": 0,
  2491. "isShare": 0,
  2492. "costType": "B",
  2493. "costTypeStartTime": "",
  2494. "costTypeendTime": "",
  2495. "costTypenumber": 0
  2496. };
  2497. }
  2498. if (resp.data.data.groupCostParameter.length > 1) {
  2499. that.costTypevalue = "B";
  2500. } else {
  2501. that.costTypevalue = "A";
  2502. }
  2503. if (that.AGroupCostParameter.costTypeStartTime) {
  2504. that.AGroupCostParameter.costTypeStartTime = new Date(that.AGroupCostParameter.costTypeStartTime);
  2505. }
  2506. if (that.AGroupCostParameter.costTypeendTime) {
  2507. that.AGroupCostParameter.costTypeendTime = new Date(that.AGroupCostParameter.costTypeendTime);
  2508. }
  2509. if (that.BGroupCostParameter.costTypeStartTime) {
  2510. that.BGroupCostParameter.costTypeStartTime = new Date(that.BGroupCostParameter.costTypeStartTime);
  2511. }
  2512. if (that.BGroupCostParameter.costTypeendTime) {
  2513. that.BGroupCostParameter.costTypeendTime = new Date(that.BGroupCostParameter.costTypeendTime);
  2514. }
  2515. } else {
  2516. that.AGroupCostParameter = {
  2517. "id": 0,
  2518. "diId": 0,
  2519. "currency": "CNY",
  2520. "rate": 0,
  2521. "tax": 0,
  2522. "ffys": 0,
  2523. "hotelXS": 0,
  2524. "jjccb": 0,
  2525. "jjcxs": 0,
  2526. "jjcrs": 0,
  2527. "gwccb": 0,
  2528. "gwcxs": 0,
  2529. "gwcrs": 0,
  2530. "hcpcb": 0,
  2531. "hcpxs": 0,
  2532. "hcprs": 0,
  2533. "cpcb": 0,
  2534. "cpxs": 0,
  2535. "cprs": 0,
  2536. "bxcb": 0,
  2537. "bxxs": 0,
  2538. "bxrs": 0,
  2539. "hscb": 0,
  2540. "hsxs": 0,
  2541. "hsrs": 0,
  2542. "visaCB": 0,
  2543. "visaXS": 0,
  2544. "visaRS": 0,
  2545. "gwcb": 0,
  2546. "gwxs": 0,
  2547. "gwrs": 0,
  2548. "djcb": 0,
  2549. "djrs": 0,
  2550. "djxs": 0,
  2551. "sgrcb": 0,
  2552. "sgrNumber": 0,
  2553. "sgrxs": 0,
  2554. "tbrcb": 0,
  2555. "tbrNumber": 0,
  2556. "tbrxs": 0,
  2557. "jsescb": 0,
  2558. "jsesNumber": 0,
  2559. "jsesxs": 0,
  2560. "suitecb": 0,
  2561. "suiteNumber": 0,
  2562. "suitexs": 0,
  2563. "lyjcb": 0,
  2564. "lyjxs": 0,
  2565. "lyjrs": 0,
  2566. "isShare": 0,
  2567. "costType": "A",
  2568. "costTypeStartTime": "",
  2569. "costTypeendTime": "",
  2570. "costTypenumber": 0
  2571. };
  2572. that.BGroupCostParameter = {
  2573. "id": 0,
  2574. "diId": 0,
  2575. "currency": "",
  2576. "rate": 0,
  2577. "tax": 0,
  2578. "ffys": 0,
  2579. "hotelXS": 0,
  2580. "jjccb": 0,
  2581. "jjcxs": 0,
  2582. "jjcrs": 0,
  2583. "gwccb": 0,
  2584. "gwcxs": 0,
  2585. "gwcrs": 0,
  2586. "hcpcb": 0,
  2587. "hcpxs": 0,
  2588. "hcprs": 0,
  2589. "cpcb": 0,
  2590. "cpxs": 0,
  2591. "cprs": 0,
  2592. "bxcb": 0,
  2593. "bxxs": 0,
  2594. "bxrs": 0,
  2595. "hscb": 0,
  2596. "hsxs": 0,
  2597. "hsrs": 0,
  2598. "visaCB": 0,
  2599. "visaXS": 0,
  2600. "visaRS": 0,
  2601. "gwcb": 0,
  2602. "gwxs": 0,
  2603. "gwrs": 0,
  2604. "djcb": 0,
  2605. "djxs": 0,
  2606. "djrs": 0,
  2607. "sgrcb": 0,
  2608. "sgrNumber": 0,
  2609. "sgrxs": 0,
  2610. "tbrcb": 0,
  2611. "tbrNumber": 0,
  2612. "tbrxs": 0,
  2613. "jsescb": 0,
  2614. "jsesNumber": 0,
  2615. "jsesxs": 0,
  2616. "suitecb": 0,
  2617. "suiteNumber": 0,
  2618. "suitexs": 0,
  2619. "lyjcb": 0,
  2620. "lyjxs": 0,
  2621. "lyjrs": 0,
  2622. "isShare": 0,
  2623. "costType": "B",
  2624. "costTypeStartTime": "",
  2625. "costTypeendTime": "",
  2626. "costTypenumber": 0
  2627. };
  2628. that.AGroupCostParameter.diId = that.diid;
  2629. that.BGroupCostParameter.diId = that.diid;
  2630. that.costTypevalue = 'A';
  2631. }
  2632. let hotelNumber = resp.data.data.hotelNumber;
  2633. if (hotelNumber.length > 0) {
  2634. for (var i = 0; i < hotelNumber.length; i++) {
  2635. //替换costTypeHotelNumbers ;
  2636. Array.forEach(that.costTypeHotelNumbers, (item, index) => {
  2637. if (hotelNumber[i]['type'] == item.type) {
  2638. that.$set(that.costTypeHotelNumbers, index, hotelNumber[i]);
  2639. }
  2640. })
  2641. }
  2642. } else {
  2643. that.costTypeHotelNumbers = [{
  2644. "sgr": 0,
  2645. "tbr": 0,
  2646. "jses": 0,
  2647. "suite": 0,
  2648. "type": "Default",
  2649. "diid": 0,
  2650. id: 0,
  2651. },
  2652. {
  2653. "sgr": 0,
  2654. "tbr": 0,
  2655. "jses": 0,
  2656. "suite": 0,
  2657. "type": "A",
  2658. "diid": 0,
  2659. id: 0,
  2660. },
  2661. {
  2662. "sgr": 0,
  2663. "tbr": 0,
  2664. "jses": 0,
  2665. "suite": 0,
  2666. "type": "B",
  2667. "diid": 0,
  2668. id: 0,
  2669. }]
  2670. }
  2671. }
  2672. that.costloading = false;
  2673. }).catch(err => {
  2674. that.costloading = false;
  2675. this.$message({
  2676. message: '网络异常!',
  2677. type: 'error'
  2678. });
  2679. })
  2680. },
  2681. groupChange() {
  2682. this.clearFormVerify();
  2683. this.loadData(this.diid);
  2684. },
  2685. async save() {
  2686. var that = this;
  2687. var Data = { diid: this.diid, userid: this.userId };
  2688. var isTrue = await this.formVerify();
  2689. if (isTrue) {
  2690. Data.checkBoxs = this.CheckBoxListSelect.map(x => {
  2691. return {
  2692. diid: x.diid,
  2693. cbType: x.cbType,
  2694. cbValues: x.cbValues.join(',')
  2695. };
  2696. });
  2697. Data.groupCosts = this.tableData;
  2698. Data.costTypeHotelNumbers = this.costTypeHotelNumbers.map(x => {
  2699. return {
  2700. id: x.id,
  2701. sgr: x.sgr,
  2702. tbr: x.tbr,
  2703. jses: x.jses,
  2704. suite: x.suite,
  2705. type: x.type,
  2706. diid: that.diid
  2707. };
  2708. });
  2709. this.AGroupCostParameter.diId = this.diid;
  2710. this.BGroupCostParameter.diId = this.diid;
  2711. var Aparam = Object.assign({}, this.AGroupCostParameter);
  2712. var Bparam = Object.assign({}, this.BGroupCostParameter);
  2713. if (that.AGroupCostParameter.costTypeStartTime) {
  2714. Aparam.costTypeStartTime = this.addOneDay(that.AGroupCostParameter.costTypeStartTime, 0);
  2715. }
  2716. if (that.AGroupCostParameter.costTypeendTime) {
  2717. Aparam.costTypeendTime = this.addOneDay(that.AGroupCostParameter.costTypeendTime, 0);
  2718. }
  2719. if (that.BGroupCostParameter.costTypeStartTime) {
  2720. Bparam.costTypeStartTime = this.addOneDay(that.BGroupCostParameter.costTypeStartTime, 0);
  2721. }
  2722. if (that.BGroupCostParameter.costTypeendTime) {
  2723. Bparam.costTypeendTime = this.addOneDay(that.BGroupCostParameter.costTypeendTime, 0);
  2724. }
  2725. if (this.costTypevalue == "A") {
  2726. Data.groupCostParameters = [Aparam];
  2727. } else {
  2728. Data.groupCostParameters = [Aparam, Bparam];
  2729. }
  2730. console.log(Data, "save-------Data");
  2731. var that = this;
  2732. this.$axios.post('/api/Groups/SaveGroupCost', Data, {
  2733. headers: {
  2734. 'Authorization': that.token,
  2735. }
  2736. }).then(resp => {
  2737. console.log(resp.data.data, '------------------------------------');
  2738. if (resp.data.code == 200) {
  2739. this.$message({
  2740. message: '保存成功!',
  2741. type: 'success'
  2742. });
  2743. } else {
  2744. this.$message.error('保存失败!' + resp.data.msg);
  2745. }
  2746. })
  2747. } else {
  2748. this.$message.error('请输入完整!');
  2749. }
  2750. },
  2751. TopChange() {
  2752. },
  2753. calculateZCB(EnLabelParam) {
  2754. if (EnLabelParam == undefined) {
  2755. return 0.00;
  2756. }
  2757. var sum = 0.00;
  2758. if (this.AGroupCostParameter[EnLabelParam + 'CB'] != undefined) {
  2759. sum = (parseFloat(this.AGroupCostParameter[EnLabelParam + 'CB']) * parseInt(this.AGroupCostParameter[EnLabelParam + 'RS']));
  2760. } else if (this.AGroupCostParameter[EnLabelParam + 'cb'] != undefined) {
  2761. sum = (parseFloat(this.AGroupCostParameter[EnLabelParam + 'cb']) * parseInt(this.AGroupCostParameter[EnLabelParam + 'rs'] != undefined ? this.AGroupCostParameter[EnLabelParam + 'rs'] : this.AGroupCostParameter[EnLabelParam + 'Number']));
  2762. }
  2763. if (isNaN(sum)) {
  2764. sum = 0.00;
  2765. }
  2766. return sum.toFixed(2);
  2767. },
  2768. calculateDRBJ(EnLabelParam) {
  2769. if (EnLabelParam == undefined) {
  2770. return 0.00;
  2771. }
  2772. var sum = 0.00;
  2773. if (this.AGroupCostParameter[EnLabelParam + 'CB'] != undefined) {
  2774. sum = (parseFloat(this.AGroupCostParameter[EnLabelParam + 'CB']) * parseFloat(this.AGroupCostParameter[EnLabelParam + 'XS']));
  2775. } else if (this.AGroupCostParameter[EnLabelParam + 'cb'] != undefined) {
  2776. sum = (parseFloat(this.AGroupCostParameter[EnLabelParam + 'cb']) * parseFloat(this.AGroupCostParameter[EnLabelParam + 'xs']));
  2777. }
  2778. if (isNaN(sum)) {
  2779. sum = 0.00;
  2780. }
  2781. return sum.toFixed(2);
  2782. },
  2783. calculateZBJ(EnLabelParam) {
  2784. if (EnLabelParam == undefined) {
  2785. return 0.00;
  2786. }
  2787. var sum = 0.00;
  2788. var drbj = this.calculateDRBJ(EnLabelParam);
  2789. if (this.AGroupCostParameter[EnLabelParam + 'RS'] != undefined) {
  2790. sum = drbj * parseInt(this.AGroupCostParameter[EnLabelParam + 'RS']);
  2791. } else if (this.AGroupCostParameter[EnLabelParam + 'rs'] != undefined) {
  2792. sum = drbj * parseInt(this.AGroupCostParameter[EnLabelParam + 'rs']);
  2793. } else if (this.AGroupCostParameter[EnLabelParam + 'Number'] != undefined) {
  2794. sum = drbj * parseInt(this.AGroupCostParameter[EnLabelParam + 'Number']);
  2795. }
  2796. if (isNaN(sum)) {
  2797. sum = 0.00;
  2798. }
  2799. return sum.toFixed(2);
  2800. },
  2801. calculateDRLR(EnLabelParam) {
  2802. if (EnLabelParam == undefined) {
  2803. return 0.00;
  2804. }
  2805. var sum = 0.00;
  2806. var drbj = this.calculateDRBJ(EnLabelParam);
  2807. if (this.AGroupCostParameter[EnLabelParam + 'CB'] != undefined) {
  2808. sum = (drbj - parseFloat(this.AGroupCostParameter[EnLabelParam + 'CB']));
  2809. } else if (this.AGroupCostParameter[EnLabelParam + 'cb'] != undefined) {
  2810. sum = (drbj - parseFloat(this.AGroupCostParameter[EnLabelParam + 'cb']));
  2811. }
  2812. if (isNaN(sum)) {
  2813. sum = 0.00;
  2814. }
  2815. return sum.toFixed(2);
  2816. },
  2817. calculateZLR(EnLabelParam) {
  2818. if (EnLabelParam == undefined) {
  2819. return 0.00;
  2820. }
  2821. var sum = 0.00;
  2822. var drlr = this.calculateDRLR(EnLabelParam);
  2823. if (this.AGroupCostParameter[EnLabelParam + 'RS'] != undefined) {
  2824. sum = drlr * parseInt(this.AGroupCostParameter[EnLabelParam + 'RS']);
  2825. } else if (this.AGroupCostParameter[EnLabelParam + 'rs'] != undefined) {
  2826. sum = drlr * parseInt(this.AGroupCostParameter[EnLabelParam + 'rs']);
  2827. }
  2828. if (isNaN(sum)) {
  2829. sum = 0.00;
  2830. }
  2831. return sum.toFixed(2);
  2832. },
  2833. BcalculateZCB(EnLabelParam) {
  2834. if (EnLabelParam == undefined) {
  2835. return 0.00;
  2836. }
  2837. var sum = 0.00;
  2838. if (this.BGroupCostParameter[EnLabelParam + 'CB'] != undefined) {
  2839. sum = (parseFloat(this.BGroupCostParameter[EnLabelParam + 'CB']) * parseInt(this.BGroupCostParameter[EnLabelParam + 'RS']));
  2840. } else if (this.BGroupCostParameter[EnLabelParam + 'cb'] != undefined) {
  2841. sum = (parseFloat(this.BGroupCostParameter[EnLabelParam + 'cb']) * parseInt(this.BGroupCostParameter[EnLabelParam + 'rs'] != undefined ? this.BGroupCostParameter[EnLabelParam + 'rs'] : this.BGroupCostParameter[EnLabelParam + 'Number']));
  2842. }
  2843. if (isNaN(sum)) {
  2844. sum = 0.00;
  2845. }
  2846. return sum.toFixed(2);;
  2847. },
  2848. BcalculateDRBJ(EnLabelParam) {
  2849. if (EnLabelParam == undefined) {
  2850. return 0.00;
  2851. }
  2852. var sum = 0.00;
  2853. if (this.BGroupCostParameter[EnLabelParam + 'CB'] != undefined) {
  2854. sum = (parseFloat(this.BGroupCostParameter[EnLabelParam + 'CB']) * parseFloat(this.BGroupCostParameter[EnLabelParam + 'XS']));
  2855. } else if (this.BGroupCostParameter[EnLabelParam + 'cb'] != undefined) {
  2856. sum = (parseFloat(this.BGroupCostParameter[EnLabelParam + 'cb']) * parseFloat(this.BGroupCostParameter[EnLabelParam + 'xs']));
  2857. }
  2858. if (isNaN(sum)) {
  2859. sum = 0.00;
  2860. }
  2861. return sum.toFixed(2);;
  2862. },
  2863. BcalculateZBJ(EnLabelParam) {
  2864. if (EnLabelParam == undefined) {
  2865. return 0.00;
  2866. }
  2867. var sum = 0.00;
  2868. var drbj = this.BcalculateDRBJ(EnLabelParam);
  2869. if (this.BGroupCostParameter[EnLabelParam + 'RS'] != undefined) {
  2870. sum = drbj * parseInt(this.BGroupCostParameter[EnLabelParam + 'RS']);
  2871. } else if (this.BGroupCostParameter[EnLabelParam + 'rs'] != undefined) {
  2872. sum = drbj * parseInt(this.BGroupCostParameter[EnLabelParam + 'rs']);
  2873. } else if (this.BGroupCostParameter[EnLabelParam + 'Number'] != undefined) {
  2874. sum = drbj * parseInt(this.BGroupCostParameter[EnLabelParam + 'Number']);
  2875. }
  2876. if (isNaN(sum)) {
  2877. sum = 0.00;
  2878. }
  2879. return sum.toFixed(2);
  2880. },
  2881. BcalculateDRLR(EnLabelParam) {
  2882. if (EnLabelParam == undefined) {
  2883. return 0.00;
  2884. }
  2885. var sum = 0.00;
  2886. var drbj = this.BcalculateDRBJ(EnLabelParam);
  2887. if (this.BGroupCostParameter[EnLabelParam + 'CB'] != undefined) {
  2888. sum = drbj - parseFloat(this.BGroupCostParameter[EnLabelParam + 'CB']);
  2889. } else if (this.BGroupCostParameter[EnLabelParam + 'cb'] != undefined) {
  2890. sum = drbj - parseFloat(this.BGroupCostParameter[EnLabelParam + 'cb']);
  2891. }
  2892. if (isNaN(sum)) {
  2893. sum = 0.00;
  2894. }
  2895. return sum.toFixed(2);;
  2896. },
  2897. BcalculateZLR(EnLabelParam) {
  2898. if (EnLabelParam == undefined) {
  2899. return 0.00;
  2900. }
  2901. var sum = 0.00;
  2902. var drlr = this.BcalculateDRLR(EnLabelParam);
  2903. if (this.BGroupCostParameter[EnLabelParam + 'RS'] != undefined) {
  2904. sum = drlr * parseInt(this.BGroupCostParameter[EnLabelParam + 'RS']);
  2905. } else if (this.BGroupCostParameter[EnLabelParam + 'rs'] != undefined) {
  2906. sum = drlr * parseInt(this.BGroupCostParameter[EnLabelParam + 'rs']);
  2907. }
  2908. if (isNaN(sum)) {
  2909. sum = 0.00;
  2910. }
  2911. return sum.toFixed(2);;
  2912. },
  2913. handleCurrentChange(val) {
  2914. this.currentPage = val;
  2915. },
  2916. SelChange(row, oldrow) {
  2917. console.log(row, oldrow);
  2918. },
  2919. handleSizeChange(val) {
  2920. this.currentPage = 1;
  2921. this.pageSize = val;
  2922. },
  2923. CalculatedPrice() {
  2924. let rate = Number(this.AGroupCostParameter.rate);
  2925. let Djsum = 0;
  2926. let BDjsum = 0;
  2927. var that = this;
  2928. this.DJLables.forEach(function (item) {
  2929. that.sumTopPrice.forEach(function (item1) {
  2930. if (item == item1.label) {
  2931. var Aprice = Number(item1.Aprice);
  2932. if (!isNaN(Aprice)) {
  2933. Djsum += Aprice;
  2934. }
  2935. var Bprice = Number(item1.Bprice);
  2936. if (!isNaN(Bprice)) {
  2937. BDjsum += Bprice;
  2938. }
  2939. }
  2940. })
  2941. })
  2942. Djsum = Number((Djsum * rate).toFixed(2));
  2943. BDjsum = Number((BDjsum * rate).toFixed(2));
  2944. let GWsum = 0;
  2945. let BGWsum = 0;
  2946. this.GwLables.forEach(function (item) {
  2947. that.sumTopPrice.forEach(function (item1) {
  2948. if (item == item1.label) {
  2949. var Aprice = Number(item1.Aprice);
  2950. if (!isNaN(Aprice)) {
  2951. GWsum += Aprice;
  2952. }
  2953. var Bprice = Number(item1.Bprice);
  2954. if (!isNaN(Bprice)) {
  2955. BGWsum += Bprice;
  2956. }
  2957. }
  2958. })
  2959. })
  2960. GWsum = Number((GWsum * rate).toFixed(2));
  2961. BGWsum = Number((BGWsum * rate).toFixed(2));
  2962. let LYJsum = 0;
  2963. let BLYJsum = 0;
  2964. var lyjList = that.sumTopPrice.filter((x) => {
  2965. return x.label == 'P/C';
  2966. })
  2967. if (lyjList.length > 0) {
  2968. LYJsum = lyjList[0].Aprice;
  2969. BLYJsum = lyjList[0].Bprice;
  2970. }
  2971. LYJsum = isNaN(LYJsum) ? 0 : LYJsum;
  2972. BLYJsum = isNaN(BLYJsum) ? 0 : BLYJsum;
  2973. LYJsum = Number((LYJsum * rate).toFixed(2));
  2974. BLYJsum = Number((BLYJsum * rate).toFixed(2));
  2975. let SGRsum = 0;
  2976. let BSGRsum = 0;
  2977. var SGRList = that.sumTopPrice.filter((x) => {
  2978. return x.label == 'SGR';
  2979. })
  2980. if (SGRList.length > 0) {
  2981. SGRsum = SGRList[0].Aprice;
  2982. BSGRsum = SGRList[0].Bprice;
  2983. }
  2984. SGRsum = isNaN(SGRsum) ? 0 : SGRsum;
  2985. BSGRsum = isNaN(BSGRsum) ? 0 : BSGRsum;
  2986. SGRsum = (SGRsum * rate).toFixed(2);
  2987. BSGRsum = (BSGRsum * rate).toFixed(2);
  2988. let TBRsum = 0;
  2989. let BTBRsum = 0;
  2990. var TBRList = that.sumTopPrice.filter((x) => {
  2991. return x.label == 'TBR';
  2992. })
  2993. if (TBRList.length > 0) {
  2994. TBRsum = TBRList[0].Aprice;
  2995. BTBRsum = TBRList[0].Bprice;
  2996. }
  2997. TBRsum = isNaN(TBRsum) ? 0 : TBRsum;
  2998. BTBRsum = isNaN(BTBRsum) ? 0 : BTBRsum;
  2999. TBRsum = TBRsum * rate;
  3000. BTBRsum = BTBRsum * rate;
  3001. let JSESsum = 0;
  3002. let BJSESsum = 0;
  3003. var JSESList = that.sumTopPrice.filter((x) => {
  3004. return x.label == 'JS/ES';
  3005. })
  3006. if (JSESList.length > 0) {
  3007. JSESsum = JSESList[0].Aprice;
  3008. BJSESsum = JSESList[0].Bprice;
  3009. }
  3010. JSESsum = isNaN(JSESsum) ? 0 : JSESsum;
  3011. BJSESsum = isNaN(BJSESsum) ? 0 : BJSESsum;
  3012. JSESsum = JSESsum * rate;
  3013. BJSESsum = BJSESsum * rate;
  3014. let SUITEsum = 0;
  3015. let BSUITEsum = 0;
  3016. var SUITEList = that.sumTopPrice.filter((x) => {
  3017. return x.label == 'SUITE';
  3018. })
  3019. if (SUITEList.length > 0) {
  3020. SUITEsum = SUITEList[0].Aprice;
  3021. BSUITEsum = SUITEList[0].Bprice;
  3022. }
  3023. SUITEsum = isNaN(SUITEsum) ? 0 : SUITEsum;
  3024. BSUITEsum = isNaN(BSUITEsum) ? 0 : BSUITEsum;
  3025. SUITEsum = SUITEsum * rate;
  3026. BSUITEsum = BSUITEsum * rate;
  3027. // console.log(Djsum, GWsum, LYJsum, 'Djsum,GWsum,LYJsum');
  3028. // console.log(SGRsum, TBRsum, JSESsum, SUITEsum, 'SGRsum,TBRsum,JSESsum,SUITEsum');
  3029. var sgrfilter = this.costTypeHotelNumbers.filter(x => {
  3030. return x.type == 'Default'
  3031. })
  3032. let Bsgrfilter = {};
  3033. if (this.costTypevalue == 'B') {
  3034. sgrfilter = this.costTypeHotelNumbers.filter(x => {
  3035. return x.type == 'A'
  3036. })
  3037. Bsgrfilter = this.costTypeHotelNumbers.filter(x => {
  3038. return x.type == 'B'
  3039. })
  3040. Bsgrfilter = Bsgrfilter[0];
  3041. }
  3042. sgrfilter = sgrfilter[0];
  3043. let hotelRooms = {
  3044. "SGR": sgrfilter.sgr,
  3045. "TBR": sgrfilter.tbr,
  3046. "JSES": sgrfilter.jses,
  3047. "SUITE": sgrfilter.suite
  3048. };
  3049. let flights = {
  3050. "经济舱": this.AGroupCostParameter.jjcrs,
  3051. "公务舱": this.AGroupCostParameter.gwcrs
  3052. };
  3053. let result = {};
  3054. for (let flight of ["经济舱", "公务舱"]) {
  3055. if (flight === "经济舱") {
  3056. this.matchRooms(hotelRooms, flights, ["SGR", "TBR", "JSES", "SUITE"], flight, result);
  3057. } else if (flight === "公务舱") {
  3058. this.matchRooms(hotelRooms, flights, ["SUITE", "JSES", "SGR", "TBR"], flight, result);
  3059. }
  3060. }
  3061. if (this.costTypevalue == 'B') {
  3062. let BhotelRooms = {
  3063. "SGR": Bsgrfilter.sgr,
  3064. "TBR": Bsgrfilter.tbr,
  3065. "JSES": Bsgrfilter.jses,
  3066. "SUITE": Bsgrfilter.suite
  3067. };
  3068. let Bflights = {
  3069. "经济舱": this.BGroupCostParameter.jjcrs,
  3070. "公务舱": this.BGroupCostParameter.gwcrs
  3071. };
  3072. let Bresult = {};
  3073. for (let flight of ["经济舱", "公务舱"]) {
  3074. if (flight === "经济舱") {
  3075. this.matchRooms(BhotelRooms, Bflights, ["SGR", "TBR", "JSES", "SUITE"], flight, Bresult);
  3076. } else if (flight === "公务舱") {
  3077. this.matchRooms(BhotelRooms, Bflights, ["SUITE", "JSES", "SGR", "TBR"], flight, Bresult);
  3078. }
  3079. }
  3080. var BtxtJJCSGRRS = (Bresult.hasOwnProperty("经济舱SGR") ? Bresult["经济舱SGR"] : 0)
  3081. var BlblGWCSGRRS = (Bresult.hasOwnProperty("公务舱SGR") ? Bresult["公务舱SGR"] : 0)
  3082. var BtxtJJCTBRRS = (Bresult.hasOwnProperty("经济舱TBR") ? Bresult["经济舱TBR"] * 2 : 0)
  3083. var BtxtGWCJSESRS = (Bresult.hasOwnProperty("公务舱JSES") ? Bresult["公务舱JSES"] : 0)
  3084. var BJJCSUITERS = (Bresult.hasOwnProperty("经济舱SUITE") ? Bresult["经济舱SUITE"] : 0)
  3085. var BtxtGWCSUITERS = (Bresult.hasOwnProperty("公务舱SUITE") ? Bresult["公务舱SUITE"] : 0)
  3086. this.BcabinDatal[0].sheetInfo[0].toll = BtxtJJCTBRRS;
  3087. this.BcabinDatal[1].sheetInfo[0].toll = BtxtJJCSGRRS;
  3088. this.BcabinDatal[2].sheetInfo[0].toll = BlblGWCSGRRS;
  3089. this.BcabinDatal[3].sheetInfo[0].toll = BtxtGWCJSESRS;
  3090. this.BcabinDatal[4].sheetInfo[0].toll = BtxtGWCSUITERS;
  3091. this.BcabinDatal[5].sheetInfo[0].toll = BJJCSUITERS;
  3092. this.BGroupCostParameter.djcb = BDjsum;
  3093. this.BGroupCostParameter.gwcb = BGWsum;
  3094. this.BGroupCostParameter.lyjcb = BLYJsum;
  3095. this.BGroupCostParameter.sgrcb = BSGRsum;
  3096. this.BGroupCostParameter.tbrcb = BTBRsum;
  3097. this.BGroupCostParameter.jsescb = BJSESsum;
  3098. this.BGroupCostParameter.suitecb = BSUITEsum;
  3099. var BleftSum = this.BOtherCost();
  3100. let BJJCSGR = (BleftSum + Number(this.BGroupCostParameter.sgrcb) + Number(this.BGroupCostParameter.jjccb));
  3101. let BJJCTBR = BleftSum + Number(this.BGroupCostParameter.tbrcb) + Number(this.BGroupCostParameter.jjccb);
  3102. let BJJCSUITE = BleftSum + Number(this.BGroupCostParameter.suitecb) + Number(this.BGroupCostParameter.jjccb);
  3103. let BGWCSUITE = BleftSum + Number(this.BGroupCostParameter.suitecb) + Number(this.BGroupCostParameter.gwccb);
  3104. let BGWCSGR = BleftSum + Number(this.BGroupCostParameter.sgrcb) + Number(this.BGroupCostParameter.gwccb);
  3105. let BGWCJSES = BleftSum + Number(this.BGroupCostParameter.jsescb) + Number(this.BGroupCostParameter.gwccb);
  3106. BJJCSGR = BJJCSGR.toFixed(2);
  3107. var BrightSum = 0;
  3108. this.OtherCostPropertyBJ.forEach((x) => {
  3109. BrightSum += Number(that.BcalculateDRBJ(x));
  3110. })
  3111. let BJJCSGRDRBJ = BrightSum + Number(that.BcalculateDRBJ('jjc')) + Number(that.BcalculateDRBJ('sgr'));
  3112. let BJJCTBRDRBJ = BrightSum + Number(that.BcalculateDRBJ('tbr')) + Number(that.BcalculateDRBJ('jjc'));
  3113. let BJJCSUITEDRBJ = BrightSum + Number(that.BcalculateDRBJ('suite')) + Number(that.BcalculateDRBJ('jjc'));
  3114. let BGWCSUITEDRBJ = BrightSum + Number(that.BcalculateDRBJ('suite')) + Number(that.BcalculateDRBJ('gwc'));
  3115. let BGWCSGRDRBJ = BrightSum + Number(that.BcalculateDRBJ('sgr')) + Number(that.BcalculateDRBJ('gwc'));
  3116. let BGWCJSESDRBJ = BrightSum + Number(that.BcalculateDRBJ('jses')) + Number(that.BcalculateDRBJ('gwc'));
  3117. this.BcabinDatal[0].sheetInfo[0].costPerson = BJJCTBR;
  3118. this.BcabinDatal[0].sheetInfo[0].singleQuote = BJJCTBRDRBJ;
  3119. this.BcabinDatal[1].sheetInfo[0].costPerson = BJJCSGR;
  3120. this.BcabinDatal[1].sheetInfo[0].singleQuote = BJJCSGRDRBJ;
  3121. this.BcabinDatal[2].sheetInfo[0].costPerson = BGWCSGR;
  3122. this.BcabinDatal[2].sheetInfo[0].singleQuote = BGWCSGRDRBJ;
  3123. this.BcabinDatal[3].sheetInfo[0].costPerson = BGWCJSES;
  3124. this.BcabinDatal[3].sheetInfo[0].singleQuote = BGWCJSESDRBJ;
  3125. this.BcabinDatal[4].sheetInfo[0].costPerson = BGWCSUITE;
  3126. this.BcabinDatal[4].sheetInfo[0].singleQuote = BGWCSUITEDRBJ;
  3127. this.BcabinDatal[5].sheetInfo[0].costPerson = BJJCSUITE;
  3128. this.BcabinDatal[5].sheetInfo[0].singleQuote = BJJCSUITEDRBJ;
  3129. }
  3130. var txtJJCSGRRS = (result.hasOwnProperty("经济舱SGR") ? result["经济舱SGR"] : 0)
  3131. var lblGWCSGRRS = (result.hasOwnProperty("公务舱SGR") ? result["公务舱SGR"] : 0)
  3132. var txtJJCTBRRS = (result.hasOwnProperty("经济舱TBR") ? result["经济舱TBR"] * 2 : 0)
  3133. var txtGWCJSESRS = (result.hasOwnProperty("公务舱JSES") ? result["公务舱JSES"] : 0)
  3134. var JJCSUITERS = (result.hasOwnProperty("经济舱SUITE") ? result["经济舱SUITE"] : 0)
  3135. var txtGWCSUITERS = (result.hasOwnProperty("公务舱SUITE") ? result["公务舱SUITE"] : 0)
  3136. this.cabinDatal[0].sheetInfo[0].toll = txtJJCTBRRS;
  3137. this.cabinDatal[1].sheetInfo[0].toll = txtJJCSGRRS;
  3138. this.cabinDatal[2].sheetInfo[0].toll = lblGWCSGRRS;
  3139. this.cabinDatal[3].sheetInfo[0].toll = txtGWCJSESRS;
  3140. this.cabinDatal[4].sheetInfo[0].toll = txtGWCSUITERS;
  3141. this.cabinDatal[5].sheetInfo[0].toll = JJCSUITERS;
  3142. this.AGroupCostParameter.djcb = Djsum;
  3143. this.AGroupCostParameter.gwcb = GWsum;
  3144. this.AGroupCostParameter.lyjcb = LYJsum;
  3145. this.AGroupCostParameter.sgrcb = SGRsum;
  3146. this.AGroupCostParameter.tbrcb = TBRsum;
  3147. this.AGroupCostParameter.jsescb = JSESsum;
  3148. this.AGroupCostParameter.suitecb = SUITEsum;
  3149. var leftSum = this.OtherCost();
  3150. let JJCSGR = (leftSum + Number(this.AGroupCostParameter.sgrcb) + Number(this.AGroupCostParameter.jjccb)).toFixed(2);
  3151. let JJCTBR = (leftSum + Number(this.AGroupCostParameter.tbrcb) + Number(this.AGroupCostParameter.jjccb)).toFixed(2);
  3152. let JJCSUITE = (leftSum + Number(this.AGroupCostParameter.suitecb) + Number(this.AGroupCostParameter.jjccb)).toFixed(2);
  3153. let GWCSUITE = (leftSum + Number(this.AGroupCostParameter.suitecb) + Number(this.AGroupCostParameter.gwccb)).toFixed(2);
  3154. let GWCSGR = (leftSum + Number(this.AGroupCostParameter.sgrcb) + Number(this.AGroupCostParameter.gwccb)).toFixed(2);
  3155. let GWCJSES = (leftSum + Number(this.AGroupCostParameter.jsescb) + Number(this.AGroupCostParameter.gwccb)).toFixed(2);
  3156. //console.log(JJCSGR, JJCTBR, JJCSUITE, GWCSUITE, GWCSGR, GWCJSES, '666--------------------------');
  3157. var rightSum = 0;
  3158. this.OtherCostPropertyBJ.forEach((x) => {
  3159. rightSum += Number(that.calculateDRBJ(x));
  3160. })
  3161. let JJCSGRDRBJ = (rightSum + Number(that.calculateDRBJ('jjc')) + Number(that.calculateDRBJ('sgr'))).toFixed(2);
  3162. let JJCTBRDRBJ = (rightSum + Number(that.calculateDRBJ('tbr')) + Number(that.calculateDRBJ('jjc'))).toFixed(2);
  3163. let JJCSUITEDRBJ = (rightSum + Number(that.calculateDRBJ('suite')) + Number(that.calculateDRBJ('jjc'))).toFixed(2);
  3164. let GWCSUITEDRBJ = (rightSum + Number(that.calculateDRBJ('suite')) + Number(that.calculateDRBJ('gwc'))).toFixed(2);
  3165. let GWCSGRDRBJ = (rightSum + Number(that.calculateDRBJ('sgr')) + Number(that.calculateDRBJ('gwc'))).toFixed(2);
  3166. let GWCJSESDRBJ = (rightSum + Number(that.calculateDRBJ('jses')) + Number(that.calculateDRBJ('gwc'))).toFixed(2);
  3167. this.cabinDatal[0].sheetInfo[0].costPerson = JJCTBR;
  3168. this.cabinDatal[0].sheetInfo[0].singleQuote = JJCTBRDRBJ;
  3169. this.cabinDatal[1].sheetInfo[0].costPerson = JJCSGR;
  3170. this.cabinDatal[1].sheetInfo[0].singleQuote = JJCSGRDRBJ;
  3171. this.cabinDatal[2].sheetInfo[0].costPerson = GWCSGR;
  3172. this.cabinDatal[2].sheetInfo[0].singleQuote = GWCSGRDRBJ;
  3173. this.cabinDatal[3].sheetInfo[0].costPerson = GWCJSES;
  3174. this.cabinDatal[3].sheetInfo[0].singleQuote = GWCJSESDRBJ;
  3175. this.cabinDatal[4].sheetInfo[0].costPerson = GWCSUITE;
  3176. this.cabinDatal[4].sheetInfo[0].singleQuote = GWCSUITEDRBJ;
  3177. this.cabinDatal[5].sheetInfo[0].costPerson = JJCSUITE;
  3178. this.cabinDatal[5].sheetInfo[0].singleQuote = JJCSUITEDRBJ;
  3179. let groupCosts = 0;
  3180. let gtroupQuotes = 0;
  3181. for (var i = 0; i < this.cabinDatal.length; i++) {
  3182. var forNumber = Number(this.cabinDatal[i].sheetInfo[0]['toll']);
  3183. if (!isNaN(forNumber) && forNumber > 0) {
  3184. groupCosts += (Number(this.cabinDatal[i].sheetInfo[0]['costPerson']) * forNumber);
  3185. gtroupQuotes += (Number(this.cabinDatal[i].sheetInfo[0]['singleQuote']) * forNumber);
  3186. }
  3187. }
  3188. if (this.costTypevalue == 'B') {
  3189. for (var i = 0; i < this.BcabinDatal.length; i++) {
  3190. var forNumber = Number(this.BcabinDatal[i].sheetInfo[0]['toll']);
  3191. if (!isNaN(forNumber) && forNumber > 0) {
  3192. groupCosts += (Number(this.BcabinDatal[i].sheetInfo[0]['costPerson']) * forNumber);
  3193. gtroupQuotes += (Number(this.BcabinDatal[i].sheetInfo[0]['singleQuote']) * forNumber);
  3194. }
  3195. }
  3196. }
  3197. let groupProfit = gtroupQuotes - groupCosts;
  3198. var cabinDatalLast = this.cabinDatal.filter(function (x) {
  3199. return x.label == '团组预算明细'
  3200. })
  3201. groupCosts = groupCosts.toFixed(2);
  3202. gtroupQuotes = gtroupQuotes.toFixed(2);
  3203. groupProfit = groupProfit.toFixed(2);
  3204. cabinDatalLast[0].sheetInfo[0]['groupCosts'] = groupCosts;
  3205. cabinDatalLast[0].sheetInfo[0]['gtroupQuotes'] = gtroupQuotes;
  3206. cabinDatalLast[0].sheetInfo[0]['groupProfit'] = groupProfit;
  3207. //costTypeHotelNumbers{
  3208. // "sgr": 0,
  3209. // "tbr": 0,
  3210. // "jses": 0,
  3211. // "suite": 0,
  3212. // "type": "Default",
  3213. // "diid": 0,
  3214. // id: 0,
  3215. // }
  3216. //console.log(groupCosts, gtroupQuotes, groupProfit, 'groupCosts, gtroupQuotes, groupProfit');
  3217. },
  3218. OtherCost() {
  3219. // txtVisaCost.Text +txtHCPCB.Text + txtCPCB.Text
  3220. // txtBXCB.Text +txtHSCB.Text) +lblDJDRCB.Text + lblGWDRCD.Text + lblLYJDRCB.Text
  3221. var that = this;
  3222. let sum = 0;
  3223. this.OtherCostProperty.forEach((x) => {
  3224. var param = that.AGroupCostParameter[x];
  3225. if (param != undefined) {
  3226. sum += Number(param);
  3227. }
  3228. })
  3229. return sum;
  3230. },
  3231. BOtherCost() {
  3232. // txtVisaCost.Text +txtHCPCB.Text + txtCPCB.Text
  3233. // txtBXCB.Text +txtHSCB.Text) +lblDJDRCB.Text + lblGWDRCD.Text + lblLYJDRCB.Text
  3234. var that = this;
  3235. let sum = 0;
  3236. this.OtherCostProperty.forEach((x) => {
  3237. var param;
  3238. if (x == 'visaCB' || x == 'bxcb') {
  3239. param = that.AGroupCostParameter[x];
  3240. } else {
  3241. param = that.BGroupCostParameter[x];
  3242. }
  3243. if (param != undefined) {
  3244. sum += Number(param);
  3245. }
  3246. })
  3247. return sum;
  3248. },
  3249. matchRooms(hotelRooms, flights, roomTypes, flightType, result) {
  3250. for (let roomType of roomTypes) {
  3251. while (hotelRooms[roomType] > 0 && flights[flightType] > 0) {
  3252. hotelRooms[roomType]--;
  3253. flights[flightType]--;
  3254. if (roomType === "TBR") {
  3255. flights[flightType]--; //双人间在减少1
  3256. }
  3257. if (result.hasOwnProperty(flightType + roomType)) {
  3258. result[flightType + roomType]++;
  3259. } else {
  3260. result[flightType + roomType] = 1;
  3261. }
  3262. }
  3263. }
  3264. },
  3265. NumberSetTime(number, index) {
  3266. console.log(number, index, this.grouptitleinfo.visitStartDate);
  3267. number = parseInt(number);
  3268. if (!isNaN(number)) {
  3269. var time = this.addOneDay(this.grouptitleinfo.visitStartDate, number)
  3270. this.tableData[index].date = time;
  3271. } else {
  3272. this.tableData[index].date = '';
  3273. this.tableData[index].day = '';
  3274. }
  3275. },
  3276. addOneDay(dateString, number) {
  3277. let date = new Date(dateString);
  3278. date.setDate(date.getDate() + number);
  3279. let year = date.getFullYear();
  3280. let month = date.getMonth() + 1;
  3281. let day = date.getDate();
  3282. month = month < 10 ? '0' + month : month;
  3283. day = day < 10 ? '0' + day : day;
  3284. return `${year}-${month}-${day}`;
  3285. },
  3286. costTypeSelect(val) {
  3287. console.log('costTypeSelect--------------------------------------------------------', val);
  3288. },
  3289. async formVerify() {
  3290. return new Promise((resolve, reject) => {
  3291. var forFormList = [];
  3292. if (this.costTypevalue == 'A') {
  3293. forFormList = ['inputs', 'DHotel'];
  3294. } else {
  3295. forFormList = ['inputs', 'AHotel', 'Asection', 'BHotel', 'Bsection'];
  3296. }
  3297. var that = this;
  3298. for (var i = 0; i < forFormList.length; i++) {
  3299. that.$refs[forFormList[i]].validate((valid) => {
  3300. if (valid) {
  3301. } else {
  3302. resolve(valid);
  3303. }
  3304. });
  3305. }
  3306. resolve(true);
  3307. })
  3308. },
  3309. clearFormVerify() {
  3310. var forFormList = ['inputs', 'AHotel', 'Asection', 'BHotel', 'Bsection', 'DHotel'];
  3311. this.$nextTick(() => {
  3312. for (var i = 0; i < forFormList.length; i++) {
  3313. this.$refs[forFormList[i]].resetFields();
  3314. }
  3315. })
  3316. }
  3317. },
  3318. mounted() {
  3319. this.token = JSON.parse(localStorage.getItem('userinif')).token;
  3320. this.userId = JSON.parse(localStorage.getItem('userinif')).userInfo.userId
  3321. this.loadData(-1);
  3322. },
  3323. computed: {
  3324. defaultCostTypeHotelNumber() {
  3325. const defaultItems = this.costTypeHotelNumbers.filter(item => item.type == 'Default');
  3326. return defaultItems[0];
  3327. },
  3328. filterdialogSearchInput() {
  3329. var that = this;
  3330. return this.dialogTableData.filter(function (x) {
  3331. return x.city.indexOf(that.dialogSearchInput) != -1 || x.country.indexOf(that.dialogSearchInput) != -1;
  3332. })
  3333. },
  3334. columnWidth() {
  3335. if (this.CheckBoxListSelect.filter(item => item.cbType == 'Top')[0].cbValues.length < 9) {
  3336. return ''
  3337. } else {
  3338. return 150
  3339. }
  3340. }
  3341. }
  3342. }
  3343. </script>
  3344. <style>
  3345. .cost-box {
  3346. background-color: #fff;
  3347. padding: 10px;
  3348. box-shadow: 0 0 5px #0005;
  3349. border-radius: 10px;
  3350. }
  3351. .cost-box .el-button+.el-button {
  3352. margin-left: 0;
  3353. }
  3354. .fade-enter-active,
  3355. .fade-leave-active {
  3356. transition: opacity 1;
  3357. }
  3358. .fade-enter,
  3359. .fade-leave-to {
  3360. opacity: 0;
  3361. }
  3362. .cost-haed {
  3363. margin-bottom: 10px;
  3364. }
  3365. .ser-btn {
  3366. display: flex;
  3367. justify-content: space-between;
  3368. margin-bottom: 10px;
  3369. }
  3370. .cost-info {
  3371. display: flex;
  3372. }
  3373. .cost-info-li {
  3374. margin-right: 30px;
  3375. }
  3376. .cost-info-li label {
  3377. color: #606266;
  3378. font-size: 15px;
  3379. font-weight: 600;
  3380. }
  3381. .cost-info-li span {
  3382. color: #606266;
  3383. font-size: 14px;
  3384. }
  3385. .cost-box .el-checkbox-group {
  3386. margin: 5px 0;
  3387. }
  3388. .form-ss .el-checkbox {
  3389. width: 100px;
  3390. margin: 5px 0;
  3391. }
  3392. .sheet-box {
  3393. margin-top: 30px;
  3394. }
  3395. .cabin-box {
  3396. margin-top: 30px;
  3397. }
  3398. .biaoge {
  3399. margin-bottom: 30px;
  3400. }
  3401. .rapAddress {
  3402. overflow: hidden;
  3403. white-space: nowrap;
  3404. text-overflow: ellipsis;
  3405. }
  3406. .cost-box .cabin-box .cost-box .el-checkbox {
  3407. margin-right: 20px;
  3408. }
  3409. .cost-box .el-table .cell {
  3410. text-align: center;
  3411. }
  3412. .figures-btn {
  3413. display: flex;
  3414. flex-direction: column;
  3415. align-items: center;
  3416. }
  3417. .figures-btn .el-button--mini {
  3418. width: 70px;
  3419. margin: 2px 0;
  3420. margin-left: 0;
  3421. }
  3422. .CostBShow .el-col-3 .el-form-item__content {
  3423. width: 60%;
  3424. }
  3425. .CostBShow .el-form-item__content {
  3426. width: 60%;
  3427. }
  3428. .CostBShow .el-date-editor--date {
  3429. width: 100%;
  3430. }
  3431. .Cost_topFlex .el-select {
  3432. width: 200px;
  3433. }
  3434. .hiddenElement {
  3435. visibility: hidden;
  3436. }
  3437. .cost-all .el-table__footer-wrapper .cell {
  3438. white-space: pre;
  3439. }
  3440. </style>