Fix agenda create event component

This commit is contained in:
Peter Maquiran
2021-07-14 14:29:03 +01:00
parent 5614fc38fd
commit 8c859834aa
4 changed files with 47 additions and 50 deletions
+1
View File
@@ -11,6 +11,7 @@
"e2e": "ng e2e",
"nice": "node server.js",
"test": "jest --detectOpenHandles --runInBand",
"test:prof": "ionic build --prod && npm run test",
"dev": "lite-server --baseDir=www"
},
"private": true,
@@ -99,7 +99,6 @@ export class NewEventPage implements OnInit {
Form: FormGroup;
validateFrom = false
public options = [
{ value: true, label: 'True' },
{ value: false, label: 'False' }
@@ -110,14 +109,10 @@ export class NewEventPage implements OnInit {
public stepMinutes = [1, 5, 10, 15, 20, 25];
public stepSeconds = [1, 5, 10, 15, 20, 25];
public dateControlStart = new FormControl(moment("DD MM YYYY hh"));
public dateControlEnd = new FormControl(moment("DD MM YYYY hh"));
public dateControlOccurrence = new FormControl(moment("DD MM YYYY hh"));
showLoader = false
get dateOccurrence () {
return this.dateControlOccurrence.value
}
@@ -133,6 +128,7 @@ export class NewEventPage implements OnInit {
) {
this.dateAdapter.setLocale('pt');
this.loggeduser = userService.ValidatedUser;
this.postEvent = new Event();
this.postEvent.StartDate = new Date();
this.postEvent.EndDate = new Date(new Date().getTime() + 15 * 60000);
@@ -144,7 +140,7 @@ export class NewEventPage implements OnInit {
if(!this.restoreTemporaryData()){
// clear
this.postEvent = new Event();
this.eventBody = { BodyType : "1", Text : ""};
this.postEvent.Body = this.eventBody;
+1 -1
View File
@@ -8,7 +8,7 @@ describe('Puppeteer tests', () => {
// await page.goto(process.env.PUPPETEER_HOST)
})
test('[table] create event', async () => {
test('[table] Open create event component', async () => {
await page.setViewport({width: 1200, height: 720});
await page.goto(process.env.PUPPETEER_HOST); // wait until page load