Création d'utilisateur (interface) en cours.

This commit is contained in:
xdrm-brackets 2016-04-14 16:23:08 +02:00
parent 11edcc60e1
commit f255bdb6a1
10 changed files with 301 additions and 51 deletions

View File

@ -1,2 +1,2 @@
#WRAPPER>#CONTAINER>section{display:none;position:relative;flex-grow:1;padding:1em;border-radius:3px;background-color:#fff;color:#000;font-size:1em;border:1px solid #ddd}#WRAPPER>#CONTAINER>section.active{display:block}#WRAPPER>#CONTAINER>section h6{color:#848484;font-size:1.2em;text-transform:uppercase;font-weight:300;letter-spacing:.2em;margin:0;padding:0}#WRAPPER>#CONTAINER>section h6:before{content:'- '}#WRAPPER>#CONTAINER>section h6:after{content:' -'}#WRAPPER>#CONTAINER>section h6.center{text-align:center}#WRAPPER>#CONTAINER>section input[type="radio"],#WRAPPER>#CONTAINER>section input[type="checkbox"]{display:none}#WRAPPER>#CONTAINER>section input[type="radio"]+label[for],#WRAPPER>#CONTAINER>section input[type="checkbox"]+label[for]{padding-left:.8em;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#WRAPPER>#CONTAINER>section input[type="radio"]+label[for]:before,#WRAPPER>#CONTAINER>section input[type="checkbox"]+label[for]:before{content:'';display:inline-block;position:relative;top:.1em;left:-.8em;width:calc( 1em - 2*.15em );height:calc( 1em - 2*.15em );border-radius:50% / 50%;border:0.15em solid #399ced;background:#fff center center no-repeat;background-image:none;background-size:70% auto;transition:background .2s ease-in-out;cursor:pointer}#WRAPPER>#CONTAINER>section input[type="radio"]:checked+label[for]:before,#WRAPPER>#CONTAINER>section input[type="checkbox"]:checked+label[for]:before{background-color:#399ced;background-image:url("/f/svg/checked/st/container")}#WRAPPER>#CONTAINER>section input[type="checkbox"]+label[for]:before{border-radius:3px}#WRAPPER>#CONTAINER>section input[type="submit"],#WRAPPER>#CONTAINER>section input[type="button"]{margin:.5em 0;padding:.3em .5em;border-radius:3px;border:1px solid #515151;font-weight:bold;color:#515151;background-color:#fff;transition:background .1s ease-in-out, color .1s ease-in-out}#WRAPPER>#CONTAINER>section input[type="submit"]:hover,#WRAPPER>#CONTAINER>section input[type="button"]:hover{background-color:#515151;color:#fff}#WRAPPER>#CONTAINER>section input[type="submit"].primary,#WRAPPER>#CONTAINER>section input[type="button"].primary{border-color:#399ced;color:#399ced;background-color:#fff}#WRAPPER>#CONTAINER>section input[type="submit"].primary:hover,#WRAPPER>#CONTAINER>section input[type="button"].primary:hover{background-color:#399ced;color:#fff}#WRAPPER>#CONTAINER>section img{margin:1em;height:3em}#WRAPPER>#CONTAINER>section .flag{margin:0 .8em;padding:.2em .8em;border-radius:5px;border:1px solid #b5b5b5;color:#555;font-family:'Inconsolata'} #WRAPPER>#CONTAINER>section{display:none;position:relative;flex-grow:1;padding:1em;border-radius:3px;background-color:#fff;color:#000;font-size:1em;border:1px solid #ddd}#WRAPPER>#CONTAINER>section.active{display:block}#WRAPPER>#CONTAINER>section h6{color:#848484;font-size:1.2em;text-transform:uppercase;font-weight:300;letter-spacing:.2em;margin:0;padding:0}#WRAPPER>#CONTAINER>section h6:before{content:'- '}#WRAPPER>#CONTAINER>section h6:after{content:' -'}#WRAPPER>#CONTAINER>section h6.center{text-align:center}#WRAPPER>#CONTAINER>section input[type="radio"],#WRAPPER>#CONTAINER>section input[type="checkbox"]{display:none}#WRAPPER>#CONTAINER>section input[type="radio"]+label[for],#WRAPPER>#CONTAINER>section input[type="checkbox"]+label[for]{padding-left:.8em;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}#WRAPPER>#CONTAINER>section input[type="radio"]+label[for]:before,#WRAPPER>#CONTAINER>section input[type="checkbox"]+label[for]:before{content:'';display:inline-block;position:relative;top:.1em;left:-.8em;width:calc( 1em - 2*.15em );height:calc( 1em - 2*.15em );border-radius:50% / 50%;border:0.15em solid #399ced;background:#fff center center no-repeat;background-image:none;background-size:70% auto;transition:background .2s ease-in-out;cursor:pointer}#WRAPPER>#CONTAINER>section input[type="radio"]:checked+label[for]:before,#WRAPPER>#CONTAINER>section input[type="checkbox"]:checked+label[for]:before{background-color:#399ced;background-image:url("/f/svg/checked/st/container")}#WRAPPER>#CONTAINER>section input[type="checkbox"]+label[for]:before{border-radius:3px}#WRAPPER>#CONTAINER>section input[type="submit"],#WRAPPER>#CONTAINER>section input[type="button"]{margin:.5em 0;padding:.3em .5em;border-radius:3px;border:1px solid #515151;color:#515151;background-color:#fff;transition:background .1s ease-in-out, color .1s ease-in-out}#WRAPPER>#CONTAINER>section input[type="submit"]:hover,#WRAPPER>#CONTAINER>section input[type="button"]:hover{background-color:#515151;color:#fff}#WRAPPER>#CONTAINER>section input[type="submit"].primary,#WRAPPER>#CONTAINER>section input[type="button"].primary{border-color:#399ced;color:#399ced;background-color:#fff}#WRAPPER>#CONTAINER>section input[type="submit"].primary:hover,#WRAPPER>#CONTAINER>section input[type="button"].primary:hover{background-color:#399ced;color:#fff}#WRAPPER>#CONTAINER>section img{margin:1em;height:3em}#WRAPPER>#CONTAINER>section .flag{margin:0 .8em;padding:.2em .8em;border-radius:5px;border:1px solid #b5b5b5;color:#555;font-family:'Inconsolata'}
/*# sourceMappingURL=container.css.map */ /*# sourceMappingURL=container.css.map */

