This commit is contained in:
philc 2023-06-29 08:58:10 +00:00
commit bb6d71ee76
13 changed files with 234 additions and 50 deletions

View File

@ -0,0 +1,17 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "/schema/educations",
"title": "Education diplomat",
"description": "Training follow ",
"type": "object",
"properties":{
"schoolname":{"type":"string"},
"diploma":{"type":"string","enum":["BEPx","CAPy"]},
"jobsector":{"type":"string","enum":["serveur"]},
"dt_start":{"type":"string","format":"date"},
"dt_end":{"type":"string","format":"date"},
"description":{"type":"string"},
"skills":{"type":"array","$ref":"schema/skills.json"}
},
"required":["jobsector","schoolname","diploma","dt_start","dt_end"]
}

View File

@ -0,0 +1,20 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "/schema/experiences",
"title": "Describe a professionnal experience",
"description": "List of information to describe professional experiences",
"type": "object",
"properties":{
"jobtitle":{"type":"string"},
"contract":{"type":"string","enum":["CDI","CDD","FREE","STAGE","ALTERNANCE"]},
"companyname":{"type":"string"},
"location":{"type":"object","$ref":"https://schema.org/PostalAddress"},
"remotexp":{"type":"string","enum":["onsite","remote","hybrid"]},
"dt_start":{"type":"string","format":"date"},
"dt_end":{"type":"string","format":"date"},
"jobsector":{"type":"string","enum":[]},
"description":{"type":"string"},
"skills":{"type":"array","$ref":"schema/skills.json"}
},
"required":["jobtitle","companyname","contract"]
}

View File

@ -0,0 +1,4 @@
{
"CDI":{"title":"Contrat à durée indeterninée","autreinfoutile":""},
"CDD":{}
}

View File

@ -0,0 +1,3 @@
{
"BEPx":{"title":"blabla","description":"blabla"}
}

View File

@ -0,0 +1,3 @@
{
"serveur":{"title":"Serveur en salle"}
}

View File

@ -0,0 +1,30 @@
{
"offerA": {
"accessright": {
"person": "O",
"person.alias": "",
"person.owner": "",
"person.accessright": ""
},
"title":"Offre de lancement",
"description":"txt blabla",
"html":"<h1>Offre de lancement</h1> <p>blabla</p>",
"priceHT":"19",
"currency":"euro",
"monthbillfrequency":"1"
},
"offerB": {
"accessright": {
"person": "O",
"person.alias": "",
"person.owner": "",
"person.accessright": ""
},
"title":"Offre de lancement",
"description":"txt blabla",
"html":"<h1>Offre de lancement</h1> <p>blabla</p>",
"priceHT":"49",
"currency":"euro",
"monthbillfrequency":"3"
}
}

View File

@ -0,0 +1,30 @@
{
"offerA": {
"accessright": {
"person": "O",
"person.alias": "",
"person.owner": "",
"person.accessright": ""
},
"title":"Offre de lancement",
"description":"txt blabla",
"html":"<h1>Offre de lancement</h1> <p>blabla</p>",
"priceHT":"19",
"currency":"euro",
"monthbillfrequency":"1"
},
"offerB": {
"accessright": {
"person": "O",
"person.alias": "",
"person.owner": "",
"person.accessright": ""
},
"title":"Offre de lancement",
"description":"txt blabla",
"html":"<h1>Offre de lancement</h1> <p>blabla</p>",
"priceHT":"49",
"currency":"euro",
"monthbillfrequency":"3"
}
}

View File

@ -0,0 +1,5 @@
{
"M": { "title": "Monsieur", "description": "" },
"MME": { "title": "Madame", "description": "" },
"OTHER": { "title": "Autre", "edescription": "" }
}

View File

@ -0,0 +1,3 @@
{
"crit1":{"title":"critere1"}
}

View File

@ -2,16 +2,19 @@
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "/schema/person",
"title": "Person minimum definition to link a person to a pagan identity",
"description": "A person is a human with a apxtrib identity (Public Private Key. Information stored (not cipher) for a person are only visible from the town's Mayor and the tribe's Druid. You need at least trus the druid that trust the mayor (for sensitive data Mayor and Druid can be the same apx Identity.) Only a pagan that have the privateKey can read cipher data. The purpose of this sschema is to link a person to a tribe and manage basic activities, profil will be a tribe object if need more personnal information",
"description": "A person is a human with a apxtrib identity (alias = Public Private Key) that accept to be part of a tribe (a person is store inside a tribe). Information stored for a person are only visible from the town's Mayor and the tribe's Druid. You need at least trust the druid that trust the mayor (for sensitive data Mayor and Druid can be the same apx Identity.) Only a pagan that have the privateKey can read cipher data. The purpose of this schema is to link a person to a tribe and manage basic activities, profil for specific purpose will be a tribe object that can be add additionalProperties of this is set at true.",
"type": "object",
"properties": {
"alias": {
"title": "alias",
"description": "A unique string identifying a unique public key",
"type": "string",
"minLength": 5,
"pattern": "^[a-z0-9]*$"
},
"owner": {
"title": "Alias that own this object",
"title": "Owner of this person",
"description": "For accessright purpose this is always equal as alias",
"type": "string",
"format": "Alias"
},
@ -25,53 +28,92 @@
"format": "date-time"
},
"dt_lastlogin": {
"title": "Last time login",
"description": "Last time this person authentify as alias access to this tribe",
"type": "string",
"format": "date-time"
},
"dt_close": {
"title": "Date of leaving tribe",
"description": "Date from when this alias is ban of tribe by druid or want to leave. A pocess of data cleaning has to be run depending of Tribe's rules.",
"type": "string",
"format": "date-time"
},
"recoveryauth": {
"title": "Store numeric identity to recover it by email",
"description": "This object store numeric identity alias with an email mainly used at Person level to recover by email a private and passphrase key associate to alias",
"type": "object",
"$ref": "schema/recoveryauth.json"
"$ref": "#/definitions/recoveryauth"
},
"firstname": {
"title": "A firstname",
"description": "This will be use to present yourself",
"type": "string"
},
"lastname": {
"title": "A lastname",
"description": "This will be use to present yourself",
"type": "string"
},
"dt_birth": {
"title": "Your birthdate",
"description": "Date of birth you want to communicate",
"type": "string",
"format": "date"
},
"gender":{
"pronom": {
"title": "Your pronom",
"description": "The way you want people communicate with you",
"type": "string",
"enum": ["M", "MME", "OTHER"]
},
"emailcom":{"type":"string","format":"email"},
"emailcom": {
"title": "email use to communicate with you",
"description": "email used by tribe to communicate with you, depending of your profil you can also define other mail to interact with other person",
"type": "string",
"format": "email"
},
"biography": {
"title":"Your bio or few words to define yoursel",
"description":"Use this to share your values, this will be public to all of tribe's members and link to your person",
"type": "string",
"pattern": "^.{O,150}$"
},
"imgavatar": {
"type": "string"
"title":"A picture of your person or personnality",
"description":"This picture will be public to all tribe's member",
"type": "url"
},
"accessrights": {
"title": "Accessright per Object or per Object.key belonging to tribe",
"description": "A Person has to exist and want to create read update delete, if Own means if owner = alias of user requested some CRUD action to owner then he can act on this object or object.key List of Object with CRUDO value like {Person:'RUDO',"Person.recoveryauth":'O',...}",
"type": "object"
"title": "Accessright per Object or per Object.key belonging to a tribe",
"description": "A Person can create read update delete an object (CRUD), if Own means if owner = alias of user requested some CRUD action to owner then he can act on this object or object.key List of Object with CRUDO value like {Person:'RUDO','Person.recoveryauth':'O',...}. To simplify some profil can be define admin, user, recruiter, seeker, and get a standard accessright object",
"type": "object",
"$ref": "#/definitions/accessright"
}
},
"required": [
"alias",
"accessright"
],
"definitions": {
"recoveryauth": {
"type": "object",
"properties": {
"email": { "type": "string", "format": "email" },
"alias": { "type": "string", "format": "Pagan" },
"privatekey": { "type": "string", "format": "eccCorve25519armored" }
}
},
"accessright":{
"type":"object",
"properties":{
"type":"object",
"properties":{
"objkey": {"type":"sring","format":"CRUDO"}
}
}
}
},
"required": ["alias", "accessright"],
"additionalProperties": true,
"apxprimarykey": "alias",
"apxunique": [
""
],
"apxunique": [""],
"apxsearchindex": [
{
"key": "alias",

View File

@ -1,11 +0,0 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "/schema/recoveryauth",
"title": "Store numeric identity to recover it by email",
"description": "This object store numeric identity alias with an email mainly used at Person level to recover by email a private and passphrase key associate to alias",
"properties":{
"email": { "type": "string", "format": "email" },
"alias": {"type": "string", "format":"Pagan"},
"privatekey": { "type": "string", "format": "eccCorve25519armored" }
}
}

View File

@ -5,14 +5,52 @@
"description": "All those data have to store any useffull logistical data and profil about a seeker (skill, ...) ",
"type": "object",
"properties": {
"offerseeker": { "type": "string", "emum": ["offerA", "offerB"] },
"emailseek": { "type": "string", "format": "email" },
"mainlivinglocation":{"type":"object","$ref":"https://schema.org/PostalAddress"},
"secondlivinglocation":{"type":"object","$ref":"https://schema.org/PostalAddress"},
"thirdlivinglocation":{"type":"object","$ref":"https://schema.org/PostalAddress"},
"fourthlivinglocation":{"type":"object","$ref":"https://schema.org/PostalAddress"},
"seekcriterias":{"type":"array","$ref":"schema/seekcriteria.json"},
"skills":{"type":"array","$ref":"schema/skills.json"},
"educations":{"type":"array","$ref":"schema/educations.json"},
"experiences":{"type":"array","$ref":"schema/experiences.json"}
"seeklocation": {
"type": "array",
"items": {
"type": "object",
"$ref": "https://schema.org/PostalAddress"
}
},
"seekcriterias": {
"type": "array",
"items": { "type": "string", "enum": [] }
},
"skills": {
"type": "array",
"items": { "type": "object", "$ref": "schema/skills.json" }
},
"educations": {
"type": "array",
"items": { "type": "object", "$ref": "schema/educations.json" }
},
"experiences": {
"type": "array",
"items": { "type": "object", "$ref": "schema/experiences.json" }
},
"recommandation": {
"type": "array",
"items": { "type": "object", "$ref": "#/definitions/recommandation"}
}
},
"definitions": {
"recommandation": {
"type": "object",
"properties": {
"email": { "type": "string", "format": "email" },
"phone": { "type": "string", "format": "telephone" },
"fisrtname": { "type": "string" },
"lastname": { "type": "string" },
"jobtitle": { "type": "string" },
"description": {
"title": "Area of recomandation",
"description": "Describe why this recommandation is relevant to confirm your skills",
"type": "string"
}
}
}
},
"required": ["offerseeker", "emailseek", "mainlivinglocation", ""]
}

View File

@ -51,7 +51,7 @@ towns.owntown = (newowner) => {
console.log(rep);
apx.data.tpldata.setup.mayorId = newowner;
apx.save();
app.load("apxmain", "townowner", towns.loadtpldata());
app.load("apxmain", "townowner", towns.loadtpldata("owner"));
})
.catch((err) => {
console.log(err);