outSpecial.jsx 28 KB

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