Skip to content

Instantly share code, notes, and snippets.

@guillaumeduhan
Last active October 11, 2022 14:24
Show Gist options
  • Save guillaumeduhan/90645e34469284492dd00621b874121b to your computer and use it in GitHub Desktop.
Save guillaumeduhan/90645e34469284492dd00621b874121b to your computer and use it in GitHub Desktop.
{
id: { type: String, unique: true, required: true },
domain: Array,
subdomain: { type: String },
file_external_id: Array,
contract_external_id: Array,
visualFileName: { type: String, default: "document.pdf" }, // n'a pas lieu d'être, nom + type généré à la volée
name: { type: String, required: true },
code: { type: String, default: "" }, // internal unique name for file upload ????
desc: { type: String },
type: { type: String }, // Validate: video, txt, pdf
cat: { type: String }, // Validate: Medical, Administratif, Autre
privacy: { type: String, default: "INTERNAL" }, // Validate: INTERNAL, EXTERNAL
key: { type: String, default: "" }, // short unique identifier for the file like fuid, but uploaded by front
groups_uid: Array,
user_uid: String,
sender_uid: String,
// Okay
access_uid: Array, // UID qui peuvent acceder le fichier
groupUid: Array, // orgUid Groupes qui peuvent accéder au fichier
orgUid: Array, // organisations uids qui peuvent accéder au fichier
client_id: String, // code clients
//
access_uids: Array, // un array comptant tous les uuids ayant accès
// merge
contract_uid: { type: String },
contractstUid: Array,
// to
contracts_uid: Array
doc_ref_uid: Array,
sub_doc_ref: String, // nom du document ex: convention de compte, le type pdf du document
created_at: { type: Date },
clientTags: Array, // liste of tags, les tags qui peuvent être gérées par le client
tagList: Array, // liste of default tags, ce sont de tags système
namedTags: [{ tagName: String, tagValue: String }], // liste of default internal tags
keywords: Array, // liste of keyworks
source: String,
repository: String,
size: String, // no file
sha1: String,
sha256: String,
validated_by: Array, // {medical, avocat}
validation_status: String, // validé , invalidé, à valider
contractRef: { type: String },
vaultUid: { type: String },
taskUid: String,
validFrom: { type: Date, default: null },
validUntil: { type: Date, default: null }, /// date dans le futur lointin dans 50 ans
file_status: { type: String, default: "OK" },
bannetteName: String, //unique name of bannette
signed: { type: Boolean, default: false }, //true, false
// merge
signators: Array, //array de signataires
signatures: Array, // array de signatures as of 26.05.2022 only one signature stored in array
signators2: Array, //array de signataires niveau 2
// to
signators: Array, //array de signataires
signed_at: { type: Date }, // date de signature
bundleRef: String, //bundle ref de la signature
signerAuthority: { type: String, default: "VAULTINUM" },
sinceInBanette: { type: Date }, // datetime since in bannette
//storage status, archivé banqué, serveur,
storage_status: { type: String, default: "vault" }, // zipped, GEDBanque, //iubitrust //replicated xxx, etc..
storage_status_ts: { type: Date, default: Date.now },
// merge
//SIMPLE SIGNATURE 1
sSignIdentity_1: { type: String },
sSignIdentityUid_1: { type: String },
sSignIdentityTimeStamp_1: { type: Date },
sSigned_1: { type: String }, // true ou false
// to
signed_X: { type: String }
// A ce stade, il faut une BDD Signatures
// merge
sSignNotified_1: { type: String },
sSignNotifiedUid_1: { type: String },
sSignNotifiedTimeStamp_1: { type: Date },
sNotified_1: { type: String }, // true ou false
// to
notified_at: { type: Date },
notitied_to_x: { type: String }
sSignDecision_1: { type: String },
sSignDecisionTimeStamp_1: { type: String },
sSignDecisionComments_1: { type: String },
sDecision_1: { type: String }, // true ou false
//SIMPLE SIGNATURE 2
sSignIdentity_2: { type: String },
sSignIdentityUid_2: { type: String },
sSignIdentityTimeStamp_2: { type: Date },
sSigned_2: { type: String }, // true ou false
sSignNotified_2: { type: String },
sSignNotifiedUid_2: { type: String },
sSignNotifiedTimeStamp_2: { type: Date },
sNotified_2: { type: String }, // true ou false
sSignDecision_2: { type: String },
sSignDecisionTimeStamp_2: { type: Date },
sSignDecisionComments_2: { type: String },
sDecision_2: { type: String }, // true ou false
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment