JannekeDL 5 years ago
parent
commit
5dd02bc9a5

+ 2
- 0
.gitignore View File

19
 *.njsproj
19
 *.njsproj
20
 *.sln
20
 *.sln
21
 *.sw?
21
 *.sw?
22
+vue.config.js
23
+.gitignore

+ 4
- 0
src/assets/staticData/maritalStatus.js View File

1
+const items = ['ICOP (In Community of Property)', 'OCOP (Out of Community of Property)', 'Other',
2
+  'Traditional Wedding', 'Single', 'Divorced', 'Widow', 'Committed Relationship', 'Partner',
3
+];
4
+export default items;

+ 186
- 0
src/components/processFlow/makeOffer.vue View File

1
+<template>
2
+  <!-- eslint-disable max-len -->
3
+  <div style="padding-left:50px; padding-right:50px; padding-bottom:50px;">
4
+    <div>
5
+      <br />
6
+      <div v-if="isProperty">
7
+        <div class="form-group row">
8
+          <div class="col-md-6">
9
+            <div class="title-box-d">
10
+              <h3 class="title-d">{{ item.shortDescription }}</h3>
11
+            </div>
12
+          </div>
13
+        </div>
14
+        <div class="form-group row">
15
+          <div class="col-md-12" style="text-align:left">
16
+            <div v-html="item.description"></div>
17
+          </div>
18
+        </div>
19
+      </div>
20
+      <div v-if="!isProperty">
21
+        <div class="form-group row">
22
+          <div class="col-md-6 col-lg-5 section-md-t3">
23
+            <div class="title-box-d">
24
+              <h3 class="title-d">{{ item.resort }}</h3>
25
+            </div>
26
+          </div>
27
+        </div>
28
+        <div class="form-group row">
29
+          <div class="col-md-4">
30
+            <label for="resortunit">Unit</label>
31
+            <input
32
+              class="form-control"
33
+              type="text"
34
+              id="resort"
35
+              name="resortunit"
36
+              disabled
37
+              v-model="item.unit"
38
+            />
39
+          </div>
40
+          <div class="col-md-4">
41
+            <label for="resortWeek">Week</label>
42
+            <input
43
+              class="form-control"
44
+              type="text"
45
+              id="week"
46
+              name="resortWeek"
47
+              disabled
48
+              v-model="item.week"
49
+            />
50
+          </div>
51
+          <div class="col-md-4">
52
+            <label for="resortModule">Module</label>
53
+            <input
54
+              class="form-control"
55
+              type="text"
56
+              id="module"
57
+              name="resortModule"
58
+              disabled
59
+              v-model="item.module"
60
+            />
61
+          </div>
62
+        </div>
63
+      </div>
64
+      <div class="form-group row">
65
+        <div class="col-md-6">
66
+          <label>Current Price</label>
67
+          <div class="input-group mb-3">
68
+            <div class="input-group-prepend">
69
+              <span class="input-group-text">R</span>
70
+            </div>
71
+            <input class="form-control" type="number" v-model="item.price" disabled />
72
+          </div>
73
+        </div>
74
+        <div class="col-md-6">
75
+          <label>Offer</label>
76
+          <div class="input-group mb-3">
77
+            <div class="input-group-prepend">
78
+              <span class="input-group-text">R</span>
79
+            </div>
80
+            <input
81
+              class="form-control"
82
+              type="number"
83
+              step="any"
84
+              id="minPrice"
85
+              name="minPrice"
86
+              v-model="item.offer"
87
+              :disabled="!isMakeOffer"
88
+            />
89
+          </div>
90
+        </div>
91
+      </div>
92
+      <div class="form-group row">
93
+        <div class="col-md-12">
94
+          <label>Comments</label>
95
+          <textarea
96
+            class="form-control editor form-control-lg form-control-a"
97
+            name="description"
98
+            v-model="item.comments"
99
+            :disabled="!isMakeOffer"
100
+          ></textarea>
101
+        </div>
102
+      </div>
103
+    </div>
104
+    <div class="container">
105
+      <button
106
+        v-if="isMakeOffer"
107
+        type="button"
108
+        @click="SendOffer()"
109
+        class="btn btn-b-n"
110
+        style="width: 150px; height:40px;"
111
+        data-dismiss="modal"
112
+      >Send Offer</button>
113
+      <button
114
+        v-if="!isMakeOffer && !isDecline"
115
+        type="submit"
116
+        @click="Accept()"
117
+        class="btn btn-b-n"
118
+        style="width: 150px; height:40px;"
119
+        data-dismiss="modal"
120
+      >Accept</button>
121
+      <button
122
+        v-if="!isMakeOffer && !isDecline"
123
+        type="button"
124
+        @click="Decline()"
125
+        class="btn btn-b-n"
126
+        style="width: 150px; height:40px;"
127
+      >Decline</button>
128
+      <div v-if="isDecline" class="form-group row">
129
+        <div class="col-md-12">
130
+          <br />
131
+          <label>Decline Reason</label>
132
+          <textarea class="form-control editor form-control-lg form-control-a" name="description"></textarea>
133
+        </div>
134
+      </div>
135
+      <button
136
+        v-if="isDecline"
137
+        type="button"
138
+        @click="Complete()"
139
+        class="btn btn-b-n"
140
+        style="width: 150px; height:40px;"
141
+        data-dismiss="modal"
142
+      >Complete</button>
143
+    </div>
144
+  </div>
145
+</template>
146
+
147
+<script>
148
+export default {
149
+  name: 'MakeOffer',
150
+  props: {
151
+    isMakeOffer: Boolean,
152
+    isProperty: Boolean,
153
+    item: Object,
154
+  },
155
+  data() {
156
+    return {
157
+      isDecline: false,
158
+    };
159
+  },
160
+  methods: {
161
+    SendOffer() {
162
+      // Save Offer data
163
+    },
164
+    Accept() {
165
+      // Accept Offer
166
+    },
167
+    Decline() {
168
+      this.isDecline = true;
169
+    },
170
+    Complete() {
171
+      this.isDecline = false;
172
+    },
173
+    Close() {},
174
+  },
175
+};
176
+</script>
177
+
178
+<style scoped>
179
+.myWell {
180
+  width: 100%;
181
+  background-color: rgba(217, 217, 217, 0.85);
182
+  border-radius: 6px;
183
+  padding: 5px;
184
+  margin: 3px;
185
+}
186
+</style>

