Quellcode durchsuchen

Carine & Delia Feedback

master
30117125 vor 4 Jahren
Ursprung
Commit
ac596e5904

+ 4
- 1
public/css/newStyle.css Datei anzeigen

@@ -132,6 +132,9 @@ a:focus {
132 132
 p {
133 133
   padding: 0;
134 134
   margin: 0 0 20px 0;
135
+}
136
+
137
+ql-align-center {
135 138
   text-align: center;
136 139
 }
137 140
 
@@ -273,7 +276,7 @@ h3 {
273 276
 .modal-dialog {
274 277
   position: fixed;
275 278
   margin: auto;
276
-  width: 320px;
279
+  width: 520px;
277 280
   right: 0px;
278 281
   height: 100%;
279 282
 }

+ 8
- 1
src/components/about/aboutTimeshareContentSection.vue Datei anzeigen

@@ -52,7 +52,9 @@
52 52
       <div class="row" data-aos="fade-down">
53 53
         <div class="col-lg-12">
54 54
           <h3>
55
-            Uni-Vate Properties facilitates the timeshare resale for a listing fee of only R380
55
+            Uni-Vate Properties facilitates the timeshare resale for a listing fee of only R{{
56
+              getListingFee.amount
57
+            }}
56 58
             including VAT payable when listing your week/module.
57 59
           </h3>
58 60
           <br />
@@ -65,9 +67,14 @@
65 67
 <script>
66 68
 import AOS from "aos";
67 69
 import "aos/dist/aos.css";
70
+import { mapGetters } from "vuex";
71
+
68 72
 export default {
69 73
   created() {
70 74
     AOS.init();
75
+  },
76
+  computed: {
77
+    ...mapGetters("fees", ["getListingFee"])
71 78
   }
72 79
 };
73 80
 </script>

+ 1
- 1
src/components/about/aboutUsCarouselSection.vue Datei anzeigen

@@ -7,7 +7,7 @@
7 7
             <h2>About Us</h2>
8 8
             <p>
9 9
               Uni-Vate Properties began in 2013 in Pretoria East with various properties in their
10
-              portfolio. Led by our Director, Delia 0' Conner, who has over 25 years of experience
10
+              portfolio. Led by our Director, Delia O' Conner, who has over 25 years of experience
11 11
               in the timeshare industry, the move to conventional property sales and rentals was an
12 12
               easy transition for the Uni-Vate team.
13 13
             </p>

+ 10
- 3
src/components/about/aboutUsContentSection.vue Datei anzeigen

@@ -23,9 +23,11 @@
23 23
           </p>
24 24
           <p>
25 25
             <strong
26
-              >Sellers across SA are able to list properties for a listing fee of R380 per property
27
-              listing which gives them exposure not only on the website, but on social media sites
28
-              also.</strong
26
+              >Sellers across SA are able to list properties for a listing fee of R{{
27
+                getListingFee.amount
28
+              }}
29
+              per property listing which gives them exposure not only on the website, but on social
30
+              media sites also.</strong
29 31
             >
30 32
           </p>
31 33
           <p>
@@ -58,9 +60,14 @@
58 60
 <script>
59 61
 import AOS from "aos";
60 62
 import "aos/dist/aos.css";
63
+import { mapGetters } from "vuex";
64
+
61 65
 export default {
62 66
   created() {
63 67
     AOS.init();
68
+  },
69
+  computed: {
70
+    ...mapGetters("fees", ["getListingFee"])
64 71
   }
65 72
 };
66 73
 </script>

+ 1
- 1
src/components/admin/misc/termsConditions.vue Datei anzeigen

@@ -56,7 +56,7 @@ export default {
56 56
       customToolbar: [
57 57
         [{ header: [false, 1, 2, 3, 4, 5, 6] }],
58 58
         ["bold", "italic", "underline", "strike"],
59
-        [{ align: "" }, { align: "center" }, { align: "right" }, { align: "justify" }],
59
+
60 60
         [{ list: "ordered" }, { list: "bullet" }, { list: "check" }],
61 61
         [{ script: "sub" }, { script: "super" }],
62 62
         [{ indent: "-1" }, { indent: "+1" }]

+ 23
- 15
src/components/admin/status/editTimeShareAdminPage.vue Datei anzeigen

@@ -13,7 +13,6 @@
13 13
                 <div align="center" class="col"></div>
14 14
               </div>
15 15
             </div>
16
-
17 16
             <div class="form">
18 17
               <div id="sendmessage">Your details has been sent. Thank you!</div>
19 18
               <div id="errormessage"></div>
@@ -113,7 +112,7 @@
113 112
                       name="week"
114 113
                       id="week"
115 114
                       placeholder="UNIT / WEEK NUMBER"
116
-                      v-model="weekParam.weekNumber"
115
+                      v-model="week.module"
117 116
                       data-msg="Please enter week number"
118 117
                     />
119 118
                   </float-label>
@@ -218,16 +217,16 @@
218 217
                   <div class="validation"></div>
219 218
                 </div>
220 219
                 <div class="form-group col-md-6 mt-2">
221
-                  <label v-if="!weekParam.askingPrice" for="tsaPrice" class="uniSelectLabel"
220
+                  <label v-if="!week.askingPrice" for="tsaPrice" class="uniSelectLabel"
222 221
                     >ASKING PRICE</label
223 222
                   >
224 223
                   <float-label label="ASKING PRICE">
225 224
                     <currency-input
226 225
                       onclick="this.setSelectionRange(0, this.value.length)"
227 226
                       name="tsaPrice"
228
-                      :value="weekParam.askingPrice"
229
-                      @input="weekParam.askingPrice = $event"
230
-                      v-model="weekParam.askingPrice"
227
+                      :value="week.askingPrice"
228
+                      @input="week.askingPrice = $event"
229
+                      v-model="week.askingPrice"
231 230
                       id="resPrice"
232 231
                       class="form-control uniInput"
233 232
                     />
@@ -404,7 +403,7 @@
404 403
                       id="landline"
405 404
                       placeholder="Landline Number"
406 405
                       data-msg="Please enter your landline number"
407
-                      v-model="week.owner.landlineNumber"
406
+                      v-model="week.owner.telephone"
408 407
                     />
409 408
                   </float-label>
410 409
 
@@ -530,6 +529,8 @@ export default {
530 529
     this.getIndividual(Log.getUser().id);
531 530
     this.getBanks();
532 531
     //this.getWeek(this.weekParam.id);
532
+    console.log(this.regions);
533
+    console.log(this.weekParam.region.regionCode);
533 534
     this.selectedRegion = this.weekParam.region.regionCode;
534 535
     this.selectedResort = this.weekParam.resort.resortCode;
535 536
     this.selectedBedrooms = this.weekParam.bedrooms;
@@ -575,9 +576,9 @@ export default {
575 576
     },
576 577
     filteredResort() {
577 578
       let list = [];
578
-      if (this.sellItem && this.sellItem.region && this.sellItem.region.regionCode) {
579
+      if (this.week && this.week.region && this.selectedRegion) {
579 580
         const item = this.detailedRegion.find(
580
-          region => region.region.regionCode === this.sellItem.region.regionCode
581
+          region => region.region.regionCode === this.selectedRegion
581 582
         );
582 583
         if (item) {
583 584
           list = item.children;
@@ -604,11 +605,13 @@ export default {
604 605
     saveEdit() {
605 606
       this.regions.forEach(region => {
606 607
         if (region.regionCode === this.selectedRegion) {
607
-          this.weekParam.region = region;
608
+          //console.log(region);
609
+          this.weekParam.regionId = region.id;
608 610
         }
609 611
       });
610 612
       this.resorts.forEach(resort => {
611 613
         if (resort.resortCode === this.selectedResort) {
614
+          this.weekParam.resortCode = resort.resortCode;
612 615
           this.weekParam.resortName = resort.resortName;
613 616
         }
614 617
       });
@@ -630,13 +633,18 @@ export default {
630 633
       if (this.week.owner.cellNumber === "") {
631 634
         this.week.owner.cellNumber = "0000000000";
632 635
       }
636
+      if (this.week.owner.telephone === "") {
637
+        this.week.owner.telephone = "0000000000";
638
+      }
633 639
       this.weekParam.arrivalDate = new Date(this.dateParam).toISOString().substring(0, 10);
634 640
       this.weekParam.departureDate = new Date(this.depDateParam).toISOString().substring(0, 10);
635 641
       this.weekParam.pulbishedDate = new Date(this.pubDateParam).toISOString().substring(0, 19);
636
-      this.weekParam.regionId = this.weekParam.region.id;
642
+      //this.weekParam.regionId = this.weekParam.region.id;
637 643
       this.weekParam.agentId = this.week.agentId;
638 644
       //this.weekParam.bankedWith = this.week.bankedWith;
639 645
       this.weekParam.owner = this.week.owner;
646
+      this.weekParam.askingPrice = this.week.askingPrice;
647
+      this.weekParam.module = this.week.module;
640 648
       parseFloat(this.weekParam.sellPrice);
641 649
       parseFloat(this.weekParam.levyAmount);
642 650
       delete this.weekParam.weekType;
@@ -646,10 +654,10 @@ export default {
646 654
       delete this.status;
647 655
       delete this.weekParam.owner.howMarried;
648 656
       delete this.weekParam.cellNumber;
649
-      console.log(JSON.stringify(this.weekParam));
650
-      // this.editSave(this.weekParam).then(() => {
651
-      //   this.backToListView();
652
-      // });
657
+      //console.log(JSON.stringify(this.weekParam));
658
+      this.editSave(this.weekParam).then(() => {
659
+        this.backToListView();
660
+      });
653 661
     },
654 662
     resortChange() {
655 663
       this.onResortChange({

+ 12
- 9
src/components/misc/TermsConditions/contentSection.vue Datei anzeigen

@@ -1,15 +1,18 @@
1 1
 <template>
2
-  <div class="container">
3
-    <div class="row">
4
-      <div class="col">
5
-        <div class="section-header">
6
-          <h2>Terms & Conditions</h2>
2
+  <div>
3
+    <div class="container" style="text-align:left">
4
+      <div class="row">
5
+        <div class="col">
6
+          <div class="section-header">
7
+            <h2>Terms & Conditions</h2>
8
+          </div>
7 9
         </div>
8 10
       </div>
9
-    </div>
10
-    <div class="row">
11
-      <div class="col">
12
-        <div v-html="terms.termsConditions"></div>
11
+
12
+      <div class="row" style="text-align:left">
13
+        <div class="col" style="text-align:left">
14
+          <div v-html="terms.termsConditions" id="htmlContainer"></div>
15
+        </div>
13 16
       </div>
14 17
     </div>
15 18
   </div>

+ 13
- 4
src/components/misc/bondCaclculator.vue Datei anzeigen

@@ -1,6 +1,15 @@
1 1
 <template>
2 2
   <div>
3
-    <h2 id="modal-bondcal">Bond Calculator</h2>
3
+    <iframe
4
+      id="better-bond-frame embed-responsive-item"
5
+      src="https://betterbond.co.za/calculators-in-frame6/home-loan-repayment"
6
+      title="Better Bond"
7
+      height="1340"
8
+      width="100%"
9
+      sandbox="allow-forms allow-scripts allow-same-origin"
10
+      scrolling="yes"
11
+    ></iframe>
12
+    <!-- <h2 id="modal-bondcal">Bond Calculator</h2>
4 13
     <p>Calculate the value of the property you could buy</p>
5 14
     <currency-input
6 15
       onClick="this.setSelectionRange(0, this.value.length)"
@@ -31,9 +40,9 @@
31 40
       id="interest"
32 41
       placeholder="Interest Rate (Percent)"
33 42
       v-model="rate"
34
-    />
43
+    /> -->
35 44
     <!-- <button @click="calculate()" class="btn-solid-blue scrollto">CALCULATE</button> -->
36
-    <div class="container p-0 mt-5">
45
+    <!-- <div class="container p-0 mt-5">
37 46
       <div class="row">
38 47
         <div class="col-md-7">
39 48
           Monthly Repayment
@@ -51,7 +60,7 @@
51 60
           <strong>{{ grossIncome | toCurrency }}</strong>
52 61
         </div>
53 62
       </div>
54
-    </div>
63
+    </div> -->
55 64
   </div>
56 65
 </template>
57 66
 

+ 1
- 1
src/components/misc/privacyPolicy/carouselSection.vue Datei anzeigen

@@ -8,7 +8,7 @@
8 8
             <p>
9 9
               We respect your privacy. This Privacy Policy governs the manner in which we will treat
10 10
               your personal information collected when using our website and when we otherwise
11
-              engage with each after you visiting our website.
11
+              engage with each after you visit our website.
12 12
             </p>
13 13
           </div>
14 14
         </div>

+ 42
- 7
src/components/property/propertyCard.vue Datei anzeigen

@@ -11,7 +11,17 @@
11 11
             <router-link :to="`/property/residential/property/${currentProperty.id}`">
12 12
               <div class="portfolio-item p-4 wow fadeInUp justify-content-md-center">
13 13
                 <div class="feature-top pt-3 mb-2">
14
-                  <h3>{{ currentProperty.displayPrice }}</h3>
14
+                  <div class="pb-2">
15
+                    <h3 style="display:inline">{{ currentProperty.displayPrice }}</h3>
16
+                    <p
17
+                      v-if="!currentProperty.isSale"
18
+                      class="ml-1"
19
+                      style="display:inline; color:white"
20
+                    >
21
+                      Per Month
22
+                    </p>
23
+                  </div>
24
+
15 25
                   <div>
16 26
                     <img
17 27
                       style="height:165px; object-fit: cover;"
@@ -27,7 +37,15 @@
27 37
                 </p>
28 38
                 <p
29 39
                   v-if="currentProperty.displayText != ''"
30
-                  :class="[currentProperty.displayColor === 'green' ? 'greenText' : currentProperty.displayColor === 'orange' ? 'pendingOffer' : currentProperty.displayColor === 'red' ? 'redText' : 'normalText']"
40
+                  :class="[
41
+                    currentProperty.displayColor === 'green'
42
+                      ? 'greenText'
43
+                      : currentProperty.displayColor === 'orange'
44
+                      ? 'pendingOffer'
45
+                      : currentProperty.displayColor === 'red'
46
+                      ? 'redText'
47
+                      : 'normalText'
48
+                  ]"
31 49
                 >
32 50
                   <strong>{{ currentProperty.displayText }}</strong>
33 51
                 </p>
@@ -38,7 +56,16 @@
38 56
             <router-link :to="`/property/commercial/property/${currentProperty.id}`">
39 57
               <div class="portfolio-item p-4 wow fadeInUp justify-content-md-center">
40 58
                 <div class="feature-top pt-3 mb-2">
41
-                  <h3>{{ currentProperty.displayPrice }}</h3>
59
+                  <div class="pb-2">
60
+                    <h3 style="display:inline">{{ currentProperty.displayPrice }}</h3>
61
+                    <p
62
+                      v-if="!currentProperty.isSale"
63
+                      class="ml-1"
64
+                      style="display:inline; color:white"
65
+                    >
66
+                      Per Month
67
+                    </p>
68
+                  </div>
42 69
                   <img
43 70
                     style="height:165px; object-fit: cover;"
44 71
                     :src="currentProperty.displayImage"
@@ -52,7 +79,15 @@
52 79
                 </p>
53 80
                 <p
54 81
                   v-if="currentProperty.displayText != ''"
55
-                  :class="[currentProperty.displayColor === 'green' ? 'greenText' : currentProperty.displayColor === 'orange' ? 'pendingOffer' : currentProperty.displayColor === 'red' ? 'redText' : 'normalText']"
82
+                  :class="[
83
+                    currentProperty.displayColor === 'green'
84
+                      ? 'greenText'
85
+                      : currentProperty.displayColor === 'orange'
86
+                      ? 'pendingOffer'
87
+                      : currentProperty.displayColor === 'red'
88
+                      ? 'redText'
89
+                      : 'normalText'
90
+                  ]"
56 91
                 >
57 92
                   <strong>{{ currentProperty.displayText }}</strong>
58 93
                 </p>
@@ -73,7 +108,7 @@ export default {
73 108
   props: {
74 109
     properties: { type: Array, default: () => [] },
75 110
     showSort: { type: Boolean, default: true },
76
-    salesType: { type: String, default: "Rent" },
111
+    salesType: { type: String, default: "Rent" }
77 112
   },
78 113
   methods: {
79 114
     sortHighPrice() {
@@ -111,8 +146,8 @@ export default {
111 146
       }
112 147
 
113 148
       return this.properties.sort(compare);
114
-    },
115
-  },
149
+    }
150
+  }
116 151
 };
117 152
 </script>
118 153
 

+ 17
- 17
src/components/shared/basePagination.vue Datei anzeigen

@@ -3,7 +3,7 @@
3 3
     <nav>
4 4
       <ul class="pagination">
5 5
         <li class="page-item" v-if="isPreviousButtonDisabled" @click="previousPage">
6
-          <a class="page-link" href="#" aria-label="Previous">
6
+          <a class="page-link" aria-label="Previous">
7 7
             <span aria-hidden="true">&laquo;</span>
8 8
             <span class="sr-only">Previous</span>
9 9
           </a>
@@ -16,7 +16,7 @@
16 16
           />
17 17
         </li>
18 18
         <li class="page-item" v-if="isNextButtonDisabled" @click="nextPage">
19
-          <a class="page-link" href="#" aria-label="Next">
19
+          <a class="page-link" aria-label="Next">
20 20
             <span aria-hidden="true">&raquo;</span>
21 21
             <span class="sr-only">Next</span>
22 22
           </a>
@@ -26,25 +26,25 @@
26 26
   </div>
27 27
 </template>
28 28
 <script>
29
-import BasePaginationItem from './basePaginationItem.vue';
29
+import BasePaginationItem from "./basePaginationItem.vue";
30 30
 
31 31
 export default {
32 32
   components: {
33
-    BasePaginationItem,
33
+    BasePaginationItem
34 34
   },
35 35
   props: {
36 36
     visiblePagesCount: {
37 37
       type: Number,
38
-      default: 5,
38
+      default: 5
39 39
     },
40 40
     currentPage: {
41 41
       type: Number,
42
-      required: true,
42
+      required: true
43 43
     },
44 44
     pageCount: {
45 45
       type: Number,
46
-      required: true,
47
-    },
46
+      required: true
47
+    }
48 48
   },
49 49
   computed: {
50 50
     isPreviousButtonDisabled() {
@@ -71,37 +71,37 @@ export default {
71 71
       if (currentPage <= visiblePagesThreshold + 1) {
72 72
         pagintationItemsArray[0] = 1;
73 73
         const pagintationItems = pagintationItemsArray.map(
74
-          (paginationTrigger, index) => pagintationItemsArray[0] + index,
74
+          (paginationTrigger, index) => pagintationItemsArray[0] + index
75 75
         );
76 76
         pagintationItems.push(pageCount);
77 77
         return pagintationItems;
78 78
       }
79 79
       if (currentPage >= pageCount - visiblePagesThreshold + 1) {
80 80
         const pagintationItems = pagintationItemsArray.map(
81
-          (paginationTrigger, index) => pageCount - index,
81
+          (paginationTrigger, index) => pageCount - index
82 82
         );
83 83
         pagintationItems.reverse().unshift(1);
84 84
         return pagintationItems;
85 85
       }
86 86
       pagintationItemsArray[0] = currentPage - visiblePagesThreshold + 1;
87 87
       const pagintationItems = pagintationItemsArray.map(
88
-        (paginationTrigger, index) => pagintationItemsArray[0] + index,
88
+        (paginationTrigger, index) => pagintationItemsArray[0] + index
89 89
       );
90 90
       pagintationItems.unshift(1);
91 91
       pagintationItems[pagintationItems.length - 1] = pageCount;
92 92
       return pagintationItems;
93
-    },
93
+    }
94 94
   },
95 95
   methods: {
96 96
     onLoadPage(value) {
97
-      this.$emit('loadPage', value);
97
+      this.$emit("loadPage", value);
98 98
     },
99 99
     nextPage() {
100
-      this.$emit('nextPage');
100
+      this.$emit("nextPage");
101 101
     },
102 102
     previousPage() {
103
-      this.$emit('previousPage');
104
-    },
105
-  },
103
+      this.$emit("previousPage");
104
+    }
105
+  }
106 106
 };
107 107
 </script>

+ 6
- 6
src/components/shared/footerSection.vue Datei anzeigen

@@ -32,10 +32,10 @@
32 32
               ><br />
33 33
             </p>
34 34
           </div>
35
-          <div class="col-lg-9 section-header" id="contactFoot">
35
+          <div class="col-lg-4 section-header" id="contactFoot">
36 36
             <h2 align="left">Contact Us</h2>
37 37
             <div class="row">
38
-              <div class="col-md-4">
38
+              <div class="col-md-12">
39 39
                 <p class="footerText">
40 40
                   105 Lombardy Business Park<br />
41 41
                   Cnr. Graham and Cole Rd.<br />
@@ -44,18 +44,18 @@
44 44
                   ><br />
45 45
                   <a href="tel:0124921238">+27 (0) 12 492 1238</a>
46 46
                 </p>
47
-                <br /><br />
47
+                <br />
48 48
                 <p>
49 49
                   <a href="#body"
50 50
                     ><img src="../../../public/img/logos/UVProp.png" width="200px" alt="" title=""
51 51
                   /></a>
52 52
                 </p>
53 53
               </div>
54
-              <div class="col-md-8">
55
-                <contactUsSection />
56
-              </div>
57 54
             </div>
58 55
           </div>
56
+          <div class="col-lg-5 section-header" id="contactFoot">
57
+            <contactUsSection />
58
+          </div>
59 59
         </div>
60 60
       </div>
61 61
     </section>

+ 73
- 7
src/components/timeshare/buy/weekListComponent.vue Datei anzeigen

@@ -18,7 +18,7 @@
18 18
           </tr>
19 19
         </thead>
20 20
         <tbody>
21
-          <tr v-for="(item, i) in filteredWeeks" :key="i">
21
+          <tr v-for="(item, i) in DisplayItems" :key="i">
22 22
             <td>#{{ item.id }}</td>
23 23
             <td>{{ item.unitNumber }}</td>
24 24
             <td>{{ item.weekNumber }}</td>
@@ -49,6 +49,29 @@
49 49
           </tr>
50 50
         </tbody>
51 51
       </table>
52
+      <div class="row">
53
+        <div class="col-md-2">
54
+          Items Per Page:
55
+          <select
56
+            class="form-control"
57
+            v-model="visibleItemsPerPageCount"
58
+            @change="onChangeItemsPerPage()"
59
+          >
60
+            <option v-for="(item, i) in visibleItemSelector" :key="i">{{ item }}</option>
61
+          </select>
62
+        </div>
63
+        <div class="col-md-10 mt-4">
64
+          <div style="float:right">
65
+            <BasePagination
66
+              :currentPage="currentPage"
67
+              :pageCount="PageCount"
68
+              @nextPage="pageChangeHandle('next')"
69
+              @previousPage="pageChangeHandle('previous')"
70
+              @loadPage="pageChangeHandle"
71
+            />
72
+          </div>
73
+        </div>
74
+      </div>
52 75
     </div>
53 76
     <div v-else>
54 77
       <div class="row">
@@ -73,34 +96,77 @@
73 96
 
74 97
 <script>
75 98
 /* eslint-disable */
76
-
99
+import BasePagination from "../../shared/basePagination";
77 100
 import { mapState, mapActions, mapGetters } from "vuex";
78 101
 
79 102
 export default {
80 103
   props: {
81 104
     resortCode: undefined,
82 105
     userId: undefined,
106
+    currentPage: {
107
+      default: 1
108
+    }
109
+  },
110
+  data() {
111
+    return {
112
+      visibleItemsPerPageCount: 8,
113
+      visibleItemSelector: [5, 8, 10, 20, 50, 100]
114
+    };
115
+  },
116
+  components: {
117
+    BasePagination
83 118
   },
84
-  components: {},
85 119
   computed: {
86 120
     ...mapState("weekList", ["weeks", "status"]),
87 121
     ...mapGetters({
88 122
       filteredWeeks: "weekList/filteredWeeks",
89
-      getRegions: "weekList/getRegions",
123
+      getRegions: "weekList/getRegions"
90 124
     }),
125
+    DisplayItems() {
126
+      const list = this.filteredWeeks;
127
+      const startSlice = (this.currentPage - 1) * this.visibleItemsPerPageCount;
128
+      let endSlice = this.currentPage * this.visibleItemsPerPageCount;
129
+      if (endSlice > list.length) {
130
+        endSlice = list.length;
131
+      }
132
+      return list.slice(startSlice, endSlice);
133
+    },
134
+    PageCount() {
135
+      return this.visibleItemsPerPageCount !== 0
136
+        ? Math.ceil(this.filteredWeeks.length / this.visibleItemsPerPageCount)
137
+        : 1;
138
+    }
91 139
   },
92 140
   mounted() {
93 141
     if (this.resortCode) {
94 142
       this.applyResortFilter(this.resortCode);
95 143
     }
96
-    this.getWeeks();
144
+    this.getByResortCode(this.$route.params.resortCode);
145
+    //this.getWeeks();
97 146
   },
98 147
   methods: {
148
+    ...mapActions("weekList", ["getWeeks", "applyResortFilter", "getByResortCode"]),
99 149
     View(item) {
100 150
       this.$router.push(`/resort/${item.resort.resortCode}/${item.unitNumber}`);
101 151
     },
102
-    ...mapActions("weekList", ["getWeeks", "applyResortFilter"]),
103
-  },
152
+    onChangeItemsPerPage() {
153
+      if (this.currentPage !== 1) {
154
+        this.currentPage = 1;
155
+      }
156
+    },
157
+    async pageChangeHandle(value) {
158
+      switch (value) {
159
+        case "next":
160
+          this.currentPage += 1;
161
+          break;
162
+        case "previous":
163
+          this.currentPage -= 1;
164
+          break;
165
+        default:
166
+          this.currentPage = value;
167
+      }
168
+    }
169
+  }
104 170
 };
105 171
 </script>
106 172
 

+ 7
- 6
src/components/timeshare/resort/contentSection.vue Datei anzeigen

@@ -17,6 +17,7 @@
17 17
         </div>
18 18
         <div class="col-md-9 p-5 resort-profile">
19 19
           <h2>{{ resort.prName }}</h2>
20
+          {{ resort }}
20 21
           <WeekList :resortCode="resortCode" />
21 22
           <p>{{ resort.prNotes }}</p>
22 23
           <div class="d-flex mt-3">
@@ -54,13 +55,13 @@ import gallerySection from "./gallerySection";
54 55
 
55 56
 export default {
56 57
   props: {
57
-    resortCode: {},
58
+    resortCode: {}
58 59
   },
59 60
   components: {
60 61
     WeekList,
61 62
     FilterComponent,
62 63
     ResortImages,
63
-    gallerySection,
64
+    gallerySection
64 65
   },
65 66
   // async mounted() {
66 67
   //   await this.initResort(this.resortCode);
@@ -69,7 +70,7 @@ export default {
69 70
   data() {
70 71
     return {
71 72
       index: null,
72
-      boolLoaded: false,
73
+      boolLoaded: false
73 74
     };
74 75
   },
75 76
   computed: {
@@ -80,14 +81,14 @@ export default {
80 81
       return this.resort
81 82
         ? `http://maps.google.com/maps?q=${this.resort.prLatitude},${this.resort.prLongitude}&z=15&output=embed`
82 83
         : "";
83
-    },
84
+    }
84 85
   },
85 86
   methods: {
86 87
     ...mapActions("resort", ["GetResortData"]),
87 88
     routerGoTo(goto) {
88 89
       this.$router.push(goto);
89
-    },
90
-  },
90
+    }
91
+  }
91 92
 };
92 93
 </script>
93 94
 

+ 25
- 34
src/components/timeshare/resort/resortPageNew.vue Datei anzeigen

@@ -3,39 +3,29 @@
3 3
     <carouselSection v-if="!wait" :resortImages="resort.images" />
4 4
     <main id="main" style="margin-top:-20px;">
5 5
       <section>
6
-        <div class="container wider">
6
+        <div class="container">
7 7
           <div class="row" id="resort-profile">
8 8
             <div class="col-md-3">
9
-              <img src="img/listings/property1/property1-gallery.jpg" class="img-fluid" alt />
10
-              <div class="row no-gutters">
11
-                <div class="col-6">
12
-                  <img src="img/listings/property1/property1-gallery.jpg" class="img-fluid" alt />
13
-                </div>
14
-                <div class="col-6">
15
-                  <img src="img/listings/property1/property1-gallery.jpg" class="img-fluid" alt />
16
-                </div>
17
-              </div>
18 9
               <gallerySection :images="resort.images" />
19 10
               <FilterComponent :hideTop="true" />
20 11
             </div>
21
-            <div class="col-md-9 resort-profile" style="margin-top:15px; margin-bottom:15px;">
12
+            <div class="col resort-profile" style="margin-top:15px; margin-bottom:15px;">
22 13
               <h2>{{ resort.prName }}</h2>
23 14
               <WeekList :resortCode="resortCode" />
24 15
               <p v-if="resort.description && resort.description !== ''">{{ resort.description }}</p>
25 16
               <br v-if="resort.description && resort.description !== ''" />
26
-              <p>{{ resort.prNotes }}</p>
27 17
               <div class="d-flex mt-3">
28 18
                 <iframe
29 19
                   width="100%"
30 20
                   height="200"
31 21
                   id="gmap_canvas"
32 22
                   :src="
33
-                'https://maps.google.com/maps?q=' +
34
-                  resort.prLatitude +
35
-                  ',' +
36
-                  resort.prLongitude +
37
-                  '&hl=en&z=14&amp;output=embed'
38
-              "
23
+                    'https://maps.google.com/maps?q=' +
24
+                      resort.prLatitude +
25
+                      ',' +
26
+                      resort.prLongitude +
27
+                      '&hl=en&z=14&amp;output=embed'
28
+                  "
39 29
                   frameborder="0"
40 30
                   scrolling="no"
41 31
                   marginheight="0"
@@ -44,6 +34,13 @@
44 34
               </div>
45 35
             </div>
46 36
           </div>
37
+          <div class="row">
38
+            <div class="col">
39
+              <router-link style="float:right" class="btn-solid-blue mb-4" to="/timeshare/buy"
40
+                >BACK</router-link
41
+              >
42
+            </div>
43
+          </div>
47 44
         </div>
48 45
       </section>
49 46
     </main>
@@ -66,39 +63,33 @@ export default {
66 63
     WeekList,
67 64
     FilterComponent,
68 65
     ResortImages,
69
-    gallerySection,
66
+    gallerySection
70 67
   },
71 68
   data() {
72 69
     return {
73
-      wait: false,
70
+      wait: true
74 71
     };
75 72
   },
76 73
   props: {
77
-    resortCode: {},
74
+    resortCode: {}
78 75
   },
79 76
   methods: {
80 77
     ...mapActions("resort", ["getResortData"]),
81 78
     routerGoTo(goto) {
82 79
       this.$router.push(goto);
83
-    },
80
+    }
84 81
   },
85 82
   computed: {
86
-    ...mapState("resort", ["resort"]),
87
-  },
88
-  mounted() {
89
-    this.wait = true;
90
-    this.getResortData(this.resortCode).then((fulfilled) => {
91
-      this.wait = false;
92
-    });
93
-    // .then(() => {
94
-    //   setTimeout(() => (this.boolLoaded = true), 2000);
95
-    // });
83
+    ...mapState("resort", ["resort"])
96 84
   },
85
+  created() {
86
+    this.getResortData(this.resortCode).then(() => (this.wait = false));
87
+  }
97 88
 };
98 89
 </script>
99 90
 
100 91
 <style lang="scss" scoped>
101
-.wider {
102
-  width: 1600px;
92
+.container {
93
+  max-width: 1400px;
103 94
 }
104 95
 </style>

+ 2
- 0
src/components/timeshare/sell/contentSection.vue Datei anzeigen

@@ -937,6 +937,8 @@ export default {
937 937
         this.saveWeek(this.sellItem).then(fulfilled => {
938 938
           this.paygateRedirect();
939 939
         });
940
+      } else {
941
+        this.$router.push("/user/login");
940 942
       }
941 943
     },
942 944
     paygateRedirect() {

+ 1
- 1
src/store/modules/timeshare/myWeeks.js Datei anzeigen

@@ -71,7 +71,7 @@ export default {
71 71
       await axios
72 72
         .get(`/api/timeshareweek/${id}`)
73 73
         .then(r => {
74
-          console.log(JSON.stringify(r));
74
+          //console.log(JSON.stringify(r));
75 75
           commit("setItem", r.data);
76 76
         })
77 77
         .catch(console.error);

+ 8
- 10
src/store/modules/timeshare/resort.js Datei anzeigen

@@ -136,16 +136,14 @@ export default {
136 136
         )
137 137
         .then(result => commit("setResortMedia", result.data));
138 138
     },
139
-    getResortData({ commit }, resortCode) {
140
-      return new Promise((resolve, reject) => {
141
-        axios
142
-          .get(`/api/resort/GetResortData/${resortCode}`)
143
-          .then(result => {
144
-            commit("setResort", result.data);
145
-            resolve();
146
-          })
147
-          .catch(error => reject(new Error(error.message)));
148
-      });
139
+    async getResortData({ commit }, resortCode) {
140
+      await axios
141
+        .get(`/api/resort/GetResortData/${resortCode}`)
142
+        .then(result => {
143
+          console.log(result.data);
144
+          commit("setResort", result.data);
145
+        })
146
+        .catch(error => console.log(new Error(error.message)));
149 147
     }
150 148
   }
151 149
 };

+ 12
- 3
src/store/modules/timeshare/weekList.js Datei anzeigen

@@ -2,6 +2,7 @@
2 2
 /* eslint-disable eqeqeq */
3 3
 /* eslint-disable no-restricted-syntax */
4 4
 /* eslint-disable guard-for-in */
5
+/* eslint-disable */
5 6
 import axios from "axios";
6 7
 import _, { min } from "lodash";
7 8
 
@@ -140,12 +141,20 @@ export default {
140 141
         resortCode
141 142
       });
142 143
     },
143
-    async getWeeks({ commit, rootGetters }) {
144
+    async getByResortCode({ commit }, resortCode) {
144 145
       commit("onLoading");
145
-      return axios
146
+      await axios.get("/api/timeshareweek/getByResortCode/" + resortCode).then(result => {
147
+        commit("setWeeks", result.data);
148
+        console.log(result);
149
+      });
150
+    },
151
+    async getWeeks({ commit, rootGetters }) {
152
+      //commit("onLoading");
153
+      await axios
146 154
         .get("/api/timeshareweek")
147 155
         .then(result => {
148 156
           const arr2 = result.data.filter(x => x.region !== null);
157
+          console.log(arr2);
149 158
           const arr3 = result.data.filter(x => x.region === null);
150 159
           for (const item in arr3) {
151 160
             const myItem = arr3[item];
@@ -160,8 +169,8 @@ export default {
160 169
               };
161 170
             }
162 171
           }
172
+          console.log(arr3);
163 173
           commit("setWeeks", arr2);
164
-          return Promise.resolve(arr2);
165 174
         })
166 175
         .catch(console.error);
167 176
     },

Laden…
Abbrechen
Speichern