mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
Merge branch 'master' into new_deployment
This commit is contained in:
commit
94dc5d3962
@ -2,7 +2,7 @@
|
|||||||
"bookmark": "bookmark",
|
"bookmark": "bookmark",
|
||||||
"confirmed": "bestätigt",
|
"confirmed": "bestätigt",
|
||||||
"creation_form": {
|
"creation_form": {
|
||||||
"creation_for": "Schöpfung für ",
|
"creation_for": "Schöpfung für",
|
||||||
"enter_text": "Text eintragen",
|
"enter_text": "Text eintragen",
|
||||||
"form": "Schöpfungsformular",
|
"form": "Schöpfungsformular",
|
||||||
"min_characters": "Mindestens 10 Zeichen eingeben",
|
"min_characters": "Mindestens 10 Zeichen eingeben",
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
"bookmark": "Remember",
|
"bookmark": "Remember",
|
||||||
"confirmed": "confirmed",
|
"confirmed": "confirmed",
|
||||||
"creation_form": {
|
"creation_form": {
|
||||||
"creation_for": "Creation for ",
|
"creation_for": "Creation for",
|
||||||
"enter_text": "Enter text",
|
"enter_text": "Enter text",
|
||||||
"form": "Creation form",
|
"form": "Creation form",
|
||||||
"min_characters": "Enter at least 10 characters",
|
"min_characters": "Enter at least 10 characters",
|
||||||
|
|||||||
@ -8,14 +8,14 @@ const apolloQueryMock = jest.fn().mockResolvedValue({
|
|||||||
data: {
|
data: {
|
||||||
searchUsers: [
|
searchUsers: [
|
||||||
{
|
{
|
||||||
id: 1,
|
userId: 1,
|
||||||
firstName: 'Bibi',
|
firstName: 'Bibi',
|
||||||
lastName: 'Bloxberg',
|
lastName: 'Bloxberg',
|
||||||
email: 'bibi@bloxberg.de',
|
email: 'bibi@bloxberg.de',
|
||||||
creation: [200, 400, 600],
|
creation: [200, 400, 600],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 2,
|
userId: 2,
|
||||||
firstName: 'Benjamin',
|
firstName: 'Benjamin',
|
||||||
lastName: 'Blümchen',
|
lastName: 'Blümchen',
|
||||||
email: 'benjamin@bluemchen.de',
|
email: 'benjamin@bluemchen.de',
|
||||||
@ -71,7 +71,7 @@ describe('Creation', () => {
|
|||||||
it('sets the data of itemsList', () => {
|
it('sets the data of itemsList', () => {
|
||||||
expect(wrapper.vm.itemsList).toEqual([
|
expect(wrapper.vm.itemsList).toEqual([
|
||||||
{
|
{
|
||||||
id: 1,
|
userId: 1,
|
||||||
firstName: 'Bibi',
|
firstName: 'Bibi',
|
||||||
lastName: 'Bloxberg',
|
lastName: 'Bloxberg',
|
||||||
email: 'bibi@bloxberg.de',
|
email: 'bibi@bloxberg.de',
|
||||||
@ -79,7 +79,7 @@ describe('Creation', () => {
|
|||||||
showDetails: false,
|
showDetails: false,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 2,
|
userId: 2,
|
||||||
firstName: 'Benjamin',
|
firstName: 'Benjamin',
|
||||||
lastName: 'Blümchen',
|
lastName: 'Blümchen',
|
||||||
email: 'benjamin@bluemchen.de',
|
email: 'benjamin@bluemchen.de',
|
||||||
@ -100,7 +100,7 @@ describe('Creation', () => {
|
|||||||
wrapper.findComponent({ name: 'UserTable' }).vm.$emit(
|
wrapper.findComponent({ name: 'UserTable' }).vm.$emit(
|
||||||
'update-item',
|
'update-item',
|
||||||
{
|
{
|
||||||
id: 2,
|
userId: 2,
|
||||||
firstName: 'Benjamin',
|
firstName: 'Benjamin',
|
||||||
lastName: 'Blümchen',
|
lastName: 'Blümchen',
|
||||||
email: 'benjamin@bluemchen.de',
|
email: 'benjamin@bluemchen.de',
|
||||||
@ -114,7 +114,7 @@ describe('Creation', () => {
|
|||||||
it('removes the pushed item from itemsList', () => {
|
it('removes the pushed item from itemsList', () => {
|
||||||
expect(wrapper.vm.itemsList).toEqual([
|
expect(wrapper.vm.itemsList).toEqual([
|
||||||
{
|
{
|
||||||
id: 1,
|
userId: 1,
|
||||||
firstName: 'Bibi',
|
firstName: 'Bibi',
|
||||||
lastName: 'Bloxberg',
|
lastName: 'Bloxberg',
|
||||||
email: 'bibi@bloxberg.de',
|
email: 'bibi@bloxberg.de',
|
||||||
@ -127,7 +127,7 @@ describe('Creation', () => {
|
|||||||
it('adds the pushed item to itemsMassCreation', () => {
|
it('adds the pushed item to itemsMassCreation', () => {
|
||||||
expect(wrapper.vm.itemsMassCreation).toEqual([
|
expect(wrapper.vm.itemsMassCreation).toEqual([
|
||||||
{
|
{
|
||||||
id: 2,
|
userId: 2,
|
||||||
firstName: 'Benjamin',
|
firstName: 'Benjamin',
|
||||||
lastName: 'Blümchen',
|
lastName: 'Blümchen',
|
||||||
email: 'benjamin@bluemchen.de',
|
email: 'benjamin@bluemchen.de',
|
||||||
@ -142,7 +142,7 @@ describe('Creation', () => {
|
|||||||
wrapper.findComponent({ name: 'UserTable' }).vm.$emit(
|
wrapper.findComponent({ name: 'UserTable' }).vm.$emit(
|
||||||
'update-item',
|
'update-item',
|
||||||
{
|
{
|
||||||
id: 2,
|
userId: 2,
|
||||||
firstName: 'Benjamin',
|
firstName: 'Benjamin',
|
||||||
lastName: 'Blümchen',
|
lastName: 'Blümchen',
|
||||||
email: 'benjamin@bluemchen.de',
|
email: 'benjamin@bluemchen.de',
|
||||||
@ -160,7 +160,7 @@ describe('Creation', () => {
|
|||||||
it('adds the item to itemsList', () => {
|
it('adds the item to itemsList', () => {
|
||||||
expect(wrapper.vm.itemsList).toEqual([
|
expect(wrapper.vm.itemsList).toEqual([
|
||||||
{
|
{
|
||||||
id: 1,
|
userId: 1,
|
||||||
firstName: 'Bibi',
|
firstName: 'Bibi',
|
||||||
lastName: 'Bloxberg',
|
lastName: 'Bloxberg',
|
||||||
email: 'bibi@bloxberg.de',
|
email: 'bibi@bloxberg.de',
|
||||||
@ -168,7 +168,7 @@ describe('Creation', () => {
|
|||||||
showDetails: false,
|
showDetails: false,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 2,
|
userId: 2,
|
||||||
firstName: 'Benjamin',
|
firstName: 'Benjamin',
|
||||||
lastName: 'Blümchen',
|
lastName: 'Blümchen',
|
||||||
email: 'benjamin@bluemchen.de',
|
email: 'benjamin@bluemchen.de',
|
||||||
@ -206,7 +206,7 @@ describe('Creation', () => {
|
|||||||
await wrapper.findComponent({ name: 'UserTable' }).vm.$emit(
|
await wrapper.findComponent({ name: 'UserTable' }).vm.$emit(
|
||||||
'update-item',
|
'update-item',
|
||||||
{
|
{
|
||||||
id: 2,
|
userId: 2,
|
||||||
firstName: 'Benjamin',
|
firstName: 'Benjamin',
|
||||||
lastName: 'Blümchen',
|
lastName: 'Blümchen',
|
||||||
email: 'benjamin@bluemchen.de',
|
email: 'benjamin@bluemchen.de',
|
||||||
|
|||||||
@ -133,16 +133,16 @@ export default {
|
|||||||
|
|
||||||
switch (event) {
|
switch (event) {
|
||||||
case 'push':
|
case 'push':
|
||||||
findArr = this.itemsList.find((arr) => arr.id === e.id)
|
findArr = this.itemsList.find((item) => e.userId === item.userId)
|
||||||
index = this.itemsList.indexOf(findArr)
|
index = this.itemsList.indexOf(findArr)
|
||||||
this.itemsList.splice(index, 1)
|
this.itemsList.splice(index, 1)
|
||||||
this.itemsMassCreation.push(e)
|
this.itemsMassCreation.push(findArr)
|
||||||
break
|
break
|
||||||
case 'remove':
|
case 'remove':
|
||||||
findArr = this.itemsMassCreation.find((arr) => arr.id === e.id)
|
findArr = this.itemsMassCreation.find((item) => e.userId === item.userId)
|
||||||
index = this.itemsMassCreation.indexOf(findArr)
|
index = this.itemsMassCreation.indexOf(findArr)
|
||||||
this.itemsMassCreation.splice(index, 1)
|
this.itemsMassCreation.splice(index, 1)
|
||||||
this.itemsList.push(e)
|
this.itemsList.push(findArr)
|
||||||
break
|
break
|
||||||
default:
|
default:
|
||||||
throw new Error(event)
|
throw new Error(event)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user