+ 109
- 0
src/components/processFlow/offers.vue View File

1
+<template>
2
+  <!-- eslint-disable max-len -->
3
+  <div>
4
+    <div class="container">
5
+      <section class="intro-single">
6
+        <div class="container">
7
+          <div class="row">
8
+            <div class="col-md-12 col-lg-8">
9
+              <div class="title-single-box">
10
+                <h1 class="title-single">Bid Offers</h1>
11
+              </div>
12
+            </div>
13
+          </div>
14
+        </div>
15
+      </section>
16
+    </div>
17
+    <div class="container">
18
+      <table class="table table-bordered">
19
+        <thead>
20
+          <tr>
21
+            <th>Type</th>
22
+            <th>Description</th>
23
+            <th></th>
24
+          </tr>
25
+        </thead>
26
+        <tbody>
27
+          <tr v-for="(item, i) in items" :key="i">
28
+            <td v-if="item.isProperty">Property</td>
29
+            <td v-else>Timeshare</td>
30
+            <td>{{ item.uid }}</td>
31
+            <td>
32
+              <button
33
+                type="button"
34
+                class="btn btn-b-n"
35
+                data-toggle="modal"
36
+                :data-target="'#myModal' + i"
37
+              >View</button>
38
+              <div :id="'myModal' + i" class="modal fade" role="dialog">
39
+                <div class="modal-dialog modal-lg">
40
+                  <!-- Modal content-->
41
+                  <div class="modal-content">
42
+                    <div class="modal-header">
43
+                      <button type="button" class="close" data-dismiss="modal">&times;</button>
44
+                    </div>
45
+                    <div padding-left="20px">
46
+                      <makeOffer
47
+                        name="MakeOffer"
48
+                        :isMakeOffer="false"
49
+                        :isProperty="item.isProperty"
50
+                        :item="item"
51
+                      />
52
+                    </div>
53
+                  </div>
54
+                </div>
55
+              </div>
56
+            </td>
57
+          </tr>
58
+        </tbody>
59
+      </table>
60
+    </div>
61
+  </div>
62
+</template>
63
+
64
+<script>
65
+import makeOffer from './makeOffer.vue';
66
+
67
+export default {
68
+  name: 'offers',
69
+  components: { makeOffer },
70
+  data() {
71
+    return {
72
+      item: {},
73
+      items: [
74
+        {
75
+          isProperty: true,
76
+          uid: '1 - 2 Bedroom House',
77
+          id: 1,
78
+          shortDescription: '2 Bedroom House',
79
+          description: '<div><i>Property Description</i></div>',
80
+          price: 1000,
81
+          offer: 1500,
82
+          comments: 'Bla Bla Bla',
83
+        },
84
+        {
85
+          isProperty: false,
86
+          uid: 'NL N18 359',
87
+          id: 2,
88
+          shortDescription: '',
89
+          description: '',
90
+          price: 85000,
91
+          offer: 90000,
92
+          comments: 'I want to go....',
93
+          resort: 'Ngwenya Lodge',
94
+          unit: '359',
95
+          week: 'N18',
96
+          module: '359/N18 River View',
97
+        },
98
+      ],
99
+    };
100
+  },
101
+  //   methods: {
102
+  //     SetItem(data) {
103
+  //       this.item = data;
104
+  //       const element = this.$refs.modal.$el;
105
+  //       $(element).modal('show');
106
+  //     },
107
+  //   },
108
+};
109
+</script>

