
import React from 'react';
import { Button } from 'kts-components-antd-x3/lib/radio';
import { Invoice, IGood } from '../../../../src';
import { IGetBuyerListOption } from '../../../Invoice/InvoiceController/InvoiceControllerState/BuyerState';

const InvoiceController = Invoice.InvoiceController

export default () => {

  // 初始化控制器
  const controller = React.useMemo(() => new MyInvoiceController(), []);

  return (
    <>
      <Button style={{ marginBottom: 10 }} onClick={async () => { console.log('===> 当前组件状态', await controller.validateFields()); }} >获取数据</Button>
      <Invoice controller={controller} />
    </>
  );
};

// 重写 购买方 的数据源，实现 ‘获取 购买方 列表’ 方法
class MyInvoiceController extends InvoiceController {
  constructor() {
    super();
    this.state.goodsListState.columnshide = [];

    this.state.autoComplete.onItemNameBlur = async (value: any) => {
      console.log(value, 'onBuyerNameBlur - Blur');

      return new Promise((resolve, reject)=> {
          resolve([
            {
              "taxCategoryCode": "1030206030000000000",
              "productName": "醋及醋代用品",
              "shorthand": "调味品",
              "id": null,
              "specification": null,
              "createTime": null,
              "status": 1,
              "versionCode": "48.0",
              "version": "32.0",
              "startTime": "20190401",
              "endTime": null,
              "cargo": null,
              "desc": null,
              "taxRate": "13%",
              "keyword": "食醋、米醋、酒醋、啤酒醋、麦芽醋、酒精醋、水果醋、醋精",
              "summarizedItem": "N",
              "countCode": null,
              "customsItem": null,
              "updateTime": null,
              "hzx": null,
              "children": null,
              "vatspecialManagement": "",
              "pid": "1030206000000000000",
              "vatpolicyBasis": null,
              "vatspecialManagementCode": "",
              "gstpolicyBasisCode": null,
              "gstspecialManagement": null,
              "gstpolicyBasis": null
            }
          ]);

      });
      //
      // return [
      //   {
      //     "taxCategoryCode": "1030206030000000000",
      //     "productName": "醋及醋代用品",
      //     "shorthand": "调味品",
      //     "id": null,
      //     "specification": null,
      //     "createTime": null,
      //     "status": 1,
      //     "versionCode": "48.0",
      //     "version": "32.0",
      //     "startTime": "20190401",
      //     "endTime": null,
      //     "cargo": null,
      //     "desc": null,
      //     "taxRate": "13%",
      //     "keyword": "食醋、米醋、酒醋、啤酒醋、麦芽醋、酒精醋、水果醋、醋精",
      //     "summarizedItem": "N",
      //     "countCode": null,
      //     "customsItem": null,
      //     "updateTime": null,
      //     "hzx": null,
      //     "children": null,
      //     "vatspecialManagement": "",
      //     "pid": "1030206000000000000",
      //     "vatpolicyBasis": null,
      //     "vatspecialManagementCode": "",
      //     "gstpolicyBasisCode": null,
      //     "gstspecialManagement": null,
      //     "gstpolicyBasis": null
      //   }
      // ]
    };

    this.state.autoComplete.onItemNameSearch = async (value: any) => {
      console.log(value, 'onItemNameSearch - Search');

      const data = [
        {
          "taxCategoryCode": "1090111090000000000",
          "productName": "苹果",
          "name": null,
          "productCode": "0003",
          "shorthand": "小型起重设备",
          "id": "10881474649024102400167947617243",
          "specification": null,
          "categoryId": "10688389540499947520167487266471",
          "categoryName": "水果",
          "internalNumber": null,
          "taxCategoryName": "轻小型起重设备配套件",
          "referenceAmount": null,
          "priceAmount": 200.00000000000000000000,
          "taxId": null,
          "taxRate": null,
          "unitId": null,
          "unitName": null,
          "taxExemptionType": null,
          "enjoyPreferentialPolicies": 0,
          "preferentialPoliciesType": null,
          "productStatus": 1,
          "specialGoodsMark": "",
          "createTime": "2023-03-22 17:09:32",
          "updateTime": "2023-03-22 17:09:32"
        }
      ];

      return data.map((item: any) =>{
        return {
          ...data,
          itemName:item.productName,
          taxClassificationCode:item.taxCategoryCode,
          itemModelName:item.specification,
          shorthand:item.shorthand,
          priceIncludeTax:item.priceAmount,
          unit:item.unitName,
          taxRate:item.taxRate,
        }
      })
    };

    this.state.goodsListState.endowCode.onSearchTaxClassificationCode = async (value: any) => {
      console.log(value, 'value-onSearchTaxClassificationCode');

      return [
        {
          "taxCategoryCode": "1030206030000000000",
          "productName": "醋及醋代用品",
          "shorthand": "调味品",
          "id": null,
          "specification": null,
          "createTime": null,
          "status": 1,
          "versionCode": "48.0",
          "version": "32.0",
          "startTime": "20190401",
          "endTime": null,
          "cargo": null,
          "desc": null,
          "taxRate": "13%",
          "keyword": "食醋、米醋、酒醋、啤酒醋、麦芽醋、酒精醋、水果醋、醋精",
          "summarizedItem": "N",
          "countCode": null,
          "customsItem": null,
          "updateTime": null,
          "hzx": null,
          "children": null,
          "vatspecialManagement": "",
          "pid": "1030206000000000000",
          "vatpolicyBasis": null,
          "vatspecialManagementCode": "",
          "gstpolicyBasisCode": null,
          "gstspecialManagement": null,
          "gstpolicyBasis": null
        }
      ]
    };

    this.state.goodsListState.endowCode.onLoadTaxClassificationCode = async (value: any) => {
      console.log(value, 'value-onSearchTaxClassificationCode');
      if(value === '3000000000000000000') {
        return [
          {
            "taxCategoryCode": "3060000000000000000",
            "productName": "金融服务",
            "shorthand": "金融服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:55:37 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "金融服务",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:55:37 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3000000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3070000000000000000",
            "productName": "生活服务",
            "shorthand": "生活服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:57:32 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:57:32 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3000000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3030000000000000000",
            "productName": "电信服务",
            "shorthand": "电信服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:43 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "电信服务",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:43 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3000000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3020000000000000000",
            "productName": "邮政服务",
            "shorthand": "邮政服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:38 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:38 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3000000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3010000000000000000",
            "productName": "交通运输服务",
            "shorthand": "运输服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:17 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "交通运输",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:17 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3000000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3050000000000000000",
            "productName": "建筑服务",
            "shorthand": "建筑服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:55:29 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:55:29 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3000000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3040000000000000000",
            "productName": "现代服务",
            "shorthand": "现代服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:54:17 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:54:17 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3000000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          }
        ]
      } else if(value === '3060000000000000000') {
        return [
          {
            "taxCategoryCode": "3060100000000000000",
            "productName": "贷款服务",
            "shorthand": "金融服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:02 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "贷款",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:02 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3060000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3060200000000000000",
            "productName": "直接收费金融服务",
            "shorthand": "金融服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:13 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "6%",
            "keyword": "货币兑换、账户管理、电子银行、信用卡、信用证、财务担保、资产管理、信托管理、基金管理、金融商品交易、资金结算、资金清算、金融支付",
            "summarizedItem": "N",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:13 CST 2023",
            "hzx": "N",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3060000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3060300000000000000",
            "productName": "保险服务",
            "shorthand": "金融服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:55:47 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:55:47 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3060000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "3060400000000000000",
            "productName": "金融商品转让",
            "shorthand": "金融服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:54:38 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "金融商品转让",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:54:38 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "3060000000000000000",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          }
        ]
      }else {
        return [
          {
            "taxCategoryCode": "3000000000000000000",
            "productName": "销售服务",
            "shorthand": "销售服务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:46 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:46 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "0",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "5000000000000000000",
            "productName": "不动产",
            "shorthand": "不动产",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:59 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:59 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "0",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "4000000000000000000",
            "productName": "无形资产",
            "shorthand": "无形资产",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:53:36 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:53:36 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "0",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "1000000000000000000",
            "productName": "货物",
            "shorthand": "货物",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:26 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:26 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "0",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "2000000000000000000",
            "productName": "劳务",
            "shorthand": "劳务",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:56:38 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:56:38 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "0",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          },
          {
            "taxCategoryCode": "6000000000000000000",
            "productName": "未发生销售行为的不征税项目",
            "shorthand": "不征税项目",
            "id": null,
            "specification": null,
            "createTime": "Tue Jun 20 14:55:06 CST 2023",
            "status": 1,
            "versionCode": "48.0",
            "version": "32.0",
            "startTime": "20190401",
            "endTime": null,
            "cargo": null,
            "desc": null,
            "taxRate": "",
            "keyword": "",
            "summarizedItem": "Y",
            "countCode": null,
            "customsItem": null,
            "updateTime": "Tue Jun 20 14:55:06 CST 2023",
            "hzx": "Y",
            "children": null,
            "vatspecialManagement": "",
            "pid": "0",
            "vatpolicyBasis": null,
            "vatspecialManagementCode": "",
            "gstpolicyBasisCode": null,
            "gstspecialManagement": null,
            "gstpolicyBasis": null
          }
        ]
      }
    };
    // 添加附加信息
    this.state.goodsListState.importGoods.columns = [
      ...this.state.goodsListState.importGoods.columns,
      {
        title: '附加信息',
        dataIndex: 'affix',
        key: 'affix',
      },
    ];

    // 设置比对方法
    this.state.goodsListState.productComparison = {
      onComply: async (e: IGood[]) => {
        // return e.map(e => {
        //   return {
        //     ...e,
        //     itemName: e.itemNameSelf + '(他方)',
        //     itemModelName: e.itemModelNameSelf + '(他方)',
        //     itemCode: e.itemCodeSelf + '(他方)',
        //   }
        // })
        return [
          {
            "itemCodeSelf": null,
            "itemNameSelf": "china",
            "itemModelNameSelf": "xx",
            "itemCode": null,
            "itemName": "中国",
            "itemModelName": "北京房山 "
          },
          {
            "itemCodeSelf": null,
            "itemNameSelf": "china",
            "itemModelNameSelf": "xx",
            "itemCode": null,
            "itemName": "中国",
            "itemModelName": "北京房山 "
          }
        ] as any
      }
    }

    this.state.en = '08'
    this.state.invoiceType = '10'
  }

  // 重写 的 获取商品列表
  getGoodsList = this.pipeline<IGetBuyerListOption>(async (state, option) => {
    if (!option) return;

    // 初始化测试数据
    const dataSource = await getMok(option.pagination.current)

    // 设置分页数据
    state.goodsListState.importGoods.pagination = {
      ...option.pagination,
      pageSize: 20,
      total: 80,
    };

    // 设置列表数据
    state.goodsListState.importGoods.dataSource = dataSource;
  });
}

// const getMok = async (current: number = 1) => {
//   const dataSource: any[] = [];
//   for (let i = 0; i < 20; i++) {
//     const p = i + 20 * (current - 1);
//     dataSource.push({
//       itemType: `商品分类${p}`,
//       itemNo: `商品编码${p}`,
//       itemName: `商品名称${p}`,
//       shorthand: `前缀${p}`,
//       itemModelName: `规格型号${p}`,
//       unit: `计量单位${p}`,
//       priceIncludeTax: p,
//       priceExcludeTax: p,
//       taxClassificationCode: `税收分类编码${p}`,
//       affix: `附加信息${p}`,
//     });
//   }
//   return dataSource;
// }


const getMok = async (current: number = 1) => {
  return [
    {
      "attributeVOList": null,
      "brandName": null,
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 2073,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2021-09-10 15:45:43.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 146200,
      "internalNumber": "发动机盖",
      "isUalityInspection": null,
      "name": "发动机ABC",
      "preferentialPoliciesType": null,
      "priceAmount": 50,
      "procurementCycle": 0,
      "shorthand": "发动机",
      "specification": "abc",
      "spuCode": "6000001738252675",
      "status": 1,
      "taxCategoryCode": "1090102040000000000",
      "taxExemptionType": "",
      "taxId": 11,
      "taxRate": null,
      "unitId": 30,
      "unitName": "件",
      "itemType": "通用",
      "itemNo": "6000001738252675",
      "itemName": "发动机ABC---",
      "itemCode": "123123",
      "itemModelName": "abc",
      "unit": "件",
      "priceIncludeTax": 50,
      "priceExcludeTax": 50,
      "taxClassificationCode": "1090102040000000000"
    },
    {
      "attributeVOList": null,
      "brandName": "丹东一号",
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 2073,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2021-09-02 14:59:52.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 146199,
      "internalNumber": null,
      "isUalityInspection": null,
      "name": "aaaa",
      "preferentialPoliciesType": null,
      "priceAmount": 0,
      "procurementCycle": 0,
      "shorthand": "活牲畜",
      "specification": null,
      "spuCode": "6000001311479375",
      "status": 1,
      "taxCategoryCode": "1010301010000000000",
      "taxExemptionType": "1",
      "taxId": 1,
      "taxRate":null,
      "unitId": null,
      "unitName": null,
      "itemType": "通用",
      "itemNo": "6000001311479375",
      "itemName": "aaaa",
      "itemModelName": null,
      "unit": null,
      "priceIncludeTax": 0,
      "priceExcludeTax": 0,
      "taxClassificationCode": "1010301010000000000"
    },
    {
      "attributeVOList": null,
      "brandName": "丹东一号",
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 246,
      "categoryName": "分类cc>1",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2020-12-28 18:23:55.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 146131,
      "internalNumber": null,
      "isUalityInspection": null,
      "name": "AAAA",
      "preferentialPoliciesType": null,
      "priceAmount": null,
      "procurementCycle": 0,
      "shorthand": null,
      "specification": "1234EFF",
      "spuCode": "6000002120658581",
      "status": 1,
      "taxCategoryCode": null,
      "taxExemptionType": null,
      "taxId": null,
      "taxRate":null,
      "unitId": 362,
      "unitName": "年",
      "itemType": "分类cc>1",
      "itemNo": "6000002120658581",
      "itemName": "AAAA",
      "itemModelName": "1234EFF",
      "unit": "年",
      "priceIncludeTax": 0,
      "priceExcludeTax": 0,
      "taxClassificationCode": null
    },
    {
      "attributeVOList": null,
      "brandName": null,
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 2073,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2020-12-15 10:14:14.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 146129,
      "internalNumber": null,
      "isUalityInspection": null,
      "name": "服务费",
      "preferentialPoliciesType": null,
      "priceAmount": null,
      "procurementCycle": 0,
      "shorthand": "软件",
      "specification": null,
      "spuCode": "6000001474077629",
      "status": 1,
      "taxCategoryCode": "1060301020100000000",
      "taxExemptionType": null,
      "taxId": null,
      "taxRate":null,
      "unitId": null,
      "unitName": null,
      "itemType": "通用",
      "itemNo": "6000001474077629",
      "itemName": "服务费",
      "itemModelName": null,
      "unit": null,
      "priceIncludeTax": 0,
      "priceExcludeTax": 0,
      "taxClassificationCode": "1060301020100000000"
    },
    {
      "attributeVOList": null,
      "brandName": "丹东一号",
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 2073,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2020-10-30 15:07:05.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 145809,
      "internalNumber": "0987",
      "isUalityInspection": null,
      "name": "中科",
      "preferentialPoliciesType": null,
      "priceAmount": 1000,
      "procurementCycle": 0,
      "shorthand": "糖料",
      "specification": "12",
      "spuCode": "6000001168374126",
      "status": 1,
      "taxCategoryCode": "1010107010000000000",
      "taxExemptionType": "3",
      "taxId": 1,
      "taxRate":null,
      "unitId": 32,
      "unitName": "把",
      "itemType": "通用",
      "itemNo": "6000001168374126",
      "itemName": "中科",
      "itemModelName": "12",
      "unit": "把",
      "priceIncludeTax": 1000,
      "priceExcludeTax": 1000,
      "taxClassificationCode": "1010107010000000000"
    },
    {
      "attributeVOList": null,
      "brandName": null,
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 1862,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2019-03-22 11:06:53.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 144321,
      "internalNumber": "4302111",
      "isUalityInspection": 0,
      "name": "农用化肥2",
      "preferentialPoliciesType": "",
      "priceAmount": 90,
      "procurementCycle": 0,
      "shorthand": "肥料",
      "specification": "HLHF-211",
      "spuCode": "1000019000000056",
      "status": 1,
      "taxCategoryCode": "1000000000000000000",
      "taxExemptionType": null,
      "taxId": null,
      "taxRate":null,
      "unitId": 11,
      "unitName": "包",
      "itemType": "通用",
      "itemNo": "1000019000000056",
      "itemName": "农用化肥2",
      "itemModelName": "HLHF-211",
      "unit": "包",
      "priceIncludeTax": 90,
      "priceExcludeTax": 90,
      "taxClassificationCode": "1000000000000000000"
    },
    {
      "attributeVOList": null,
      "brandName": null,
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 1862,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2019-03-22 11:06:52.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 144320,
      "internalNumber": "4302111",
      "isUalityInspection": 0,
      "name": "园林轻化肥",
      "preferentialPoliciesType": "",
      "priceAmount": null,
      "procurementCycle": null,
      "shorthand": "肥料",
      "specification": "HLHF-211",
      "spuCode": "1000019000000055",
      "status": 1,
      "taxCategoryCode": "233WD5FG00911",
      "taxExemptionType": null,
      "taxId": null,
      "taxRate":null,
      "unitId": 11,
      "unitName": "包",
      "itemType": "通用",
      "itemNo": "1000019000000055",
      "itemName": "园林轻化肥",
      "itemModelName": "HLHF-211",
      "unit": "包",
      "priceIncludeTax": 0,
      "priceExcludeTax": 0,
      "taxClassificationCode": "233WD5FG00911"
    },
    {
      "attributeVOList": null,
      "brandName": null,
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 1862,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2019-03-06 16:06:16.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 101211,
      "internalNumber": "4302111",
      "isUalityInspection": 0,
      "name": "营养土壤",
      "preferentialPoliciesType": "",
      "priceAmount": null,
      "procurementCycle": null,
      "shorthand": "肥料",
      "specification": "HLHF-211",
      "spuCode": "1000019000000053",
      "status": 1,
      "taxCategoryCode": "233WD5FG00911",
      "taxExemptionType": null,
      "taxId": null,
      "taxRate":null,
      "unitId": 11,
      "unitName": "包",
      "itemType": "通用",
      "itemNo": "1000019000000053",
      "itemName": "营养土壤",
      "itemModelName": "HLHF-211",
      "unit": "包",
      "priceIncludeTax": 0,
      "priceExcludeTax": 0,
      "taxClassificationCode": "233WD5FG00911"
    },
    {
      "attributeVOList": null,
      "brandName": null,
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 1862,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2019-03-06 16:06:16.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 101212,
      "internalNumber": "4302111",
      "isUalityInspection": 0,
      "name": "植物营养液",
      "preferentialPoliciesType": "",
      "priceAmount": null,
      "procurementCycle": null,
      "shorthand": "肥料",
      "specification": "HLHF-211",
      "spuCode": "1000019000000054",
      "status": 1,
      "taxCategoryCode": "233WD5FG00911",
      "taxExemptionType": null,
      "taxId": null,
      "taxRate":null,
      "unitId": 11,
      "unitName": "包",
      "itemType": "通用",
      "itemNo": "1000019000000054",
      "itemName": "植物营养液",
      "itemModelName": "HLHF-211",
      "unit": "包",
      "priceIncludeTax": 0,
      "priceExcludeTax": 0,
      "taxClassificationCode": "233WD5FG00911"
    },
    {
      "attributeVOList": null,
      "brandName": null,
      "buyGroupCode": null,
      "buyGroupId": null,
      "buyGroupName": null,
      "categoryId": 1862,
      "categoryName": "通用",
      "companyId": "41daec4c-baa2-451f-b756-e26067b8657c",
      "createTime": "2019-03-05 18:15:59.0",
      "enjoyPreferentialPolicies": 0,
      "factoryCode": null,
      "factoryId": null,
      "factoryName": null,
      "id": 101203,
      "internalNumber": "4353245243",
      "isUalityInspection": 0,
      "name": "医用棉布纱布条",
      "preferentialPoliciesType": "",
      "priceAmount": null,
      "procurementCycle": null,
      "shorthand": "布料",
      "specification": "ZC11D-006",
      "spuCode": "6000000804084562",
      "status": 1,
      "taxCategoryCode": "1234567890123456789",
      "taxExemptionType": null,
      "taxId": 5,
      "taxRate": 3,
      "unitId": 3,
      "unitName": "米",
      "itemType": "通用",
      "itemNo": "6000000804084562",
      "itemName": "医用棉布纱布条",
      "itemModelName": "ZC11D-006",
      "unit": "米",
      "priceIncludeTax": 0,
      "priceExcludeTax": 0,
      "taxClassificationCode": "1234567890123456789"
    }
  ]
}
