Ben Lin
2024-06-12 47df576f3a56a657b97c6179417a2d0f80441471
src/views/tigerprojects/bas/mesline/mesline.data.ts
@@ -2,11 +2,12 @@
import { FormSchema } from '/@/components/Table';
import { h } from 'vue';
import { Tag } from 'ant-design-vue';
import { getEntity } from '/@/api/tigerapi/system';
//列表显示
export const columns: BasicColumn[] = [
  {
    title: '工厂编码',
    dataIndex: 'FACTORY_CODE',
    dataIndex: 'AUTH_PROD',
    width: 180,
  },
  {
@@ -19,15 +20,15 @@
  },
  {
    title: '车间',
    dataIndex: 'WORKSHOP_CODE',
    dataIndex: 'WS_CODE',
  },
  {
    title: '组织ID',
    dataIndex: 'ORG_ID',
  },
  // {
  //   title: '组织ID',
  //   dataIndex: 'ORG_ID',
  // },
  {
    title: '班制代码',
    dataIndex: 'SHIFTTYPE_CODE',
    dataIndex: 'SFTS_CODE',
  },
  {
    title: '是否启用',
@@ -52,6 +53,11 @@
    title: '更新人',
    dataIndex: 'UPDATE_USER',
  },
  {
    title: 'ID',
    dataIndex: 'ID',
    ifShow: false,
  },
];
//模糊查询
export const searchFormSchema: FormSchema[] = [
@@ -72,10 +78,17 @@
export const formSchema: FormSchema[] = [
  {
    field: 'LINE_CODE',
    label: '产线代码',
    label: '产线编码',
    required: true,
    component: 'Input',
    colProps: { span: 8 },
    colProps: { span: 24 },
  },
  {
    field: 'LINE_NAME',
    label: '产线名称',
    required: true,
    component: 'Input',
    colProps: { span: 24 },
  },
  {
    field: 'ID',
@@ -88,42 +101,56 @@
    label: '产线名称',
    component: 'Input',
    show: false,
    colProps: { span: 8 },
    colProps: { span: 24 },
  },
  // {
  //   field: 'FACTORY_CODE',
  //   label: '工厂编码',
  //   required: true,
  //   component: 'ApiSelect',
  //   colProps: { span: 24 },
  //   componentProps: {
  //     api: getEntity,
  //     params: { entityName: 'MES_FACTORY', sqlcmd: ' 1=1 ' },
  //     resultField: 'Data.Items',
  //     labelField: 'FTY_NAME',
  //     valueField: 'FTY_CODE',
  //   },
  // },
  {
    field: 'FACTORY_CODE',
    label: '工厂编码',
    required: true,
    component: 'Input',
    colProps: { span: 8 },
  },
  {
    field: 'WORKSHOP_CODE',
    field: 'WS_CODE',
    label: '车间',
    required: true,
    component: 'Input',
    colProps: { span: 8 },
    component: 'ApiSelect',
    colProps: { span: 24 },
    componentProps: {
      api: getEntity,
      params: { entityName: 'MES_WORKSHOP', sqlcmd: ' 1=1 ' },
      resultField: 'Data.Items',
      labelField: 'WS_NAME',
      valueField: 'WS_CODE',
    },
  },
  // {
  //   field: 'ORG_ID',
  //   label: '组织ID',
  //   required: true,
  //   component: 'Input',
  //   colProps: { span: 24 },
  // },
  {
    field: 'ORG_ID',
    label: '组织ID',
    required: true,
    component: 'Input',
    colProps: { span: 8 },
  },
  {
    field: 'SHIFTTYPE_CODE',
    field: 'SFTS_CODE',
    label: '班制代码',
    required: true,
    component: 'Input',
    colProps: { span: 8 },
    colProps: { span: 24 },
  },
  {
    field: 'IS_ACTIVE',
    label: '是否启用',
    required: true,
    component: 'Select',
    colProps: { span: 8 },
    colProps: { span: 24 },
    componentProps: {
      options: [
        {