orderDetail.vue 165 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645
  1. <template>
  2. <div class="app-container">
  3. <el-collapse v-model="activeName" @change="handleChange">
  4. <el-collapse-item>
  5. <template slot="title">
  6. <span style="font-size:20px; margin-left:20px;letter-spacing:2px;color:red">
  7. <i class="el-icon-warning"></i>
  8. <span> 当前节点:{{ currentNode == null ? '???' : currentNode.nodeName ? currentNode.nodeName : '结束' }}</span>
  9. <!-- <span v-if = "currentNode.tasks.length>0" style="margin-left:30px">任务:</span> -->
  10. <!-- <span v-for="( t,index) in currentNode.tasks" :key=index >{{t.info}}</span> -->
  11. <!-- <span style="margin-left:30px" v-if="statementNo || reportNo">该流程已取:<el-tag type="success" v-if="statementNo">{{statementNo}}</el-tag> <el-tag type="danger" v-if="reportNo">{{reportNo}}</el-tag></span> -->
  12. </span>
  13. <span style="font-size:15px; margin-left:15px;letter-spacing:2px; color:RGB(168,168,168)">
  14. 点击展开查看实时流程图
  15. </span>
  16. </template>
  17. <WorkflowBoard ref='board' @workflowCommitVerify="workflowCommitVerify" :nodeBusinessInfo="nodeBusinessInfo"
  18. @getPreviousNode="getPreviousNode" />
  19. </el-collapse-item>
  20. </el-collapse>
  21. <div class="button-area" v-if="couldEdit">
  22. <el-button @click="openProductionDialog"
  23. v-if="currentNode.nodeCode === 'PRODUCT_CHOICE' || currentNode.nodeCode === 'REPORT_CHOICE'" type="danger" round>
  24. 选择产品
  25. </el-button>
  26. <el-button @click="openAssetsAchievementRatioDialog()" v-if="currentNode.nodeCode === 'CHECK_ARCHIVING'"
  27. type="danger" round>
  28. <!-- <span v-if="currentNode.nodeCode === 'RECHECK_ARCHIVING'">复审部</span> -->
  29. 归档审核
  30. </el-button>
  31. <el-button v-if="nodeBusinessInfo.currentNodePermission.commit" class="y-save" type="success" round
  32. @click="commit('PASS')" :disabled="!nodeBusinessInfo.doWorkflow">提交</el-button>
  33. <el-button v-if="nodeBusinessInfo.currentNodePermission.reversible" class="y-save" type="warning" round
  34. @click="commit('REVERSE')" :disabled="!nodeBusinessInfo.doWorkflow">退回</el-button>
  35. <el-button v-if="nodeBusinessInfo.currentNodePermission.skippable" class="y-save" type="warning" round
  36. @click="commit('SKIP')" :disabled="!nodeBusinessInfo.doWorkflow">跳过</el-button>
  37. <el-button v-if="nodeBusinessInfo.currentNodePermission.terminable" class="y-save" type="danger" round
  38. @click="commit('TERMINATE')" :disabled="!nodeBusinessInfo.doWorkflow">终止</el-button>
  39. <el-button v-if="nodeBusinessInfo.currentNodePermission.restartable" class="y-save" type="danger" round
  40. @click="commit('RESTART')" :disabled="!nodeBusinessInfo.doWorkflow">重置</el-button>
  41. <el-button class="y-save" round type="info" @click="goBack">返回</el-button>
  42. </div>
  43. <el-tabs v-model="activeTabName" @tab-click="handleClick" type="border-card">
  44. <el-tab-pane name="baseInfo" class="pane-class" :lazy=true>
  45. <span slot="label"><i class="el-icon-document"></i>基本信息</span>
  46. <y-detail-page-layout ref="addAssetsOrder" name="assets">
  47. <el-form ref="assetsForm" :model="assetsForm" :rules="assetsFormRules" :disabled="disabledStatus">
  48. <div class="createMajor-main-container">
  49. <div class="postInfo-container">
  50. <el-row v-if="canUpdateOrderBaseInfoNode.includes(currentNode.nodeCode)" class="row-style"
  51. style="margin-top: 20px; float: right; position: relative; z-index: 2;">
  52. <el-col :xs="24" :sm="12" :lg="23" :span="12">
  53. <el-button type="danger" @click="updateOrderBaseInfo()" round>更新基本信息</el-button>
  54. </el-col>
  55. </el-row>
  56. <div>
  57. <el-divider content-position="left">
  58. <h3 class="title">
  59. <div class="avatar-wrapper icon-title">订单</div>
  60. <div class="icon-info">资产订单</div>
  61. </h3>
  62. </el-divider>
  63. </div>
  64. <el-row class="row-style">
  65. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  66. <el-form-item label="项目编号:" prop="orderId" label-width="170px" class="postInfo-container-item">
  67. <el-input :value="assetsForm.orderId" class="filter-item" readonly disabled
  68. style=" width: 100%" />
  69. </el-form-item>
  70. </el-col>
  71. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  72. <el-form-item label="客户经理:" prop="clientManager" label-width="170px" class="postInfo-container-item">
  73. <el-input :value="assetsForm.clientManagerName" class="filter-item" readonly disabled
  74. style=" width: 100%" />
  75. </el-form-item>
  76. </el-col>
  77. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  78. <el-form-item label="接单部门:" prop="departmentId" label-width="170px" class="postInfo-container-item">
  79. <el-select v-model="assetsForm.departmentId" readonly disabled style=" width: 100%">
  80. <el-option v-for="(d, id) in allotDepartment" :label="d.name" :value="d.id"
  81. :key="d.id"></el-option>
  82. </el-select>
  83. </el-form-item>
  84. </el-col>
  85. </el-row>
  86. <el-row class="row-style">
  87. <el-col :xs="24" :sm="24" :lg="24" :span="24">
  88. <el-form-item prop="name" label-width="170px" class="postInfo-container-item" label="项目名称:">
  89. <el-input v-model="assetsForm.name" class="filter-item" />
  90. </el-form-item>
  91. </el-col>
  92. </el-row>
  93. <el-row class="row-style">
  94. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  95. <el-form-item label="业务类型:" prop="assetsBusinessGener" label-width="170px"
  96. class="postInfo-container-item">
  97. <el-select v-model="assetsForm.assetsBusinessGener" filterable placeholder="业务类型"
  98. style=" width: 100%">
  99. <el-option v-for="(s, index) in assetsBusinessGeners" :label="s.label" :value="s.value"
  100. :key="s.id"></el-option>
  101. </el-select>
  102. </el-form-item>
  103. </el-col>
  104. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  105. <el-form-item label="客户再次委托:" prop="entrustAgain" label-width="170px" class="postInfo-container-item">
  106. <el-radio v-model="assetsForm.entrustAgain" :label="false" border size="medium">否</el-radio>
  107. <el-radio v-model="assetsForm.entrustAgain" :label="true" border size="medium">是</el-radio>
  108. </el-form-item>
  109. </el-col>
  110. </el-row>
  111. <el-row class="row-style">
  112. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  113. <el-form-item label="客户类型:" prop="clienteleType" label-width="170px" class="postInfo-container-item">
  114. <el-select v-model="assetsForm.clienteleType" placeholder="请选择"
  115. @change="changeCustomerType(assetsForm.clienteleType)" readonly disabled style=" width: 100%">
  116. <el-option label="企业" value="企业"></el-option>
  117. <el-option label="个人" value="个人"></el-option>
  118. </el-select>
  119. </el-form-item>
  120. </el-col>
  121. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  122. <el-form-item label="客户名称:" prop="clienteleId" label-width="170px" class="postInfo-container-item"
  123. v-if="itemHideStatus">
  124. <el-select v-model="assetsForm.clienteleId" placeholder="请选择(可搜索)" @change="findSubClientele(0)"
  125. clearable filterable readonly disabled style=" width: 100%">
  126. <el-option v-for="(c, id) in customerCompany" :label="c.name" :value="c.id"
  127. :key="c.id"></el-option>
  128. </el-select>
  129. </el-form-item>
  130. </el-col>
  131. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  132. <el-form-item label="业务来源:" prop="clienteleSubId" label-width="170px" class="postInfo-container-item"
  133. v-if="itemHideStatus">
  134. <el-select v-model="assetsForm.clienteleSubId" placeholder="请选择(可搜索)" @change="getCustomerContract"
  135. clearable filterable readonly disabled style=" width: 100%">
  136. <el-option v-for="(s, id) in subCustomerCompany" :label="s.name" :value="s.id"
  137. :key="s.id"></el-option>
  138. </el-select>
  139. </el-form-item>
  140. </el-col>
  141. </el-row>
  142. <el-row class="row-style">
  143. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  144. <el-form-item label="客户联系人:" prop="clienteleContactId" label-width="170px"
  145. class="postInfo-container-item">
  146. <div>
  147. <el-select v-model="assetsForm.clienteleContactId" placeholder="请选择(可搜索)" clearable filterable
  148. @change="getContactInfo();" readonly disabled style=" width: 100%">
  149. <!-- <el-option v-for="(c, id) in customerContract" :label="c.name" :value="c.id"
  150. :key="c.id"></el-option> -->
  151. <el-option :label="linkmanInfo.name" :value="linkmanInfo.id" :key="linkmanInfo.id"></el-option>
  152. </el-select>
  153. <!-- <el-tooltip class="item" effect="dark" content="没有联系人?点击新增" placement="top-end">
  154. <span style="margin-left:5%;color:RGB(64,158,255);cursor:pointer"
  155. @click="createLinkman(false)">新增</span>
  156. </el-tooltip> -->
  157. </div>
  158. </el-form-item>
  159. </el-col>
  160. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  161. <el-form-item label="联系人电话:" prop="mobile" label-width="170px" class="postInfo-container-item">
  162. <el-input :value="assetsForm.linkmanMobile" class="filter-item" readonly disabled
  163. style=" width: 100%" />
  164. </el-form-item>
  165. </el-col>
  166. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  167. <el-form-item label="联系人部门:" prop="department" label-width="170px" class="postInfo-container-item">
  168. <el-input :value="assetsForm.linkmanDepartment" class="filter-item" readonly disabled
  169. style=" width: 100%" />
  170. </el-form-item>
  171. </el-col>
  172. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  173. <el-form-item label="联系人职务:" prop="duty" label-width="170px" class="postInfo-container-item">
  174. <el-input :value="assetsForm.linkmanDuty" class="filter-item" readonly disabled
  175. style=" width: 100%" />
  176. </el-form-item>
  177. </el-col>
  178. </el-row>
  179. <el-row class="row-style">
  180. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  181. <el-form-item label="是否证券项目:" prop="security" label-width="170px" class="postInfo-container-item">
  182. <el-radio v-model="assetsForm.security" :label="false" border size="medium">否</el-radio>
  183. <el-radio v-model="assetsForm.security" :label="true" border size="medium">是</el-radio>
  184. </el-form-item>
  185. </el-col>
  186. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  187. <el-form-item label="是否资产重组项目:" prop="significantAssetsReorganization" label-width="170px"
  188. class="postInfo-container-item">
  189. <el-radio v-model="assetsForm.significantAssetsReorganization" :label="false" border
  190. size="medium">否</el-radio>
  191. <el-radio v-model="assetsForm.significantAssetsReorganization" :label="true" border
  192. size="medium">是</el-radio>
  193. </el-form-item>
  194. </el-col>
  195. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  196. <el-form-item label=" 是否国资项目:" prop="stateAssets" label-width="170px" class="postInfo-container-item">
  197. <el-radio v-model="assetsForm.stateAssets" :label="false" border size="medium">否</el-radio>
  198. <el-radio v-model="assetsForm.stateAssets" :label="true" border size="medium">是</el-radio>
  199. </el-form-item>
  200. </el-col>
  201. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  202. <el-form-item label="是否涉及境外资产:" prop="foreignAssetsInvolved" label-width="170px"
  203. class="postInfo-container-item">
  204. <el-radio v-model="assetsForm.foreignAssetsInvolved" :label="false" border
  205. size="medium">否</el-radio>
  206. <el-radio v-model="assetsForm.foreignAssetsInvolved" :label="true" border size="medium">是</el-radio>
  207. </el-form-item>
  208. </el-col>
  209. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  210. <el-form-item label="是否分配产值:" prop="dispenseBenefit" label-width="170px"
  211. class="postInfo-container-item">
  212. <el-radio v-model="assetsForm.dispenseBenefit" :label="false" border size="medium">否</el-radio>
  213. <el-radio v-model="assetsForm.dispenseBenefit" :label="true" border size="medium">是</el-radio>
  214. </el-form-item>
  215. </el-col>
  216. </el-row>
  217. <el-row class="row-style">
  218. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  219. <el-form-item label="委托人:" prop="bailor" label-width="170px" class="postInfo-container-item">
  220. <el-input v-model="assetsForm.bailor" class="filter-item" />
  221. </el-form-item>
  222. </el-col>
  223. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  224. <el-form-item label="委托联系人:" prop="bailorContactName" label-width="170px"
  225. class="postInfo-container-item">
  226. <el-input v-model="assetsForm.bailorContactName" class="filter-item" />
  227. </el-form-item>
  228. </el-col>
  229. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  230. <el-form-item label="委托人联系人电话:" prop="bailorContactTel" label-width="170px"
  231. class="postInfo-container-item">
  232. <el-input v-model="assetsForm.bailorContactTel" class="filter-item" style=" width: 100%" />
  233. </el-form-item>
  234. </el-col>
  235. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  236. <el-form-item label="委托人地址:" prop="bailorAddress" label-width="170px" class="postInfo-container-item">
  237. <el-input v-model="assetsForm.bailorAddress" class="filter-item" style=" width: 100%" />
  238. </el-form-item>
  239. </el-col>
  240. </el-row>
  241. <el-row class="row-style">
  242. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  243. <el-form-item label="终端客户类型:" prop="terminalClienteleType" label-width="170px"
  244. class="postInfo-container-item">
  245. <el-select v-model="assetsForm.terminalClienteleType" placeholder="请选择" readonly disabled
  246. style=" width: 100%">
  247. <el-option label="企业" value="企业"></el-option>
  248. <el-option label="个人" value="个人"></el-option>
  249. </el-select>
  250. </el-form-item>
  251. </el-col>
  252. <el-col :xs="24" :sm="12" :lg="12" :span="6" v-if="assetsForm.terminalClienteleType === '企业'">
  253. <el-form-item label="终端客户名称:" prop="terminalClienteleId" label-width="170px"
  254. class="postInfo-container-item">
  255. <!-- <div v-if="couldEdit"> -->
  256. <el-select v-model="assetsForm.terminalClienteleId" placeholder="请选择(可搜索)"
  257. @change="findSubClientele(1)" clearable filterable readonly disabled style="width:100%">
  258. <!-- <el-option v-for="(c, id) in tCustomerCompany" :label="c.name" :value="c.id"
  259. :key="c.id"></el-option> -->
  260. <el-option :label="tCustomerInfo.name" :value="tCustomerInfo.id"
  261. :key="tCustomerInfo.id"></el-option>
  262. </el-select>
  263. <!-- <el-tooltip class="item" effect="dark" content="没有终端客户?点击新增" placement="top-end">
  264. <span style="margin-left:5%;color:RGB(64,158,255);cursor:pointer"
  265. @click="createTerminalClient()">新增</span>
  266. </el-tooltip> -->
  267. <!-- </div> -->
  268. <!-- <el-input :value="assetsForm.tterminalClienteleName" class="filter-item" style=" width: 225px"
  269. v-else /> -->
  270. </el-form-item>
  271. </el-col>
  272. </el-row>
  273. <el-row class="row-style">
  274. <el-col :xs="24" :sm="12" :lg="6" :span="6" v-if="assetsForm.terminalClienteleType">
  275. <el-form-item label="终端联系人:" prop="terminalClienteleContactId" label-width="170px"
  276. class="postInfo-container-item">
  277. <el-select v-model="assetsForm.terminalClienteleContactId" placeholder="请选择(可搜索)" clearable
  278. filterable readonly disabled style=" width: 100%">
  279. <!-- <el-option v-for="(c, id) in tCustomerContract" :label="c.name" :value="c.id"
  280. :key="c.id"></el-option> -->
  281. <el-option :label="tLinkmanInfo.name" :value="tLinkmanInfo.id" :key="tLinkmanInfo.id"></el-option>
  282. </el-select>
  283. <!-- <el-tooltip class="item" effect="dark" content="没有联系人?点击新增" placement="top-end">
  284. <span style="margin-left:5%;color:RGB(64,158,255);cursor:pointer"
  285. @click="createTlinkman()">新增</span>
  286. </el-tooltip> -->
  287. </el-form-item>
  288. </el-col>
  289. <el-col :xs="24" :sm="12" :lg="6" :span="6" v-if="assetsForm.terminalClienteleType">
  290. <el-form-item label="终端联系电话:" prop="clienteleType" label-width="170px"
  291. class="postInfo-container-item">
  292. <el-input :value="assetsForm.tmobile" class="filter-item" readonly disabled style=" width: 100%" />
  293. </el-form-item>
  294. </el-col>
  295. </el-row>
  296. <el-row class="row-style">
  297. <el-col :xs="24" :sm="12" :lg="23" :span="12">
  298. <el-form-item label="备注:" prop="remark" label-width="170px" class="postInfo-container-item">
  299. <el-input v-model="assetsForm.remark" :autosize="{ minRows: 4, maxRows: 4 }" class="filter-item"
  300. type="textarea" />
  301. </el-form-item>
  302. </el-col>
  303. </el-row>
  304. </div>
  305. </div>
  306. </el-form>
  307. </y-detail-page-layout>
  308. </el-tab-pane>
  309. <el-tab-pane name="members" class="pane-class" :lazy=true>
  310. <span slot="label"><i class="el-icon-document"></i>项目人员</span>
  311. <!-- <y-detail-page-layout @save="updatePrincipalAndMembers" ref="addAssetsOrder" name="assets"
  312. :editStatus="currentNode.nodeCode === 'DEPARTMENT_ALLOCATION' || !disabledStatus"> -->
  313. <el-form ref="assetsForm" :model="assetsForm" :rules="assetsFormRules"
  314. :disabled="currentNode.nodeCode !== 'DEPARTMENT_ALLOCATION' || disabledStatus">
  315. <div class="createMajor-main-container">
  316. <div class="postInfo-container">
  317. <div style="margin-top: 35px;">
  318. <el-divider content-position="left">
  319. <h3 class="title">
  320. <div class="avatar-wrapper icon-title">成员</div>
  321. <div class="icon-info">项目成员</div>
  322. </h3>
  323. </el-divider>
  324. </div>
  325. <el-row class="row-style">
  326. <el-col :xs="24" :sm="12" :lg="4" :span="6">
  327. <el-form-item label="接单部门:" prop="departmentId" label-width="120px"
  328. :class="['postInfo-container-item', currentNode.nodeCode === 'DEPARTMENT_ALLOCATION' ? 'task-class' : '']">
  329. <el-select @change="getPrincipalByAllotDepartment()" v-model="assetsForm.departmentId">
  330. <el-option v-for="(d, id) in allotDepartment" :label="d.name" :value="d.id" :key="d.id"></el-option>
  331. </el-select>
  332. </el-form-item>
  333. </el-col>
  334. </el-row>
  335. <el-row class="row-style">
  336. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  337. <el-form-item label="项目负责人:" prop="principalId" label-width="120px"
  338. :class="['postInfo-container-item', currentNode.nodeCode === 'DEPARTMENT_ALLOCATION' ? 'task-class' : '']"
  339. :rules="{ required: true, message: '项目负责人不能为空', trigger: 'blur' }">
  340. <el-select v-model="assetsForm.principalId" placeholder="请选择(可搜索)"
  341. :filterable="currentNode.nodeCode === 'DEPARTMENT_ALLOCATION'"
  342. :clearable="currentNode.nodeCode === 'DEPARTMENT_ALLOCATION'"
  343. :readonly="currentNode.nodeCode != 'DEPARTMENT_ALLOCATION'"
  344. :disabled="currentNode.nodeCode != 'DEPARTMENT_ALLOCATION'">
  345. <el-option v-for="(p, id) in principals" :label="p.name" :value="p.id" :key="p.id"></el-option>
  346. </el-select>
  347. </el-form-item>
  348. </el-col>
  349. </el-row>
  350. <el-row class="row-style">
  351. <el-col :xs="24" :sm="12" :lg="3" :span="6">
  352. <el-form-item label="项目成员:" prop="members" label-width="120px"
  353. :class="['postInfo-container-item', currentNode.nodeCode === 'DEPARTMENT_ALLOCATION' ? 'task-class' : '']"
  354. :rules="{ required: true, message: '项目成员不能为空', trigger: 'blur' }">
  355. <el-select v-model="assetsForm.members" placeholder="请选择(可搜索)" multiple style=" width: 686px"
  356. :filterable="currentNode.nodeCode === 'DEPARTMENT_ALLOCATION'"
  357. :clearable="currentNode.nodeCode === 'DEPARTMENT_ALLOCATION'"
  358. :readonly="currentNode.nodeCode != 'DEPARTMENT_ALLOCATION'"
  359. :disabled="currentNode.nodeCode != 'DEPARTMENT_ALLOCATION'">
  360. <el-option v-for="(u, id) in depUsers" :label="u.name" :value="u.id" :key="u.id"></el-option>
  361. </el-select>
  362. </el-form-item>
  363. </el-col>
  364. </el-row>
  365. <el-row class="row-style">
  366. <el-col :xs="24" :sm="12" :lg="3" :span="6">
  367. <el-button type="danger" @click="updatePrincipalAndMembers()" round>保存项目人员信息</el-button>
  368. </el-col>
  369. </el-row>
  370. </div>
  371. </div>
  372. </el-form>
  373. <!-- </y-detail-page-layout> -->
  374. </el-tab-pane>
  375. <el-tab-pane name="target" class="pane-class" :lazy=true>
  376. <span @click="getAETargetListByAssetsId()" slot="label"><i class="el-icon-document"></i>资产评估对象</span>
  377. <div class="createMajor-main-container">
  378. <div class="postInfo-container">
  379. <div style="margin-top: 35px;">
  380. <el-divider content-position="left">
  381. <h3 class="title">
  382. <div class="avatar-wrapper icon-title">评估</div>
  383. <div class="icon-info">资产评估对象</div>
  384. </h3>
  385. </el-divider>
  386. </div>
  387. <el-row>
  388. <el-col :span="2">
  389. <div>
  390. <el-statistic group-separator="," :precision="4" :value="totalEvaluateValue" title="估价对象总价(万)">
  391. <template slot="prefix">
  392. <i class="el-icon-coin"></i>
  393. </template>
  394. </el-statistic>
  395. </div>
  396. </el-col>
  397. <el-col :span="2">
  398. <el-button v-if="currentNode.nodeCode === 'SPOT_RECONNAISSANCE_DETERMINE_PRICE' && couldEdit"
  399. type="danger" @click="openTargetDialog(), changeStatus('add')" round>添加评估对象</el-button>
  400. </el-col>
  401. <el-col :span="2" v-if="currentNode.nodeCode === 'GENERATE_STATEMENT' && couldEdit">
  402. <el-tooltip class="item" effect="dark" content="全选取主号,多次取号(主号-子号)" placement="right">
  403. <el-button type="success" @click="takeAssetsStatementProductionNo('STATEMENT')" round>意见书取号</el-button>
  404. </el-tooltip>
  405. </el-col>
  406. <el-col :span="2" v-if="currentNode.nodeCode === 'ASSET_REPORT_TAKE_NO' && couldEdit">
  407. <el-tooltip class="item" effect="dark" content="全选取主号,多次取号(主号-子号)" placement="right">
  408. <el-button type="success" @click="takeAssetsReportProductionNo('REPORT')" round>报告取号</el-button>
  409. </el-tooltip>
  410. </el-col>
  411. <el-col :span="2" v-if="(currentNode.nodeCode === 'GENERATE_STATEMENT' && writeProductionStatementNos.length > 0)
  412. || (currentNode.nodeCode === 'WRITE_REPORT' && writeProductionReportNos.length > 0)
  413. && couldEdit">
  414. <el-tooltip class="item" effect="dark" content="请仔细确认产品内容" placement="right">
  415. <el-button type="success" @click="openWriteProductionDialog(false, 'add')" round>撰写产品信息</el-button>
  416. </el-tooltip>
  417. </el-col>
  418. </el-row>
  419. <el-table ref="multipleTable" :data="assetsEvaluationTarget" stripe @selection-change="targetSelectionChange"
  420. :header-row-style="{ color: '#333333' }" border takeNumberItems style="width: 100%; margin-top:20px">
  421. <el-table-column type="selection" width="55" :selectable="selectable">
  422. </el-table-column>
  423. <el-table-column width="220" prop="statementNo" label="意见书号" align="center" show-overflow-tooltip>
  424. <template slot-scope="scope">
  425. <el-tag type='success' v-if="scope.row.statementNo">
  426. {{ scope.row.statementNo }}
  427. </el-tag>
  428. <el-tag type='danger' v-else>
  429. 未取号
  430. </el-tag>
  431. </template>
  432. </el-table-column>
  433. <el-table-column width="220" prop="reportNo" label="报告号" align="center" show-overflow-tooltip>
  434. <template slot-scope="scope">
  435. <el-tag type='success' v-if="scope.row.reportNo">
  436. {{ scope.row.reportNo }}
  437. </el-tag>
  438. <el-tag type='danger' v-else>
  439. 未取号
  440. </el-tag>
  441. </template>
  442. </el-table-column>
  443. <el-table-column prop="statementCreateProductionDate" label="意见书出具状态" align="center" show-overflow-tooltip>
  444. <template slot-scope="{row}">
  445. <el-tag v-if="row.statementCreateProductionDate !== null" type='success'> 已出具</el-tag>
  446. <el-tag v-if="row.statementCreateProductionDate == null" type='danger'> 未出具</el-tag>
  447. </template>
  448. </el-table-column>
  449. <el-table-column prop="reportCreateProductionDate" label="报告出具状态" align="center" show-overflow-tooltip>
  450. <template slot-scope="{row}">
  451. <el-tag v-if="row.reportCreateProductionDate !== null" type='success'> 已出具</el-tag>
  452. <el-tag v-if="row.reportCreateProductionDate == null" type='danger'> 未出具</el-tag>
  453. </template>
  454. </el-table-column>
  455. <el-table-column prop="purposeName" label="评估目的" align="center" show-overflow-tooltip>
  456. </el-table-column>
  457. <el-table-column label="评估对象" align="center" show-overflow-tooltip>
  458. <template slot-scope="{row}">
  459. <span>{{ row.targetTypename }}</span>
  460. <span>--</span>
  461. <span>{{ row.secTargetTypaName }}</span>
  462. </template>
  463. </el-table-column>
  464. <el-table-column prop="theHolder" label="产权持有人" align="center" show-overflow-tooltip>
  465. </el-table-column>
  466. <el-table-column prop="valueTypeName" label="价值类型" align="center" show-overflow-tooltip>
  467. </el-table-column>
  468. <el-table-column prop="totalAssetCarryingAmount" label="总资产账面值(万)" align="center" show-overflow-tooltip>
  469. </el-table-column>
  470. <el-table-column prop="totalLiabilitiesCarryingAmount" label="总负债账面值(万)" align="center"
  471. show-overflow-tooltip>
  472. </el-table-column>
  473. <el-table-column prop="carryingAmountOfNetAssets" label="净资产账面值(万)" align="center" show-overflow-tooltip>
  474. </el-table-column>
  475. <el-table-column prop="estimatedValue" label="评估价格(万)" align="center" show-overflow-tooltip>
  476. </el-table-column>
  477. <el-table-column prop="checkValue" label="审核价格(万)" align="center" show-overflow-tooltip>
  478. </el-table-column>
  479. <el-table-column label="操作" align="center" width="130" fixed="right">
  480. <template slot-scope="scope">
  481. <el-button type="text" size="small"
  482. @click="getAssetsTargetDetail(scope.row.id), changeStatus('detail')">
  483. 查看
  484. </el-button>
  485. <el-button
  486. v-if="(currentNode.nodeCode === 'SPOT_RECONNAISSANCE_DETERMINE_PRICE' || (currentNode.nodeCode !== 'QUOTATION_FEEDBACK')) && !disabledStatus && assetsForm.principalId === $store.getters.userInfo.id"
  487. type="text" size="small" @click="getAssetsTargetDetail(scope.row.id), changeStatus('edit')">
  488. 编辑
  489. </el-button>
  490. <el-button
  491. v-if="(currentNode.nodeCode === 'SPOT_RECONNAISSANCE_DETERMINE_PRICE' || (currentNode.nodeCode !== 'QUOTATION_FEEDBACK' && !scope.row.statementNo && !scope.row.reportNo)) && !disabledStatus"
  492. type="text" size="small" @click="assetsTargetDelete(scope.row.id)">删除</el-button>
  493. <el-button
  494. v-if="(currentNode.nodeCode === 'REVIEW_STATEMENT' || currentNode.nodeCode === 'CHECK_REPORT') && !disabledStatus"
  495. type="text" size="small" @click="openCheckValueDialog(scope.row.id);">审核定价</el-button>
  496. </template>
  497. </el-table-column>
  498. </el-table>
  499. <el-row>
  500. <el-col :span="2">
  501. <p v-if="assetsProductionForm.productionType">产品类型:
  502. <span style="color: red" v-if="assetsProductionForm.productionType == 'CONSULT'">
  503. 咨询报告
  504. </span>
  505. <span style="color: red" v-if="assetsProductionForm.productionType == 'REPORT'">
  506. 评估报告
  507. </span>
  508. <span style="color: red" v-if="assetsProductionForm.productionType == 'LETTER'">
  509. 意见函
  510. </span>
  511. <span style="color: red" v-if="assetsProductionForm.productionType == 'STATEMENT'">
  512. 价值意见书
  513. </span>
  514. </p>
  515. </el-col>
  516. </el-row>
  517. </div>
  518. </div>
  519. </el-tab-pane>
  520. <el-tab-pane name="production" class="pane-class" :lazy=true>
  521. <span slot="label" @click="getAETargetListByAssetsId()"><i class="el-icon-document"></i>产品信息</span>
  522. <div class="createMajor-main-container">
  523. <div class="postInfo-container">
  524. <div style="margin-top: 35px;">
  525. <el-divider content-position="left">
  526. <h3 class="title">
  527. <div class="avatar-wrapper icon-title">产品</div>
  528. <div class="icon-info">资产产品信息</div>
  529. </h3>
  530. </el-divider>
  531. </div>
  532. <div style="margin-top: 30px; color: red;" v-if="currentNode.nodeCode === 'GENERATE_STATEMENT' && couldEdit">
  533. 选择要提交的意见书:
  534. <el-select v-model="commitProductionNo" @change="pushProductionNo()" placeholder="请选择要提交的产品"
  535. style="width: 300px;">
  536. <el-option v-for="(pro, productionNo) in assetsProductionData" v-if="pro.productionType == 'STATEMENT'"
  537. :label="pro.productionNo" :value="pro.productionNo" :key="pro.id"></el-option>
  538. </el-select>
  539. </div>
  540. <div style="margin-top: 30px; color: red;" v-if="currentNode.nodeCode === 'WRITE_REPORT' && couldEdit">
  541. 选择要提交的报告:
  542. <el-select v-model="commitProductionNo" @change="pushProductionNo()" placeholder="请选择要提交的产品"
  543. style="width: 300px;">
  544. <el-option v-for="(pro, productionNo) in assetsProductionData" v-if="pro.productionType !== 'STATEMENT'"
  545. :label="pro.productionNo" :value="pro.productionNo" :key="pro.id"></el-option>
  546. </el-select>
  547. </div>
  548. <div style="margin-top: 30px;">
  549. <span v-if="currentNode.nodeCode === 'STATEMENT_BOOKBINDING_STAMP'">
  550. <span v-for="pro in assetsProductionData" :key="pro.id" style="color: red;">
  551. 打印份数:{{ pro.printCount }}
  552. </span>
  553. </span>
  554. </div>
  555. <el-table :data="assetsProductionData" stripe :header-row-style="{ color: '#333333' }" border takeNumberItems
  556. style="width: 100%; margin-top:20px">
  557. <el-table-column type="expand">
  558. <template slot-scope="props">
  559. <el-form label-position="left">
  560. <el-row class="row-style">
  561. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  562. <el-form-item label-width="150px" label="委托方名称:">
  563. <span>{{ props.row.clientName }}</span>
  564. </el-form-item>
  565. </el-col>
  566. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  567. <el-form-item label-width="150px" label="委托方电话:">
  568. <span>{{ props.row.clientTel }}</span>
  569. </el-form-item>
  570. </el-col>
  571. </el-row>
  572. <el-row class="row-style">
  573. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  574. <el-form-item label-width="150px" label="评估基准日:">
  575. <span>{{ props.row.valuationBasisDate }}</span>
  576. </el-form-item>
  577. </el-col>
  578. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  579. <el-form-item label-width="150px" label="评估面积:">
  580. <span>{{ props.row.evaluateAcreage }} m²</span>
  581. </el-form-item>
  582. </el-col>
  583. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  584. <el-form-item label-width="150px" label="评估单价:">
  585. <span>{{ props.row.evaluatePrice }}(元)</span>
  586. </el-form-item>
  587. </el-col>
  588. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  589. <el-form-item label-width="150px" label="评估总价:">
  590. <span>{{ props.row.evaluateAmount }}(万)</span>
  591. </el-form-item>
  592. </el-col>
  593. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  594. <el-form-item label-width="150px" label="产权人:">
  595. <span>{{ props.row.owner }}</span>
  596. </el-form-item>
  597. </el-col>
  598. </el-row>
  599. <el-row class="row-style">
  600. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  601. <el-form-item label-width="150px" label="产品打印数量:">
  602. <span>{{ props.row.printCount }}(份)</span>
  603. </el-form-item>
  604. </el-col>
  605. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  606. <el-form-item label-width="150px" label="产品出具日期:">
  607. <span>{{ props.row.createProductionDate }}</span>
  608. </el-form-item>
  609. </el-col>
  610. </el-row>
  611. <el-row class="row-style">
  612. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  613. <el-form-item label-width="150px" label="资料附件:">
  614. <span type="primary" v-for="file in props.row.filePath" :key="file.name">
  615. <el-link @click="officeFileView(file.name, file.url)">{{ file.name }}</el-link>
  616. </span>
  617. </el-form-item>
  618. </el-col>
  619. </el-row>
  620. <el-row class="row-style">
  621. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  622. <el-form-item prop="qrCode" label-width="150px" label="产品二维码:">
  623. <img style="width:130px;height:120px; display:inline-block ;" :src="props.row.qrCode"
  624. alt="NULL" />
  625. </el-form-item>
  626. </el-col>
  627. </el-row>
  628. <el-row class="row-style">
  629. <el-col :xs="24" :sm="12" :lg="6" :span="6" class="postInfo-container-item">
  630. <el-form-item label-width="150px" label="特殊情况说明:">
  631. <span>{{ props.row.comment }}</span>
  632. </el-form-item>
  633. </el-col>
  634. </el-row>
  635. </el-form>
  636. </template>
  637. </el-table-column>
  638. <el-table-column prop="productionNo" label="产品号" align="center" show-overflow-tooltip>
  639. <template slot-scope="{row}">
  640. <el-tag type="success"><span>{{ row.productionNo }}</span></el-tag>
  641. </template>
  642. </el-table-column>
  643. <el-table-column prop="productionType" label="产品类型" align="center" show-overflow-tooltip>
  644. <template slot-scope="{row}">
  645. <el-tag v-if="row.productionType === 'STATEMENT'">价值意见书</el-tag>
  646. <el-tag v-if="row.productionType == 'LETTER'">意见函</el-tag>
  647. <el-tag v-if="row.productionType == 'CONSULT'">咨询报告</el-tag>
  648. <el-tag v-if="row.productionType == 'REPORT'">评估报告</el-tag>
  649. </template>
  650. </el-table-column>
  651. <el-table-column prop="repertoryState" label="库存状态" align="center" show-overflow-tooltip>
  652. <template slot-scope="{row}">
  653. <el-tag type="danger" v-if="row.repertoryState === null">未入库</el-tag>
  654. <el-tag type="success" v-if="row.repertoryState === true">已出库</el-tag>
  655. <el-tag type="warning" v-if="row.repertoryState === false">已入库</el-tag>
  656. </template>
  657. </el-table-column>
  658. <el-table-column prop="comment" label="特殊情况说明" align="center" show-overflow-tooltip>
  659. </el-table-column>
  660. <el-table-column label="操作" align="center" width="180" fixed="right">
  661. <template slot-scope="scope">
  662. <el-button type="text" size="small"
  663. @click="openWriteProductionDialog(true, 'detail'), getAssetsProductionDetail(scope.row.id)">
  664. 查看
  665. </el-button>
  666. <el-button
  667. v-if="(currentNode.nodeCode === 'REVIEW_STATEMENT' || (currentNode.nodeCode === 'GENERATE_STATEMENT' && scope.row.productionType === 'STATEMENT') || (currentNode.nodeCode === 'WRITE_REPORT' && scope.row.productionType !== 'STATEMENT')) && !disabledStatus"
  668. type="text" size="small"
  669. @click="openWriteProductionDialog(false, 'edit'), getAssetsProductionDetail(scope.row.id)">
  670. 编辑
  671. </el-button>
  672. <el-button
  673. v-if="currentNode.nodeCode === 'REVIEW_STATEMENT' && scope.row.productionType === 'STATEMENT' && !disabledStatus"
  674. type="text" size="small"
  675. @click="productionPerformanceForm.productionId = scope.row.id, openProductionCheckDialog()">
  676. 审核意见书
  677. </el-button>
  678. <el-button
  679. v-if="currentNode.nodeCode === 'REEXAMINE_STATEMENT' && scope.row.productionType === 'STATEMENT' && !disabledStatus"
  680. type="text" size="small"
  681. @click="productionPerformanceForm.productionId = scope.row.id, openProductionCheckDialog()">
  682. 复审意见书
  683. </el-button>
  684. <el-button
  685. v-if="currentNode.nodeCode === 'CHECK_REPORT' && scope.row.productionType !== 'STATEMENT' && !disabledStatus"
  686. type="text" size="small"
  687. @click="productionPerformanceForm.productionId = scope.row.id, openProductionCheckDialog()">
  688. 审核报告
  689. </el-button>
  690. <el-button
  691. v-if="currentNode.nodeCode === 'RECHECK_REPORT' && scope.row.productionType !== 'STATEMENT' && !disabledStatus"
  692. type="text" size="small"
  693. @click="productionPerformanceForm.productionId = scope.row.id, openProductionCheckDialog()">
  694. 复审报告
  695. </el-button>
  696. <el-button
  697. v-if="currentNode.nodeCode === 'FOURTH_CHECK_REPORT' && scope.row.productionType !== 'STATEMENT' && !disabledStatus"
  698. type="text" size="small"
  699. @click="productionPerformanceForm.productionId = scope.row.id, openProductionCheckDialog()">
  700. 四审报告
  701. </el-button>
  702. <el-button
  703. v-if="(currentNode.nodeCode === 'STATEMENT_IN' || currentNode.nodeCode === 'REPORT_IN') && scope.row.repertoryState === null && !disabledStatus"
  704. type="text" size="small" @click="openWareHouseDialog(scope.row);">产品入库</el-button>
  705. <el-button
  706. v-if="(currentNode.nodeCode === 'STATEMENT_OUT' || currentNode.nodeCode === 'REPORT_OUT') && scope.row.repertoryState === false && !disabledStatus"
  707. type="text" size="small" @click="openWareHouseDialog(scope.row);">产品出库</el-button>
  708. </template>
  709. </el-table-column>
  710. </el-table>
  711. </div>
  712. </div>
  713. </el-tab-pane>
  714. <el-tab-pane name="finance" class="pane-class" :lazy=true>
  715. <span slot="label" @click="getOrderFundInvoiceById()"><i class="el-icon-document"></i>款项信息</span>
  716. <div class="createMajor-main-container">
  717. <div class="postInfo-container">
  718. <div style="margin-top: 35px;">
  719. <el-divider content-position="left">
  720. <h3 class="title">
  721. <div class="avatar-wrapper icon-title">款项</div>
  722. <div class="icon-info">资产款项信息</div>
  723. </h3>
  724. </el-divider>
  725. </div>
  726. </div>
  727. <el-form ref="invoiceData" :model="invoiceData" :disabled="true">
  728. <el-row>
  729. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  730. <el-form-item label="应收金额(元):" prop="shouldAmount" label-width="120px" class="postInfo-container-item">
  731. <el-input v-model="invoiceData.shouldAmount" class="filter-item" />
  732. </el-form-item>
  733. </el-col>
  734. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  735. <el-form-item label="实收金额(元):" prop="realAmount" label-width="120px" class="postInfo-container-item">
  736. <el-input v-model="invoiceData.realAmount" class="filter-item" />
  737. </el-form-item>
  738. </el-col>
  739. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  740. <el-form-item label="剩余金额(元):" prop="leftAmount" label-width="120px" class="postInfo-container-item">
  741. <el-input v-model="invoiceData.leftAmount" class="filter-item" />
  742. </el-form-item>
  743. </el-col>
  744. </el-row>
  745. <el-row v-for="(invoice, id) in invoiceData.financeInvoiceVoList" :key="id">
  746. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  747. <el-form-item label="开票类型:" prop="type" label-width="120px" class="postInfo-container-item">
  748. <el-input v-model="invoice.type" class="filter-item" />
  749. </el-form-item>
  750. </el-col>
  751. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  752. <el-form-item label="发票抬头:" prop="title" label-width="120px" class="postInfo-container-item">
  753. <el-input v-model="invoice.title" class="filter-item" />
  754. </el-form-item>
  755. </el-col>
  756. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  757. <el-form-item label="税号:" prop="taxNo" label-width="120px" class="postInfo-container-item">
  758. <el-input v-model="invoice.taxNo" class="filter-item" />
  759. </el-form-item>
  760. </el-col>
  761. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  762. <el-form-item label="开户银行:" prop="bankName" label-width="120px" class="postInfo-container-item">
  763. <el-input v-model="invoice.bankName" class="filter-item" />
  764. </el-form-item>
  765. </el-col>
  766. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  767. <el-form-item label="银行地址:" prop="bankAddress" label-width="120px" class="postInfo-container-item">
  768. <el-input v-model="invoice.bankAddress" class="filter-item" />
  769. </el-form-item>
  770. </el-col>
  771. <el-col :xs="24" :sm="12" :lg="6" :span="6">
  772. <el-form-item label="联系电话:" prop="bankTel" label-width="120px" class="postInfo-container-item">
  773. <el-input v-model="invoice.bankTel" class="filter-item" />
  774. </el-form-item>
  775. </el-col>
  776. </el-row>
  777. </el-form>
  778. </div>
  779. </el-tab-pane>
  780. </el-tabs>
  781. <el-dialog :visible.sync="targetDialogVisible" @open="clear()" @close="resettargetForm"
  782. custom-class="doWarehouseClass">
  783. <div>
  784. <el-form ref="targetForm" :model="targetForm" style="margin-top:20px" :rules="targetFormRules"
  785. :disabled="targetDisabledStatus">
  786. <el-divider content-position="left">【资产】评估对象</el-divider>
  787. <el-row class="row-style">
  788. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  789. <el-form-item label="评估目的:" prop="evaluationPurposeId" label-width="200px" class="postInfo-container-item">
  790. <el-select v-model="targetForm.evaluationPurposeId" style="width: 100%">
  791. <el-option v-for="(p, id) in assetsEvaluationTargetPurpose" :label="p.purposeName"
  792. :value="p.id"></el-option>
  793. </el-select>
  794. </el-form-item>
  795. </el-col>
  796. </el-row>
  797. <el-row class="row-style">
  798. <el-col :xs="24" :sm="12" :lg="12" :span="3">
  799. <el-form-item label="评估对象:" prop="evaluationTypeId" label-width="200px" class="postInfo-container-item">
  800. <el-select v-model="targetForm.evaluationTypeId"
  801. @change="getTypeList(targetForm.evaluationTypeId, 2), targetForm.evaluationTypeSecId = null"
  802. style="width: 100%">
  803. <el-option v-for="(t, id) in assetsEvaluationTargetType" :label="t.typeName" :value="t.id"
  804. :key="t.id"></el-option>
  805. </el-select>
  806. </el-form-item>
  807. </el-col>
  808. <el-col :xs="24" :sm="12" :lg="12" :span="3">
  809. <el-form-item prop="evaluationTypeSecId" label-width="10px" class="postInfo-container-item">
  810. <el-select v-model="targetForm.evaluationTypeSecId" style="width: 70%">
  811. <el-option v-for="(t, id) in assetsSecEvaluationTargetType" :label="t.typeName" :value="t.id"
  812. :key="t.id"></el-option>
  813. </el-select>
  814. </el-form-item>
  815. </el-col>
  816. <el-col :xs="24" :sm="12" :lg="12" :span="3"
  817. v-if="targetForm.evaluationTypeSecId && [15, 20, 34, 47].includes(targetForm.evaluationTypeSecId)">
  818. <el-form-item prop="evaluationTypeDefinedSec" label-width="200px" class="postInfo-container-item">
  819. <el-input v-model="targetForm.evaluationTypeDefinedSec" multiple style="width: 100%;">
  820. </el-input>
  821. </el-form-item>
  822. </el-col>
  823. </el-row>
  824. <el-row class="row-style">
  825. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  826. <el-form-item label=" 产权持有人:" prop="theHolder" label-width="200px" class="postInfo-container-item">
  827. <el-input v-model="targetForm.theHolder" class="filter-item" style="width: 100%" />
  828. </el-form-item>
  829. </el-col>
  830. </el-row>
  831. <el-row class="row-style">
  832. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  833. <el-form-item label="价值类型:" prop="assetsValueId" label-width="200px" class="postInfo-container-item">
  834. <el-select v-model="targetForm.assetsValueId" style="width: 100%">
  835. <el-option v-for="(t, id) in assetsValueType" :label="t.typeName" :value="t.id" :key="t.id"></el-option>
  836. </el-select>
  837. </el-form-item>
  838. </el-col>
  839. </el-row>
  840. <el-row class="row-style">
  841. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  842. <el-form-item label="项目负责人:" label-width="200px" class="postInfo-container-item">
  843. <el-select v-model="targetForm.principalId" placeholder="请选择" readonly disabled style="width: 100%">
  844. <el-option v-for="(u, id) in principals" :label="u.name" :value="u.id" :key="u.id"></el-option>
  845. </el-select>
  846. </el-form-item>
  847. </el-col>
  848. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  849. <el-form-item label="实勘人:" prop="siteIds" label-width="200px" class="postInfo-container-item">
  850. <el-select v-model="targetForm.siteIds" placeholder="请选择" multiple style="width: 100%">
  851. <el-option v-for="(u, id) in depUsers" :label="u.name" :value="u.id" :key="u.id"></el-option>
  852. </el-select>
  853. </el-form-item>
  854. </el-col>
  855. </el-row>
  856. <el-row class="row-style">
  857. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  858. <el-form-item prop="valuationBasisDate" label-width="200px" label="估价基准日:" class="postInfo-container-item">
  859. <el-date-picker v-model="targetForm.valuationBasisDate" type="date" placeholder="选择日期" value-format="yyyy-MM-dd" style="width:100%">
  860. </el-date-picker>
  861. </el-form-item>
  862. </el-col>
  863. </el-row>
  864. <el-row class="row-style">
  865. <el-col :xs="12" :sm="12" :lg="12" :span="12">
  866. <el-form-item label="评估方法:" prop="evaluationMethodId" label-width="200px" class="postInfo-container-item">
  867. <el-select v-model="targetForm.evaluationMethodId" multiple style="width: 100%;">
  868. <el-option v-for="(m, id) in assetsEvaluationMethod" :label="m.methodName" :value="m.id"
  869. :key="m.id"></el-option>
  870. </el-select>
  871. </el-form-item>
  872. </el-col>
  873. <el-col :xs="12" :sm="12" :lg="12" :span="12" v-if="targetForm.evaluationMethodId.includes(7)">
  874. <el-form-item prop="definedEvaluationMethod" label-width="20px" class="postInfo-container-item">
  875. <el-input v-model="targetForm.definedEvaluationMethod" multiple style="width: 50%;">
  876. </el-input>
  877. </el-form-item>
  878. </el-col>
  879. </el-row>
  880. <el-row class="row-style">
  881. <el-col :xs="12" :sm="12" :lg="12" :span="12">
  882. <el-form-item label="最终选择的评估方法:" prop="choiceEvaluationMethodId" label-width="200px"
  883. class="postInfo-container-item">
  884. <el-select v-model="targetForm.choiceEvaluationMethodId" multiple style="width: 100%;">
  885. <el-option v-for="(m, id) in assetsEvaluationMethod" :label="m.methodName" :value="m.id"
  886. :key="m.id"></el-option>
  887. </el-select>
  888. </el-form-item>
  889. </el-col>
  890. <el-col :xs="12" :sm="12" :lg="12" :span="12" v-if="targetForm.choiceEvaluationMethodId.includes(7)">
  891. <el-form-item prop="choiceDefinedEvaluationMethod" label-width="20px" class="postInfo-container-item">
  892. <el-input v-model="targetForm.choiceDefinedEvaluationMethod" multiple style="width: 50%;">
  893. </el-input>
  894. </el-form-item>
  895. </el-col>
  896. </el-row>
  897. <el-row class="row-style">
  898. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  899. <el-form-item label="总资产账面值:" prop="totalAssetCarryingAmount" label-width="200px"
  900. class="postInfo-container-item">
  901. <el-input-number v-model="targetForm.totalAssetCarryingAmount" controls-position="right" :precision="2"
  902. :step="0.1"></el-input-number>
  903. <span>(万)</span>
  904. </el-form-item>
  905. </el-col>
  906. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  907. <el-form-item label="总负债账面值:" prop="totalLiabilitiesCarryingAmount" label-width="200px"
  908. class="postInfo-container-item">
  909. <el-input-number v-model="targetForm.totalLiabilitiesCarryingAmount" controls-position="right"
  910. :precision="2" :step="0.1"></el-input-number>
  911. <span>(万)</span>
  912. </el-form-item>
  913. </el-col>
  914. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  915. <el-form-item label="净资产账面值:" prop="carryingAmountOfNetAssets" label-width="200px"
  916. class="postInfo-container-item">
  917. <el-input-number v-model="targetForm.carryingAmountOfNetAssets" controls-position="right" :precision="2"
  918. :step="0.1"></el-input-number>
  919. <span>(万)</span>
  920. </el-form-item>
  921. </el-col>
  922. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  923. <el-form-item label="评估结论对应的评估值:" prop="estimatedValue" label-width="200px" class="postInfo-container-item">
  924. <el-input-number v-model="targetForm.estimatedValue" controls-position="right" :precision="2"
  925. :step="0.1"></el-input-number>
  926. <span>(万)</span>
  927. </el-form-item>
  928. </el-col>
  929. </el-row>
  930. <el-row class="row-style" v-if="currentNode.nodeCode === 'REVIEW_QUOTATION'">
  931. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  932. <el-form-item label="审核定价:" prop="checkValue" label-width="200px" class="postInfo-container-item">
  933. <el-input-number v-model="targetForm.checkValue" controls-position="right" :precision="2"
  934. :step="0.1"></el-input-number>
  935. <span>(万)</span>
  936. </el-form-item>
  937. </el-col>
  938. </el-row>
  939. <el-row class="row-style">
  940. <el-col :xs="24" :sm="12" :lg="18" :span="6">
  941. <el-form-item prop="filePath" label="资料附件:" label-width="200px" class="postInfo-container-item">
  942. <el-upload action="/api/upload" :limit="10" :on-success="changeresTarget" :on-exceed="handleExceed"
  943. :on-preview="handleAttachmentPreview" :before-remove="beforeRemove" :file-list="fileList" multiple>
  944. <el-button plain type="info" round style="width: 100%">上传附件<i
  945. class="el-icon-upload el-icon--right"></i></el-button>
  946. </el-upload>
  947. </el-form-item>
  948. </el-col>
  949. </el-row>
  950. <el-row class="row-style">
  951. <el-col :xs="24" :sm="12" :lg="24" :span="12">
  952. <el-form-item label="备注:" prop="remark" label-width="200px" class="postInfo-container-item">
  953. <el-input v-model="targetForm.remark" :autosize="{ minRows: 4, maxRows: 4 }" class="filter-item"
  954. type="textarea" />
  955. </el-form-item>
  956. </el-col>
  957. </el-row>
  958. <el-row class="row-style" style="text-align:center">
  959. <el-button type="success" v-if="saveButtonStatus" @click="assetsTargetSave">保存</el-button>
  960. <el-button type="success" v-if="updateButtonStatus" @click="assetsTargetUpdate">更新</el-button>
  961. </el-row>
  962. </el-form>
  963. </div>
  964. </el-dialog>
  965. <el-dialog :visible.sync="productionChoiceDialogVisible">
  966. <el-form ref="assetsProductionForm" :model="assetsProductionForm" :rules="assetsProductionFormRules">
  967. <div class="createMajor-main-container">
  968. <div class="postInfo-container">
  969. <div>
  970. <el-divider content-position="left">
  971. <h3 class="title">
  972. <div class="avatar-wrapper icon-title">产品</div>
  973. <div class="icon-info">选择产品</div>
  974. </h3>
  975. </el-divider>
  976. </div>
  977. <el-row class="row-style">
  978. <el-col :xs="24" :sm="12" :lg="12" :span="6" style="width: 800px;">
  979. <el-form-item label="产品类型:" prop="productionType" label-width="120px" class="postInfo-container-item">
  980. <el-radio v-if="currentNode.nodeCode === 'PRODUCT_CHOICE'" v-model="assetsProductionForm.productionType"
  981. label="STATEMENT" border size="medium">价值意见书</el-radio>
  982. <el-radio v-model="assetsProductionForm.productionType" label="CONSULT" border
  983. size="medium">咨询报告</el-radio>
  984. <el-radio v-model="assetsProductionForm.productionType" label="REPORT" border
  985. size="medium">评估报告</el-radio>
  986. <el-radio v-model="assetsProductionForm.productionType" label="LETTER" border
  987. size="medium">意见函</el-radio>
  988. </el-form-item>
  989. </el-col>
  990. </el-row>
  991. <el-row class="row-style">
  992. <el-col :xs="24" :sm="12" :lg="12" :span="6" style="width: 345px;">
  993. <el-form-item label="打印份数:" prop="printCount" label-width="120px" class="postInfo-container-item">
  994. <el-input v-model.number="assetsProductionForm.printCount" class="filter-item" />
  995. </el-form-item>
  996. </el-col>
  997. </el-row>
  998. <el-row class="row-style" style="text-align:center">
  999. <el-button type="primary" v-if="productionChoiceStatus == 0" @click="assetsProductionSave">提交</el-button>
  1000. <el-button type="primary" v-if="productionChoiceStatus == 1"
  1001. @click="assetsProductionUpdateChoice">提交</el-button>
  1002. </el-row>
  1003. </div>
  1004. </div>
  1005. </el-form>
  1006. </el-dialog>
  1007. <el-dialog :visible.sync="productionWriteDialogVisible" @open="clearassetsProductionFormValidate(), byAssetEvaluator()"
  1008. @close="resetProductionForm()">
  1009. <el-form ref="assetsProductionForm" :model="assetsProductionForm" :rules="assetsProductionFormRules"
  1010. :disabled="productionDisabledStatus">
  1011. <div class="createMajor-main-container">
  1012. <div class="postInfo-container">
  1013. <div>
  1014. <el-divider content-position="left">
  1015. <h3 class="title">
  1016. <div class="avatar-wrapper icon-title">产品</div>
  1017. <div class="icon-info">撰写产品信息</div>
  1018. </h3>
  1019. </el-divider>
  1020. </div>
  1021. <el-row class="row-style">
  1022. <el-col v-if="currentNode.nodeCode === 'GENERATE_STATEMENT'">
  1023. <el-form-item label="产品号:" prop="productionNo" label-width="140px" class="postInfo-container-item">
  1024. <el-select v-model="assetsProductionForm.productionNo" @change="getAssetsProductionDetailByNo()"
  1025. placeholder="请选择" style="width: 300px;">
  1026. <el-option v-for="statementNo in writeProductionStatementNos" :label="statementNo"
  1027. :value="statementNo" :key="statementNo"></el-option>
  1028. </el-select>
  1029. </el-form-item>
  1030. </el-col>
  1031. <el-col v-if="currentNode.nodeCode === 'WRITE_REPORT'">
  1032. <el-form-item label="产品号:" prop="productionNo" label-width="140px" class="postInfo-container-item">
  1033. <el-select v-model="assetsProductionForm.productionNo" @change="getAssetsProductionDetailByNo()"
  1034. placeholder="请选择" style="width: 300px;">
  1035. <el-option v-for="reportNo in writeProductionReportNos" :label="reportNo" :value="reportNo"
  1036. :key="reportNo"></el-option>
  1037. </el-select>
  1038. </el-form-item>
  1039. </el-col>
  1040. </el-row>
  1041. <el-row class="row-style">
  1042. <el-col>
  1043. <el-form-item label="项目名称:" prop="assetsName" label-width="140px" class="postInfo-container-item">
  1044. <el-input v-model.number="assetsProductionForm.assetsName" class="filter-item" />
  1045. </el-form-item>
  1046. </el-col>
  1047. </el-row>
  1048. <el-row class="row-style"
  1049. v-if="(assetsProductionForm.productionType && assetsProductionForm.productionType === 'REPORT')">
  1050. <el-col>
  1051. <el-form-item label="签字人:" prop="signatory" label-width="140px" class="postInfo-container-item">
  1052. <el-select v-model="assetsProductionForm.signatory" placeholder="请选择" multiple>
  1053. <el-option v-for="(u, id) in assetEvaluator" :label="u.name" :value="u.id" :key="u.id"></el-option>
  1054. </el-select>
  1055. </el-form-item>
  1056. </el-col>
  1057. </el-row>
  1058. <el-row class="row-style">
  1059. <el-col>
  1060. <el-form-item label="委托方名称:" prop="clientName" label-width="140px" class="postInfo-container-item">
  1061. <el-input v-model.number="assetsProductionForm.clientName" class="filter-item" />
  1062. </el-form-item>
  1063. </el-col>
  1064. </el-row>
  1065. <el-row class="row-style">
  1066. <el-col>
  1067. <el-form-item label="委托方电话:" prop="clientTel" label-width="140px" class="postInfo-container-item">
  1068. <el-input v-model.number="assetsProductionForm.clientTel" class="filter-item" />
  1069. </el-form-item>
  1070. </el-col>
  1071. </el-row>
  1072. <el-row class="row-style">
  1073. <el-col>
  1074. <el-form-item label="估价基准日:" prop="valuationBasisDate" label-width="140px"
  1075. class="postInfo-container-item">
  1076. <el-date-picker v-model="assetsProductionForm.valuationBasisDate" type="date" placeholder="选择日期" value-format="yyyy-MM-dd"
  1077. style="width:100%">
  1078. </el-date-picker>
  1079. </el-form-item>
  1080. </el-col>
  1081. </el-row>
  1082. <el-row class="row-style">
  1083. <el-col>
  1084. <el-form-item label="评估面积:" prop="evaluateAcreage" label-width="140px" class="postInfo-container-item">
  1085. <el-input-number v-model="assetsProductionForm.evaluateAcreage" @change="computeAmount"
  1086. controls-position="right" :precision="2" :step="0.1"></el-input-number>
  1087. <span>(m²)</span>
  1088. </el-form-item>
  1089. </el-col>
  1090. </el-row>
  1091. <el-row class="row-style">
  1092. <el-col>
  1093. <el-form-item label="评估单价:" prop="evaluatePrice" label-width="140px" class="postInfo-container-item">
  1094. <el-input-number v-model="assetsProductionForm.evaluatePrice" @change="computeAmount"
  1095. controls-position="right" :precision="2" :step="0.1"></el-input-number>
  1096. <span>(元)</span>
  1097. </el-form-item>
  1098. </el-col>
  1099. </el-row>
  1100. <el-row class="row-style">
  1101. <el-col>
  1102. <el-form-item label="评估总价:" prop="evaluateAmount" label-width="140px" class="postInfo-container-item">
  1103. <el-input-number v-model="assetsProductionForm.evaluateAmount" controls-position="right" :precision="2"
  1104. :step="0.1"></el-input-number>
  1105. <span>(万)</span>
  1106. </el-form-item>
  1107. </el-col>
  1108. </el-row>
  1109. <el-row class="row-style">
  1110. <el-col>
  1111. <el-form-item label="资产持有人:" prop="owner" label-width="140px" class="postInfo-container-item">
  1112. <el-input v-model.number="assetsProductionForm.owner" class="filter-item" />
  1113. </el-form-item>
  1114. </el-col>
  1115. </el-row>
  1116. <el-row class="row-style">
  1117. <el-col>
  1118. <el-form-item label="产品打印份数:" prop="printCount" label-width="140px" class="postInfo-container-item">
  1119. <el-input v-model.number="assetsProductionForm.printCount" class="filter-item" />
  1120. </el-form-item>
  1121. </el-col>
  1122. </el-row>
  1123. <el-row class="row-style">
  1124. <el-col>
  1125. <el-form-item label="出具产品日期:" prop="createProductionDate" label-width="140px"
  1126. class="postInfo-container-item">
  1127. <el-date-picker v-model="assetsProductionForm.createProductionDate" type="date" placeholder="选择日期" value-format="yyyy-MM-dd"
  1128. style="width:100%">
  1129. </el-date-picker>
  1130. </el-form-item>
  1131. </el-col>
  1132. </el-row>
  1133. <el-row class="row-style">
  1134. <el-col>
  1135. <el-form-item prop="filePath" label="资料附件:" label-width="140px" class="postInfo-container-item">
  1136. <el-upload action="/api/upload" :limit="10" :on-success="changeresProduction" :on-exceed="handleExceed"
  1137. :on-preview="handleAttachmentPreview" :before-remove="beforeRemovePro" :file-list="fileList" multiple>
  1138. <el-button plain type="info" round style="width: 100%">上传附件<i
  1139. class="el-icon-upload el-icon--right"></i></el-button>
  1140. </el-upload>
  1141. </el-form-item>
  1142. </el-col>
  1143. </el-row>
  1144. <el-row class="row-style">
  1145. <el-col>
  1146. <el-form-item label="特殊情况说明:" prop="comment" label-width="140px" class="postInfo-container-item">
  1147. <el-input v-model="assetsProductionForm.comment" :autosize="{ minRows: 4, maxRows: 4 }"
  1148. class="filter-item" type="textarea" />
  1149. </el-form-item>
  1150. </el-col>
  1151. </el-row>
  1152. <el-row class="row-style" style="text-align:center">
  1153. <el-button type="primary" v-if="writeType === 'add'" @click="writeAssetsProduction()">提交</el-button>
  1154. </el-row>
  1155. <el-row class="row-style" style="text-align:center">
  1156. <el-button type="primary" v-if="writeType === 'edit'" @click="productionUpdate()">提交</el-button>
  1157. </el-row>
  1158. </div>
  1159. </div>
  1160. </el-form>
  1161. </el-dialog>
  1162. <el-dialog :visible.sync="checkValueDialogVisible">
  1163. <el-divider content-position="left">【资产】审核定价</el-divider>
  1164. <el-form ref="targetForm" :model="targetForm" :rules="targetFormRules">
  1165. <div class="createMajor-main-container">
  1166. <div class="postInfo-container">
  1167. <el-row>
  1168. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  1169. <el-form-item label="评估方法:" prop="evaluationMethodId" label-width="190px" class="postInfo-container-item">
  1170. <el-select v-model="targetForm.evaluationMethodId" multiple style="width: 100%;">
  1171. <el-option v-for="(m, id) in assetsEvaluationMethod" :label="m.methodName" :value="m.id"
  1172. :key="m.id"></el-option>
  1173. </el-select>
  1174. </el-form-item>
  1175. </el-col>
  1176. <el-col :xs="24" :sm="12" :lg="12" :span="6" v-if="targetForm.evaluationMethodId.includes(7)">
  1177. <el-form-item prop="definedEvaluationMethod" label-width="20px" class="postInfo-container-item">
  1178. <el-input v-model="targetForm.definedEvaluationMethod" multiple style="width: 50%;">
  1179. </el-input>
  1180. </el-form-item>
  1181. </el-col>
  1182. </el-row>
  1183. <el-row>
  1184. <el-col :xs="24" :sm="12" :lg="12" :span="6">
  1185. <el-form-item label="最终选择的评估方法:" prop="choiceEvaluationMethodId" label-width="190px"
  1186. class="postInfo-container-item">
  1187. <el-select v-model="targetForm.choiceEvaluationMethodId" multiple style="width: 100%;">
  1188. <el-option v-for="(m, id) in assetsEvaluationMethod" :label="m.methodName" :value="m.id"
  1189. :key="m.id"></el-option>
  1190. </el-select>
  1191. </el-form-item>
  1192. </el-col>
  1193. <el-col :xs="24" :sm="12" :lg="12" :span="6" v-if="targetForm.choiceEvaluationMethodId.includes(7)">
  1194. <el-form-item prop="choiceDefinedEvaluationMethod" label-width="20px" class="postInfo-container-item">
  1195. <el-input v-model="targetForm.choiceDefinedEvaluationMethod" multiple style="width: 50%;">
  1196. </el-input>
  1197. </el-form-item>
  1198. </el-col>
  1199. </el-row>
  1200. <el-row>
  1201. <el-col>
  1202. <el-form-item label="审核价格:" prop="checkValue" label-width="190px" class="postInfo-container-item">
  1203. <el-input-number v-model="targetForm.checkValue" controls-position="right" :precision="2" :step="0.1"></el-input-number>
  1204. <span>(万)</span>
  1205. </el-form-item>
  1206. </el-col>
  1207. </el-row>
  1208. <el-row style="text-align:center">
  1209. <el-col>
  1210. <el-button type="primary" @click="checkValue()">审核定价</el-button>
  1211. </el-col>
  1212. </el-row>
  1213. </div>
  1214. </div>
  1215. </el-form>
  1216. </el-dialog>
  1217. <el-dialog :visible.sync="productionCheckDialogVisible" @close="resetProductionForm()">
  1218. <el-form ref="productionPerformanceForm" :model="productionPerformanceForm">
  1219. <div class="createMajor-main-container">
  1220. <div class="postInfo-container">
  1221. <div>
  1222. <el-divider content-position="left">
  1223. <h3 class="title">
  1224. <div class="avatar-wrapper icon-title">产品</div>
  1225. <div class="icon-info">产品质检</div>
  1226. </h3>
  1227. </el-divider>
  1228. </div>
  1229. <el-row class="row-style">
  1230. <el-col>
  1231. <el-form-item prop="normalMistake" label-width="120px" class="postInfo-container-item" label="一般错误个数:">
  1232. <el-input-number :min="0" style="width:50%;" type="number"
  1233. v-model="productionPerformanceForm.normalMistake" class="filter-item" />
  1234. </el-form-item>
  1235. </el-col>
  1236. </el-row>
  1237. <el-row class="row-style">
  1238. <el-col>
  1239. <el-form-item prop="normalMistake" label-width="120px" class="postInfo-container-item" label="较大错误个数:">
  1240. <el-input-number :min="0" style="width:50%;" type="number"
  1241. v-model="productionPerformanceForm.hardMistake" class="filter-item" />
  1242. </el-form-item>
  1243. </el-col>
  1244. </el-row>
  1245. <el-row class="row-style">
  1246. <el-col>
  1247. <el-form-item prop="fatalMistake" label-width="120px" class="postInfo-container-item" label="重大错误个数:">
  1248. <el-input-number :min="0" style="width:50%;" type="number"
  1249. v-model="productionPerformanceForm.fatalMistake" class="filter-item" />
  1250. </el-form-item>
  1251. </el-col>
  1252. </el-row>
  1253. <el-row class="row-style">
  1254. <el-col :xs="24" :sm="12" :lg="24" :span="6">
  1255. <el-form-item prop="reason" label-width="120px" class="postInfo-container-item" label="扣分原因:">
  1256. <el-input v-model.trim="productionPerformanceForm.reason" class="filter-item" type="textarea" />
  1257. </el-form-item>
  1258. </el-col>
  1259. </el-row>
  1260. <div v-if="currentNode.nodeCode === 'RECHECK_REPORT' || currentNode.nodeCode === 'FOURTH_CHECK_REPORT'">
  1261. <el-row class="row-style">
  1262. <el-col>
  1263. <el-form-item label="特殊情况说明:" prop="comment" label-width="150px" class="postInfo-container-item">
  1264. <el-input v-model="assetsProductionForm.comment" :autosize="{ minRows: 4, maxRows: 4 }"
  1265. class="filter-item" type="textarea" />
  1266. </el-form-item>
  1267. </el-col>
  1268. </el-row>
  1269. <el-row class="row-style">
  1270. <el-col>
  1271. <el-form-item :rules="{ required: true, message: '请上传附件资料', trigger: 'changes' }" prop="filePath"
  1272. label="资料附件:" label-width="120px" class="postInfo-container-item">
  1273. <el-upload action="/api/upload" :limit="10" :on-success="changeresProduction" :on-exceed="handleExceed"
  1274. :on-preview="handleAttachmentPreview" :before-remove="beforeRemovePro" :file-list="fileList" multiple>
  1275. <el-button plain type="info" round style="width: 100%">上传附件<i
  1276. class="el-icon-upload el-icon--right"></i></el-button>
  1277. </el-upload>
  1278. </el-form-item>
  1279. </el-col>
  1280. </el-row>
  1281. </div>
  1282. <el-row style="text-align:center">
  1283. <el-col>
  1284. <el-button type="primary" @click="saveQuality()">提交</el-button>
  1285. </el-col>
  1286. </el-row>
  1287. </div>
  1288. </div>
  1289. </el-form>
  1290. </el-dialog>
  1291. <el-dialog :visible.sync="warehouseDialog" width="25%" center top="35vh" custom-class="doWarehouseClass"
  1292. @closed="cleanWareHouseProductionType()">
  1293. <ScanEntry ref="scanEntry" @scanEntryFun="handleScanEntry" label="请扫描二维码或输入报告号" />
  1294. <span slot="footer" class="dialog-footer">
  1295. <el-button @click="warehouseDialog = false">取 消</el-button>
  1296. <el-button type="primary" @click="doWareHouse()">确 定</el-button>
  1297. </span>
  1298. </el-dialog>
  1299. <el-dialog :visible.sync="assetsAchievementRatioDialogVisible" @close="resetProductionForm()"
  1300. @closed="resetBusinessPerformanceDistributionForm()" width="25%">
  1301. <div v-if="businessPerformanceDistributionForm.distributionList !== null" class="createMajor-main-container">
  1302. <div class="postInfo-container">
  1303. <div>
  1304. <el-divider content-position="left">
  1305. <h3 class="title">
  1306. <div class="avatar-wrapper icon-title">归档</div>
  1307. <div class="icon-info">归档审核</div>
  1308. </h3>
  1309. </el-divider>
  1310. </div>
  1311. <!-- <p style="margin-top: 50px; color: red;">绩效比例:</p>
  1312. <el-row style="margin-top: 10px;" v-for="(member, index) in assetsBusinessMembers" :key="index"
  1313. class="row-style">
  1314. <el-col>
  1315. <p style="width: 65px; display: inline-block; text-align: right;">
  1316. {{ member.memberName }}:
  1317. </p>
  1318. <el-input-number
  1319. v-model="businessPerformanceDistributionForm.distributionList[index].performanceDistribution"
  1320. :precision="2" :step="0.1" :max="100">
  1321. </el-input-number>
  1322. <p style="margin-left: 5px; display: inline-block;">
  1323. %
  1324. </p>
  1325. <p style="margin-left: 5px; display: inline-block;">
  1326. <span v-if="member.memberType === '项目负责人'" style="color: blueviolet;">
  1327. * {{ member.memberType }}
  1328. </span>
  1329. <span v-if="member.memberType === '项目参与人'">
  1330. * {{ member.memberType }}
  1331. </span>
  1332. <span v-if="member.memberType === '签字师'" style="color: red;">
  1333. * {{ member.memberType }}
  1334. </span>
  1335. </p>
  1336. </el-col>
  1337. </el-row> -->
  1338. <span v-if="currentNode.nodeCode === 'CHECK_ARCHIVING'">
  1339. <el-row style="margin-top: 10px;" class="row-style">
  1340. <el-col>
  1341. <el-form>
  1342. <el-form-item :rules="{ required: true, message: '请上传附件资料', trigger: 'changes' }" prop="filePath"
  1343. label="资料附件:" label-width="120px" class="postInfo-container-item">
  1344. <el-upload action="/api/upload" :limit="10" :on-success="changeresProduction" :on-exceed="handleExceed"
  1345. :on-preview="handleAttachmentPreview" :before-remove="beforeRemovePro" :file-list="fileList" multiple>
  1346. <el-button plain type="info" round style="width: 100%">上传附件<i
  1347. class="el-icon-upload el-icon--right"></i></el-button>
  1348. </el-upload>
  1349. </el-form-item>
  1350. </el-form>
  1351. </el-col>
  1352. </el-row>
  1353. </span>
  1354. </div>
  1355. </div>
  1356. <span v-if="businessPerformanceDistributionForm.distributionList !== null" slot="footer" class="dialog-footer">
  1357. <el-button @click="assetsAchievementRatioDialogVisible = false">取 消</el-button>
  1358. <!-- <el-button v-if="showDistributionButton" type="primary" @click="saveBusinessPerformanceDistribution()">新
  1359. 增</el-button>
  1360. <el-button v-if="!showDistributionButton" type="primary" @click="updateAssetsPerformanceDistribution()">修
  1361. 改</el-button> -->
  1362. <el-button @click="updateProductionFileInfo(), assetsAchievementRatioDialogVisible = false">确 认</el-button>
  1363. </span>
  1364. </el-dialog>
  1365. </div>
  1366. </template>
  1367. <script>
  1368. import YDetailPageLayout from '@/components/YDetailPageLayout/index_detail'
  1369. import WorkflowBoard from '@/components/workflowBoard'
  1370. import ScanEntry from '@/components/ScanEntry'
  1371. import { isNumber, phoneNumber, postiveInteger, isIdNumber } from '@/utils/validate'
  1372. export default {
  1373. name: 'AssetsOrderDetail',
  1374. components: {
  1375. YDetailPageLayout,
  1376. WorkflowBoard,
  1377. ScanEntry
  1378. },
  1379. watch: {
  1380. $route(to, from) {
  1381. // 获取页面参数
  1382. this.pageParams.back = this.$route.query.back;
  1383. this.pageParams.row = JSON.parse(this.$route.query.row);
  1384. this.getProductionTypes(this.pageParams.row.assetsId);
  1385. this.nodeBusinessInfo.doWorkflow = true;
  1386. this.nodeBusinessInfo.mainBusiness = 'ASSET_BUSINESS';
  1387. this.nodeBusinessInfo.businessId = this.pageParams.row.assetsId;
  1388. this.nodeBusinessInfo.businessSubId = this.pageParams.row.statementNo;
  1389. this.nodeBusinessInfo.businessMinId = this.pageParams.row.reportNo;
  1390. this.nodeBusinessInfo.reportNos.push(this.pageParams.row.statementNo);
  1391. this.disabledStatus = this.$route.query.disabledStatus === 'true';
  1392. this.couldEdit = this.$route.query.couldEdit === 'true';
  1393. this.couldBack = this.$route.query.couldBack === 'true';
  1394. if (this.$route.query.activeTabName !== null && this.$route.query.activeTabName !== undefined) {
  1395. this.activeTabName = this.$route.query.activeTabName;
  1396. }
  1397. this.byDepartmentName();
  1398. this.getCurrentNodeInfo();
  1399. this.getAllotDepartment();
  1400. this.getAssetsDetailById(this.pageParams.row.assetsId);
  1401. this.getAETargetListByAssetsId();
  1402. this.getOrderFundInvoiceById();
  1403. }
  1404. },
  1405. data() {
  1406. var checkSignatoryLength = (rule, value, callback) => {
  1407. if (this.assetsProductionForm.signatory !== undefined && this.assetsProductionForm.signatory !== null) {
  1408. if (this.assetsProductionForm.signatory.length < 2) {
  1409. return callback(new Error('需至少选择两个签字人'));
  1410. } else {
  1411. callback();
  1412. }
  1413. }
  1414. };
  1415. return {
  1416. editStatus: false,
  1417. // 资产业务表单禁用状态
  1418. disabledStatus: true,
  1419. // 评估对象表单禁用状态
  1420. targetDisabledStatus: true,
  1421. // 评估对象表单保存按钮显示状态
  1422. saveButtonStatus: true,
  1423. // 评估对象表单更新按钮显示状态
  1424. updateButtonStatus: true,
  1425. couldEdit: null,
  1426. couldBack: null,
  1427. // 表单项目隐藏字段
  1428. itemHideStatus: false,
  1429. createLinkmanVisible: false,
  1430. // 文件上传数组
  1431. fileList: [],
  1432. // 资产业务下单表单校验规则
  1433. assetsFormRules: {
  1434. departmentId: [
  1435. { required: true, message: '请选择接单部门', trigger: 'change' }
  1436. ],
  1437. name: [
  1438. { required: true, message: '项目名称不能为空', trigger: 'blur' }
  1439. ],
  1440. assetsBusinessGener: [
  1441. { required: true, message: '请选择业务类型', trigger: 'change' }
  1442. ],
  1443. entrustAgain: [
  1444. { required: true, message: '请选择客户是否再次委托', trigger: 'change' }
  1445. ],
  1446. clienteleType: [
  1447. { required: true, message: '请选择客户类型', trigger: 'change' }
  1448. ],
  1449. clienteleId: [
  1450. { required: true, message: '请选择客户名称', trigger: 'change' }
  1451. ],
  1452. clienteleSubId: [
  1453. { required: true, message: '请选择业务来源', trigger: 'change' }
  1454. ],
  1455. clienteleContactId: [
  1456. { required: true, message: '请选择客户联系人', trigger: 'change' }
  1457. ],
  1458. security: [
  1459. { required: true, message: '请选择是否证券项目', trigger: 'change' }
  1460. ],
  1461. significantAssetsReorganization: [
  1462. { required: true, message: '请选择是否资产重组项目', trigger: 'change' }
  1463. ],
  1464. stateAssets: [
  1465. { required: true, message: '请选择是否是否国资项目', trigger: 'change' }
  1466. ],
  1467. foreignAssetsInvolved: [
  1468. { required: true, message: '请选择是否 是否涉及境外资产', trigger: 'change' }
  1469. ],
  1470. dispenseBenefit: [
  1471. { required: true, message: '请选择是否是否分配产值', trigger: 'change' }
  1472. ],
  1473. // terminalClienteleType: [
  1474. // { required: true, message: '请选择终端客户类型', trigger: 'change' }
  1475. // ],
  1476. terminalClienteleId: [
  1477. { required: true, message: '终端客户名称不能为空', trigger: 'blur' }
  1478. ],
  1479. terminalClienteleContactId: [
  1480. { required: true, message: '终端联系人不能为空', trigger: 'blur' }
  1481. ],
  1482. bailorContactTel: [
  1483. { required: false, validator: phoneNumber, trigger: 'blur' }
  1484. ]
  1485. },
  1486. workflowLogs: [],
  1487. activeName: 'workflowInfo',
  1488. activeTabName: "baseInfo",
  1489. nodeBusinessInfo: {
  1490. currentNodePermission: {
  1491. commit: true,
  1492. reversible: true,
  1493. restartable: true,
  1494. terminable: true,
  1495. skippable: true,
  1496. },
  1497. mainBusiness: "ASSET_BUSINESS",
  1498. doWorkflow: false,
  1499. businessSubId: null,
  1500. businessId: null,
  1501. currentNodeInstanceId: null,
  1502. production: [],
  1503. reportNos: [],
  1504. currentNodeInstanceCode: null,
  1505. ifCheckTask: true,
  1506. ifPay: null,
  1507. doFourthCheck: false,
  1508. ifProductionFund: false
  1509. },
  1510. currentNode: {
  1511. flowId: null,
  1512. pnodeId: null,
  1513. nodeId: null,
  1514. flowCode: null,
  1515. nodeName: "",
  1516. nodeCode: null,
  1517. state: "",
  1518. instanceId: null,
  1519. sequence: null,
  1520. restartable: null,
  1521. reversible: null,
  1522. skippable: null,
  1523. terminable: null,
  1524. tasks: []
  1525. },
  1526. assetsForm: {
  1527. // 项目名
  1528. name: null,
  1529. // 客户经理id
  1530. clientManagerId: this.$store.getters.userInfo.id,
  1531. // 客户经理
  1532. clientManagerName: this.$store.getters.userInfo.name,
  1533. // 接单部门id
  1534. departmentId: null,
  1535. // 资产业务类型
  1536. assetsBusinessGener: null,
  1537. // 客户再次委托
  1538. entrustAgain: null,
  1539. // 客户类型(企业,个人)
  1540. clienteleType: null,
  1541. // 客户id
  1542. clienteleId: null,
  1543. // 业务来源(下级客户id)
  1544. clienteleSubId: null,
  1545. // 客户联系人id
  1546. clienteleContactId: null,
  1547. // 是否证券项目
  1548. security: null,
  1549. // 是否资产重组项目
  1550. significantAssetsReorganization: null,
  1551. // 是否国资项目
  1552. stateAssets: null,
  1553. // 是否涉及境外资产
  1554. foreignAssetsInvolved: null,
  1555. // 是否分配产值
  1556. dispenseBenefit: null,
  1557. // 委托人
  1558. bailor: null,
  1559. // 委托人地址
  1560. bailorAddress: null,
  1561. // 委托联系人姓名
  1562. bailorContactName: null,
  1563. // 委托人联系人电话
  1564. bailorContactTel: null,
  1565. // 终端客户id
  1566. terminalClienteleId: null,
  1567. // 终端客户类型
  1568. terminalClienteleType: null,
  1569. // 终端联系人id
  1570. terminalClienteleContactId: null,
  1571. // 备注
  1572. remark: null,
  1573. // 终端联系电话
  1574. tmobile: null,
  1575. // 分单类型
  1576. allotType: "指派",
  1577. // 项目成员
  1578. members: null,
  1579. },
  1580. // 客户联系人信息
  1581. linkmanInfo: {
  1582. },
  1583. // 终端联系人信息
  1584. tLinkmanInfo: {
  1585. },
  1586. // 终端客户信息
  1587. tCustomerInfo: {
  1588. },
  1589. //
  1590. pageParams: {
  1591. back: null,
  1592. row: null
  1593. },
  1594. // 业务类型下拉列表
  1595. assetsBusinessGeners: [
  1596. {
  1597. value: '企业价值',
  1598. label: '企业价值'
  1599. }, {
  1600. value: '单项资产',
  1601. label: '单项资产'
  1602. }, {
  1603. value: '资产组合',
  1604. label: '资产组合'
  1605. }, {
  1606. value: '无形资产',
  1607. label: '无形资产'
  1608. }, {
  1609. value: '森林资源资产',
  1610. label: '森林资源资产'
  1611. }, {
  1612. value: '珠宝首饰艺术品',
  1613. label: '珠宝首饰艺术品'
  1614. }, {
  1615. value: '其他资产评估',
  1616. label: '其他资产评估'
  1617. }
  1618. ],
  1619. // 接单部门
  1620. allotDepartment: [],
  1621. // 客户信息
  1622. customerCompany: [],
  1623. // 业务信息(二级客户)
  1624. subCustomerCompany: [],
  1625. // 客户联系人下拉列表
  1626. customerContract: [],
  1627. // 终端客户下拉列表
  1628. tCustomerCompany: [],
  1629. // 终端联系人下拉列表
  1630. tCustomerContract: [],
  1631. // 项目负责人下拉列表
  1632. principals: [],
  1633. // 用户下拉列表
  1634. allUsers: [],
  1635. // 资产评估师
  1636. assetEvaluator: [],
  1637. // 资产事业部人员
  1638. depUsers: [],
  1639. // 资产评估对象信息
  1640. assetsEvaluationTarget: [],
  1641. writeProductionStatementNos: [],
  1642. writeProductionReportNos: [],
  1643. // 估计对象总价
  1644. totalEvaluateValue: 0.00,
  1645. // 评估对象表单
  1646. targetForm: {
  1647. id: null,
  1648. // 资产评估目的id
  1649. evaluationPurposeId: null,
  1650. // 资产评估对象类型一级id
  1651. evaluationTypeId: null,
  1652. // 资产评估对象类型二级id
  1653. evaluationTypeSecId: null,
  1654. // 其他自定义二级资产评估对象类型
  1655. evaluationTypeDefinedSec: null,
  1656. // 产权持有人
  1657. theHolder: null,
  1658. // 资产价值类型id
  1659. assetsValueId: null,
  1660. // 项目负责人id
  1661. principalId: null,
  1662. // 实勘人id (json 可多个)
  1663. siteIds: [],
  1664. // 估价基准日
  1665. valuationBasisDate: null,
  1666. // 评估方法id
  1667. evaluationMethodId: [],
  1668. // 最终选择的评估方法id
  1669. choiceEvaluationMethodId: [],
  1670. // 总资产账面值(万)
  1671. totalAssetCarryingAmount: null,
  1672. // 总负债账面值(万)
  1673. totalLiabilitiesCarryingAmount: null,
  1674. // 净资产账面值(万)
  1675. carryingAmountOfNetAssets: null,
  1676. // 评估结论对应的评估值(万)
  1677. estimatedValue: null,
  1678. // 审核价格
  1679. checkValue: null,
  1680. // 资料路由信息
  1681. filePath: [],
  1682. // 资产业务id
  1683. assetsId: null,
  1684. //自定义其他评估方法
  1685. definedEvaluationMethod: null,
  1686. //最终选择的自定义其他评估方法
  1687. choiceDefinedEvaluationMethod: null
  1688. },
  1689. // 资产评估对象评估目的
  1690. assetsEvaluationTargetPurpose: [],
  1691. // 资产评估方法
  1692. assetsEvaluationMethod: [],
  1693. // 资产价值类型
  1694. assetsValueType: [],
  1695. // 资产评估对象类型
  1696. assetsEvaluationTargetType: [],
  1697. // 二级资产评估对象类型
  1698. assetsSecEvaluationTargetType: [],
  1699. // 评估对象弹窗可视状态
  1700. targetDialogVisible: false,
  1701. // 添加评估对象表单校验规则
  1702. targetFormRules: {
  1703. evaluationPurposeId: [
  1704. { required: true, message: '请选择评估目的', trigger: 'change' }
  1705. ],
  1706. evaluationTypeId: [
  1707. { required: true, message: '请选择评估对象', trigger: 'change' }
  1708. ],
  1709. evaluationTypeSecId: [
  1710. { required: true, message: '请选择评估对象', trigger: 'change' }
  1711. ],
  1712. evaluationTypeDefinedSec: [
  1713. { required: true, message: '请填写其他', trigger: 'change' }
  1714. ],
  1715. theHolder: [
  1716. { required: true, message: '请填写产权持有人', trigger: 'blur' }
  1717. ],
  1718. assetsValueId: [
  1719. { required: true, message: '请选择价值类型', trigger: 'change' }
  1720. ],
  1721. principalId: [
  1722. { required: true, message: '请选择项目负责人', trigger: 'change' }
  1723. ],
  1724. siteIds: [
  1725. { required: true, message: '请选择实勘人', trigger: 'change' }
  1726. ],
  1727. valuationBasisDate: [
  1728. { required: true, message: '请选择价格基准日', trigger: 'change' }
  1729. ],
  1730. evaluationMethodId: [
  1731. { required: true, message: '请选择评估方法', trigger: 'change' }
  1732. ],
  1733. definedEvaluationMethod: [
  1734. { required: true, message: '请填写其他评估方法', trigger: 'blur' }
  1735. ],
  1736. choiceEvaluationMethodId: [
  1737. { required: true, message: '请选择最终选择的评估方法', trigger: 'change' }
  1738. ],
  1739. choiceDefinedEvaluationMethod: [
  1740. { required: true, message: '请填写其他评估方法', trigger: 'blur' }
  1741. ],
  1742. totalAssetCarryingAmount: [
  1743. { required: true, message: '请填写总资产账面值', trigger: 'blur' }
  1744. ],
  1745. totalLiabilitiesCarryingAmount: [
  1746. { required: true, message: '请填写总负债账面值', trigger: 'blur' }
  1747. ],
  1748. carryingAmountOfNetAssets: [
  1749. { required: true, message: '请填写净资产账面值', trigger: 'blur' }
  1750. ],
  1751. estimatedValue: [
  1752. { required: true, message: '请填写评估结论对应的评估值', trigger: 'blur' }
  1753. ],
  1754. // filePath: [
  1755. // { required: true, message: '请上传附件资料', trigger: 'change' }
  1756. // ],
  1757. checkValue: [
  1758. { required: true, message: '请填写审核价格', trigger: 'blur' }
  1759. ]
  1760. },
  1761. // 款项信息
  1762. invoiceData: {
  1763. businessId: null,
  1764. shouldAmount: null,
  1765. realAmount: null,
  1766. leftAmount: null,
  1767. title: null,
  1768. type: null,
  1769. taxNo: null,
  1770. bankName: null,
  1771. bankAddress: null,
  1772. bankTel: null
  1773. },
  1774. // 节点任务提交dto
  1775. taskRecordDTO: {
  1776. recordId: null,
  1777. taskData: {}
  1778. },
  1779. pNode: null,
  1780. // 产品选择表单可视状态
  1781. productionChoiceDialogVisible: false,
  1782. // 产品信息撰写表单可视状态
  1783. productionWriteDialogVisible: false,
  1784. // 评估对象审核定价表单可视状态
  1785. checkValueDialogVisible: false,
  1786. // isCheckValue: false,
  1787. // 0:新增,1:更新
  1788. productionChoiceStatus: 0,
  1789. // 产品表单
  1790. assetsProductionForm: {
  1791. businessId: null,
  1792. productionNo: null,
  1793. productionType: null,
  1794. signatory: [],
  1795. clientName: null,
  1796. clientTel: null,
  1797. valuationBasisDate: null,
  1798. evaluateAcreage: null,
  1799. evaluatePrice: null,
  1800. evaluateAmount: null,
  1801. owner: null,
  1802. printCount: null,
  1803. createProductionDate: null,
  1804. comment: null,
  1805. filePath: [],
  1806. assetsName: null
  1807. },
  1808. // 产品选择表单校验规则
  1809. assetsProductionFormRules: {
  1810. productionType: [
  1811. { required: true, message: '请选择产品类型', trigger: 'change' }
  1812. ],
  1813. printCount: [
  1814. { required: true, message: '请填写打印份数', trigger: 'blur' },
  1815. { type: 'number', message: '请填写数字' }
  1816. ],
  1817. signatory: [
  1818. { required: true, message: '请选择签字人', trigger: 'change' },
  1819. { required: true, validator: checkSignatoryLength, trigger: 'change' }
  1820. ],
  1821. clientName: [
  1822. { required: true, message: '请填写委托方名称', trigger: 'blur' }
  1823. ],
  1824. // clientTel: [
  1825. // { required: true, message: '请填写委托方电话', trigger: 'blur' }
  1826. // ],
  1827. valuationBasisDate: [
  1828. { required: true, message: '请选择估价基准日', trigger: 'change' }
  1829. ],
  1830. // evaluateAcreage: [
  1831. // { required: true, message: '请填写评估面积', trigger: 'blur' }
  1832. // ],
  1833. // evaluatePrice: [
  1834. // { required: true, message: '请填写评估单价', trigger: 'blur' }
  1835. // ],
  1836. evaluateAmount: [
  1837. { required: true, message: '请填写评估总价', trigger: 'blur' }
  1838. ],
  1839. // owner: [
  1840. // { required: true, message: '请填写持有人', trigger: 'blur' }
  1841. // ],
  1842. createProductionDate: [
  1843. { required: true, message: '请选择产品出具日期', trigger: 'change' }
  1844. ],
  1845. filePath: [
  1846. { required: true, message: '请上传附件资料', trigger: 'change' }
  1847. ],
  1848. assetsName: [
  1849. { required: true, message: '请填写项目名称', trigger: 'change' }
  1850. ],
  1851. productionNo: [
  1852. { required: true, message: '请选择评估对象', trigger: 'change' }
  1853. ]
  1854. },
  1855. // 资产业务取号dto
  1856. takeAssetsProductionNoDTO: {
  1857. targetIdList: [],
  1858. businessId: null,
  1859. productionType: null,
  1860. hasNotTakeNumTargetSelect: null,
  1861. selectAll: null,
  1862. printCount: null,
  1863. statementNo: null
  1864. },
  1865. assetsProductionData: null,
  1866. commitProductionNo: null,
  1867. proInatanceCount: null,
  1868. // 产品撰写表单禁用状态
  1869. productionDisabledStatus: false,
  1870. // 产品表单编辑类型
  1871. writeType: null,
  1872. // 产品质检表单可视状态
  1873. productionCheckDialogVisible: false,
  1874. // 产品质检信息
  1875. productionPerformanceForm: {
  1876. id: null,
  1877. businessType: null,
  1878. productionId: null,
  1879. checkLoop: null,
  1880. fatalMistake: 0,
  1881. hardMistake: 0,
  1882. normalMistake: 0,
  1883. reason: null,
  1884. checkId: null
  1885. },
  1886. // 产品入库弹窗
  1887. warehouseDialog: false,
  1888. scanEntryData: null,
  1889. wareHouseProductionType: null,
  1890. wareHouseproductionId: null,
  1891. assetsAchievementRatioDialogVisible: false,
  1892. // 项目所有参与人信息
  1893. assetsBusinessMembers: [],
  1894. // 资产绩效比例表单
  1895. businessPerformanceDistributionForm: {
  1896. businessId: null,
  1897. businessType: null,
  1898. reportNo: null,
  1899. distributionList: [
  1900. // {
  1901. // memberId: null,
  1902. // performanceDistribution: null
  1903. // }
  1904. ]
  1905. },
  1906. showDistributionButton: null,
  1907. // 可以更新订单基本信息的节点
  1908. canUpdateOrderBaseInfoNode: [
  1909. 'DEPARTMENT_ALLOCATION', 'SPOT_RECONNAISSANCE_DETERMINE_PRICE', 'QUOTATION_FEEDBACK',
  1910. 'PRODUCT_CHOICE', 'GENERATE_STATEMENT', 'REVIEW_STATEMENT', 'REEXAMINE_STATEMENT',
  1911. 'WRITE_REPORT', 'CHECK_REPORT', 'RECHECK_REPORT', 'FOURTH_CHECK_REPORT'
  1912. ],
  1913. // 统计文件上传次数与文件数量是否符合,以免过早清空文件列表
  1914. fileCount: 0
  1915. }
  1916. },
  1917. created() {
  1918. // 获取页面参数
  1919. this.pageParams.back = this.$route.query.back;
  1920. this.pageParams.row = JSON.parse(this.$route.query.row);
  1921. this.getProductionTypes(this.pageParams.row.assetsId);
  1922. this.nodeBusinessInfo.doWorkflow = true;
  1923. this.nodeBusinessInfo.mainBusiness = 'ASSET_BUSINESS';
  1924. this.nodeBusinessInfo.businessId = this.pageParams.row.assetsId;
  1925. this.nodeBusinessInfo.businessSubId = this.pageParams.row.statementNo;
  1926. this.nodeBusinessInfo.businessMinId = this.pageParams.row.reportNo;
  1927. this.nodeBusinessInfo.reportNos.push(this.pageParams.row.statementNo);
  1928. this.disabledStatus = this.$route.query.disabledStatus === 'true';
  1929. this.couldEdit = this.$route.query.couldEdit === 'true';
  1930. this.couldBack = this.$route.query.couldBack === 'true';
  1931. if (this.$route.query.activeTabName !== null && this.$route.query.activeTabName !== undefined) {
  1932. this.activeTabName = this.$route.query.activeTabName;
  1933. }
  1934. this.byDepartmentName();
  1935. this.getCurrentNodeInfo();
  1936. this.getAllotDepartment();
  1937. this.getAssetsDetailById(this.pageParams.row.assetsId);
  1938. this.getAETargetListByAssetsId();
  1939. },
  1940. methods: {
  1941. // 根据业务id获取资产业务详情
  1942. getAssetsDetailById(id) {
  1943. this.$api.assets.getAssetsDetailById(id).then(res => {
  1944. if (res.code === 200) {
  1945. this.assetsForm = res.data;
  1946. this.assetsForm.members = JSON.parse(res.data.members);
  1947. this.initCustomerSelect(this.assetsForm.clienteleType);
  1948. this.getPrincipalByAllotDepartment();
  1949. this.getContactInfo();
  1950. // this.getAllUser();
  1951. }
  1952. })
  1953. },
  1954. handleChange() {
  1955. },
  1956. workflowCommitVerify(val, callback) {
  1957. let commit = val.commit;
  1958. let verify = new Object();
  1959. verify.state = true;
  1960. verify.cleanReport = false;
  1961. verify.nextHandlerId = this.secondCheckUserId;
  1962. if (commit.state === 'PASS') {
  1963. let nodeCode = this.currentNode.nodeCode;
  1964. switch (nodeCode) {
  1965. case 'GENERATE_STATEMENT':
  1966. let notTakeNumberTargets = this.assetsEvaluationTarget.filter(obj => !obj.productionNo).length;
  1967. if (notTakeNumberTargets.length > 0) {
  1968. this.$notify({
  1969. title: '提示',
  1970. message: '还有意见书号未取的估价对象,请先完成取号操作。',
  1971. type: 'error',
  1972. duration: 3000
  1973. });
  1974. verify.state = false;
  1975. callback(verify);
  1976. return;
  1977. }
  1978. if (typeof (commit.businessSubId) == 'undefined' || commit.businessSubId == null || commit.ifCheckTask == null) {
  1979. this.$notify({
  1980. title: '提示',
  1981. message: '未选择产品,请前往产品信息选择产品后进行提交。',
  1982. type: 'error',
  1983. duration: 3000
  1984. });
  1985. verify.state = false;
  1986. callback(verify);
  1987. return;
  1988. }
  1989. if (this.proInatanceCount > 0) {
  1990. this.$notify({
  1991. title: '提示',
  1992. message: '该产品已提交相应流程,不可重复提交。',
  1993. type: 'error',
  1994. duration: 3000
  1995. });
  1996. verify.state = false;
  1997. callback(verify);
  1998. return;
  1999. }
  2000. break;
  2001. case 'WRITE_REPORT':
  2002. let notTakeReportNoTargets = this.assetsEvaluationTarget.filter(function (e) {
  2003. return e.reportNo == null;
  2004. })
  2005. if (notTakeReportNoTargets.length > 0) {
  2006. this.$notify({
  2007. title: '提示',
  2008. message: '还有报告号未取的估价对象,请先完成取号操作。',
  2009. type: 'error',
  2010. duration: 3000
  2011. });
  2012. verify.state = false;
  2013. callback(verify);
  2014. return;
  2015. }
  2016. if (typeof (commit.businessMinId) == 'undefined' || commit.businessMinId == null || commit.ifCheckTask == null) {
  2017. this.$notify({
  2018. title: '提示',
  2019. message: '未选择产品,请前往产品信息选择产品后进行提交。',
  2020. type: 'error',
  2021. duration: 3000
  2022. });
  2023. verify.state = false;
  2024. callback(verify);
  2025. return;
  2026. }
  2027. if (this.proInatanceCount > 0) {
  2028. this.$notify({
  2029. title: '提示',
  2030. message: '该产品已提交相应流程,不可重复提交。',
  2031. type: 'error',
  2032. duration: 3000
  2033. });
  2034. verify.state = false;
  2035. callback(verify);
  2036. return;
  2037. }
  2038. break;
  2039. case 'ASSET_REPORT_TAKE_NO':
  2040. if (this.assetsEvaluationTarget.some(item => !item.reportNo)) {
  2041. this.$notify({
  2042. title: '提示',
  2043. message: '还有评估对象未取号,请先完成取号再提交。',
  2044. type: 'error',
  2045. duration: 3000
  2046. });
  2047. verify.state = false;
  2048. callback(verify);
  2049. return;
  2050. }
  2051. break;
  2052. // case 'RECHECK_REPORT':
  2053. // this.flowDoFourthCheck();
  2054. // break;
  2055. }
  2056. callback(verify);
  2057. }
  2058. },
  2059. goBack() {
  2060. const back = this.$route.query.back
  2061. if (back) {
  2062. this.$router.push(back)
  2063. }
  2064. },
  2065. handleClick(tab) {
  2066. },
  2067. // 改变客户类型时进行值重置的操作
  2068. changeCustomerType(val) {
  2069. // 清空联系人下拉列表
  2070. this.assetsForm.clienteleContactId = null;
  2071. this.assetsForm.clienteleSubId = null;
  2072. this.customerContract = [];
  2073. if (val === "企业") {
  2074. this.getCustomerCompany(0);
  2075. this.itemHideStatus = true;
  2076. } else {
  2077. this.getCustomerContract(1);
  2078. this.itemHideStatus = false;
  2079. }
  2080. },
  2081. initCustomerSelect(val) {
  2082. if (val === "企业") {
  2083. this.getCustomerCompany(0);
  2084. // this.getCustomerContract();
  2085. this.itemHideStatus = true;
  2086. } else {
  2087. // this.getCustomerContract(1);
  2088. this.itemHideStatus = false;
  2089. }
  2090. },
  2091. // 获取部门下拉列表
  2092. getAllotDepartment() {
  2093. this.$api.department.allot('ASSET_BUSINESS').then(res => {
  2094. if (res.code === 200) {
  2095. this.allotDepartment = res.data;
  2096. }
  2097. })
  2098. },
  2099. // 获取客户信息
  2100. getCustomerCompany(val) {
  2101. if (val === 0) {
  2102. let simpleAll = new Object();
  2103. simpleAll.terminal = val;
  2104. this.$api.customerCompany.simpleAll(simpleAll).then(res => {
  2105. if (res.code === 200) {
  2106. this.customerCompany = res.data;
  2107. this.findSubClientele(0);
  2108. }
  2109. })
  2110. } else {
  2111. let simpleAll = new Object();
  2112. simpleAll.terminal = val;
  2113. this.$api.customerCompany.simpleAll(simpleAll).then(res => {
  2114. if (res.code === 200) {
  2115. this.tCustomerCompany = res.data;
  2116. }
  2117. })
  2118. }
  2119. },
  2120. // 打开新建客户联系人弹窗
  2121. createLinkman(val) {
  2122. // 打开前判断是否已经选择客户信息
  2123. if (this.targetFassetsFormorm.clienteleType === "个人" || this.assetsForm.clienteleType != null && this.assetsForm.clienteleId != null && this.assetsForm.clienteleSubId != null) {
  2124. this.createLinkmanVisible = true;
  2125. this.linkmanForm.terminal = val;
  2126. this.linkmanForm.clienteleType = this.assetsForm.clienteleType;
  2127. this.linkmanForm.clienteleId = this.assetsForm.clienteleId;
  2128. this.linkmanForm.clienteleSubId = this.assetsForm.clienteleSubId;
  2129. if (this.assetsForm.clienteleType === '企业') {
  2130. this.linkmanForm.ccId = this.assetsForm.clienteleSubId
  2131. } else {
  2132. this.assetsForm.clienteleSubId = 1;
  2133. this.linkmanForm.ccId = this.assetsForm.clienteleSubId;
  2134. }
  2135. } else {
  2136. this.$notify({
  2137. title: '警告',
  2138. message: '请先选择客户!',
  2139. type: 'warning',
  2140. duration: 2000
  2141. });
  2142. }
  2143. },
  2144. // 获取客户联系人列表
  2145. getCustomerContract(val) {
  2146. // if (this.assetsForm.clienteleSubId) {
  2147. let simpleAll = new Object();
  2148. simpleAll.terminal = 0;
  2149. if (val === 1) {
  2150. simpleAll.ccId = val;
  2151. } else {
  2152. simpleAll.ccId = this.assetsForm.clienteleSubId;
  2153. }
  2154. this.$api.customerLinkman.simpleAll(simpleAll).then(res => {
  2155. if (res.code === 200) {
  2156. this.customerContract = res.data;
  2157. }
  2158. })
  2159. // }
  2160. },
  2161. // 获取二级客户信息(业务来源)
  2162. findSubClientele(val) {
  2163. if (val === 0) {
  2164. if (this.assetsForm.clienteleId) {
  2165. let simpleAll = new Object();
  2166. simpleAll.terminal = val;
  2167. simpleAll.parentId = this.assetsForm.clienteleId;
  2168. this.$api.customerCompany.simpleAll(simpleAll).then(res => {
  2169. if (res.code === 200) {
  2170. this.subCustomerCompany = res.data;
  2171. }
  2172. })
  2173. }
  2174. } else {
  2175. if (this.assetsForm.terminalClienteleId) {
  2176. let simpleAll = new Object();
  2177. simpleAll.terminal = val;
  2178. simpleAll.ccId = this.assetsForm.terminalClienteleId;
  2179. this.$api.customerCompany.detail(this.assetsForm.terminalClienteleId).then(res => {
  2180. if (res.code === 200) {
  2181. this.assetsForm.tmobile = res.data.phone;
  2182. }
  2183. })
  2184. }
  2185. }
  2186. },
  2187. // 打开新增终端客户弹窗
  2188. createTerminalClient() {
  2189. this.createTerminalClientVisible = true;
  2190. },
  2191. // 根据部门id获取项目负责人列表
  2192. getPrincipalByAllotDepartment() {
  2193. let departmentId = this.assetsForm.departmentId;
  2194. if (departmentId) {
  2195. this.$api.user.usersByDepartmentId(departmentId).then(res => {
  2196. if (res.code === 200) {
  2197. this.principals = res.data;
  2198. }
  2199. })
  2200. }
  2201. },
  2202. // 获取用户下拉列表
  2203. getAllUser() {
  2204. this.$api.user.simpleAll().then(res => {
  2205. if (res.code === 200) {
  2206. let principals = this.principals;
  2207. let all = res.data;
  2208. let arr = principals.concat(all);
  2209. let obj = {}
  2210. arr = arr.reduce((pre, next) => {
  2211. obj[next.id] ? null : (obj[next.id] = true && pre.push(next))
  2212. return pre;
  2213. }, [])
  2214. this.allUsers = arr;
  2215. }
  2216. })
  2217. },
  2218. // 获取资产评估师用户
  2219. byAssetEvaluator() {
  2220. this.$api.user.byAssetEvaluator().then(res => {
  2221. if (res.code === 200) {
  2222. this.assetEvaluator = res.data;
  2223. }
  2224. })
  2225. },
  2226. // 根据部门名称获取部门及其下辖部门人员
  2227. byDepartmentName() {
  2228. this.$api.user.byDepartmentName("资产评估事业部").then(res => {
  2229. if (res.code === 200) {
  2230. this.depUsers = res.data;
  2231. }
  2232. })
  2233. },
  2234. // 获取流程节点信息
  2235. getCurrentNodeInfo() {
  2236. if (this.pageParams.row.assetsId) {
  2237. this.$api.workNodeInstance.currentNode({ "mainBusiness": "ASSET_BUSINESS", "businessId": this.pageParams.row.assetsId, "businessSubId": this.pageParams.row.statementNo, "businessMinId": this.pageParams.row.reportNo }).then(res => {
  2238. if (res.code === 200) {
  2239. if (res.data) {
  2240. this.currentNode = res.data;
  2241. this.nodeBusinessInfo.currentInstanceNodeId = res.data.instanceId;
  2242. this.nodeBusinessInfo.currentNodeInstanceCode = res.data.nodeCode;
  2243. this.nodeBusinessInfo.currentNodePermission.restartable = res.data.restartable;
  2244. this.nodeBusinessInfo.currentNodePermission.reversible = res.data.reversible;
  2245. this.nodeBusinessInfo.currentNodePermission.skippable = res.data.skippable;
  2246. this.nodeBusinessInfo.currentNodePermission.terminable = res.data.terminable;
  2247. // this.nodeBusinessInfo.businessId = this.pageParams.row.assetsId;
  2248. if (this.currentNode.nodeCode === 'REPORT_IN') {
  2249. this.getProductionRealAmount(this.pageParams.row.reportNo);
  2250. }
  2251. }
  2252. }
  2253. })
  2254. }
  2255. },
  2256. // 修改项目负责人与项目成员信息
  2257. updatePrincipalAndMembers() {
  2258. let assetsPrincipalMembers = new Object();
  2259. assetsPrincipalMembers.id = this.assetsForm.id;
  2260. assetsPrincipalMembers.principalId = this.assetsForm.principalId;
  2261. assetsPrincipalMembers.departmentId = this.assetsForm.departmentId;
  2262. assetsPrincipalMembers.members = JSON.stringify(this.assetsForm.members);
  2263. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  2264. this.taskRecordDTO.taskData = assetsPrincipalMembers;
  2265. if (assetsPrincipalMembers.id && assetsPrincipalMembers.principalId && assetsPrincipalMembers.departmentId && this.assetsForm.members.length > 0) {
  2266. this.$api.assets.updatePrincipalAndMembers(this.taskRecordDTO).then(res => {
  2267. if (res.code === 200 && res.data) {
  2268. this.$notify({
  2269. title: '成功',
  2270. message: '保存成功,请提交节点继续流程。',
  2271. type: 'success',
  2272. duration: 2000
  2273. });
  2274. }
  2275. })
  2276. } else {
  2277. this.$notify({
  2278. title: '警告',
  2279. message: '请先完善项目负责人与项目成员信息!',
  2280. type: 'error',
  2281. duration: 2000
  2282. });
  2283. }
  2284. },
  2285. // 根据节点返回不同的操作按钮信息
  2286. hanlderType() {
  2287. if (this.currentNode) {
  2288. if (this.currentNode.nodeCode === 'SPOT_RECONNAISSANCE') {
  2289. return "编辑";
  2290. }
  2291. if (this.currentNode.nodeCode === 'INITIAL_PRICE') {
  2292. return "定价";
  2293. }
  2294. if (this.currentNode.nodeCode === 'REVIEW_QUOTATION') {
  2295. return "审核定价";
  2296. }
  2297. return "查看";
  2298. }
  2299. },
  2300. // 根据资产业务id获取资产业务评估对象集合
  2301. getAETargetListByAssetsId(productionNo) {
  2302. let aETargetListSelectDTO = new Object();
  2303. aETargetListSelectDTO.businessId = this.pageParams.row.assetsId;
  2304. // if (productionNo != null || productionNo != undefined || productionNo != '') {
  2305. // aETargetListSelectDTO.statementNo = productionNo;
  2306. // aETargetListSelectDTO.reportNo = productionNo;
  2307. // } else {
  2308. aETargetListSelectDTO.statementNo = this.pageParams.row.statementNo;
  2309. aETargetListSelectDTO.reportNo = this.pageParams.row.reportNo;
  2310. // }
  2311. this.$api.assets.getAETargetListByAssetsId(aETargetListSelectDTO).then(res => {
  2312. if (res.code === 200 && res.data !== null) {
  2313. this.assetsEvaluationTarget = res.data;
  2314. this.writeProductionStatementNos = this.assetsEvaluationTarget
  2315. // 过滤
  2316. .filter(obj => (!obj.statementCreateProductionDate && obj.statementNo))
  2317. // 获取
  2318. .map(obj => obj.statementNo)
  2319. // 去重
  2320. .filter((value, index, self) => self.indexOf(value) === index);
  2321. this.writeProductionReportNos = this.assetsEvaluationTarget
  2322. // 过滤
  2323. .filter(obj => (!obj.reportCreateProductionDate && obj.reportNo))
  2324. // 获取
  2325. .map(obj => obj.reportNo)
  2326. // 去重
  2327. .filter((value, index, self) => self.indexOf(value) === index);
  2328. // 获取资产产品列表
  2329. this.getProductionList();
  2330. // 计算所有评估对象评估总价
  2331. this.totalEvaluateValue = this.assetsEvaluationTarget.reduce((sum, target) => sum + target.estimatedValue, 0);
  2332. // 获取评估对象信息后查询产品选择信息
  2333. this.getChoiceLog();
  2334. }
  2335. })
  2336. },
  2337. // 获取所有资产评估目的集合
  2338. getPurpose() {
  2339. this.$api.assets.getPurpose().then(res => {
  2340. if (res.code === 200) {
  2341. this.assetsEvaluationTargetPurpose = res.data;
  2342. }
  2343. })
  2344. },
  2345. // 获取所有评估方法集合
  2346. getAssetsEvaluationMethod() {
  2347. this.$api.assets.getAssetsEvaluationMethod().then(res => {
  2348. if (res.code === 200) {
  2349. this.assetsEvaluationMethod = res.data;
  2350. }
  2351. })
  2352. },
  2353. // 获取所有资产价值类型
  2354. getAssetsValueType() {
  2355. this.$api.assets.getAssetsValueType().then(res => {
  2356. if (res.code === 200) {
  2357. this.assetsValueType = res.data;
  2358. }
  2359. })
  2360. },
  2361. // 根据父级id获取资产评估对象类型(id可为空)
  2362. getTypeList(val, level) {
  2363. let parentId = val;
  2364. // 每次进入方法清空二级下拉选择
  2365. // this.targetForm.evaluationTypeSecId = null;
  2366. this.assetsSecEvaluationTargetType = [];
  2367. this.$api.assets.getTypeList(parentId).then(res => {
  2368. if (res.code === 200) {
  2369. if (level == 1) {
  2370. // 等级为1赋值给assetsEvaluationTargetType
  2371. this.assetsEvaluationTargetType = res.data;
  2372. } else {
  2373. // 其他赋值给assetsEvaluationTargetType
  2374. this.assetsSecEvaluationTargetType = res.data;
  2375. }
  2376. }
  2377. })
  2378. },
  2379. // 打开新增评估对象弹窗表单
  2380. openTargetDialog() {
  2381. // 可视状态为true
  2382. this.targetDialogVisible = true;
  2383. // 初始表单所需信息
  2384. this.targetForm.principalId = this.assetsForm.principalId;
  2385. if (!this.targetForm.siteIds || !this.targetForm.siteIds.length > 0) {
  2386. this.targetForm.siteIds = this.assetsForm.members;
  2387. }
  2388. if (this.assetsEvaluationTargetPurpose.length == 0 || this.assetsEvaluationMethod.length == 0 || this.assetsValueType.length == 0 || this.assetsEvaluationTargetType.length == 0) {
  2389. this.getPurpose();
  2390. this.getAssetsEvaluationMethod();
  2391. this.getAssetsValueType();
  2392. this.getTypeList(0, 1);
  2393. }
  2394. },
  2395. // 文件选择改变触发事件
  2396. changeresTarget(res, file, fileList) {
  2397. // 上传成功向表单附件信息数组添加信息
  2398. if (res.code === 200) {
  2399. this.targetForm.filePath.push({ name: file.name, url: res.data.url });
  2400. } else {
  2401. this.$notify({
  2402. title: '错误',
  2403. message: '电子文档上传失败',
  2404. type: 'error',
  2405. duration: 2000
  2406. });
  2407. }
  2408. },
  2409. changeresProduction(res, file, fileList) {
  2410. // 上传成功向表单附件信息数组添加信息
  2411. if (res.code === 200) {
  2412. this.assetsProductionForm.filePath.push({ name: file.name, url: res.data.url });
  2413. } else {
  2414. this.$notify({
  2415. title: '错误',
  2416. message: '电子文档上传失败',
  2417. type: 'error',
  2418. duration: 2000
  2419. });
  2420. }
  2421. },
  2422. // 文件上传数量限制
  2423. handleExceed() {
  2424. this.$message.warning(`当前限制选择10个文件!`);
  2425. },
  2426. handleAttachmentPreview(file) {
  2427. // window.open(file.url)
  2428. this.officeFileView(file.name, file.url);
  2429. },
  2430. // 移除文件
  2431. beforeRemove(file, fileList) {
  2432. fileList = fileList.filter((o) => {
  2433. return o.name !== file.name
  2434. });
  2435. this.targetForm.filePath = this.targetForm.filePath.filter((o) => {
  2436. return o.name !== file.name
  2437. });
  2438. },
  2439. // 移除文件
  2440. beforeRemovePro(file, fileList) {
  2441. fileList = fileList.filter((o) => {
  2442. return o.name !== file.name
  2443. });
  2444. this.assetsProductionForm.filePath = this.assetsProductionForm.filePath.filter((o) => {
  2445. return o.name !== file.name
  2446. });
  2447. },
  2448. resettargetForm() {
  2449. this.targetForm = {
  2450. id: null,
  2451. evaluationPurposeId: null,
  2452. evaluationTypeId: null,
  2453. evaluationTypeSecId: null,
  2454. theHolder: null,
  2455. assetsValueId: null,
  2456. principalId: null,
  2457. siteIds: [],
  2458. valuationBasisDate: null,
  2459. evaluationMethodId: [],
  2460. choiceEvaluationMethodId: [],
  2461. totalAssetCarryingAmount: null,
  2462. totalLiabilitiesCarryingAmount: null,
  2463. carryingAmountOfNetAssets: null,
  2464. estimatedValue: null,
  2465. checkValue: null,
  2466. filePath: [],
  2467. assetsId: null,
  2468. definedEvaluationMethod: null,
  2469. choiceDefinedEvaluationMethod: null
  2470. }
  2471. this.fileList = [];
  2472. },
  2473. clear() {
  2474. if (this.$refs.targetForm !== undefined) {
  2475. this.$refs.targetForm.clearValidate();
  2476. }
  2477. },
  2478. // 保存新增资产业务评估对象
  2479. assetsTargetSave() {
  2480. this.$refs.targetForm.validate(valid => {
  2481. if (valid) {
  2482. this.targetForm.assetsId = this.assetsForm.id;
  2483. this.targetForm.siteIds = JSON.stringify(this.targetForm.siteIds);
  2484. this.targetForm.evaluationMethodId = JSON.stringify(this.targetForm.evaluationMethodId);
  2485. this.targetForm.choiceEvaluationMethodId = JSON.stringify(this.targetForm.choiceEvaluationMethodId);
  2486. this.targetForm.filePath = JSON.stringify(this.targetForm.filePath);
  2487. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  2488. this.taskRecordDTO.taskData = this.targetForm;
  2489. this.$api.assets.assetsTargetSave(this.taskRecordDTO).then(res => {
  2490. if (res.code === 200) {
  2491. this.$notify({
  2492. title: '成功',
  2493. message: '添加资产业务评估对象成功,可继续添加或提交节点',
  2494. type: 'success',
  2495. duration: 2000
  2496. });
  2497. this.targetDialogVisible = false;
  2498. //获取评估对象列表
  2499. this.getAETargetListByAssetsId();
  2500. }
  2501. })
  2502. }
  2503. })
  2504. },
  2505. // 根据id获取资产评估对象详情
  2506. getAssetsTargetDetail(id) {
  2507. this.$api.assets.getAssetsTargetDetail(id).then(res => {
  2508. if (res.code === 200) {
  2509. this.targetForm = res.data;
  2510. this.targetForm.siteIds = JSON.parse(res.data.siteIds);
  2511. this.targetForm.evaluationMethodId = JSON.parse(res.data.evaluationMethodId);
  2512. this.targetForm.choiceEvaluationMethodId = JSON.parse(res.data.choiceEvaluationMethodId);
  2513. this.targetForm.filePath = JSON.parse(res.data.filePath);
  2514. this.fileList = JSON.parse(JSON.stringify(this.targetForm.filePath));
  2515. this.getTypeList(this.targetForm.evaluationTypeId, 2);
  2516. this.openTargetDialog();
  2517. }
  2518. })
  2519. },
  2520. // 更新资产评估对象
  2521. assetsTargetUpdate() {
  2522. this.$refs.targetForm.validate(valid => {
  2523. if (valid) {
  2524. this.targetForm.assetsId = this.assetsForm.id;
  2525. this.targetForm.siteIds = JSON.stringify(this.targetForm.siteIds);
  2526. this.targetForm.evaluationMethodId = JSON.stringify(this.targetForm.evaluationMethodId);
  2527. this.targetForm.choiceEvaluationMethodId = JSON.stringify(this.targetForm.choiceEvaluationMethodId);
  2528. this.targetForm.filePath = JSON.stringify(this.targetForm.filePath);
  2529. this.$api.assets.assetsTargetUpdate(this.targetForm).then(res => {
  2530. if (res.code === 200) {
  2531. this.$notify({
  2532. title: '成功',
  2533. message: '更新资产业务评估对象成功!',
  2534. type: 'success',
  2535. duration: 2000
  2536. });
  2537. this.targetDialogVisible = false;
  2538. //获取评估对象列表
  2539. this.getAETargetListByAssetsId();
  2540. }
  2541. })
  2542. }
  2543. })
  2544. },
  2545. // 删除资产评估对象
  2546. assetsTargetDelete(id) {
  2547. this.$confirm('确认删除该评估对象?', '提示', {
  2548. confirmButtonText: '确定',
  2549. cancelButtonText: '取消',
  2550. type: 'warning'
  2551. }).then(() => {
  2552. this.$api.assets.assetsTargetDelete(id).then(res => {
  2553. if (res.code === 200) {
  2554. this.$notify({
  2555. title: '成功',
  2556. message: '删除资产业务评估对象成功!',
  2557. type: 'success',
  2558. duration: 2000
  2559. });
  2560. this.getAETargetListByAssetsId();
  2561. }
  2562. })
  2563. }).catch(() => {
  2564. this.$message({
  2565. type: 'info',
  2566. message: '已取消删除'
  2567. });
  2568. });
  2569. },
  2570. // 根据不同情况打开的评估对象表单可编辑状态不同
  2571. changeStatus(val) {
  2572. if (val == "edit") {
  2573. this.targetDisabledStatus = false;
  2574. this.updateButtonStatus = true;
  2575. this.saveButtonStatus = false;
  2576. } else if (val == "add") {
  2577. this.targetDisabledStatus = false;
  2578. this.saveButtonStatus = true;
  2579. this.updateButtonStatus = false;
  2580. } else if (val == "detail") {
  2581. this.targetDisabledStatus = true;
  2582. this.saveButtonStatus = false;
  2583. this.updateButtonStatus = false;
  2584. }
  2585. },
  2586. // 根据业务id获取资产业务款项信息
  2587. getOrderFundInvoiceById() {
  2588. this.$api.assets.getOrderFundInvoiceById(this.assetsForm.id).then(res => {
  2589. if (res.code === 200) {
  2590. // if (res.data != null) {
  2591. this.invoiceData = res.data;
  2592. this.invoiceData.leftAmount = this.invoiceData.shouldAmount - this.invoiceData.realAmount;
  2593. // }
  2594. }
  2595. })
  2596. },
  2597. // 获取产品信息类型
  2598. getProductionTypes(id) {
  2599. this.$api.assets.getProductionTypes(id).then(res => {
  2600. if (res.code === 200) {
  2601. this.nodeBusinessInfo.production = res.data;
  2602. this.$refs.board.getInstanceQueue();
  2603. }
  2604. })
  2605. },
  2606. // 提交节点
  2607. commit(state) {
  2608. this.flowDoFourthCheck();
  2609. this.$refs.board.commit(state);
  2610. },
  2611. getPreviousNode(pNode) {
  2612. this.pNode = pNode;
  2613. },
  2614. // 打开产品选择表单弹窗
  2615. openProductionDialog() {
  2616. this.productionChoiceDialogVisible = true;
  2617. // this.getProductionByBusinessId(this.pageParams.row.assetsId);
  2618. this.getChoiceLog();
  2619. },
  2620. // 获取产品选择记录
  2621. getChoiceLog() {
  2622. let selectDTO = {};
  2623. selectDTO.businessType = 'ASSET_BUSINESS';
  2624. selectDTO.businessId = this.pageParams.row.assetsId;
  2625. for (let i = 0; i < this.assetsEvaluationTarget.length; i++) {
  2626. if (this.assetsEvaluationTarget[i].reportNo === null) {
  2627. selectDTO.targetId = this.assetsEvaluationTarget[i].id;
  2628. break; // 找到第一个 reportNo 为 null 的元素后退出循环
  2629. }
  2630. // 如果 reportNo 不为 null,继续检查下一个元素
  2631. }
  2632. this.$api.businessProductionChoiceLog.getChoiceLog(selectDTO).then(res => {
  2633. if (res.code == 200 && res.data !== null) {
  2634. this.productionChoiceStatus = 1;
  2635. this.assetsProductionForm.id = res.data.productionId;
  2636. this.assetsProductionForm.productionType = res.data.productionType;
  2637. this.assetsProductionForm.printCount = res.data.printCount;
  2638. }
  2639. })
  2640. },
  2641. // 根据业务id获取是否已选择产品
  2642. // getProductionByBusinessId(id) {
  2643. // this.$api.assets.getProductionByBusinessId(id).then(res => {
  2644. // if (res.code === 200) {
  2645. // // 产品信息不为null,则证明已经选择过产品,将按钮改为修改
  2646. // if (res.data !== null) {
  2647. // if (res.data.productionType == 'STATEMENT' && (this.currentNode.nodeCode === 'PRODUCT_CHOICE' || this.currentNode.nodeCode === 'GENERATE_STATEMENT')) {
  2648. // this.assetsProductionForm = res.data;
  2649. // this.productionChoiceStatus = 1;
  2650. // }
  2651. // if (res.data.productionType !== 'STATEMENT' && (this.currentNode.nodeCode === 'REPORT_CHOICE' || this.currentNode.nodeCode === 'ASSET_REPORT_TAKE_NO')) {
  2652. // this.assetsProductionForm = res.data;
  2653. // this.productionChoiceStatus = 1;
  2654. // }
  2655. // }
  2656. // }
  2657. // })
  2658. // },
  2659. // 选择产品,新增产品信息
  2660. assetsProductionSave() {
  2661. this.$refs.assetsProductionForm.validate(valid => {
  2662. if (valid) {
  2663. this.assetsProductionForm.businessId = this.assetsForm.id;
  2664. // if (this.assetsProductionForm.productionType == 1) {
  2665. // // 价值意见书
  2666. // this.assetsProductionForm.productionType = 'STATEMENT';
  2667. // } else if (this.assetsProductionForm.productionType == 4) {
  2668. // // 意见函
  2669. // this.assetsProductionForm.productionType = 'LETTER';
  2670. // } else if (this.assetsProductionForm.productionType == 2) {
  2671. // // 咨询报告
  2672. // this.assetsProductionForm.productionType = 'CONSULT';
  2673. // } else {
  2674. // // 评估报告
  2675. // this.assetsProductionForm.productionType = 'REPORT';
  2676. // }
  2677. this.assetsProductionForm.filePath = JSON.stringify(this.assetsProductionForm.filePath);
  2678. this.assetsProductionForm.signatory = JSON.stringify(this.assetsProductionForm.signatory);
  2679. this.assetsProductionForm.targetIdList = this.assetsEvaluationTarget.map(item => item.id);
  2680. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  2681. this.taskRecordDTO.taskData = this.assetsProductionForm;
  2682. this.$api.assets.assetsProductionSave(this.taskRecordDTO).then(res => {
  2683. if (res.code === 200) {
  2684. this.$notify({
  2685. title: '成功',
  2686. message: '选择产品成功!请继续提交流程节点!',
  2687. type: 'success',
  2688. duration: 2000
  2689. });
  2690. this.getProductionTypes(this.assetsForm.id);
  2691. this.productionChoiceDialogVisible = false;
  2692. this.$refs.assetsProductionForm.resetFields();
  2693. }
  2694. })
  2695. }
  2696. })
  2697. },
  2698. // 选择产品,更新已选择产品信息
  2699. assetsProductionUpdateChoice() {
  2700. this.$refs.assetsProductionForm.validate(valid => {
  2701. if (valid) {
  2702. this.assetsProductionForm.businessId = this.assetsForm.id;
  2703. // if (this.assetsProductionForm.productionType == 1) {
  2704. // // 价值意见书
  2705. // this.assetsProductionForm.productionType = 'STATEMENT';
  2706. // } else if (this.assetsProductionForm.productionType == 4) {
  2707. // // 意见函
  2708. // this.assetsProductionForm.productionType = 'LETTER';
  2709. // } else {
  2710. // // 报告
  2711. // this.assetsProductionForm.productionType = 'REPORT';
  2712. // }
  2713. this.assetsProductionForm.filePath = JSON.stringify(this.assetsProductionForm.filePath);
  2714. this.assetsProductionForm.signatory = JSON.stringify(this.assetsProductionForm.signatory);
  2715. this.assetsProductionForm.targetIdList = this.assetsEvaluationTarget.map(item => item.id);
  2716. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  2717. this.taskRecordDTO.taskData = this.assetsProductionForm;
  2718. this.$api.assets.assetsProductionUpdateChoice(this.taskRecordDTO).then(res => {
  2719. if (res.code === 200) {
  2720. this.$notify({
  2721. title: '成功',
  2722. message: '选择产品成功!请继续提交流程节点!',
  2723. type: 'success',
  2724. duration: 2000
  2725. });
  2726. this.getProductionTypes(this.assetsForm.id);
  2727. this.productionChoiceDialogVisible = false;
  2728. this.$refs.assetsProductionForm.resetFields();
  2729. }
  2730. })
  2731. }
  2732. })
  2733. },
  2734. // 资产产品意见书取号
  2735. takeAssetsStatementProductionNo() {
  2736. this.takeAssetsProductionNoDTO.allTargetIdList = this.assetsEvaluationTarget.map(item => item.id);
  2737. // 提交的要取号数组长度与table长度一致则是全部取号
  2738. // if (this.takeAssetsProductionNoDTO.targetIdList.length === this.assetsEvaluationTarget.length) {
  2739. // this.takeAssetsProductionNoDTO.selectAll = true;
  2740. // } else {
  2741. // this.takeAssetsProductionNoDTO.selectAll = false;
  2742. // }
  2743. // 判断表格中是否还有未选择且未取号的评估对象,返回布尔
  2744. let notTakeNumTargetSelect = this.assetsEvaluationTarget.filter(item => !this.takeAssetsProductionNoDTO.targetIdList.includes(item.id));
  2745. this.takeAssetsProductionNoDTO.hasNotTakeNumTargetSelect = notTakeNumTargetSelect.some(target => target.statementNo === null || target.statementNo === '');
  2746. this.takeAssetsProductionNoDTO.businessId = this.assetsForm.id;
  2747. // this.getProductionByBusinessId(this.assetsForm.id);
  2748. // this.takeAssetsProductionNoDTO.productionType = this.assetsProductionForm.productionType;
  2749. // this.takeAssetsProductionNoDTO.productionType = this.nodeBusinessInfo.production[this.nodeBusinessInfo.production.length - 1];
  2750. // this.takeAssetsProductionNoDTO.printCount = this.assetsProductionForm.printCount;
  2751. if (!this.takeAssetsProductionNoDTO.targetIdList.length == 0) {
  2752. this.$api.assets.takeAssetsStatementProductionNo(this.takeAssetsProductionNoDTO).then(res => {
  2753. if (res.code === 200 && res.data) {
  2754. this.$notify({
  2755. title: '成功',
  2756. message: '产品取号成功!',
  2757. type: 'success',
  2758. duration: 2000
  2759. });
  2760. // this.pageParams.row.productionNo = res.data;
  2761. this.getAETargetListByAssetsId();
  2762. }
  2763. })
  2764. } else {
  2765. this.$notify({
  2766. title: '警告',
  2767. message: '您必须选择至少一个评估对象!',
  2768. type: 'warning',
  2769. duration: 2000
  2770. });
  2771. }
  2772. },
  2773. // 资产产品报告取号
  2774. takeAssetsReportProductionNo() {
  2775. this.takeAssetsProductionNoDTO.allTargetIdList = this.assetsEvaluationTarget.map(item => item.id);
  2776. this.takeAssetsProductionNoDTO.statementNo = this.assetsEvaluationTarget[0].statementNo;
  2777. // 提交的要取号数组长度与table长度一致则是全部取号
  2778. // if (this.takeAssetsProductionNoDTO.targetIdList.length === this.assetsEvaluationTarget.length) {
  2779. // this.takeAssetsProductionNoDTO.selectAll = true;
  2780. // } else {
  2781. // this.takeAssetsProductionNoDTO.selectAll = false;
  2782. // }
  2783. // 判断表格中是否还有未选择且未取号的评估对象,返回布尔
  2784. let notTakeNumTargetSelect = this.assetsEvaluationTarget.filter(item => !this.takeAssetsProductionNoDTO.targetIdList.includes(item.id));
  2785. this.takeAssetsProductionNoDTO.hasNotTakeNumTargetSelect = notTakeNumTargetSelect.some(target => target.reportNo === null || target.reportNo === '');
  2786. this.takeAssetsProductionNoDTO.businessId = this.assetsForm.id;
  2787. // this.getProductionByBusinessId(this.assetsForm.id);
  2788. // this.takeAssetsProductionNoDTO.productionType = this.assetsProductionForm.productionType;
  2789. // this.takeAssetsProductionNoDTO.productionType = this.nodeBusinessInfo.production[this.nodeBusinessInfo.production.length - 1];
  2790. // this.takeAssetsProductionNoDTO.printCount = this.assetsProductionForm.printCount;
  2791. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  2792. this.taskRecordDTO.taskData = this.takeAssetsProductionNoDTO;
  2793. if (!this.takeAssetsProductionNoDTO.targetIdList.length == 0) {
  2794. this.$api.assets.takeAssetsReportProductionNo(this.taskRecordDTO).then(res => {
  2795. if (res.code === 200 && res.data) {
  2796. this.$notify({
  2797. title: '成功',
  2798. message: '产品取号成功!',
  2799. type: 'success',
  2800. duration: 2000
  2801. });
  2802. // this.pageParams.row.productionNo = res.data;
  2803. this.getAETargetListByAssetsId();
  2804. }
  2805. })
  2806. } else {
  2807. this.$notify({
  2808. title: '警告',
  2809. message: '您必须选择至少一个评估对象!',
  2810. type: 'warning',
  2811. duration: 2000
  2812. });
  2813. }
  2814. },
  2815. // 资产评估对象选取数据处理
  2816. targetSelectionChange(val) {
  2817. this.takeAssetsProductionNoDTO.targetIdList = val;
  2818. this.takeAssetsProductionNoDTO.targetIdList = this.takeAssetsProductionNoDTO.targetIdList.map(selection => selection.id);
  2819. },
  2820. // 判断行数据是否可选
  2821. selectable(row) {
  2822. if (row.statementNo != null && row.statementNo != '' && this.currentNode.nodeCode !== 'ASSET_REPORT_TAKE_NO') {
  2823. return false;
  2824. } else if (row.reportNo != null && row.reportNo != '' && this.currentNode.nodeCode !== 'GENERATE_STATEMENT') {
  2825. return false;
  2826. } else {
  2827. return true;
  2828. }
  2829. },
  2830. openWriteProductionDialog(status, type) {
  2831. this.productionWriteDialogVisible = true;
  2832. this.productionDisabledStatus = status;
  2833. this.writeType = type;
  2834. },
  2835. // 根据业务id与产品号获取资产产品信息并初始化表单
  2836. getAssetsProductionDetailByNo() {
  2837. let assetsProductionDetailDTO = new Object();
  2838. assetsProductionDetailDTO.businessId = this.assetsForm.id;
  2839. assetsProductionDetailDTO.productionNo = this.assetsProductionForm.productionNo;
  2840. this.$api.assets.getAssetsProductionDetailByNo(assetsProductionDetailDTO).then(res => {
  2841. if (res.code == 200 && res.data !== null) {
  2842. this.assetsProductionForm.productionType = res.data.productionType
  2843. this.assetsProductionForm.printCount = res.data.printCount;
  2844. this.assetsProductionForm.clientName = this.assetsForm.bailorContactName;
  2845. this.assetsProductionForm.clientTel = this.assetsForm.bailorContactTel;
  2846. this.assetsProductionForm.assetsName = this.assetsForm.name;
  2847. this.assetsProductionForm.owner = this.assetsEvaluationTarget.find(obj => obj.productionNo === assetsProductionDetailDTO.productionNo)?.theHolder;
  2848. this.assetsProductionForm.valuationBasisDate = this.assetsEvaluationTarget[0].valuationBasisDate;
  2849. this.assetsProductionForm.filePath = [];
  2850. this.assetsProductionForm.signatory = [];
  2851. }
  2852. })
  2853. },
  2854. // 当产品单价或面积改变时触发
  2855. computeAmount() {
  2856. this.assetsProductionForm.evaluateAmount = (this.assetsProductionForm.evaluatePrice * this.assetsProductionForm.evaluateAcreage) / 10000;
  2857. },
  2858. // 资产撰写产品(意见书和报告都是这个接口)
  2859. writeAssetsProduction() {
  2860. this.$refs.assetsProductionForm.validate(valid => {
  2861. if (valid) {
  2862. this.assetsProductionForm.filePath = JSON.stringify(this.assetsProductionForm.filePath);
  2863. if (this.assetsProductionForm.signatory !== null) {
  2864. this.assetsProductionForm.signatory = JSON.stringify(this.assetsProductionForm.signatory);
  2865. } else {
  2866. this.assetsProductionForm.signatory = null;
  2867. }
  2868. this.assetsProductionForm.businessId = this.assetsForm.id;
  2869. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  2870. this.taskRecordDTO.taskData = this.assetsProductionForm;
  2871. this.$api.assets.writeAssetsProduction(this.taskRecordDTO).then(res => {
  2872. if (res.code == 200) {
  2873. this.$notify({
  2874. title: '成功',
  2875. message: '产品撰写成功!请继续提交流程节点!',
  2876. type: 'success',
  2877. duration: 2000
  2878. });
  2879. }
  2880. this.getAETargetListByAssetsId(this.assetsProductionForm.productionNo);
  2881. this.productionWriteDialogVisible = false;
  2882. this.getProductionList();
  2883. this.writeProductionReportNos = [];
  2884. this.writeProductionStatementNos = [];
  2885. })
  2886. }
  2887. })
  2888. },
  2889. resetProductionForm() {
  2890. this.assetsProductionForm = {
  2891. businessId: null,
  2892. productionNo: null,
  2893. productionType: null,
  2894. signatory: [],
  2895. clientName: null,
  2896. clientTel: null,
  2897. valuationBasisDate: null,
  2898. evaluateAcreage: null,
  2899. evaluatePrice: null,
  2900. evaluateAmount: null,
  2901. owner: null,
  2902. printCount: null,
  2903. createProductionDate: null,
  2904. comment: null,
  2905. filePath: [],
  2906. assetsName: null
  2907. }
  2908. this.fileList = [];
  2909. },
  2910. clearassetsProductionFormValidate() {
  2911. if (this.$refs.assetsProductionForm !== undefined) {
  2912. this.$refs.assetsProductionForm.clearValidate();
  2913. }
  2914. },
  2915. // 根据业务id与产品号查询产品信息
  2916. getProductionList() {
  2917. let aProListSelectDTO = new Object();
  2918. aProListSelectDTO.businessId = this.pageParams.row.assetsId;
  2919. // aProListSelectDTO.statementNo = this.pageParams.row.statementNo;
  2920. // aProListSelectDTO.reportNo = this.pageParams.row.reportNo;
  2921. // if (this.currentNode.nodeCode == 'WRITE_REPORT' && this.assetsEvaluationTarget[0].statementNo !== null) {
  2922. // aProListSelectDTO.reportNo = this.assetsEvaluationTarget[0].reportNo;
  2923. //获取评估对象中取的号
  2924. aProListSelectDTO.statementNos = this.assetsEvaluationTarget.filter(obj => obj.statementNo !== null && obj.statementNo !== '').map(obj => obj.statementNo);
  2925. aProListSelectDTO.reportNos = this.assetsEvaluationTarget.filter(obj => obj.reportNo !== null && obj.reportNo !== '').map(obj => obj.reportNo);
  2926. // }
  2927. this.assetsProductionData = null;
  2928. if (aProListSelectDTO.statementNos.length > 0 || aProListSelectDTO.reportNos.length > 0) {
  2929. this.$api.assets.getProductionList(aProListSelectDTO).then(res => {
  2930. if (res.code == 200) {
  2931. this.assetsProductionData = res.data;
  2932. this.assetsProductionData = this.assetsProductionData.map(item => {
  2933. // 检查 filePath 是否为字符串且不为空
  2934. if (typeof item.filePath === 'string' && item.filePath.trim() !== '') {
  2935. try {
  2936. // 使用 JSON.parse 解析 filePath 字符串
  2937. item.filePath = JSON.parse(item.filePath);
  2938. } catch (error) {
  2939. console.error('解析 filePath 时发生错误:', error);
  2940. }
  2941. }
  2942. // 返回更新后的对象
  2943. return item;
  2944. });
  2945. }
  2946. })
  2947. }
  2948. },
  2949. //选择要提交节点的产品号
  2950. pushProductionNo() {
  2951. // 查询该产品是否已有提交的流程
  2952. let aProListSelectDTO = { businessId: null, productionNo: null, productionNos: [] };
  2953. this.nodeBusinessInfo.reportNos = [];
  2954. this.nodeBusinessInfo.reportNos.push(this.commitProductionNo);
  2955. if (this.currentNode.nodeCode == 'GENERATE_STATEMENT') {
  2956. this.nodeBusinessInfo.businessSubId = this.commitProductionNo;
  2957. aProListSelectDTO.productionNos = this.assetsProductionData.filter(obj => obj.productionType == 'STATEMENT').map(obj => obj.productionNo);
  2958. }
  2959. if (this.currentNode.nodeCode == 'WRITE_REPORT') {
  2960. this.nodeBusinessInfo.businessMinId = this.commitProductionNo;
  2961. aProListSelectDTO.productionNos = this.assetsProductionData.filter(obj => obj.productionType !== 'STATEMENT').map(obj => obj.productionNo);
  2962. }
  2963. aProListSelectDTO.businessId = this.assetsForm.id;
  2964. aProListSelectDTO.productionNo = this.commitProductionNo;
  2965. this.$api.assets.getInatanceCount(aProListSelectDTO).then(res => {
  2966. if (res.code == 200) {
  2967. this.proInatanceCount = res.data;
  2968. }
  2969. })
  2970. //判断是否还有未撰写或未提交的产品(false:无,提交时完成节点 true:有,提交时不完成节点)
  2971. let isNotWriteAllPro = true;
  2972. if (this.currentNode.nodeCode === 'GENERATE_STATEMENT') {
  2973. isNotWriteAllPro = this.assetsEvaluationTarget.some(obj =>
  2974. (obj.statementCreateProductionDate === null || obj.statementCreateProductionDate === '')
  2975. );
  2976. }
  2977. if (this.currentNode.nodeCode === 'WRITE_REPORT') {
  2978. isNotWriteAllPro = this.assetsEvaluationTarget.some(obj =>
  2979. (obj.reportCreateProductionDate === null || obj.reportCreateProductionDate === '')
  2980. );
  2981. }
  2982. // 判断是否完成节点
  2983. if (isNotWriteAllPro) { // 还有未撰写或未提交产品不完成节点
  2984. this.nodeBusinessInfo.ifCheckTask = false;
  2985. } else {
  2986. this.$api.assets.getInatanceCountList(aProListSelectDTO).then(res => {
  2987. if (res.code == 200) {
  2988. // 未提交的同类型产品大于1时,不完成节点
  2989. if (res.data.filter(count => count === 0).length > 1) {
  2990. this.nodeBusinessInfo.ifCheckTask = false;
  2991. } else {
  2992. this.nodeBusinessInfo.ifCheckTask = true;
  2993. }
  2994. } else {
  2995. this.nodeBusinessInfo.ifCheckTask = true;
  2996. }
  2997. })
  2998. }
  2999. },
  3000. // 打开审核定价弹窗表单
  3001. openCheckValueDialog(id) {
  3002. this.checkValueDialogVisible = true;
  3003. this.$api.assets.getAssetsTargetDetail(id).then(res => {
  3004. if (res.code === 200) {
  3005. this.targetForm = res.data;
  3006. this.targetForm.evaluationMethodId = JSON.parse(res.data.evaluationMethodId);
  3007. this.targetForm.choiceEvaluationMethodId = JSON.parse(res.data.choiceEvaluationMethodId);
  3008. }
  3009. })
  3010. this.getAssetsEvaluationMethod()
  3011. },
  3012. // 评估对象审核定价
  3013. checkValue() {
  3014. this.$refs.targetForm.validate(valid => {
  3015. if (valid) {
  3016. this.targetForm.evaluationMethodId = JSON.stringify(this.targetForm.evaluationMethodId);
  3017. this.targetForm.choiceEvaluationMethodId = JSON.stringify(this.targetForm.choiceEvaluationMethodId);
  3018. this.$api.assets.checkValue(this.targetForm).then(res => {
  3019. if (res.code == 200) {
  3020. this.$notify({
  3021. title: '成功',
  3022. message: '审核定价已完成!',
  3023. type: 'success',
  3024. duration: 2000
  3025. });
  3026. this.checkValueDialogVisible = false;
  3027. this.getAETargetListByAssetsId();
  3028. // this.isCheckValue = true;
  3029. }
  3030. })
  3031. }
  3032. })
  3033. },
  3034. // 根据产品id获取产品详情
  3035. getAssetsProductionDetail(id) {
  3036. this.$api.assets.getAssetsProductionDetail(id).then(res => {
  3037. if (res.code == 200) {
  3038. this.assetsProductionForm = res.data;
  3039. this.assetsProductionForm.signatory = JSON.parse(res.data.signatory);
  3040. this.assetsProductionForm.filePath = JSON.parse(res.data.filePath);
  3041. this.fileList = JSON.parse(JSON.stringify(this.assetsProductionForm.filePath));
  3042. this.productionWriteDialogVisible = true;
  3043. }
  3044. })
  3045. },
  3046. // 更新产品信息
  3047. productionUpdate() {
  3048. this.$refs.assetsProductionForm.validate(valid => {
  3049. if (valid) {
  3050. this.assetsProductionForm.filePath = JSON.stringify(this.assetsProductionForm.filePath);
  3051. if (this.assetsProductionForm.signatory !== null) {
  3052. this.assetsProductionForm.signatory = JSON.stringify(this.assetsProductionForm.signatory);
  3053. } else {
  3054. this.assetsProductionForm.signatory = null;
  3055. }
  3056. this.$api.assets.productionUpdate(this.assetsProductionForm).then(res => {
  3057. if (res.code == 200) {
  3058. this.$notify({
  3059. title: '成功',
  3060. message: '产品修改成功!',
  3061. type: 'success',
  3062. duration: 2000
  3063. });
  3064. }
  3065. this.getAETargetListByAssetsId();
  3066. this.productionWriteDialogVisible = false;
  3067. this.getProductionList();
  3068. })
  3069. }
  3070. })
  3071. },
  3072. // 根据业务类型,产品id及checkLoop获取质检信息
  3073. openProductionCheckDialog() {
  3074. this.$api.assets.getAssetsProductionDetail(this.productionPerformanceForm.productionId).then(res => {
  3075. if (res.code == 200) {
  3076. this.assetsProductionForm = res.data;
  3077. this.assetsProductionForm.filePath = JSON.parse(res.data.filePath);
  3078. this.fileList = JSON.parse(JSON.stringify(this.assetsProductionForm.filePath));
  3079. }
  3080. })
  3081. const curNode = this.currentNode.nodeCode;
  3082. if (curNode === 'REVIEW_STATEMENT' || curNode === 'CHECK_REPORT') {
  3083. if (this.assetsEvaluationTarget.some(item => !item.checkValue)) {
  3084. this.$notify({
  3085. title: '警告',
  3086. message: '评估对象需要进行审核定价',
  3087. type: 'error',
  3088. duration: 3000
  3089. });
  3090. } else {
  3091. this.initProQuality(curNode);
  3092. }
  3093. } else {
  3094. this.initProQuality(curNode);
  3095. }
  3096. },
  3097. // 质检信息基础信息赋值
  3098. initProQuality(curNode) {
  3099. this.productionCheckDialogVisible = true;
  3100. this.productionPerformanceForm.businessType = 'ASSET_BUSINESS';
  3101. if (curNode === 'REVIEW_STATEMENT' || curNode === 'CHECK_REPORT') {
  3102. this.productionPerformanceForm.checkLoop = "初审";
  3103. }
  3104. if (curNode === 'REEXAMINE_STATEMENT' || curNode === 'RECHECK_REPORT') {
  3105. this.productionPerformanceForm.checkLoop = "复审";
  3106. }
  3107. if (curNode === 'FOURTH_CHECK_REPORT') {
  3108. this.productionPerformanceForm.checkLoop = "四审";
  3109. }
  3110. this.$api.businessProductionPerformance.getProductionPerformance(this.productionPerformanceForm).then(res => {
  3111. if (res.code === 200 && res.data !== null) {
  3112. this.productionPerformanceForm.id = res.data.id;
  3113. this.productionPerformanceForm.fatalMistake = res.data.fatalMistake;
  3114. this.productionPerformanceForm.hardMistake = res.data.hardMistake;
  3115. this.productionPerformanceForm.normalMistake = res.data.normalMistake;
  3116. this.productionPerformanceForm.reason = res.data.reason;
  3117. }
  3118. })
  3119. },
  3120. // 保存产品质检信息(新增与保存都是这个方法)
  3121. saveQuality() {
  3122. if ((this.productionPerformanceForm.hardMistake + this.productionPerformanceForm.fatalMistake + this.productionPerformanceForm.normalMistake) > 0) {
  3123. if (this.productionPerformanceForm.reason !== null && this.productionPerformanceForm.reason !== '') {
  3124. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  3125. this.taskRecordDTO.taskData = this.productionPerformanceForm;
  3126. // id不为空更新
  3127. if (this.productionPerformanceForm.id) {
  3128. this.$api.businessProductionPerformance.edit(this.taskRecordDTO).then(res => {
  3129. if (res.code === 200 && res.data) {
  3130. this.$notify({
  3131. title: '成功',
  3132. message: '质检信息更新成功,请继续提交流程节点!',
  3133. type: 'success',
  3134. duration: 3000
  3135. });
  3136. if (this.currentNode.nodeCode === 'RECHECK_REPORT' || this.currentNode.nodeCode === 'FOURTH_CHECK_REPORT') {
  3137. this.updateProductionFileInfo();
  3138. }
  3139. this.productionCheckDialogVisible = false;
  3140. }
  3141. })
  3142. } else { // id为空新增
  3143. this.$api.businessProductionPerformance.add(this.taskRecordDTO).then(res => {
  3144. if (res.code === 200 && res.data) {
  3145. this.$notify({
  3146. title: '成功',
  3147. message: '质检信息保存成功,请继续提交流程节点!',
  3148. type: 'success',
  3149. duration: 3000
  3150. });
  3151. if (this.currentNode.nodeCode === 'RECHECK_REPORT' || this.currentNode.nodeCode === 'FOURTH_CHECK_REPORT') {
  3152. this.updateProductionFileInfo();
  3153. }
  3154. this.productionCheckDialogVisible = false;
  3155. }
  3156. })
  3157. }
  3158. } else {
  3159. this.$notify({
  3160. title: '错误',
  3161. message: '错误个数大于0时必须填写扣分原因',
  3162. type: 'error',
  3163. duration: 3000
  3164. });
  3165. }
  3166. } else {
  3167. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  3168. this.taskRecordDTO.taskData = this.productionPerformanceForm;
  3169. // id不为空更新
  3170. if (this.productionPerformanceForm.id) {
  3171. this.$api.businessProductionPerformance.edit(this.taskRecordDTO).then(res => {
  3172. if (res.code === 200 && res.data) {
  3173. this.$notify({
  3174. title: '成功',
  3175. message: '质检信息更新成功,请继续提交流程节点!',
  3176. type: 'success',
  3177. duration: 3000
  3178. });
  3179. if (this.currentNode.nodeCode === 'RECHECK_REPORT' || this.currentNode.nodeCode === 'FOURTH_CHECK_REPORT') {
  3180. this.updateProductionFileInfo();
  3181. }
  3182. this.productionCheckDialogVisible = false;
  3183. }
  3184. })
  3185. } else { // id为空新增
  3186. this.$api.businessProductionPerformance.add(this.taskRecordDTO).then(res => {
  3187. if (res.code === 200 && res.data) {
  3188. this.$notify({
  3189. title: '成功',
  3190. message: '质检信息保存成功,请继续提交流程节点!',
  3191. type: 'success',
  3192. duration: 3000
  3193. });
  3194. if (this.currentNode.nodeCode === 'RECHECK_REPORT' || this.currentNode.nodeCode === 'FOURTH_CHECK_REPORT') {
  3195. this.updateProductionFileInfo();
  3196. }
  3197. this.productionCheckDialogVisible = false;
  3198. }
  3199. })
  3200. }
  3201. }
  3202. },
  3203. // 根据资产产品id更新文件路由信息
  3204. updateProductionFileInfo() {
  3205. this.assetsProductionForm.filePath = JSON.stringify(this.assetsProductionForm.filePath);
  3206. this.$api.assets.updateProductionFileInfo(this.assetsProductionForm).then(res => {
  3207. if (res.code === 200 && res.data) {
  3208. this.$notify({
  3209. title: '成功',
  3210. message: '产品附件保存成功',
  3211. type: 'success',
  3212. duration: 3000
  3213. });
  3214. }
  3215. })
  3216. },
  3217. // 打开产品出入库弹窗
  3218. openWareHouseDialog(row) {
  3219. this.warehouseDialog = true;
  3220. this.wareHouseProductionType = row.productionType;
  3221. this.wareHouseproductionId = row.id
  3222. },
  3223. handleScanEntry(scanData) {
  3224. this.scanEntryData = scanData;
  3225. },
  3226. cleanWareHouseProductionType() {
  3227. this.wareHouseProductionType = null;
  3228. this.wareHouseproductionId = null;
  3229. },
  3230. // 产品出入库
  3231. doWareHouse() {
  3232. let productionNo = this.scanEntryData
  3233. let wareHoaseDto = new Object();
  3234. if (productionNo) {
  3235. wareHoaseDto.productionNo = reportNo;
  3236. } else {
  3237. wareHoaseDto.productionNo = this.$refs.scanEntry.scanEntryData;
  3238. }
  3239. if (this.currentNode.nodeName.includes("入库")) {
  3240. wareHoaseDto.repertoryState = 0;
  3241. } else {
  3242. wareHoaseDto.repertoryState = 1;
  3243. }
  3244. wareHoaseDto.productionType = this.wareHouseProductionType;
  3245. wareHoaseDto.productionId = this.wareHouseproductionId;
  3246. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  3247. this.taskRecordDTO.taskData = wareHoaseDto;
  3248. this.$api.assets.assetsProRepertory(this.taskRecordDTO).then(res => {
  3249. if (res.code === 200 && res.data) {
  3250. this.$notify({
  3251. title: '成功',
  3252. message: '库存操作成功,请继续提交流程节点!',
  3253. type: 'success',
  3254. duration: 2000
  3255. });
  3256. this.warehouseDialog = false;
  3257. this.getProductionList();
  3258. }
  3259. else {
  3260. this.$message({
  3261. type: 'info',
  3262. message: '取消操作'
  3263. });
  3264. }
  3265. })
  3266. },
  3267. // 判断流程是否进行四审
  3268. flowDoFourthCheck() {
  3269. if (this.currentNode.nodeCode == 'RECHECK_REPORT') {
  3270. // 判断评估值是否超过8000万
  3271. let isSubstantialAssets = this.assetsEvaluationTarget.reduce((sum, obj) => { return sum + obj.estimatedValue; }, 0) > 8000;
  3272. // 获取是否有评估目的为搬迁、司法涉讼的评估对象
  3273. let isLawsuit = this.assetsEvaluationTarget.some(obj => obj.purposeName === '搬迁' || obj.purposeName === '资产涉讼');
  3274. // 获取是否证券项目
  3275. let isSecurity = this.assetsForm.security;
  3276. // 是否证券项目,或是否评估目的搬迁、诉讼,或是否价值大于8000万
  3277. if (isSecurity || isLawsuit || isSubstantialAssets) {
  3278. this.nodeBusinessInfo.doFourthCheck = true;
  3279. }
  3280. }
  3281. },
  3282. // 根据产品号获取产品实收款
  3283. getProductionRealAmount(productionNo) {
  3284. this.$api.assets.getProductionRealAmount(productionNo).then(res => {
  3285. if (res.code === 200 && res.data !== null) {
  3286. this.nodeBusinessInfo.ifProductionFund = true;
  3287. } else {
  3288. this.nodeBusinessInfo.ifProductionFund = false;
  3289. }
  3290. })
  3291. },
  3292. // 打开绩效比例分配弹窗
  3293. openAssetsAchievementRatioDialog() {
  3294. // this.businessPerformanceDistributionForm.distributionList = [];
  3295. //获取报告附件信息
  3296. let assetsProductionDetailDTO = new Object();
  3297. assetsProductionDetailDTO.businessId = this.pageParams.row.assetsId;
  3298. assetsProductionDetailDTO.productionNo = this.pageParams.row.reportNo;
  3299. this.$api.assets.getAssetsProductionDetailByNo(assetsProductionDetailDTO).then(res => {
  3300. if (res.code == 200 && res.data !== null) {
  3301. this.assetsProductionForm = res.data;
  3302. this.assetsProductionForm.filePath = JSON.parse(res.data.filePath);
  3303. this.fileList = JSON.parse(JSON.stringify(this.assetsProductionForm.filePath));
  3304. }
  3305. })
  3306. this.assetsAchievementRatioDialogVisible = true;
  3307. // this.getPerformanceDistributionList();
  3308. // if (this.businessPerformanceDistributionForm.distributionList !== null && this.businessPerformanceDistributionForm.distributionList[0].id !== null) {
  3309. // this.showDistributionButton = false;
  3310. // } else {
  3311. // this.showDistributionButton = true;
  3312. // }
  3313. },
  3314. // 新增资产绩效分配信息
  3315. saveBusinessPerformanceDistribution() {
  3316. const sum = this.businessPerformanceDistributionForm.distributionList.reduce((accumulator, obj) => {
  3317. return accumulator + obj.performanceDistribution;
  3318. }, 0);
  3319. if (sum === 100) {
  3320. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  3321. this.taskRecordDTO.taskData = this.businessPerformanceDistributionForm;
  3322. this.$api.businessPerformanceDistribution.addAssetsPerformanceDistribution(this.taskRecordDTO).then(res => {
  3323. if (res.code === 200) {
  3324. this.$notify({
  3325. title: '成功',
  3326. message: '绩效分配新增完成,请继续提交流程节点!',
  3327. type: 'success',
  3328. duration: 3000
  3329. });
  3330. if (this.currentNode.nodeCode === 'CHECK_ARCHIVING') {
  3331. this.updateProductionFileInfo();
  3332. }
  3333. this.resetBusinessPerformanceDistributionForm();
  3334. }
  3335. })
  3336. } else {
  3337. this.$notify({
  3338. title: '警告',
  3339. message: '所有人员分配的绩效之和必须等于100%!',
  3340. type: 'error',
  3341. duration: 3000
  3342. });
  3343. }
  3344. },
  3345. // 重置绩效分配表单
  3346. resetBusinessPerformanceDistributionForm() {
  3347. this.assetsAchievementRatioDialogVisible = false;
  3348. this.businessPerformanceDistributionForm.businessId = null;
  3349. this.businessPerformanceDistributionForm.businessType = null;
  3350. this.businessPerformanceDistributionForm.reportNo = null;
  3351. },
  3352. // 获取资产绩效分配信息list
  3353. getPerformanceDistributionList() {
  3354. this.businessPerformanceDistributionForm.businessId = this.pageParams.row.assetsId;
  3355. this.businessPerformanceDistributionForm.businessType = 'ASSET_BUSINESS';
  3356. this.businessPerformanceDistributionForm.reportNo = this.pageParams.row.reportNo;
  3357. let selectDTO = this.businessPerformanceDistributionForm;
  3358. selectDTO.distributionList = null;
  3359. this.$api.businessPerformanceDistribution.getPerformanceDistributionList(this.businessPerformanceDistributionForm).then(res => {
  3360. if (res.code === 200 && res.data !== null && res.data.length > 0) {
  3361. this.businessPerformanceDistributionForm.distributionList = res.data;
  3362. this.getAssetsBusinessMembers();
  3363. this.showDistributionButton = false;
  3364. } else {
  3365. this.showDistributionButton = true;
  3366. this.getAssetsBusinessMembers(true);
  3367. }
  3368. })
  3369. },
  3370. // 获取项目参与人信息
  3371. getAssetsBusinessMembers(state) {
  3372. let assetsBusinessMembersDTO = { businessId: null, reportNo: null };
  3373. assetsBusinessMembersDTO.businessId = this.pageParams.row.assetsId;
  3374. assetsBusinessMembersDTO.reportNo = this.pageParams.row.reportNo;
  3375. this.$api.assets.getAssetsBusinessMembers(assetsBusinessMembersDTO).then(res => {
  3376. // 返回不为空,且没有绩效分配信息
  3377. if (res.code === 200 && res.data !== null) {
  3378. this.assetsBusinessMembers = res.data;
  3379. if (state) {
  3380. this.businessPerformanceDistributionForm.distributionList = [];
  3381. for (let i = 0; i < this.assetsBusinessMembers.length; i++) {
  3382. let memberInfo = { memberId: this.assetsBusinessMembers[i].memberId, performanceDistribution: 0, memberType: this.assetsBusinessMembers[i].memberType }
  3383. this.businessPerformanceDistributionForm.distributionList.push(memberInfo)
  3384. }
  3385. }
  3386. }
  3387. })
  3388. },
  3389. // 修改资产绩效分配信息
  3390. updateAssetsPerformanceDistribution() {
  3391. const sum = this.businessPerformanceDistributionForm.distributionList.reduce((accumulator, obj) => {
  3392. return accumulator + obj.performanceDistribution;
  3393. }, 0);
  3394. if (sum === 100) {
  3395. this.taskRecordDTO.recordId = this.currentNode.tasks[0].recordId;
  3396. this.taskRecordDTO.taskData = this.businessPerformanceDistributionForm;
  3397. this.$api.businessPerformanceDistribution.updateAssetsPerformanceDistribution(this.taskRecordDTO).then(res => {
  3398. if (res.code === 200) {
  3399. this.$notify({
  3400. title: '成功',
  3401. message: '绩效分配修改完成,请继续提交流程节点!',
  3402. type: 'success',
  3403. duration: 3000
  3404. });
  3405. if (this.currentNode.nodeCode === 'CHECK_ARCHIVING') {
  3406. this.updateProductionFileInfo();
  3407. }
  3408. this.resetBusinessPerformanceDistributionForm();
  3409. }
  3410. })
  3411. } else {
  3412. this.$notify({
  3413. title: '警告',
  3414. message: '所有人员分配的绩效之和必须等于100%!',
  3415. type: 'error',
  3416. duration: 3000
  3417. });
  3418. }
  3419. },
  3420. // 获取联系信息
  3421. getContactInfo() {
  3422. if (this.assetsForm.clienteleContactId) {
  3423. this.$api.customerLinkman.detail(this.assetsForm.clienteleContactId).then(res => {
  3424. if (res.code === 200) {
  3425. this.linkmanInfo = res.data;
  3426. }
  3427. })
  3428. }
  3429. if (this.assetsForm.terminalClienteleContactId) {
  3430. this.$api.customerLinkman.detail(this.assetsForm.terminalClienteleContactId).then(res => {
  3431. if (res.code === 200) {
  3432. this.tLinkmanInfo = res.data;
  3433. this.$forceUpdate();
  3434. this.assetsForm.tmobile = this.tLinkmanInfo.mobile;
  3435. }
  3436. })
  3437. }
  3438. if (this.assetsForm.terminalClienteleId) {
  3439. this.$api.customerCompany.detail(this.assetsForm.terminalClienteleId).then(res => {
  3440. if (res.code === 200) {
  3441. this.tCustomerInfo = res.data;
  3442. // this.assetsForm.tmobile = this.tCustomerInfo.phone;
  3443. }
  3444. })
  3445. }
  3446. },
  3447. // 更新资产订单基本信息
  3448. updateOrderBaseInfo() {
  3449. this.$refs.assetsForm.validate(valid => {
  3450. if (valid) {
  3451. this.$confirm('是否确定要修改订单基本信息?', '提示', {
  3452. confirmButtonText: '确定',
  3453. cancelButtonText: '取消',
  3454. type: 'warning'
  3455. }).then(() => {
  3456. if (this.assetsForm.members) {
  3457. this.assetsForm.members = JSON.stringify(this.assetsForm.members);
  3458. }
  3459. this.$api.assets.updateOrderBaseInfo(this.assetsForm).then(res => {
  3460. if (res.code === 200 && res.data) {
  3461. this.$notify({
  3462. title: '成功',
  3463. message: '订单基本信息更新成功!',
  3464. type: 'success',
  3465. duration: 3000
  3466. });
  3467. this.getAssetsDetailById(this.pageParams.row.assetsId);
  3468. } else {
  3469. this.$notify({
  3470. title: '失败',
  3471. message: '订单基本信息更新失败!请稍后重试!',
  3472. type: 'warning',
  3473. duration: 3000
  3474. });
  3475. }
  3476. })
  3477. }).catch(() => {
  3478. this.$message({
  3479. type: 'info',
  3480. message: '已取消更新'
  3481. });
  3482. });
  3483. }
  3484. })
  3485. },
  3486. // 文档预览
  3487. officeFileView(name, url) {
  3488. if (name && url) {
  3489. const route = this.$router.resolve({
  3490. path: "/office/view/window",
  3491. query: {
  3492. // 文档标题
  3493. title: name,
  3494. // 文档url地址
  3495. url: url
  3496. }
  3497. });
  3498. // 在新窗口打开页面
  3499. window.open(route.href, "_blank");
  3500. } else {
  3501. this.$notify({
  3502. title: '失败',
  3503. message: 'url为空,无法打开,如未保存请保存后再试!',
  3504. type: 'error',
  3505. duration: 2000
  3506. });
  3507. }
  3508. }
  3509. }
  3510. }
  3511. </script>
  3512. <style lang="scss" scoped>
  3513. .row-style {
  3514. margin-left: 40px;
  3515. margin-right: 1%;
  3516. }
  3517. .major-radio {
  3518. width: 92px
  3519. }
  3520. .task-class {
  3521. /deep/ .el-form-item__label {
  3522. color: red;
  3523. }
  3524. }
  3525. .evaluate-table {
  3526. margin-left: 40px;
  3527. margin-top: 35px;
  3528. }
  3529. .pane-class {
  3530. height: 800px;
  3531. width: 100%;
  3532. overflow-y: scroll;
  3533. }
  3534. /deep/ .cell-class {
  3535. font-size: 13px;
  3536. color: black;
  3537. }
  3538. .table {
  3539. /deep/ thead {
  3540. .el-table-column--selection {
  3541. .cell {
  3542. display: none;
  3543. }
  3544. }
  3545. }
  3546. }
  3547. /deep/.doWarehouseClass {
  3548. border-radius: 10px;
  3549. }
  3550. .button-area {
  3551. position: absolute;
  3552. top: 20px;
  3553. right: 50px;
  3554. }
  3555. .error-type {
  3556. margin-right: 5px;
  3557. }
  3558. .error-type:hover {
  3559. cursor: pointer;
  3560. }
  3561. .box-card {
  3562. margin-top: 40px
  3563. }
  3564. .time {
  3565. font-size: 13px;
  3566. color: #999;
  3567. float: right;
  3568. margin-top: 5px;
  3569. }
  3570. .bottom {
  3571. margin-top: 13px;
  3572. line-height: 12px;
  3573. }
  3574. .button {
  3575. float: left;
  3576. }
  3577. .image {
  3578. width: 100%;
  3579. padding: 0%;
  3580. display: block;
  3581. }
  3582. .control {
  3583. z-index: 999;
  3584. position: relative;
  3585. top: 10px;
  3586. }
  3587. </style>