@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.
package/dist/index.cjs CHANGED
@@ -10044,6 +10044,12 @@ var MINI_QUIZ_QUESTION_FIELDS_FRAGMENT = gql`
10044
10044
  }
10045
10045
  ${MINI_QUIZ_ANSWER_FIELDS_FRAGMENT}
10046
10046
  `;
10047
+ var MINI_QUIZ_ANSWERED_QUESTION_FIELDS_FRAGMENT = gql`
10048
+ fragment MiniQuizAnsweredQuestionFields on MiniQuizAnsweredQuestionType {
10049
+ questionId
10050
+ selectedAnswerId
10051
+ }
10052
+ `;
10047
10053
  var MINI_QUIZ_BASE_GAME_FIELDS_FRAGMENT = gql`
10048
10054
  fragment MiniQuizBaseGameFields on MiniQuizBaseGameType {
10049
10055
  questions {
@@ -10057,14 +10063,14 @@ var MINI_QUIZ_GAME_DATA_FIELDS_FRAGMENT = gql`
10057
10063
  gameFields {
10058
10064
  ...MiniQuizBaseGameFields
10059
10065
  }
10060
- quizInfo {
10061
- ...MiniQuizQuestionFields
10066
+ answeredQuestions {
10067
+ ...MiniQuizAnsweredQuestionFields
10062
10068
  }
10063
10069
  points
10064
10070
  streak
10065
10071
  }
10066
10072
  ${MINI_QUIZ_BASE_GAME_FIELDS_FRAGMENT}
10067
- ${MINI_QUIZ_QUESTION_FIELDS_FRAGMENT}
10073
+ ${MINI_QUIZ_ANSWERED_QUESTION_FIELDS_FRAGMENT}
10068
10074
  `;
10069
10075
  var GAME_HISTORY_FIELDS_FRAGMENT = gql`
10070
10076
  fragment GameHistoryFields on GameHistoryType {
@@ -10102,6 +10108,7 @@ var GAME_FIELDS_FRAGMENT = gql`
10102
10108
  ...GameHistoryFields
10103
10109
  }
10104
10110
  gameType
10111
+ gameTypeId
10105
10112
  updatedAt
10106
10113
  }
10107
10114
  ${GAME_DATA_FIELDS_FRAGMENT}
@@ -10158,6 +10165,7 @@ var GET_GAME_LEADERBOARD = gql`
10158
10165
  `;
10159
10166
  var BASE_GAME_FIELDS_FRAGMENT = gql`
10160
10167
  fragment BaseGameFields on BaseGameType {
10168
+ gameTypeId
10161
10169
  gameType
10162
10170
  dailyClue {
10163
10171
  ...DailyClueBaseGameFields
@@ -10337,9 +10345,9 @@ var UPDATE_DAILY_CLUE_MUTATION = gql`
10337
10345
  var UPDATE_MINI_QUIZ_MUTATION = gql`
10338
10346
  mutation updateMiniQuizGame(
10339
10347
  $_id: ID!
10340
- $questions: [MiniQuizQuestionInputType!]!
10348
+ $answeredQuestions: [MiniQuizAnsweredQuestionInputType!]!
10341
10349
  ) {
10342
- updateMiniQuizGame(_id: $_id, questions: $questions) {
10350
+ updateMiniQuizGame(_id: $_id, answeredQuestions: $answeredQuestions) {
10343
10351
  ...GameDocFields
10344
10352
  }
10345
10353
  }
@@ -12493,15 +12501,22 @@ var schemaMiniQuizBaseGame = new MongooseSchema21(
12493
12501
  },
12494
12502
  { _id: false }
12495
12503
  );
12504
+ var schemaMiniQuizAnsweredQuestion = new MongooseSchema21(
12505
+ {
12506
+ questionId: { required: true, type: String },
12507
+ selectedAnswerId: { required: true, type: String }
12508
+ },
12509
+ { _id: false }
12510
+ );
12496
12511
  var schemaMiniQuizGameData = new MongooseSchema21(
12497
12512
  {
12498
- gameFields: { required: true, type: schemaMiniQuizBaseGame },
12499
- points: { default: 0, required: true, type: Number },
12500
- quizInfo: {
12513
+ answeredQuestions: {
12501
12514
  default: null,
12502
12515
  required: false,
12503
- type: [schemaMiniQuizQuestion]
12516
+ type: [schemaMiniQuizAnsweredQuestion]
12504
12517
  },
12518
+ gameFields: { required: true, type: schemaMiniQuizBaseGame },
12519
+ points: { default: 0, required: true, type: Number },
12505
12520
  streak: { default: 0, required: true, type: Number }
12506
12521
  },
12507
12522
  { _id: false }
@@ -12546,7 +12561,8 @@ var gameTypeSchema = new MongooseSchema22(
12546
12561
  enum: Object.values(EnumGameType),
12547
12562
  required: true,
12548
12563
  type: String
12549
- }
12564
+ },
12565
+ gameTypeId: { required: true, type: String }
12550
12566
  },
12551
12567
  { timestamps: true }
12552
12568
  );