View File

@ -1,6 +1,6 @@
{ {
"version": 3, "version": 3,
"mappings": "AAMC,2BAAW,CACV,OAAO,CAAE,IAAI,CAKb,QAAQ,CAAE,QAAQ,CAClB,SAAS,CAAE,CAAC,CAEZ,OAAO,CAAE,GAAG,CAEZ,aAAa,CAAE,GAAG,CAElB,gBAAgB,CAAE,IAAI,CAEtB,KAAK,CAAE,IAAI,CACX,SAAS,CAAE,GAAG,CAEd,MAAM,CAAE,cAAc,CAdtB,kCAAQ,CAAE,OAAO,CAAE,KAAK,CAoBxB,8BAAI,CACH,KAAK,CAAE,OAAsB,CAC7B,SAAS,CAAE,KAAK,CAChB,cAAc,CAAE,SAAS,CACzB,WAAW,CAAE,GAAG,CAChB,cAAc,CAAE,IAAI,CA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,IAAI,CACT,IAAI,CAAE,KAAK,CACX,KAAK,CAAE,qBAAqB,CAC5B,MAAM,CAAE,qBAAqB,CAE9B,aAAa,CAAE,SAAS,CACxB,MAAM,CAAE,oBAA6B,CAErC,UAAU,CAAE,4BAA4B,CACxC,gBAAgB,CAAE,IAAI,CACtB,eAAe,CAAE,QAAQ,CAEzB,UAAU,CAAE,0BAA0B,CAEtC,MAAM,CAAE,OAAO,CAKjB,sJACoD,CACnD,gBAAgB,CC9FA,OAAO,CD+FvB,gBAAgB,CAAE,kCAAkC,CAKrD,oEAA4C,CAC3C,aAAa,CAAE,GAAG,CASnB,iGACsB,CACrB,MAAM,CAAE,MAAM,CACd,OAAO,CAAE,SAAS,CAElB,aAAa,CAAE,GAAG,CAClB,MAAM,CAAE,iBAAmB,CAE3B,KAAK,CCvHW,OAAO,CDyHvB,gBAAgB,CAAE,IAAI,CAEtB,UAAU,CAAE,iDAAiD,CAG7D,6GAAO,CACN,gBAAgB,CC/HD,OAAO,CDgItB,KAAK,CAAE,IAAI,CAKZ,iHAAS,CACR,YAAY,CCrIG,OAAO,CDsItB,KAAK,CCtIU,OAAO,CDuItB,gBAAgB,CAAE,IAAI,CAItB,6HAAO,CACN,gBAAgB,CC5IF,OAAO,CD6IrB,KAAK,CAAE,IAAI,CASd,+BAAK,CACJ,MAAM,CAAE,GAAG,CACX,MAAM,CAAE,GAAG,CAKZ,iCAAO,CACN,MAAM,CAAE,MAAM,CACd,OAAO,CAAE,SAAS,CAElB,aAAa,CAAE,GAAG,CAClB,MAAM,CAAE,iBAAiB,CAEzB,KAAK,CAAE,IAAI,CACX,WAAW,CAAE,aAAa",
"sources": ["container.scss","constants.scss"], "sources": ["container.scss","constants.scss"],
"names": [], "names": [],
"file": "container.css" "file": "container.css"

View File

@ -122,7 +122,6 @@
border-radius: 3px; border-radius: 3px;
border: 1px solid $theme-fg; border: 1px solid $theme-fg;
font-weight: bold;
color: $theme-fg; color: $theme-fg;
background-color: #fff; background-color: #fff;

View File

@ -1,2 +1,2 @@
section[data-panel-list]{display:block;position:relative;border-radius:3px;border:1px solid #ccc;background-color:#fff;font-size:.8em;color:#000}section[data-panel-list]>div[data-header]{display:flex;position:relative;flex-direction:row;flex-wrap:nowrap;justify-content:space-between;align-items:center;padding:.5em .7em;border-radius:3px 3px 0 0;border-bottom:1px solid #ccc;background-color:#f5f5f5;box-shadow:inset 0 0 5px #eee}section[data-panel-list]>div[data-header]>span,section[data-panel-list]>div[data-header]>button{color:#333;font-weight:bold;line-height:2em}section[data-panel-list]>div[data-header]>button{padding:.1em .7em;border-radius:3px;border:1px solid #555;background:#f5f5f5;transition:all .2s ease-in-out}section[data-panel-list]>div[data-header]>button:hover{background:#333;color:#fff}section[data-panel-list]>div[data-description]{display:block;position:relative;border-bottom:1px solid #ccc;padding:.7em .7em;color:#555}section[data-panel-list]>ul[data-list]{display:flex;position:relative;flex-direction:column;justify-content:flex-start;flex-wrap:nowrap;margin:0;padding:0;list-style:none}section[data-panel-list]>ul[data-list]>li[data-element]{display:flex;flex-direction:row;justify-content:space-between;align-items:center;flex-wrap:nowrap;padding:1em}section[data-panel-list]>ul[data-list]>li[data-element]:not(:last-child){border-bottom:1px solid #ccc}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1){display:flex;width:10em;height:6em;flex-direction:column;justify-content:flex-end;align-items:center;background:url("/f/svg/token/st/container/666666") center 1em no-repeat;background-size:auto 50%}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1).active{background-image:url("/f/svg/token/st/container/399ced")}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1)>span{display:block;padding:0 .4em;border-radius:3px;border:1px solid #ddd;font-size:.8em;color:#555;text-transform:uppercase;font-weight:bold}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(n+2){display:flex;position:relative;flex:10em;padding:1em;flex-direction:column;justify-content:flex-start;align-items:flex-start;font-size:1em;color:#000;font-weight:bold}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(n+2)>span[data-prefix]:before{content:attr(data-prefix) ": ";font-weight:normal}section[data-panel-list]>ul[data-list]>li[data-element]>button{padding:.1em .7em;height:2em;border-radius:3px;border:1px solid #de2b08;background:#fff;color:#de2b08;font-weight:bold;transition:all .2s ease-in-out}section[data-panel-list]>ul[data-list]>li[data-element]>button:hover{background:#de2b08;color:#fff}section[data-panel-list]>div[data-add]{display:none;position:relative;padding:1em;border-bottom:1px solid #ccc;background-color:#f5f5f5;font-weight:bold}section[data-panel-list]>div[data-add].active{display:block}section[data-panel-list]>div[data-add]>input[type='text']{margin:1em 0;padding:.3em .5em;border-radius:3px;border:1px solid #999;background-color:#fff;color:#000;font-weight:normal} section[data-panel-list]{display:block;position:relative;border-radius:3px;border:1px solid #ccc;background-color:#fff;font-size:.8em;color:#000}section[data-panel-list]>div[data-header]{display:flex;position:relative;flex-direction:row;flex-wrap:nowrap;justify-content:space-between;align-items:center;padding:.5em .7em;border-radius:3px 3px 0 0;border-bottom:1px solid #ccc;background-color:#f5f5f5;box-shadow:inset 0 0 5px #eee}section[data-panel-list]>div[data-header]>span,section[data-panel-list]>div[data-header]>button{color:#333;font-weight:bold;line-height:2em}section[data-panel-list]>div[data-header]>button{padding:.1em .7em;border-radius:3px;border:1px solid #555;background:#f5f5f5;transition:all .2s ease-in-out}section[data-panel-list]>div[data-header]>button:hover{background:#333;color:#fff}section[data-panel-list]>div[data-description]{display:block;position:relative;border-bottom:1px solid #ccc;padding:.7em .7em;color:#555}section[data-panel-list]>ul[data-list]{display:flex;position:relative;flex-direction:column;justify-content:flex-start;flex-wrap:nowrap;margin:0;padding:0;list-style:none}section[data-panel-list]>ul[data-list]>li[data-element]{display:flex;flex-direction:row;justify-content:space-between;align-items:center;flex-wrap:nowrap;padding:1em}section[data-panel-list]>ul[data-list]>li[data-element]:not(:last-child){border-bottom:1px solid #ccc}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1){display:flex;width:10em;height:6em;flex-direction:column;justify-content:flex-end;align-items:center;background-size:auto 50%}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1)[data-token]{background:url("/f/svg/token/st/container/666666") center 1em no-repeat}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1)[data-token].active{background-image:url("/f/svg/token/st/container/399ced")}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1)[data-user]{background:url("/f/svg/user/st/container/666666") center 1em no-repeat}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1)[data-user].active{background-image:url("/f/svg/user/st/container/399ced")}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(1)>span{display:block;padding:0 .4em;border-radius:3px;border:1px solid #ddd;font-size:.8em;color:#555;text-transform:uppercase;font-weight:bold}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(n+2){display:flex;position:relative;flex:10em;padding:1em;flex-direction:column;justify-content:flex-start;align-items:flex-start;font-size:1em;color:#000;font-weight:bold}section[data-panel-list]>ul[data-list]>li[data-element]>div:nth-child(n+2)>span[data-prefix]:before{content:attr(data-prefix) ": ";font-weight:normal}section[data-panel-list]>ul[data-list]>li[data-element]>button{padding:.1em .7em;height:2em;border-radius:3px;border:1px solid #de2b08;background:#fff;color:#de2b08;font-weight:bold;transition:all .2s ease-in-out}section[data-panel-list]>ul[data-list]>li[data-element]>button:hover{background:#de2b08;color:#fff}section[data-panel-list]>div[data-add]{display:none;position:relative;padding:1em;border-bottom:1px solid #ccc;background-color:#f5f5f5}section[data-panel-list]>div[data-add].active{display:block}section[data-panel-list]>div[data-add]>.label{display:inline-block;width:18em;padding-right:2em;text-align:right}section[data-panel-list]>div[data-add]>input[type='text'],section[data-panel-list]>div[data-add]>input[type='email'],section[data-panel-list]>div[data-add]>input[type='password']{margin:1em 0;padding:.3em .5em;border-radius:3px;border:1px solid #999;background-color:#fff;color:#000;font-weight:normal}section[data-panel-list]>div[data-add]>input[type='text']:focus,section[data-panel-list]>div[data-add]>input[type='email']:focus,section[data-panel-list]>div[data-add]>input[type='password']:focus{border-color:#399ced}
/*# sourceMappingURL=global.css.map */ /*# sourceMappingURL=global.css.map */

View File

@ -1,7 +1,7 @@
{ {
"version": 3, "version": 3,
"mappings": "AAEA,wBAAwB,CACvB,OAAO,CAAE,KAAK,CACd,QAAQ,CAAE,QAAQ,CAElB,aAAa,CAAE,GAAG,CAClB,MAAM,CAAE,cAAc,CAEtB,gBAAgB,CAAE,IAAI,CAEtB,SAAS,CAAE,IAAI,CACf,KAAK,CAAE,IAAI,CAIX,yCAAoB,CACnB,OAAO,CAAE,IAAI,CACb,QAAQ,CAAE,QAAQ,CAGlB,cAAc,CAAE,GAAG,CACnB,SAAS,CAAE,MAAM,CACjB,eAAe,CAAE,aAAa,CAC9B,WAAW,CAAE,MAAM,CAEnB,OAAO,CAAE,SAAS,CAElB,aAAa,CAAE,WAAW,CAC1B,aAAa,CAAE,cAAc,CAE7B,gBAAgB,CAAE,OAAO,CACzB,UAAU,CAAE,kBAAkB,CAG9B,+FACU,CACT,KAAK,CAAE,IAAI,CACX,WAAW,CAAE,IAAI,CACjB,WAAW,CAAE,GAAG,CAIjB,gDAAU,CACT,OAAO,CAAE,SAAS,CAElB,aAAa,CAAE,GAAG,CAClB,MAAM,CAAE,cAAc,CAEtB,UAAU,CAAE,OAAO,CAEnB,UAAU,CAAE,mBAAmB,CAG/B,sDAAO,CACN,UAAU,CAAE,IAAI,CAChB,KAAK,CAAE,IAAI,CAQd,8CAAyB,CACxB,OAAO,CAAE,KAAK,CACd,QAAQ,CAAE,QAAQ,CAElB,aAAa,CAAE,cAAc,CAE7B,OAAO,CAAE,SAAS,CAElB,KAAK,CAAE,IAAI,CAMZ,sCAAiB,CAChB,OAAO,CAAE,IAAI,CACb,QAAQ,CAAE,QAAQ,CAGlB,cAAc,CAAE,MAAM,CACtB,eAAe,CAAE,UAAU,CAC3B,SAAS,CAAE,MAAM,CAEjB,MAAM,CAAE,CAAC,CACT,OAAO,CAAE,CAAC,CAEV,UAAU,CAAE,IAAI,CAIhB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AC3B,WAAW,CAAE,UAAU,CAEvB,SAAS,CAAE,GAAG,CACd,KAAK,CAAE,IAAI,CACX,WAAW,CAAE,IAAI,CAGjB,mGAA4B,CAC3B,OAAO,CAAE,sBAAsB,CAC/B,WAAW,CAAE,MAAM,CAKrB,8DAAU,CACT,OAAO,CAAE,SAAS,CACjB,MAAM,CAAE,GAAG,CAEZ,aAAa,CAAE,GAAG,CAClB,MAAM,CAAE,iBAAiB,CAEzB,UAAU,CAAE,IAAI,CAEhB,KAAK,CAAE,OAAO,CACd,WAAW,CAAE,IAAI,CAEjB,UAAU,CAAE,mBAAmB,CAG/B,oEAAO,CACN,UAAU,CAAE,OAAO,CACnB,KAAK,CAAE,IAAI,CASf,sCAAiB,CAChB,OAAO,CAAE,IAAI,CAOb,QAAQ,CAAE,QAAQ,CAElB,OAAO,CAAE,GAAG,CAEZ,aAAa,CAAE,cAAc,CAE7B,gBAAgB,CAAE,OAAO,CAVzB,6CAAQ,CACP,OAAO,CAAE,KAAK,CAcf,6CAAU,CACT,OAAO,CAAE,YAAY,CACrB,KAAK,CAAE,IAAI,CACX,aAAa,CAAE,GAAG,CAClB,UAAU,CAAE,KAAK,CAKlB,kLAE0B,CACzB,MAAM,CAAE,KAAK,CACb,OAAO,CAAE,SAAS,CAElB,aAAa,CAAE,GAAG,CAClB,MAAM,CAAE,cAAc,CAEtB,gBAAgB,CAAE,IAAI,CAEtB,KAAK,CAAE,IAAI,CACX,WAAW,CAAE,MAAM,CAGnB,oMAAO,CACN,YAAY,CC9PG,OAAO",
"sources": ["global.scss"], "sources": ["global.scss","constants.scss"],
"names": [], "names": [],
"file": "global.css" "file": "global.css"
} }

View File

@ -1,3 +1,6 @@
@import 'constants';
/* [1] Panneau d'ajout/suppression d'elements /* [1] Panneau d'ajout/suppression d'elements
=========================================================*/ =========================================================*/
section[data-panel-list]{ section[data-panel-list]{
@ -119,13 +122,27 @@ section[data-panel-list]{
justify-content: flex-end; justify-content: flex-end;
align-items: center; align-items: center;
// Image pour token
&[data-token]{
background: url('/f/svg/token/st/container/666666') center 1em no-repeat; background: url('/f/svg/token/st/container/666666') center 1em no-repeat;
background-size: auto 50%;
// Si le token est actif // Si le token est actif
&.active{ &.active{
background-image: url('/f/svg/token/st/container/399ced'); background-image: url('/f/svg/token/st/container/399ced');
} }
}
// Image pour utilisateur
&[data-user]{
background: url('/f/svg/user/st/container/666666') center 1em no-repeat;
// Si le token est actif
&.active{
background-image: url('/f/svg/user/st/container/399ced');
}
}
background-size: auto 50%;
// Texte pour le type d'element // Texte pour le type d'element
@ -213,11 +230,21 @@ section[data-panel-list]{
background-color: #f5f5f5; background-color: #f5f5f5;
font-weight: bold; // font-weight: bold;
/* (5.1) Description du champ de texte */
& > .label{
display: inline-block;
width: 18em;
padding-right: 2em;
text-align: right;
}
/* (5.1) Champs de texte */ /* (5.2) Champs de texte */
& > input[type='text']{ & > input[type='text'],
& > input[type='email'],
& > input[type='password']{
margin: 1em 0; margin: 1em 0;
padding: .3em .5em; padding: .3em .5em;
@ -228,6 +255,11 @@ section[data-panel-list]{
color: #000; color: #000;
font-weight: normal; font-weight: normal;
// Animation de @focus
&:focus{
border-color: $theme-fg-primary;
}
} }
} }

View File

@ -196,15 +196,15 @@
break; break;
case 'varchar(255)': case 'varchar(255)':
return $checker && is_string($value) && strlen($value) <= 255; return $checker && is_string($value) && strlen($value) <= 255 && strlen($value) > 0;
break; break;
case 'varchar(50)': case 'varchar(50)':
return $checker && is_string($value) && strlen($value) <= 50; return $checker && is_string($value) && strlen($value) <= 50 && strlen($value) > 0;
break; break;
case 'varchar(30)': case 'varchar(30)':
return $checker && is_string($value) && strlen($value) <= 30; return $checker && is_string($value) && strlen($value) <= 30 && strlen($value) > 0;
break; break;
case 'text': case 'text':

View File

@ -0,0 +1,54 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
enable-background="new 0 0 24 24"
id="Layer_1"
version="1.0"
viewBox="0 0 32 32"
xml:space="preserve"
inkscape:version="0.91 r13725"
sodipodi:docname="user.svg"
width="32"
height="32"><metadata
id="metadata4194"><rdf:RDF><cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><defs
id="defs4192" /><sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1920"
inkscape:window-height="1056"
id="namedview4190"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="39.75"
inkscape:cx="8"
inkscape:cy="8"
inkscape:window-x="0"
inkscape:window-y="24"
inkscape:window-maximized="1"
inkscape:current-layer="Layer_1" /><g
id="g4196"
transform="matrix(2,0,0,2,-8,-8)"><circle
id="stylisable"
r="4"
cy="8"
cx="12" /><path
id="stylisable"
d="m 12,14 c -6.1,0 -8,4 -8,4 l 0,2 16,0 0,-2 c 0,0 -1.9,-4 -8,-4 z"
inkscape:connector-curvature="0" /></g></svg>

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@ -4,12 +4,12 @@
var TOKEN = { var TOKEN = {
add: { // Tout ce qui attrait a l'ajout add: { // Tout ce qui attrait a l'ajout
toggle: document.getElementById('add-token'), // bouton de toggle pour l'affichage du panel toggle: document.getElementById('add-token'), // bouton de toggle pour l'affichage du panel
panel: document.querySelector('div[data-add]'), // formulaire de creation panel: document.querySelector("[data-sublink='tokens'] div[data-add]"), // formulaire de creation
state: true, // etat (visible ou non) du panel state: true, // etat (visible ou non) du panel
name: document.getElementById('add-name'), // nom du token a creer name: document.querySelector("[data-sublink='tokens'] div[data-add] #add-name"), // nom du token a creer
duration: document.getElementById('add-duration'), // duree du token a creer (en jours) duration: document.querySelector("[data-sublink='tokens'] div[data-add] #add-duration"), // duree du token a creer (en jours)
submit: document.getElementById('add-submit') // validation de la creation submit: document.querySelector("[data-sublink='tokens'] div[data-add] #add-submit") // validation de la creation
}, },
@ -52,13 +52,7 @@ var TOKEN = {
}, false); }, false);
/* (2) Gestion de la suppression d'un token */
/* (2) Gestion de la suppression de token */
for( var i = 0 ; i < TOKEN.remove.buttons.length ; i++ ){ for( var i = 0 ; i < TOKEN.remove.buttons.length ; i++ ){
/* (2.0) Pour chaque bouton supprimer, on attache un evenement */ /* (2.0) Pour chaque bouton supprimer, on attache un evenement */
@ -76,6 +70,104 @@ for( var i = 0 ; i < TOKEN.remove.buttons.length ; i++ ){
// On lance la requete // On lance la requete
api.send(request, function(answer){ api.send(request, function(answer){
console.log(answer);
// Si la suppression effectuee, on recharge la page
if( answer.ModuleError == 0 )
reload();
});
}, false);
}
/* [2] Gestion des utilisateurs
=========================================================*/
var USERS = {
add: { // Tout ce qui attrait a l'ajout
toggle: document.getElementById('add-user'), // bouton de toggle pour l'affichage du panel
panel: document.querySelector("[data-sublink='users'] div[data-add]"), // formulaire de creation
state: true, // etat (visible ou non) du panel
login: document.querySelector("[data-sublink='users'] div[data-add] #add-login"), // identifiant de l'utilisateur
password: document.querySelector("[data-sublink='users'] div[data-add] #add-password"), // password de l'utilisateur
mail: document.querySelector("[data-sublink='users'] div[data-add] #add-mail"), // adresse mail de l'utilisateur
permissions: document.querySelector("[data-sublink='users'] div[data-add] #add-permissions"), // permissions de l'utilisateur
reference: document.querySelector("[data-sublink='users'] div[data-add] #add-reference"), // reference de l'utilisateur
submit: document.querySelector("[data-sublink='users'] div[data-add] #add-submit") // validation de la creation
},
remove: {
buttons: document.querySelectorAll('.remove-user')
}
};
/* (1) Gestion de la creation d'utilisateur */
/* (1.1) Gestion du toggle pour le panel de creation */
USERS.add.toggle.addEventListener('click', function(e){
// Gestion du toggle
if( USERS.add.state ) USERS.add.panel.addClass('active');
else USERS.add.panel.remClass('active');
USERS.add.state = !USERS.add.state; // switch de l'etat pour le toggle
}, false);
/* (1.2) Gestion de la creation */
USERS.add.submit.addEventListener('click', function(e){
// On redige la requete
var request = { // on ecrit la requete
'path': 'user/create',
'login': USERS.add.login.value,
'password': USERS.add.password.value,
'mail': USERS.add.mail.value,
'reference': USERS.add.reference.value,
'permissions': USERS.add.permissions.value
};
// On lance la requete
api.send(request, function(answer){
console.log(answer);
// Si la generation effectuee, on recharge la page
if( answer.ModuleError == 0 )
reload();
});
}, false);
/* (2) Gestion de la suppression d'utilisateur */
for( var i = 0 ; i < USERS.remove.buttons.length ; i++ ){
/* (2.0) Pour chaque bouton supprimer, on attache un evenement */
USERS.remove.buttons[i].addEventListener('click', function(e){
var user_id = e.target.parentNode.getData('id');
/* (2.1) Si on ne trouve pas l'id, on retourne une erreur */
if( user_id == false ){ console.warn('id de l\'utilisateur non trouvee'); return; }
/* (2.2) On lance la suppression */
var request = { // on ecrit la requete
'path': 'user/remove',
'user_id': user_id
};
// On lance la requete
api.send(request, function(answer){
console.log(answer);
// Si la suppression effectuee, on recharge la page // Si la suppression effectuee, on recharge la page
if( answer.ModuleError == 0 ) if( answer.ModuleError == 0 )
reload(); reload();

View File

@ -6,23 +6,25 @@
use \manager\ResourceDispatcher; use \manager\ResourceDispatcher;
use \manager\Database; use \manager\Database;
debug();
/* (1) Gestion des droits */
if( permission('admin') ){
/* [1] Gestion des tokens /* [1] Gestion des tokens
=========================================================*/ =========================================================*/
// permission: admin // permission: admin
//=======================================================// //=======================================================//
/* (1) On recupere la liste des tokens */ /* (2) On recupere la liste des tokens */
$req_tokens = new Repo('token/getAll'); $req_tokens = new Repo('token/getAll');
$tokens = $req_tokens->answer(); $tokens = $req_tokens->answer();
/* (2) Gestion des droits */ ?><section data-sublink='tokens'>
if( permission('admin') ){ ?>
<section data-sublink='tokens'>
<h6 class='center'>Gestion des accès distants</h6><br> <h6 class='center'>Gestion des accès distants</h6><br>
@ -38,8 +40,8 @@ if( permission('admin') ){ ?>
<div data-description>Liste des accès distants actifs. Ils seront automatiquement désactivés a la date d'expiration. Veuillez toutefois les supprimer.</div> <div data-description>Liste des accès distants actifs. Ils seront automatiquement désactivés a la date d'expiration. Veuillez toutefois les supprimer.</div>
<!-- Creation d'un nouvel element (cache) --> <!-- Creation d'un nouvel element (cache) -->
<div data-add> <div data-add>
<label for='add-name'>Nom de l'accès</label><br><input type='text' placeholder='token' id='add-name'><br> <span class='label'>Nom de l'accès</span><input type='text' placeholder='token' id='add-name'><br>
<label for='add-duration'>Duree de vie (jours)</label><br><input type='text' value='10' id='add-duration'><br> <span class='label'>Duree de vie (jours)</span><input type='text' value='10' id='add-duration'><br>
<input type='button' value='Ajouter un accès' id='add-submit'> <input type='button' value='Ajouter un accès' id='add-submit'>
</div> </div>
@ -52,9 +54,9 @@ if( permission('admin') ){ ?>
echo "<li data-element data-id='".$token['id']."'>"; echo "<li data-element data-id='".$token['id']."'>";
// Si token actif // Si token actif
if( !$token['expired'] ) if( !$token['expired'] )
echo "<div class='active'><span>actif</span></div>"; echo "<div class='active' data-token><span>actif</span></div>";
else else
echo "<div><span>Expiré</span></div>"; echo "<div data-token><span>Expiré</span></div>";
echo "<div>"; echo "<div>";
@ -76,8 +78,79 @@ if( permission('admin') ){ ?>
</section> </section>
</section> </section>
<?php } ?> <?php
/* [2] Gestion des utilisateurs
=========================================================*/
// permission: admin
//=======================================================//
/* (1) On recupere la liste des utilisateurs */
$req_users = new ModuleRequest('user/getAll');
$answer_users = $req_users->dispatch();
// Si erreur de requete
if( $answer_users->error != ManagerError::Success )
var_dump( ManagerError::explicit($answer_users->error) );
// On recupere la liste des utilisateurs
$users = $answer_users->get('users');
?><section data-sublink='users'>
<h6 class='center'>Gestion des utilisateurs</h6><br>
<!-- [1] Panel d'ajout/suppression d'utilisateur -->
<section data-panel-list>
<!-- Header -->
<div data-header>
<span>Gestion des utilisateurs</span>
<button id='add-user'>Ajouter un utilisateur</button>
</div>
<!-- Description des utilisateurs et des permissions -->
<div data-description>Liste des utilisateurs de la plateforme. Un <i>administrateur</i> peut tout faire. Un <i>sujet</i> peut compléter ses données et les consulter.</div>
<!-- Creation d'un nouvel element (cache) -->
<div data-add>
<span class='label'>Identifiant</span><input type='text' id='add-login'><br>
<span class='label'>Adresse mail</span><input type='email' id='add-mail'><br>
<span class='label'>Mot de passe</span><input type='password' id='add-password'><br>
<span class='label'>Vérification du mot de passe</span><input type='password' id='add-password2'><br>
<span class='label'>Droits</span>
<input type='checkbox' id='add-admin' id='add-admin'><label for='add-admin'>Administrateur</label>
<input type='checkbox' id='add-subject' id='add-subject'><label for='add-subject'>Sujet</label><br>
<input type='button' value='Créer un utilisateur' id='add-submit'>
</div>
<!-- Conteneur de la liste des elements -->
<ul data-list>
<!-- Elements de la liste -->
<?php
foreach($users as $user){
echo "<li data-element data-id='".$user['id_user']."'>";
// Si user actif
if( in_array('admin', $user['permission']) )
echo "<div class='active' data-user><span>Administrateur</span></div>";
else
echo "<div data-user><span>Sujet</span></div>";
echo "<div>";
echo "<span data-prefix='Identifiant'>".$user['login']."</span>";
echo "<span data-prefix='Adresse mail'>".$user['mail']."</span>";
echo "<span data-prefix='Permissions'>".implode(", ", $user['permission'])."</span>";
echo "</div>";
echo "<button class='remove-user'>Supprimer</button>";
echo "</li>";
}
?>
</ul>
<section data-sublink='users'>
Gestion des utilisateurs
</section> </section>
</section>
<!-- FIN PERMISSION ADMIN -->
<?php } ?>