+ 28
- 0
src/components/property/propertyPage.vue View File

96
                     </ul>
96
                     </ul>
97
                   </div>
97
                   </div>
98
                 </div>
98
                 </div>
99
+                <div class="col-md-12">
100
+                  <button
101
+                    type="button"
102
+                    class="btn btn-b-n"
103
+                    data-toggle="modal"
104
+                    data-target="#myModal"
105
+                  >Make an Offer</button>
106
+                  <div id="myModal" class="modal fade" role="dialog">
107
+                    <div class="modal-dialog modal-lg">
108
+                      <!-- Modal content-->
109
+                      <div class="modal-content">
110
+                        <div class="modal-header">
111
+                          <button type="button" class="close" data-dismiss="modal">&times;</button>
112
+                        </div>
113
+                        <div padding-left="20px">
114
+                          <makeOffer
115
+                            name="MakeOffer"
116
+                            :isMakeOffer="true"
117
+                            :isProperty="true"
118
+                            :item="{id: property.id, shortDescription: property.shortDescription, description: property.description, price: property.price}"
119
+                          />
120
+                        </div>
121
+                      </div>
122
+                    </div>
123
+                  </div>
124
+                </div>
99
                 <div class="col-md-12">
125
                 <div class="col-md-12">
100
                   <div class="row section-t3">
126
                   <div class="row section-t3">
101
                     <div class="col-sm-12">
127
                     <div class="col-sm-12">
229
 <script>
255
 <script>
230
 import { mapState, mapActions } from 'vuex';
256
 import { mapState, mapActions } from 'vuex';
231
 import lightBox from '../shared/lightBoxGallery.vue';
257
 import lightBox from '../shared/lightBoxGallery.vue';
258
+import makeOffer from '../processFlow/makeOffer.vue';
232
 
259
 
