index.vue 115 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579
  1. <template>
  2. <div class="app-container">
  3. <div v-show="mainTable == false">
  4. <el-form
  5. :model="tableFilter"
  6. ref="queryForm"
  7. :inline="true"
  8. v-show="showSearch"
  9. label-width="68px"
  10. >
  11. <el-row>
  12. <el-col :span="6">
  13. <el-form-item label="系统编号" prop="fBillno">
  14. <el-input
  15. v-model="tableFilter.fBillno"
  16. placeholder="请输入系统编号"
  17. clearable
  18. size="small"
  19. style="width: 200px"
  20. @keyup.enter.native="handleQuery"
  21. />
  22. </el-form-item>
  23. </el-col>
  24. <el-col :span="6">
  25. <el-form-item label="货权方" prop="fCtrlcorpid">
  26. <el-input
  27. v-model="tableFilter.fCtrlcorpid"
  28. placeholder="请输入货权方"
  29. clearable
  30. size="small"
  31. style="width: 200px"
  32. @keyup.enter.native="handleQuery"
  33. />
  34. </el-form-item>
  35. </el-col>
  36. <el-col :span="6">
  37. <el-form-item label="结算单位" prop="fCorpid">
  38. <el-select
  39. v-model="tableFilter.fCorpid"
  40. filterable
  41. remote
  42. clearable
  43. size="small"
  44. style="width: 200px"
  45. @keyup.enter.native="handleQuery"
  46. :remote-method="corpsRemoteMethod"
  47. placeholder="请输入结算单位"
  48. >
  49. <el-option
  50. v-for="(dict, index) in fMblnoOptions"
  51. :key="index.fId"
  52. :label="dict.fName"
  53. :value="dict.fId"
  54. ></el-option>
  55. </el-select>
  56. </el-form-item>
  57. </el-col>
  58. <el-col :span="6">
  59. <el-form-item label="状态" prop="fBillstatus">
  60. <el-select
  61. v-model="tableFilter.fBillstatus"
  62. placeholder="请选择状态"
  63. clearable
  64. style="width: 200px"
  65. >
  66. <el-option label="保存" value="1"/>
  67. <el-option label="暂存" value="2"/>
  68. <el-option label="审批驳回" value="3"/>
  69. <el-option label="提交审核" value="4"/>
  70. <el-option label="审批中" value="5"/>
  71. <el-option label="审核完成" value="6"/>
  72. </el-select>
  73. </el-form-item>
  74. </el-col>
  75. </el-row>
  76. <el-collapse-transition>
  77. <div v-show="show">
  78. <el-row>
  79. <el-col :span="6">
  80. <el-form-item label="实收合计" prop="amount">
  81. <el-input
  82. v-model="tableFilter.firstMoney"
  83. placeholder="金额区间"
  84. style="width: 95px;margin-right: 10px"
  85. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  86. />
  87. <el-input
  88. v-model="tableFilter.lastMoney"
  89. placeholder="金额区间"
  90. @change="changeMoney"
  91. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  92. style="width: 95px"
  93. />
  94. </el-form-item>
  95. </el-col>
  96. <el-col :span="6">
  97. <el-form-item label="备注" prop="fRemarks">
  98. <el-input
  99. v-model="tableFilter.fRemarks"
  100. placeholder="请输入备注"
  101. clearable
  102. style="width: 200px"
  103. @keyup.enter.native="handleQuery"
  104. />
  105. </el-form-item>
  106. </el-col>
  107. <el-col :span="12">
  108. <el-form-item label="收费日期" prop="timeInterval">
  109. <el-date-picker
  110. type="daterange"
  111. size="small"
  112. style="width: 230px"
  113. v-model="tableFilter.timeInterval"
  114. start-placeholder="开始日期"
  115. end-placeholder="结束日期"
  116. value-format="yyyy-MM-dd"
  117. :default-time="['00:00:00', '23:59:59']"
  118. >
  119. </el-date-picker>
  120. </el-form-item>
  121. </el-col>
  122. </el-row>
  123. </div>
  124. </el-collapse-transition>
  125. </el-form>
  126. <el-row :gutter="10" class="mb8">
  127. <el-col :span="1.5">
  128. <el-button
  129. type="primary"
  130. icon="el-icon-plus"
  131. size="mini"
  132. @click="handleAdd"
  133. v-hasPermi="['finance:charge:add']"
  134. >新增
  135. </el-button>
  136. </el-col>
  137. <el-col :span="1.5">
  138. <el-button
  139. type="success"
  140. icon="el-icon-edit"
  141. size="mini"
  142. :disabled="single"
  143. @click="handleUpdate"
  144. v-hasPermi="['finance:charge:edit']"
  145. >修改
  146. </el-button>
  147. </el-col>
  148. <!-- <el-col :span="1.5">-->
  149. <!-- <el-button-->
  150. <!-- type="danger"-->
  151. <!-- icon="el-icon-delete"-->
  152. <!-- size="mini"-->
  153. <!-- :disabled="multiple"-->
  154. <!-- @click="handleDelete"-->
  155. <!-- v-hasPermi="['finance:charge:remove']"-->
  156. <!-- >删除-->
  157. <!-- </el-button>-->
  158. <!-- </el-col>-->
  159. <el-col :span="1.5">
  160. <el-button
  161. type="warning"
  162. icon="el-icon-download"
  163. size="mini"
  164. @click="handleExport"
  165. v-hasPermi="['finance:charge:export']"
  166. >导出
  167. </el-button>
  168. </el-col>
  169. <div class="tabSetting">
  170. <div style="margin-right: 20px">
  171. <el-button
  172. type="cyan"
  173. icon="el-icon-search"
  174. size="mini"
  175. @click="handleQuery"
  176. >搜索</el-button
  177. >
  178. <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
  179. >重置</el-button
  180. >
  181. <el-button
  182. v-show="show"
  183. @click="show = !show"
  184. icon="el-icon-arrow-up"
  185. size="mini"
  186. >展开</el-button
  187. >
  188. <el-button
  189. v-show="!show"
  190. @click="show = !show"
  191. icon="el-icon-arrow-down"
  192. size="mini"
  193. >展开</el-button
  194. >
  195. </div>
  196. <right-toolbar
  197. :showSearch.sync="showSearch"
  198. @queryTable="getList"
  199. ></right-toolbar>
  200. <div style="margin: 0 12px">
  201. <el-button
  202. icon="el-icon-setting"
  203. size="mini"
  204. circle
  205. @click="showSetting = !showSetting"
  206. ></el-button>
  207. </div>
  208. </div>
  209. </el-row>
  210. <el-dialog
  211. title="自定义列显示"
  212. :visible.sync="showSetting"
  213. width="700px"
  214. v-dialogDrag
  215. >
  216. <template slot="title">
  217. <div class="avue-crud__dialog__header">
  218. <span class="el-dialog__title">
  219. <span
  220. style="
  221. display: inline-block;
  222. width: 3px;
  223. height: 20px;
  224. margin-right: 5px;
  225. float: left;
  226. margin-top: 2px;
  227. "
  228. ></span>
  229. </span>
  230. </div>
  231. </template>
  232. <div>配置排序列数据(拖动调整顺序)</div>
  233. <div style="margin-left: 17px">
  234. <el-checkbox
  235. v-model="allCheck"
  236. label="全选"
  237. @change="allChecked"
  238. ></el-checkbox>
  239. </div>
  240. <div style="padding: 4px; display: flex; justify-content: center">
  241. <draggable
  242. v-model="setRowList"
  243. group="site"
  244. animation="300"
  245. @start="onStart"
  246. @end="onEnd"
  247. handle=".indraggable"
  248. >
  249. <transition-group>
  250. <div
  251. v-for="item in setRowList"
  252. :key="item.surface"
  253. class="listStyle"
  254. >
  255. <div style="width: 500px" class="indraggable">
  256. <div class="progress" :style="{ width: item.width + 'px' }">
  257. <el-checkbox
  258. :label="item.name"
  259. v-model="item.checked"
  260. :true-label="0"
  261. :false-label="1"
  262. >{{ item.name }}
  263. </el-checkbox>
  264. </div>
  265. </div>
  266. <el-input-number
  267. v-model.number="item.width"
  268. controls-position="right"
  269. :min="1"
  270. :max="500"
  271. size="mini"
  272. ></el-input-number>
  273. </div>
  274. </transition-group>
  275. </draggable>
  276. </div>
  277. <span slot="footer" class="dialog-footer">
  278. <el-button @click="showSetting = false">取 消</el-button>
  279. <el-button @click="delRow" type="danger">重 置</el-button>
  280. <el-button type="primary" @click="save">确 定</el-button>
  281. </span>
  282. </el-dialog>
  283. <el-table
  284. v-loading="loading"
  285. :data="chargeList"
  286. @selection-change="handleSelectionChange"
  287. show-summary
  288. :summary-method="listTotal"
  289. >
  290. <el-table-column type="selection" width="100" align="center" />
  291. <el-table-column
  292. label="序号"
  293. type="index"
  294. width="55"
  295. align="center"
  296. fixed
  297. />
  298. <el-table-column
  299. v-for="(item, index) in getRowList"
  300. :key="index"
  301. :label="item.name"
  302. :width="item.width"
  303. :prop="item.label"
  304. align="center"
  305. :show-overflow-tooltip="true"
  306. sortable
  307. :fixed="item.fixed"
  308. >
  309. <template slot-scope="scope">
  310. <span v-if="item.label == 'createBy'">{{scope.row.createBy}}</span>
  311. <span v-if="item.label == 'fBillno'">{{scope.row.fBillno}}</span>
  312. <span v-if="item.label == 'fCtrlcorpid'">{{scope.row.fCtrlcorpid}}</span>
  313. <span v-if="item.label == 'createTime'">{{scope.row.createTime?scope.row.createTime.slice(0,10):''}}</span>
  314. <span v-if="item.label == 'fAccbilldate'">{{scope.row.fAccbilldate}}</span>
  315. <span v-if="item.label == 'fMblno'">{{scope.row.fMblno}}</span>
  316. <span v-if="item.label == 'chargingMethod'">{{scope.row.chargingMethod}}</span>
  317. <span v-if="item.label == 'invoiceNo'">{{scope.row.invoiceNo}}</span>
  318. <span v-if="item.label == 'bank'">{{scope.row.bank}}</span>
  319. <span v-if="item.label == 'waterBillNo'">{{scope.row.waterBillNo}}</span>
  320. <span v-if="item.label == 'fAmtdr'">{{scope.row.fAmtdr}}</span>
  321. <span v-if="item.label == 'fAmtcr'">{{scope.row.fAmtcr}}</span>
  322. <span v-if="item.label == 'fRemarks'">{{scope.row.fRemarks}}</span>
  323. <span v-if="item.label == 'fBillstatus'">{{scope.row.fBillstatus}}</span>
  324. </template>
  325. </el-table-column>
  326. <el-table-column
  327. label="操作"
  328. align="center"
  329. class-name="small-padding fixed-width"
  330. min-width="180"
  331. fixed="right"
  332. >
  333. <template slot-scope="scope">
  334. <el-button
  335. size="mini"
  336. type="text"
  337. icon="el-icon-view"
  338. @click="check(scope.row, 0)"
  339. v-hasPermi="['finance:contrast:edit']"
  340. >查看</el-button
  341. >
  342. <el-button
  343. size="mini"
  344. type="text"
  345. icon="el-icon-view"
  346. @click="check(scope.row, 1)"
  347. v-hasPermi="['finance:contrast:edit']"
  348. v-if="
  349. scope.row.fBillstatus == '提交审核' ||
  350. scope.row.fBillstatus == '审核中'
  351. "
  352. >审批进度</el-button
  353. >
  354. <el-button
  355. size="mini"
  356. type="text"
  357. icon="el-icon-edit"
  358. @click="handleUpdate(scope.row)"
  359. v-hasPermi="['finance:charge:edit']"
  360. v-if="
  361. scope.row.fBillstatus == '保存' ||
  362. scope.row.fBillstatus == '暂存' ||
  363. scope.row.fBillstatus == '审批驳回'
  364. "
  365. >修改
  366. </el-button>
  367. <el-button
  368. size="mini"
  369. type="text"
  370. icon="el-icon-delete"
  371. @click="handleDelete(scope.row)"
  372. v-hasPermi="['finance:charge:remove']"
  373. v-if="
  374. scope.row.fBillstatus == '保存' ||
  375. scope.row.fBillstatus == '暂存' ||
  376. scope.row.fBillstatus == '审批驳回'
  377. "
  378. >删除
  379. </el-button>
  380. <!-- <el-button-->
  381. <!-- size="mini"-->
  382. <!-- type="text"-->
  383. <!-- icon="el-icon-delete"-->
  384. <!-- v-if="scope.row.fBillstatus === 6"-->
  385. <!-- >查看-->
  386. <!-- </el-button>-->
  387. <!-- <el-button-->
  388. <!-- size="mini"-->
  389. <!-- type="text"-->
  390. <!-- icon="el-icon-delete"-->
  391. <!-- v-if="scope.row.fBillstatus > 3 && scope.row.fBillstatus < 6"-->
  392. <!-- >查看审批流-->
  393. <!-- </el-button>-->
  394. </template>
  395. </el-table-column>
  396. <!-- <el-table-column label="单据类型" align="center" prop="fBilltype"/>-->
  397. <!-- <el-table-column label="制单部门" align="center" prop="fDeptid"/>-->
  398. </el-table>
  399. <pagination
  400. v-show="total > 0"
  401. :total="total"
  402. :page.sync="tableFilter.pageNum"
  403. :limit.sync="tableFilter.pageSize"
  404. @pagination="getList"
  405. />
  406. </div>
  407. <div v-if="mainTable == true">
  408. <el-form
  409. :model="queryParams"
  410. :rules="ruless"
  411. ref="ruless"
  412. :inline="true"
  413. v-show="showSearch"
  414. label-width="78px"
  415. >
  416. <el-form-item label="货权方" prop="fCtrlcorpid">
  417. <el-input
  418. v-model="queryParams.fCtrlcorpid"
  419. placeholder="请输入货权方"
  420. clearable
  421. size="small"
  422. :disabled="notChange"
  423. style="width: 200px"
  424. @keyup.enter.native="handleQuery"
  425. />
  426. </el-form-item>
  427. <el-form-item label="结算单位" prop="fCorpid">
  428. <el-select
  429. v-model="queryParams.fCorpid"
  430. filterable
  431. remote
  432. clearable
  433. size="small"
  434. style="width: 200px"
  435. @keyup.enter.native="handleQuery"
  436. :remote-method="corpsRemoteMethod"
  437. :disabled="doNot"
  438. placeholder="请输入结算单位"
  439. >
  440. <el-option
  441. v-for="(dict, index) in fMblnoOptions"
  442. :key="index.fId"
  443. :label="dict.fName"
  444. :value="dict.fId"
  445. ></el-option>
  446. </el-select>
  447. </el-form-item>
  448. <el-form-item label="收费日期" prop="fAccbilldate">
  449. <el-date-picker
  450. clearable
  451. size="small"
  452. style="width: 200px"
  453. v-model="queryParams.fAccbilldate"
  454. type="date"
  455. value-format="yyyy-MM-dd"
  456. placeholder="选择账单日期"
  457. :disabled="notChange"
  458. >
  459. </el-date-picker>
  460. </el-form-item>
  461. <el-form-item label="系统编号" prop="fBillno">
  462. <el-input
  463. v-model="queryParams.fBillno"
  464. placeholder="请输入系统编号"
  465. clearable
  466. disabled
  467. style="width: 200px"
  468. size="small"
  469. @keyup.enter.native="handleQuery"
  470. />
  471. </el-form-item>
  472. <el-form-item label="收费方式" prop="chargingMethod">
  473. <el-select
  474. v-model="queryParams.chargingMethod"
  475. placeholder="请选择收费方式"
  476. clearable
  477. :disabled="notChange"
  478. style="width: 200px"
  479. size="small"
  480. >
  481. <el-option
  482. v-for="(dict, index) in methodOptions"
  483. :key="index.dictValue"
  484. :label="dict.dictLabel"
  485. :value="dict.dictValue"
  486. ></el-option>
  487. </el-select>
  488. </el-form-item>
  489. <el-form-item label="收款银行" prop="bank">
  490. <el-input
  491. v-model="queryParams.bank"
  492. placeholder="请输入收款银行"
  493. clearable
  494. size="small"
  495. style="width: 200px"
  496. :disabled="notChange"
  497. />
  498. </el-form-item>
  499. <el-form-item label="发票号" prop="invoiceNo">
  500. <el-input
  501. v-model="queryParams.invoiceNo"
  502. placeholder="请输入发票号"
  503. clearable
  504. size="small"
  505. style="width: 200px"
  506. :disabled="notChange"
  507. />
  508. </el-form-item>
  509. <el-form-item label="水单号" prop="waterBillNo">
  510. <el-input
  511. v-model="queryParams.waterBillNo"
  512. placeholder="请输入收款银行"
  513. clearable
  514. size="small"
  515. style="width: 200px"
  516. :disabled="notChange"/>
  517. </el-form-item>
  518. <el-form-item label="备注" prop="fRemarks">
  519. <el-input
  520. v-model="queryParams.fRemarks"
  521. placeholder="请输入备注"
  522. clearable
  523. size="small"
  524. style="width: 200px"
  525. :disabled="notChange"
  526. @keyup.enter.native="handleQuery"
  527. />
  528. </el-form-item>
  529. <!-- <el-form-item label="业务类型" prop="fSystemType">-->
  530. <!-- <el-select-->
  531. <!-- v-model="queryParams.fSystemType"-->
  532. <!-- placeholder="请选择业务类型"-->
  533. <!-- size="small"-->
  534. <!-- disabled-->
  535. <!-- style="width: 200px"-->
  536. <!-- >-->
  537. <!-- <el-option-->
  538. <!-- v-for="item in typeoptions"-->
  539. <!-- :key="item.value"-->
  540. <!-- :label="item.label"-->
  541. <!-- :value="item.value"-->
  542. <!-- >-->
  543. <!-- </el-option>-->
  544. <!-- </el-select>-->
  545. <!-- </el-form-item>-->
  546. </el-form>
  547. <div style="width: 100%; display: flex; justify-content: space-between">
  548. <div style="display: flex">
  549. <el-button icon="el-icon-arrow-left" type="danger" v-if="cancelButton === true" size="mini" @click="cancel"
  550. >返回列表</el-button
  551. >
  552. <el-button icon="el-icon-arrow-left" type="danger" v-if="cancelButton === false" size="mini" @click="homePage"
  553. >返回首页</el-button
  554. >
  555. <el-button
  556. type="warning"
  557. size="mini"
  558. @click="charGe"
  559. :disabled="notChange"
  560. v-if="queryParams.fBillstatus < '4'"
  561. >检索</el-button
  562. >
  563. <el-button
  564. type="primary"
  565. size="mini"
  566. @click="confirmCharge"
  567. :disabled="notChange"
  568. v-if="queryParams.fBillstatus < '4'"
  569. >确认收费</el-button
  570. >
  571. <el-button type="warning" size="mini" @click="handleExportItems"
  572. >导出</el-button
  573. >
  574. <el-button
  575. type="success"
  576. size="mini"
  577. @click="revokeCharge"
  578. v-if="queryParams.fBillstatus === '6'"
  579. >撤销收费</el-button
  580. >
  581. <!-- <el-button type="info" size="small" @click="printing">打印</el-button>-->
  582. <!-- <el-button type="danger" size="small" :disabled="notChange" v-show="Lander == Operator">
  583. </el-button>-->
  584. <el-button
  585. type="danger"
  586. size="mini"
  587. :disabled="tablefilter"
  588. @click="approvalRevocation('f_billstatus')"
  589. v-show="queryParams.fBillstatus === '4'"
  590. >撤销审批</el-button
  591. >
  592. <el-button v-if="approve === true" size="mini" @click="immediateApproval('f_billstatus')"
  593. >审批</el-button
  594. >
  595. <el-button
  596. type="primary"
  597. size="mini"
  598. v-if="queryParams.fBillstatus >= '3'"
  599. @click="addOrUpdateHandle('f_billstatus')"
  600. >查看审批流</el-button
  601. >
  602. <el-button type="success" @click="submitForm(0)" size="mini" :disabled="notChange"
  603. >保 存</el-button
  604. >
  605. <el-button type="primary" @click="addPage" size="mini">新 增</el-button>
  606. </div>
  607. <div style="margin: 0 12px">
  608. <el-button
  609. icon="el-icon-setting"
  610. size="mini"
  611. circle
  612. @click="showSetting2 = !showSetting2"
  613. ></el-button>
  614. </div>
  615. </div>
  616. <el-dialog
  617. title="自定义列显示"
  618. :visible.sync="showSetting2"
  619. width="700px"
  620. v-dialogDrag
  621. append-to-body
  622. >
  623. <template slot="title">
  624. <div class="avue-crud__dialog__header">
  625. <span class="el-dialog__title">
  626. <span
  627. style="
  628. display: inline-block;
  629. width: 3px;
  630. height: 20px;
  631. margin-right: 5px;
  632. float: left;
  633. margin-top: 2px;
  634. "
  635. ></span>
  636. </span>
  637. </div>
  638. </template>
  639. <div>配置排序列数据(拖动调整顺序)</div>
  640. <div style="margin-left: 17px">
  641. <el-checkbox
  642. v-model="allCheck2"
  643. label="全选"
  644. @change="allChecked2"
  645. ></el-checkbox>
  646. </div>
  647. <div style="padding: 4px; display: flex; justify-content: center">
  648. <draggable
  649. v-model="setRowList2"
  650. group="site"
  651. animation="300"
  652. @start="onStart"
  653. @end="onEnd"
  654. handle=".indraggable"
  655. >
  656. <transition-group>
  657. <div
  658. v-for="item in setRowList2"
  659. :key="item.surface"
  660. class="listStyle"
  661. >
  662. <div style="width: 500px" class="indraggable">
  663. <div class="progress" :style="{ width: item.width + 'px' }">
  664. <el-checkbox
  665. :label="item.name"
  666. v-model="item.checked"
  667. :true-label="0"
  668. :false-label="1"
  669. >{{ item.name }}
  670. </el-checkbox>
  671. </div>
  672. </div>
  673. <el-input-number
  674. v-model.number="item.width"
  675. controls-position="right"
  676. :min="1"
  677. :max="500"
  678. size="mini"
  679. ></el-input-number>
  680. </div>
  681. </transition-group>
  682. </draggable>
  683. </div>
  684. <span slot="footer" class="dialog-footer">
  685. <el-button @click="showSetting2 = false">取 消</el-button>
  686. <el-button @click="delRow2" type="danger">重 置</el-button>
  687. <el-button type="primary" @click="save2()">确 定</el-button>
  688. </span>
  689. </el-dialog>
  690. <el-table
  691. v-loading="loading"
  692. :data="increase_s"
  693. @selection-change="handleSelectionChange_s"
  694. show-summary
  695. :summary-method="listTotal"
  696. >
  697. <!-- <el-table-column type="selection" width="55" align="center"/>-->
  698. <el-table-column label="序号" type="index" align="center" />
  699. <el-table-column
  700. v-for="(item, index) in getRowList2"
  701. :key="index"
  702. :label="item.name"
  703. :width="item.width"
  704. :prop="item.label"
  705. align="center"
  706. :show-overflow-tooltip="true"
  707. sortable
  708. :fixed="item.fixed"
  709. >
  710. <template slot-scope="scope">
  711. <span v-if="item.label == 'fBsdate'">{{scope.row.fBsdate ? scope.row.fBsdate.slice(0, 10) : scope.row.fReviewDate}}</span>
  712. <span v-if="item.label == 'fSrcdc' && login == 3">{{ scope.row.fSrcdc == 'D' ? '收' : '付' }}</span>
  713. <span v-else>{{ scope.row[item.label] }}</span>
  714. </template>
  715. </el-table-column>
  716. <!-- <el-table-column label="提单号" align="center" prop="fMblno" />
  717. <el-table-column label="存货单号" align="center" prop="fBscorpno" />
  718. <el-table-column label="品名" align="center" prop="fProductName" />
  719. <el-table-column label="业务日期" align="center" prop="fBsdate">
  720. <template slot-scope="scope" v-if="scope.row.fBsdate">
  721. <span>{{ scope.row.fBsdate.slice(0, 10) }}</span>
  722. </template>
  723. </el-table-column>
  724. <el-table-column label="费用名称" align="center" prop="fFeeName" />
  725. <el-table-column label="收/付" align="center" prop="fSrcdc">
  726. <template slot-scope="scope">
  727. <span v-if="scope.row.fSrcdc == 'D'">收</span>
  728. <span v-else-if="scope.row.fSrcdc == 'C'">付</span>
  729. </template>
  730. </el-table-column>
  731. <el-table-column label="业务类型" align="center" prop="fBilltype">
  732. <template slot-scope="scope">
  733. <span v-if="scope.row.fBilltype == 'SJRK'">入库</span>
  734. <span v-else-if="scope.row.fBilltype == 'SJCK'">出库</span>
  735. <span v-else>{{ scope.row.fBilltype }}</span>
  736. </template>
  737. </el-table-column>
  738. <el-table-column label="作业类型" align="center" prop="fBusinessType" />
  739. <el-table-column label="金额" align="center" prop="fAmtdr" />
  740. <el-table-column label="本次金额" align="center" prop="fAmt" />
  741. <el-table-column label="备注" align="center" prop="fRemarks" /> -->
  742. <el-table-column
  743. label="操作"
  744. align="center"
  745. class-name="small-padding fixed-width"
  746. >
  747. <template slot-scope="scope">
  748. <el-button
  749. size="mini"
  750. type="text"
  751. icon="el-icon-delete"
  752. @click.native.prevent="deleteRow(scope.$index, increase_s)"
  753. :disabled="notChange"
  754. >删除
  755. </el-button>
  756. </template>
  757. </el-table-column>
  758. </el-table>
  759. <div slot="footer" class="dialog-footer">
  760. <add-or-update
  761. v-if="addOrUpdateVisible"
  762. ref="addOrUpdate"
  763. @refreshDataList="getDataList"
  764. ></add-or-update>
  765. <approval-comments
  766. v-if="addOrUpdateVisib"
  767. ref="ApprovalComments"
  768. @refreshDataList="returnData"
  769. ></approval-comments>
  770. </div>
  771. <el-dialog
  772. v-dialogDrag
  773. :fullscreen="dialogFull"
  774. :close-on-click-modal="false"
  775. width="78%"
  776. :visible.sync="innerVisible"
  777. title="导入数据"
  778. append-to-body
  779. >
  780. <template slot="title">
  781. <div class="avue-crud__dialog__header">
  782. <span class="el-dialog__title" style="font-size: 18px;font-weight: bold;color: #606266;">
  783. <span
  784. style="
  785. display: inline-block;
  786. width: 3px;
  787. height: 20px;
  788. margin-right: 5px;
  789. float: left;
  790. margin-top: 2px;
  791. "
  792. ></span>检索
  793. </span>
  794. <div class="avue-crud__dialog__menu enlarge" @click="full">
  795. <i
  796. style="
  797. cursor: pointer;
  798. display: block;
  799. width: 12px;
  800. height: 12px;
  801. border: 1px solid #909399;
  802. border-top: 3px solid #909399;
  803. margin-top: -3px;
  804. "
  805. ></i>
  806. </div>
  807. </div>
  808. </template>
  809. <el-form
  810. ref="form"
  811. :model="queryParameter"
  812. :rules="rules"
  813. label-width="80px"
  814. style="display: flex; flex-wrap: wrap"
  815. >
  816. <el-row>
  817. <el-col :span="6">
  818. <el-form-item label="货权方" prop="fCtrlcorpid">
  819. <!-- <el-input v-model="queryParameter.fCorpid" placeholder="请输入货权方" style="width: 200px;"/>-->
  820. <el-select
  821. v-model="queryParams.fCorpid"
  822. filterable
  823. remote
  824. clearable
  825. size="small"
  826. style="width: 160px"
  827. @keyup.enter.native="handleQuery"
  828. :remote-method="corpsRemoteMethod"
  829. placeholder="请选择货权方"
  830. >
  831. <el-option
  832. v-for="(dict, index) in fMblnoOptions"
  833. :key="index.fId"
  834. :label="dict.fName"
  835. :value="dict.fId"
  836. ></el-option>
  837. </el-select>
  838. </el-form-item>
  839. </el-col>
  840. <el-col :span="6">
  841. <el-form-item label="结算单位" prop="fToCorpid">
  842. <el-select
  843. v-model="queryParameter.fToCorpid"
  844. filterable
  845. remote
  846. clearable
  847. size="small"
  848. style="width: 160px"
  849. :disabled="doNot"
  850. @keyup.enter.native="handleQuery"
  851. :remote-method="corpsRemoteMethod"
  852. placeholder="请输入结算单位"
  853. >
  854. <el-option
  855. v-for="(dict, index) in fMblnoOptions"
  856. :key="index.fId"
  857. :label="dict.fName"
  858. :value="dict.fId"
  859. ></el-option>
  860. </el-select>
  861. </el-form-item>
  862. </el-col>
  863. <el-col :span="6">
  864. <el-form-item label="提单号" prop="fMblno">
  865. <el-input
  866. v-model="queryParameter.fMblno"
  867. placeholder="请输入提单号"
  868. style="width: 160px"
  869. size="small"
  870. />
  871. </el-form-item>
  872. </el-col>
  873. <el-col :span="6">
  874. <el-form-item label="对账单号" prop="fStatementNo">
  875. <el-input
  876. v-model="queryParameter.fStatementNo"
  877. placeholder="请输入提单号"
  878. size="small"
  879. @change="noNull"
  880. style="width: 160px"
  881. />
  882. </el-form-item>
  883. </el-col>
  884. </el-row>
  885. <el-row>
  886. <el-col :span="6">
  887. <el-form-item label="费用名称" prop="fFeeid">
  888. <el-select
  889. v-model="queryParameter.fFeeid"
  890. filterable
  891. remote
  892. size="small"
  893. style="width: 160px"
  894. :remote-method="fWRemoteMethod"
  895. placeholder="费用名称"
  896. multiple
  897. >
  898. <el-option
  899. v-for="item in fWbuOptions"
  900. :key="item.fId"
  901. :label="item.fName"
  902. :value="item.fId"
  903. >
  904. </el-option>
  905. </el-select>
  906. </el-form-item>
  907. </el-col>
  908. <el-col :span="6">
  909. <el-form-item label="仓储业务" prop="fFeeid" v-if="typevalue == 1 || typevalue == 3">
  910. <el-select
  911. v-model="queryParameter.fBilltype"
  912. size="small"
  913. style="width: 160px"
  914. @change="changefBilltype"
  915. placeholder="请选择仓储业务"
  916. >
  917. <el-option label="入库" value="SJRK"></el-option>
  918. <el-option label="出库" value="SJCK"></el-option>
  919. <el-option label="货权转移" value="HQZY"></el-option>
  920. </el-select>
  921. </el-form-item>
  922. </el-col>
  923. <el-col :span="6">
  924. <el-form-item
  925. label="作业类型"
  926. prop="fBusinessType"
  927. v-if="typevalue == 1 || typevalue == 3"
  928. >
  929. <el-select
  930. v-model="queryParameter.fBusinessType"
  931. filterable
  932. remote
  933. size="small"
  934. style="width: 160px"
  935. placeholder="作业类型"
  936. multiple
  937. >
  938. <el-option
  939. v-for="(dict,index) in businessTypeOption"
  940. :key="index"
  941. :label="dict.dictLabel"
  942. :value="dict.dictValue"
  943. >
  944. </el-option>
  945. </el-select>
  946. </el-form-item>
  947. </el-col>
  948. <el-col :span="6" style="width: 240px"></el-col>
  949. </el-row>
  950. <el-row>
  951. <el-col :span="8">
  952. <el-form-item
  953. label="审核日期"
  954. prop="timeExamine"
  955. v-if="typevalue == 1 || typevalue == 3"
  956. >
  957. <el-date-picker
  958. size="small"
  959. style="width: 240px"
  960. v-model="queryParameter.timeExamine"
  961. type="daterange"
  962. start-placeholder="开始日期"
  963. end-placeholder="结束日期"
  964. value-format="yyyy-MM-dd"
  965. :default-time="['00:00:00', '23:59:59']"
  966. >
  967. </el-date-picker>
  968. </el-form-item>
  969. </el-col>
  970. <el-col :span="8">
  971. <el-form-item
  972. label="出入库日期"
  973. label-width="85px"
  974. prop="fAccbilldate"
  975. v-if="typevalue == 1 || typevalue == 3"
  976. >
  977. <el-date-picker
  978. size="small"
  979. style="width: 240px"
  980. v-model="queryParameter.timeInterval"
  981. type="daterange"
  982. start-placeholder="开始日期"
  983. end-placeholder="结束日期"
  984. value-format="yyyy-MM-dd"
  985. :default-time="['00:00:00', '23:59:59']"
  986. >
  987. </el-date-picker>
  988. </el-form-item>
  989. </el-col>
  990. <el-col :span="8" style="width: 320px">
  991. <el-form-item>
  992. </el-form-item>
  993. </el-col>
  994. </el-row>
  995. </el-form>
  996. <div style="margin-right: 20px;float: right">
  997. <el-button
  998. type="cyan"
  999. icon="el-icon-search"
  1000. size="mini"
  1001. @click="importSearch"
  1002. >搜索</el-button
  1003. >
  1004. <el-button icon="el-icon-refresh" size="mini" @click="resetQuery_s"
  1005. >重置</el-button
  1006. >
  1007. <el-button
  1008. icon="el-icon-setting"
  1009. size="mini"
  1010. circle
  1011. @click="showSetting3 = !showSetting3"
  1012. ></el-button>
  1013. </div>
  1014. <el-dialog
  1015. title="自定义列显示"
  1016. :visible.sync="showSetting3"
  1017. width="700px"
  1018. v-dialogDrag
  1019. append-to-body
  1020. >
  1021. <template slot="title">
  1022. <div class="avue-crud__dialog__header">
  1023. <span class="el-dialog__title">
  1024. <span
  1025. style="
  1026. display: inline-block;
  1027. width: 3px;
  1028. height: 20px;
  1029. margin-right: 5px;
  1030. float: left;
  1031. margin-top: 2px;
  1032. "
  1033. ></span>
  1034. </span>
  1035. </div>
  1036. </template>
  1037. <div>配置排序列数据(拖动调整顺序)</div>
  1038. <div style="margin-left: 17px">
  1039. <el-checkbox
  1040. v-model="allCheck3"
  1041. label="全选"
  1042. @change="allChecked3"
  1043. ></el-checkbox>
  1044. </div>
  1045. <div style="padding: 4px; display: flex; justify-content: center">
  1046. <draggable
  1047. v-model="setRowList3"
  1048. group="site"
  1049. animation="300"
  1050. @start="onStart"
  1051. @end="onEnd"
  1052. handle=".indraggable"
  1053. >
  1054. <transition-group>
  1055. <div
  1056. v-for="item in setRowList3"
  1057. :key="item.surface"
  1058. class="listStyle"
  1059. >
  1060. <div style="width: 500px" class="indraggable">
  1061. <div class="progress" :style="{ width: item.width + 'px' }">
  1062. <el-checkbox
  1063. :label="item.name"
  1064. v-model="item.checked"
  1065. :true-label="0"
  1066. :false-label="1"
  1067. >{{ item.name }}
  1068. </el-checkbox>
  1069. </div>
  1070. </div>
  1071. <el-input-number
  1072. v-model.number="item.width"
  1073. controls-position="right"
  1074. :min="1"
  1075. :max="500"
  1076. size="mini"
  1077. ></el-input-number>
  1078. </div>
  1079. </transition-group>
  1080. </draggable>
  1081. </div>
  1082. <span slot="footer" class="dialog-footer">
  1083. <el-button @click="showSetting3 = false">取 消</el-button>
  1084. <el-button @click="delRow3" type="danger">重 置</el-button>
  1085. <el-button type="primary" @click="save3()">确 定</el-button>
  1086. </span>
  1087. </el-dialog>
  1088. <el-table
  1089. v-loading="loading"
  1090. :data="chargeList_s"
  1091. ref="chargeList"
  1092. show-summary
  1093. :summary-method="getSum"
  1094. @selection-change="handleSelectionChange_s"
  1095. >
  1096. <el-table-column type="selection" width="55" align="center" />
  1097. <el-table-column label="序号" type="index" width="55" align="center"/>
  1098. <el-table-column
  1099. v-for="(item, index) in getRowList3"
  1100. :key="index"
  1101. :label="item.name"
  1102. :width="item.width"
  1103. :prop="item.label"
  1104. align="center"
  1105. :fixed="item.fixed"
  1106. :show-overflow-tooltip="true"
  1107. sortable
  1108. >
  1109. <template slot-scope="scope">
  1110. <span v-if="item.label == 'fName'">{{scope.row.fName}}</span>
  1111. <span v-if="item.label == 'fMblno'">{{scope.row.fMblno}}</span>
  1112. <span v-if="item.label == 'fProductName'">{{scope.row.fProductName}}</span>
  1113. <span v-if="item.label == 'fBsdate'">{{scope.row.fBsdate ? scope.row.fBsdate.slice(0, 10) : scope.row.fReviewDate}}</span>
  1114. <span v-if="item.label == 'fBilltype'">
  1115. <template>
  1116. <span v-if="scope.row.fBilltype == 'SJRK'">入库</span>
  1117. <span v-else-if="scope.row.fBilltype == 'SJCK'">出库</span>
  1118. <span v-else-if="scope.row.fBilltype == 'KHDD'">凯和订单</span>
  1119. <span v-else>{{ scope.row.fBilltype }}</span>
  1120. </template>
  1121. </span>
  1122. <span v-if="item.label == 'fBusinessType'">{{scope.row.fBusinessType}}</span>
  1123. <span v-if="item.label == 'fReviewDate'">{{scope.row.fReviewDate}}</span>
  1124. <span v-if="item.label == 'fFeeName'">{{scope.row.fFeeName}}</span>
  1125. <span v-if="item.label == 'fAmtdr'">{{scope.row.fAmtdr}}</span>
  1126. <el-input
  1127. v-model="scope.row.fAmt" v-if="item.label == 'fAmt'"
  1128. oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'
  1129. @change="imgChangeI(scope.row)"/>
  1130. <el-input v-model="scope.row.fRemarks" v-if="item.label == 'fRemarks'"/>
  1131. </template>
  1132. </el-table-column>
  1133. <!-- <el-table-column label="货权方" align="center" prop="fName" width="200px" show-overflow-tooltip/>-->
  1134. <!-- <el-table-column label="提单号" align="center" prop="fMblno" />-->
  1135. <!-- <el-table-column v-if="typevalue == 1 || typevalue == 2" label="品名" align="center" prop="fProductName" />-->
  1136. <!-- <el-table-column v-if="typevalue == 1 || typevalue == 2" label="业务日期" align="center">-->
  1137. <!-- <template slot-scope="scope" v-if="scope.row.fBsdate">-->
  1138. <!-- <span>{{ scope.row.fBsdate.slice(0, 10) }}</span>-->
  1139. <!-- </template>-->
  1140. <!-- </el-table-column>-->
  1141. <!-- <el-table-column label="业务类型" align="center" prop="fBilltype">-->
  1142. <!-- <template slot-scope="scope">-->
  1143. <!-- <span v-if="scope.row.fBilltype == 'SJRK'">入库</span>-->
  1144. <!-- <span v-else-if="scope.row.fBilltype == 'SJCK'">出库</span>-->
  1145. <!-- <span v-else>{{ scope.row.fBilltype }}</span>-->
  1146. <!-- </template>-->
  1147. <!-- </el-table-column>-->
  1148. <!-- <el-table-column-->
  1149. <!-- label="作业类型"-->
  1150. <!-- align="center"-->
  1151. <!-- prop="fBusinessType"-->
  1152. <!-- />-->
  1153. <!-- <el-table-column label="审核日期" align="center" prop="fReviewDate" width="100px"/>-->
  1154. <!-- <el-table-column label="费用名称" align="center" prop="fFeeName" width="100px" show-overflow-tooltip/>-->
  1155. <!-- <el-table-column label="金额" align="center" prop="fAmtdr" />-->
  1156. <!-- <el-table-column-->
  1157. <!-- label="本次金额"-->
  1158. <!-- align="center"-->
  1159. <!-- prop="fAmt"-->
  1160. <!-- width="100"-->
  1161. <!-- >-->
  1162. <!-- <template slot-scope="scope">-->
  1163. <!-- <el-input-->
  1164. <!-- v-model="scope.row.fAmt"-->
  1165. <!-- placeholder="请输入本次金额"-->
  1166. <!-- clearable-->
  1167. <!-- size="small"-->
  1168. <!-- oninput='this.value=this.value.replace(/[^\-?\d.]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3")'-->
  1169. <!-- @change="imgChangeI(scope.row)"-->
  1170. <!-- />-->
  1171. <!-- </template>-->
  1172. <!-- </el-table-column>-->
  1173. <!-- <el-table-column label="备注" align="center" prop="fRemarks">-->
  1174. <!-- <template slot-scope="scope">-->
  1175. <!-- <el-input-->
  1176. <!-- v-model="scope.row.fRemarks"-->
  1177. <!-- placeholder="请输入备注"-->
  1178. <!-- clearable-->
  1179. <!-- size="small"-->
  1180. <!-- width="100"-->
  1181. <!-- />-->
  1182. <!-- </template>-->
  1183. <!-- </el-table-column>-->
  1184. </el-table>
  1185. <div slot="footer" class="dialog-footer">
  1186. <el-button type="primary" @click="confirmImport">确 定</el-button>
  1187. <el-button @click="signOut">取 消</el-button>
  1188. </div>
  1189. </el-dialog>
  1190. </div>
  1191. <!-- 打印页面-->
  1192. <!-- <el-dialog-->
  1193. <!-- :visible.sync="printStatus"-->
  1194. <!-- width="80%"-->
  1195. <!-- :before-close="closePrinting"-->
  1196. <!-- >-->
  1197. <!-- <el-table-->
  1198. <!-- id="print_area2"-->
  1199. <!-- v-loading="loading"-->
  1200. <!-- ref="table"-->
  1201. <!-- :data="printObject"-->
  1202. <!-- @selection-change="handleSelectionChange_s"-->
  1203. <!-- >-->
  1204. <!-- &lt;!&ndash; <el-table-column type="selection" width="55" align="center"/> &ndash;&gt;-->
  1205. <!-- <el-table-column label="序号" type="index" width="70" align="center" />-->
  1206. <!-- <el-table-column-->
  1207. <!-- label="提单号"-->
  1208. <!-- align="center"-->
  1209. <!-- prop="fMblno"-->
  1210. <!-- width="120"-->
  1211. <!-- />-->
  1212. <!-- <el-table-column-->
  1213. <!-- label="存货单号"-->
  1214. <!-- align="center"-->
  1215. <!-- prop="fBscorpno"-->
  1216. <!-- width="120"-->
  1217. <!-- />-->
  1218. <!-- <el-table-column-->
  1219. <!-- label="品名"-->
  1220. <!-- align="center"-->
  1221. <!-- prop="fProductName"-->
  1222. <!-- width="120"-->
  1223. <!-- />-->
  1224. <!-- <el-table-column-->
  1225. <!-- label="业务日期"-->
  1226. <!-- align="center"-->
  1227. <!-- prop="fBsdate"-->
  1228. <!-- width="120"-->
  1229. <!-- >-->
  1230. <!-- <template slot-scope="scope" v-if="scope.row.fBsdate">-->
  1231. <!-- <span>{{ scope.row.fBsdate.slice(0, 10) }}</span>-->
  1232. <!-- </template>-->
  1233. <!-- </el-table-column>-->
  1234. <!-- <el-table-column-->
  1235. <!-- label="费用名称"-->
  1236. <!-- align="center"-->
  1237. <!-- prop="fFeeName"-->
  1238. <!-- width="120"-->
  1239. <!-- />-->
  1240. <!-- <el-table-column label="收/付" align="center" prop="fSrcdc" width="120">-->
  1241. <!-- <template slot-scope="scope">-->
  1242. <!-- <span v-if="scope.row.fSrcdc == 'D'">收</span>-->
  1243. <!-- <span v-else-if="scope.row.fSrcdc == 'C'">付</span>-->
  1244. <!-- </template>-->
  1245. <!-- </el-table-column>-->
  1246. <!-- <el-table-column-->
  1247. <!-- label="业务类型"-->
  1248. <!-- align="center"-->
  1249. <!-- prop="fBilltype"-->
  1250. <!-- width="120"-->
  1251. <!-- >-->
  1252. <!-- <template slot-scope="scope">-->
  1253. <!-- <span v-if="scope.row.fBilltype == 'SJRK'">入库</span>-->
  1254. <!-- <span v-else-if="scope.row.fBilltype == 'SJCK'">出库</span>-->
  1255. <!-- <span v-else>{{ scope.row.fBilltype }}</span>-->
  1256. <!-- </template>-->
  1257. <!-- </el-table-column>-->
  1258. <!-- <el-table-column label="作业类型" align="center" prop="fBusinessType" />-->
  1259. <!-- <el-table-column-->
  1260. <!-- label="金额"-->
  1261. <!-- align="center"-->
  1262. <!-- prop="fAmtdr"-->
  1263. <!-- width="120"-->
  1264. <!-- />-->
  1265. <!-- <el-table-column-->
  1266. <!-- label="本次金额"-->
  1267. <!-- align="center"-->
  1268. <!-- prop="fAmt"-->
  1269. <!-- width="120"-->
  1270. <!-- />-->
  1271. <!-- </el-table>-->
  1272. <!-- <span slot="footer" class="dialog-footer">-->
  1273. <!-- <el-button-->
  1274. <!-- type="primary"-->
  1275. <!-- style="margintop: 10px"-->
  1276. <!-- @click="printSomething"-->
  1277. <!-- >打印</el-button-->
  1278. <!-- >-->
  1279. <!-- <el-button @click="printStatus = false">取 消</el-button>-->
  1280. <!-- </span>-->
  1281. <!-- </el-dialog>-->
  1282. </div>
  1283. </template>
  1284. <script>
  1285. import {
  1286. collectFee,
  1287. collectFees,
  1288. listCharge,
  1289. listCharges,
  1290. getCharge,
  1291. getCharges,
  1292. delCharge,
  1293. delCharges,
  1294. addCharge,
  1295. addCharges,
  1296. exportCharge,
  1297. search,
  1298. searchs,
  1299. listCorps,
  1300. delCharge_s,
  1301. delCharge_ss,
  1302. backCharge,
  1303. revocation,
  1304. exportWarehousebillsitems,
  1305. } from "@/api/finance/charge";
  1306. import { listFees } from "@/api/basicdata/fees";
  1307. import print from "print-js";
  1308. import AddOrUpdate from "@/views/viewApproval";
  1309. import ApprovalComments from "@/views/startApproval";
  1310. import { queryUserVal } from "@/api/warehouseBusiness/agreement";
  1311. import Global from "@/layout/components/global";
  1312. import Vue from "vue";
  1313. import Cookies from "js-cookie";
  1314. import draggable from "vuedraggable";
  1315. import { addSet, select,resetModule } from "@/api/system/set";
  1316. import { MessageBox } from 'element-ui'
  1317. Vue.directive("dialogDrag", {
  1318. bind(el, binding, vnode, oldVnode) {
  1319. const dialogHeaderEl = el.querySelector(".el-dialog__header");
  1320. const dragDom = el.querySelector(".el-dialog");
  1321. const enlarge = el.querySelector(".enlarge");
  1322. dialogHeaderEl.style.cursor = "move";
  1323. // 获取原有属性 ie dom元素.currentStyle 火狐谷歌 window.getComputedStyle(dom元素, null);
  1324. const sty = dragDom.currentStyle || window.getComputedStyle(dragDom, null);
  1325. if (enlarge) {
  1326. enlarge.onclick = (e) => {
  1327. dragDom.style.top = "0px";
  1328. dragDom.style.left = "0px";
  1329. };
  1330. }
  1331. dialogHeaderEl.onmousedown = (e) => {
  1332. // 鼠标按下,计算当前元素距离可视区的距离
  1333. const disX = e.clientX - dialogHeaderEl.offsetLeft;
  1334. const disY = e.clientY - dialogHeaderEl.offsetTop;
  1335. // 获取到的值带px 正则匹配替换
  1336. let styL, styT;
  1337. // 注意在ie中 第一次获取到的值为组件自带50% 移动之后赋值为px
  1338. if (sty.left.includes("%")) {
  1339. styL =
  1340. +document.body.clientWidth * (+sty.left.replace(/\%/g, "") / 100);
  1341. styT =
  1342. +document.body.clientHeight * (+sty.top.replace(/\%/g, "") / 100);
  1343. } else {
  1344. styL = +sty.left.replace(/\px/g, "");
  1345. styT = +sty.top.replace(/\px/g, "");
  1346. }
  1347. document.onmousemove = function (e) {
  1348. // 通过事件委托,计算移动的距离
  1349. const l = e.clientX - disX;
  1350. const t = e.clientY - disY;
  1351. // 移动当前元素
  1352. if (t + styT >= 0) {
  1353. dragDom.style.top = `${t + styT}px`;
  1354. }
  1355. dragDom.style.left = `${l + styL}px`;
  1356. // 将此时的位置传出去
  1357. // binding.value({x:e.pageX,y:e.pageY})
  1358. };
  1359. document.onmouseup = function (e) {
  1360. document.onmousemove = null;
  1361. document.onmouseup = null;
  1362. };
  1363. };
  1364. },
  1365. });
  1366. export default {
  1367. name: "Charge",
  1368. data() {
  1369. return {
  1370. login:Cookies.get('sysType'),
  1371. show:false,
  1372. mainTable:false,
  1373. //全屏放大
  1374. dialogFull: false,
  1375. drag: false,
  1376. tableDate: [
  1377. {
  1378. surface: "1",
  1379. label: "createBy",
  1380. name: "制单人",
  1381. checked: 0,
  1382. fixed: "left",
  1383. width: 100,
  1384. },
  1385. {
  1386. surface: "2",
  1387. label: "fBillno",
  1388. name: "系统编号",
  1389. checked: 0,
  1390. fixed: "left",
  1391. width: 100,
  1392. },
  1393. {
  1394. surface: "3",
  1395. label: "fCtrlcorpid",
  1396. name: "货权方",
  1397. checked: 0,
  1398. width: 100,
  1399. },
  1400. {
  1401. surface: "4",
  1402. label: "createTime",
  1403. name: "制单日期",
  1404. checked: 0,
  1405. width: 100,
  1406. },
  1407. {
  1408. surface: "5",
  1409. label: "fAccbilldate",
  1410. name: "收费日期",
  1411. checked: 0,
  1412. width: 100,
  1413. },
  1414. {
  1415. surface: "6",
  1416. label: "fMblno",
  1417. name: "提单号",
  1418. checked: 0,
  1419. width: 100,
  1420. },
  1421. {
  1422. surface: "7",
  1423. label: "chargingMethod",
  1424. name: "收费方式",
  1425. checked: 0,
  1426. width: 100,
  1427. },
  1428. {
  1429. surface: "8",
  1430. label: "invoiceNo",
  1431. name: "发票号",
  1432. checked: 0,
  1433. width: 100,
  1434. },
  1435. {
  1436. surface: "9",
  1437. label: "bank",
  1438. name: "收款银行",
  1439. checked: 0,
  1440. width: 100,
  1441. },
  1442. {
  1443. surface: "10",
  1444. label: "waterBillNo",
  1445. name: "水单号",
  1446. checked: 0,
  1447. width: 100,
  1448. },
  1449. {
  1450. surface: "11",
  1451. label: "fAmtdr",
  1452. name: "应收合计",
  1453. checked: 0,
  1454. width: 100,
  1455. },
  1456. {
  1457. surface: "12",
  1458. label: "fAmtcr",
  1459. name: "实收合计",
  1460. checked: 0,
  1461. width: 100,
  1462. },
  1463. {
  1464. surface: "13",
  1465. label: "fRemarks",
  1466. name: "备注",
  1467. checked: 0,
  1468. width: 100,
  1469. },
  1470. {
  1471. surface: "14",
  1472. label: "fBillstatus",
  1473. name: "状态",
  1474. checked: 0,
  1475. width: 100,
  1476. },
  1477. ],
  1478. tableDate2: [
  1479. {
  1480. surface: "1",
  1481. label: "fMblno",
  1482. name: "提单号",
  1483. checked: 0,
  1484. width: 100,
  1485. },
  1486. {
  1487. surface: "2",
  1488. label: "fBscorpno",
  1489. name: "存货单号",
  1490. checked: 0,
  1491. width: 100,
  1492. },
  1493. {
  1494. surface: "3",
  1495. label: "fProductName",
  1496. name: "品名",
  1497. checked: 0,
  1498. width: 100,
  1499. },
  1500. {
  1501. surface: "4",
  1502. label: "fBsdate",
  1503. name: "业务日期",
  1504. checked: 0,
  1505. width: 100,
  1506. },
  1507. {
  1508. surface: "5",
  1509. label: "fFeeName",
  1510. name: "费用名称",
  1511. checked: 0,
  1512. width: 100,
  1513. },
  1514. {
  1515. surface: "6",
  1516. label: "fSrcdc",
  1517. name: "收/付",
  1518. checked: 0,
  1519. width: 100,
  1520. },
  1521. {
  1522. surface: "7",
  1523. label: "fBilltype",
  1524. name: "业务类型",
  1525. checked: 0,
  1526. width: 100,
  1527. },
  1528. {
  1529. surface: "8",
  1530. label: "fBusinessType",
  1531. name: "作业类型",
  1532. checked: 0,
  1533. width: 100,
  1534. },
  1535. {
  1536. surface: "9",
  1537. label: "fAmtdr",
  1538. name: "金额",
  1539. checked: 0,
  1540. width: 100,
  1541. },
  1542. {
  1543. surface: "10",
  1544. label: "fAmt",
  1545. name: "本次金额",
  1546. checked: 0,
  1547. width: 100,
  1548. },
  1549. {
  1550. surface: "11",
  1551. label: "fRemarks",
  1552. name: "备注",
  1553. checked: 0,
  1554. width: 100,
  1555. },
  1556. ],
  1557. tableDate3: [
  1558. {
  1559. surface: "1",
  1560. label: "fName",
  1561. name: "货权方",
  1562. checked: 0,
  1563. width: 100,
  1564. },
  1565. {
  1566. surface: "2",
  1567. label: "fMblno",
  1568. name: "提单号",
  1569. checked: 0,
  1570. width: 100,
  1571. },
  1572. {
  1573. surface: "3",
  1574. label: "fProductName",
  1575. name: "品名",
  1576. checked: 0,
  1577. width: 100,
  1578. },
  1579. {
  1580. surface: "4",
  1581. label: "fBsdate",
  1582. name: "业务日期",
  1583. checked: 0,
  1584. width: 100,
  1585. },
  1586. {
  1587. surface: "5",
  1588. label: "fBilltype",
  1589. name: "业务类型",
  1590. checked: 0,
  1591. width: 100,
  1592. },
  1593. {
  1594. surface: "6",
  1595. label: "fBusinessType",
  1596. name: "作业类型",
  1597. checked: 0,
  1598. width: 100,
  1599. },
  1600. {
  1601. surface: "7",
  1602. label: "fReviewDate",
  1603. name: "审核日期",
  1604. checked: 0,
  1605. width: 100,
  1606. },
  1607. {
  1608. surface: "8",
  1609. label: "fFeeName",
  1610. name: "费用名称",
  1611. checked: 0,
  1612. width: 100,
  1613. },
  1614. {
  1615. surface: "9",
  1616. label: "fAmtdr",
  1617. name: "金额",
  1618. checked: 0,
  1619. width: 100,
  1620. },
  1621. {
  1622. surface: "10",
  1623. label: "fAmt",
  1624. name: "本次金额",
  1625. checked: 0,
  1626. width: 100,
  1627. },
  1628. {
  1629. surface: "11",
  1630. label: "fRemarks",
  1631. name: "备注",
  1632. checked: 0,
  1633. width: 100,
  1634. },
  1635. ],
  1636. setRowList: [],
  1637. getRowList: [],
  1638. setRowList2: [],
  1639. getRowList2: [],
  1640. allCheck2: false,
  1641. showSetting2: false,
  1642. setRowList3: [],
  1643. getRowList3: [],
  1644. allCheck3: false,
  1645. showSetting3: false,
  1646. typevalue: "",
  1647. typeoptions: [
  1648. {
  1649. value: "1",
  1650. label: "仓储",
  1651. },
  1652. {
  1653. value: "2",
  1654. label: "车队",
  1655. },
  1656. {
  1657. value: "3",
  1658. label: "船务",
  1659. }
  1660. ],
  1661. allCheck: false,
  1662. showSetting: false,
  1663. //收费方式
  1664. methodOptions: [],
  1665. doNot: false,
  1666. Lander: "",
  1667. Operator: "",
  1668. approve: false,
  1669. addOrUpdateVisible: false,
  1670. businessTypeOption: [],
  1671. contrastId: 220,
  1672. tablefilter: false,
  1673. hide: false,
  1674. openPrint: false,
  1675. notChange: false,
  1676. browseStatus: true,
  1677. nothing: [],
  1678. //打印表
  1679. printObject: [],
  1680. printStatus: false,
  1681. //导入状态
  1682. state_s: true,
  1683. fWbuOptions: [],
  1684. options: "",
  1685. // 遮罩层
  1686. loading: true,
  1687. //打开内部弹窗
  1688. innerVisible: false,
  1689. chargeList_s: [],
  1690. selection: "",
  1691. increase_s: [],
  1692. cancelButton: true,
  1693. // 选中数组
  1694. ids: [],
  1695. // 非单个禁用
  1696. single: true,
  1697. // 非多个禁用
  1698. multiple: true,
  1699. // 显示搜索条件
  1700. showSearch: true,
  1701. // 总条数
  1702. total: 0,
  1703. totAL: 0,
  1704. Ttime: 0,
  1705. //提单号暂存
  1706. fMblno: "",
  1707. // 财务数据主表格数据
  1708. chargeList: [],
  1709. // 弹出层标题
  1710. title: "",
  1711. // 是否显示弹出层
  1712. open: false,
  1713. fMblnoOptions: "",
  1714. //导入查询参数
  1715. queryParameter: {
  1716. fCorpid: "",
  1717. fToCorpid: "",
  1718. fMblno: "",
  1719. fStatementNo: "",
  1720. fFeeid: "",
  1721. timeExamine: "",
  1722. timeInterval: "",
  1723. fBilltype: "",
  1724. fBusinessType: "",
  1725. },
  1726. empty: [],
  1727. //导入从表传主表
  1728. pass: {
  1729. fAmtdr: 0, //应收合计
  1730. fAmtcr: 0, //应付合计
  1731. fMblno: "", //提单号
  1732. fName: "", //货权方
  1733. },
  1734. Xbutton: true,
  1735. // 查询参数
  1736. queryParams: {
  1737. fId: null,
  1738. pageNum: 1,
  1739. pageSize: 10,
  1740. fBillno: null,
  1741. fCtrlcorpid: null,
  1742. fCorpid: null,
  1743. fMblno: null,
  1744. fAmtdr: null,
  1745. fAmtcr: null,
  1746. fBilltype: null,
  1747. fBillstatus: null,
  1748. fRemarks: null,
  1749. fAccbilldate: null,
  1750. fDeptid: null,
  1751. chargingMethod: null,
  1752. invoiceNo: null,
  1753. bank: null,
  1754. waterBillNo: null,
  1755. },
  1756. addOrUpdateVisib: false,
  1757. // 主表查询参数
  1758. tableFilter: {
  1759. pageNum: 1,
  1760. pageSize: 10,
  1761. fBillno: null,
  1762. fCtrlcorpid: null,
  1763. fCorpid: null,
  1764. fBillstatus: null,
  1765. amount: [],
  1766. firstMoney: null,
  1767. lastMoney: null,
  1768. fRemarks: null,
  1769. timeInterval:null
  1770. },
  1771. approval: [],
  1772. // 表单参数
  1773. form: {},
  1774. // 表单校验
  1775. ruless: {
  1776. fCtrlcorpid: [{ required: true, message: " ", trigger: "blur" }],
  1777. fCorpid: [{ required: true, message: " ", trigger: "blur" }],
  1778. fAccbilldate: [{ required: true, message: " ", trigger: "blur" }],
  1779. },
  1780. // 表单校验
  1781. rules: {
  1782. fBilltype: [{ required: true, message: " ", trigger: "change" }],
  1783. fBillstatus: [{ required: true, message: " ", trigger: "blur" }],
  1784. fDeptid: [{ required: true, message: " ", trigger: "blur" }],
  1785. fToCorpid: [{ required: true, message: " ", trigger: "blur" }],
  1786. timeExamine: [{ required: true, message: " ", trigger: "blur" }],
  1787. },
  1788. };
  1789. },
  1790. components: {
  1791. AddOrUpdate,
  1792. ApprovalComments,
  1793. draggable
  1794. },
  1795. created() {
  1796. this.setRowList = this.tableDate;
  1797. this.getRowList = this.tableDate;
  1798. this.setRowList2 = this.tableDate2;
  1799. this.getRowList2 = this.tableDate2;
  1800. this.setRowList3 = this.tableDate3;
  1801. this.getRowList3 = this.tableDate3;
  1802. this.typevalue = Cookies.get("sysType");
  1803. this.getList();
  1804. this.register();
  1805. this.getDicts("st_in_type").then((response) => {
  1806. this.businessTypeOption = response.data;
  1807. });
  1808. this.getDicts("data_settlement_type").then((response) => {
  1809. this.methodOptions = response.data;
  1810. });
  1811. this.getRow();
  1812. // this.getRow2();
  1813. this.getRow3();
  1814. this.corpsRemoteMethod()
  1815. },
  1816. activated() {
  1817. if(this.$route.query.data){
  1818. let data = JSON.parse(this.$route.query.data)
  1819. if(data.key === 1){
  1820. this.handleAdd()
  1821. }else{
  1822. this.adoPt();
  1823. }
  1824. }
  1825. },
  1826. methods: {
  1827. changeMoney(){
  1828. if(parseInt(this.tableFilter.lastMoney) < parseInt(this.tableFilter.firstMoney)){
  1829. this.$message.error("第二个金额不能小于第一个金额,请重新输入")
  1830. this.tableFilter.lastMoney = ''
  1831. }
  1832. },
  1833. noNull(){
  1834. if(this.queryParameter.fStatementNo == ''){
  1835. this.rules = {
  1836. fToCorpid: [{ required: true, message: " ", trigger: "blur" }],
  1837. timeExamine: [{ required: true, message: " ", trigger: "blur" }],
  1838. };
  1839. }
  1840. },
  1841. addPage(){
  1842. MessageBox.confirm("是否已保存?",{
  1843. confirmButtonText: '确定',
  1844. cancelButtonText: '取消',
  1845. type: 'warning'
  1846. }
  1847. ).then(()=> {
  1848. this.handleAdd()
  1849. })
  1850. },
  1851. //导出明细
  1852. handleExportItems() {
  1853. const fIds = this.queryParams.fId;
  1854. if (fIds !== null) {
  1855. this.$confirm("是否确认导出所有计费物资明细数据?", "警告", {
  1856. confirmButtonText: "确定",
  1857. cancelButtonText: "取消",
  1858. type: "warning",
  1859. })
  1860. .then(function () {
  1861. return exportWarehousebillsitems(fIds);
  1862. })
  1863. .then((response) => {
  1864. this.download(response.msg);
  1865. });
  1866. } else {
  1867. this.$message("请先保存");
  1868. }
  1869. },
  1870. full() {
  1871. this.dialogFull = !this.dialogFull;
  1872. },
  1873. //列设置全选
  1874. allChecked() {
  1875. if (this.allCheck == true) {
  1876. this.setRowList.map((e) => {
  1877. return (e.checked = 0);
  1878. });
  1879. } else {
  1880. this.setRowList.map((e) => {
  1881. return (e.checked = 1);
  1882. });
  1883. }
  1884. },
  1885. //查询列数据
  1886. getRow() {
  1887. let that = this;
  1888. this.data = {
  1889. tableName: "-收费",
  1890. userId: Cookies.get("userName"),
  1891. };
  1892. select(this.data).then((res) => {
  1893. if (res.data.length != 0) {
  1894. this.getRowList = res.data.filter((e) => e.checked == 0);
  1895. this.setRowList = res.data;
  1896. this.setRowList = this.setRowList.reduce((res, item) => {
  1897. res.push({
  1898. surface: item.surface,
  1899. label: item.label,
  1900. name: item.name,
  1901. checked: item.checked,
  1902. width: item.width,
  1903. fixed: item.fixed,
  1904. });
  1905. return res;
  1906. }, []);
  1907. }
  1908. });
  1909. },
  1910. //保存列设置
  1911. save() {
  1912. this.showSetting = false;
  1913. this.data = {
  1914. tableName: "-收费",
  1915. userId: Cookies.get("userName"),
  1916. sysTableSetList: this.setRowList,
  1917. };
  1918. addSet(this.data).then((res) => {
  1919. this.getRowList = this.setRowList.filter((e) => e.checked == 0);
  1920. });
  1921. },
  1922. //重置列表
  1923. delRow() {
  1924. this.data = {
  1925. tableName: "-收费",
  1926. userId: Cookies.get("userName"),
  1927. };
  1928. resetModule(this.data).then((res) => {
  1929. if (res.code == 200) {
  1930. this.showSetting = false;
  1931. this.setRowList = this.getRowList = this.$options.data().tableDate
  1932. }
  1933. });
  1934. },
  1935. //列设置全选
  1936. allChecked2() {
  1937. if (this.allCheck2 == true) {
  1938. this.setRowList2.map((e) => {
  1939. return (e.checked = 0);
  1940. });
  1941. } else {
  1942. this.setRowList2.map((e) => {
  1943. return (e.checked = 1);
  1944. });
  1945. }
  1946. },
  1947. //查询列数据
  1948. getRow2() {
  1949. let that = this;
  1950. this.data = {
  1951. tableName: "收费明细",
  1952. userId: Cookies.get("userName"),
  1953. };
  1954. select(this.data).then((res) => {
  1955. if (res.data.length != 0) {
  1956. this.getRowList2 = res.data.filter((e) => e.checked == 0);
  1957. this.setRowList2 = res.data;
  1958. this.setRowList2 = this.setRowList2.reduce((res, item) => {
  1959. res.push({
  1960. surface: item.surface,
  1961. label: item.label,
  1962. name: item.name,
  1963. checked: item.checked,
  1964. width: item.width,
  1965. fixed: item.fixed,
  1966. });
  1967. return res;
  1968. }, []);
  1969. }
  1970. });
  1971. },
  1972. //保存列设置
  1973. save2() {
  1974. this.showSetting2 = false;
  1975. this.data = {
  1976. tableName: "收费明细",
  1977. userId: Cookies.get("userName"),
  1978. sysTableSetList: this.setRowList2,
  1979. };
  1980. addSet(this.data).then((res) => {
  1981. this.getRowList2 = this.setRowList2.filter((e) => e.checked == 0);
  1982. });
  1983. },
  1984. //重置列表
  1985. delRow2() {
  1986. this.data = {
  1987. tableName: "收费明细",
  1988. userId: Cookies.get("userName"),
  1989. };
  1990. resetModule(this.data).then((res) => {
  1991. if (res.code == 200) {
  1992. this.showSetting2 = false;
  1993. this.setRowList2 = this.getRowList2 = this.$options.data().tableDate2
  1994. }
  1995. });
  1996. },
  1997. //列设置全选
  1998. allChecked3() {
  1999. if (this.allCheck3 == true) {
  2000. this.setRowList3.map((e) => {
  2001. return (e.checked = 0);
  2002. });
  2003. } else {
  2004. this.setRowList3.map((e) => {
  2005. return (e.checked = 1);
  2006. });
  2007. }
  2008. },
  2009. //查询列数据
  2010. getRow3() {
  2011. let that = this;
  2012. this.data = {
  2013. tableName: "收费明细",
  2014. userId: Cookies.get("userName"),
  2015. };
  2016. select(this.data).then((res) => {
  2017. if (res.data.length != 0) {
  2018. this.getRowList3 = res.data.filter((e) => e.checked == 0);
  2019. this.setRowList3 = res.data;
  2020. this.setRowList3 = this.setRowList3.reduce((res, item) => {
  2021. res.push({
  2022. surface: item.surface,
  2023. label: item.label,
  2024. name: item.name,
  2025. checked: item.checked,
  2026. width: item.width,
  2027. fixed: item.fixed,
  2028. });
  2029. return res;
  2030. }, []);
  2031. }
  2032. });
  2033. },
  2034. //保存列设置
  2035. save3() {
  2036. this.showSetting3 = false;
  2037. this.data = {
  2038. tableName: "收费明细",
  2039. userId: Cookies.get("userName"),
  2040. sysTableSetList: this.setRowList3,
  2041. };
  2042. addSet(this.data).then((res) => {
  2043. this.getRowList3 = this.setRowList3.filter((e) => e.checked == 0);
  2044. });
  2045. },
  2046. //重置列表
  2047. delRow3() {
  2048. this.data = {
  2049. tableName: "收费明细",
  2050. userId: Cookies.get("userName"),
  2051. };
  2052. resetModule(this.data).then((res) => {
  2053. if (res.code == 200) {
  2054. this.showSetting3 = false;
  2055. this.setRowList3 = this.getRowList3 = this.$options.data().tableDate3
  2056. }
  2057. });
  2058. },
  2059. //开始拖拽事件
  2060. onStart() {
  2061. this.drag = true;
  2062. },
  2063. //拖拽结束事件
  2064. onEnd() {
  2065. this.drag = false;
  2066. },
  2067. //财务主取消
  2068. signOut() {
  2069. if (this.increase_s.length == 0) {
  2070. this.doNot = false;
  2071. } else {
  2072. this.doNot = true;
  2073. }
  2074. this.innerVisible = false;
  2075. this.feeList = [];
  2076. },
  2077. //收费页面合计
  2078. listTotal(param) {
  2079. const { columns, data } = param;
  2080. const sums = [];
  2081. columns.forEach((column, index) => {
  2082. if (index === 0) {
  2083. sums[index] = "合计";
  2084. } else if (column.label == '应收合计' || column.label == '实收合计' || column.label == '金额' || column.label == '本次金额') {
  2085. const values = data.map((item) => Number(item[column.property]));
  2086. if (!values.every((value) => isNaN(value))) {
  2087. sums[index] = values.reduce((prev, curr) => {
  2088. const value = Number(curr);
  2089. if (!isNaN(value)) {
  2090. return prev + curr;
  2091. } else {
  2092. return prev;
  2093. }
  2094. }, 0);
  2095. }
  2096. }
  2097. });
  2098. return sums;
  2099. },
  2100. approvalRevocation(status) {
  2101. if(Cookies.get("sysType") == 3){
  2102. let data = {
  2103. id: this.queryParams.fId,
  2104. actId: 440,
  2105. billId: this.queryParams.fId,
  2106. fidStatus: status,
  2107. };
  2108. revocation(data).then((data) => {
  2109. if (data.code === 200) {
  2110. this.$message.success("撤销成功");
  2111. this.mainTable = false
  2112. this.open = false;
  2113. this.getList();
  2114. }
  2115. });
  2116. }else{
  2117. let data = {
  2118. id: this.queryParams.fId,
  2119. actId: this.contrastId,
  2120. billId: this.queryParams.fId,
  2121. fidStatus: status,
  2122. };
  2123. revocation(data).then((data) => {
  2124. if (data.code === 200) {
  2125. this.$message.success("撤销成功");
  2126. this.open = false;
  2127. this.getList();
  2128. }
  2129. });
  2130. }
  2131. },
  2132. returnData() {
  2133. this.addOrUpdateVisib = false;
  2134. this.open = false;
  2135. this.homepaGe();
  2136. },
  2137. getDataList() {
  2138. this.addOrUpdateVisible = false;
  2139. },
  2140. changefBilltype() {
  2141. this.businessTypeOption = [];
  2142. if (this.queryParameter.fBilltype == "SJRK") {
  2143. this.getDicts("st_in_type").then((response) => {
  2144. this.businessTypeOption = response.data;
  2145. });
  2146. } else if (this.queryParameter.fBilltype == "SJCK") {
  2147. this.getDicts("st_out_type").then((response) => {
  2148. this.businessTypeOption = response.data;
  2149. });
  2150. } else if (this.queryParameter.fBilltype == "HQZY") {
  2151. this.getDicts("st_trans_type").then((response) => {
  2152. this.businessTypeOption = response.data;
  2153. });
  2154. }
  2155. },
  2156. homepaGe() {
  2157. let view = {
  2158. fullPath: "/finance/charge",
  2159. hash: "",
  2160. matched: Array(2),
  2161. meta: Object,
  2162. name: "Charge",
  2163. params: Object,
  2164. path: "/finance/charge",
  2165. query: Object,
  2166. title: "收费",
  2167. };
  2168. this.$router.push({ path: "/index" });
  2169. this.$store
  2170. .dispatch("tagsView/delView", view)
  2171. .then(({ visitedViews }) => {
  2172. if (this.isActive(view)) {
  2173. this.toLastView(visitedViews, view);
  2174. }
  2175. });
  2176. Global.$emit("removeCache", "closeSelectedTag", view);
  2177. },
  2178. adoPt() {
  2179. this.approval = this.$route.query.data;
  2180. if (this.approval) {
  2181. this.doNot = true
  2182. this.Xbutton = false;
  2183. this.approval = JSON.parse(this.approval);
  2184. this.hide = false;
  2185. this.tablefilter = true;
  2186. this.notChange = true;
  2187. this.approve = true;
  2188. this.cancelButton = false;
  2189. this.reset();
  2190. this.pass = {
  2191. fAmtdr: 0, //应收合计
  2192. fAmtcr: 0, //应付合计
  2193. fMblno: "", //提单号
  2194. fName: "", //货权方
  2195. fFeesName: "", //结算单位
  2196. fCorpid: "", //结算单位ID
  2197. };
  2198. if(Cookies.get("sysType") == 1 || Cookies.get("sysType") == 2){
  2199. getCharge(this.approval.billId).then((response) => {
  2200. this.Operator = response.data.tFee.createBy;
  2201. if (response.data.feeDoList != 0) {
  2202. response.data.feeDoList.map((e) => {
  2203. if (e.fBsdate) {
  2204. e.fBsdate = e.fBsdate.slice(0, 10);
  2205. }
  2206. if (e.fSrcdc) {
  2207. if (e.fSrcdc == "D") {
  2208. e.fSrcdc = "收";
  2209. } else {
  2210. e.fSrcdc = "付";
  2211. }
  2212. }
  2213. });
  2214. }
  2215. this.increase_s = response.data.feeDoList;
  2216. this.fWbuOptions = response.data.feesList;
  2217. this.queryParams = response.data.tFee;
  2218. this.fWbuOptions = response.data.feesList;
  2219. this.fMblnoOptions = response.data.corps;
  2220. this.mainTable = true
  2221. this.title = "修改收费列表";
  2222. });
  2223. }else if(Cookies.get("sysType") == 3){
  2224. getCharge(this.approval.billId).then((response) => {
  2225. this.Operator = response.data.tFee.createBy;
  2226. if (response.data.feeDoList != 0) {
  2227. response.data.feeDoList.map((e) => {
  2228. if (e.fBsdate) {
  2229. e.fBsdate = e.fBsdate.slice(0, 10);
  2230. }
  2231. });
  2232. }
  2233. this.increase_s = response.data.feeDoList;
  2234. this.fWbuOptions = response.data.feesList;
  2235. this.queryParams = response.data.tFee;
  2236. this.fWbuOptions = response.data.feesList;
  2237. this.fMblnoOptions = response.data.corps;
  2238. this.mainTable = true
  2239. this.title = "修改收费列表";
  2240. });
  2241. }
  2242. }
  2243. },
  2244. homePage() {
  2245. this.open = false;
  2246. let view = {
  2247. fullPath: "/finance/charge",
  2248. hash: "",
  2249. matched: Array(2),
  2250. meta: Object,
  2251. name: "Charge",
  2252. params: Object,
  2253. path: "/finance/charge",
  2254. query: Object,
  2255. title: "收费",
  2256. };
  2257. this.$router.push({ path: "/index" });
  2258. this.$store
  2259. .dispatch("tagsView/delView", view)
  2260. .then(({ visitedViews }) => {
  2261. if (this.isActive(view)) {
  2262. this.toLastView(visitedViews, view);
  2263. }
  2264. });
  2265. Global.$emit("removeCache", "closeSelectedTag", view);
  2266. },
  2267. register() {
  2268. queryUserVal().then((response) => {
  2269. this.Lander = response.user.userName;
  2270. });
  2271. },
  2272. immediateApproval(status) {
  2273. this.addOrUpdateVisib = true;
  2274. console.log(this.approval.actId)
  2275. this.$nextTick(() => {
  2276. if(Cookies.get("sysType") == 3){
  2277. this.$refs.ApprovalComments.init(
  2278. this.approval.billId,status,
  2279. 440
  2280. );
  2281. }else{
  2282. this.$refs.ApprovalComments.init(
  2283. this.approval.billId,status,
  2284. this.contrastId
  2285. );
  2286. }
  2287. });
  2288. },
  2289. // 查看审批流
  2290. addOrUpdateHandle(status) {
  2291. this.addOrUpdateVisible = true;
  2292. this.addOrUpdateVisib = false;
  2293. let id = "448";
  2294. let actId = "110";
  2295. this.$nextTick(() => {
  2296. if(Cookies.get("sysType") == 3){
  2297. this.$refs.addOrUpdate.init(this.queryParams.fId, 440,status);
  2298. }else{
  2299. this.$refs.addOrUpdate.init(this.queryParams.fId, 220,status);
  2300. }
  2301. });
  2302. },
  2303. // 撤销收费
  2304. revokeCharge() {
  2305. this.queryParams.fBillstatus = "1";
  2306. let formDate = new window.FormData();
  2307. formDate.append("tFee", JSON.stringify(this.queryParams));
  2308. formDate.append("tFeeDo", JSON.stringify(this.increase_s));
  2309. backCharge(formDate).then((response) => {
  2310. this.open = false;
  2311. this.mainTable = false
  2312. this.msgSuccess("操作成功");
  2313. this.getList();
  2314. });
  2315. },
  2316. // 查看按钮
  2317. check(row, res) {
  2318. this.notChange = true;
  2319. this.doNot = true
  2320. if (Cookies.get("sysType") == 1) {
  2321. //大木
  2322. getCharge(row.fId).then((response) => {
  2323. this.Operator = response.data.tFee.createBy;
  2324. if (response.data.feeDoList != 0) {
  2325. response.data.feeDoList.map((e) => {
  2326. if (e.fBsdate) {
  2327. e.fBsdate = e.fBsdate.slice(0, 10);
  2328. }
  2329. if (e.fSrcdc) {
  2330. if (e.fSrcdc == "D") {
  2331. e.fSrcdc = "收";
  2332. } else {
  2333. e.fSrcdc = "付";
  2334. }
  2335. }
  2336. });
  2337. }
  2338. this.increase_s = response.data.feeDoList;
  2339. this.fWbuOptions = response.data.feesList;
  2340. this.queryParams = response.data.tFee;
  2341. this.fWbuOptions = response.data.feesList;
  2342. this.fMblnoOptions = response.data.corps;
  2343. this.mainTable = true
  2344. this.title = "收费列表";
  2345. this.tablefilter = true;
  2346. if (res == 1) {
  2347. this.notChange = true;
  2348. if (this.Operator == this.Lander) {
  2349. this.tablefilter = false;
  2350. this.reset();
  2351. this.pass = {
  2352. fAmtdr: 0, //应收合计
  2353. fAmtcr: 0, //应付合计
  2354. fMblno: "", //提单号
  2355. fName: "", //货权方
  2356. fFeesName: "", //结算单位
  2357. fCorpid: "", //结算单位ID
  2358. };
  2359. const fId = row.fId || this.ids;
  2360. getCharge(fId).then((response) => {
  2361. if (response.data.feeDoList != 0) {
  2362. response.data.feeDoList.map((e) => {
  2363. if (e.fBsdate) {
  2364. e.fBsdate = e.fBsdate.slice(0, 10);
  2365. }
  2366. if (e.fSrcdc) {
  2367. if (e.fSrcdc == "D") {
  2368. e.fSrcdc = "收";
  2369. } else {
  2370. e.fSrcdc = "付";
  2371. }
  2372. }
  2373. });
  2374. }
  2375. this.increase_s = response.data.feeDoList;
  2376. this.fWbuOptions = response.data.feesList;
  2377. this.queryParams = response.data.tFee;
  2378. this.fWbuOptions = response.data.feesList;
  2379. this.fMblnoOptions = response.data.corps;
  2380. this.mainTable = true
  2381. });
  2382. } else {
  2383. this.notChange = true;
  2384. // this.$message.error('未知异常,请联系管理员')
  2385. }
  2386. } else {
  2387. this.notChange = true;
  2388. this.reset();
  2389. this.pass = {
  2390. fAmtdr: 0, //应收合计
  2391. fAmtcr: 0, //应付合计
  2392. fMblno: "", //提单号
  2393. fName: "", //货权方
  2394. fFeesName: "", //结算单位
  2395. fCorpid: "", //结算单位ID
  2396. };
  2397. const fId = row.fId || this.ids;
  2398. getCharge(fId).then((response) => {
  2399. if (response.data.feeDoList != 0) {
  2400. response.data.feeDoList.map((e) => {
  2401. if (e.fBsdate) {
  2402. e.fBsdate = e.fBsdate.slice(0, 10);
  2403. }
  2404. if (e.fSrcdc) {
  2405. if (e.fSrcdc == "D") {
  2406. e.fSrcdc = "收";
  2407. } else {
  2408. e.fSrcdc = "付";
  2409. }
  2410. }
  2411. });
  2412. }
  2413. this.increase_s = response.data.feeDoList;
  2414. this.fWbuOptions = response.data.feesList;
  2415. this.queryParams = response.data.tFee;
  2416. this.fWbuOptions = response.data.feesList;
  2417. this.fMblnoOptions = response.data.corps;
  2418. this.mainTable = true
  2419. });
  2420. }
  2421. });
  2422. } else if (Cookies.get("sysType") == 2) {
  2423. //车队
  2424. getCharges(row.fId).then((response) => {
  2425. this.Operator = response.data.tFee.createBy;
  2426. if (response.data.feeDoList != 0) {
  2427. response.data.feeDoList.map((e) => {
  2428. if (e.fBsdate) {
  2429. e.fBsdate = e.fBsdate.slice(0, 10);
  2430. }
  2431. if (e.fSrcdc) {
  2432. if (e.fSrcdc == "D") {
  2433. e.fSrcdc = "收";
  2434. } else {
  2435. e.fSrcdc = "付";
  2436. }
  2437. }
  2438. });
  2439. }
  2440. this.increase_s = response.data.feeDoList;
  2441. this.fWbuOptions = response.data.feesList;
  2442. this.queryParams = response.data.tFee;
  2443. this.fWbuOptions = response.data.feesList;
  2444. this.fMblnoOptions = response.data.corps;
  2445. this.mainTable = true
  2446. this.title = "收费列表";
  2447. this.tablefilter = true;
  2448. if (res == 1) {
  2449. this.notChange = true;
  2450. if (this.Operator == this.Lander) {
  2451. this.tablefilter = false;
  2452. this.reset();
  2453. this.pass = {
  2454. fAmtdr: 0, //应收合计
  2455. fAmtcr: 0, //应付合计
  2456. fMblno: "", //提单号
  2457. fName: "", //货权方
  2458. fFeesName: "", //结算单位
  2459. fCorpid: "", //结算单位ID
  2460. };
  2461. const fId = row.fId || this.ids;
  2462. getCharges(fId).then((response) => {
  2463. if (response.data.feeDoList != 0) {
  2464. response.data.feeDoList.map((e) => {
  2465. if (e.fBsdate) {
  2466. e.fBsdate = e.fBsdate.slice(0, 10);
  2467. }
  2468. if (e.fSrcdc) {
  2469. if (e.fSrcdc == "D") {
  2470. e.fSrcdc = "收";
  2471. } else {
  2472. e.fSrcdc = "付";
  2473. }
  2474. }
  2475. });
  2476. }
  2477. this.increase_s = response.data.feeDoList;
  2478. this.fWbuOptions = response.data.feesList;
  2479. this.queryParams = response.data.tFee;
  2480. this.fWbuOptions = response.data.feesList;
  2481. this.fMblnoOptions = response.data.corps;
  2482. this.mainTable = true
  2483. });
  2484. } else {
  2485. this.notChange = true;
  2486. // this.$message.error('未知异常,请联系管理员')
  2487. }
  2488. } else {
  2489. this.notChange = true;
  2490. this.reset();
  2491. this.pass = {
  2492. fAmtdr: 0, //应收合计
  2493. fAmtcr: 0, //应付合计
  2494. fMblno: "", //提单号
  2495. fName: "", //货权方
  2496. fFeesName: "", //结算单位
  2497. fCorpid: "", //结算单位ID
  2498. };
  2499. const fId = row.fId || this.ids;
  2500. getCharges(fId).then((response) => {
  2501. if (response.data.feeDoList != 0) {
  2502. response.data.feeDoList.map((e) => {
  2503. if (e.fBsdate) {
  2504. e.fBsdate = e.fBsdate.slice(0, 10);
  2505. }
  2506. if (e.fSrcdc) {
  2507. if (e.fSrcdc == "D") {
  2508. e.fSrcdc = "收";
  2509. } else {
  2510. e.fSrcdc = "付";
  2511. }
  2512. }
  2513. });
  2514. }
  2515. this.increase_s = response.data.feeDoList;
  2516. this.fWbuOptions = response.data.feesList;
  2517. this.queryParams = response.data.tFee;
  2518. this.fWbuOptions = response.data.feesList;
  2519. this.fMblnoOptions = response.data.corps;
  2520. this.mainTable = true
  2521. });
  2522. }
  2523. });
  2524. }else if(Cookies.get("sysType") == 3){
  2525. getCharge(row.fId).then((response) => {
  2526. this.Operator = response.data.tFee.createBy;
  2527. if (response.data.feeDoList != 0) {
  2528. response.data.feeDoList.map((e) => {
  2529. if (e.fBsdate) {
  2530. e.fBsdate = e.fBsdate.slice(0, 10);
  2531. }
  2532. });
  2533. }
  2534. this.increase_s = response.data.feeDoList;
  2535. this.fWbuOptions = response.data.feesList;
  2536. this.queryParams = response.data.tFee;
  2537. this.fWbuOptions = response.data.feesList;
  2538. this.fMblnoOptions = response.data.corps;
  2539. this.mainTable = true
  2540. this.title = "收费列表";
  2541. this.tablefilter = true;
  2542. if (res == 1) {
  2543. this.notChange = true;
  2544. if (this.Operator == this.Lander) {
  2545. this.tablefilter = false;
  2546. this.reset();
  2547. this.pass = {
  2548. fAmtdr: 0, //应收合计
  2549. fAmtcr: 0, //应付合计
  2550. fMblno: "", //提单号
  2551. fName: "", //货权方
  2552. fFeesName: "", //结算单位
  2553. fCorpid: "", //结算单位ID
  2554. };
  2555. const fId = row.fId || this.ids;
  2556. getCharge(fId).then((response) => {
  2557. if (response.data.feeDoList != 0) {
  2558. response.data.feeDoList.map((e) => {
  2559. if (e.fBsdate) {
  2560. e.fBsdate = e.fBsdate.slice(0, 10);
  2561. }
  2562. });
  2563. }
  2564. this.increase_s = response.data.feeDoList;
  2565. this.fWbuOptions = response.data.feesList;
  2566. this.queryParams = response.data.tFee;
  2567. this.fWbuOptions = response.data.feesList;
  2568. this.fMblnoOptions = response.data.corps;
  2569. this.mainTable = true
  2570. this.title = "收费列表";
  2571. });
  2572. } else {
  2573. this.notChange = true;
  2574. // this.$message.error('未知异常,请联系管理员')
  2575. }
  2576. } else {
  2577. this.notChange = true;
  2578. this.reset();
  2579. this.pass = {
  2580. fAmtdr: 0, //应收合计
  2581. fAmtcr: 0, //应付合计
  2582. fMblno: "", //提单号
  2583. fName: "", //货权方
  2584. fFeesName: "", //结算单位
  2585. fCorpid: "", //结算单位ID
  2586. };
  2587. const fId = row.fId || this.ids;
  2588. getCharge(fId).then((response) => {
  2589. if (response.data.feeDoList != 0) {
  2590. response.data.feeDoList.map((e) => {
  2591. if (e.fBsdate) {
  2592. e.fBsdate = e.fBsdate.slice(0, 10);
  2593. }
  2594. });
  2595. }
  2596. this.increase_s = response.data.feeDoList;
  2597. this.fWbuOptions = response.data.feesList;
  2598. this.queryParams = response.data.tFee;
  2599. this.fWbuOptions = response.data.feesList;
  2600. this.fMblnoOptions = response.data.corps;
  2601. this.mainTable = true
  2602. this.title = "收费列表";
  2603. this.tablefilter = true;
  2604. });
  2605. }
  2606. });
  2607. }
  2608. },
  2609. //打印功能
  2610. printing() {
  2611. if (this.increase_s.length !== 0) {
  2612. this.printStatus = true;
  2613. this.printObject = this.increase_s;
  2614. } else {
  2615. this.$message.error("无数据,请检查是否有数据");
  2616. }
  2617. },
  2618. //确认打印
  2619. printSomething() {
  2620. // 此处的style即为打印时的样式
  2621. const style =
  2622. "table tr td,th { border-collapse: collapse;padding:0px;border:.5px #000 solid;text-align:center;}";
  2623. print({
  2624. printable: "print_area2",
  2625. type: "html",
  2626. header: "收费表",
  2627. style: style, // 亦可使用引入的外部css;
  2628. scanStyles: false,
  2629. });
  2630. },
  2631. //关闭打印弹窗
  2632. closePrinting() {
  2633. this.$confirm("确认关闭?")
  2634. .then((_) => {
  2635. this.printStatus = false;
  2636. })
  2637. .catch((_) => {});
  2638. },
  2639. // 确认收费
  2640. confirmCharge() {
  2641. this.$refs["ruless"].validate((valid) => {
  2642. if (valid) {
  2643. if (this.increase_s.length) {
  2644. // this.queryParams.fBillstatus = '4'
  2645. let formDate = new window.FormData();
  2646. formDate.append("tFee", JSON.stringify(this.queryParams));
  2647. formDate.append("tFeeDo", JSON.stringify(this.increase_s));
  2648. if (Cookies.get("sysType") == 1) {
  2649. collectFee(formDate).then((response) => {
  2650. this.open = false;
  2651. this.msgSuccess("操作成功");
  2652. this.getList();
  2653. });
  2654. } else if(Cookies.get("sysType") == 2){
  2655. collectFees(formDate).then((response) => {
  2656. this.open = false;
  2657. this.msgSuccess("操作成功");
  2658. this.getList();
  2659. });
  2660. }else if(Cookies.get("sysType") == 3){
  2661. formDate.append('billsType','KHSF')
  2662. collectFee(formDate).then((response) => {
  2663. this.queryParams.fId = response.data.tFee.fId
  2664. this.queryParams.fBillno = response.data.tFee.fBillno
  2665. this.open = false;
  2666. this.msgSuccess("操作成功");
  2667. this.getList();
  2668. this.notChange = true;
  2669. this.doNot = true
  2670. this.$set(this.queryParams,'fBillstatus','4')
  2671. // this.queryParams.fBillstatus = '4'
  2672. if (this.Operator == this.Lander) {
  2673. this.tablefilter = false;
  2674. }
  2675. });
  2676. }
  2677. } else {
  2678. this.$message.error("表单为空不允许操作");
  2679. }
  2680. }
  2681. });
  2682. },
  2683. charGe() {
  2684. if (!Cookies.get("sysType")) {
  2685. return this.$message("请先选择业务类型");
  2686. }
  2687. this.queryParameter.fToCorpid = this.queryParams.fCorpid
  2688. this.chargeList_s = [];
  2689. // this.queryParameter.fToCorpid = this.queryParams.fCorpid
  2690. this.innerVisible = true;
  2691. // if (this.queryParams.fCorpid) {
  2692. // this.doNot = true;
  2693. // }
  2694. },
  2695. getSum(param) {
  2696. const { columns, data } = param;
  2697. const sums = [];
  2698. columns.forEach((column, index) => {
  2699. if(this.selection.length == 0){
  2700. if (index === 0) {
  2701. sums[index] = "合计";
  2702. } else if ( column.label == '金额' || column.label == '本次金额') {
  2703. const values = data.map((item) => Number(item[column.property]));
  2704. if (!values.every((value) => isNaN(value))) {
  2705. sums[index] = values.reduce((prev, curr) => {
  2706. const value = Number(curr);
  2707. if (!isNaN(value)) {
  2708. return prev + curr;
  2709. } else {
  2710. return prev;
  2711. }
  2712. }, 0);
  2713. }
  2714. }
  2715. }else{
  2716. if (index === 0) {
  2717. sums[index] = "合计";
  2718. } else if (column.label == '金额' || column.label == '本次金额') {
  2719. const values = this.selection.map((selection) => Number(selection[column.property]));
  2720. if (!values.every((value) => isNaN(value))) {
  2721. sums[index] = values.reduce((prev, curr) => {
  2722. const value = Number(curr);
  2723. if (!isNaN(value)) {
  2724. return prev + curr;
  2725. } else {
  2726. return prev;
  2727. }
  2728. }, 0);
  2729. }
  2730. }
  2731. }
  2732. // sums[0] = "合计";
  2733. // sums[10] = this.totAL.toFixed(2);
  2734. // sums[9] = this.Ttime.toFixed(2);
  2735. });
  2736. return sums;
  2737. },
  2738. // 导入多选框
  2739. handleSelectionChange_s(selection) {
  2740. // this.totAL = 0;
  2741. // this.Ttime = 0;
  2742. this.selection = selection;
  2743. // if (this.selection.length == 0) {
  2744. // for (let item in this.chargeList_s) {
  2745. // this.totAL += Number(this.chargeList_s[item].fAmt);
  2746. // this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  2747. // }
  2748. // } else {
  2749. // for (let index in selection) {
  2750. // this.totAL += Number(selection[index].fAmt);
  2751. // this.Ttime += Number(selection[index].fAmtdr);
  2752. // }
  2753. // }
  2754. // this.getSummaries()
  2755. },
  2756. // 多选框选中数据
  2757. handleSelectionChange(selection) {
  2758. this.totAL = 0;
  2759. this.ids = selection.map((item) => item.fId);
  2760. this.single =
  2761. selection.length !== 1 ||
  2762. selection.map((item) => item.fBillstatus) == 6 ||
  2763. selection.map((item) => item.fBillstatus) == 4;
  2764. this.multiple = !selection.length;
  2765. },
  2766. imgChangeI(row) {
  2767. if (row.fAmt && Number(row.fAmt) > Number(row.fAmtdr)) {
  2768. this.$set(row, "fAmt", row.fAmtdr);
  2769. this.state_s = true;
  2770. }
  2771. if (this.selection.length !== 0) {
  2772. this.totAL = 0;
  2773. this.Ttime = 0;
  2774. for (let item in this.selection) {
  2775. this.totAL += Number(this.selection[item].fAmt);
  2776. this.Ttime += Number(this.selection[item].fAmtdr);
  2777. }
  2778. } else {
  2779. this.totAL = 0;
  2780. this.Ttime = 0;
  2781. for (let item in this.chargeList_s) {
  2782. this.totAL += Number(this.chargeList_s[item].fAmt);
  2783. this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  2784. }
  2785. }
  2786. },
  2787. //确认导入
  2788. confirmImport() {
  2789. this.hide = true;
  2790. this.pass.fAmtdr = 0;
  2791. this.pass.fAmtcr = 0;
  2792. for (let item in this.selection) {
  2793. this.pass.fAmtcr = Number(this.pass.fAmtcr);
  2794. this.pass.fAmtdr = Number(this.pass.fAmtdr);
  2795. this.pass.fAmtcr += Number(this.selection[item].fAmt);
  2796. this.pass.fAmtdr += Number(this.selection[item].fAmtdr);
  2797. }
  2798. // this.pass.fAmtcr.toFixed(2);
  2799. if (this.state_s == true) {
  2800. if (this.selection.length == "0") {
  2801. this.$message.error("未选择导入行");
  2802. } else {
  2803. let Num = []
  2804. for (let item in this.selection) {
  2805. this.empty.push(this.selection[item].fMblno);
  2806. this.nothing.push(this.selection[item].fName);
  2807. if (this.increase_s.length === 0) {
  2808. this.increase_s = this.increase_s.concat(this.selection)
  2809. //去重提单号
  2810. this.empty = new Set(this.empty);
  2811. this.empty = Array.from(this.empty);
  2812. //去重货权方
  2813. this.nothing = new Set(this.nothing);
  2814. this.nothing = Array.from(this.nothing);
  2815. if (this.empty.length <= 1) {
  2816. this.pass.fMblno = this.empty[0];
  2817. } else {
  2818. this.pass.fMblno = this.empty[0] + "...";
  2819. }
  2820. if (this.nothing.length <= 1) {
  2821. this.pass.fName = this.nothing[0];
  2822. } else {
  2823. this.pass.fName = this.nothing[0] + "...";
  2824. }
  2825. // this.increase_s = this.increase_s.concat(this.selection);
  2826. this.queryParams.fMblno = this.pass.fMblno; //提单号
  2827. this.queryParams.fCtrlcorpid = this.pass.fName;
  2828. this.queryParams.fCorpid = this.queryParameter.fToCorpid;
  2829. this.queryParams.fAmtcr = this.pass.fAmtcr
  2830. this.queryParams.fAmtdr = this.pass.fAmtdr
  2831. this.innerVisible = false;
  2832. this.chargeList_s = [];
  2833. this.queryParameter = {
  2834. fCorpid: "",
  2835. fToCorpid: this.queryParams.fCorpid,
  2836. fMblno: "",
  2837. fStatementNo: "",
  2838. fFeeid: "",
  2839. timeExamine: "",
  2840. timeInterval: "",
  2841. fSystemType: Cookies.get("sysType")
  2842. };
  2843. return
  2844. }
  2845. }
  2846. for (let li in this.increase_s) {
  2847. for(let item in this.selection) {
  2848. if (this.selection[item].fSrcid !== this.increase_s[li].fSrcid) {
  2849. this.Fee = this.increase_s.concat(this.selection);
  2850. let result = [];
  2851. let obj = {};
  2852. for (let lis in this.Fee) {
  2853. if (!obj[this.Fee[lis].fSrcid]) {
  2854. result.push(this.Fee[lis]);
  2855. obj[this.Fee[lis].fSrcid] = true;
  2856. }
  2857. }
  2858. //去重提单号
  2859. this.empty = new Set(this.empty);
  2860. this.empty = Array.from(this.empty);
  2861. //去重货权方
  2862. this.nothing = new Set(this.nothing);
  2863. this.nothing = Array.from(this.nothing);
  2864. if (this.empty.length <= 1) {
  2865. this.pass.fMblno = this.empty[0];
  2866. } else {
  2867. this.pass.fMblno = this.empty[0] + "...";
  2868. }
  2869. if (this.nothing.length <= 1) {
  2870. this.pass.fName = this.nothing[0];
  2871. } else {
  2872. this.pass.fName = this.nothing[0] + "...";
  2873. }
  2874. // this.increase_s = this.increase_s.concat(this.selection);
  2875. this.queryParams.fMblno = this.pass.fMblno; //提单号
  2876. this.queryParams.fCtrlcorpid = this.pass.fName;
  2877. this.queryParams.fCorpid = this.queryParameter.fToCorpid;
  2878. this.queryParams.fAmtcr = Number(this.pass.fAmtcr).toFixed(2);
  2879. this.queryParams.fAmtdr = Number(this.pass.fAmtdr).toFixed(2);
  2880. this.innerVisible = false;
  2881. this.chargeList_s = [];
  2882. this.queryParameter = {
  2883. fCorpid: "",
  2884. fToCorpid: this.queryParams.fCorpid,
  2885. fMblno: "",
  2886. fStatementNo: "",
  2887. fFeeid: "",
  2888. fBilltype: "",
  2889. fBusinessType: "",
  2890. fVslid: "",
  2891. fVoyid: "",
  2892. timeExamine: "",
  2893. timeInterval: "",
  2894. fSystemType: Cookies.get("sysType")
  2895. };
  2896. this.increase_s = result;
  2897. } else {
  2898. let i = Number(li) + 1;
  2899. Num += i + '、'
  2900. }
  2901. }
  2902. }
  2903. if(Num.length != 0){
  2904. MessageBox.confirm("从表的第" + (Num).slice(0,Num.length-1) + "行重复,如本次金额变更,请删除后重新选择","提示",{
  2905. confirmButtonText: '确定',
  2906. cancelButtonText: '取消',
  2907. type: 'warning'
  2908. }
  2909. )
  2910. }
  2911. }
  2912. } else if (this.state_s == false) {
  2913. this.$message.error("本次金额不能大于原定金额");
  2914. }
  2915. },
  2916. /** 查询财务数据主列表 */
  2917. getList() {
  2918. this.loading = true;
  2919. this.getDicts("approval_process").then((response) => {
  2920. this.options = response.data;
  2921. });
  2922. if (Cookies.get("sysType") == 1) {
  2923. //大木
  2924. listCharge(this.tableFilter).then((response) => {
  2925. this.chargeList = response.rows;
  2926. this.total = response.total;
  2927. this.loading = false;
  2928. });
  2929. } else if (Cookies.get("sysType") == 2) {
  2930. //车队
  2931. listCharges(this.tableFilter).then((response) => {
  2932. response.rows.map((e) => {
  2933. if (e.createTime) {
  2934. e.createTime = e.createTime.substring(0, 10);
  2935. }
  2936. });
  2937. this.chargeList = response.rows;
  2938. this.total = response.total;
  2939. this.loading = false;
  2940. });
  2941. }else if(Cookies.get("sysType") == 3){
  2942. this.tableFilter.fBilltype = 'KHSF'
  2943. if(this.tableFilter.firstMoney || this.tableFilter.lastMoney){
  2944. if(this.tableFilter.firstMoney == '' || this.tableFilter.lastMoney == ''){
  2945. this.$message.error("实收合计为金额区间,请填写完整")
  2946. this.tableFilter.amount = []
  2947. }else if(!this.tableFilter.firstMoney || !this.tableFilter.lastMoney){
  2948. this.$message.error("实收合计为金额区间,请填写完整")
  2949. }else{
  2950. this.tableFilter.amount[0] = this.tableFilter.firstMoney
  2951. this.tableFilter.amount[1] = this.tableFilter.lastMoney
  2952. }
  2953. }else{
  2954. this.tableFilter.amount = []
  2955. }
  2956. listCharge(this.tableFilter).then((response) => {
  2957. this.chargeList = response.rows;
  2958. this.total = response.total;
  2959. this.loading = false;
  2960. });
  2961. }
  2962. },
  2963. // 取消按钮
  2964. cancel() {
  2965. if(this.notChange == true){
  2966. this.mainTable = false
  2967. }else{
  2968. this.$confirm("返回列表,是否保存?", "提示", {
  2969. confirmButtonText: "保存",
  2970. cancelButtonText: "取消",
  2971. type: "warning",
  2972. })
  2973. .then(() => {
  2974. this.submitForm(Cookies.get("sysType"))
  2975. })
  2976. .catch(() => {
  2977. this.mainTable = false
  2978. this.getList();
  2979. });
  2980. }
  2981. },
  2982. // 表单重置
  2983. reset() {
  2984. this.form = {
  2985. fId: null,
  2986. fBillno: null,
  2987. fCtrlcorpid: null,
  2988. fCorpid: null,
  2989. fMblno: null,
  2990. fAmtdr: null,
  2991. fAmtcr: null,
  2992. fBilltype: null,
  2993. fBillstatus: "0",
  2994. fRemarks: null,
  2995. fAccbilldate: null,
  2996. delFlag: null,
  2997. createBy: null,
  2998. fDeptid: null,
  2999. createTime: null,
  3000. updateBy: null,
  3001. updateTime: null,
  3002. };
  3003. this.resetForm("form");
  3004. },
  3005. /** 搜索按钮操作 */
  3006. handleQuery() {
  3007. this.queryParams.pageNum = 1;
  3008. this.getList();
  3009. },
  3010. /** 导入搜索 */
  3011. importSearch() {
  3012. this.chargeList_s = [];
  3013. if (this.queryParameter.fStatementNo) {
  3014. this.rules = {};
  3015. if (Cookies.get("sysType") == 1) {
  3016. search(this.queryParameter).then((response) => {
  3017. this.chargeList_s = response.rows;
  3018. this.$message.success("查询成功");
  3019. for (let item in this.chargeList_s) {
  3020. this.totAL += Number(this.chargeList_s[item].fAmt);
  3021. this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  3022. }
  3023. });
  3024. } else if(Cookies.get("sysType") == 2){
  3025. searchs(this.queryParameter).then((response) => {
  3026. this.chargeList_s = response.rows;
  3027. this.$message.success("查询成功");
  3028. for (let item in this.chargeList_s) {
  3029. this.totAL += Number(this.chargeList_s[item].fAmt);
  3030. this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  3031. }
  3032. });
  3033. }else if(Cookies.get("sysType") == 3){
  3034. this.queryParameter.fSystemType = this.queryParams.fSystemType
  3035. search(this.queryParameter).then((response) => {
  3036. this.chargeList_s = response.rows;
  3037. this.$message.success("查询成功");
  3038. for (let item in this.chargeList_s) {
  3039. this.totAL += Number(this.chargeList_s[item].fAmt);
  3040. this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  3041. }
  3042. });
  3043. }
  3044. } else{
  3045. // this.rules = {
  3046. // fToCorpid: [{ required: true, message: " ", trigger: "blur" }],
  3047. // timeExamine: [{ required: true, message: " ", trigger: "blur" }],
  3048. // };
  3049. if (this.rules) {
  3050. this.$refs["form"].validate((valid) => {
  3051. if (valid) {
  3052. if (Cookies.get("sysType") == 1) {
  3053. search(this.queryParameter).then((response) => {
  3054. this.chargeList_s = response.rows;
  3055. if (this.chargeList_s.length !== 0) {
  3056. this.$message.success("查询成功");
  3057. this.totAL = 0;
  3058. this.Ttime = 0;
  3059. for (let item in this.chargeList_s) {
  3060. this.totAL += Number(this.chargeList_s[item].fAmt);
  3061. this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  3062. }
  3063. } else {
  3064. this.$message.error("暂无数据");
  3065. }
  3066. });
  3067. } else if(Cookies.get("sysType") == 2){
  3068. searchs(this.queryParameter).then((response) => {
  3069. this.chargeList_s = response.rows;
  3070. if (this.chargeList_s.length !== 0) {
  3071. this.$message.success("查询成功");
  3072. this.totAL = 0;
  3073. this.Ttime = 0;
  3074. for (let item in this.chargeList_s) {
  3075. this.totAL += Number(this.chargeList_s[item].fAmt);
  3076. this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  3077. }
  3078. } else {
  3079. this.$message.error("暂无数据");
  3080. }
  3081. });
  3082. }else if(Cookies.get("sysType") == 3){
  3083. this.queryParameter.fSystemType = this.queryParams.fSystemType
  3084. search(this.queryParameter).then((response) => {
  3085. this.chargeList_s = response.rows;
  3086. if (this.chargeList_s.length !== 0) {
  3087. this.$message.success("查询成功");
  3088. this.totAL = 0;
  3089. this.Ttime = 0;
  3090. for (let item in this.chargeList_s) {
  3091. this.totAL += Number(this.chargeList_s[item].fAmt);
  3092. this.Ttime += Number(this.chargeList_s[item].fAmtdr);
  3093. }
  3094. } else {
  3095. this.$message.error("暂无数据");
  3096. }
  3097. });
  3098. }
  3099. }
  3100. });
  3101. } else {
  3102. this.$message.error("操作频繁");
  3103. }
  3104. }
  3105. },
  3106. /** 远程模糊查询用户 */
  3107. corpsRemoteMethod(name) {
  3108. // if (name == null || name === "") {
  3109. // return false;
  3110. // }
  3111. let queryParams = { fName: name };
  3112. listCorps(queryParams).then((response) => {
  3113. this.fMblnoOptions = response;
  3114. this.KHblnoOptions = response;
  3115. });
  3116. },
  3117. /** 重置按钮操作 */
  3118. resetQuery() {
  3119. this.tableFilter = {
  3120. pageNum: 1,
  3121. pageSize: 10,
  3122. fBillno: null,
  3123. fCtrlcorpid: null,
  3124. fCorpid: null,
  3125. timeInterval: null,
  3126. };
  3127. this.handleQuery();
  3128. },
  3129. //导入重置按钮
  3130. resetQuery_s() {
  3131. this.queryParameter = {
  3132. fCorpid: "",
  3133. fToCorpid: "",
  3134. fMblno: "",
  3135. fStatementNo: "",
  3136. fFeeid: "",
  3137. timeExamine: "",
  3138. timeInterval: "",
  3139. };
  3140. },
  3141. // 远程模糊查询费用名称
  3142. fWRemoteMethod(name) {
  3143. this.fWbuOptions = [];
  3144. if (name == null || name === "") {
  3145. return false;
  3146. }
  3147. let queryParams = { pageNum: 1, pageSize: 10, fName: name };
  3148. listFees(queryParams).then((response) => {
  3149. this.fWbuOptions = response.rows;
  3150. });
  3151. },
  3152. /** 新增按钮操作 */
  3153. handleAdd() {
  3154. this.notChange = false;
  3155. this.doNot = false
  3156. this.hide = true;
  3157. this.reset();
  3158. this.pass = {
  3159. fAmtdr: 0, //应收合计
  3160. fAmtcr: 0, //应付合计
  3161. fMblno: "", //提单号
  3162. fName: "", //货权方
  3163. fFeesName: "", //结算单位
  3164. fCorpid: "", //结算单位ID
  3165. },
  3166. // this.queryParams = []
  3167. this.increase_s = [];
  3168. this.queryParams = {
  3169. pageNum: 1,
  3170. pageSize: 10,
  3171. fBillno: null,
  3172. fCtrlcorpid: null,
  3173. fCorpid: null,
  3174. fMblno: null,
  3175. fAmtdr: null,
  3176. fAmtcr: null,
  3177. fBilltype: null,
  3178. fBillstatus: null,
  3179. fRemarks: null,
  3180. fAccbilldate: null,
  3181. fDeptid: null,
  3182. chargingMethod: null,
  3183. invoiceNo: null,
  3184. bank: null,
  3185. waterBillNo: null,
  3186. fSystemType: Cookies.get("sysType"),
  3187. };
  3188. this.resetForm("queryParams");
  3189. this.mainTable = true;
  3190. this.title = "添加财务数据主";
  3191. },
  3192. /** 修改按钮操作 */
  3193. handleUpdate(row) {
  3194. this.approve = false;
  3195. this.hide = false;
  3196. this.notChange = false;
  3197. this.reset();
  3198. this.pass = {
  3199. fAmtdr: 0, //应收合计
  3200. fAmtcr: 0, //应付合计
  3201. fMblno: "", //提单号
  3202. fName: "", //货权方
  3203. fFeesName: "", //结算单位
  3204. fCorpid: "", //结算单位ID
  3205. };
  3206. const fId = row.fId || this.ids;
  3207. if (Cookies.get("sysType") == 1) {
  3208. //大木
  3209. getCharge(fId).then((response) => {
  3210. this.Operator = response.data.tFee.createBy;
  3211. if (response.data.feeDoList != 0) {
  3212. response.data.feeDoList.map((e) => {
  3213. if (e.fBsdate) {
  3214. e.fBsdate = e.fBsdate.slice(0, 10);
  3215. }
  3216. if (e.fSrcdc) {
  3217. if (e.fSrcdc == "D") {
  3218. e.fSrcdc = "收";
  3219. } else {
  3220. e.fSrcdc = "付";
  3221. }
  3222. }
  3223. });
  3224. }
  3225. this.increase_s = response.data.feeDoList;
  3226. this.fWbuOptions = response.data.feesList;
  3227. this.queryParams = response.data.tFee;
  3228. this.fWbuOptions = response.data.feesList;
  3229. this.fMblnoOptions = response.data.corps;
  3230. this.mainTable = true
  3231. this.title = "修改收费列表";
  3232. if (this.increase_s.length != 0) {
  3233. this.doNot = true;
  3234. } else {
  3235. this.doNot = false;
  3236. }
  3237. });
  3238. } else if (Cookies.get("sysType") == 2) {
  3239. //车队
  3240. getCharges(fId).then((response) => {
  3241. this.Operator = response.data.tFee.createBy;
  3242. if (response.data.feeDoList != 0) {
  3243. response.data.feeDoList.map((e) => {
  3244. if (e.fBsdate) {
  3245. e.fBsdate = e.fBsdate.slice(0, 10);
  3246. }
  3247. if (e.fSrcdc) {
  3248. if (e.fSrcdc == "D") {
  3249. e.fSrcdc = "收";
  3250. } else {
  3251. e.fSrcdc = "付";
  3252. }
  3253. }
  3254. });
  3255. }
  3256. this.increase_s = response.data.feeDoList;
  3257. this.fWbuOptions = response.data.feesList;
  3258. this.queryParams = response.data.tFee;
  3259. this.fWbuOptions = response.data.feesList;
  3260. this.fMblnoOptions = response.data.corps;
  3261. this.mainTable = true
  3262. this.title = "修改收费列表";
  3263. if (this.increase_s.length != 0) {
  3264. this.doNot = true;
  3265. } else {
  3266. this.doNot = false;
  3267. }
  3268. });
  3269. }else if(Cookies.get("sysType") == 3){
  3270. getCharge(fId).then((response) => {
  3271. this.Operator = response.data.tFee.createBy;
  3272. if (response.data.feeDoList != 0) {
  3273. response.data.feeDoList.map((e) => {
  3274. if (e.fBsdate) {
  3275. e.fBsdate = e.fBsdate.slice(0, 10);
  3276. }
  3277. });
  3278. }
  3279. this.increase_s = response.data.feeDoList;
  3280. this.fWbuOptions = response.data.feesList;
  3281. this.queryParams = response.data.tFee;
  3282. this.fWbuOptions = response.data.feesList;
  3283. this.fMblnoOptions = response.data.corps;
  3284. this.mainTable = true
  3285. this.title = "修改收费列表";
  3286. if (this.increase_s.length != 0) {
  3287. this.doNot = true;
  3288. } else {
  3289. this.doNot = false;
  3290. }
  3291. });
  3292. }
  3293. },
  3294. /** 提交按钮 */
  3295. submitForm(res) {
  3296. this.$refs["ruless"].validate((valid) => {
  3297. if (valid) {
  3298. if (!this.queryParams.fId) {
  3299. // this.chargeList.fBillstatus = '1'
  3300. this.queryParams.fBillstatus = "1";
  3301. let formData = new window.FormData();
  3302. formData.append("tFee", JSON.stringify(this.queryParams));
  3303. formData.append("tFeeDo", JSON.stringify(this.increase_s));
  3304. if (Cookies.get("sysType") == 1) {
  3305. addCharge(formData).then((response) => {
  3306. let feeBills = response.data.tFee;
  3307. this.$set(this.queryParams, "fId", response.data.tFee.fId);
  3308. this.$set(
  3309. this.queryParams,
  3310. "fBillno",
  3311. response.data.tFee.fBillno
  3312. );
  3313. this.msgSuccess("新增成功");
  3314. });
  3315. } else if(Cookies.get("sysType") == 2){
  3316. addCharges(formData).then((response) => {
  3317. let feeBills = response.data.tFee;
  3318. this.$set(this.queryParams, "fId", response.data.tFee.fId);
  3319. this.$set(
  3320. this.queryParams,
  3321. "fBillno",
  3322. response.data.tFee.fBillno
  3323. );
  3324. this.msgSuccess("新增成功");
  3325. });
  3326. }else if(Cookies.get("sysType") == 3){
  3327. formData.append("billsType", 'KHSF');
  3328. addCharge(formData).then((response) => {
  3329. this.queryParams = response.data.tFee;
  3330. this.$set(this.queryParams, "fId", response.data.tFee.fId);
  3331. this.$set(this.queryParams, "fBillno", response.data.tFee.fBillno);
  3332. this.msgSuccess("新增成功");
  3333. if(res === 0){
  3334. this.mainTable = true
  3335. }else{
  3336. this.mainTable = false
  3337. }
  3338. this.getList()
  3339. });
  3340. }
  3341. } else if(Cookies.get("sysType") == 1 || Cookies.get("sysType") == 2){
  3342. this.queryParams.fBillstatus = "1";
  3343. let formData = new window.FormData();
  3344. formData.append("tFee", JSON.stringify(this.queryParams));
  3345. formData.append("tFeeDo", JSON.stringify(this.increase_s));
  3346. addCharge(formData).then((response) => {
  3347. this.msgSuccess("修改成功");
  3348. this.getList();
  3349. });
  3350. }else if(Cookies.get("sysType") == 3){
  3351. this.queryParams.fBillstatus = "1";
  3352. let formData = new window.FormData();
  3353. formData.append("tFee", JSON.stringify(this.queryParams));
  3354. formData.append("tFeeDo", JSON.stringify(this.increase_s));
  3355. formData.append("billsType", 'KHSF');
  3356. addCharge(formData).then((response) => {
  3357. this.msgSuccess("修改成功");
  3358. if(res === 0){
  3359. this.mainTable = true
  3360. }else{
  3361. this.mainTable = false
  3362. }
  3363. this.getList();
  3364. });
  3365. }
  3366. }
  3367. });
  3368. },
  3369. /** 删除按钮操作 */
  3370. handleDelete(row) {
  3371. const fIds = row.fId || this.ids;
  3372. let tips = "";
  3373. if (Cookies.get("sysType") == 1) {
  3374. //大木
  3375. delCharge_s(fIds).then((data) => {
  3376. switch (data.msg) {
  3377. case "0": {
  3378. this.$message.error("当前数据已被其他操作员操作请刷新页面");
  3379. break;
  3380. }
  3381. case "1": {
  3382. tips = "当前主表有数据从表无数据是否删除";
  3383. this.delete_S(fIds, tips);
  3384. break;
  3385. }
  3386. case "2": {
  3387. tips = "当前主表有数据从表有数据是否删除";
  3388. this.delete_S(fIds, tips);
  3389. break;
  3390. }
  3391. default: {
  3392. return this.$message.error("未知错误,无状态");
  3393. }
  3394. }
  3395. });
  3396. } else if (Cookies.get("sysType") == 2) {
  3397. // 车队;
  3398. delCharge_ss(fIds).then((data) => {
  3399. switch (data.msg) {
  3400. case "0": {
  3401. this.$message.error("当前数据已被其他操作员操作请刷新页面");
  3402. break;
  3403. }
  3404. case "1": {
  3405. tips = "当前主表有数据从表无数据是否删除";
  3406. this.delete_S(fIds, tips);
  3407. break;
  3408. }
  3409. case "2": {
  3410. tips = "当前主表有数据从表有数据是否删除";
  3411. this.delete_S(fIds, tips);
  3412. break;
  3413. }
  3414. default: {
  3415. return this.$message.error("未知错误,无状态");
  3416. }
  3417. }
  3418. });
  3419. }else if(Cookies.get("sysType") == 3){
  3420. delCharge_s(fIds).then((data) => {
  3421. switch (data.msg) {
  3422. case "0": {
  3423. this.$message.error("当前数据已被其他操作员操作请刷新页面");
  3424. break;
  3425. }
  3426. case "1": {
  3427. tips = "当前主表有数据从表无数据是否删除";
  3428. this.delete_S(fIds, tips);
  3429. break;
  3430. }
  3431. case "2": {
  3432. tips = "当前主表有数据从表有数据是否删除";
  3433. this.delete_S(fIds, tips);
  3434. break;
  3435. }
  3436. default: {
  3437. return this.$message.error("未知错误,无状态");
  3438. }
  3439. }
  3440. });
  3441. }
  3442. },
  3443. delete_S(fIds, tips) {
  3444. this.$confirm(tips, "警告", {
  3445. confirmButtonText: "确定",
  3446. cancelButtonText: "取消",
  3447. type: "warning",
  3448. })
  3449. .then(function () {
  3450. if (Cookies.get("sysType") == 1) {
  3451. return delCharge(fIds);
  3452. } else if (Cookies.get("sysType") == 2) {
  3453. return delCharges(fIds);
  3454. }else if(Cookies.get("sysType") == 3){
  3455. return delCharge(fIds);
  3456. }
  3457. })
  3458. .then(() => {
  3459. this.getList();
  3460. this.msgSuccess("删除成功");
  3461. });
  3462. },
  3463. /** 导出按钮操作 */
  3464. handleExport() {
  3465. const queryParams = this.queryParams;
  3466. this.$confirm("是否确认导出所有财务数据主数据项?", "警告", {
  3467. confirmButtonText: "确定",
  3468. cancelButtonText: "取消",
  3469. type: "warning",
  3470. })
  3471. .then(function () {
  3472. return exportCharge(queryParams);
  3473. })
  3474. .then((response) => {
  3475. this.download(response.msg);
  3476. });
  3477. },
  3478. //清空一行
  3479. deleteRow(index, rows) {
  3480. this.queryParams.fAmtcr = 0;
  3481. this.queryParams.fAmtdr = 0;
  3482. rows.splice(index, 1);
  3483. for (let item in this.increase_s) {
  3484. this.queryParams.fAmtcr += this.increase_s[item].fAmt;
  3485. this.queryParams.fAmtdr += this.increase_s[item].fAmtdr;
  3486. }
  3487. if (this.increase_s.length == 0) {
  3488. this.doNot = false;
  3489. } else {
  3490. this.doNot = true;
  3491. }
  3492. },
  3493. // 财务结算方式(数据字典),对应data_settlement_type 字典翻译
  3494. methodTypeFormat(row, column) {
  3495. return this.selectDictLabel(this.methodOptions, row.chargingMethod);
  3496. },
  3497. },
  3498. };
  3499. </script>
  3500. <style lang="scss" scoped>
  3501. .tabSetting {
  3502. display: flex;
  3503. justify-content: flex-end;
  3504. }
  3505. .listStyle {
  3506. display: flex;
  3507. border-top: 1px solid #dcdfe6;
  3508. border-left: 1px solid #dcdfe6;
  3509. border-right: 1px solid #dcdfe6;
  3510. }
  3511. .listStyle:last-child {
  3512. border-bottom: 1px solid #dcdfe6;
  3513. }
  3514. .progress {
  3515. display: flex;
  3516. align-items: center;
  3517. padding: 2px;
  3518. background-color: rgba(0, 0, 0, 0.05);
  3519. height: 100%;
  3520. }
  3521. .avue-crud__dialog__header {
  3522. display: -webkit-box;
  3523. display: -ms-flexbox;
  3524. display: flex;
  3525. -webkit-box-align: center;
  3526. -ms-flex-align: center;
  3527. align-items: center;
  3528. -webkit-box-pack: justify;
  3529. -ms-flex-pack: justify;
  3530. justify-content: space-between;
  3531. }
  3532. .el-dialog__title {
  3533. color: rgba(0, 0, 0, 0.85);
  3534. font-weight: 500;
  3535. word-wrap: break-word;
  3536. }
  3537. .avue-crud__dialog__menu {
  3538. padding-right: 20px;
  3539. float: left;
  3540. }
  3541. .avue-crud__dialog__menu i {
  3542. color: #909399;
  3543. font-size: 15px;
  3544. }
  3545. .el-icon-full-screen {
  3546. cursor: pointer;
  3547. }
  3548. .el-icon-full-screen:before {
  3549. content: "\e719";
  3550. }
  3551. </style>
  3552. <style lang="scss">
  3553. .el-dialog__body{
  3554. padding: 0 20px 30px 20px;
  3555. }
  3556. </style>