@timardex/cluemart-server-shared 1.0.156 → 1.0.158

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10034,6 +10034,12 @@ var MINI_QUIZ_QUESTION_FIELDS_FRAGMENT = gql`
10034
10034
  }
10035
10035
  ${MINI_QUIZ_ANSWER_FIELDS_FRAGMENT}
10036
10036
  `;
10037
+ var MINI_QUIZ_ANSWERED_QUESTION_FIELDS_FRAGMENT = gql`
10038
+ fragment MiniQuizAnsweredQuestionFields on MiniQuizAnsweredQuestionType {
10039
+ questionId
10040
+ selectedAnswerId
10041
+ }
10042
+ `;
10037
10043
  var MINI_QUIZ_BASE_GAME_FIELDS_FRAGMENT = gql`
10038
10044
  fragment MiniQuizBaseGameFields on MiniQuizBaseGameType {
10039
10045
  questions {
@@ -10047,14 +10053,14 @@ var MINI_QUIZ_GAME_DATA_FIELDS_FRAGMENT = gql`
10047
10053
  gameFields {
10048
10054
  ...MiniQuizBaseGameFields
10049
10055
  }
10050
- quizInfo {
10051
- ...MiniQuizQuestionFields
10056
+ answeredQuestions {
10057
+ ...MiniQuizAnsweredQuestionFields
10052
10058
  }
10053
10059
  points
10054
10060
  streak
10055
10061
  }
10056
10062
  ${MINI_QUIZ_BASE_GAME_FIELDS_FRAGMENT}
10057
- ${MINI_QUIZ_QUESTION_FIELDS_FRAGMENT}
10063
+ ${MINI_QUIZ_ANSWERED_QUESTION_FIELDS_FRAGMENT}
10058
10064
  `;
10059
10065
  var GAME_HISTORY_FIELDS_FRAGMENT = gql`
10060
10066
  fragment GameHistoryFields on GameHistoryType {
@@ -10092,6 +10098,7 @@ var GAME_FIELDS_FRAGMENT = gql`
10092
10098
  ...GameHistoryFields
10093
10099
  }
10094
10100
  gameType
10101
+ gameTypeId
10095
10102
  updatedAt
10096
10103
  }
10097
10104
  ${GAME_DATA_FIELDS_FRAGMENT}
@@ -10148,6 +10155,7 @@ var GET_GAME_LEADERBOARD = gql`
10148
10155
  `;
10149
10156
  var BASE_GAME_FIELDS_FRAGMENT = gql`
10150
10157
  fragment BaseGameFields on BaseGameType {
10158
+ gameTypeId
10151
10159
  gameType
10152
10160
  dailyClue {
10153
10161
  ...DailyClueBaseGameFields
@@ -10327,9 +10335,9 @@ var UPDATE_DAILY_CLUE_MUTATION = gql`
10327
10335
  var UPDATE_MINI_QUIZ_MUTATION = gql`
10328
10336
  mutation updateMiniQuizGame(
10329
10337
  $_id: ID!
10330
- $questions: [MiniQuizQuestionInputType!]!
10338
+ $answeredQuestions: [MiniQuizAnsweredQuestionInputType!]!
10331
10339
  ) {
10332
- updateMiniQuizGame(_id: $_id, questions: $questions) {
10340
+ updateMiniQuizGame(_id: $_id, answeredQuestions: $answeredQuestions) {
10333
10341
  ...GameDocFields
10334
10342
  }
10335
10343
  }
@@ -12483,15 +12491,22 @@ var schemaMiniQuizBaseGame = new MongooseSchema21(
12483
12491
  },
12484
12492
  { _id: false }
12485
12493
  );
12494
+ var schemaMiniQuizAnsweredQuestion = new MongooseSchema21(
12495
+ {
12496
+ questionId: { required: true, type: String },
12497
+ selectedAnswerId: { required: true, type: String }
12498
+ },
12499
+ { _id: false }
12500
+ );
12486
12501
  var schemaMiniQuizGameData = new MongooseSchema21(
12487
12502
  {
12488
- gameFields: { required: true, type: schemaMiniQuizBaseGame },
12489
- points: { default: 0, required: true, type: Number },
12490
- quizInfo: {
12503
+ answeredQuestions: {
12491
12504
  default: null,
12492
12505
  required: false,
12493
- type: [schemaMiniQuizQuestion]
12506
+ type: [schemaMiniQuizAnsweredQuestion]
12494
12507
  },
12508
+ gameFields: { required: true, type: schemaMiniQuizBaseGame },
12509
+ points: { default: 0, required: true, type: Number },
12495
12510
  streak: { default: 0, required: true, type: Number }
12496
12511
  },
12497
12512
  { _id: false }
@@ -12536,7 +12551,8 @@ var gameTypeSchema = new MongooseSchema22(
12536
12551
  enum: Object.values(EnumGameType),
12537
12552
  required: true,
12538
12553
  type: String
12539
- }
12554
+ },
12555
+ gameTypeId: { required: true, type: String }
12540
12556
  },
12541
12557
  { timestamps: true }
12542
12558
  );