import 'package:domain/entity/response/index_option_entity.dart';
import 'package:domain/generated/json/base/json_field.dart';
import 'package:domain/generated/json/agency_detail_entity.g.dart';
import 'dart:convert';
export 'package:domain/generated/json/agency_detail_entity.g.dart';

@JsonSerializable()
class AgencyDetailEntity {
	AgencyDetailPivot? pivot;
	@JSONField(name: "status_radios")
	List<IndexOptionEntity> statusRadios = [];
	@JSONField(name: "contract_start")
	String? contractStart;
	@JSONField(name: "contract_end")
	String? contractEnd;

	AgencyDetailEntity();

	factory AgencyDetailEntity.fromJson(Map<String, dynamic> json) => $AgencyDetailEntityFromJson(json);

	Map<String, dynamic> toJson() => $AgencyDetailEntityToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class AgencyDetailPivot {
	@JSONField(name: "id")
	String? pivotId;
	@JSONField(name: "employer_id")
	String? employerId;
	@JSONField(name: "agency_id")
	String? agencyId;
	@JSONField(name: "agency_name")
	String? agencyName;
	@JSONField(name: "uen_no")
	String? uenNo;
	@JSONField(name: "company_no")
	String? companyNo;
	@JSONField(name: "contact_person")
	String? contactPerson;
	@JSONField(name: "contact_no")
	String? contactNo;
	@JSONField(name: "contact_email")
	String? contactEmail;
	String? address;
	@JSONField(name: "contract_start")
	String? contractStart;
	@JSONField(name: "contract_end")
	String? contractEnd;
	String? attachment;
	int status = 0;
	@JSONField(name: "reg_token")
	String? regToken;
	@JSONField(name: "created_at")
	String? createdAt;
	@JSONField(name: "updated_at")
	String? updatedAt;

	AgencyDetailPivot();

	factory AgencyDetailPivot.fromJson(Map<String, dynamic> json) => $AgencyDetailPivotFromJson(json);

	Map<String, dynamic> toJson() => $AgencyDetailPivotToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}
