invoiceApplyListQuery.jsx 29 KB

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