mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-17 23:49:02 +01:00
19 lines
609 B
JavaScript
19 lines
609 B
JavaScript
import ForeignDocumentUUIDField from './foreignDocumentUUIDField.mjs';
|
|
|
|
export default class ItemLinkFields extends foundry.data.fields.ArrayField {
|
|
constructor(options, context) {
|
|
super(new ItemLinkField(), options, context);
|
|
}
|
|
}
|
|
|
|
class ItemLinkField extends foundry.data.fields.SchemaField {
|
|
constructor(context) {
|
|
super(
|
|
{
|
|
type: new foundry.data.fields.StringField({ choices: CONFIG.DH.ITEM.featureSubTypes, nullable: true }),
|
|
item: new ForeignDocumentUUIDField({ type: 'Item' })
|
|
},
|
|
context
|
|
);
|
|
}
|
|
}
|