invoiceApplyListWai.jsx 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998
  1. import React from "react";
  2. import $ from "jquery/src/ajax";
  3. import "./public.less";
  4. import {
  5. Form,
  6. Button,
  7. Input,
  8. Select,
  9. Spin,
  10. Table,
  11. message,
  12. Modal,
  13. Upload,
  14. Tabs
  15. } from "antd";
  16. import {
  17. getProjectStatus,
  18. getProvinceA,
  19. getInvoiceStatus,
  20. getProcessStatus,
  21. getprovince,
  22. getStatus,
  23. getPeople,
  24. splitUrl
  25. } from "@/tools";
  26. const FormItem = Form.Item;
  27. const {TabPane}= Tabs
  28. import OrderDesc from "../orderDetail/orderDesc";
  29. const invoiceApplyListWai = React.createClass({
  30. departmentList() {
  31. this.setState({
  32. loading: true
  33. });
  34. $.ajax({
  35. method: "get",
  36. dataType: "json",
  37. crossDomain: false,
  38. url: globalConfig.context + "/api/admin/organization/selectSuperId",
  39. data: {},
  40. success: function(data) {
  41. let thedata = data.data;
  42. let theArr = [];
  43. if (!thedata) {
  44. if (data.error && data.error.length) {
  45. message.warning(data.error[0].message);
  46. }
  47. } else {
  48. thedata.map(function(item, index) {
  49. theArr.push({
  50. key: index,
  51. name: item.name,
  52. id: item.id
  53. });
  54. });
  55. }
  56. this.setState({
  57. departmentArr: theArr
  58. });
  59. }.bind(this)
  60. }).always(
  61. function() {
  62. this.setState({
  63. loading: false
  64. });
  65. }.bind(this)
  66. );
  67. },
  68. loadData(pageNo) {
  69. this.state.data = [];
  70. this.setState({
  71. loading: true
  72. });
  73. $.ajax({
  74. method: "get",
  75. dataType: "json",
  76. crossDomain: false,
  77. url:
  78. globalConfig.context +
  79. "/api/admin/orderInvoice/financeOrderInvoiceList",
  80. data: {
  81. pageNo: pageNo || 1,
  82. pageSize: this.state.pagination.pageSize,
  83. name: this.state.nameSearch, //客户名称
  84. orderNo: this.state.orderNoSearch,
  85. orderDep: this.state.departmenttList,
  86. type: 1
  87. },
  88. success: function(data) {
  89. let theArr = [];
  90. if (!data.data || !data.data.list) {
  91. if (data.error && data.error.length) {
  92. message.warning(data.error[0].message);
  93. }
  94. } else {
  95. for (let i = 0; i < data.data.list.length; i++) {
  96. let thisdata = data.data.list[i];
  97. theArr.push({
  98. key: i,
  99. id: thisdata.id,
  100. status: thisdata.status,
  101. unitName: thisdata.unitName,
  102. orderNo: thisdata.orderno,
  103. name: thisdata.name,
  104. projectStatus: thisdata.projectStatus,
  105. processStatus: thisdata.processStatus,
  106. amount: thisdata.amount,
  107. sumAmount: thisdata.sumAmount,
  108. createTime: thisdata.createTime
  109. ? new Date(thisdata.createTime).toLocaleString()
  110. : "",
  111. settlementAmount: thisdata.settlementAmount,
  112. notAmount: thisdata.notAmount
  113. });
  114. }
  115. }
  116. this.state.pagination.current = data.data.pageNo;
  117. this.state.pagination.total = data.data.totalCount;
  118. if (data.data && data.data.list && !data.data.list.length) {
  119. this.state.pagination.current = 0;
  120. this.state.pagination.total = 0;
  121. }
  122. this.setState({
  123. totalPage: data.data.totalPage,
  124. dataSource: theArr,
  125. pagination: this.state.pagination
  126. });
  127. }.bind(this)
  128. }).always(
  129. function() {
  130. this.setState({
  131. loading: false
  132. });
  133. }.bind(this)
  134. );
  135. },
  136. tableRowClick(record) {
  137. this.state.RowData = record;
  138. this.setState({
  139. showDesc: true
  140. });
  141. },
  142. closeDesc(e, s) {
  143. this.state.showDesc = e;
  144. if (s) {
  145. this.loadData(this.state.page);
  146. }
  147. },
  148. invoiceData() {
  149. this.setState({
  150. loading: true
  151. });
  152. $.ajax({
  153. method: "get",
  154. dataType: "json",
  155. crossDomain: false,
  156. url:
  157. globalConfig.context + "/api/admin/orderInvoice/selectByIdOrderInvoice",
  158. data: {
  159. id: this.state.id
  160. },
  161. success: function(data) {
  162. let thisdata = data.data;
  163. this.setState({
  164. contractNo: thisdata.contractNo,
  165. orderNo: thisdata.orderNo,
  166. approval: thisdata.approval,
  167. type: thisdata.type,
  168. status: thisdata.status,
  169. remarks: thisdata.remarks,
  170. invoiceType: thisdata.invoiceType,
  171. unitName: thisdata.unitName,
  172. taxNumber: thisdata.taxNumber,
  173. amount: thisdata.amount,
  174. banks: thisdata.banks,
  175. content: thisdata.content,
  176. unitAddress: thisdata.unitAddress,
  177. invoiceRemarks: thisdata.invoiceRemarks,
  178. unitMobile: thisdata.unitMobile,
  179. post: thisdata.post,
  180. addressee: thisdata.addressee,
  181. addresseeMobile: thisdata.addresseeMobile,
  182. addresseeProvince: thisdata.addresseeProvince,
  183. addresseeCity: thisdata.addresseeCity,
  184. addresseeArea: thisdata.addresseeArea,
  185. alreadyAmount: thisdata.alreadyAmount,
  186. recipientAddress: thisdata.recipientAddress,
  187. orgCodeUrl: thisdata.voucherUrl
  188. ? splitUrl(
  189. thisdata.voucherUrl,
  190. ",",
  191. globalConfig.avatarHost + "/upload"
  192. )
  193. : []
  194. });
  195. }.bind(this)
  196. }).done(
  197. function() {
  198. this.setState({
  199. loading: false
  200. });
  201. }.bind(this)
  202. );
  203. },
  204. getInitialState() {
  205. return {
  206. searchMore: true,
  207. assignVisible: false,
  208. releaseDate: [],
  209. totalPage: 0,
  210. boHuivisible: false,
  211. selectedRowKeys: [],
  212. selectedRows: [],
  213. loading: false,
  214. contractNo: "",
  215. reason: "",
  216. foo: 0,
  217. pagination: {
  218. defaultCurrent: 1,
  219. defaultPageSize: 10,
  220. showQuickJumper: true,
  221. pageSize: 10,
  222. onChange: function(page) {
  223. this.loadData(page);
  224. }.bind(this),
  225. showTotal: function(total) {
  226. return "共" + total + "条数据";
  227. }
  228. },
  229. columns: [
  230. {
  231. title: "编号",
  232. dataIndex: "id",
  233. key: "id",
  234. },
  235. {
  236. title: "客户",
  237. dataIndex: "unitName",
  238. key: "unitName"
  239. },
  240. {
  241. title: "跟单人/签单人",
  242. dataIndex: "name",
  243. key: "name"
  244. },
  245. {
  246. title: "开票状态",
  247. dataIndex: "status",
  248. key: "status",
  249. render: text => {
  250. return getStatus(text);
  251. }
  252. },
  253. {
  254. title: "流程状态",
  255. dataIndex: "processStatus",
  256. key: "processStatus",
  257. render: text => {
  258. return getProcessStatus(text);
  259. }
  260. },
  261. {
  262. title: "项目状态",
  263. dataIndex: "projectStatus",
  264. key: "projectStatus",
  265. render: text => {
  266. return getProjectStatus(text);
  267. }
  268. },
  269. {
  270. title: "申请开票(万)",
  271. dataIndex: "amount",
  272. key: "amount"
  273. },
  274. {
  275. title: "已开票(万)",
  276. dataIndex: "sumAmount",
  277. key: "sumAmount"
  278. },
  279. {
  280. title: "已收款",
  281. dataIndex: "settlementAmount",
  282. key: "settlementAmount"
  283. },
  284. {
  285. title: "未收款",
  286. dataIndex: "notAmount",
  287. key: "notAmount"
  288. },
  289. {
  290. title: "申请时间",
  291. dataIndex: "createTime",
  292. key: "createTime"
  293. },
  294. {
  295. title: "操作",
  296. dataIndex: "caozuo",
  297. key: "caouzo",
  298. render: (_text, record, index) => {
  299. return (
  300. <div>
  301. {
  302. <Button
  303. type="primary"
  304. onClick={e => {
  305. e.stopPropagation(), this.visit(index);
  306. }}
  307. style={{ background: "deepskyblue", border: "none" }}
  308. >
  309. 申请内容
  310. </Button>
  311. }
  312. {record.status !== 2 ? (
  313. <Button
  314. type="primary"
  315. style={{ marginLeft: "10px" }}
  316. onClick={e => {
  317. e.stopPropagation(),
  318. this.setState({ examine: 2 }, () => {
  319. this.sende(record);
  320. });
  321. }}
  322. >
  323. 通过
  324. </Button>
  325. ) : (
  326. ""
  327. )}
  328. {record.status !== 2 ? (
  329. <Button
  330. type="danger"
  331. onClick={e => {
  332. e.stopPropagation(),
  333. this.setState({ examine: 3 }, () => {
  334. this.reject(record);
  335. });
  336. }}
  337. style={{ marginLeft: "10px" }}
  338. >
  339. 拒绝
  340. </Button>
  341. ) : (
  342. ""
  343. )}
  344. {record.status === 2 ? (
  345. <Button
  346. style={{ marginLeft: "10px", color: "black" }}
  347. disabled={true}
  348. >
  349. 已通过
  350. </Button>
  351. ) : (
  352. ""
  353. )}
  354. {
  355. <Button
  356. type="primary"
  357. style={{
  358. marginLeft: "10px",
  359. background: "orangered",
  360. border: "none"
  361. }}
  362. onClick={e => {
  363. e.stopPropagation(), this.inRecord(record, index);
  364. }}
  365. >
  366. 开票记录
  367. </Button>
  368. }
  369. </div>
  370. );
  371. }
  372. }
  373. ],
  374. columnsDate: [
  375. {
  376. title: "编号",
  377. dataIndex: "id",
  378. key: "id"
  379. },
  380. {
  381. title: "订单编号",
  382. dataIndex: "orderno",
  383. key: "orderno"
  384. },
  385. {
  386. title: "开票金额(万元)",
  387. dataIndex: "amount",
  388. key: "amount"
  389. },
  390. {
  391. title: "申请时间",
  392. dataIndex: "createTime",
  393. key: "createTime"
  394. },
  395. {
  396. title: "开票状态",
  397. dataIndex: "status",
  398. key: "status",
  399. render: text => {
  400. return getInvoiceStatus(text);
  401. }
  402. }
  403. ],
  404. dataSource: [],
  405. searchTime: [,]
  406. };
  407. },
  408. loadSend(record) {
  409. this.setState({
  410. loading: true
  411. });
  412. if (this.state.examine === 3 && this.state.reason === "") {
  413. message.warning("拒绝理由不能为空!");
  414. return;
  415. }
  416. $.ajax({
  417. method: "post",
  418. dataType: "json",
  419. crossDomain: false,
  420. url: globalConfig.context + "/api/admin/orderInvoice/financeExamine",
  421. data: {
  422. id: this.state.examine === 2 ? record.id : this.state.id,
  423. examine: this.state.examine,
  424. reason: this.state.reason
  425. },
  426. success: function() {}.bind(this)
  427. }).done(
  428. function() {
  429. this.setState({
  430. loading: false
  431. });
  432. if (this.state.examine === 2) {
  433. message.success("通过成功!");
  434. this.loadData();
  435. } else {
  436. message.success("拒绝成功!");
  437. this.resetReason();
  438. this.rejectCancels();
  439. this.loadData();
  440. }
  441. }.bind(this)
  442. );
  443. },
  444. //重置拒绝理由
  445. resetReason() {
  446. this.setState({
  447. reason: ""
  448. });
  449. },
  450. sende(record) {
  451. this.loadSend(record);
  452. },
  453. commit() {
  454. this.loadSend();
  455. this.setState({
  456. avisible: false
  457. });
  458. },
  459. visit(index) {
  460. this.setState(
  461. {
  462. id: this.state.dataSource[index].id,
  463. avisible: true
  464. },
  465. () => {
  466. this.invoiceData();
  467. }
  468. );
  469. },
  470. visitCancels() {
  471. this.setState({
  472. avisible: false
  473. });
  474. },
  475. reject(record) {
  476. this.setState({
  477. visibleR: true,
  478. id: record.id
  479. });
  480. },
  481. rejectCancels() {
  482. this.setState({
  483. visibleR: false
  484. });
  485. },
  486. inRecordData() {
  487. this.setState({
  488. loading: true
  489. });
  490. $.ajax({
  491. method: "get",
  492. dataType: "json",
  493. crossDomain: false,
  494. url:
  495. globalConfig.context +
  496. "/api/admin/orderInvoice/salesmanOrderInvoiceList",
  497. data: {
  498. orderNo: this.state.orderNo2
  499. },
  500. success: function(data) {
  501. let theArr = [];
  502. let sum = 0;
  503. if (!data.data) {
  504. if (data.error && data.error.length) {
  505. message.warning(data.error[0].message);
  506. }
  507. } else {
  508. for (let i = 0; i < data.data.list.length; i++) {
  509. let thisdata = data.data.list[i];
  510. sum += parseFloat(thisdata.amount);
  511. theArr.push({
  512. id: thisdata.id,
  513. orderno: thisdata.orderno, //订单编号
  514. amount: thisdata.amount, //签单金额
  515. createTime: thisdata.createTime, //流程状态
  516. status: thisdata.status, //结算状态
  517. rejectReason: thisdata.rejectReason
  518. });
  519. }
  520. }
  521. this.setState({
  522. recordData: theArr,
  523. sum: sum.toFixed(4)
  524. });
  525. }.bind(this)
  526. }).done(
  527. function() {
  528. this.setState({
  529. loading: false
  530. });
  531. }.bind(this)
  532. );
  533. },
  534. inRecord(record) {
  535. this.setState(
  536. {
  537. bvisible: true,
  538. orderNo2: record.orderNo
  539. },
  540. () => {
  541. this.inRecordData();
  542. }
  543. );
  544. },
  545. inRecordCanl() {
  546. this.setState({
  547. bvisible: false
  548. });
  549. },
  550. search() {
  551. this.loadData();
  552. },
  553. componentWillMount() {
  554. this.departmentList();
  555. this.loadData();
  556. },
  557. reset() {
  558. this.state.nameSearch = "";
  559. this.state.releaseDate = [];
  560. this.state.orderNoSearch = "";
  561. this.state.processStatus = [];
  562. this.state.departmenttList = [];
  563. this.loadData();
  564. },
  565. render() {
  566. const formItemLayout = {
  567. labelCol: { span: 8 },
  568. wrapperCol: { span: 14 }
  569. };
  570. var departmentArr = this.state.departmentArr || [];
  571. return (
  572. <div className="user-content">
  573. <div className="content-title">
  574. <span>省外开票审核</span>
  575. </div>
  576. <Tabs
  577. defaultActiveKey="1"
  578. onChange={this.callback}
  579. className="test">
  580. <TabPane tab="搜索" key="1">
  581. <div className="user-search">
  582. <Input
  583. placeholder="营销员名称"
  584. value={this.state.nameSearch}
  585. onChange={e => {
  586. this.setState({ nameSearch: e.target.value });
  587. }}
  588. />
  589. <Input
  590. placeholder="订单编号"
  591. value={this.state.orderNoSearch}
  592. onChange={e => {
  593. this.setState({ orderNoSearch: e.target.value });
  594. }}
  595. />
  596. <Select
  597. placeholder="订单部门"
  598. style={{ width: 150, marginRight: 10 }}
  599. value={this.state.departmenttList}
  600. onChange={e => {
  601. this.setState({ departmenttList: e });
  602. }}
  603. >
  604. {departmentArr.map(function(item) {
  605. return <Select.Option key={item.id}>{item.name}</Select.Option>;
  606. })}
  607. </Select>
  608. <Button
  609. type="primary"
  610. onClick={this.search}
  611. style={{ marginLeft: 10 }}
  612. >
  613. 搜索
  614. </Button>
  615. <Button onClick={this.reset}>重置</Button>
  616. </div>
  617. </TabPane>
  618. </Tabs>
  619. <div className="patent-table">
  620. <Spin spinning={this.state.loading}>
  621. <Table
  622. columns={this.state.columns}
  623. scroll={{ x: 1500, y: 0 }}
  624. onRowClick={this.tableRowClick}
  625. dataSource={this.state.dataSource}
  626. pagination={this.state.pagination}
  627. bordered
  628. size="small"
  629. />
  630. </Spin>
  631. </div>
  632. <Modal
  633. visible={this.state.visibleR}
  634. className="admin-desc-content"
  635. footer=""
  636. title="拒绝理由"
  637. width="400px"
  638. onCancel={this.rejectCancels}
  639. >
  640. <Input.TextArea
  641. placeholder="请输入拒绝理由"
  642. rows={4}
  643. value={this.state.reason}
  644. onChange={e => {
  645. this.setState({ reason: e.target.value });
  646. }}
  647. ></Input.TextArea>
  648. <div className="clearfix" style={{ marginTop: "20px" }}>
  649. <Button
  650. type="primary"
  651. onClick={e => {
  652. e.stopPropagation(), this.commit();
  653. }}
  654. style={{ float: "right" }}
  655. >
  656. 提交
  657. </Button>
  658. </div>
  659. </Modal>
  660. <Modal
  661. className="admin-desc-content"
  662. footer=""
  663. title="开具发票申请单"
  664. width="900px"
  665. visible={this.state.avisible}
  666. onOk={this.visitOks}
  667. onCancel={this.visitCancels}
  668. >
  669. <Form
  670. layout="horizontal"
  671. id="demand-form"
  672. style={{ paddingBottom: "40px" }}
  673. >
  674. <Spin spinning={this.state.loading}>
  675. <div className="clearfix">
  676. <div className="clearfix">
  677. <FormItem
  678. className="half-item"
  679. {...formItemLayout}
  680. label="合同编号"
  681. >
  682. <span>{this.state.contractNo}</span>
  683. </FormItem>
  684. <FormItem
  685. className="half-item"
  686. {...formItemLayout}
  687. label="备注"
  688. >
  689. <span>{this.state.remarks}</span>
  690. </FormItem>
  691. </div>
  692. <div className="clearfix">
  693. <FormItem
  694. className="half-item"
  695. {...formItemLayout}
  696. label={
  697. <span>
  698. <strong style={{ color: "#f00" }}>*</strong>省内/外
  699. </span>
  700. }
  701. >
  702. <span>{getProvinceA(this.state.type)}</span>
  703. </FormItem>
  704. <FormItem
  705. className="half-item"
  706. {...formItemLayout}
  707. label={
  708. <span>
  709. <strong style={{ color: "#f00" }}>*</strong>特批
  710. </span>
  711. }
  712. >
  713. <span>{this.state.approval === 0 ? "否" : "是"}</span>
  714. </FormItem>
  715. </div>
  716. <hr
  717. style={{
  718. border: "1px dashed #aaa",
  719. width: "90%",
  720. margin: "auto"
  721. }}
  722. />
  723. <div style={{ marginTop: "13px", marginLeft: "16px" }}>
  724. <span style={{ fontSize: "14px" }}>发票内容</span>
  725. </div>
  726. <div className="clearfix">
  727. <FormItem
  728. className="half-item"
  729. {...formItemLayout}
  730. label={
  731. <span>
  732. <strong style={{ color: "#f00" }}>*</strong>发票类型
  733. </span>
  734. }
  735. >
  736. <span>
  737. {this.state.invoiceType === 0
  738. ? "增值税专用发票"
  739. : this.state.invoiceType === 1
  740. ? "增值税普通发票"
  741. : "其他"}
  742. </span>
  743. </FormItem>
  744. </div>
  745. <div className="clearfix">
  746. <FormItem
  747. className="half-item"
  748. {...formItemLayout}
  749. label={
  750. <span>
  751. <strong style={{ color: "#f00" }}>*</strong>单位名称
  752. </span>
  753. }
  754. >
  755. <span>{this.state.unitName}</span>
  756. </FormItem>
  757. <FormItem
  758. className="half-item"
  759. {...formItemLayout}
  760. label={
  761. <span>
  762. <strong style={{ color: "#f00" }}>*</strong>税号
  763. </span>
  764. }
  765. >
  766. <span>{this.state.taxNumber}</span>
  767. </FormItem>
  768. <FormItem
  769. className="half-item"
  770. {...formItemLayout}
  771. label={
  772. <span>
  773. <strong style={{ color: "#f00" }}>*</strong>
  774. 开票金额(万元)
  775. </span>
  776. }
  777. >
  778. <span>{this.state.amount}</span>
  779. </FormItem>
  780. <FormItem
  781. className="half-item"
  782. {...formItemLayout}
  783. label={
  784. <span>
  785. <strong style={{ color: "#f00" }}>*</strong>
  786. 开户行银行账号
  787. </span>
  788. }
  789. >
  790. <span>{this.state.banks}</span>
  791. </FormItem>
  792. <FormItem
  793. className="half-item"
  794. {...formItemLayout}
  795. label={
  796. <span>
  797. <strong style={{ color: "#f00" }}>*</strong>
  798. 开票内容及说明
  799. </span>
  800. }
  801. >
  802. <span>{this.state.content}</span>
  803. </FormItem>
  804. <FormItem
  805. className="half-item"
  806. {...formItemLayout}
  807. label={
  808. <span>
  809. <strong style={{ color: "#f00" }}>*</strong>单位地址
  810. </span>
  811. }
  812. >
  813. <span>{this.state.unitAddress}</span>
  814. </FormItem>
  815. <FormItem
  816. className="half-item"
  817. {...formItemLayout}
  818. label="备注"
  819. >
  820. <span>{this.state.invoiceRemarks}</span>
  821. </FormItem>
  822. <FormItem
  823. className="half-item"
  824. {...formItemLayout}
  825. label={
  826. <span>
  827. <strong style={{ color: "#f00" }}>*</strong>单位电话
  828. </span>
  829. }
  830. >
  831. <span>{this.state.unitMobile}</span>
  832. </FormItem>
  833. </div>
  834. <div className="clearfix">
  835. <FormItem
  836. labelCol={{ span: 4 }}
  837. wrapperCol={{ span: 18 }}
  838. label={
  839. <span>
  840. <strong style={{ color: "#f00" }}>*</strong>附件
  841. </span>
  842. }
  843. >
  844. <Upload
  845. className="demandDetailShow-upload"
  846. listType="picture-card"
  847. fileList={this.state.orgCodeUrl}
  848. onPreview={file => {
  849. this.setState({
  850. previewImage: file.url || file.thumbUrl,
  851. previewVisible: true
  852. });
  853. }}
  854. ></Upload>
  855. <Modal
  856. maskClosable={false}
  857. footer={null}
  858. visible={this.state.previewVisible}
  859. onCancel={() => {
  860. this.setState({ previewVisible: false });
  861. }}
  862. >
  863. <img
  864. alt=""
  865. style={{ width: "100%" }}
  866. src={this.state.previewImage || ""}
  867. />
  868. </Modal>
  869. </FormItem>
  870. </div>
  871. <hr
  872. style={{
  873. border: "1px dashed #aaa",
  874. width: "90%",
  875. margin: "auto"
  876. }}
  877. />
  878. <div className="clearfix" style={{ marginTop: "10px" }}>
  879. <FormItem
  880. className="half-item"
  881. {...formItemLayout}
  882. label="发票是否邮寄:"
  883. >
  884. <span>{this.state.post === 0 ? "是" : "否"}</span>
  885. </FormItem>
  886. </div>
  887. {this.state.post === 0 ? (
  888. <div>
  889. <div className="clearfix">
  890. <FormItem
  891. className="half-item"
  892. {...formItemLayout}
  893. label="收信人姓名"
  894. >
  895. <span>{this.state.addressee}</span>
  896. </FormItem>
  897. <FormItem
  898. className="half-item"
  899. {...formItemLayout}
  900. label="电话"
  901. >
  902. <span>{this.state.addresseeMobile}</span>
  903. </FormItem>
  904. </div>
  905. <div className="clearfix">
  906. <FormItem
  907. className="half-item"
  908. {...formItemLayout}
  909. label="省-市-区"
  910. >
  911. <span>
  912. {getprovince(this.state.addresseeProvince)}/
  913. {getprovince(this.state.addresseeCity)}/
  914. {getprovince(this.state.addresseeArea)}
  915. </span>
  916. </FormItem>
  917. </div>
  918. <div className="clearfix">
  919. <FormItem
  920. className="half-item"
  921. {...formItemLayout}
  922. label="详细地址"
  923. >
  924. <span>{this.state.recipientAddress}</span>
  925. </FormItem>
  926. </div>
  927. </div>
  928. ) : (
  929. ""
  930. )}
  931. <FormItem
  932. className="half-item"
  933. {...formItemLayout}
  934. label={
  935. <span>
  936. <strong style={{ color: "#f00" }}>*</strong>开票金额总计
  937. </span>
  938. }
  939. >
  940. <span>{this.state.alreadyAmount}万元</span>
  941. </FormItem>
  942. </div>
  943. </Spin>
  944. </Form>
  945. </Modal>
  946. <Modal
  947. visible={this.state.bvisible}
  948. footer=""
  949. title="开票历史记录"
  950. className="admin-desc-content"
  951. width="900px"
  952. onCancel={this.inRecordCanl}
  953. >
  954. <Spin spinning={this.state.loading}>
  955. <div className="patent-table">
  956. <Table
  957. columns={this.state.columnsDate}
  958. dataSource={this.state.recordData}
  959. pagination={false}
  960. bordered
  961. size="small"
  962. />
  963. <div className="clearfix" style={{ marginTop: "20px" }}>
  964. <FormItem
  965. className="half-item"
  966. {...formItemLayout}
  967. label={<span style={{ fontSize: "14px" }}>开票总计</span>}
  968. >
  969. <span>{this.state.sum + "(万元)"}</span>
  970. </FormItem>
  971. </div>
  972. </div>
  973. </Spin>
  974. </Modal>
  975. <OrderDesc
  976. data={this.state.RowData}
  977. showDesc={this.state.showDesc}
  978. closeDesc={this.closeDesc.bind(this)}
  979. />
  980. </div>
  981. );
  982. }
  983. });
  984. export default invoiceApplyListWai;