Merge from booking branch
@ -0,0 +1,465 @@
|
||||
|
||||
body {
|
||||
background-color: grey;
|
||||
color: #303030;
|
||||
font-family: 'Arial', cursive;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
.tagname { color: #D0FFD0; }
|
||||
.tagname+.tagname:before { content: ', '; }
|
||||
.tagname:hover { background-color: red; cursor:pointer; }
|
||||
|
||||
/* Start by setting display:none to make this hidden.
|
||||
Then we position it in relation to the viewport window
|
||||
with position:fixed. Width, height, top and left speak
|
||||
for themselves. Background we set to 80% white with
|
||||
our animation centered, and no-repeating */
|
||||
.modal {
|
||||
display: none;
|
||||
position: fixed;
|
||||
z-index: 1000;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
background: rgba( 255, 255, 255, .8 )
|
||||
url('/App_Themes/images/FhHRx.gif')
|
||||
50% 50%
|
||||
no-repeat;
|
||||
overflow: auto;
|
||||
}
|
||||
.dispmodal {
|
||||
position: fixed;
|
||||
z-index: 1000;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
}
|
||||
|
||||
body.loading {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
body.loading .modal {
|
||||
display: block;
|
||||
}
|
||||
.iconsmall { max-height: 1.3em; max-width: 1.3em; }
|
||||
|
||||
input, textarea, checkbox {
|
||||
color: #FFA0A0;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
.post .photo { max-width: 100%; }
|
||||
|
||||
.blogbanner { float: left; top:0; }
|
||||
.subtitle { font-size:small; font-style: italic; }
|
||||
header {
|
||||
transition: margin 2s, padding 2s;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: block;
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.jpg") 50% 0 repeat fixed;
|
||||
}
|
||||
|
||||
#logo {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
min-height: 12em;
|
||||
background: url("/App_Themes/images/logo.s.png") 1em 1em no-repeat fixed;
|
||||
}
|
||||
|
||||
|
||||
|
||||
h1, h2, h3 { background-color: rgba(256,256,256,.5); }
|
||||
|
||||
nav {
|
||||
transition: margin 2s, padding 2s;
|
||||
margin: 2em;
|
||||
padding: 2em;
|
||||
display: block;
|
||||
border-radius:1em;
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.jpg") 50% 10em repeat fixed ;
|
||||
justify-content: space-around;
|
||||
}
|
||||
nav li { display: inline-block; }
|
||||
main {
|
||||
transition: margin 2s, padding 2s;
|
||||
margin: 2em;
|
||||
padding: 2em;
|
||||
display: block;
|
||||
border-radius:1em;
|
||||
background: url("/App_Themes/images/musician-923526_1.nbbi.jpg") 50% 20em repeat fixed ;
|
||||
}
|
||||
|
||||
footer {
|
||||
transition: margin 2s, padding 2s;
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.jpg") 50% 30em repeat fixed ;
|
||||
margin: 0;
|
||||
margin-top: 2em;
|
||||
padding: 2em;
|
||||
display: block;
|
||||
clear: both;
|
||||
font-size: smaller;
|
||||
justify-content: space-around;
|
||||
}
|
||||
footer {
|
||||
border-radius:1em;
|
||||
padding:1em;
|
||||
}
|
||||
legend {
|
||||
border-radius:5px;
|
||||
padding:.5em;
|
||||
background-color: rgba(240,240,240,.5);
|
||||
}
|
||||
#copyr { text-align: center; display: block; background-color: rgba(250,250,250,.8); }
|
||||
footer p { display:inline-block; }
|
||||
|
||||
footer img { max-height: 3em; vertical-align: middle; }
|
||||
a img, h1 img, .menuitem img { vertical-align: middle; }
|
||||
|
||||
#gspacer {
|
||||
background-color: rgba(209,209,209,.8);
|
||||
border-radius:1em;
|
||||
margin:1em; padding:1em; display: inline-block }
|
||||
|
||||
form {
|
||||
background-color: rgba(150,150,256,0.8);
|
||||
}
|
||||
|
||||
fieldset {
|
||||
background-color: rgba(216,216,256,0.8);
|
||||
border-radius:5px; border: solid 1px #000060;
|
||||
}
|
||||
|
||||
.post video, .post img {
|
||||
max-width:100%;
|
||||
max-height:75%;
|
||||
padding: 1em;
|
||||
}
|
||||
|
||||
aside {
|
||||
display: inline-block;
|
||||
float: right;
|
||||
max-width: 40em;
|
||||
}
|
||||
|
||||
.postpreview {
|
||||
display: inline-block;
|
||||
padding: 1em;
|
||||
background-color: rgba(233,233,233,0.8);
|
||||
border-radius:1em;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
img.postpreviewphoto, .postpreview video, .postpreview img {
|
||||
padding: 1em;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.post {
|
||||
display:block;
|
||||
padding: 1em;
|
||||
background-color: rgba(256,256,256,0.8);
|
||||
border-radius:1em;
|
||||
}
|
||||
.hiddenpost { background-color: rgba(160,160,160,0.5); }
|
||||
.fullwidth { width: 100%; }
|
||||
|
||||
textarea.fullwidth { min-height:10em; }
|
||||
a { color: rgb(0,56,0); }
|
||||
a:hover {
|
||||
background-color: rgba(160,160,160,.7);
|
||||
}
|
||||
|
||||
footer a {
|
||||
transition: margin 2s, padding 2s;
|
||||
border-radius:1em;
|
||||
margin:1em;
|
||||
padding:1em;
|
||||
text-decoration: none;
|
||||
display:inline-block;
|
||||
color: black;
|
||||
font-weight: bold;
|
||||
border: solid black 1px;
|
||||
background-color: rgba(220,220,220,.8);
|
||||
cursor: pointer;
|
||||
font-family: 'Arial', cursive;
|
||||
}
|
||||
.panel { max-width: 24em; display:inline-block; padding: 1em; }
|
||||
.panel,.bshpanel, aside {
|
||||
background-color: rgba(200,200,200,.8);
|
||||
border-radius: 1em;
|
||||
padding: 1em;
|
||||
}
|
||||
.spanel {
|
||||
max-width: 18em;
|
||||
display: inline-block;
|
||||
padding: .3em;
|
||||
}
|
||||
.xspanel {
|
||||
max-width:13em;
|
||||
display: inline-block;
|
||||
padding:.2em;
|
||||
}
|
||||
.xxspanel {
|
||||
max-width:7em;
|
||||
display: inline-block;
|
||||
padding:.1em;
|
||||
}
|
||||
.hint {
|
||||
display: inline;
|
||||
font-style: italic;
|
||||
font-size: smaller;
|
||||
}
|
||||
.hint::before {
|
||||
content: "(";
|
||||
}
|
||||
.hint::after {
|
||||
content: ")";
|
||||
}
|
||||
|
||||
|
||||
.usertitleref {
|
||||
border-radius: 1em;
|
||||
background-color:rgba(256,256,212,0.6);
|
||||
font-family: 'Arial', cursive;
|
||||
padding: 1em;
|
||||
}
|
||||
label {
|
||||
font-size: medium;
|
||||
}
|
||||
.editable {
|
||||
margin: .5em;
|
||||
min-height:1em;
|
||||
border-radius: 1em;
|
||||
border: dashed rgb(200,200,256) 2px;
|
||||
}
|
||||
|
||||
.notification {
|
||||
font-size: large;
|
||||
background-color: rgba(264,264,128,0.5);
|
||||
border: solid green 1px;
|
||||
padding: 1em;
|
||||
border-radius:1em;
|
||||
margin:1em;
|
||||
padding:1em;
|
||||
}
|
||||
.dirty {
|
||||
background-color: rgba(256,228,128,0.5);
|
||||
}
|
||||
.error, #error {
|
||||
color: #f88;
|
||||
font-size: large;
|
||||
background-color: rgba(256,.5);
|
||||
}
|
||||
.validation-summary-errors{
|
||||
color: #f88;
|
||||
background-color: rgba(256,256,139,0.5);
|
||||
}
|
||||
|
||||
.hidden { display:none; }
|
||||
|
||||
ul.preview li:nth-child(-n+10) {
|
||||
display:inline;
|
||||
font-size:xx-small;
|
||||
}
|
||||
|
||||
ul.preview li:nth-child(n) {
|
||||
display:none;
|
||||
}
|
||||
|
||||
.validation-summary-errors{
|
||||
color: #f88;
|
||||
}
|
||||
|
||||
a.menuitem {
|
||||
display:inline-block;
|
||||
color: black;
|
||||
font-weight: bold;
|
||||
border-radius:1em;
|
||||
border: solid black 1px;
|
||||
background-color: rgba(220,220,220,.8);
|
||||
cursor: pointer;
|
||||
font-family: 'Arial', cursive;
|
||||
padding: 1em;
|
||||
}
|
||||
|
||||
|
||||
.actionlink {
|
||||
text-decoration: none;
|
||||
display:inline-block;
|
||||
color: black;
|
||||
font-weight: bold;
|
||||
border-radius:1em;
|
||||
border: solid black 1px;
|
||||
background-color: rgba(220,220,220,.8);
|
||||
cursor: pointer;
|
||||
font-family: 'Arial', cursive;
|
||||
padding: 1em;
|
||||
}
|
||||
|
||||
input, select, textarea {
|
||||
color: black;
|
||||
background-color:rgba(256,256,256,0.8);
|
||||
border: solid 1px rgb(128,128,128);
|
||||
border-radius:1em;
|
||||
font-family: 'Arial', cursive;
|
||||
}
|
||||
|
||||
a:active {
|
||||
background-color:rgba(184,180,132,0.9);
|
||||
}
|
||||
|
||||
input:hover, textarea:hover {
|
||||
color: white;
|
||||
background-color:rgba(164,164,164,0.8);
|
||||
}
|
||||
.code {
|
||||
font-family: "monospace";
|
||||
background-color: rgba(230,230,230,0.5);
|
||||
border-radius:25px;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
#avatar {
|
||||
float: left;
|
||||
margin:1em;
|
||||
}
|
||||
|
||||
.comment {
|
||||
border-radius:25px;
|
||||
font-size: smaller;
|
||||
}
|
||||
|
||||
.onhover {
|
||||
display:none;
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
.ohafter:hover + .onhover, .ohinside:hover > .onhover {
|
||||
display:block;
|
||||
z-index:2;
|
||||
padding:5px; margin:5px;
|
||||
background-color: rgba(240,240,250,.8);
|
||||
}
|
||||
|
||||
.input-validation-error { border: solid 1px red; }
|
||||
.field-validation-error { color: red; }
|
||||
|
||||
.c2 { font-size: small; font-style: italic; }
|
||||
.c3 { font-size: x-small; font-style: italic; }
|
||||
|
||||
header h1, .actionlink, .menuitem {transition: padding 2s; padding:1em;}
|
||||
|
||||
@media print {
|
||||
body {background-color:white;color:black;}
|
||||
.control, .actionlink, .menuitem, nav { display:none;}
|
||||
}
|
||||
|
||||
.bshpanel { display:block; }
|
||||
.bsh { display: none; }
|
||||
.c3 { display:initial; }
|
||||
.c3-alt { display:none; }
|
||||
|
||||
@media all and (max-width: 640px) {
|
||||
#logo {
|
||||
min-height: 6em;
|
||||
background: url("/App_Themes/images/logo.xs.png") 0 0 no-repeat fixed;
|
||||
}
|
||||
|
||||
header {
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.s.jpg") 50% 0 repeat fixed;
|
||||
}
|
||||
|
||||
#avatar {
|
||||
margin:.5em;
|
||||
}
|
||||
|
||||
header h1, .actionlink, .menuitem { padding:.5em;}
|
||||
|
||||
nav {
|
||||
margin: 1em;
|
||||
padding: 1em;
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.s.jpg") 50% 10% repeat fixed ;
|
||||
}
|
||||
main {
|
||||
margin: 1em;
|
||||
padding: 1em;
|
||||
background: url("/App_Themes/images/musician-923526_1.nbbi.xs.jpg") 50% 20em repeat fixed ;
|
||||
}
|
||||
footer {
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.s.jpg") 50% 90% repeat fixed ;
|
||||
}
|
||||
footer a {
|
||||
border-radius:.5em;
|
||||
margin:.5em;
|
||||
padding:.5em;
|
||||
}
|
||||
|
||||
.notification {
|
||||
padding: .5em;
|
||||
border-radius:.5em;
|
||||
margin:.5em;
|
||||
padding:.5em;
|
||||
}
|
||||
.menuitem {
|
||||
display: block;
|
||||
}
|
||||
.post {
|
||||
margin:.3em;
|
||||
padding:.3em;
|
||||
}
|
||||
.usertitleref{
|
||||
padding:.3em;
|
||||
}
|
||||
.bshpanel { cursor:zoom-in; }
|
||||
|
||||
.c2 { display:initial; }
|
||||
.c2-alt { display:none; }
|
||||
.c3 { display:none; }
|
||||
.c3-alt { display:initial; }
|
||||
#gspacer {
|
||||
border-radius:.5em;
|
||||
margin:.5em; padding:.5em; }
|
||||
}
|
||||
|
||||
@media all and (max-width: 350px) {
|
||||
#logo {
|
||||
min-height: 3em;
|
||||
background: url("/App_Themes/images/logo.xxs.png") 0 0 no-repeat fixed;
|
||||
}
|
||||
header {
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.xxs.jpg") -1em -1em repeat fixed;
|
||||
}
|
||||
|
||||
header h1, .actionlink, .menuitem { padding:.2em;}
|
||||
|
||||
nav {
|
||||
margin: .5em;
|
||||
padding: .5em;
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.xxs.jpg") 50% 10% repeat fixed ;
|
||||
}
|
||||
main {
|
||||
margin: .5em;
|
||||
padding: .5em;
|
||||
background: url("/App_Themes/images/musician-923526_1.nbbi.xxs.jpg") 50% 20em repeat fixed ;
|
||||
}
|
||||
footer {
|
||||
background: url("/App_Themes/images/live-concert-388160_1280.xxs.jpg") 50% 90% repeat fixed ;
|
||||
}
|
||||
footer {
|
||||
border-radius:.2em;
|
||||
margin:.2em;
|
||||
padding:.2em;
|
||||
}
|
||||
.c2 { display:none; }
|
||||
.c2-alt { display:initial; }
|
||||
#gspacer {
|
||||
border-radius:.2em;
|
||||
margin:.2em; padding:.2em; }
|
||||
}
|
||||
|
@ -0,0 +1,345 @@
|
||||
|
||||
body {
|
||||
font-family: 'Arial', cursive;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
background-color: black;
|
||||
color: #D0FFD0;
|
||||
}
|
||||
.tagname { color: #D0FFD0; }
|
||||
.tagname+.tagname:before { content: ', '; }
|
||||
.tagname:hover { cursor:pointer; background-color: red; }
|
||||
|
||||
|
||||
.rate {
|
||||
border-radius:1em;
|
||||
border: solid rgb(128,128,0) 1px;
|
||||
background-color: rgba(20,20,20,.8);
|
||||
color: yellow;
|
||||
}
|
||||
.rate:hover { border-color: green;
|
||||
background-color:rgba(30,0,124,0.9); }
|
||||
|
||||
input, textarea, checkbox {
|
||||
color: #FFFFA0;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
header {
|
||||
transition: margin 2s, padding 2s;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
padding-top: 2em;
|
||||
padding-bottom:2em;
|
||||
display: block;
|
||||
background: url("/App_Themes/images/star-939235_1280.jpg") -3em -3em no-repeat fixed;
|
||||
}
|
||||
|
||||
header h1, header a {
|
||||
transition:padding 2s;
|
||||
background-color: rgba(0,0,0,.5);
|
||||
margin:0; padding:1em;
|
||||
}
|
||||
|
||||
nav {
|
||||
transition: margin 2s, padding 2s;
|
||||
margin: 2em;
|
||||
padding: 2em;
|
||||
display: block;
|
||||
border-radius:1em;
|
||||
background: url("/App_Themes/images/helix-nebula-1400x1400.s.jpg") 50% 10% repeat fixed ;
|
||||
justify-content: space-around;
|
||||
}
|
||||
|
||||
main {
|
||||
transition: margin 2s, padding 2s;
|
||||
margin: 2em;
|
||||
padding: 2em;
|
||||
display: block;
|
||||
border-radius:1em;
|
||||
background: url("/App_Themes/images/p8-av4.png") 50% 20em no-repeat fixed ;
|
||||
}
|
||||
|
||||
footer {
|
||||
transition: margin 2s, padding 2s;
|
||||
background: url("/App_Themes/images/helix-nebula-1400x1400.s.jpg") 50% 90% repeat fixed ;
|
||||
margin: 0;
|
||||
margin-top: 2em;
|
||||
padding: 2em;
|
||||
display: block;
|
||||
clear: both;
|
||||
font-size: smaller;
|
||||
justify-content: space-around;
|
||||
}
|
||||
|
||||
#copyr { text-align: center; display: block; background-color: rgba(20,20,20,.8); }
|
||||
footer p { display:inline-block; }
|
||||
|
||||
footer img { max-height: 3em; vertical-align: middle; }
|
||||
a img, h1 img, .menuitem img { vertical-align: middle; }
|
||||
fieldset {
|
||||
background-color: rgba(16,16,64,0.8);
|
||||
border-radius:5px; border: solid 1px #000060;
|
||||
}
|
||||
|
||||
legend {
|
||||
background-color: rgba(0,0,32,.5);
|
||||
}
|
||||
|
||||
#gspacer {
|
||||
background-color: rgba(20,20,20,.8);
|
||||
border-radius:1em;
|
||||
margin:1em; padding:1em; display: inline-block }
|
||||
|
||||
|
||||
main video, main img {
|
||||
max-width:100%;
|
||||
max-height:75%;
|
||||
padding: 1em;
|
||||
}
|
||||
|
||||
aside {
|
||||
display: inline-block;
|
||||
float: right;
|
||||
max-width: 40em;
|
||||
}
|
||||
|
||||
.postpreview {
|
||||
display: inline-block;
|
||||
max-width: 40em;
|
||||
padding: 1em;
|
||||
background-color: rgba(0,0,32,0.8);
|
||||
border-radius:1em;
|
||||
}
|
||||
.postpreview video, .postpreview img {
|
||||
max-width: 100%;
|
||||
padding: 1em;
|
||||
}
|
||||
.post {
|
||||
display:block;
|
||||
padding: 1em;
|
||||
background-color: rgba(0,0,32,0.8);
|
||||
color: #eee;
|
||||
border-radius:1em;
|
||||
}
|
||||
.hiddenpost { background-color: rgba(16,16,16,0.5); }
|
||||
.fullwidth { width: 100%; }
|
||||
|
||||
textarea.fullwidth { min-height:10em; }
|
||||
|
||||
.thanks {
|
||||
max-width: 10%;
|
||||
text-align: center;
|
||||
font-size:smaller;
|
||||
display:inline;
|
||||
bottom:0;
|
||||
}
|
||||
.panel {
|
||||
display:inline-block;
|
||||
}
|
||||
|
||||
.panel,.bshpanel, aside {
|
||||
background-color: rgba(20,20,20,.8);
|
||||
border-radius: 1em;
|
||||
padding: 1em;
|
||||
}
|
||||
.spanel {
|
||||
max-width: 18em;
|
||||
display: inline-block;
|
||||
padding: .3em;
|
||||
}
|
||||
.xspanel {
|
||||
max-width:13em;
|
||||
display: inline-block;
|
||||
padding:.2em;
|
||||
}
|
||||
.xxspanel {
|
||||
max-width:7em;
|
||||
display: inline-block;
|
||||
padding:.1em;
|
||||
}
|
||||
.hint {
|
||||
display: inline;
|
||||
font-style: italic;
|
||||
font-size: smaller;
|
||||
}
|
||||
.hint::before {
|
||||
content: "(";
|
||||
}
|
||||
.hint::after {
|
||||
content: ")";
|
||||
}
|
||||
|
||||
|
||||
.usertitleref {
|
||||
border-radius: 1em;
|
||||
background-color:rgba(0,0,32,0.6);
|
||||
font-family: 'Arial', cursive;
|
||||
padding: 1em;
|
||||
}
|
||||
label {
|
||||
font-size: medium;
|
||||
}
|
||||
.editable {
|
||||
margin: .5em;
|
||||
min-height:1em;
|
||||
border-radius: 1em;
|
||||
border: dashed rgb(020,20,256) 2px;
|
||||
}
|
||||
|
||||
.notification {
|
||||
font-size: large;
|
||||
background-color: rgba(64,64,0,0.5);
|
||||
border: solid green 1px;
|
||||
padding: 1em;
|
||||
border-radius:1em;
|
||||
margin:1em;
|
||||
padding:1em;
|
||||
}
|
||||
.dirty {
|
||||
background-color: rgba(128,128,0,0.5);
|
||||
}
|
||||
.error, #error {
|
||||
color: #f88;
|
||||
font-size: large;
|
||||
background-color: rgba(256,0,0,0.5);
|
||||
}
|
||||
.validation-summary-errors{
|
||||
color: #f88;
|
||||
background-color: rgba(256,0,0,0.5);
|
||||
}
|
||||
|
||||
.hidden { display:none; }
|
||||
|
||||
ul.preview li:nth-child(-n+10) {
|
||||
display:inline;
|
||||
font-size:xx-small;
|
||||
}
|
||||
|
||||
ul.preview li:nth-child(n) {
|
||||
display:none;
|
||||
}
|
||||
|
||||
.validation-summary-errors{
|
||||
color: #f88;
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.actionlink, .menuitem, a {
|
||||
border-color: rgb(128,128,0);
|
||||
background-color: rgba(20,20,20,.8);
|
||||
color: yellow;
|
||||
}
|
||||
|
||||
input, select, textarea {
|
||||
color: white;
|
||||
background-color:rgba(0,0,64,0.8);
|
||||
border-color: rgb(128,128,128);
|
||||
}
|
||||
|
||||
a:hover {
|
||||
background-color:rgba(30,0,124,0.9);
|
||||
border-color: green ;
|
||||
}
|
||||
a:active {
|
||||
background-color:rgba(124,0,32,0.9);
|
||||
}
|
||||
|
||||
input:hover, textarea:hover {
|
||||
color: white;
|
||||
background-color:rgba(64,64,64,0.8);
|
||||
}
|
||||
.code {
|
||||
background-color: rgba(0,0,256,0.1);
|
||||
}
|
||||
|
||||
|
||||
@media all and (max-width: 640px) {
|
||||
header {
|
||||
padding-top:1em;
|
||||
padding-bottom:1em;
|
||||
background: url("/App_Themes/images/star-939235_1280.s.jpg") 0 0 no-repeat fixed;
|
||||
}
|
||||
|
||||
#avatar {
|
||||
margin:.5em;
|
||||
}
|
||||
|
||||
header h1, header a , .actionlink, .menuitem, a { padding:.5em;}
|
||||
|
||||
nav {
|
||||
margin: 1em;
|
||||
padding: 1em;
|
||||
background: url("/App_Themes/images/helix-nebula-1400x1400.s.jpg") 50% 10% repeat fixed ;
|
||||
}
|
||||
main {
|
||||
margin: 1em;
|
||||
padding: 1em;
|
||||
background: url("/App_Themes/images/p8-av4.s.jpg") 50% 20em no-repeat fixed ;
|
||||
}
|
||||
footer {
|
||||
background: url("/App_Themes/images/helix-nebula-1400x1400.s.jpg") 50% 90% repeat fixed ;
|
||||
}
|
||||
footer a {
|
||||
border-radius:.5em;
|
||||
margin:.5em;
|
||||
padding:.5em;
|
||||
}
|
||||
|
||||
.notification {
|
||||
padding: .5em;
|
||||
border-radius:.5em;
|
||||
margin:.5em;
|
||||
padding:.5em;
|
||||
}
|
||||
.menuitem {
|
||||
display: block;
|
||||
}
|
||||
.post {
|
||||
margin:.3em;
|
||||
padding:.3em;
|
||||
}
|
||||
.usertitleref{
|
||||
padding:.3em;
|
||||
}
|
||||
.bshpanel { cursor:zoom-in; }
|
||||
|
||||
.c2 { display:initial; }
|
||||
.c2-alt { display:none; }
|
||||
.c3 { display:none; }
|
||||
.c3-alt { display:initial; }
|
||||
}
|
||||
|
||||
@media all and (max-width: 350px) {
|
||||
header {
|
||||
padding-top:.5em;
|
||||
padding-bottom:.5em;
|
||||
background: url("/App_Themes/images/star-939235_1280.xxs.jpg") 0 0 no-repeat fixed;
|
||||
}
|
||||
|
||||
header h1, header a { padding:.2em;}
|
||||
|
||||
nav {
|
||||
margin: .5em;
|
||||
padding: .5em;
|
||||
background: url("/App_Themes/images/helix-nebula-1400x1400.xxs.jpg") 50% 10% repeat fixed ;
|
||||
}
|
||||
main {
|
||||
margin: .5em;
|
||||
padding: .5em;
|
||||
background: url("/App_Themes/images/p8-av4.xxs.jpg") 50% 20em repeat fixed ;
|
||||
}
|
||||
footer {
|
||||
background: url("/App_Themes/images/helix-nebula-1400x1400.xxs.jpg") 50% 10% repeat fixed ;
|
||||
}
|
||||
footer a {
|
||||
border-radius:.2em;
|
||||
margin:.2em;
|
||||
padding:.2em;
|
||||
}
|
||||
.c2 { display:none; }
|
||||
.c2-alt { display:initial; }
|
||||
}
|
After Width: | Height: | Size: 752 B |
After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 164 KiB |
After Width: | Height: | Size: 70 KiB |
After Width: | Height: | Size: 24 KiB |
After Width: | Height: | Size: 46 KiB |
After Width: | Height: | Size: 293 KiB |
After Width: | Height: | Size: 52 KiB |
After Width: | Height: | Size: 136 KiB |
After Width: | Height: | Size: 38 KiB |
After Width: | Height: | Size: 9.8 KiB |
After Width: | Height: | Size: 132 KiB |
After Width: | Height: | Size: 20 KiB |
After Width: | Height: | Size: 4.1 KiB |
@ -0,0 +1,189 @@
|
||||
/* NUGET: BEGIN LICENSE TEXT
|
||||
*
|
||||
* Microsoft grants you the right to use these script files for the sole
|
||||
* purpose of either: (i) interacting through your browser with the Microsoft
|
||||
* website or online service, subject to the applicable licensing or use
|
||||
* terms; or (ii) using the files as included with a Microsoft product subject
|
||||
* to that product's license terms. Microsoft reserves all other rights to the
|
||||
* files not expressly granted by Microsoft, whether by implication, estoppel
|
||||
* or otherwise. Insofar as a script file is dual licensed under GPL,
|
||||
* Microsoft neither took the code under GPL nor distributes it thereunder but
|
||||
* under the terms set out in this paragraph. All notices and licenses
|
||||
* below are for informational purposes only.
|
||||
*
|
||||
* NUGET: END LICENSE TEXT */
|
||||
/*!
|
||||
** Unobtrusive Ajax support library for jQuery
|
||||
** Copyright (C) Microsoft Corporation. All rights reserved.
|
||||
*/
|
||||
|
||||
/*jslint white: true, browser: true, onevar: true, undef: true, nomen: true, eqeqeq: true, plusplus: true, bitwise: true, regexp: true, newcap: true, immed: true, strict: false */
|
||||
/*global window: false, jQuery: false */
|
||||
|
||||
(function ($) {
|
||||
var data_click = "unobtrusiveAjaxClick",
|
||||
data_target = "unobtrusiveAjaxClickTarget",
|
||||
data_validation = "unobtrusiveValidation";
|
||||
|
||||
function getFunction(code, argNames) {
|
||||
var fn = window, parts = (code || "").split(".");
|
||||
while (fn && parts.length) {
|
||||
fn = fn[parts.shift()];
|
||||
}
|
||||
if (typeof (fn) === "function") {
|
||||
return fn;
|
||||
}
|
||||
argNames.push(code);
|
||||
return Function.constructor.apply(null, argNames);
|
||||
}
|
||||
|
||||
function isMethodProxySafe(method) {
|
||||
return method === "GET" || method === "POST";
|
||||
}
|
||||
|
||||
function asyncOnBeforeSend(xhr, method) {
|
||||
if (!isMethodProxySafe(method)) {
|
||||
xhr.setRequestHeader("X-HTTP-Method-Override", method);
|
||||
}
|
||||
}
|
||||
|
||||
function asyncOnSuccess(element, data, contentType) {
|
||||
var mode;
|
||||
|
||||
if (contentType.indexOf("application/x-javascript") !== -1) { // jQuery already executes JavaScript for us
|
||||
return;
|
||||
}
|
||||
|
||||
mode = (element.getAttribute("data-ajax-mode") || "").toUpperCase();
|
||||
$(element.getAttribute("data-ajax-update")).each(function (i, update) {
|
||||
var top;
|
||||
|
||||
switch (mode) {
|
||||
case "BEFORE":
|
||||
top = update.firstChild;
|
||||
$("<div />").html(data).contents().each(function () {
|
||||
update.insertBefore(this, top);
|
||||
});
|
||||
break;
|
||||
case "AFTER":
|
||||
$("<div />").html(data).contents().each(function () {
|
||||
update.appendChild(this);
|
||||
});
|
||||
break;
|
||||
case "REPLACE-WITH":
|
||||
$(update).replaceWith(data);
|
||||
break;
|
||||
default:
|
||||
$(update).html(data);
|
||||
break;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function asyncRequest(element, options) {
|
||||
var confirm, loading, method, duration;
|
||||
|
||||
confirm = element.getAttribute("data-ajax-confirm");
|
||||
if (confirm && !window.confirm(confirm)) {
|
||||
return;
|
||||
}
|
||||
|
||||
loading = $(element.getAttribute("data-ajax-loading"));
|
||||
duration = parseInt(element.getAttribute("data-ajax-loading-duration"), 10) || 0;
|
||||
|
||||
$.extend(options, {
|
||||
type: element.getAttribute("data-ajax-method") || undefined,
|
||||
url: element.getAttribute("data-ajax-url") || undefined,
|
||||
cache: !!element.getAttribute("data-ajax-cache"),
|
||||
beforeSend: function (xhr) {
|
||||
var result;
|
||||
asyncOnBeforeSend(xhr, method);
|
||||
result = getFunction(element.getAttribute("data-ajax-begin"), ["xhr"]).apply(element, arguments);
|
||||
if (result !== false) {
|
||||
loading.show(duration);
|
||||
}
|
||||
return result;
|
||||
},
|
||||
complete: function () {
|
||||
loading.hide(duration);
|
||||
getFunction(element.getAttribute("data-ajax-complete"), ["xhr", "status"]).apply(element, arguments);
|
||||
},
|
||||
success: function (data, status, xhr) {
|
||||
asyncOnSuccess(element, data, xhr.getResponseHeader("Content-Type") || "text/html");
|
||||
getFunction(element.getAttribute("data-ajax-success"), ["data", "status", "xhr"]).apply(element, arguments);
|
||||
},
|
||||
error: function () {
|
||||
getFunction(element.getAttribute("data-ajax-failure"), ["xhr", "status", "error"]).apply(element, arguments);
|
||||
}
|
||||
});
|
||||
|
||||
options.data.push({ name: "X-Requested-With", value: "XMLHttpRequest" });
|
||||
|
||||
method = options.type.toUpperCase();
|
||||
if (!isMethodProxySafe(method)) {
|
||||
options.type = "POST";
|
||||
options.data.push({ name: "X-HTTP-Method-Override", value: method });
|
||||
}
|
||||
|
||||
$.ajax(options);
|
||||
}
|
||||
|
||||
function validate(form) {
|
||||
var validationInfo = $(form).data(data_validation);
|
||||
return !validationInfo || !validationInfo.validate || validationInfo.validate();
|
||||
}
|
||||
|
||||
$(document).on("click", "a[data-ajax=true]", function (evt) {
|
||||
evt.preventDefault();
|
||||
asyncRequest(this, {
|
||||
url: this.href,
|
||||
type: "GET",
|
||||
data: []
|
||||
});
|
||||
});
|
||||
|
||||
$(document).on("click", "form[data-ajax=true] input[type=image]", function (evt) {
|
||||
var name = evt.target.name,
|
||||
target = $(evt.target),
|
||||
form = $(target.parents("form")[0]),
|
||||
offset = target.offset();
|
||||
|
||||
form.data(data_click, [
|
||||
{ name: name + ".x", value: Math.round(evt.pageX - offset.left) },
|
||||
{ name: name + ".y", value: Math.round(evt.pageY - offset.top) }
|
||||
]);
|
||||
|
||||
setTimeout(function () {
|
||||
form.removeData(data_click);
|
||||
}, 0);
|
||||
});
|
||||
|
||||
$(document).on("click", "form[data-ajax=true] :submit", function (evt) {
|
||||
var name = evt.currentTarget.name,
|
||||
target = $(evt.target),
|
||||
form = $(target.parents("form")[0]);
|
||||
|
||||
form.data(data_click, name ? [{ name: name, value: evt.currentTarget.value }] : []);
|
||||
form.data(data_target, target);
|
||||
|
||||
setTimeout(function () {
|
||||
form.removeData(data_click);
|
||||
form.removeData(data_target);
|
||||
}, 0);
|
||||
});
|
||||
|
||||
$(document).on("submit", "form[data-ajax=true]", function (evt) {
|
||||
var clickInfo = $(this).data(data_click) || [],
|
||||
clickTarget = $(this).data(data_target),
|
||||
isCancel = clickTarget && clickTarget.hasClass("cancel");
|
||||
evt.preventDefault();
|
||||
if (!isCancel && !validate(this)) {
|
||||
return;
|
||||
}
|
||||
asyncRequest(this, {
|
||||
url: this.action,
|
||||
type: this.method || "GET",
|
||||
data: clickInfo.concat($(this).serializeArray())
|
||||
});
|
||||
});
|
||||
}(jQuery));
|
@ -0,0 +1,19 @@
|
||||
/* NUGET: BEGIN LICENSE TEXT
|
||||
*
|
||||
* Microsoft grants you the right to use these script files for the sole
|
||||
* purpose of either: (i) interacting through your browser with the Microsoft
|
||||
* website or online service, subject to the applicable licensing or use
|
||||
* terms; or (ii) using the files as included with a Microsoft product subject
|
||||
* to that product's license terms. Microsoft reserves all other rights to the
|
||||
* files not expressly granted by Microsoft, whether by implication, estoppel
|
||||
* or otherwise. Insofar as a script file is dual licensed under GPL,
|
||||
* Microsoft neither took the code under GPL nor distributes it thereunder but
|
||||
* under the terms set out in this paragraph. All notices and licenses
|
||||
* below are for informational purposes only.
|
||||
*
|
||||
* NUGET: END LICENSE TEXT */
|
||||
/*
|
||||
** Unobtrusive Ajax support library for jQuery
|
||||
** Copyright (C) Microsoft Corporation. All rights reserved.
|
||||
*/
|
||||
(function(a){var b="unobtrusiveAjaxClick",d="unobtrusiveAjaxClickTarget",h="unobtrusiveValidation";function c(d,b){var a=window,c=(d||"").split(".");while(a&&c.length)a=a[c.shift()];if(typeof a==="function")return a;b.push(d);return Function.constructor.apply(null,b)}function e(a){return a==="GET"||a==="POST"}function g(b,a){!e(a)&&b.setRequestHeader("X-HTTP-Method-Override",a)}function i(c,b,e){var d;if(e.indexOf("application/x-javascript")!==-1)return;d=(c.getAttribute("data-ajax-mode")||"").toUpperCase();a(c.getAttribute("data-ajax-update")).each(function(f,c){var e;switch(d){case"BEFORE":e=c.firstChild;a("<div />").html(b).contents().each(function(){c.insertBefore(this,e)});break;case"AFTER":a("<div />").html(b).contents().each(function(){c.appendChild(this)});break;case"REPLACE-WITH":a(c).replaceWith(b);break;default:a(c).html(b)}})}function f(b,d){var j,k,f,h;j=b.getAttribute("data-ajax-confirm");if(j&&!window.confirm(j))return;k=a(b.getAttribute("data-ajax-loading"));h=parseInt(b.getAttribute("data-ajax-loading-duration"),10)||0;a.extend(d,{type:b.getAttribute("data-ajax-method")||undefined,url:b.getAttribute("data-ajax-url")||undefined,cache:!!b.getAttribute("data-ajax-cache"),beforeSend:function(d){var a;g(d,f);a=c(b.getAttribute("data-ajax-begin"),["xhr"]).apply(b,arguments);a!==false&&k.show(h);return a},complete:function(){k.hide(h);c(b.getAttribute("data-ajax-complete"),["xhr","status"]).apply(b,arguments)},success:function(a,e,d){i(b,a,d.getResponseHeader("Content-Type")||"text/html");c(b.getAttribute("data-ajax-success"),["data","status","xhr"]).apply(b,arguments)},error:function(){c(b.getAttribute("data-ajax-failure"),["xhr","status","error"]).apply(b,arguments)}});d.data.push({name:"X-Requested-With",value:"XMLHttpRequest"});f=d.type.toUpperCase();if(!e(f)){d.type="POST";d.data.push({name:"X-HTTP-Method-Override",value:f})}a.ajax(d)}function j(c){var b=a(c).data(h);return!b||!b.validate||b.validate()}a(document).on("click","a[data-ajax=true]",function(a){a.preventDefault();f(this,{url:this.href,type:"GET",data:[]})});a(document).on("click","form[data-ajax=true] input[type=image]",function(c){var g=c.target.name,e=a(c.target),f=a(e.parents("form")[0]),d=e.offset();f.data(b,[{name:g+".x",value:Math.round(c.pageX-d.left)},{name:g+".y",value:Math.round(c.pageY-d.top)}]);setTimeout(function(){f.removeData(b)},0)});a(document).on("click","form[data-ajax=true] :submit",function(e){var g=e.currentTarget.name,f=a(e.target),c=a(f.parents("form")[0]);c.data(b,g?[{name:g,value:e.currentTarget.value}]:[]);c.data(d,f);setTimeout(function(){c.removeData(b);c.removeData(d)},0)});a(document).on("submit","form[data-ajax=true]",function(h){var e=a(this).data(b)||[],c=a(this).data(d),g=c&&c.hasClass("cancel");h.preventDefault();if(!g&&!j(this))return;f(this,{url:this.action,type:this.method||"GET",data:e.concat(a(this).serializeArray())})})})(jQuery);
|
@ -0,0 +1,429 @@
|
||||
/* NUGET: BEGIN LICENSE TEXT
|
||||
*
|
||||
* Microsoft grants you the right to use these script files for the sole
|
||||
* purpose of either: (i) interacting through your browser with the Microsoft
|
||||
* website or online service, subject to the applicable licensing or use
|
||||
* terms; or (ii) using the files as included with a Microsoft product subject
|
||||
* to that product's license terms. Microsoft reserves all other rights to the
|
||||
* files not expressly granted by Microsoft, whether by implication, estoppel
|
||||
* or otherwise. Insofar as a script file is dual licensed under GPL,
|
||||
* Microsoft neither took the code under GPL nor distributes it thereunder but
|
||||
* under the terms set out in this paragraph. All notices and licenses
|
||||
* below are for informational purposes only.
|
||||
*
|
||||
* NUGET: END LICENSE TEXT */
|
||||
/*!
|
||||
** Unobtrusive validation support library for jQuery and jQuery Validate
|
||||
** Copyright (C) Microsoft Corporation. All rights reserved.
|
||||
*/
|
||||
|
||||
/*jslint white: true, browser: true, onevar: true, undef: true, nomen: true, eqeqeq: true, plusplus: true, bitwise: true, regexp: true, newcap: true, immed: true, strict: false */
|
||||
/*global document: false, jQuery: false */
|
||||
|
||||
(function ($) {
|
||||
var $jQval = $.validator,
|
||||
adapters,
|
||||
data_validation = "unobtrusiveValidation";
|
||||
|
||||
function setValidationValues(options, ruleName, value) {
|
||||
options.rules[ruleName] = value;
|
||||
if (options.message) {
|
||||
options.messages[ruleName] = options.message;
|
||||
}
|
||||
}
|
||||
|
||||
function splitAndTrim(value) {
|
||||
return value.replace(/^\s+|\s+$/g, "").split(/\s*,\s*/g);
|
||||
}
|
||||
|
||||
function escapeAttributeValue(value) {
|
||||
// As mentioned on http://api.jquery.com/category/selectors/
|
||||
return value.replace(/([!"#$%&'()*+,./:;<=>?@\[\\\]^`{|}~])/g, "\\$1");
|
||||
}
|
||||
|
||||
function getModelPrefix(fieldName) {
|
||||
return fieldName.substr(0, fieldName.lastIndexOf(".") + 1);
|
||||
}
|
||||
|
||||
function appendModelPrefix(value, prefix) {
|
||||
if (value.indexOf("*.") === 0) {
|
||||
value = value.replace("*.", prefix);
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
function onError(error, inputElement) { // 'this' is the form element
|
||||
var container = $(this).find("[data-valmsg-for='" + escapeAttributeValue(inputElement[0].name) + "']"),
|
||||
replaceAttrValue = container.attr("data-valmsg-replace"),
|
||||
replace = replaceAttrValue ? $.parseJSON(replaceAttrValue) !== false : null;
|
||||
|
||||
container.removeClass("field-validation-valid").addClass("field-validation-error");
|
||||
error.data("unobtrusiveContainer", container);
|
||||
|
||||
if (replace) {
|
||||
container.empty();
|
||||
error.removeClass("input-validation-error").appendTo(container);
|
||||
}
|
||||
else {
|
||||
error.hide();
|
||||
}
|
||||
}
|
||||
|
||||
function onErrors(event, validator) { // 'this' is the form element
|
||||
var container = $(this).find("[data-valmsg-summary=true]"),
|
||||
list = container.find("ul");
|
||||
|
||||
if (list && list.length && validator.errorList.length) {
|
||||
list.empty();
|
||||
container.addClass("validation-summary-errors").removeClass("validation-summary-valid");
|
||||
|
||||
$.each(validator.errorList, function () {
|
||||
$("<li />").html(this.message).appendTo(list);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function onSuccess(error) { // 'this' is the form element
|
||||
var container = error.data("unobtrusiveContainer"),
|
||||
replaceAttrValue = container.attr("data-valmsg-replace"),
|
||||
replace = replaceAttrValue ? $.parseJSON(replaceAttrValue) : null;
|
||||
|
||||
if (container) {
|
||||
container.addClass("field-validation-valid").removeClass("field-validation-error");
|
||||
error.removeData("unobtrusiveContainer");
|
||||
|
||||
if (replace) {
|
||||
container.empty();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function onReset(event) { // 'this' is the form element
|
||||
var $form = $(this),
|
||||
key = '__jquery_unobtrusive_validation_form_reset';
|
||||
if ($form.data(key)) {
|
||||
return;
|
||||
}
|
||||
// Set a flag that indicates we're currently resetting the form.
|
||||
$form.data(key, true);
|
||||
try {
|
||||
$form.data("validator").resetForm();
|
||||
} finally {
|
||||
$form.removeData(key);
|
||||
}
|
||||
|
||||
$form.find(".validation-summary-errors")
|
||||
.addClass("validation-summary-valid")
|
||||
.removeClass("validation-summary-errors");
|
||||
$form.find(".field-validation-error")
|
||||
.addClass("field-validation-valid")
|
||||
.removeClass("field-validation-error")
|
||||
.removeData("unobtrusiveContainer")
|
||||
.find(">*") // If we were using valmsg-replace, get the underlying error
|
||||
.removeData("unobtrusiveContainer");
|
||||
}
|
||||
|
||||
function validationInfo(form) {
|
||||
var $form = $(form),
|
||||
result = $form.data(data_validation),
|
||||
onResetProxy = $.proxy(onReset, form),
|
||||
defaultOptions = $jQval.unobtrusive.options || {},
|
||||
execInContext = function (name, args) {
|
||||
var func = defaultOptions[name];
|
||||
func && $.isFunction(func) && func.apply(form, args);
|
||||
}
|
||||
|
||||
if (!result) {
|
||||
result = {
|
||||
options: { // options structure passed to jQuery Validate's validate() method
|
||||
errorClass: defaultOptions.errorClass || "input-validation-error",
|
||||
errorElement: defaultOptions.errorElement || "span",
|
||||
errorPlacement: function () {
|
||||
onError.apply(form, arguments);
|
||||
execInContext("errorPlacement", arguments);
|
||||
},
|
||||
invalidHandler: function () {
|
||||
onErrors.apply(form, arguments);
|
||||
execInContext("invalidHandler", arguments);
|
||||
},
|
||||
messages: {},
|
||||
rules: {},
|
||||
success: function () {
|
||||
onSuccess.apply(form, arguments);
|
||||
execInContext("success", arguments);
|
||||
}
|
||||
},
|
||||
attachValidation: function () {
|
||||
$form
|
||||
.off("reset." + data_validation, onResetProxy)
|
||||
.on("reset." + data_validation, onResetProxy)
|
||||
.validate(this.options);
|
||||
},
|
||||
validate: function () { // a validation function that is called by unobtrusive Ajax
|
||||
$form.validate();
|
||||
return $form.valid();
|
||||
}
|
||||
};
|
||||
$form.data(data_validation, result);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
$jQval.unobtrusive = {
|
||||
adapters: [],
|
||||
|
||||
parseElement: function (element, skipAttach) {
|
||||
/// <summary>
|
||||
/// Parses a single HTML element for unobtrusive validation attributes.
|
||||
/// </summary>
|
||||
/// <param name="element" domElement="true">The HTML element to be parsed.</param>
|
||||
/// <param name="skipAttach" type="Boolean">[Optional] true to skip attaching the
|
||||
/// validation to the form. If parsing just this single element, you should specify true.
|
||||
/// If parsing several elements, you should specify false, and manually attach the validation
|
||||
/// to the form when you are finished. The default is false.</param>
|
||||
var $element = $(element),
|
||||
form = $element.parents("form")[0],
|
||||
valInfo, rules, messages;
|
||||
|
||||
if (!form) { // Cannot do client-side validation without a form
|
||||
return;
|
||||
}
|
||||
|
||||
valInfo = validationInfo(form);
|
||||
valInfo.options.rules[element.name] = rules = {};
|
||||
valInfo.options.messages[element.name] = messages = {};
|
||||
|
||||
$.each(this.adapters, function () {
|
||||
var prefix = "data-val-" + this.name,
|
||||
message = $element.attr(prefix),
|
||||
paramValues = {};
|
||||
|
||||
if (message !== undefined) { // Compare against undefined, because an empty message is legal (and falsy)
|
||||
prefix += "-";
|
||||
|
||||
$.each(this.params, function () {
|
||||
paramValues[this] = $element.attr(prefix + this);
|
||||
});
|
||||
|
||||
this.adapt({
|
||||
element: element,
|
||||
form: form,
|
||||
message: message,
|
||||
params: paramValues,
|
||||
rules: rules,
|
||||
messages: messages
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$.extend(rules, { "__dummy__": true });
|
||||
|
||||
if (!skipAttach) {
|
||||
valInfo.attachValidation();
|
||||
}
|
||||
},
|
||||
|
||||
parse: function (selector) {
|
||||
/// <summary>
|
||||
/// Parses all the HTML elements in the specified selector. It looks for input elements decorated
|
||||
/// with the [data-val=true] attribute value and enables validation according to the data-val-*
|
||||
/// attribute values.
|
||||
/// </summary>
|
||||
/// <param name="selector" type="String">Any valid jQuery selector.</param>
|
||||
|
||||
// $forms includes all forms in selector's DOM hierarchy (parent, children and self) that have at least one
|
||||
// element with data-val=true
|
||||
var $selector = $(selector),
|
||||
$forms = $selector.parents()
|
||||
.addBack()
|
||||
.filter("form")
|
||||
.add($selector.find("form"))
|
||||
.has("[data-val=true]");
|
||||
|
||||
$selector.find("[data-val=true]").each(function () {
|
||||
$jQval.unobtrusive.parseElement(this, true);
|
||||
});
|
||||
|
||||
$forms.each(function () {
|
||||
var info = validationInfo(this);
|
||||
if (info) {
|
||||
info.attachValidation();
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
adapters = $jQval.unobtrusive.adapters;
|
||||
|
||||
adapters.add = function (adapterName, params, fn) {
|
||||
/// <summary>Adds a new adapter to convert unobtrusive HTML into a jQuery Validate validation.</summary>
|
||||
/// <param name="adapterName" type="String">The name of the adapter to be added. This matches the name used
|
||||
/// in the data-val-nnnn HTML attribute (where nnnn is the adapter name).</param>
|
||||
/// <param name="params" type="Array" optional="true">[Optional] An array of parameter names (strings) that will
|
||||
/// be extracted from the data-val-nnnn-mmmm HTML attributes (where nnnn is the adapter name, and
|
||||
/// mmmm is the parameter name).</param>
|
||||
/// <param name="fn" type="Function">The function to call, which adapts the values from the HTML
|
||||
/// attributes into jQuery Validate rules and/or messages.</param>
|
||||
/// <returns type="jQuery.validator.unobtrusive.adapters" />
|
||||
if (!fn) { // Called with no params, just a function
|
||||
fn = params;
|
||||
params = [];
|
||||
}
|
||||
this.push({ name: adapterName, params: params, adapt: fn });
|
||||
return this;
|
||||
};
|
||||
|
||||
adapters.addBool = function (adapterName, ruleName) {
|
||||
/// <summary>Adds a new adapter to convert unobtrusive HTML into a jQuery Validate validation, where
|
||||
/// the jQuery Validate validation rule has no parameter values.</summary>
|
||||
/// <param name="adapterName" type="String">The name of the adapter to be added. This matches the name used
|
||||
/// in the data-val-nnnn HTML attribute (where nnnn is the adapter name).</param>
|
||||
/// <param name="ruleName" type="String" optional="true">[Optional] The name of the jQuery Validate rule. If not provided, the value
|
||||
/// of adapterName will be used instead.</param>
|
||||
/// <returns type="jQuery.validator.unobtrusive.adapters" />
|
||||
return this.add(adapterName, function (options) {
|
||||
setValidationValues(options, ruleName || adapterName, true);
|
||||
});
|
||||
};
|
||||
|
||||
adapters.addMinMax = function (adapterName, minRuleName, maxRuleName, minMaxRuleName, minAttribute, maxAttribute) {
|
||||
/// <summary>Adds a new adapter to convert unobtrusive HTML into a jQuery Validate validation, where
|
||||
/// the jQuery Validate validation has three potential rules (one for min-only, one for max-only, and
|
||||
/// one for min-and-max). The HTML parameters are expected to be named -min and -max.</summary>
|
||||
/// <param name="adapterName" type="String">The name of the adapter to be added. This matches the name used
|
||||
/// in the data-val-nnnn HTML attribute (where nnnn is the adapter name).</param>
|
||||
/// <param name="minRuleName" type="String">The name of the jQuery Validate rule to be used when you only
|
||||
/// have a minimum value.</param>
|
||||
/// <param name="maxRuleName" type="String">The name of the jQuery Validate rule to be used when you only
|
||||
/// have a maximum value.</param>
|
||||
/// <param name="minMaxRuleName" type="String">The name of the jQuery Validate rule to be used when you
|
||||
/// have both a minimum and maximum value.</param>
|
||||
/// <param name="minAttribute" type="String" optional="true">[Optional] The name of the HTML attribute that
|
||||
/// contains the minimum value. The default is "min".</param>
|
||||
/// <param name="maxAttribute" type="String" optional="true">[Optional] The name of the HTML attribute that
|
||||
/// contains the maximum value. The default is "max".</param>
|
||||
/// <returns type="jQuery.validator.unobtrusive.adapters" />
|
||||
return this.add(adapterName, [minAttribute || "min", maxAttribute || "max"], function (options) {
|
||||
var min = options.params.min,
|
||||
max = options.params.max;
|
||||
|
||||
if (min && max) {
|
||||
setValidationValues(options, minMaxRuleName, [min, max]);
|
||||
}
|
||||
else if (min) {
|
||||
setValidationValues(options, minRuleName, min);
|
||||
}
|
||||
else if (max) {
|
||||
setValidationValues(options, maxRuleName, max);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
adapters.addSingleVal = function (adapterName, attribute, ruleName) {
|
||||
/// <summary>Adds a new adapter to convert unobtrusive HTML into a jQuery Validate validation, where
|
||||
/// the jQuery Validate validation rule has a single value.</summary>
|
||||
/// <param name="adapterName" type="String">The name of the adapter to be added. This matches the name used
|
||||
/// in the data-val-nnnn HTML attribute(where nnnn is the adapter name).</param>
|
||||
/// <param name="attribute" type="String">[Optional] The name of the HTML attribute that contains the value.
|
||||
/// The default is "val".</param>
|
||||
/// <param name="ruleName" type="String" optional="true">[Optional] The name of the jQuery Validate rule. If not provided, the value
|
||||
/// of adapterName will be used instead.</param>
|
||||
/// <returns type="jQuery.validator.unobtrusive.adapters" />
|
||||
return this.add(adapterName, [attribute || "val"], function (options) {
|
||||
setValidationValues(options, ruleName || adapterName, options.params[attribute]);
|
||||
});
|
||||
};
|
||||
|
||||
$jQval.addMethod("__dummy__", function (value, element, params) {
|
||||
return true;
|
||||
});
|
||||
|
||||
$jQval.addMethod("regex", function (value, element, params) {
|
||||
var match;
|
||||
if (this.optional(element)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
match = new RegExp(params).exec(value);
|
||||
return (match && (match.index === 0) && (match[0].length === value.length));
|
||||
});
|
||||
|
||||
$jQval.addMethod("nonalphamin", function (value, element, nonalphamin) {
|
||||
var match;
|
||||
if (nonalphamin) {
|
||||
match = value.match(/\W/g);
|
||||
match = match && match.length >= nonalphamin;
|
||||
}
|
||||
return match;
|
||||
});
|
||||
|
||||
if ($jQval.methods.extension) {
|
||||
adapters.addSingleVal("accept", "mimtype");
|
||||
adapters.addSingleVal("extension", "extension");
|
||||
} else {
|
||||
// for backward compatibility, when the 'extension' validation method does not exist, such as with versions
|
||||
// of JQuery Validation plugin prior to 1.10, we should use the 'accept' method for
|
||||
// validating the extension, and ignore mime-type validations as they are not supported.
|
||||
adapters.addSingleVal("extension", "extension", "accept");
|
||||
}
|
||||
|
||||
adapters.addSingleVal("regex", "pattern");
|
||||
adapters.addBool("creditcard").addBool("date").addBool("digits").addBool("email").addBool("number").addBool("url");
|
||||
adapters.addMinMax("length", "minlength", "maxlength", "rangelength").addMinMax("range", "min", "max", "range");
|
||||
adapters.addMinMax("minlength", "minlength").addMinMax("maxlength", "minlength", "maxlength");
|
||||
adapters.add("equalto", ["other"], function (options) {
|
||||
var prefix = getModelPrefix(options.element.name),
|
||||
other = options.params.other,
|
||||
fullOtherName = appendModelPrefix(other, prefix),
|
||||
element = $(options.form).find(":input").filter("[name='" + escapeAttributeValue(fullOtherName) + "']")[0];
|
||||
|
||||
setValidationValues(options, "equalTo", element);
|
||||
});
|
||||
adapters.add("required", function (options) {
|
||||
// jQuery Validate equates "required" with "mandatory" for checkbox elements
|
||||
if (options.element.tagName.toUpperCase() !== "INPUT" || options.element.type.toUpperCase() !== "CHECKBOX") {
|
||||
setValidationValues(options, "required", true);
|
||||
}
|
||||
});
|
||||
adapters.add("remote", ["url", "type", "additionalfields"], function (options) {
|
||||
var value = {
|
||||
url: options.params.url,
|
||||
type: options.params.type || "GET",
|
||||
data: {}
|
||||
},
|
||||
prefix = getModelPrefix(options.element.name);
|
||||
|
||||
$.each(splitAndTrim(options.params.additionalfields || options.element.name), function (i, fieldName) {
|
||||
var paramName = appendModelPrefix(fieldName, prefix);
|
||||
value.data[paramName] = function () {
|
||||
var field = $(options.form).find(":input").filter("[name='" + escapeAttributeValue(paramName) + "']");
|
||||
// For checkboxes and radio buttons, only pick up values from checked fields.
|
||||
if (field.is(":checkbox")) {
|
||||
return field.filter(":checked").val() || field.filter(":hidden").val() || '';
|
||||
}
|
||||
else if (field.is(":radio")) {
|
||||
return field.filter(":checked").val() || '';
|
||||
}
|
||||
return field.val();
|
||||
};
|
||||
});
|
||||
|
||||
setValidationValues(options, "remote", value);
|
||||
});
|
||||
adapters.add("password", ["min", "nonalphamin", "regex"], function (options) {
|
||||
if (options.params.min) {
|
||||
setValidationValues(options, "minlength", options.params.min);
|
||||
}
|
||||
if (options.params.nonalphamin) {
|
||||
setValidationValues(options, "nonalphamin", options.params.nonalphamin);
|
||||
}
|
||||
if (options.params.regex) {
|
||||
setValidationValues(options, "regex", options.params.regex);
|
||||
}
|
||||
});
|
||||
|
||||
$(function () {
|
||||
$jQval.unobtrusive.parse(document);
|
||||
});
|
||||
}(jQuery));
|
@ -0,0 +1,29 @@
|
||||
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %>
|
||||
<%= Html.ValidationSummary() %>
|
||||
<% using(Html.BeginForm("AddUserToRole", "Admin"))
|
||||
{ %>
|
||||
<fieldset>
|
||||
<div id="roleaddedresult"></div>
|
||||
<% if (ViewData ["UserName"] != null) { %>
|
||||
<%= Html.Hidden("RoleName",ViewData ["RoleName"]) %>
|
||||
<% } else { %>
|
||||
<div>
|
||||
<label for="UserName" >Utilisateur : </label><input type="text" name="UserName" id="UserName">
|
||||
<%= Html.ValidationMessage("UserName", "*") %>
|
||||
</div>
|
||||
<% } %>
|
||||
|
||||
<% if (ViewData ["RoleName"] != null) { %>
|
||||
<%= Html.Hidden("RoleName",ViewData ["RoleName"]) %>
|
||||
<% } else { %>
|
||||
<div>
|
||||
<label for="RoleName" >Nom du rôle : </label>
|
||||
<input type="text" name="RoleName" id="RoleName">
|
||||
<%= Html.ValidationMessage("RoleName", "*") %>
|
||||
</div>
|
||||
<% } %>
|
||||
|
||||
<%= Html.Hidden("ReturnUrl", Request.Url.PathAndQuery ) %>
|
||||
<input type="submit">
|
||||
</fieldset>
|
||||
<% } %>
|
@ -0,0 +1,6 @@
|
||||
<%@ Control Language="C#" Inherits="Yavsc.RateControl<IRating>" %>
|
||||
<div data-id="<%=Model.Id%>" data-type="rate-bill" ><% int i = 0; for (; i<NbFilled; i++) {
|
||||
%><i class="fa fa-star" ></i><% }
|
||||
%><% if (HasHalf) { %><i class="fa fa-star-half-o"></i><% i++; }
|
||||
%><% for (int j=0; j<NbEmpty; j++, i++ ) { %><i class="fa fa-star-o"></i><% }
|
||||
%></div>
|
@ -0,0 +1,6 @@
|
||||
<%@ Control Language="C#" Inherits="Yavsc.RateControl<IRating>" %>
|
||||
<div data-id="<%=Model.Id%>" data-type="rate-bill" ><% int i = 0; for (; i<NbFilled; i++) {
|
||||
%><i class="fa fa-star" ></i><% }
|
||||
%><% if (HasHalf) { %><i class="fa fa-star-half-o"></i><% i++; }
|
||||
%><% for (int j=0; j<NbEmpty; j++, i++ ) { %><i class="fa fa-star-o"></i><% }
|
||||
%></div>
|
@ -0,0 +1,7 @@
|
||||
<%@ Control Language="C#" Inherits="Yavsc.RateControl<IRating>" %>
|
||||
<% Rate = Model.Rate; %>
|
||||
<div data-id="<%=Model.Id%>" data-type="rate-skill" ><% int i = 0; for (; i<NbFilled; i++) {
|
||||
%><i class="fa fa-star" ></i><% }
|
||||
%><% if (HasHalf) { %><i class="fa fa-star-half-o"></i><% i++; }
|
||||
%><% for (int j=0; j<NbEmpty; j++, i++ ) { %><i class="fa fa-star-o"></i><% }
|
||||
%></div>
|
@ -0,0 +1,7 @@
|
||||
<%@ Control Language="C#" Inherits="Yavsc.RateControl<IRating>" %>
|
||||
<% Rate = Model.Rate; %>
|
||||
<div data-id="<%=Model.Id%>" data-type="rate-user-skill" ><% int i = 0; for (; i<NbFilled; i++) {
|
||||
%><i class="fa fa-star" ></i><% }
|
||||
%><% if (HasHalf) { %><i class="fa fa-star-half-o"></i><% i++; }
|
||||
%><% for (int j=0; j<NbEmpty; j++, i++ ) { %><i class="fa fa-star-o"></i><% }
|
||||
%></div>
|
@ -0,0 +1,38 @@
|
||||
<%@ Page Title="Skills" Language="C#" MasterPageFile="~/Models/App.master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<Skill>>" %>
|
||||
|
||||
<asp:Content ID="headContent" ContentPlaceHolderID="head" runat="server">
|
||||
<script src="<%=Url.Content("~/Scripts/yavsc.skills.js")%>"></script>
|
||||
</asp:Content>
|
||||
|
||||
<asp:Content ID="MainContentContent" ContentPlaceHolderID="MainContent" runat="server">
|
||||
|
||||
|
||||
<aside class="control">
|
||||
<form method="post" action="DeclareSkill">
|
||||
<fieldset>
|
||||
<div id="Err_skillName" class="field-validation-error"></div>
|
||||
<input type="text" name="SkillName" id="SkillName" >
|
||||
<input type="button" value="Créer la compétence" id="btncreate" >
|
||||
</fieldset>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function () {
|
||||
$('#btncreate').click( function() {
|
||||
Skills.createSkill(sname, function(sid) {
|
||||
var sname = $('#SkillName').val();
|
||||
console.log(' Skill created id : '+sid);
|
||||
$('<li>'+sname+'</li>').data('sid',sid).addClass('skillname').appendTo('#skills');
|
||||
$('#SkillName').val('');
|
||||
}); } ); });
|
||||
</script>
|
||||
</aside>
|
||||
|
||||
<ul id="skills">
|
||||
<% foreach (var skill in Model) { %>
|
||||
<li class="skillname" data-sid="<%= skill.Id %>">
|
||||
<%= skill.Name %> <%=Html.Partial("RateSkillControl", skill) %>
|
||||
</li>
|
||||
<% } %>
|
||||
</ul>
|
||||
|
||||
</asp:Content>
|
@ -0,0 +1,2 @@
|
||||
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %>
|
||||
|
@ -0,0 +1,51 @@
|
||||
<%@ Page Title="Skills" Language="C#" MasterPageFile="~/Models/App.master" Inherits="System.Web.Mvc.ViewPage<PerformerProfile>" %>
|
||||
|
||||
<asp:Content ID="headContent" ContentPlaceHolderID="head" runat="server">
|
||||
<script src="<%=Url.Content("~/Scripts/yavsc.skills.js")%>"></script>
|
||||
</asp:Content>
|
||||
|
||||
<asp:Content ID="MainContentContent" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<aside class="control">
|
||||
<form method="post" action="DeclareUserSkill">
|
||||
<fieldset>
|
||||
<legend>Declarer une compétence supplémentaire</legend>
|
||||
<div id="Err_skillId" class="field-validation-error"></div>
|
||||
<h2>
|
||||
<select id="SkillId" >
|
||||
<% foreach (var skill in (Skill[]) ViewData["SiteSkills"]) {
|
||||
if (Model.HasSkill(skill.Id)) {%>
|
||||
<option value="<%=skill.Id%>" disabled>
|
||||
<%=skill.Name%></option>
|
||||
<% } else { %>
|
||||
<option value="<%=skill.Id%>"><%=skill.Name%></option>
|
||||
<% } } %>
|
||||
</select></h2>
|
||||
<label for="Comment">Si vous le désirez, faites un commentaire sur cette compétence</label>
|
||||
<textarea id="Comment"></textarea>
|
||||
<input type="button" value="Ajouter la compétence à votre profile" id="btndeclare" >
|
||||
</fieldset>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function () {
|
||||
$('#btndeclare').click( function() {
|
||||
var sid = $('#SkillId').val();
|
||||
var cmnt = $('#Comment').val();
|
||||
var sname = $('#SkillId').text();
|
||||
Skills.declareUserSkill({ username: <%=YavscAjaxHelper.QuoteJavascriptString(Model.UserName) %> ,
|
||||
skillid: sid, rate: 50, comment: cmnt }, function(usid) {
|
||||
console.log('User skill created, id : '+usid);
|
||||
$('<li>'+sname+'</li>').data('sid',sid).data('id',usid).addClass('skillname').appendTo('#userskills');
|
||||
$('#SkillId').val(0);
|
||||
}); }); });
|
||||
</script>
|
||||
</aside>
|
||||
|
||||
<ul id="userskills">
|
||||
<% foreach (var userskill in Model.Skills) { %>
|
||||
<li class="skillname" data-sid="<%= userskill.Id %>">
|
||||
<h2><%= userskill.SkillName %></h2><br> <div data-type="comment"><%= userskill.Comment %></div> <%=Html.Partial("RateUserSkillControl", userskill) %>
|
||||
</li>
|
||||
<% } %>
|
||||
</ul>
|
||||
|
||||
</asp:Content>
|
@ -0,0 +1,37 @@
|
||||
<%@ Page Title="Contact" Language="C#" MasterPageFile="~/Models/App.master" Inherits="System.Web.Mvc.ViewPage" %>
|
||||
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
<div class="panel">
|
||||
<p>
|
||||
Directeur : <br>
|
||||
Adresse postale : <br>
|
||||
Tél. : +33 <br>
|
||||
Tél. : +33 <br>
|
||||
SIREN : <br>
|
||||
SIRET : <br>
|
||||
Activité Principalement Exercée (APE) : <br>
|
||||
</p>
|
||||
<% using (Html.BeginForm("Contact", "Home")) { %>
|
||||
<fieldset>
|
||||
<legend>Message</legend>
|
||||
<p>
|
||||
<%= Html.Label("email") %>:
|
||||
<%= Html.ValidationMessage("email") %><br/>
|
||||
<%= Html.TextBox("email") %>
|
||||
</p>
|
||||
<p>
|
||||
<%= Html.Label("reason") %>:
|
||||
<%= Html.ValidationMessage("reason") %><br/>
|
||||
<%= Html.TextBox("reason") %>
|
||||
</p>
|
||||
<p>
|
||||
<%= Html.Label("body") %>:
|
||||
<%= Html.ValidationMessage("body") %><br/>
|
||||
<%= Html.TextArea("body") %>
|
||||
</p>
|
||||
</fieldset>
|
||||
<input type="submit" value="<%=Html.Translate("Submit")%>">
|
||||
|
||||
<% } %>
|
||||
</div>
|
||||
</asp:Content>
|
@ -0,0 +1,7 @@
|
||||
<%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage<BlogEntryCollection>" MasterPageFile="~/Models/App.master"%>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
Ce contenu est d'accès restreint : <<%= Html.Encode(ViewData["ControllerName"]) %>/<%= Html.Encode(ViewData["ActionName"]) %>>
|
||||
|
||||
Demandez à l'administrateur les autorisations suffisantes pour accèder à cet emplacement.
|
||||
|
||||
</asp:Content>
|
@ -0,0 +1,37 @@
|
||||
//
|
||||
// IAuthorized.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
|
||||
namespace Yavsc.Model
|
||||
{
|
||||
/// <summary>
|
||||
/// I authorized.
|
||||
/// </summary>
|
||||
public interface IAuthorized {
|
||||
/// <summary>
|
||||
/// Gets or sets the author.
|
||||
/// </summary>
|
||||
/// <value>The author.</value>
|
||||
string Author { get; set; }
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,30 @@
|
||||
//
|
||||
// ICommented.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
|
||||
namespace Yavsc.Model
|
||||
{
|
||||
|
||||
public interface IComment: IIdentified {
|
||||
string Comment { get; set; }
|
||||
}
|
||||
}
|
@ -0,0 +1,63 @@
|
||||
//
|
||||
// Manager.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
using System.Configuration;
|
||||
using System.Reflection;
|
||||
using System.Configuration.Provider;
|
||||
|
||||
namespace Yavsc.Model {
|
||||
/// <summary>
|
||||
/// Manager.
|
||||
/// </summary>
|
||||
public static class ManagerHelper {
|
||||
|
||||
/// <summary>
|
||||
/// Gets the provider.
|
||||
/// </summary>
|
||||
/// <value>The provider.</value>
|
||||
public static TProvider GetDefaultProvider<TProvider> (string configSetion) where TProvider: ProviderBase
|
||||
{
|
||||
DataProviderConfigurationSection config = ConfigurationManager.GetSection (configSetion) as DataProviderConfigurationSection;
|
||||
if (config == null)
|
||||
throw new ConfigurationErrorsException (
|
||||
string.Format(
|
||||
"The providers configuration bloc `{0}` was not found",
|
||||
configSetion));
|
||||
ProviderSettings celt =
|
||||
config.Providers [config.DefaultProvider];
|
||||
if (config == null)
|
||||
throw new ConfigurationErrorsException (
|
||||
string.Format (
|
||||
"The default provider `{0}` was not found ",
|
||||
config.DefaultProvider));
|
||||
Type provtype = Type.GetType (celt.Type);
|
||||
if (provtype == null)
|
||||
throw new ProviderException (
|
||||
string.Format (
|
||||
"Provider type '{0}' was not found",celt.Type));
|
||||
ConstructorInfo ci = provtype.GetConstructor (Type.EmptyTypes);
|
||||
ProviderBase bp = ci.Invoke (Type.EmptyTypes) as ProviderBase;
|
||||
bp.Initialize (celt.Name, celt.Parameters);
|
||||
return bp as TProvider;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,39 @@
|
||||
//
|
||||
// UserNameBase.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Yavsc.Model.RolesAndMembers
|
||||
{
|
||||
public class UserNameBase {
|
||||
/// <summary>
|
||||
/// Gets or sets the name of the user.
|
||||
/// </summary>
|
||||
/// <value>The name of the user.</value>
|
||||
[Localizable(true), Required(ErrorMessage = "S'il vous plait, entrez un nom d'utilisateur")
|
||||
,Display(ResourceType=typeof(LocalizedText),Name="User_name"),RegularExpression("([a-z]|[A-Z]|[0-9] )+")]
|
||||
public string UserName { get; set; }
|
||||
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,55 @@
|
||||
//
|
||||
// Skill.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
using System.Configuration;
|
||||
using System.Reflection;
|
||||
using System.Configuration.Provider;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Yavsc.Model.Skill
|
||||
{
|
||||
/// <summary>
|
||||
/// Skill.
|
||||
/// </summary>
|
||||
public class Skill : IRating {
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the identifier.
|
||||
/// </summary>
|
||||
/// <value>The identifier.</value>
|
||||
public long Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the name.
|
||||
/// </summary>
|
||||
/// <value>The name.</value>
|
||||
[Required(ErrorMessage = "Please, specify a skill name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the rate.
|
||||
/// </summary>
|
||||
/// <value>The rate.</value>
|
||||
public int Rate { get; set; }
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,40 @@
|
||||
//
|
||||
// UserSkillComment.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
|
||||
namespace Yavsc.Model.Skill
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// User skill comment.
|
||||
/// </summary>
|
||||
public class UserSkillComment: UserSkillReference, IComment
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the comment.
|
||||
/// </summary>
|
||||
/// <value>The comment.</value>
|
||||
public string Comment { get; set; }
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,36 @@
|
||||
//
|
||||
// UserSkillDeclaration.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
|
||||
namespace Yavsc.Model.Skill
|
||||
{
|
||||
public class UserSkillDeclaration : UserSkill {
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the name of the user.
|
||||
/// </summary>
|
||||
/// <value>The name of the user.</value>
|
||||
public string UserName { get; set; }
|
||||
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
//
|
||||
// SkillRating.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
|
||||
namespace Yavsc.Model.Skill
|
||||
{
|
||||
/// <summary>
|
||||
/// Skill rating.
|
||||
/// </summary>
|
||||
public class UserSkillRating: UserSkillReference, IRating, IAuthorized
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the rate.
|
||||
/// </summary>
|
||||
/// <value>The rate.</value>
|
||||
public int Rate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the author.
|
||||
/// </summary>
|
||||
/// <value>The author.</value>
|
||||
public string Author { get; set; }
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,49 @@
|
||||
//
|
||||
// UserSkillReference.cs
|
||||
//
|
||||
// Author:
|
||||
// Paul Schneider <paul@pschneider.fr>
|
||||
//
|
||||
// Copyright (c) 2015 GNU GPL
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Lesser General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
using System;
|
||||
|
||||
namespace Yavsc.Model.Skill
|
||||
{
|
||||
/// <summary>
|
||||
/// User skill reference.
|
||||
/// </summary>
|
||||
public class UserSkillReference {
|
||||
/// <summary>
|
||||
/// Gets or sets the user's skill identifier.
|
||||
/// </summary>
|
||||
/// <value>The skill identifier.</value>
|
||||
public long Id { get;set ; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the skill identifier.
|
||||
/// </summary>
|
||||
/// <value>The skill identifier.</value>
|
||||
public long SkillId { get;set ; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the name of the performer.
|
||||
/// </summary>
|
||||
/// <value>The name of the user.</value>
|
||||
public string Performer { get; set; }
|
||||
}
|
||||
|
||||
}
|