outInvoiceQuery.jsx 27 KB

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