<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class ConfigHardware extends Model
{
    use HasFactory;

    protected $table = 'config_pos_hardware';

    protected $fillable = [
        'printer1_avail','printer1_conn','printer1_spd','printer1_stdfile','printer1_autocutter','printer1_bgconnect',
        'printer1_dummy','video1_avail','video1_conn','video1_channel','video1_version','feedisplay_avail',
        'feedisplay_conn','feedisplay_paralel','feedisplay_version','bg_avail','  bg_conn   ','bg_paralel','bg_value',
        'sound_avail','sound_conn','sound_version','sound_partisi','id_pos','sizeable','pjg_lcd','video1_bright',
        'video2_avail','video2_conn','video2_channel','video2_version','video2_bright','video2_sizeable','smartcard_avail',
        'smartcard_speed','smartcard_port','printer2_avail','printer2_conn','printer2_spd','printer2_stdfile','printer2_autocutter',
        'printer2_bgconnect','printer2_dummy','bg_usb','fan1_maxval','fan2_maxval','temp1_maxval','temp2_maxval','sensor_fan1',
        'sensor_fan2','sensor_temp1','sensor_temp2','bg_type','video3_avail','video3_conn','video3_channel','video3_version',
        'video3_bright','video3_sizeale','bank_reader_avail','bank_reader_comm','mandiri_sam_pin','mandiri_reader_tid',
        'mandiri_reader_mid','bca_reader_tid','bca_reader_mid','bca_batch','bank_reader_tid','bank_reader_mid','bank_reader_key',
        'bni_tid','bni_mid','lpr_ip','lpr_avail','qrisdisp_avail','qrisdisp_speed','qrisdisp_port'
    ];

    public function posHardware() 
    {
        return $this->belongsTo(NamaPos::class, 'id_pos','id');
    }
}