233
 export default {
260
 export default {
234
   name: 'property',
261
   name: 'property',
235
   components: {
262
   components: {
236
     lightBox,
263
     lightBox,
264
+    makeOffer,
237
   },
265
   },
238
   data() {
266
   data() {
239
     return {};
267
     return {};

+ 0
- 9
src/components/shared/test.vue View File

1
-<template>
2
-  <div>Sataliet!!!!!!!!!!!!!</div>
3
-</template>
4
-
5
-<script>
6
-export default {
7
-  name: 'nasa',
8
-};
9
-</script>

+ 32
- 3
src/components/timeshare/resort/unitPage.vue View File

185
 
185
 
186
           <button class="btn btn-b-c even-width mr-auto" type="submit">Enquire Now</button>
186
           <button class="btn btn-b-c even-width mr-auto" type="submit">Enquire Now</button>
187
 
187
 
188
-          <a
188
+          <!-- <a
189
+              class="btn btn-b-n even-width mr-auto"
190
+              href="/share-transfer-initiation-for-purchaser/"
191
+          >Make an Offer</a>-->
192
+          <button
193
+            type="button"
189
             class="btn btn-b-n even-width mr-auto"
194
             class="btn btn-b-n even-width mr-auto"
190
-            href="/share-transfer-initiation-for-purchaser/"
191
-          >Make an Offer</a>
195
+            data-toggle="modal"
196
+            data-target="#myModal"
197
+          >Make an Offer</button>
198
+          <div id="myModal" class="modal fade" role="dialog">
199
+            <div class="modal-dialog modal-lg">
200
+              <!-- Modal content-->
201
+              <div class="modal-content">
202
+                <div class="modal-header">
203
+                  <button type="button" class="close" data-dismiss="modal">&times;</button>
204
+                </div>
205
+                <div padding-left="20px">
206
+                  <makeOffer
207
+                    name="MakeOffer"
208
+                    :isMakeOffer="true"
209
+                    :isProperty="false"
210
+                    :item="{resort: resort.prName, unit: week.unit, week: week.week, module: week.module, price: week.price}"
211
+                  />
212
+                </div>
213
+              </div>
214
+            </div>
215
+          </div>
192
 
216
 
193
           <a class="btn btn-b-c even-width mr-auto" href="javascript:history.back()">Back</a>
217
           <a class="btn btn-b-c even-width mr-auto" href="javascript:history.back()">Back</a>
194
         </div>
218
         </div>
199
 
223
 
200
 <script>
224
 <script>
201
 import { mapState, mapActions } from 'vuex';
225
 import { mapState, mapActions } from 'vuex';
226
+import makeOffer from '../../processFlow/makeOffer.vue';
202
 
227
 
203
 export default {
228
 export default {
229
+  name: 'unit',
230
+  components: {
231
+    makeOffer,
232
+  },
204
   props: {
233
   props: {
205
     resortCode: {},
234
     resortCode: {},
206
     weekId: {},
235
     weekId: {},

+ 1
- 0
src/components/timeshare/sell/sellPage.vue View File

318
             <Address :address="sellItem.owner" />
318
             <Address :address="sellItem.owner" />
319
             <hr />
319
             <hr />
320
             <BankDetails :bankingDetails="sellItem.owner.bankingDetails" />
320
             <BankDetails :bankingDetails="sellItem.owner.bankingDetails" />
321
+            <hr />
321
           </div>
322
           </div>
322
           <hr />
323
           <hr />
323
           <br />
324
           <br />

+ 8
- 6
src/components/user/timeshareIndividual.vue View File

54
             <span class="input-group-text">
54
             <span class="input-group-text">
55
               <eva-icon name="people-outline" fill="#60CBEB"></eva-icon>
55
               <eva-icon name="people-outline" fill="#60CBEB"></eva-icon>
56
             </span>
56
             </span>
57
-            <input
58
-              class="form-control"
59
-              type="text"
60
-              name="maritalstatus"
61
-              v-model="owner.maritalstatus"
62
-            />
57
+            <select class="form-control" name="maritalstatus" v-model="owner.maritalstatus">
58
+              <option v-for="(item, i) in maritalStatus" :key="i">{{item}}</option>
59
+            </select>
63
           </div>
60
           </div>
64
         </div>
61
         </div>
65
         <div class="col-md-6" style="margin-bottom: 1em">
62
         <div class="col-md-6" style="margin-bottom: 1em">
95
 </template>
92
 </template>
96
 
93
 
97
 <script>
94
 <script>
95
+import { mapState } from 'vuex';
96
+
98
 export default {
97
 export default {
99
   component: {},
98
   component: {},
100
   props: {
99
   props: {
101
     owner: {},
100
     owner: {},
102
   },
101
   },
102
+  computed: {
103
+    ...mapState('timeshare', ['maritalStatus']),
104
+  },
103
 };
105
 };
104
 </script>
106
 </script>
105
 
107
 

+ 13
- 0
src/router/index.js View File

36
 import ContactUs from '../components/misc/contactUs.vue';
36
 import ContactUs from '../components/misc/contactUs.vue';
37
 import PrivacyPolicy from '../components/misc/privacyPolicyPage.vue';
37
 import PrivacyPolicy from '../components/misc/privacyPolicyPage.vue';
38
 
38
 
39
+import MakeOffer from '../components/processFlow/makeOffer.vue';
40
+import Offer from '../components/processFlow/offers.vue';
41
+
39
 Vue.use(Router);
42
 Vue.use(Router);
40
 
43
 
41
 export default new Router({
44
 export default new Router({
197
       component: UnitPage,
200
       component: UnitPage,
198
       props: true,
201
       props: true,
199
     },
202
     },
203
+    {
204
+      path: '/MakeOffer',
205
+      name: 'MakeOffer',
206
+      component: MakeOffer,
207
+    },
208
+    {
209
+      path: '/Offers',
210
+      name: 'Offers',
211
+      component: Offer,
212
+    },
200
   ],
213
   ],
201
 });
214
 });

+ 2
- 0
src/store/modules/timeshare/timeshare.js View File

2
 /* eslint-disable no-restricted-syntax */
2
 /* eslint-disable no-restricted-syntax */
3
 import axios from 'axios';
3
 import axios from 'axios';
4
 import MyData from '../../../assets/myData';
4
 import MyData from '../../../assets/myData';
5
+import MaritalStatus from '../../../assets/staticData/maritalStatus';
5
 
6
 
6
 export default {
7
 export default {
7
   namespaced: true,
8
   namespaced: true,
15
     bankedEntities: [],
16
     bankedEntities: [],
16
     agencies: [],
17
     agencies: [],
17
     agents: [],
18
     agents: [],
19
+    maritalStatus: MaritalStatus,
18
     sellItem: {
20
     sellItem: {
19
       referedByAgent: false,
21
       referedByAgent: false,
20
       agent: undefined,
22
       agent: undefined,

Loading…
Cancel
Save