outInvoiceQuery.jsx 29 KB

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