import * as z from 'zod'

export const installationConf = {
  msg: {
    placeholder: '---pilih encounter class (fhir7)',
  },
  items: [
    { value: '1', label: 'Ambulatory', code: 'AMB' },
    { value: '2', label: 'Inpatient', code: 'IMP' },
    { value: '3', label: 'Emergency', code: 'EMER' },
    { value: '4', label: 'Observation', code: 'OBSENC' },
    { value: '5', label: 'Pre-admission', code: 'PRENC' },
    { value: '6', label: 'Short Stay', code: 'SS' },
    { value: '7', label: 'Virtual', code: 'VR' },
    { value: '8', label: 'Home Health', code: 'HH' },
  ],
}

export const schemaConf = z.object({
  name: z
    .string({
      required_error: 'Nama instalasi harus diisi',
    })
    .min(3, 'Nama instalasi minimal 3 karakter'),

  code: z
    .string({
      required_error: 'Kode instalasi harus diisi',
    })
    .min(3, 'Kode instalasi minimal 3 karakter'),

  encounterClassCode: z
    .string({
      required_error: 'Kelompok encounter class harus dipilih',
    })
    .min(1, 'Kelompok encounter class harus dipilih'),
})
