import { FormConfig } from "/@/components/PageSearch";
import { xs_order_type_options } from "/@/utils/status";

const searchFormConfig: FormConfig = {
  formItems: [
    {
      field: "date",
      type: "date_picker",
      trigger: "change",
      otherOptions: {
        type: "daterange",
        startPlaceholder: "下单开始时间",
        endPlaceholder: "下单结束时间",
        valueFormat: "YYYY-MM-DD",
        startProp: "start_date",
        endProp: "end_date"
      }
    },
    {
      field: "status",
      type: "select",
      trigger: "change",
      placeholder: "发货单状态",
      options: [
        { value: "0", label: "待发货" },
        { value: "1", label: "待库管发货" },
        { value: "2", label: "已发货待收货" },
        { value: "3", label: "已收货" },
        { value: "4", label: "已全部退货" }
      ]
    },
    {
      field: "order_type",
      type: "select",
      trigger: "change",
      placeholder: "商品类型",
      options: xs_order_type_options
    }
  ]
};

export default searchFormConfig;
