detailsPage.vue 55 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718
  1. <template>
  2. <div class="borderless">
  3. <div class="customer-head">
  4. <div class="customer-back">
  5. <el-button
  6. type="danger"
  7. style="border: none;background: none;color: red"
  8. icon="el-icon-arrow-left"
  9. @click="backToList"
  10. >返回列表
  11. </el-button>
  12. </div>
  13. <div class="add-customer-btn">
  14. <el-button
  15. type="primary"
  16. size="small"
  17. v-if="detailData.status == 1"
  18. class="el-button--small-yh "
  19. :disabled="form.status > 0"
  20. @click.stop="openEdit"
  21. >编辑
  22. </el-button>
  23. <el-dropdown style="margin-right: 8px;margin-left: 8px;">
  24. <el-button type="primary" size="small">
  25. 审核处理<i class="el-icon-arrow-down el-icon--right"></i>
  26. </el-button>
  27. <el-dropdown-menu slot="dropdown">
  28. <el-dropdown-item
  29. :disabled="form.status > 0"
  30. @click.native="pleaseCheck"
  31. >请核数据</el-dropdown-item
  32. >
  33. <el-dropdown-item disabled>审核进度</el-dropdown-item>
  34. <el-dropdown-item disabled>撤销请核</el-dropdown-item>
  35. </el-dropdown-menu>
  36. </el-dropdown>
  37. <el-button
  38. class="el-button--small-yh"
  39. type="primary"
  40. :disabled="loadingBtn || detailData.status == 1"
  41. size="small"
  42. @click="editCustomer"
  43. >保存数据
  44. </el-button>
  45. </div>
  46. </div>
  47. <div class="customer-main">
  48. <containerTitle title="基础资料"></containerTitle>
  49. <basic-container>
  50. <avue-form
  51. class="trading-form"
  52. ref="form"
  53. v-model="form"
  54. :option="option"
  55. />
  56. </basic-container>
  57. <containerTitle title="基础明细"></containerTitle>
  58. <basic-container>
  59. <avue-crud
  60. ref="crud"
  61. v-model="crudForm"
  62. :option="optionList"
  63. :data="dataList"
  64. :page.sync="page"
  65. :search.sync="search"
  66. :table-loading="loading"
  67. @current-change="currentChange"
  68. @size-change="sizeChange"
  69. @search-change="searchChange"
  70. @saveColumn="saveColumn"
  71. @refresh-change="refreshChange"
  72. @row-save="rowSave"
  73. @row-update="rowUpdate"
  74. :cell-style="cellStyle"
  75. :header-cell-class-name="headerCellClassName"
  76. >
  77. <template slot="menuLeft">
  78. <el-button
  79. type="primary"
  80. @click.stop="$refs.crud.rowAdd()"
  81. size="small"
  82. :disabled="detailData.status == 1"
  83. >新增</el-button
  84. >
  85. <el-button
  86. type="primary"
  87. size="small"
  88. @click="importExcel()"
  89. :disabled="detailData.status == 1"
  90. >导入
  91. </el-button>
  92. <el-button
  93. type="primary"
  94. size="small"
  95. @click.stop="openExport()"
  96. :disabled="detailData.status == 1"
  97. >导出
  98. </el-button>
  99. </template>
  100. <template slot="basicsSalaryLabel">
  101. <el-tag>基础工资:</el-tag>
  102. </template>
  103. <template slot="workloadSalaryLabel">
  104. <el-tag>工作量工资:</el-tag>
  105. </template>
  106. <template slot="awardSalaryLabel">
  107. <el-tag>奖励工资:</el-tag>
  108. </template>
  109. <template slot="dutyAllowancesLabel">
  110. <el-tag>职务津贴:</el-tag>
  111. </template>
  112. <template slot="classTeacherSubsidyLabel">
  113. <el-tag>班主任津贴:</el-tag>
  114. </template>
  115. <template slot="subsidyLabel">
  116. <el-tag>补贴项:</el-tag>
  117. </template>
  118. <template slot="deductionsLabel">
  119. <el-tag>扣除项:</el-tag>
  120. </template>
  121. <template slot="salaryLabel">
  122. <el-tag>应发工资:</el-tag>
  123. </template>
  124. <template slot="fsalaryLabel">
  125. <el-tag>实发工资:</el-tag>
  126. </template>
  127. <template
  128. slot="schoolAgeSalaryForm"
  129. slot-scope="{ column, disabled }"
  130. >
  131. <el-input
  132. :disabled="disabled"
  133. :placeholder="'请输入 ' + column.label"
  134. v-model="crudForm.schoolAgeSalary"
  135. @change="salaryAdd(crudForm)"
  136. />
  137. </template>
  138. <template
  139. slot="capitalIncreaseForm"
  140. slot-scope="{ column, disabled }"
  141. >
  142. <el-input
  143. :disabled="disabled"
  144. :placeholder="'请输入 ' + column.label"
  145. v-model="crudForm.capitalIncrease"
  146. @change="salaryAdd(crudForm)"
  147. />
  148. </template>
  149. <template
  150. slot="educationSalaryForm"
  151. slot-scope="{ column, disabled }"
  152. >
  153. <el-input
  154. :disabled="disabled"
  155. :placeholder="'请输入 ' + column.label"
  156. v-model="crudForm.educationSalary"
  157. @change="salaryAdd(crudForm)"
  158. />
  159. </template>
  160. <template slot="rankSalaryForm" slot-scope="{ column, disabled }">
  161. <el-input
  162. :disabled="disabled"
  163. :placeholder="'请输入 ' + column.label"
  164. v-model="crudForm.rankSalary"
  165. @change="salaryAdd(crudForm)"
  166. />
  167. </template>
  168. <template slot="salaryBaseForm" slot-scope="{ column, disabled }">
  169. <el-input
  170. :disabled="disabled"
  171. :placeholder="'请输入 ' + column.label"
  172. v-model="crudForm.salaryBase"
  173. @change="salaryAdd(crudForm)"
  174. />
  175. </template>
  176. <template slot="salaryBaseForm" slot-scope="{ column, disabled }">
  177. <el-input
  178. :disabled="disabled"
  179. :placeholder="'请输入 ' + column.label"
  180. v-model="crudForm.salaryBase"
  181. @change="salaryAdd(crudForm)"
  182. />
  183. </template>
  184. <template
  185. slot="performanceAwardForm"
  186. slot-scope="{ column, disabled }"
  187. >
  188. <el-input
  189. :disabled="disabled"
  190. :placeholder="'请输入 ' + column.label"
  191. v-model="crudForm.performanceAward"
  192. @change="salaryAdd(crudForm)"
  193. />
  194. </template>
  195. <template
  196. slot="momthWorkloadSalaryForm"
  197. slot-scope="{ column, disabled }"
  198. >
  199. <el-input
  200. :disabled="disabled"
  201. :placeholder="'请输入 ' + column.label"
  202. v-model="crudForm.momthWorkloadSalary"
  203. @change="salaryAdd(crudForm)"
  204. />
  205. </template>
  206. <template
  207. slot="vacationOvertimePayForm"
  208. slot-scope="{ column, disabled }"
  209. >
  210. <el-input
  211. :disabled="disabled"
  212. :placeholder="'请输入 ' + column.label"
  213. v-model="crudForm.vacationOvertimePay"
  214. @change="salaryAdd(crudForm)"
  215. />
  216. </template>
  217. <template slot="winningPrizeForm" slot-scope="{ column, disabled }">
  218. <el-input
  219. :disabled="disabled"
  220. :placeholder="'请输入 ' + column.label"
  221. v-model="crudForm.winningPrize"
  222. @change="salaryAdd(crudForm)"
  223. />
  224. </template>
  225. <template
  226. slot="leadingCadreSubsidyForm"
  227. slot-scope="{ column, disabled }"
  228. >
  229. <el-input
  230. :disabled="disabled"
  231. :placeholder="'请输入 ' + column.label"
  232. v-model="crudForm.leadingCadreSubsidy"
  233. @change="salaryAdd(crudForm)"
  234. />
  235. </template>
  236. <template
  237. slot="yearDownPerformanceForm"
  238. slot-scope="{ column, disabled }"
  239. >
  240. <el-input
  241. :disabled="disabled"
  242. :placeholder="'请输入 ' + column.label"
  243. v-model="crudForm.yearDownPerformance"
  244. @change="salaryAdd(crudForm)"
  245. />
  246. </template>
  247. <template slot="prepareLessonsForm" slot-scope="{ column, disabled }">
  248. <el-input
  249. :disabled="disabled"
  250. :placeholder="'请输入 ' + column.label"
  251. v-model="crudForm.prepareLessons"
  252. @change="salaryAdd(crudForm)"
  253. />
  254. </template>
  255. <template
  256. slot="leadingCadreSubsidyForm"
  257. slot-scope="{ column, disabled }"
  258. >
  259. <el-input
  260. :disabled="disabled"
  261. :placeholder="'请输入 ' + column.label"
  262. v-model="crudForm.leadingCadreSubsidy"
  263. @change="salaryAdd(crudForm)"
  264. />
  265. </template>
  266. <template
  267. slot="teachingResearchForm"
  268. slot-scope="{ column, disabled }"
  269. >
  270. <el-input
  271. :disabled="disabled"
  272. :placeholder="'请输入 ' + column.label"
  273. v-model="crudForm.teachingResearch"
  274. @change="salaryAdd(crudForm)"
  275. />
  276. </template>
  277. <template slot="classesForm" slot-scope="{ column, disabled }">
  278. <el-input
  279. :disabled="disabled"
  280. :placeholder="'请输入 ' + column.label"
  281. v-model="crudForm.classes"
  282. @change="salaryAdd(crudForm)"
  283. />
  284. </template>
  285. <template
  286. slot="classTeacherFeeForm"
  287. slot-scope="{ column, disabled }"
  288. >
  289. <el-input
  290. :disabled="disabled"
  291. :placeholder="'请输入 ' + column.label"
  292. v-model="crudForm.classTeacherFee"
  293. @change="salaryAdd(crudForm)"
  294. />
  295. </template>
  296. <template
  297. slot="reserveReplacementForm"
  298. slot-scope="{ column, disabled }"
  299. >
  300. <el-input
  301. :disabled="disabled"
  302. :placeholder="'请输入 ' + column.label"
  303. v-model="crudForm.reserveReplacement"
  304. @change="salaryAdd(crudForm)"
  305. />
  306. </template>
  307. <template slot="safetyFeesForm" slot-scope="{ column, disabled }">
  308. <el-input
  309. :disabled="disabled"
  310. :placeholder="'请输入 ' + column.label"
  311. v-model="crudForm.safetyFees"
  312. @change="salaryAdd(crudForm)"
  313. />
  314. </template>
  315. <template slot="classMinisterForm" slot-scope="{ column, disabled }">
  316. <el-input
  317. :disabled="disabled"
  318. :placeholder="'请输入 ' + column.label"
  319. v-model="crudForm.classMinister"
  320. @change="salaryAdd(crudForm)"
  321. />
  322. </template>
  323. <template slot="winningPrizeForm" slot-scope="{ column, disabled }">
  324. <el-input
  325. :disabled="disabled"
  326. :placeholder="'请输入 ' + column.label"
  327. v-model="crudForm.winningPrize"
  328. @change="salaryAdd(crudForm)"
  329. />
  330. </template>
  331. <template slot="newPostTrainForm" slot-scope="{ column, disabled }">
  332. <el-input
  333. :disabled="disabled"
  334. :placeholder="'请输入 ' + column.label"
  335. v-model="crudForm.newPostTrain"
  336. @change="salaryAdd(crudForm)"
  337. />
  338. </template>
  339. <template
  340. slot="vacationOvertimePayForm"
  341. slot-scope="{ column, disabled }"
  342. >
  343. <el-input
  344. :disabled="disabled"
  345. :placeholder="'请输入 ' + column.label"
  346. v-model="crudForm.vacationOvertimePay"
  347. @change="salaryAdd(crudForm)"
  348. />
  349. </template>
  350. <template
  351. slot="cadreAllowanceReservationForm"
  352. slot-scope="{ column, disabled }"
  353. >
  354. <el-input
  355. :disabled="disabled"
  356. :placeholder="'请输入 ' + column.label"
  357. v-model="crudForm.cadreAllowanceReservation"
  358. @change="salaryAdd(crudForm)"
  359. />
  360. </template>
  361. <template
  362. slot="yearDownPerformanceForm"
  363. slot-scope="{ column, disabled }"
  364. >
  365. <el-input
  366. :disabled="disabled"
  367. :placeholder="'请输入 ' + column.label"
  368. v-model="crudForm.yearDownPerformance"
  369. @change="salaryAdd(crudForm)"
  370. />
  371. </template>
  372. <template
  373. slot="yearUpPerformanceForm"
  374. slot-scope="{ column, disabled }"
  375. >
  376. <el-input
  377. :disabled="disabled"
  378. :placeholder="'请输入 ' + column.label"
  379. v-model="crudForm.yearUpPerformance"
  380. @change="salaryAdd(crudForm)"
  381. />
  382. </template>
  383. <template
  384. slot="overtimeAtWeekendForm"
  385. slot-scope="{ column, disabled }"
  386. >
  387. <el-input
  388. :disabled="disabled"
  389. :placeholder="'请输入 ' + column.label"
  390. v-model="crudForm.overtimeAtWeekend"
  391. @change="salaryAdd(crudForm)"
  392. />
  393. </template>
  394. <template
  395. slot="maternityLeaveSalaryForm"
  396. slot-scope="{ column, disabled }"
  397. >
  398. <el-input
  399. :disabled="disabled"
  400. :placeholder="'请输入 ' + column.label"
  401. v-model="crudForm.maternityLeaveSalary"
  402. @change="salaryAdd(crudForm)"
  403. />
  404. </template>
  405. <template slot="wxForm" slot-scope="{ column, disabled }">
  406. <el-input
  407. :disabled="disabled"
  408. :placeholder="'请输入 ' + column.label"
  409. v-model="crudForm.wx"
  410. @change="salaryAdd(crudForm)"
  411. />
  412. </template>
  413. <template
  414. slot="dormitoryManagementFeeForm"
  415. slot-scope="{ column, disabled }"
  416. >
  417. <el-input
  418. :disabled="disabled"
  419. :placeholder="'请输入 ' + column.label"
  420. v-model="crudForm.dormitoryManagementFee"
  421. @change="salaryAdd(crudForm)"
  422. />
  423. </template>
  424. <template slot="learningPowerForm" slot-scope="{ column, disabled }">
  425. <el-input
  426. :disabled="disabled"
  427. :placeholder="'请输入 ' + column.label"
  428. v-model="crudForm.learningPower"
  429. @change="salaryAdd(crudForm)"
  430. />
  431. </template>
  432. <template slot="telephoneBillForm" slot-scope="{ column, disabled }">
  433. <el-input
  434. :disabled="disabled"
  435. :placeholder="'请输入 ' + column.label"
  436. v-model="crudForm.telephoneBill"
  437. @change="salaryAdd(crudForm)"
  438. />
  439. </template>
  440. <template slot="inspectorFinesForm" slot-scope="{ column, disabled }">
  441. <el-input
  442. :disabled="disabled"
  443. :placeholder="'请输入 ' + column.label"
  444. v-model="crudForm.inspectorFines"
  445. @change="salaryAdd(crudForm)"
  446. />
  447. </template>
  448. <template slot="attendanceForm" slot-scope="{ column, disabled }">
  449. <el-input
  450. :disabled="disabled"
  451. :placeholder="'请输入 ' + column.label"
  452. v-model="crudForm.attendance"
  453. @change="salaryAdd(crudForm)"
  454. />
  455. </template>
  456. <template
  457. slot="childbirthAllowanceForm"
  458. slot-scope="{ column, disabled }"
  459. >
  460. <el-input
  461. :disabled="disabled"
  462. :placeholder="'请输入 ' + column.label"
  463. v-model="crudForm.childbirthAllowance"
  464. @change="salaryAdd(crudForm)"
  465. />
  466. </template>
  467. <template slot="androidItForm" slot-scope="{ column, disabled }">
  468. <el-input
  469. :disabled="disabled"
  470. :placeholder="'请输入 ' + column.label"
  471. v-model="crudForm.androidIt"
  472. @change="salaryAdd(crudForm)"
  473. />
  474. </template>
  475. <template slot="basicsSalaryForm" slot-scope="{ column, disabled }">
  476. <el-input
  477. :disabled="disabled"
  478. :placeholder="'请输入 ' + column.label"
  479. v-model="crudForm.basicsSalary"
  480. @change="salaryAdd(crudForm)"
  481. />
  482. </template>
  483. <template
  484. slot="customWorkloadSalaryForm"
  485. slot-scope="{ column, disabled }"
  486. >
  487. <el-input
  488. :disabled="disabled"
  489. :placeholder="'请输入 ' + column.label"
  490. v-model="crudForm.customWorkloadSalary"
  491. @change="salaryAdd(crudForm)"
  492. />
  493. </template>
  494. <template slot="workloadSalaryForm" slot-scope="{ column, disabled }">
  495. <el-input
  496. :disabled="disabled"
  497. :placeholder="'请输入 ' + column.label"
  498. v-model="crudForm.workloadSalary"
  499. @change="salaryAdd(crudForm)"
  500. />
  501. </template>
  502. <template
  503. slot="dailyAssessmentSalaryForm"
  504. slot-scope="{ column, disabled }"
  505. >
  506. <el-input
  507. :disabled="disabled"
  508. :placeholder="'请输入 ' + column.label"
  509. v-model="crudForm.dailyAssessmentSalary"
  510. @change="salaryAdd(crudForm)"
  511. />
  512. </template>
  513. <template slot="awardSalaryForm" slot-scope="{ column, disabled }">
  514. <el-input
  515. :disabled="disabled"
  516. :placeholder="'请输入 ' + column.label"
  517. v-model="crudForm.awardSalary"
  518. @change="salaryAdd(crudForm)"
  519. />
  520. </template>
  521. <template slot="dutyAllowancesForm" slot-scope="{ column, disabled }">
  522. <el-input
  523. :disabled="disabled"
  524. :placeholder="'请输入 ' + column.label"
  525. v-model="crudForm.dutyAllowances"
  526. @change="salaryAdd(crudForm)"
  527. />
  528. </template>
  529. <template
  530. slot="classTeacherSubsidyForm"
  531. slot-scope="{ column, disabled }"
  532. >
  533. <el-input
  534. :disabled="disabled"
  535. :placeholder="'请输入 ' + column.label"
  536. v-model="crudForm.classTeacherSubsidy"
  537. @change="salaryAdd(crudForm)"
  538. />
  539. </template>
  540. <template slot="subsidyForm" slot-scope="{ column, disabled }">
  541. <el-input
  542. :disabled="disabled"
  543. :placeholder="'请输入 ' + column.label"
  544. v-model="crudForm.subsidy"
  545. @change="salaryAdd(crudForm)"
  546. />
  547. </template>
  548. <template slot="deductionsForm" slot-scope="{ column, disabled }">
  549. <el-input
  550. :disabled="disabled"
  551. :placeholder="'请输入 ' + column.label"
  552. v-model="crudForm.deductions"
  553. @change="salaryAdd(crudForm)"
  554. />
  555. </template>
  556. <template
  557. slot="insurancePersonageForm"
  558. slot-scope="{ column, disabled }"
  559. >
  560. <el-input
  561. :disabled="disabled"
  562. :placeholder="'请输入 ' + column.label"
  563. v-model="crudForm.insurancePersonage"
  564. @change="salaryAdd(crudForm)"
  565. />
  566. </template>
  567. <template
  568. slot="reservedFundsPersonageForm"
  569. slot-scope="{ column, disabled }"
  570. >
  571. <el-input
  572. :disabled="disabled"
  573. :placeholder="'请输入 ' + column.label"
  574. v-model="crudForm.reservedFundsPersonage"
  575. @change="salaryAdd(crudForm)"
  576. />
  577. </template>
  578. <template slot="salaryForm" slot-scope="{ column, disabled }">
  579. <el-input
  580. :disabled="disabled"
  581. :placeholder="'请输入 ' + column.label"
  582. v-model="crudForm.salary"
  583. @change="salaryAdd(crudForm)"
  584. />
  585. </template>
  586. <template slot="personageTaxesForm" slot-scope="{ column, disabled }">
  587. <el-input
  588. :disabled="disabled"
  589. :placeholder="'请输入 ' + column.label"
  590. v-model="crudForm.personageTaxes"
  591. @change="salaryAdd(crudForm)"
  592. />
  593. </template>
  594. <template
  595. slot="insurancePersonageForm"
  596. slot-scope="{ column, disabled }"
  597. >
  598. <el-input
  599. :disabled="disabled"
  600. :placeholder="'请输入 ' + column.label"
  601. v-model="crudForm.insurancePersonage"
  602. @change="salaryAdd(crudForm)"
  603. />
  604. </template>
  605. <template
  606. slot="reservedFundsPersonageForm"
  607. slot-scope="{ column, disabled }"
  608. >
  609. <el-input
  610. :disabled="disabled"
  611. :placeholder="'请输入 ' + column.label"
  612. v-model="crudForm.reservedFundsPersonage"
  613. @change="salaryAdd(crudForm)"
  614. />
  615. </template>
  616. <template slot-scope="{ row, index }" slot="menu">
  617. <el-button
  618. type="text"
  619. size="small"
  620. @click.stop="$refs.crud.rowEdit(row, index)"
  621. :disabled="detailData.status == 1"
  622. >
  623. {{ row.$cellEdit ? "保存" : "编辑" }}
  624. </el-button>
  625. <el-button
  626. type="text"
  627. size="small"
  628. @click.stop="rowDel(row, index)"
  629. :disabled="detailData.status == 1"
  630. >
  631. 删除
  632. </el-button>
  633. </template>
  634. </avue-crud>
  635. <el-dialog
  636. title="导入教职工资料"
  637. append-to-body
  638. :visible.sync="excelBox"
  639. width="555px"
  640. v-dialog-drag
  641. >
  642. <avue-form
  643. :option="excelOption"
  644. v-model="excelForm"
  645. table-loading="excelLoading"
  646. :upload-after="uploadAfter"
  647. >
  648. <template slot="excelTemplate">
  649. <el-button type="primary" @click="derivation">
  650. 点击下载<i class="el-icon-download el-icon--right"></i>
  651. </el-button>
  652. </template>
  653. </avue-form>
  654. <p style="text-align: center;color: #DC0505">
  655. 温馨提示 第一次导入时请先下载模板
  656. </p>
  657. </el-dialog>
  658. </basic-container>
  659. <containerTitle title="导入附件记录"></containerTitle>
  660. <basic-container>
  661. <avue-crud
  662. :data="annexData"
  663. :option="annexOption"
  664. :page.sync="annexPage"
  665. :table-loading="annexLoading"
  666. @current-change="currentannexChange"
  667. @size-change="sizeannexChange"
  668. @saveColumn="saveannexColumn"
  669. @refresh-change="refreshannexChange"
  670. :cell-style="cellStyle"
  671. >
  672. <template slot-scope="{ row, index }" slot="menu">
  673. <el-button
  674. type="text"
  675. size="small"
  676. @click.stop="rowDownload(row, index)"
  677. >
  678. 下载
  679. </el-button>
  680. </template>
  681. </avue-crud>
  682. </basic-container>
  683. </div>
  684. </div>
  685. </template>
  686. <script>
  687. import { getToken } from "@/util/auth";
  688. import {
  689. detail,
  690. submit,
  691. delItem,
  692. itemAnnex,
  693. itemDetail,
  694. pleaseCheck
  695. } from "@/api/salaryManagement/primarySchool";
  696. import { numCal } from "@/util/calculate";
  697. import { optionList } from "./js/optionList";
  698. export default {
  699. name: "detailsPage",
  700. data() {
  701. return {
  702. annexLoading: false,
  703. crudForm: {},
  704. excelBox: false,
  705. loading: false,
  706. xcelLoading: false,
  707. loadingBtn: false,
  708. excelForm: {
  709. type: "1"
  710. },
  711. excelOption: {
  712. submitBtn: false,
  713. emptyBtn: false,
  714. column: [
  715. {
  716. label: "导入类型",
  717. prop: "type",
  718. type: "select",
  719. dicUrl: "/api/blade-system/dict-biz/dictionary?code=import_type",
  720. props: {
  721. label: "dictValue",
  722. value: "dictKey"
  723. },
  724. span: 12
  725. },
  726. {
  727. label: "模板下载",
  728. prop: "excelTemplate",
  729. formslot: true,
  730. span: 24
  731. },
  732. {
  733. label: "模板上传",
  734. prop: "excelFile",
  735. type: "upload",
  736. drag: true,
  737. loadText: "模板上传中,请稍等",
  738. span: 24,
  739. propsHttp: {
  740. res: "data"
  741. },
  742. tip: "请上传 .xls,.xlsx 标准格式文件",
  743. action: "/api/blade-school/salaryitem/import",
  744. disabled: false
  745. }
  746. ]
  747. },
  748. form: {},
  749. dataList: [],
  750. page: {
  751. pageSize: 20,
  752. currentPage: 1,
  753. total: 0,
  754. pageSizes: [
  755. 10,
  756. 20,
  757. 30,
  758. 40,
  759. 50,
  760. 100,
  761. 150,
  762. 200,
  763. 250,
  764. 300,
  765. 350,
  766. 400,
  767. 450,
  768. 500
  769. ]
  770. },
  771. drawer: false,
  772. tableHeight: 0,
  773. option: {
  774. menuBtn: false,
  775. labelWidth: 40,
  776. column: [
  777. {
  778. label: "年",
  779. prop: "annual",
  780. type: "year",
  781. valueFormat: "yyyy",
  782. rules: [
  783. {
  784. required: true,
  785. message: "",
  786. trigger: "blur"
  787. }
  788. ],
  789. span: 6,
  790. change: ({ value }) => {
  791. if (value) {
  792. this.optionList.column.forEach(e => {
  793. if (e.prop == "yearUpPerformance") {
  794. e.label = value + "年上学期绩效";
  795. }
  796. if (e.prop == "yearDownPerformance") {
  797. e.label = value + "年下学期绩效";
  798. }
  799. });
  800. }
  801. }
  802. },
  803. {
  804. label: "月",
  805. prop: "moon",
  806. type: "select",
  807. filterable: true,
  808. dicUrl: "/api/blade-system/dict-biz/dictionary?code=month",
  809. props: {
  810. label: "dictValue",
  811. value: "dictKey"
  812. },
  813. span: 6,
  814. rules: [
  815. {
  816. required: true,
  817. message: "",
  818. trigger: "blur"
  819. }
  820. ],
  821. change: ({ value }) => {
  822. if (value) {
  823. this.optionList.column.forEach(e => {
  824. if (e.prop == "monthHour") {
  825. e.label = value + "月份课时";
  826. }
  827. if (e.prop == "momthWorkloadSalary") {
  828. e.label = value + "月工作量工资";
  829. }
  830. if (e.prop == "monthViceClassFee") {
  831. e.label = value + "月副班费(预留补发)";
  832. }
  833. });
  834. }
  835. }
  836. },
  837. {
  838. label: "人数",
  839. prop: "personNumber",
  840. span: 6,
  841. disabled: true
  842. },
  843. {
  844. label: "状态",
  845. prop: "status",
  846. type: "select",
  847. span: 6,
  848. props: {
  849. label: "name",
  850. value: "code"
  851. },
  852. dicData: [
  853. {
  854. name: "录入",
  855. code: 0
  856. },
  857. {
  858. name: "申请审批",
  859. code: 1
  860. },
  861. {
  862. name: "审批中",
  863. code: 2
  864. },
  865. {
  866. name: "审批通过",
  867. code: 3
  868. }
  869. ],
  870. disabled: true
  871. },
  872. {
  873. label: "备注",
  874. prop: "remarks",
  875. type: "textarea",
  876. span: 24,
  877. minRows: 2
  878. }
  879. ]
  880. },
  881. optionList: optionList,
  882. exportUrl: "/api/blade-school/salaryitem/export/template",
  883. annexData: [],
  884. annexOption: {
  885. align: "center",
  886. menuAlign: "center",
  887. addBtn: false,
  888. border: true,
  889. index: true,
  890. viewBtn: false,
  891. editBtn: false,
  892. delBtn: false,
  893. stripe: true,
  894. menuWidth: 100,
  895. column: [
  896. {
  897. label: "文件类型",
  898. prop: "fileType",
  899. overHidden: true
  900. },
  901. {
  902. label: "文件名",
  903. prop: "cname",
  904. overHidden: true
  905. },
  906. {
  907. label: "创建时间",
  908. prop: "createTime",
  909. overHidden: true
  910. },
  911. {
  912. label: "创建人",
  913. prop: "createName",
  914. overHidden: true
  915. },
  916. {
  917. label: "备注",
  918. prop: "remarks",
  919. overHidden: true
  920. }
  921. ]
  922. },
  923. annexPage: {
  924. pageSize: 10,
  925. currentPage: 1,
  926. total: 0,
  927. pageSizes: [
  928. 10,
  929. 20,
  930. 30,
  931. 40,
  932. 50,
  933. 100,
  934. 150,
  935. 200,
  936. 250,
  937. 300,
  938. 350,
  939. 400,
  940. 450,
  941. 500
  942. ]
  943. }
  944. };
  945. },
  946. props: {
  947. detailData: {
  948. type: Object
  949. }
  950. },
  951. created() {
  952. if (this.detailData.id) {
  953. this.getDetail(this.detailData.id);
  954. }
  955. if (this.detailData.status == 1) {
  956. this.option.disabled = true;
  957. }
  958. this.optionList.height = window.innerHeight - 500;
  959. },
  960. methods: {
  961. cellStyle() {
  962. return "padding:0;height:40px;";
  963. },
  964. headerCellClassName({ row, column, rowIndex, columnIndex }) {
  965. if (
  966. column.property == "salaryBase" ||
  967. column.property == "workloadSalary" ||
  968. column.property == "dailyAssessmentSalary" ||
  969. column.property == "awardSalary" ||
  970. column.property == "dutyAllowances" ||
  971. column.property == "classTeacherSubsidy" ||
  972. column.property == "subsidy" ||
  973. column.property == "deductions" ||
  974. column.property == "insuranceUnit" ||
  975. column.property == "insurancePersonage" ||
  976. column.property == "reservedFundsUnit" ||
  977. column.property == "reservedFundsPersonage" ||
  978. column.property == "salary" ||
  979. column.property == "personageTaxes" ||
  980. column.property == "fsalary"
  981. ) {
  982. return "headerCellClass";
  983. }
  984. },
  985. getDetail(id) {
  986. detail(id).then(res => {
  987. this.form = res.data.data;
  988. this.getItemDetail();
  989. this.getitemAnnex();
  990. });
  991. },
  992. getItemDetail() {
  993. const data = {
  994. pid: this.form.id,
  995. ...this.search
  996. };
  997. this.loading = true;
  998. itemDetail(this.page.currentPage, this.page.pageSize, data)
  999. .then(res => {
  1000. this.dataList = res.data.data.records;
  1001. this.page.total = res.data.data.total;
  1002. })
  1003. .finally(() => {
  1004. this.loading = false;
  1005. });
  1006. },
  1007. getitemAnnex() {
  1008. const data = {
  1009. pid: this.form.id
  1010. };
  1011. this.annexLoading = true;
  1012. itemAnnex(this.annexPage.currentPage, this.annexPage.pageSize, data)
  1013. .then(res => {
  1014. this.annexData = res.data.data.records;
  1015. this.annexPage.total = res.data.data.total;
  1016. })
  1017. .finally(() => {
  1018. this.annexLoading = false;
  1019. });
  1020. },
  1021. rowSave(row, done, loading) {
  1022. if (!row.cname) {
  1023. loading();
  1024. return this.$message.error("请完善姓名");
  1025. }
  1026. if (!row.idNumber) {
  1027. loading();
  1028. return this.$message.error("请完善身份证号");
  1029. }
  1030. const arr = [];
  1031. arr.push(row);
  1032. submit({ ...this.form, salaryItemList: arr })
  1033. .then(res => {
  1034. this.$message.success("保存成功");
  1035. this.form = res.data.data;
  1036. this.getItemDetail();
  1037. done();
  1038. })
  1039. .finally(() => {
  1040. loading();
  1041. });
  1042. },
  1043. rowUpdate(row, index, done, loading) {
  1044. if (!row.cname) {
  1045. loading();
  1046. return this.$message.error("请完善姓名");
  1047. }
  1048. if (!row.idNumber) {
  1049. loading();
  1050. return this.$message.error("请完善身份证号");
  1051. }
  1052. const arr = [];
  1053. arr.push(row);
  1054. submit({ ...this.form, salaryItemList: arr })
  1055. .then(res => {
  1056. this.$message.success("修改成功");
  1057. this.form = res.data.data;
  1058. this.getItemDetail();
  1059. done();
  1060. })
  1061. .finally(() => {
  1062. loading();
  1063. });
  1064. },
  1065. rowCell(row, index) {
  1066. if (row.$cellEdit == true) {
  1067. if (!row.cname) {
  1068. return this.$message.error("请完善姓名");
  1069. }
  1070. if (!row.idNumber) {
  1071. return this.$message.error("请完善身份证号");
  1072. }
  1073. // if (!row.rankStandard) {
  1074. // return this.$message.error("请完善职级标准");
  1075. // }
  1076. const arr = [];
  1077. arr.push(row);
  1078. this.loading = true;
  1079. submit({ ...this.form, salaryItemList: arr })
  1080. .then(res => {
  1081. this.$message.success("保存成功");
  1082. this.form = res.data.data;
  1083. })
  1084. .finally(() => {
  1085. this.loading = false;
  1086. });
  1087. this.$set(row, "$cellEdit", false);
  1088. } else {
  1089. this.$set(row, "$cellEdit", true);
  1090. }
  1091. },
  1092. rowDel(row, index) {
  1093. this.$confirm("确定删除数据?", {
  1094. confirmButtonText: "确定",
  1095. cancelButtonText: "取消",
  1096. type: "warning"
  1097. }).then(() => {
  1098. if (row.id) {
  1099. delItem(row.id).then(res => {
  1100. this.$message({
  1101. type: "success",
  1102. message: "删除成功!"
  1103. });
  1104. this.getItemDetail();
  1105. });
  1106. } else {
  1107. this.$message({
  1108. type: "success",
  1109. message: "删除成功!"
  1110. });
  1111. this.dataList.splice(index, 1);
  1112. }
  1113. });
  1114. },
  1115. rowDownload(row) {
  1116. window.open(`${row.url}?${this.website.tokenHeader}=${getToken()}`);
  1117. },
  1118. searchChange(params, done) {
  1119. this.getItemDetail();
  1120. done();
  1121. },
  1122. currentChange(val) {
  1123. this.page.currentPage = val;
  1124. this.getItemDetail();
  1125. },
  1126. sizeChange(val) {
  1127. this.page.currentPage = 1;
  1128. this.page.pageSize = val;
  1129. this.getItemDetail();
  1130. },
  1131. refreshChange() {
  1132. this.getItemDetail();
  1133. },
  1134. currentannexChange(val) {
  1135. this.annexPage.currentPage = val;
  1136. this.getitemAnnex();
  1137. },
  1138. sizeannexChange(val) {
  1139. this.annexPage.currentPage = 1;
  1140. this.annexPage.pageSize = val;
  1141. this.getitemAnnex();
  1142. },
  1143. refreshannexChange() {
  1144. this.getitemAnnex();
  1145. },
  1146. uploadAfter(res, done, loading, column) {
  1147. this.excelBox = false;
  1148. // this.$message.success("导入成功!");
  1149. this.getItemDetail();
  1150. this.getitemAnnex();
  1151. done();
  1152. },
  1153. //修改提交触发
  1154. editCustomer() {
  1155. this.$refs["form"].validate((valid, done) => {
  1156. done();
  1157. if (valid) {
  1158. for (let i = 0; i < this.dataList.length; i++) {
  1159. if (!this.dataList[i].cname) {
  1160. return this.$message.error(
  1161. "请完善第" + Number(1 + i) + "行的姓名"
  1162. );
  1163. }
  1164. if (!this.dataList[i].idNumber) {
  1165. return this.$message.error(
  1166. "请完善第" + Number(1 + i) + "行的身份证号"
  1167. );
  1168. }
  1169. if (!this.dataList[i].rankStandard) {
  1170. return this.$message.error(
  1171. "请完善第" + Number(1 + i) + "行的职级标准"
  1172. );
  1173. }
  1174. }
  1175. this.loadingBtn = true;
  1176. submit({ ...this.form, salaryItemList: this.dataList })
  1177. .then(res => {
  1178. this.$message.success("保存成功");
  1179. this.form = res.data.data;
  1180. this.getItemDetail();
  1181. })
  1182. .finally(() => {
  1183. this.loadingBtn = false;
  1184. });
  1185. } else {
  1186. return false;
  1187. }
  1188. });
  1189. },
  1190. derivation() {
  1191. if (!this.excelForm.type) {
  1192. return this.$message.error("请选择导入类型");
  1193. }
  1194. if (!this.exportUrl) {
  1195. return this.$message.error("暂无模板文件");
  1196. }
  1197. window.open(
  1198. `${this.exportUrl}?${this.website.tokenHeader}=${getToken()}`
  1199. );
  1200. },
  1201. openExport() {
  1202. if (!this.form.id) {
  1203. return this.$message.error("请先保存数据");
  1204. }
  1205. window.open(
  1206. `/api/blade-school/salaryitem/export/teacher?${
  1207. this.website.tokenHeader
  1208. }=${getToken()}&pid=${this.form.id}`
  1209. );
  1210. },
  1211. importExcel() {
  1212. if (!this.form.id) {
  1213. return this.$message.error("请先保存数据");
  1214. }
  1215. this.excelOption.column.forEach(e => {
  1216. if (e.prop == "excelFile") {
  1217. e.data = {
  1218. id: this.form.id
  1219. };
  1220. }
  1221. });
  1222. this.excelBox = true;
  1223. },
  1224. //导出全部
  1225. exportAll() {
  1226. let opt = {
  1227. title: "工资条",
  1228. column: this.optionList.column,
  1229. data: this.dataList
  1230. };
  1231. this.$Export.excel({
  1232. title: opt.title,
  1233. columns: opt.column,
  1234. data: opt.data
  1235. });
  1236. },
  1237. salaryAdd(row) {
  1238. // 1. 基础工资 = +M153(校龄工资)+N153(增资)+O153(学历工资)+Q153(职级工资)+L153(履约奖)+R153(工资基数)
  1239. row.basicsSalary =
  1240. numCal(row.schoolAgeSalary) +
  1241. numCal(row.capitalIncrease) +
  1242. numCal(row.educationSalary) +
  1243. numCal(row.rankSalary) +
  1244. numCal(row.salaryBase) +
  1245. numCal(row.performanceAward);
  1246. // 2. 工作量工资 = V51(工作量工资)+Y51(暑假pad课课时费)
  1247. row.workloadSalary =
  1248. numCal(row.momthWorkloadSalary) +
  1249. numCal(row.vacationOvertimePay) +
  1250. numCal(row.customWorkloadSalary);
  1251. // 3. 奖励工资 = AD46(突出贡献奖) 无 +AE46(教学成绩优胜奖)+AF46(教学成绩进步奖) 无 +AG46(荣誉奖) 无 +AH46(领导干部奖励奖)+AI46(下学期教学成绩奖) 下学期绩效 +AJ46(中考奖励) 无
  1252. row.awardSalary =
  1253. numCal(row.winningPrize) +
  1254. numCal(row.leadingCadreSubsidy) +
  1255. numCal(row.yearDownPerformance);
  1256. // 4. 职务津贴 = AM46(备课组长)+AL46(领导干部补贴)+AN46(教研组长)
  1257. row.dutyAllowances =
  1258. numCal(row.prepareLessons) +
  1259. numCal(row.leadingCadreSubsidy) +
  1260. numCal(row.teachingResearch);
  1261. // 5. 班主任津贴 = AQ47(班额)+AP47(班主任费)
  1262. row.classTeacherSubsidy =
  1263. numCal(row.classes) + numCal(row.classTeacherFee);
  1264. // 6. 补贴项 = =BE49(预留补发)+BD49(餐车、周五测温、周五安全岗(预留补发))+BC49(9月副班费(预留补发))+BB49(级部长(预留发放))+BA49(期中期末考试学科优胜奖(预留发放))+AZ49(新岗岗前培训)+AY49(假期加班费)+AX49(干部补贴预留)+AW49(2020年下学期绩效)+AV49(2020年上学期绩效)+AU49(周末加班(提取))+AT49(产假工资)+AS49(微信)
  1265. row.subsidy =
  1266. numCal(row.reserveReplacement) +
  1267. numCal(row.safetyFees) +
  1268. numCal(row.monthViceClassFee) +
  1269. numCal(row.classMinister) +
  1270. numCal(row.winningPrize) +
  1271. numCal(row.newPostTrain) +
  1272. numCal(row.vacationOvertimePay) +
  1273. numCal(row.cadreAllowanceReservation) +
  1274. numCal(row.yearDownPerformance) +
  1275. numCal(row.yearUpPerformance) +
  1276. numCal(row.overtimeAtWeekend) +
  1277. numCal(row.maternityLeaveSalary) +
  1278. numCal(row.wx);
  1279. // 7. 扣除项 = =BL47(宿舍管理费)+BK47(学习强国)+BJ47(电话费)+BI47(督查罚款)+BH47(出勤)+BM47(生育津贴)+BN47(五险一金个人)
  1280. row.deductions =
  1281. numCal(row.dormitoryManagementFee) +
  1282. numCal(row.learningPower) +
  1283. numCal(row.telephoneBill) +
  1284. numCal(row.inspectorFines) +
  1285. numCal(row.attendance) +
  1286. numCal(row.childbirthAllowance) +
  1287. numCal(row.androidIt);
  1288. // 8. 应发工资 = S153(基础工资)+Z153(工作量工资)+AB153(日常考核工资)+AK153(奖励工资)+AO153(职务津贴)+AR153(班主任津贴)+BG153(补贴项)-BO153(扣除项)+BQ153(保险个人)+BS153(公积金个人)
  1289. row.salary =
  1290. numCal(row.basicsSalary) +
  1291. numCal(row.workloadSalary) +
  1292. numCal(row.dailyAssessmentSalary) +
  1293. numCal(row.awardSalary) +
  1294. numCal(row.dutyAllowances) +
  1295. numCal(row.classTeacherSubsidy) +
  1296. numCal(row.subsidy) -
  1297. numCal(row.deductions) +
  1298. numCal(row.insurancePersonage) +
  1299. numCal(row.reservedFundsPersonage);
  1300. // 9. 实发工资 = BT153(应发工资) - BU153(个税)-BQ153(保险个人)-BS153(公积金个人)
  1301. row.fsalary =
  1302. numCal(row.salary) -
  1303. numCal(row.personageTaxes) -
  1304. numCal(row.insurancePersonage) -
  1305. numCal(row.reservedFundsPersonage);
  1306. },
  1307. //导出工资条
  1308. exportSalary() {
  1309. let data = [];
  1310. for (let item in this.optionList.column) {
  1311. switch (this.optionList.column[item].prop) {
  1312. case "salaryBase":
  1313. data.push(this.optionList.column[item]);
  1314. break;
  1315. case "workloadSalary":
  1316. data.push(this.optionList.column[item]);
  1317. break;
  1318. case "dailyAssessmentSalary":
  1319. data.push(this.optionList.column[item]);
  1320. break;
  1321. case "awardSalary":
  1322. data.push(this.optionList.column[item]);
  1323. break;
  1324. case "dutyAllowances":
  1325. data.push(this.optionList.column[item]);
  1326. break;
  1327. case "classTeacherSubsidy":
  1328. data.push(this.optionList.column[item]);
  1329. break;
  1330. case "subsidy":
  1331. data.push(this.optionList.column[item]);
  1332. break;
  1333. case "deductions":
  1334. data.push(this.optionList.column[item]);
  1335. break;
  1336. case "insuranceUnit":
  1337. data.push(this.optionList.column[item]);
  1338. break;
  1339. case "insurancePersonage":
  1340. data.push(this.optionList.column[item]);
  1341. break;
  1342. case "reservedFundsUnit":
  1343. data.push(this.optionList.column[item]);
  1344. break;
  1345. case "reservedFundsPersonage":
  1346. data.push(this.optionList.column[item]);
  1347. break;
  1348. case "salary":
  1349. data.push(this.optionList.column[item]);
  1350. break;
  1351. case "personageTaxes":
  1352. data.push(this.optionList.column[item]);
  1353. break;
  1354. case "fsalary":
  1355. data.push(this.optionList.column[item]);
  1356. break;
  1357. }
  1358. }
  1359. let opt = {
  1360. title: "工资条",
  1361. column: data,
  1362. data: this.dataList
  1363. };
  1364. this.$Export.excel({
  1365. title: opt.title,
  1366. columns: opt.column,
  1367. data: opt.data
  1368. });
  1369. },
  1370. openEdit() {
  1371. const data = {
  1372. moduleName: "xxb",
  1373. tableName: "primary_school",
  1374. billId: this.form.id,
  1375. no: localStorage.getItem("browserID"),
  1376. billNo: this.form.annual + "-" + this.form.moon
  1377. };
  1378. this.inDetailsKey(this.$route.name, {
  1379. moduleName: "xxb",
  1380. tableName: "primary_school",
  1381. billId: this.form.id,
  1382. billNo: this.form.annual + "-" + this.form.moon
  1383. });
  1384. this.checkLock(data).then(res => {
  1385. if (res.data.code == 200) {
  1386. this.onLock(data);
  1387. this.detailData.status = 2;
  1388. this.option = this.$options.data().option;
  1389. }
  1390. });
  1391. },
  1392. // 请核
  1393. pleaseCheck() {
  1394. this.$confirm("您确定提交此次申请吗?", {
  1395. confirmButtonText: "确定",
  1396. cancelButtonText: "取消",
  1397. type: "warning"
  1398. }).then(() => {
  1399. const data = {
  1400. id: this.form.id,
  1401. checkType: "xsgz",
  1402. url: "/salaryManagement/primarySchool/index",
  1403. pageStatus: "this.$store.getters.domSaleStatus",
  1404. pageLabel: "小学部",
  1405. checkFlag: 2
  1406. };
  1407. pleaseCheck(data).then(res => {
  1408. this.$message.success("请核成功");
  1409. this.detailData.status = 1;
  1410. this.option.disabled = true;
  1411. this.getDetail(this.form.id);
  1412. });
  1413. });
  1414. },
  1415. //返回列表
  1416. backToList() {
  1417. if (this.form.id) {
  1418. this.unLock({
  1419. moduleName: "xxb",
  1420. tableName: "primary_school",
  1421. billId: this.form.id,
  1422. billNo: this.form.annual + "-" + this.form.moon
  1423. });
  1424. }
  1425. this.$emit("goBack");
  1426. this.leaveDetailsKey(this.$route.name);
  1427. }
  1428. },
  1429. watch: {
  1430. "excelForm.type": function(val) {
  1431. if (val) {
  1432. switch (val) {
  1433. case "1":
  1434. this.exportUrl = "/api/blade-school/salaryitem/export/template";
  1435. this.findObject(this.excelOption.column, "excelFile").action =
  1436. "/api/blade-school/salaryitem/import";
  1437. this.findObject(
  1438. this.excelOption.column,
  1439. "excelFile"
  1440. ).disabled = false;
  1441. break;
  1442. case "2":
  1443. this.exportUrl = "/api/blade-school/salaryitem/export/employ";
  1444. this.findObject(this.excelOption.column, "excelFile").action =
  1445. "/api/blade-school/salaryitem/import/employ";
  1446. this.findObject(
  1447. this.excelOption.column,
  1448. "excelFile"
  1449. ).disabled = false;
  1450. break;
  1451. case "3":
  1452. this.exportUrl =
  1453. "/api/blade-school/salaryitem/export/workloadExcel";
  1454. this.findObject(this.excelOption.column, "excelFile").action =
  1455. "/api/blade-school/salaryitem/import/workloadExcel";
  1456. this.findObject(
  1457. this.excelOption.column,
  1458. "excelFile"
  1459. ).disabled = false;
  1460. break;
  1461. case "4":
  1462. this.exportUrl =
  1463. "/api/blade-school/salaryitem/export/postAllowance";
  1464. this.findObject(this.excelOption.column, "excelFile").action =
  1465. "/api/blade-school/salaryitem/import/postAllowance";
  1466. this.findObject(
  1467. this.excelOption.column,
  1468. "excelFile"
  1469. ).disabled = false;
  1470. break;
  1471. case "5":
  1472. this.exportUrl =
  1473. "/api/blade-school/salaryitem/export/teacherSubsidy";
  1474. this.findObject(this.excelOption.column, "excelFile").action =
  1475. "/api/blade-school/salaryitem/import/teacherSubsidy";
  1476. this.findObject(
  1477. this.excelOption.column,
  1478. "excelFile"
  1479. ).disabled = false;
  1480. break;
  1481. case "6":
  1482. this.exportUrl = "/api/blade-school/salaryitem/export/position";
  1483. this.findObject(this.excelOption.column, "excelFile").action =
  1484. "/api/blade-school/salaryitem/import/position";
  1485. this.findObject(
  1486. this.excelOption.column,
  1487. "excelFile"
  1488. ).disabled = false;
  1489. break;
  1490. case "7":
  1491. this.exportUrl = "/api/blade-school/salaryitem/export/zhaPingExcel";
  1492. this.findObject(this.excelOption.column, "excelFile").action =
  1493. "/api/blade-school/salaryitem/import/zhaPingExcel";
  1494. this.findObject(
  1495. this.excelOption.column,
  1496. "excelFile"
  1497. ).disabled = false;
  1498. break;
  1499. case "9":
  1500. this.exportUrl = "/api/blade-school/salaryitem/export/overtime";
  1501. this.findObject(this.excelOption.column, "excelFile").action =
  1502. "/api/blade-school/salaryitem/import/overtime";
  1503. this.findObject(
  1504. this.excelOption.column,
  1505. "excelFile"
  1506. ).disabled = false;
  1507. break;
  1508. case "10":
  1509. this.exportUrl = "/api/blade-school/salaryitem/export/weChat";
  1510. this.findObject(this.excelOption.column, "excelFile").action =
  1511. "/api/blade-school/salaryitem/import/weChat";
  1512. this.findObject(
  1513. this.excelOption.column,
  1514. "excelFile"
  1515. ).disabled = false;
  1516. break;
  1517. case "11":
  1518. this.exportUrl = "/api/blade-school/salaryitem/export/power";
  1519. this.findObject(this.excelOption.column, "excelFile").action =
  1520. "/api/blade-school/salaryitem/import/power";
  1521. this.findObject(
  1522. this.excelOption.column,
  1523. "excelFile"
  1524. ).disabled = false;
  1525. break;
  1526. case "12":
  1527. this.exportUrl = "/api/blade-school/salaryitem/export/phoneFine";
  1528. this.findObject(this.excelOption.column, "excelFile").action =
  1529. "/api/blade-school/salaryitem/import/phoneFine";
  1530. this.findObject(
  1531. this.excelOption.column,
  1532. "excelFile"
  1533. ).disabled = false;
  1534. break;
  1535. case "13":
  1536. this.exportUrl =
  1537. "/api/blade-school/salaryitem/export/sanitationFee";
  1538. this.findObject(this.excelOption.column, "excelFile").action =
  1539. "/api/blade-school/salaryitem/import/sanitationFee";
  1540. this.findObject(
  1541. this.excelOption.column,
  1542. "excelFile"
  1543. ).disabled = false;
  1544. break;
  1545. case "14":
  1546. this.exportUrl =
  1547. "/api/blade-school/salaryitem/export/insuranceExcel";
  1548. this.findObject(this.excelOption.column, "excelFile").action =
  1549. "/api/blade-school/salaryitem/import/insuranceExcel";
  1550. this.findObject(
  1551. this.excelOption.column,
  1552. "excelFile"
  1553. ).disabled = false;
  1554. break;
  1555. case "15":
  1556. this.exportUrl =
  1557. "/api/blade-school/salaryitem/export/reservedFunds";
  1558. this.findObject(this.excelOption.column, "excelFile").action =
  1559. "/api/blade-school/salaryitem/import/reservedFunds";
  1560. this.findObject(
  1561. this.excelOption.column,
  1562. "excelFile"
  1563. ).disabled = false;
  1564. break;
  1565. case "16":
  1566. this.exportUrl =
  1567. "/api/blade-school/salaryitem/export/personalInsurance";
  1568. this.findObject(this.excelOption.column, "excelFile").action =
  1569. "/api/blade-school/salaryitem/import/personalInsurance";
  1570. this.findObject(
  1571. this.excelOption.column,
  1572. "excelFile"
  1573. ).disabled = false;
  1574. break;
  1575. case "17":
  1576. this.exportUrl =
  1577. "/api/blade-school/salaryitem/export/attendanceExcel";
  1578. this.findObject(this.excelOption.column, "excelFile").action =
  1579. "/api/blade-school/salaryitem/import/attendanceExcel";
  1580. this.findObject(
  1581. this.excelOption.column,
  1582. "excelFile"
  1583. ).disabled = false;
  1584. break;
  1585. case "19":
  1586. this.exportUrl = "/api/blade-school/salaryitem/export/payTaxes";
  1587. this.findObject(this.excelOption.column, "excelFile").action =
  1588. "/api/blade-school/salaryitem/import/payTaxes";
  1589. this.findObject(
  1590. this.excelOption.column,
  1591. "excelFile"
  1592. ).disabled = false;
  1593. break;
  1594. case "20":
  1595. this.exportUrl = "/api/blade-school/salaryitem/export/awardExcel";
  1596. this.findObject(this.excelOption.column, "excelFile").action =
  1597. "/api/blade-school/salaryitem/import/awardExcel";
  1598. this.findObject(
  1599. this.excelOption.column,
  1600. "excelFile"
  1601. ).disabled = false;
  1602. break;
  1603. case "21":
  1604. this.exportUrl =
  1605. "/api/blade-school/salaryitem/export/performanceExcel";
  1606. this.findObject(this.excelOption.column, "excelFile").action =
  1607. "/api/blade-school/salaryitem/import/performanceExcel";
  1608. this.findObject(
  1609. this.excelOption.column,
  1610. "excelFile"
  1611. ).disabled = false;
  1612. break;
  1613. case "22":
  1614. this.exportUrl =
  1615. "/api/blade-school/salaryitem/export/vacationExcel";
  1616. this.findObject(this.excelOption.column, "excelFile").action =
  1617. "/api/blade-school/salaryitem/import/vacationExcel";
  1618. this.findObject(
  1619. this.excelOption.column,
  1620. "excelFile"
  1621. ).disabled = false;
  1622. break;
  1623. case "23":
  1624. this.exportUrl =
  1625. "/api/blade-school/salaryitem/export/postTrainExcel";
  1626. this.findObject(this.excelOption.column, "excelFile").action =
  1627. "/api/blade-school/salaryitem/import/postTrainExcel";
  1628. this.findObject(
  1629. this.excelOption.column,
  1630. "excelFile"
  1631. ).disabled = false;
  1632. break;
  1633. case "24":
  1634. this.exportUrl = "/api/blade-school/salaryitem/export/leadExcel";
  1635. this.findObject(this.excelOption.column, "excelFile").action =
  1636. "/api/blade-school/salaryitem/import/leadExcel";
  1637. this.findObject(
  1638. this.excelOption.column,
  1639. "excelFile"
  1640. ).disabled = false;
  1641. break;
  1642. case "25":
  1643. this.exportUrl =
  1644. "/api/blade-school/salaryitem/export/teamLeaderExcel";
  1645. this.findObject(this.excelOption.column, "excelFile").action =
  1646. "/api/blade-school/salaryitem/import/teamLeaderExcel";
  1647. this.findObject(
  1648. this.excelOption.column,
  1649. "excelFile"
  1650. ).disabled = false;
  1651. break;
  1652. case "26":
  1653. this.exportUrl =
  1654. "/api/blade-school/salaryitem/export/prepareLessonsExcel";
  1655. this.findObject(this.excelOption.column, "excelFile").action =
  1656. "/api/blade-school/salaryitem/import/prepareLessonsExcel";
  1657. this.findObject(
  1658. this.excelOption.column,
  1659. "excelFile"
  1660. ).disabled = false;
  1661. break;
  1662. case "27":
  1663. this.exportUrl =
  1664. "/api/blade-school/salaryitem/export/eomNumberExcel";
  1665. this.findObject(this.excelOption.column, "excelFile").action =
  1666. "/api/blade-school/salaryitem/import/eomNumberExcel";
  1667. this.findObject(
  1668. this.excelOption.column,
  1669. "excelFile"
  1670. ).disabled = false;
  1671. break;
  1672. case "28":
  1673. this.exportUrl =
  1674. "/api/blade-school/salaryitem/export/teachingExcel";
  1675. this.findObject(this.excelOption.column, "excelFile").action =
  1676. "/api/blade-school/salaryitem/import/teachingExcel";
  1677. this.findObject(
  1678. this.excelOption.column,
  1679. "excelFile"
  1680. ).disabled = false;
  1681. break;
  1682. default:
  1683. this.findObject(
  1684. this.excelOption.column,
  1685. "excelFile"
  1686. ).disabled = true;
  1687. this.exportUrl = "";
  1688. }
  1689. } else {
  1690. this.findObject(this.excelOption.column, "excelFile").disabled = true;
  1691. }
  1692. }
  1693. }
  1694. };
  1695. </script>
  1696. <style>
  1697. .headerCellClass {
  1698. color: #fff !important;
  1699. background: #a4cf57 !important;
  1700. }
  1701. </style>
  1702. <style lang="scss" scoped>
  1703. .trading-form ::v-deep .el-form-item {
  1704. margin-bottom: 4px !important;
  1705. }
  1706. ::v-deep .el-form-item__error {
  1707. display: none !important;
  1708. }
  1709. </style>