George Williams 4 лет назад
Родитель
Сommit
16da1530e5

+ 0
- 5
package-lock.json Просмотреть файл

@@ -12315,11 +12315,6 @@
12315 12315
       "integrity": "sha512-TigfiZUs7SN3Z6uxKilqJUtYxte8vp0F4QxabCli6hkKPqU97JzAZc3P7AL6omkRAd2DMI26fOrIGjuALTvXww==",
12316 12316
       "dev": true
12317 12317
     },
12318
-    "vue-currency-input": {
12319
-      "version": "1.22.1",
12320
-      "resolved": "https://registry.npmjs.org/vue-currency-input/-/vue-currency-input-1.22.1.tgz",
12321
-      "integrity": "sha512-5cdMt5lHFx+YFeljAAp8r2gI5S6oykywER5xiFsryk4XSSklezdv+v4VnKCgWaYyZmQ69x0Qs5qqrxindoFjTg=="
12322
-    },
12323 12318
     "vue-disable-autocomplete": {
12324 12319
       "version": "0.0.4",
12325 12320
       "resolved": "https://registry.npmjs.org/vue-disable-autocomplete/-/vue-disable-autocomplete-0.0.4.tgz",

+ 0
- 1
package.json Просмотреть файл

@@ -28,7 +28,6 @@
28 28
     "v-file-upload": "^3.1.7",
29 29
     "vue": "^2.6.11",
30 30
     "vue-carousel": "^0.18.0",
31
-    "vue-currency-input": "^1.22.1",
32 31
     "vue-disable-autocomplete": "0.0.4",
33 32
     "vue-eva-icons": "^1.1.1",
34 33
     "vue-js-modal": "^1.3.33",

+ 0
- 1
public/css/newStyle.css Просмотреть файл

@@ -952,7 +952,6 @@ h4 {
952 952
 #contact {
953 953
   padding: 10px 0;
954 954
   background-color: #efefef;
955
-  scroll-behavior: smooth;
956 955
 }
957 956
 
958 957
 #contact p {

+ 2
- 5
src/components/home/carouselSection.vue Просмотреть файл

@@ -274,15 +274,12 @@ export default {
274 274
 /* Small devices (portrait tablets and large phones, 600px and up) */
275 275
 @media only screen and (min-width: 600px) {
276 276
   .introContentAdjust {
277
-    margin-top: 60px !important;
277
+    margin-top: -15px !important;
278 278
   }
279 279
 }
280 280
 
281 281
 /* Medium devices (landscape tablets, 768px and up) */
282 282
 @media only screen and (min-width: 768px) {
283
-  .introContentAdjust {
284
-    margin-top: 90px !important;
285
-  }
286 283
 }
287 284
 
288 285
 /* Large devices (laptops/desktops, 992px and up) */
@@ -295,7 +292,7 @@ export default {
295 292
 /* Extra large devices (large laptops and desktops, 1200px and up) */
296 293
 @media only screen and (min-width: 1200px) {
297 294
   .introContentAdjust {
298
-    margin-top: 80px !important;
295
+    margin-top: 0px !important;
299 296
   }
300 297
 }
301 298
 </style>

+ 46
- 14
src/components/misc/bondCaclculator.vue Просмотреть файл

@@ -2,17 +2,31 @@
2 2
   <div>
3 3
     <h2 id="modal-bondcal">Bond Calculator</h2>
4 4
     <p>Calculate the value of the property you could buy</p>
5
-    <currency-input :value="amount" @input="amount = $event" class="form-control mb-2" />
6
-    <currency-input :value="deposit" @input="deposit = $event" class="form-control mb-2" />
5
+    <input
6
+      type="text"
7
+      class="form-control mb-2"
8
+      name="income"
9
+      id="gross-income"
10
+      placeholder="Gross Monthly Household Income"
11
+      v-model="amount"
12
+      @input="displayValue()"
13
+    />
14
+    <input
15
+      type="text"
16
+      class="form-control mb-2"
17
+      name="deposit"
18
+      id="deposit"
19
+      placeholder="Deposit Amount – May be Required"
20
+      v-model="deposit"
21
+      @input="displayDeposit()"
22
+    />
7 23
     <div class="slidecontainer mt-4">
8 24
       <input type="range" min="5" max="30" value="10" class="slider" id="myRange" v-model="term" />
9 25
     </div>
10 26
     <p>{{ term }} Years</p>
11
-    <div class="percent uniSelectLabel" style="right:65px;"></div>
12 27
     <input
13
-      type="number"
28
+      type="text"
14 29
       class="form-control mb-2"
15
-      style="width:260px"
16 30
       name="interest"
17 31
       id="interest"
18 32
       placeholder="Interest Rate (Percent)"
@@ -46,8 +60,8 @@
46 60
 export default {
47 61
   data() {
48 62
     return {
49
-      amount: 1000000,
50
-      deposit: 0,
63
+      amount: "R1000000",
64
+      deposit: "R0",
51 65
       term: 10,
52 66
       rate: 7,
53 67
       isInputActive: false
@@ -56,12 +70,34 @@ export default {
56 70
   props: ["value"],
57 71
   methods: {
58 72
     calculate() {
59
-      var rate = this.rate / 100 / 12;
73
+      var rate = this.calcRate();
60 74
       var years = this.term * 12;
61 75
       var topPart = rate * Math.pow(1 + rate, years);
62 76
       var bottomPart = Math.pow(1 + rate, years) - 1;
63 77
       var netAmnt = this.amount - this.deposit;
64 78
       var bond = (netAmnt * topPart) / bottomPart;
79
+    },
80
+    calcRate() {
81
+      var answer = this.rate / 100 / 12;
82
+      return answer;
83
+    },
84
+    displayValue() {
85
+      const formatter = new Intl.NumberFormat("en-US", {
86
+        minimumFractionDigits: 2
87
+      });
88
+      if (this.amount.charAt(0) !== "R") {
89
+        this.amount = "R" + formatter.format(this.amount);
90
+        if (this.amount < 1) {
91
+          this.amount = "R" + 0;
92
+        }
93
+      }
94
+    },
95
+    displayDeposit() {
96
+      if (this.deposit.charAt(0) !== "R") {
97
+        if (this.deposit < 1) {
98
+          this.deposit = "R" + 0;
99
+        }
100
+      }
65 101
     }
66 102
   },
67 103
   computed: {
@@ -71,7 +107,7 @@ export default {
71 107
       var topPart = rate * Math.pow(1 + rate, years);
72 108
       var bottomPart = Math.pow(1 + rate, years) - 1;
73 109
 
74
-      var netAmnt = parseFloat(this.amount) - parseFloat(this.deposit);
110
+      var netAmnt = parseFloat(this.amount.substring(1)) - parseFloat(this.deposit.substring(1));
75 111
       var bond = (netAmnt * topPart) / bottomPart;
76 112
       if (isNaN(bond)) {
77 113
         return 0;
@@ -90,8 +126,4 @@ export default {
90 126
 };
91 127
 </script>
92 128
 
93
-<style lang="scss" scoped>
94
-.percent::after {
95
-  content: "%";
96
-}
97
-</style>
129
+<style lang="scss" scoped></style>

+ 1
- 3
src/components/propertyManagement/rentalManagement/contentSection.vue Просмотреть файл

@@ -19,9 +19,7 @@
19 19
       <div class="row">
20 20
         <div class="col-md-6"></div>
21 21
         <div class="col-md-6">
22
-          <button @click="$vuetify.goTo('#contact', { duration: 2000, easing: 'easeInOutCubic' })">
23
-            <h4>Contact us for a quote</h4>
24
-          </button>
22
+          <h4>Contact us for a quote</h4>
25 23
         </div>
26 24
       </div>
27 25
 

+ 2
- 14
src/components/propertyManagement/sectionalTitle/ourServicesSection.vue Просмотреть файл

@@ -18,9 +18,7 @@
18 18
       <div class="row mt-2">
19 19
         <div class="col-md-6"></div>
20 20
         <div class="col-md-6">
21
-          <button @click="$vuetify.goTo('#contact', { duration: 2000, easing: 'easeInOutCubic' })">
22
-            <h4>Contact us for a quote</h4>
23
-          </button>
21
+          <h4>Contact us for a quote</h4>
24 22
         </div>
25 23
       </div>
26 24
       <div class="row">
@@ -215,17 +213,7 @@
215 213
 </template>
216 214
 
217 215
 <script>
218
-/* eslint-disable */
219
-
220
-export default {
221
-  methods: {
222
-    scrollToAnchor() {
223
-      var element = document.getElementById("contact");
224
-      var top = element.offsetTop;
225
-      window.scrollTo(0, top, { easing: "ease-in-out" });
226
-    }
227
-  }
228
-};
216
+export default {};
229 217
 </script>
230 218
 
231 219
 <style lang="scss" scoped>

+ 0
- 1
src/components/shared/footerSection.vue Просмотреть файл

@@ -2,7 +2,6 @@
2 2
   <div>
3 3
     <section
4 4
       id="contact"
5
-      ref="contactFooter"
6 5
       data-aos="fade-up"
7 6
       data-aos-anchor-placement="top-bottom"
8 7
       data-aos-delay="150"

+ 5
- 25
src/components/shared/navBar.vue Просмотреть файл

@@ -79,12 +79,10 @@
79 79
                       </li>
80 80
                       <hr />
81 81
                       <li>
82
-                        <a href="#" @click="routerGoTo('/property/commercial/new/Sale')">To Sell</a>
82
+                        <a @click="routerGoTo('/property/commercial/new/Sale')">To Sell</a>
83 83
                       </li>
84 84
                       <li>
85
-                        <a href="#" @click="routerGoTo('/property/commercial/new/Rental')"
86
-                          >To Rent</a
87
-                        >
85
+                        <a @click="routerGoTo('/property/commercial/new/Rental')">To Rent</a>
88 86
                       </li>
89 87
                     </ul>
90 88
                   </li>
@@ -102,14 +100,10 @@
102 100
                       </li>
103 101
                       <hr />
104 102
                       <li>
105
-                        <a href="#" @click="routerGoTo('/property/residential/new/Sale')"
106
-                          >To Sell</a
107
-                        >
103
+                        <a @click="routerGoTo('/property/residential/new/Sale')">To Sell</a>
108 104
                       </li>
109 105
                       <li>
110
-                        <a href="#" @click="routerGoTo('/property/residential/new/Rental')"
111
-                          >To Rent</a
112
-                        >
106
+                        <a @click="routerGoTo('/property/residential/new/Rental')">To Rent</a>
113 107
                       </li>
114 108
                     </ul>
115 109
                   </li>
@@ -389,27 +383,13 @@ export default {
389 383
 
390 384
 /* Small devices (portrait tablets and large phones, 600px and up) */
391 385
 @media only screen and (min-width: 600px) {
392
-  .phoneIconDetail {
393
-    display: none;
394
-  }
395
-
396
-  .bondCalculatorDetail {
397
-    display: none;
398
-  }
399 386
   #header {
400
-    min-height: 175px;
387
+    min-height: 145px;
401 388
   }
402 389
 }
403 390
 
404 391
 /* Medium devices (landscape tablets, 768px and up) */
405 392
 @media only screen and (min-width: 768px) {
406
-  .phoneIconDetail {
407
-    display: initial;
408
-  }
409
-
410
-  .bondCalculatorDetail {
411
-    display: initial;
412
-  }
413 393
   #header {
414 394
     min-height: 120px;
415 395
   }

+ 74
- 79
src/components/timeshare/buy/carouselSection.vue Просмотреть файл

@@ -3,81 +3,76 @@
3 3
     <div class="container">
4 4
       <div class="row">
5 5
         <div align="left" class="col-sm-12 col-md-8">
6
-          <div class="intro-content box" style="margin-top:55px">
7
-            <div style="margin-top:-30px">
8
-              <h2>Find your Timeshare</h2>
9
-              <p>
10
-                Please specify one or more details to view the available weeks and then select the
11
-                weeks that interest you on the resort page.
12
-              </p>
13
-              <div class="row">
14
-                <div class="form-group col-md-6">
15
-                  <div class="input-group">
16
-                    <label v-if="!searchParams.region" class="uniSelectLabel" for="region"
17
-                      >REGION</label
18
-                    >
19
-                    <select
20
-                      class="form-control uniSelect"
21
-                      name="region"
22
-                      id="region"
23
-                      v-model="searchParams.region"
24
-                      @change="regionChange"
25
-                    >
26
-                      <option v-for="(region, r) in regions" :key="r">{{
27
-                        region.regionName
28
-                      }}</option>
29
-                    </select>
30
-                  </div>
31
-                  <br />
32
-                  <label>DATE FROM</label>
33
-                  <input
34
-                    type="date"
35
-                    name="arrival-to"
36
-                    class="form-control my-1 uniSelect"
37
-                    id="arrival-to"
38
-                    placeholder="Date From"
39
-                    v-model="filter.date"
40
-                  />
6
+          <div class="intro-content box" style="margin-top:-5px">
7
+            <h2>Find your Timeshare</h2>
8
+            <p>
9
+              Please specify one or more details to view the available weeks and then select the
10
+              weeks that interest you on the resort page.
11
+            </p>
12
+            <div class="row">
13
+              <div class="form-group col-md-6">
14
+                <div class="input-group">
15
+                  <label v-if="!searchParams.region" class="uniSelectLabel" for="region">REGION</label>
16
+                  <select
17
+                    class="form-control uniSelect"
18
+                    name="region"
19
+                    id="region"
20
+                    v-model="searchParams.region"
21
+                    @change="regionChange"
22
+                  >
23
+                    <option v-for="(region, r) in regions" :key="r">{{ region.regionName }}</option>
24
+                  </select>
41 25
                 </div>
42
-                <div class="form-group col-md-6">
43
-                  <div class="input-group">
44
-                    <label
45
-                      v-if="!searchParams.resort"
46
-                      class="uniSelectLabel"
47
-                      for="weekInfoResortSelect"
48
-                      >RESORT</label
49
-                    >
50
-                    <select
51
-                      id="weekInfoResortSelect"
52
-                      class="form-control uniSelect"
53
-                      v-model="searchParams.resort"
26
+                <br />
27
+                <label>DATE FROM</label>
28
+                <input
29
+                  type="date"
30
+                  name="arrival-to"
31
+                  class="form-control my-1 uniSelect"
32
+                  id="arrival-to"
33
+                  placeholder="Date From"
34
+                  v-model="filter.date"
35
+                />
36
+              </div>
37
+              <div class="form-group col-md-6">
38
+                <div class="input-group">
39
+                  <label
40
+                    v-if="!searchParams.resort"
41
+                    class="uniSelectLabel"
42
+                    for="weekInfoResortSelect"
43
+                  >RESORT</label>
44
+                  <select
45
+                    id="weekInfoResortSelect"
46
+                    class="form-control uniSelect"
47
+                    v-model="searchParams.resort"
48
+                  >
49
+                    <option
50
+                      v-for="(resort, r) in filteredResort"
51
+                      :key="r"
52
+                      :value="resort"
53
+                      @change="resortChange"
54 54
                     >
55
-                      <option
56
-                        v-for="(resort, r) in filteredResort"
57
-                        :key="r"
58
-                        :value="resort"
59
-                        @change="resortChange"
60
-                      >
61
-                        {{ resort.resortName }}
62
-                      </option>
63
-                    </select>
64
-                  </div>
65
-                  <br />
66
-                  <label>DATE TO</label>
67
-                  <input
68
-                    type="date"
69
-                    name="arrival-to"
70
-                    class="form-control my-1 uniSelect"
71
-                    id="arrival-to"
72
-                    placeholder="Date To"
73
-                    v-model="filter.ddate"
74
-                  />
55
+                      {{
56
+                      resort.resortName
57
+                      }}
58
+                    </option>
59
+                  </select>
75 60
                 </div>
61
+                <br />
62
+                <label>DATE TO</label>
63
+                <input
64
+                  type="date"
65
+                  name="arrival-to"
66
+                  class="form-control my-1 uniSelect"
67
+                  id="arrival-to"
68
+                  placeholder="Date To"
69
+                  v-model="filter.ddate"
70
+                />
76 71
               </div>
77
-              <button class="btn-solid-blue" @click="Search()">
78
-                <i class="fa fa-search"></i> SEARCH
79
-              </button>
80 72
             </div>
73
+            <button class="btn-solid-blue" @click="Search()">
74
+              <i class="fa fa-search"></i> SEARCH
75
+            </button>
81 76
           </div>
82 77
         </div>
83 78
       </div>
@@ -112,7 +107,7 @@ import carousel from "vue-owl-carousel";
112 107
 import { mapState, mapActions, mapGetters } from "vuex";
113 108
 export default {
114 109
   components: {
115
-    carousel
110
+    carousel,
116 111
   },
117 112
   data() {
118 113
     return {
@@ -121,17 +116,17 @@ export default {
121 116
       region: "",
122 117
       resort: "",
123 118
       priceMin: undefined,
124
-      priceMax: undefined
119
+      priceMax: undefined,
125 120
     };
126 121
   },
127 122
   methods: {
128 123
     ...mapActions("timeshare", ["initTimeshare", "onResortChange", "saveWeek"]),
129 124
     regionChange(item) {
130
-      let reg = this.regions.find(r => r.regionName === item.target.value);
125
+      let reg = this.regions.find((r) => r.regionName === item.target.value);
131 126
       this.regionObj = reg;
132 127
     },
133 128
     resortChange(item) {
134
-      let res = this.resorts.find(r => r.resortName === item.target.value);
129
+      let res = this.resorts.find((r) => r.resortName === item.target.value);
135 130
       this.resortObj = res;
136 131
     },
137 132
     Search() {
@@ -148,7 +143,7 @@ export default {
148 143
       }
149 144
 
150 145
       this.$router.push(`/resort/${this.searchParams.resort.resortCode}`);
151
-    }
146
+    },
152 147
   },
153 148
   computed: {
154 149
     ...mapState("timeshare", ["resorts", "regions", "detailedRegion"]),
@@ -157,7 +152,7 @@ export default {
157 152
       let list = [];
158 153
       if (this.searchParams.region && this.searchParams.region !== "") {
159 154
         const item = this.detailedRegion.find(
160
-          region => region.region.regionCode === this.regionObj.regionCode
155
+          (region) => region.region.regionCode === this.regionObj.regionCode
161 156
         );
162 157
         if (item) {
163 158
           list = item.children;
@@ -165,8 +160,8 @@ export default {
165 160
       } else {
166 161
         list = this.resorts;
167 162
       }
168
-      return _.sortBy(list, x => x.resortName);
169
-    }
163
+      return _.sortBy(list, (x) => x.resortName);
164
+    },
170 165
   },
171 166
   created() {
172 167
     this.initTimeshare(this.weekId);
@@ -176,7 +171,7 @@ export default {
176 171
     this.searchParams.resort = null;
177 172
     this.filter.date = null;
178 173
     this.filter.ddate = null;
179
-  }
174
+  },
180 175
 };
181 176
 </script>
182 177
 

+ 12
- 10
src/components/timeshare/buy/searchSection.vue Просмотреть файл

@@ -2,7 +2,7 @@
2 2
   <section>
3 3
     <div class="container pb-5">
4 4
       <div class="row" id="search">
5
-        <div class="col-md-4 panel-left p-5" style="margin-top:-25px;">
5
+        <div class="col-md-4 panel-left p-5" style="margin-top:-20px">
6 6
           <h2>Find Timeshare</h2>
7 7
 
8 8
           <div class="input-group">
@@ -29,9 +29,11 @@
29 29
               v-model="selectedResort"
30 30
               @change="resortEvent()"
31 31
             >
32
-              <option v-for="(resort, i) in selectedRegion.resorts" :key="i" :value="resort">{{
33
-                resort.resortName
34
-              }}</option>
32
+              <option
33
+                v-for="(resort, i) in selectedRegion.resorts"
34
+                :key="i"
35
+                :value="resort"
36
+              >{{ resort.resortName }}</option>
35 37
             </select>
36 38
           </div>
37 39
           <div v-else class="input-group my-1">
@@ -135,7 +137,7 @@ import Alert from "../../shared/alert.vue";
135 137
 export default {
136 138
   name: "TimeshareToBuy",
137 139
   components: {
138
-    Alert
140
+    Alert,
139 141
   },
140 142
   data() {
141 143
     return {
@@ -147,7 +149,7 @@ export default {
147 149
       bedrooms: null,
148 150
       maxPrice: null,
149 151
       dateFrom: "",
150
-      dateTo: ""
152
+      dateTo: "",
151 153
     };
152 154
   },
153 155
   mounted() {
@@ -161,8 +163,8 @@ export default {
161 163
       return `http://maps.google.com/maps?q=${this.myMap}&z=${this.myZoom}&output=embed`;
162 164
     },
163 165
     regions() {
164
-      return _.sortBy(this.detailedRegion, r => r.regionName);
165
-    }
166
+      return _.sortBy(this.detailedRegion, (r) => r.regionName);
167
+    },
166 168
   },
167 169
   methods: {
168 170
     ...mapActions("region", ["init", "getAvail", "getRegions", "getResort"]),
@@ -199,8 +201,8 @@ export default {
199 201
       if (this.selectedResort) {
200 202
         this.$router.push(`/resort/${this.selectedResort.resortCode}`);
201 203
       }
202
-    }
203
-  }
204
+    },
205
+  },
204 206
 };
205 207
 </script>
206 208
 

+ 1
- 9
src/main.js Просмотреть файл

@@ -7,12 +7,8 @@ import App from "./App.vue";
7 7
 import router from "./router";
8 8
 import store from "./store";
9 9
 import * as VueGoogleMaps from "vue2-google-maps";
10
-import Vuetify from "vuetify";
11
-import "vuetify/dist/vuetify.min.css";
12
-import VueCurrencyInput from "vue-currency-input";
13 10
 
14 11
 Vue.use(EvaIcons);
15
-Vue.use(Vuetify);
16 12
 Vue.use(VueGoogleMaps, {
17 13
   load: {
18 14
     key: "AIzaSyD8k_Kwml_C8IDfs-gX8JFV8acli3L9cAE",
@@ -25,10 +21,6 @@ Vue.use(VueGoogleMaps, {
25 21
     // v: '3.26',
26 22
   }
27 23
 });
28
-const pluginOptions = {
29
-  /* see config reference */
30
-  globalOptions: { currency: ["ZAR", null, { prefix: "R" }][2], locale: "en-us" }
31
-};
32 24
 Vue.config.productionTip = false;
33 25
 //axios.defaults.baseURL = "http://localhost:57260";
34 26
 axios.defaults.baseURL = "http://training.provision-sa.com:82";
@@ -41,7 +33,7 @@ const token = localStorage.getItem("token");
41 33
 if (token) {
42 34
   Vue.prototype.$http.defaults.headers.common.Authorization = token;
43 35
 }
44
-Vue.use(VueCurrencyInput, pluginOptions);
36
+
45 37
 router.beforeEach((to, from, next) => {
46 38
   if (to.matched.some(record => record.meta.requiresAuth)) {
47 39
     if (store.getters.isLoggedIn) {

+ 4
- 9
src/router/index.js Просмотреть файл

@@ -1,5 +1,4 @@
1 1
 /* eslint-disable import/prefer-default-export */
2
-/* eslint-disable */
3 2
 import Vue from "vue";
4 3
 import Router from "vue-router";
5 4
 
@@ -85,14 +84,10 @@ Vue.use(Router);
85 84
 export default new Router({
86 85
   // eslint-disable-next-line no-unused-vars
87 86
   scrollBehavior(to, from, savedPosition) {
88
-    if (to.hash) {
89
-      return { selector: to.hash };
90
-    } else {
91
-      return {
92
-        x: 0,
93
-        y: 0
94
-      };
95
-    }
87
+    return {
88
+      x: 0,
89
+      y: 0
90
+    };
96 91
   },
97 92
   routes: [
98 93
     {

Загрузка…
Отмена
Сохранить