outSpecial.jsx 29 KB

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