Browse Source

Univate.2 > Additions to buy Timeshare

master
George Williams 4 years ago
parent
commit
eaeefe0dd3

+ 1
- 0
src/components/timeshare/buy/searchResults.vue View File

44
     </div>
44
     </div>
45
     <div v-else class="row">
45
     <div v-else class="row">
46
       <div align="center" class="col-md-12">
46
       <div align="center" class="col-md-12">
47
+        <br />
47
         <img src="img/no-homes.png" />
48
         <img src="img/no-homes.png" />
48
         <br />
49
         <br />
49
         <br />
50
         <br />

+ 1
- 55
src/components/timeshare/buy/searchSection.vue View File

42
               <option disabled>Please Select a Region First</option>
42
               <option disabled>Please Select a Region First</option>
43
             </select>
43
             </select>
44
           </div>
44
           </div>
45
-          <!-- <div class="input-group my-1">
46
-            <label v-if="selectedSeason === null" class="uniSelectLabel" for="season">Season</label>
47
-            <select
48
-              class="form-control uniSelect"
49
-              name="season"
50
-              id="season"
51
-              v-model="selectedSeason"
52
-            >
53
-              <option v-for="season in seasons" :key="season.id" :value="season">{{ season.name }}</option>
54
-            </select>
55
-          </div>
56
-
57
-          <input
58
-            type="number"
59
-            name="bedrooms"
60
-            class="form-control my-1"
61
-            id="bedrooms"
62
-            placeholder="Bedrooms"
63
-            v-model="bedrooms"
64
-            @input="checkValueBedrooms()"
65
-          />
66
-
67
-          <input
68
-            type="number"
69
-            name="max-price"
70
-            class="form-control my-1"
71
-            id="max-price"
72
-            placeholder="Maximum Price"
73
-            v-model="maxPrice"
74
-            @input="checkValuePrice()"
75
-          />
76
-
77
-          <p>
78
-            Filter Arrival Date from
79
-            <input
80
-              type="date"
81
-              name="arrival-from"
82
-              class="form-control my-1"
83
-              id="arrival-from"
84
-              placeholder="mm/dd/yy"
85
-              v-model="dateFrom"
86
-            />
87
-          </p>
88
-          <p>
89
-            Filter Arrival Date to
90
-            <input
91
-              type="date"
92
-              name="arrival-to"
93
-              class="form-control my-1"
94
-              id="arrival-to"
95
-              placeholder="mm/dd/yy"
96
-              v-model="dateTo"
97
-            />
98
-          </p>-->
99
           <button class="btn-white-border" @click="ShowResort()">
45
           <button class="btn-white-border" @click="ShowResort()">
100
             <i class="fa fa-search"></i> SEARCH
46
             <i class="fa fa-search"></i> SEARCH
101
           </button>
47
           </button>
112
               <iframe
58
               <iframe
113
                 :src="mapUrl"
59
                 :src="mapUrl"
114
                 width="100%"
60
                 width="100%"
115
-                height="600"
61
+                height="400"
116
                 frameborder="0"
62
                 frameborder="0"
117
                 style="border-radius:10px"
63
                 style="border-radius:10px"
118
                 allowfullscreen
64
                 allowfullscreen

+ 17
- 6
src/components/timeshare/buy/weekListComponent.vue View File

4
       <table class="table table-striped table-responsive">
4
       <table class="table table-striped table-responsive">
5
         <thead>
5
         <thead>
6
           <tr>
6
           <tr>
7
-            <th scope="col">Reference</th>
7
+            <th scope="col">Ref</th>
8
             <th scope="col">Unit</th>
8
             <th scope="col">Unit</th>
9
             <th scope="col">Module</th>
9
             <th scope="col">Module</th>
10
+            <th scope="col">Arrival</th>
11
+            <th scope="col">Departure</th>
10
             <th scope="col">Bedrooms</th>
12
             <th scope="col">Bedrooms</th>
11
             <th scope="col">Season</th>
13
             <th scope="col">Season</th>
14
+            <th scope="col">Type</th>
12
             <th scope="col">Price Incl VAT</th>
15
             <th scope="col">Price Incl VAT</th>
