You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
60 lines
1.3 KiB
60 lines
1.3 KiB
3 years ago
|
/**
|
||
|
* This module was automatically generated by `ts-interface-builder`
|
||
|
*/
|
||
|
import * as t from "ts-interface-checker";
|
||
|
// tslint:disable:object-literal-key-quotes
|
||
|
|
||
|
export const NewRecord = t.iface([], {
|
||
|
"fields": t.opt(t.iface([], {
|
||
|
[t.indexKey]: "CellValue",
|
||
|
})),
|
||
|
});
|
||
|
|
||
|
export const Record = t.iface([], {
|
||
|
"id": "number",
|
||
|
"fields": t.iface([], {
|
||
|
[t.indexKey]: "CellValue",
|
||
|
}),
|
||
|
});
|
||
|
|
||
3 years ago
|
export const AddOrUpdateRecord = t.iface([], {
|
||
|
"require": t.intersection(t.iface([], {
|
||
|
[t.indexKey]: "CellValue",
|
||
|
}), t.iface([], {
|
||
|
"id": t.opt("number"),
|
||
|
})),
|
||
|
"fields": t.opt(t.iface([], {
|
||
|
[t.indexKey]: "CellValue",
|
||
|
})),
|
||
|
});
|
||
|
|
||
3 years ago
|
export const RecordsPatch = t.iface([], {
|
||
|
"records": t.tuple("Record", t.rest(t.array("Record"))),
|
||
|
});
|
||
|
|
||
|
export const RecordsPost = t.iface([], {
|
||
|
"records": t.tuple("NewRecord", t.rest(t.array("NewRecord"))),
|
||
|
});
|
||
|
|
||
3 years ago
|
export const RecordsPut = t.iface([], {
|
||
|
"records": t.tuple("AddOrUpdateRecord", t.rest(t.array("AddOrUpdateRecord"))),
|
||
|
});
|
||
|
|
||
3 years ago
|
export const RecordId = t.name("number");
|
||
|
|
||
|
export const MinimalRecord = t.iface([], {
|
||
|
"id": "number",
|
||
|
});
|
||
|
|
||
3 years ago
|
const exportedTypeSuite: t.ITypeSuite = {
|
||
|
NewRecord,
|
||
|
Record,
|
||
3 years ago
|
AddOrUpdateRecord,
|
||
3 years ago
|
RecordsPatch,
|
||
|
RecordsPost,
|
||
3 years ago
|
RecordsPut,
|
||
3 years ago
|
RecordId,
|
||
|
MinimalRecord,
|
||
3 years ago
|
};
|
||
|
export default exportedTypeSuite;
|