detail.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804
  1. <template>
  2. <div class="app-container">
  3. <el-row :gutter="10" class="mb8">
  4. <div class="tabSetting">
  5. <el-col :span="1.5">
  6. <el-button
  7. type="warning"
  8. icon="el-icon-download"
  9. size="mini"
  10. @click="handleExport"
  11. v-hasPermi="['warehouseBusiness:receivable:export']"
  12. >导出
  13. </el-button
  14. >
  15. </el-col>
  16. <div style="margin: 0 12px">
  17. <el-button
  18. icon="el-icon-setting"
  19. size="mini"
  20. circle
  21. @click="showSetting = !showSetting"
  22. ></el-button>
  23. </div>
  24. </div>
  25. </el-row>
  26. <el-dialog title="自定义列显示" :visible.sync="showSetting" width="700px">
  27. <div>配置排序列数据(拖动调整顺序)</div>
  28. <div style="margin-left: 17px">
  29. <el-checkbox
  30. v-model="allCheck"
  31. label="全选"
  32. @change="allChecked"
  33. ></el-checkbox>
  34. </div>
  35. <div style="padding: 4px; display: flex; justify-content: center">
  36. <draggable
  37. v-model="setRowList"
  38. group="site"
  39. animation="300"
  40. @start="onStart"
  41. @end="onEnd"
  42. handle=".indraggable"
  43. >
  44. <transition-group>
  45. <div
  46. v-for="item in setRowList"
  47. :key="item.surface"
  48. class="listStyle"
  49. >
  50. <div style="width: 500px" class="indraggable">
  51. <div class="progress" :style="{ width: item.width + 'px' }">
  52. <el-checkbox
  53. :label="item.name"
  54. v-model="item.checked"
  55. :true-label="0"
  56. :false-label="1"
  57. >{{ item.name }}
  58. </el-checkbox>
  59. </div>
  60. </div>
  61. <el-input-number
  62. v-model.number="item.width"
  63. controls-position="right"
  64. :min="1"
  65. :max="500"
  66. size="mini"
  67. ></el-input-number>
  68. </div>
  69. </transition-group>
  70. </draggable>
  71. </div>
  72. <span slot="footer" class="dialog-footer">
  73. <el-button @click="showSetting = false">取 消</el-button>
  74. <el-button @click="delRow" type="danger">重 置</el-button>
  75. <el-button type="primary" @click="save()">确 定</el-button>
  76. </span>
  77. </el-dialog>
  78. <el-table
  79. v-loading="loading"
  80. :data="receivableList"
  81. show-summary
  82. :summary-method="getSum"
  83. ref="table"
  84. :height="tableHeight"
  85. >
  86. <!-- <el-table-column type="selection" width="55" align="center" /> -->
  87. <el-table-column
  88. type="index"
  89. label="行号"
  90. align="center"
  91. width="80"
  92. fixed
  93. />
  94. <el-table-column
  95. v-for="(item, index) in getRowList"
  96. :key="index"
  97. :label="item.name"
  98. :width="item.width"
  99. :prop="item.label"
  100. align="center"
  101. :show-overflow-tooltip="true"
  102. sortable
  103. :fixed="item.fixed"
  104. >
  105. <template slot-scope="scope">
  106. <span v-if="item.label == 'fmblno'">
  107. <el-link :underline="false" type="primary">
  108. <div @click="goPage(scope.row)">
  109. {{ scope.row.fmblno }}
  110. </div></el-link>
  111. </span>
  112. <span v-else>{{ scope.row[item.label] }}</span>
  113. </template>
  114. </el-table-column>
  115. </el-table>
  116. <pagination
  117. v-show="total > 0"
  118. :total="total"
  119. :page.sync="queryParams.pageNum"
  120. :limit.sync="queryParams.pageSize"
  121. :page-sizes="[50, 100, 200, 500, 1000]"
  122. @pagination="getList"
  123. />
  124. <!-- 添加或修改库存总账对话框 -->
  125. <!-- <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>-->
  126. <!-- <el-form ref="form" :model="form" :rules="rules" label-width="80px">-->
  127. <!-- <el-form-item label="原始入库业务编号" prop="fOriginalbillno">-->
  128. <!-- <el-input v-model="form.fOriginalbillno" placeholder="请输入原始入库业务编号" />-->
  129. <!-- </el-form-item>-->
  130. <!-- <el-form-item label="上期件数" prop="fPreqty">-->
  131. <!-- <el-input v-model="form.fPreqty" placeholder="请输入上期件数" />-->
  132. <!-- </el-form-item>-->
  133. <!-- <el-form-item label="上期毛重,单位为吨,保留6位小数" prop="fPregrossweight">-->
  134. <!-- <el-input v-model="form.fPregrossweight" placeholder="请输入上期毛重,单位为吨,保留6位小数" />-->
  135. <!-- </el-form-item>-->
  136. <!-- <el-form-item label="上期净重," prop="fPrenetweight">-->
  137. <!-- <el-input v-model="form.fPrenetweight" placeholder="请输入上期净重," />-->
  138. <!-- </el-form-item>-->
  139. <!-- <el-form-item label="入库件数" prop="fQtyd">-->
  140. <!-- <el-input v-model="form.fQtyd" placeholder="请输入入库件数" />-->
  141. <!-- </el-form-item>-->
  142. <!-- <el-form-item label="入库尺码" prop="fVolumnd">-->
  143. <!-- <el-input v-model="form.fVolumnd" placeholder="请输入入库尺码" />-->
  144. <!-- </el-form-item>-->
  145. <!-- <el-form-item label="入库毛重" prop="fGrossweightd">-->
  146. <!-- <el-input v-model="form.fGrossweightd" placeholder="请输入入库毛重" />-->
  147. <!-- </el-form-item>-->
  148. <!-- <el-form-item label="入库净重" prop="fNetweightd">-->
  149. <!-- <el-input v-model="form.fNetweightd" placeholder="请输入入库净重" />-->
  150. <!-- </el-form-item>-->
  151. <!-- <el-form-item label="出口尺码" prop="fVolumnc">-->
  152. <!-- <el-input v-model="form.fVolumnc" placeholder="请输入出口尺码" />-->
  153. <!-- </el-form-item>-->
  154. <!-- <el-form-item label="出库件数" prop="fQtyc">-->
  155. <!-- <el-input v-model="form.fQtyc" placeholder="请输入出库件数" />-->
  156. <!-- </el-form-item>-->
  157. <!-- <el-form-item label="结余件数" prop="fQtyblc">-->
  158. <!-- <el-input v-model="form.fQtyblc" placeholder="请输入结余件数" />-->
  159. <!-- </el-form-item>-->
  160. <!-- <el-form-item label="出库毛重,单位为吨" prop="fGrossweightc">-->
  161. <!-- <el-input v-model="form.fGrossweightc" placeholder="请输入出库毛重,单位为吨" />-->
  162. <!-- </el-form-item>-->
  163. <!-- <el-form-item label="出库净重" prop="fNetweightc">-->
  164. <!-- <el-input v-model="form.fNetweightc" placeholder="请输入出库净重" />-->
  165. <!-- </el-form-item>-->
  166. <!-- <el-form-item label="结余毛重" prop="fGrossweightblc">-->
  167. <!-- <el-input v-model="form.fGrossweightblc" placeholder="请输入结余毛重" />-->
  168. <!-- </el-form-item>-->
  169. <!-- <el-form-item label="结余净重" prop="fNetweightblc">-->
  170. <!-- <el-input v-model="form.fNetweightblc" placeholder="请输入结余净重" />-->
  171. <!-- </el-form-item>-->
  172. <!-- <el-form-item label="箱号" prop="fCntrno">-->
  173. <!-- <el-input v-model="form.fCntrno" placeholder="请输入箱号" />-->
  174. <!-- </el-form-item>-->
  175. <!-- <el-form-item label="状态,默认 T ,正常T 停用F 下拉选择">-->
  176. <!-- <el-radio-group v-model="form.fStatus">-->
  177. <!-- <el-radio label="1">请选择字典生成</el-radio>-->
  178. <!-- </el-radio-group>-->
  179. <!-- </el-form-item>-->
  180. <!-- <el-form-item label="删除状态" prop="delFlag">-->
  181. <!-- <el-input v-model="form.delFlag" placeholder="请输入删除状态" />-->
  182. <!-- </el-form-item>-->
  183. <!-- <el-form-item label="唛头" prop="fMarks">-->
  184. <!-- <el-input v-model="form.fMarks" placeholder="请输入唛头" />-->
  185. <!-- </el-form-item>-->
  186. <!-- <el-form-item label="备注" prop="remark">-->
  187. <!-- <el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />-->
  188. <!-- </el-form-item>-->
  189. <!-- </el-form>-->
  190. <!-- <div slot="footer" class="dialog-footer">-->
  191. <!-- <el-button type="primary" @click="submitForm">确 定</el-button>-->
  192. <!-- <el-button @click="cancel">取 消</el-button>-->
  193. <!-- </div>-->
  194. <!-- </el-dialog>-->
  195. </div>
  196. </template>
  197. <script>
  198. import {
  199. selectDrDetail,
  200. exportDrDetail,
  201. listWhgenleg,
  202. getWhgenleg,
  203. delWhgenleg,
  204. addWhgenleg,
  205. updateWhgenleg,
  206. exporReceivable,
  207. } from "@/api/reportManagement/receivable";
  208. import {listWarehouse} from "@/api/basicdata/warehouse";
  209. import {listArea} from "@/api/basicdata/area";
  210. import {listGoods} from "@/api/basicdata/goods";
  211. import {listCorps} from "@/api/basicdata/corps";
  212. import {addSet, select, resetModule} from "@/api/system/set";
  213. import Cookies from "js-cookie";
  214. import draggable from "vuedraggable";
  215. export default {
  216. name: "generalLedgerDr",
  217. components: {draggable},
  218. data() {
  219. return {
  220. pickerOptions: {
  221. shortcuts: [{
  222. text: '最近一周',
  223. onClick(picker) {
  224. const end = new Date();
  225. const start = new Date();
  226. start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
  227. picker.$emit('pick', [start, end]);
  228. }
  229. }, {
  230. text: '最近一个月',
  231. onClick(picker) {
  232. const end = new Date();
  233. const start = new Date();
  234. start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
  235. picker.$emit('pick', [start, end]);
  236. }
  237. }, {
  238. text: '最近三个月',
  239. onClick(picker) {
  240. const end = new Date();
  241. const start = new Date();
  242. start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
  243. picker.$emit('pick', [start, end]);
  244. }
  245. }]
  246. },
  247. tableHeight: '0',
  248. // 货权方(客户数据)
  249. fMblnoOptions: [],
  250. // 贸易方式(数据字典),对应t_trademodels 字典
  251. fTrademodeidOptions: [],
  252. // 货物
  253. goodsOptions: [],
  254. // 仓库(仓库数据)
  255. warehouseOptions: [],
  256. kqhouseOptions: [],
  257. // 遮罩层
  258. loading: true,
  259. // 显示搜索条件
  260. showSearch: true,
  261. // 总条数
  262. total: 0,
  263. // 库存总账表格数据
  264. receivableList: [],
  265. // 弹出层标题
  266. title: "",
  267. // 是否显示弹出层
  268. open: false,
  269. // 查询参数
  270. queryParams: {
  271. pageNum: 1,
  272. pageSize: 50,
  273. fCorpid: null,
  274. fMblno: null,
  275. timeExamine: null,
  276. fToCorpid: null,
  277. fProductName: null,
  278. fMarks: null,
  279. fReconciliation: null,
  280. fBillstatus: null,
  281. },
  282. // 表单参数
  283. form: {},
  284. // 表单校验
  285. rules: {
  286. fMarks: [{required: true, message: "唛头不能为空", trigger: "blur"}],
  287. },
  288. showSetting: false,
  289. drag: false,
  290. setRowList: [],
  291. getRowList: [],
  292. tableDate: [
  293. {
  294. surface: "2",
  295. label: "ffeesName",
  296. name: "结算单位",
  297. checked: 0,
  298. width: 130,
  299. },
  300. {
  301. surface: "3",
  302. label: "fmblno",
  303. name: "提单号",
  304. checked: 0,
  305. width: 130,
  306. },
  307. {
  308. surface: "4",
  309. label: "fproductName",
  310. name: "货物名称",
  311. checked: 0,
  312. width: 130,
  313. },
  314. {
  315. surface: "5",
  316. label: "fmarks",
  317. name: "品牌",
  318. checked: 0,
  319. width: 130,
  320. },
  321. {
  322. surface: "5",
  323. label: "fBstime",
  324. name: "业务日期",
  325. checked: 0,
  326. width: 130,
  327. },
  328. {
  329. surface: "6",
  330. label: "fBilltype",
  331. name: "业务类型",
  332. checked: 0,
  333. width: 130,
  334. },
  335. {
  336. surface: "6",
  337. label: "fReviewDate",
  338. name: "审核日期",
  339. checked: 0,
  340. width: 130,
  341. },
  342. {
  343. surface: "6",
  344. label: "storageFee",
  345. name: "仓储费金额",
  346. checked: 0,
  347. width: 130,
  348. },
  349. {
  350. surface: "6",
  351. label: "otherFee",
  352. name: "其他金额",
  353. checked: 0,
  354. width: 130,
  355. },
  356. {
  357. surface: "7",
  358. label: "famount",
  359. name: "应收金额",
  360. checked: 0,
  361. width: 130,
  362. },
  363. {
  364. surface: "7",
  365. label: "fQty",
  366. name: "数量",
  367. checked: 0,
  368. width: 130,
  369. },
  370. {
  371. surface: "8",
  372. label: "price",
  373. name: "单价",
  374. checked: 0,
  375. width: 130,
  376. },
  377. {
  378. surface: "8",
  379. label: "fstlamount",
  380. name: "实收金额",
  381. checked: 0,
  382. width: 130,
  383. },
  384. {
  385. surface: "9",
  386. label: "nnfinished",
  387. name: "未收金额",
  388. checked: 0,
  389. width: 130,
  390. },
  391. {
  392. surface: "10",
  393. label: "faccamount",
  394. name: "对账金额",
  395. checked: 0,
  396. width: 130,
  397. },
  398. {
  399. surface: "11",
  400. label: "finvamount",
  401. name: "开票金额",
  402. checked: 0,
  403. width: 130,
  404. },
  405. ],
  406. allCheck: false,
  407. };
  408. },
  409. created() {
  410. this.setRowList = this.tableDate;
  411. this.getRowList = this.tableDate;
  412. // this.getList();
  413. this.getDicts("data_trademodes").then((response) => {
  414. this.fTrademodeidOptions = response.data;
  415. });
  416. this.getRow();
  417. },
  418. activated() {
  419. if (this.$route.query) {
  420. this.getList()
  421. }
  422. },
  423. mounted() {
  424. this.$nextTick(() => {
  425. // 监听浏览器高度变化,改变表格高度
  426. window.onresize = () => {
  427. this.tableHeight = window.innerHeight - this.$refs.table.$el.offsetTop - 70
  428. }
  429. })
  430. },
  431. methods: {
  432. //列设置全选
  433. allChecked() {
  434. if (this.allCheck == true) {
  435. this.setRowList.map((e) => {
  436. return (e.checked = 0);
  437. });
  438. } else {
  439. this.setRowList.map((e) => {
  440. return (e.checked = 1);
  441. });
  442. }
  443. },
  444. //查询列数据
  445. getRow() {
  446. let that = this;
  447. this.data = {
  448. tableName: "应收总账",
  449. userId: Cookies.get("userName"),
  450. };
  451. select(this.data).then((res) => {
  452. if (res.data.length != 0) {
  453. this.getRowList = res.data.filter((e) => e.checked == 0);
  454. this.setRowList = res.data;
  455. this.setRowList = this.setRowList.reduce((res, item) => {
  456. res.push({
  457. surface: item.surface,
  458. label: item.label,
  459. name: item.name,
  460. checked: item.checked,
  461. width: item.width,
  462. fixed: item.fixed,
  463. });
  464. return res;
  465. }, []);
  466. }
  467. });
  468. },
  469. delRow() {
  470. this.data = {
  471. tableName: "应收总账",
  472. userId: Cookies.get("userName"),
  473. };
  474. resetModule(this.data).then((res) => {
  475. if (res.code == 200) {
  476. this.showSetting = false;
  477. this.setRowList = this.tableDate;
  478. this.getRowList = this.tableDate;
  479. }
  480. });
  481. },
  482. //保存列设置
  483. save() {
  484. this.showSetting = false;
  485. this.data = {
  486. tableName: "应收总账",
  487. userId: Cookies.get("userName"),
  488. sysTableSetList: this.setRowList,
  489. };
  490. addSet(this.data).then((res) => {
  491. if (res.code == 200) {
  492. this.showSetting = false;
  493. this.getRowList = this.setRowList.filter((e) => e.checked == 0);
  494. }
  495. });
  496. },
  497. //开始拖拽事件
  498. onStart() {
  499. this.drag = true;
  500. },
  501. //拖拽结束事件
  502. onEnd() {
  503. this.drag = false;
  504. },
  505. getSum(param) {
  506. const {columns, data} = param;
  507. const sums = [];
  508. columns.forEach((column, index) => {
  509. if (index === 0) {
  510. sums[index] = "总计";
  511. } else if (index === 6 || index === 7 || index === 8 || index === 9 || index === 10 || index === 11) {
  512. const values = data.map((item) => Number(item[column.property]));
  513. if (!values.every((value) => isNaN(value))) {
  514. sums[index] = values.reduce((prev, curr) => {
  515. const value = Number(curr);
  516. if (!isNaN(value)) {
  517. return (Number(prev) + Number(curr)).toFixed(2)
  518. } else {
  519. return Number(prev).toFixed(2);
  520. }
  521. }, 0);
  522. }
  523. }
  524. });
  525. return sums;
  526. },
  527. // 贸易方式(数据字典),对���t_trademodels 字典翻译
  528. fTrademodeidFormat(row, column) {
  529. return this.selectDictLabel(this.fTrademodeidOptions, row.fTrademodeid);
  530. },
  531. /* 远程模糊查询仓库 */
  532. warehouseRemoteMethod(name) {
  533. if (name == null || name === "") {
  534. return false;
  535. }
  536. let queryParams = {pageNum: 1, pageSize: 10, fName: name};
  537. listWarehouse(queryParams).then((response) => {
  538. this.warehouseOptions = response.rows;
  539. });
  540. },
  541. /* 远程模糊查询库区 */
  542. kqhouseRemoteMethod(name) {
  543. if (name == null || name === "") {
  544. return false;
  545. }
  546. if (!this.queryParams.fWarehouseid) {
  547. this.$message.error("请输入仓库!");
  548. return false;
  549. }
  550. let queryParams = {
  551. pageNum: 1,
  552. pageSize: 10,
  553. fWarehouseid: this.queryParams.fWarehouseid,
  554. fName: name,
  555. };
  556. listArea(queryParams).then((response) => {
  557. this.kqhouseOptions = response.rows;
  558. });
  559. },
  560. /* 远程模糊查询商品 */
  561. goodsRemoteMethod(name) {
  562. if (name == null || name === "") {
  563. return false;
  564. }
  565. let queryParams = {pageNum: 1, pageSize: 10, fName: name};
  566. listGoods(queryParams).then((response) => {
  567. this.goodsOptions = response.rows;
  568. });
  569. },
  570. /* 远程模糊查询用户 */
  571. corpsRemoteMethod(name) {
  572. if (name == null || name === "") {
  573. return false;
  574. }
  575. let queryParams = {pageNum: 1, pageSize: 10, fName: name};
  576. listCorps(queryParams).then((response) => {
  577. this.fMblnoOptions = response.rows;
  578. this.KHblnoOptions = response.rows;
  579. });
  580. },
  581. /** 查询库存总账列表 */
  582. getList() {
  583. this.loading = true;
  584. this.getDicts("approval_process").then((response) => {
  585. this.options = response.data;
  586. });
  587. selectDrDetail(this.$route.query).then((response) => {
  588. this.receivableList = response.data;
  589. // this.total = response.total;
  590. this.loading = false;
  591. // 根据浏览器高度设置初始高度
  592. setTimeout(() => {
  593. this.tableHeight = window.innerHeight - this.$refs.table.$el.offsetTop - 70
  594. }, 300)
  595. });
  596. },
  597. // 取消按钮
  598. cancel() {
  599. this.open = false;
  600. this.reset();
  601. },
  602. // 表单重置
  603. reset() {
  604. this.form = {
  605. fAccyear: null,
  606. fId: null,
  607. fAccmonth: null,
  608. fCorpid: null,
  609. fMblno: null,
  610. fOriginalbillno: null,
  611. fWarehouseLocationid: null,
  612. fGoodsid: null,
  613. fTrademodeid: null,
  614. fPreqty: null,
  615. fPregrossweight: null,
  616. fPrenetweight: null,
  617. fQtyd: null,
  618. fVolumnd: null,
  619. fGrossweightd: null,
  620. fNetweightd: null,
  621. fVolumnc: null,
  622. fQtyc: null,
  623. fQtyblc: null,
  624. fGrossweightc: null,
  625. fNetweightc: null,
  626. fGrossweightblc: null,
  627. fNetweightblc: null,
  628. fCntrno: null,
  629. fStatus: "0",
  630. delFlag: null,
  631. createBy: null,
  632. fMarks: null,
  633. createTime: null,
  634. updateBy: null,
  635. updateTime: null,
  636. remark: null,
  637. };
  638. this.resetForm("form");
  639. },
  640. /** 搜索按钮操作 */
  641. handleQuery() {
  642. this.queryParams.pageNum = 1;
  643. this.getList();
  644. },
  645. /** 重置按钮操作 */
  646. resetQuery() {
  647. // this.resetForm("queryForm");
  648. this.resetQueryParams();
  649. this.handleQuery();
  650. },
  651. // 搜索重置
  652. resetQueryParams() {
  653. this.queryParams = {
  654. pageNum: 1,
  655. pageSize: 50,
  656. fCorpid: null,
  657. fMblno: null,
  658. timeExamine: null,
  659. fToCorpid: null,
  660. fProductName: null,
  661. fMarks: null,
  662. fReconciliation: null,
  663. fBillstatus: null,
  664. }
  665. },
  666. /** 新增按钮操作 */
  667. handleAdd() {
  668. this.reset();
  669. this.open = true;
  670. this.title = "添加库存总账";
  671. },
  672. /** 提交按钮 */
  673. submitForm() {
  674. this.$refs["form"].validate((valid) => {
  675. if (valid) {
  676. if (this.form.fAccyear != null) {
  677. updateWhgenleg(this.form).then((response) => {
  678. this.msgSuccess("修改成功");
  679. this.open = false;
  680. this.getList();
  681. });
  682. } else {
  683. addWhgenleg(this.form).then((response) => {
  684. this.msgSuccess("新增成功");
  685. this.open = false;
  686. this.getList();
  687. });
  688. }
  689. }
  690. });
  691. },
  692. /** 导出按钮操作 */
  693. handleExport() {
  694. const queryParams = this.$route.query;
  695. this.$confirm("是否确认导出所有应收总账数据项?", "警告", {
  696. confirmButtonText: "确定",
  697. cancelButtonText: "取消",
  698. type: "warning",
  699. })
  700. .then(function () {
  701. return exportDrDetail(queryParams);
  702. })
  703. .then((response) => {
  704. this.download(response.msg);
  705. });
  706. },
  707. // 去页面
  708. goPage(row) {
  709. switch (row.fBilltype) {
  710. case "入库": {
  711. this.$router.push({
  712. path: "/business/inStock",
  713. query: { id: row.fsrcpid },
  714. });
  715. break;
  716. }
  717. case "出库": {
  718. this.$router.push({
  719. path: "/business/outStock",
  720. query: { id: row.fsrcpid },
  721. });
  722. break;
  723. }
  724. case "调拨": {
  725. this.$router.push({
  726. path: "/business/stockTransfer",
  727. query: { id: row.fsrcpid },
  728. });
  729. break;
  730. }
  731. case "货权转移": {
  732. this.$router.push({
  733. path: "/business/stockTransfer",
  734. query: { id: row.fsrcpid },
  735. });
  736. break;
  737. }
  738. case "货物通关": {
  739. this.$router.push({
  740. path: "/business/cargoClearance",
  741. });
  742. break;
  743. }
  744. case "计算仓储费": {
  745. this.$router.push({
  746. path: "/business/agreement",
  747. query: { id: row.fsrcpid },
  748. });
  749. break;
  750. }
  751. case "其他账务": {
  752. this.$router.push({
  753. path: "/finance/otherFinancial",
  754. query: { id: row.fsrcpid },
  755. });
  756. break;
  757. }
  758. case "场地直装": {
  759. this.$router.push({
  760. path: "/business/inAndOutStock",
  761. query: { id: row.fsrcpid },
  762. });
  763. break;
  764. }
  765. default: {
  766. return this.$message.error("未知错误,无状态");
  767. }
  768. }
  769. },
  770. },
  771. };
  772. </script>
  773. <style lang="scss">
  774. .tabSetting {
  775. display: flex;
  776. justify-content: flex-end;
  777. }
  778. .listStyle {
  779. display: flex;
  780. border-top: 1px solid #dcdfe6;
  781. border-left: 1px solid #dcdfe6;
  782. border-right: 1px solid #dcdfe6;
  783. }
  784. .listStyle:last-child {
  785. border-bottom: 1px solid #dcdfe6;
  786. }
  787. .progress {
  788. display: flex;
  789. align-items: center;
  790. padding: 2px;
  791. background-color: rgba(0, 0, 0, 0.05);
  792. height: 100%;
  793. }
  794. </style>