16
+            <th scope="col">Status</th>
13
             <th scope="col">Interested?</th>
17
             <th scope="col">Interested?</th>
14
           </tr>
18
           </tr>
15
         </thead>
19
         </thead>
18
             <td>#{{ item.id }}</td>
22
             <td>#{{ item.id }}</td>
19
             <td>{{ item.unitNumber }}</td>
23
             <td>{{ item.unitNumber }}</td>
20
             <td>{{ item.weekNumber }}</td>
24
             <td>{{ item.weekNumber }}</td>
25
+            <td v-if="item.arrivalDate === '0001-01-01T00:00:00'"></td>
26
+            <td v-else>{{ item.arrivalDate | toDate }}</td>
27
+            <td v-if="item.departureDate === '0001-01-01T00:00:00'"></td>
28
+            <td v-else>{{ item.departureDate | toDate }}</td>
21
             <td>{{ item.bedrooms }}</td>
29
             <td>{{ item.bedrooms }}</td>
22
             <td>{{ item.season }}</td>
30
             <td>{{ item.season }}</td>
31
+            <td>{{ item.weekType }}</td>
23
             <td>{{ item.sellPrice | toCurrency }}</td>
32
             <td>{{ item.sellPrice | toCurrency }}</td>
33
+            <td v-if="item.status">{{ item.status.display }}</td>
34
+            <td v-else></td>
24
             <!-- <td>{{ item.region ? item.region.regionName : "" }}</td>
35
             <!-- <td>{{ item.region ? item.region.regionName : "" }}</td>
25
             <td>{{ item.resort ? item.resort.resortName : "" }}</td>
36
             <td>{{ item.resort ? item.resort.resortName : "" }}</td>
26
 
37
 
