outInvoiceQuery.jsx 29 KB

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