68
 export default {
79
 export default {
69
   props: {
80
   props: {
70
     resortCode: undefined,
81
     resortCode: undefined,
71
-    userId: undefined
82
+    userId: undefined,
72
   },
83
   },
73
   components: {},
84
   components: {},
74
   computed: {
85
   computed: {
75
     ...mapState("weekList", ["weeks", "status"]),
86
     ...mapState("weekList", ["weeks", "status"]),
76
     ...mapGetters({
87
     ...mapGetters({
77
       filteredWeeks: "weekList/filteredWeeks",
88
       filteredWeeks: "weekList/filteredWeeks",
78
-      getRegions: "weekList/getRegions"
79
-    })
89
+      getRegions: "weekList/getRegions",
90
+    }),
80
   },
91
   },
81
   mounted() {
92
   mounted() {
82
     if (this.resortCode) {
93
     if (this.resortCode) {
88
     View(item) {
99
     View(item) {
89
       this.$router.push(`/resort/${item.resort.resortCode}/${item.unitNumber}`);
100
       this.$router.push(`/resort/${item.resort.resortCode}/${item.unitNumber}`);
90
     },
101
     },
91
-    ...mapActions("weekList", ["getWeeks", "applyResortFilter"])
92
-  }
102
+    ...mapActions("weekList", ["getWeeks", "applyResortFilter"]),
103
+  },
93
 };
104
 };
94
 </script>
105
 </script>
95
 
106
 

+ 2
- 2
src/components/timeshare/resort/contentSection.vue View File

2
   <section>
2
   <section>
3
     <div class="container">
3
     <div class="container">
4
       <div class="row" id="resort-profile">
4
       <div class="row" id="resort-profile">
5
-        <div class="col-md-4">
5
+        <div class="col-md-3">
6
           <img src="img/listings/property1/property1-gallery.jpg" class="img-fluid" alt />
6
           <img src="img/listings/property1/property1-gallery.jpg" class="img-fluid" alt />
7
           <div class="row no-gutters">
7
           <div class="row no-gutters">
8
             <div class="col-6">
8
             <div class="col-6">
15
           <gallerySection :images="images" />
15
           <gallerySection :images="images" />
16
           <FilterComponent :hideTop="true" />
16
           <FilterComponent :hideTop="true" />
17
         </div>
17
         </div>
18
-        <div class="col-md-8 p-5 resort-profile">
18
+        <div class="col-md-9 p-5 resort-profile">
19
           <h2>{{ resort.prName }}</h2>
19
           <h2>{{ resort.prName }}</h2>
20
           <WeekList :resortCode="resortCode" />
20
           <WeekList :resortCode="resortCode" />
21
           <p>{{ resort.prNotes }}</p>
21
           <p>{{ resort.prNotes }}</p>

+ 104
- 74
src/components/timeshare/sell/contentSection.vue View File

18
                   :checked="refAgent"
18
                   :checked="refAgent"
19
                   @change="changeRef"
19
                   @change="changeRef"
20
                 />
20
                 />
21
-                <label class="custom-control-label" for="customSwitch1">
22
-                  {{ refAgent ? "Yes" : "No" }}
23
-                </label>
21
+                <label
22
+                  class="custom-control-label"
23
+                  for="customSwitch1"
24
+                >{{ refAgent ? "Yes" : "No" }}</label>
24
                 <div class="refbyAgent" :class="{ 'refbyAgent--clicked': refAgent }">
25
                 <div class="refbyAgent" :class="{ 'refbyAgent--clicked': refAgent }">
25
                   <div class="col-md-6" v-if="refAgent">
26
                   <div class="col-md-6" v-if="refAgent">
26
                     <label for="Name of Agency">Agency</label>
27
                     <label for="Name of Agency">Agency</label>
30
                       name="agency"
31
                       name="agency"
31
                       v-model="sellItem.agencyId"
32
                       v-model="sellItem.agencyId"
32
                     >
33
                     >
33
-                      <option v-for="(item, i) in agencies" :key="i" :value="item.id">{{
34
+                      <option v-for="(item, i) in agencies" :key="i" :value="item.id">
35
+                        {{
34
                         item.agencyName
36
                         item.agencyName
35
-                      }}</option>
37
+                        }}
38
+                      </option>
36
                     </select>
39
                     </select>
37
                   </div>
40
                   </div>
38
                   <div class="col-md-6" v-if="refAgent">
41
                   <div class="col-md-6" v-if="refAgent">
64
             <div class="form-row">
67
             <div class="form-row">
65
               <div class="form-group col-md-6">
68
               <div class="form-group col-md-6">
66
                 <div class="input-group">
69
                 <div class="input-group">
67
-                  <label v-if="!sellItem.region" class="uniSelectLabel" for="weekInfoRegionSelect"
68
-                    >REGION</label
69
-                  >
70
+                  <label
71
+                    v-if="!sellItem.region"
72
+                    class="uniSelectLabel"
73
+                    for="weekInfoRegionSelect"
74
+                  >REGION</label>
70
 
75
 
71
                   <select
76
                   <select
72
                     id="weekInfoRegionSelect"
77
                     id="weekInfoRegionSelect"
75
                     @change="regionChange()"
80
                     @change="regionChange()"
76
                     style="font-size: 15px"
81
                     style="font-size: 15px"
77
                   >
82
                   >
78
-                    <option v-for="(region, r) in regions" :key="r" :value="region">
79
-                      {{ region.regionName }}
80
-                    </option>
83
+                    <option
84
+                      v-for="(region, r) in regions"
85
+                      :key="r"
86
+                      :value="region"
87
+                    >{{ region.regionName }}</option>
81
                   </select>
88
                   </select>
82
                 </div>
89
                 </div>
83
 
90
 
94
               </div>
101
               </div>
95
               <div class="form-group col-md-6">
102
               <div class="form-group col-md-6">
96
                 <div class="input-group">
103
                 <div class="input-group">
97
-                  <label v-if="!sellItem.resort" class="uniSelectLabel" for="weekInfoResortSelect"
98
-                    >RESORT NAME</label
99
-                  >
104
+                  <label
105
+                    v-if="!sellItem.resort"
106
+                    class="uniSelectLabel"
107
+                    for="weekInfoResortSelect"
108
+                  >RESORT NAME</label>
100
 
109
 
101
                   <select
110
                   <select
102
                     id="weekInfoResortSelect"
111
                     id="weekInfoResortSelect"
105
                     @change="resortChange()"
114
                     @change="resortChange()"
106
                   >
115
                   >
107
                     <option value="Other">Other</option>
116
                     <option value="Other">Other</option>
108
-                    <option v-for="(resort, r) in filteredResort" :key="r" :value="resort">
109
-                      {{ resort.resortName }}
110
-                    </option>
117
+                    <option
118
+                      v-for="(resort, r) in filteredResort"
119
+                      :key="r"
120
+                      :value="resort"
121
+                    >{{ resort.resortName }}</option>
111
                   </select>
122
                   </select>
112
                 </div>
123
                 </div>
113
                 <!-- <input
124
                 <!-- <input
184
                 <div class="validation"></div>
195
                 <div class="validation"></div>
185
               </div>
196
               </div>
186
               <div class="form-group col-md-6">
197
               <div class="form-group col-md-6">
187
-                <label v-if="!sellItem.bedrooms" class="uniSelectLabel" for="region"
188
-                  >BEDROOM/S</label
189
-                >
198
+                <label v-if="!sellItem.bedrooms" class="uniSelectLabel" for="region">BEDROOM/S</label>
190
 
199
 
191
                 <select
200
                 <select
192
                   class="form-control uniSelect"
201
                   class="form-control uniSelect"
199
                 <div class="validation"></div>
208
                 <div class="validation"></div>
200
               </div>
209
               </div>
201
               <div class="form-group col-md-6">
210
               <div class="form-group col-md-6">
202
-                <label v-if="!sellItem.maxSleep" class="uniSelectLabel" for="region"
203
-                  >SLEEP MAX</label
204
-                >
211
+                <label v-if="!sellItem.maxSleep" class="uniSelectLabel" for="region">SLEEP MAX</label>
205
 
212
 
206
                 <select
213
                 <select
207
                   class="form-control uniSelect"
214
                   class="form-control uniSelect"
225
                 />
232
                 />
226
                 <div class="validation"></div>
233
                 <div class="validation"></div>
227
               </div>
234
               </div>
235
+              <div class="form-group col-md-6">
236
+                <label v-if="!sellItem.weekType" class="uniSelectLabel" for="region">WEEK TYPE</label>
237
+                <select
238
+                  class="form-control uniSelect"
239
+                  name="region"
240
+                  id="region"
241
+                  v-model="sellItem.weekType"
242
+                >
243
+                  <option :key="0">Flexi</option>
244
+                  <option :key="1">Fixed</option>
245
+                  <option :key="2">Module</option>
246
+                  <option :key="3">Syndicate</option>
247
+                </select>
248
+              </div>
228
             </div>
249
             </div>
229
           </div>
250
           </div>
230
           <div align="left" class="custom-control custom-switch mb-2">
251
           <div align="left" class="custom-control custom-switch mb-2">
238
                   :checked="sellItem.currentYearBanked"
259
                   :checked="sellItem.currentYearBanked"
239
                   @change="changeCurrentBanked"
260
                   @change="changeCurrentBanked"
240
                 />
261
                 />
241
-                <label class="custom-control-label" for="customSwitch2">
242
-                  {{ sellItem.currentYearBanked ? "Yes" : "No" }}
243
-                </label>
262
+                <label
263
+                  class="custom-control-label"
264
+                  for="customSwitch2"
265
+                >{{ sellItem.currentYearBanked ? "Yes" : "No" }}</label>
244
                 <div
266
                 <div
245
                   class="spacebanked1"
267
                   class="spacebanked1"
246
                   :class="{ 'spacebanked1--clicked': sellItem.currentYearBanked }"
268
                   :class="{ 'spacebanked1--clicked': sellItem.currentYearBanked }"
247
                 >
269
                 >
248
                   <div class="col-md-6">
270
                   <div class="col-md-6">
249
-                    <label for="If yes, please confirm with whom" v-if="sellItem.currentYearBanked"
250
-                      >Please confirm with whom</label
251
-                    >
271
+                    <label
272
+                      for="If yes, please confirm with whom"
273
+                      v-if="sellItem.currentYearBanked"
274
+                    >Please confirm with whom</label>
252
                     <select
275
                     <select
253
                       class="form-control uniSelect"
276
                       class="form-control uniSelect"
254
                       name="spacebankOwner"
277
                       name="spacebankOwner"
482
                     v-if="!indiv.bankingDetails.bank"
505
                     v-if="!indiv.bankingDetails.bank"
483
                     class="uniSelectLabel"
506
                     class="uniSelectLabel"
484
                     for="weekInfoRegionSelect"
507
                     for="weekInfoRegionSelect"
485
-                    >BANK</label
486
-                  >
508
+                  >BANK</label>
487
 
509
 
488
                   <select
510
                   <select
489
                     id="weekInfoRegionSelect"
511
                     id="weekInfoRegionSelect"
492
                     style="font-size: 15px"
514
                     style="font-size: 15px"
493
                     v-model="indiv.bankingDetails.bank"
515
                     v-model="indiv.bankingDetails.bank"
494
                   >
516
                   >
495
-                    <option v-for="bank in banks" :key="bank.id" :value="bank">
496
-                      {{ bank.name }}
497
-                    </option>
517
+                    <option v-for="bank in banks" :key="bank.id" :value="bank">{{ bank.name }}</option>
498
                   </select>
518
                   </select>
499
                 </div>
519
                 </div>
500
                 <div class="validation"></div>
520
                 <div class="validation"></div>
539
                 class="form-group col-md-12"
559
                 class="form-group col-md-12"
540
                 style="border:solid;border-width:2px; border-color:rgb(27, 117, 187); border-radius: 3px"
560
                 style="border:solid;border-width:2px; border-color:rgb(27, 117, 187); border-radius: 3px"
541
               >
561
               >
542
-                <p style="text-align: left; margin:auto; padding:10px">
543
-                  1. With respect to my timeshare module/week, I confirm that:
544
-                </p>
562
+                <p
563
+                  style="text-align: left; margin:auto; padding:10px"
564
+                >1. With respect to my timeshare module/week, I confirm that:</p>
545
                 <div class="validation"></div>
565
                 <div class="validation"></div>
546
               </div>
566
               </div>
547
             </div>
567
             </div>
559
                     :checked="sellItem.leviesPaidInFull"
579
                     :checked="sellItem.leviesPaidInFull"
560
                     @change="changeLeviesPaidInFull"
580
                     @change="changeLeviesPaidInFull"
561
                   />
581
                   />
562
-                  <label class="custom-control-label" for="customSwitch3">
563
-                    {{ sellItem.leviesPaidInFull ? "Yes" : "No" }}
564
-                  </label>
582
+                  <label
583
+                    class="custom-control-label"
584
+                    for="customSwitch3"
585
+                  >{{ sellItem.leviesPaidInFull ? "Yes" : "No" }}</label>
565
                 </div>
586
                 </div>
566
                 <div class="validation"></div>
587
                 <div class="validation"></div>
567
               </div>
588
               </div>
580
                     :checked="sellItem.weekPlacedForRental"
601
                     :checked="sellItem.weekPlacedForRental"
581
                     @change="changeWeekPlacedForRental"
602
                     @change="changeWeekPlacedForRental"
582
                   />
603
                   />
583
-                  <label class="custom-control-label" for="customSwitch4">
584
-                    {{ sellItem.weekPlacedForRental ? "Yes" : "No" }}
585
-                  </label>
604
+                  <label
605
+                    class="custom-control-label"
606
+                    for="customSwitch4"
607
+                  >{{ sellItem.weekPlacedForRental ? "Yes" : "No" }}</label>
586
                 </div>
608
                 </div>
587
                 <div class="validation"></div>
609
                 <div class="validation"></div>
588
               </div>
610
               </div>
700
               </div>
722
               </div>
701
             </div>
723
             </div>
702
             <div class="text-center col-12">
724
             <div class="text-center col-12">
703
-              <button class="btn-solid-blue" v-if="!sellItem.id" @click="submitSale()">
704
-                SUBMIT
705
-              </button>
725
+              <button class="btn-solid-blue" v-if="!sellItem.id" @click="submitSale()">SUBMIT</button>
706
               <button class="btn-solid-blue" v-else @click="newSale()">NEW WEEK</button>
726
               <button class="btn-solid-blue" v-else @click="newSale()">NEW WEEK</button>
707
             </div>
727
             </div>
708
             <div class="text-center col-12">
728
             <div class="text-center col-12">
709
-              <button class="btn-solid-blue" @click="paygateRedirect()">
710
-                PayGate
711
-              </button>
729
+              <button class="btn-solid-blue" @click="paygateRedirect()">PayGate</button>
712
             </div>
730
             </div>
713
             <br />
731
             <br />
714
             <br />
732
             <br />
734
   name: "TimeshareToSell",
752
   name: "TimeshareToSell",
735
   props: {
753
   props: {
736
     weekId: {
754
     weekId: {
737
-      default: 0
738
-    }
755
+      default: 0,
756
+    },
739
   },
757
   },
740
   data() {
758
   data() {
741
     return {
759
     return {
742
       wait: false,
760
       wait: false,
743
-      userLoggedIn: Log.isLoggedIn()
761
+      userLoggedIn: Log.isLoggedIn(),
744
     };
762
     };
745
   },
763
   },
746
   components: {
764
   components: {
747
     addressAutoComplete,
765
     addressAutoComplete,
748
-    Alert
766
+    Alert,
749
   },
767
   },
750
   mounted() {
768
   mounted() {
751
     if (this.sellItem.id) {
769
     if (this.sellItem.id) {
771
       "sellItem",
789
       "sellItem",
772
       "agencies",
790
       "agencies",
773
       "agents",
791
       "agents",
774
-      "getTemplate"
792
+      "getTemplate",
775
     ]),
793
     ]),
776
     ...mapState("individual", ["indiv"]),
794
     ...mapState("individual", ["indiv"]),
777
     ...mapState("authentication", ["isLoggedIn"]),
795
     ...mapState("authentication", ["isLoggedIn"]),
778
     ...mapGetters({
796
     ...mapGetters({
779
       user: "authentication/getUser",
797
       user: "authentication/getUser",
780
-      person: "authentication/getPerson"
798
+      person: "authentication/getPerson",
781
     }),
799
     }),
782
     ...mapState("bank", ["banks"]),
800
     ...mapState("bank", ["banks"]),
783
     refAgent() {
801
     refAgent() {
785
     },
803
     },
786
     filteredResort() {
804
     filteredResort() {
787
       let list = [];
805
       let list = [];
788
-      if (this.sellItem && this.sellItem.region && this.sellItem.region.regionCode) {
806
+      if (
807
+        this.sellItem &&
808
+        this.sellItem.region &&
809
+        this.sellItem.region.regionCode
810
+      ) {
789
         const item = this.detailedRegion.find(
811
         const item = this.detailedRegion.find(
790
-          region => region.region.regionCode === this.sellItem.region.regionCode
812
+          (region) =>
813
+            region.region.regionCode === this.sellItem.region.regionCode
791
         );
814
         );
792
         if (item) {
815
         if (item) {
793
           list = item.children;
816
           list = item.children;
795
       } else {
818
       } else {
796
         list = this.resorts;
819
         list = this.resorts;
797
       }
820
       }
798
-      return _.sortBy(list, x => x.resortName);
821
+      return _.sortBy(list, (x) => x.resortName);
799
     },
822
     },
800
     isLoggedIn() {
823
     isLoggedIn() {
801
       return this.user && this.person;
824
       return this.user && this.person;
802
     },
825
     },
803
     displayNotDeletedAgents() {
826
     displayNotDeletedAgents() {
804
       var notDeletedArr = [];
827
       var notDeletedArr = [];
805
-      this.agents.forEach(agent => {
828
+      this.agents.forEach((agent) => {
806
         if (!agent.isDeleted) {
829
         if (!agent.isDeleted) {
807
           if (agent.agencyId === this.sellItem.agencyId) {
830
           if (agent.agencyId === this.sellItem.agencyId) {
808
             notDeletedArr.push(agent);
831
             notDeletedArr.push(agent);
810
         }
833
         }
811
       });
834
       });
812
       return notDeletedArr;
835
       return notDeletedArr;
813
-    }
836
+    },
814
   },
837
   },
815
   methods: {
838
   methods: {
816
     ...mapActions("individual", ["getIndividual"]),
839
     ...mapActions("individual", ["getIndividual"]),
817
-    ...mapActions("timeshare", ["initTimeshare", "onResortChange", "saveWeek", "getBlankWeek"]),
840
+    ...mapActions("timeshare", [
841
+      "initTimeshare",
842
+      "onResortChange",
843
+      "saveWeek",
844
+      "getBlankWeek",
845
+    ]),
818
     ...mapActions("payment", ["addPayment"]),
846
     ...mapActions("payment", ["addPayment"]),
819
     ...mapActions("bank", ["getBanks"]),
847
     ...mapActions("bank", ["getBanks"]),
820
     newSale() {
848
     newSale() {
824
     submitSale() {
852
     submitSale() {
825
       if (this.userLoggedIn) {
853
       if (this.userLoggedIn) {
826
         this.sellItem.ownerObject = this.indiv;
854
         this.sellItem.ownerObject = this.indiv;
827
-        console.log(this.sellItem);
828
-
829
-        this.saveWeek(this.sellItem).then(fulfilled => {
830
-          this.paygateRedirect();
831
-        });
855
+        this.sellItem.status = undefined;
856
+        console.log(JSON.stringify(this.sellItem));
857
+        //   this.saveWeek(this.sellItem).then((fulfilled) => {
858
+        //     this.paygateRedirect();
859
+        //   });
832
       } else this.$router.push("/user/login");
860
       } else this.$router.push("/user/login");
833
     },
861
     },
834
     paygateRedirect() {
862
     paygateRedirect() {
838
         creatydById: Log.getUser().id, //Log.getUser().id,
866
         creatydById: Log.getUser().id, //Log.getUser().id,
839
         amount: 380.0,
867
         amount: 380.0,
840
         paymentStatus: "",
868
         paymentStatus: "",
841
-        paymentToken: ""
869
+        paymentToken: "",
842
       };
870
       };
843
 
871
 
844
-      this.addPayment(paymentObj).then(res => {
872
+      this.addPayment(paymentObj).then((res) => {
845
         this.$router.push({
873
         this.$router.push({
846
           name: "PaymentGateway",
874
           name: "PaymentGateway",
847
           params: {
875
           params: {
848
             paymentReqId: res.PAY_REQUEST_ID,
876
             paymentReqId: res.PAY_REQUEST_ID,
849
-            checksum: res.CHECKSUM
850
-          }
877
+            checksum: res.CHECKSUM,
878
+          },
851
         });
879
         });
852
       });
880
       });
853
     },
881
     },
872
     resortChange() {
900
     resortChange() {
873
       this.onResortChange({
901
       this.onResortChange({
874
         resortName: this.sellItem.resort.resortName,
902
         resortName: this.sellItem.resort.resortName,
875
-        resortCode: this.sellItem.resort.resortCode
903
+        resortCode: this.sellItem.resort.resortCode,
876
       });
904
       });
877
 
905
 
878
       if (this.sellItem && this.sellItem.resort === "Other") {
906
       if (this.sellItem && this.sellItem.resort === "Other") {
884
       }
912
       }
885
     },
913
     },
886
     regionChange() {
914
     regionChange() {
887
-      this.sellItem.regionId = this.sellItem.region ? this.sellItem.region.id : 1;
915
+      this.sellItem.regionId = this.sellItem.region
916
+        ? this.sellItem.region.id
917
+        : 1;
888
     },
918
     },
889
     UpdateAddress(address) {
919
     UpdateAddress(address) {
890
       this.indiv.address.streetNumber = address.streetNumber;
920
       this.indiv.address.streetNumber = address.streetNumber;
893
       this.indiv.address.city = address.city;
923
       this.indiv.address.city = address.city;
894
       this.indiv.address.suburb = address.suburb;
924
       this.indiv.address.suburb = address.suburb;
895
       this.indiv.address.postalCode = address.postalCode;
925
       this.indiv.address.postalCode = address.postalCode;
896
-    }
897
-  }
926
+    },
927
+  },
898
 };
928
 };
899
 </script>
929
 </script>
900
 
930
 

Loading…
Cancel
Save