first commit

This commit is contained in:
Inshal
2024-05-29 22:34:28 +05:00
commit e63fc41a20
1470 changed files with 174828 additions and 0 deletions

View File

@@ -0,0 +1,131 @@
<script setup>
const props = defineProps({
formData: {
type: null,
required: true,
},
})
const emit = defineEmits(['update:formData'])
const formData = ref(props.formData)
const offeredItems = [
'iPhone 12 Pro Max',
'iPhone 12 Pro',
'iPhone 11 Pro Max',
'iPhone 11',
'iPhone 12 Mini',
'OnePlus Nord CE',
]
watch(formData, () => {
emit('update:formData', formData.value)
})
</script>
<template>
<VForm>
<VRow>
<VCol
cols="12"
sm="6"
>
<VTextField
v-model="formData.title"
label="Deal Title"
placeholder="Black Friday Sale, 50% off on all products"
/>
</VCol>
<VCol
cols="12"
sm
>
<VTextField
v-model="formData.code"
label="Deal Code"
placeholder="BLACKFRIDAY50"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VTextarea
v-model="formData.description"
label="Deal Description"
placeholder="Write something about this deal"
auto-grow
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VRow>
<VCol cols="12">
<VSelect
v-model="formData.offeredUItems"
multiple
chips
label="Offered Items"
placeholder="Select Offered Items"
:items="offeredItems"
/>
</VCol>
<VCol cols="12">
<VSelect
v-model="formData.cartCondition"
label="Cart Condition"
placeholder="Select Cart Condition"
:items="['Cart must contain all selected Downloads', 'Cart needs one or more of the selected Downloads']"
/>
</VCol>
</VRow>
</VCol>
<VCol
cols="12"
sm="6"
>
<AppDateTimePicker
v-model="formData.dealDuration"
label="Deal Duration"
placeholder="Select Date"
:config="{ mode: 'range' }"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<h6 class="text-sm font-weight-medium">
Notify Users
</h6>
<div class="d-flex align-center flex-wrap gap-x-3">
<VCheckbox
v-model="formData.notification.email"
label="Email"
value="email"
/>
<VCheckbox
v-model="formData.notification.sms"
label="SMS"
value="sms"
/>
<VCheckbox
v-model="formData.notification.pushNotification"
label="Push Notification"
value="push-notification"
/>
</div>
</VCol>
</VRow>
</VForm>
</template>

View File

@@ -0,0 +1,124 @@
<script setup>
import reviewAndComplete from '@images/pages/create-deal-review-complete.png'
const props = defineProps({
formData: {
type: null,
required: true,
},
})
const emit = defineEmits(['update:formData'])
const formData = ref(props.formData)
watch(formData, () => {
emit('update:formData', formData.value)
})
</script>
<template>
<VRow>
<VCol
cols="12"
md="7"
>
<h4 class="text-h4 mb-4">
Almost done! 🚀
</h4>
<p>Confirm your deal details information and submit to create it.</p>
<table class="text-base">
<tr>
<td style="inline-size: 202px;">
<p class="font-weight-medium mb-2">
Deal Type
</p>
</td>
<td>
<p class="mb-2">
Percentage
</p>
</td>
</tr>
<tr>
<td>
<p class="font-weight-medium mb-2">
Amount
</p>
</td>
<td>
<p class="mb-2">
25%
</p>
</td>
</tr>
<tr>
<td>
<p class="font-weight-medium mb-2">
Deal Code
</p>
</td>
<td>
<p class="mb-2">
<VChip
size="small"
color="warning"
>
25PEROFF
</VChip>
</p>
</td>
</tr>
<tr>
<td>
<p class="font-weight-medium mb-2">
Deal Title
</p>
</td>
<td>
<p class="mb-2">
Black friday sale, 25% OFF
</p>
</td>
</tr>
<tr>
<td>
<p class="font-weight-medium mb-2">
Deal Duration
</p>
</td>
<td>
<p class="mb-2">
2021-07-14 to 2021-07-30
</p>
</td>
</tr>
</table>
<VSwitch
v-model="formData.isDealDetailsConfirmed"
label="I have confirmed the deal details."
class="mb-3"
/>
</VCol>
<VCol
cols="12"
md="5"
>
<div class="border rounded pa-4 pb-0">
<VImg
width="178"
:src="reviewAndComplete"
class="mx-auto"
/>
</div>
</VCol>
</VRow>
</template>

View File

@@ -0,0 +1,90 @@
<script setup>
import ShoppingGirl from '@images/pages/shopping-girl.png'
const props = defineProps({
formData: {
type: null,
required: true,
},
})
const emit = defineEmits(['update:formData'])
const discountOffers = [
{
icon: 'ri-percent-line',
title: 'Percentage',
desc: 'Create a deal which offer uses some % off (i.e 5% OFF) on total.',
value: 'percentage',
},
{
icon: 'ri-money-dollar-circle-line',
title: 'Flat Amount',
desc: 'Create a deal which offer uses some flat amount (i.e $5 OFF) on total.',
value: 'flat',
},
{
icon: 'ri-user-line',
title: 'Prime member',
desc: 'Create prime member only deal to encourage the prime members.',
value: 'prime',
},
]
const formData = ref(props.formData)
watch(formData, () => {
emit('update:formData', formData.value)
})
</script>
<template>
<VForm>
<VRow>
<!-- 👉 Shopping girl image -->
<VCol cols="12">
<VImg
:src="ShoppingGirl"
max-height="240"
class="border rounded"
/>
</VCol>
<VCol cols="12">
<CustomRadiosWithIcon
v-model:selected-radio="formData.Offer"
:radio-content="discountOffers"
:grid-column="{ cols: '12', sm: '4' }"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VTextField
v-model="formData.discount"
type="number"
label="Discount"
placeholder="10%"
hint="Enter the discount percentage. 10 = 10%"
persistent-hint
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VSelect
v-model="formData.region"
label="Region"
:items="['Asia', 'Europe', 'Africa', 'Australia', 'North America', 'South America']"
placeholder="Select Region"
hint="Select applicable regions for the deal."
persistent-hint
/>
</VCol>
</VRow>
</VForm>
</template>

View File

@@ -0,0 +1,101 @@
<script setup>
const props = defineProps({
formData: {
type: null,
required: true,
},
})
const emit = defineEmits(['update:formData'])
const formData = ref(props.formData)
watch(formData, () => {
emit('update:formData', formData.value)
})
</script>
<template>
<VForm>
<VRow>
<VCol
cols="12"
sm="6"
>
<VSelect
v-model="formData.userType"
label="User Type"
placeholder="Select User Type"
:items="['All', 'Registered', 'Unregistered', 'Prime Member']"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VTextField
v-model="formData.maxUsers"
label="Max Users"
placeholder="1000"
type="number"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VTextField
v-model="formData.cartAmount"
label="Minimum Cart Amount"
placeholder="$199"
type="number"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VTextField
v-model="formData.promotionFree"
label="Promotion Fee"
placeholder="$4.99"
type="number"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VSelect
v-model="formData.paymentMethod"
label="Payment Method"
placeholder="Select Payment Method"
:items="['Any', 'Credit Card', 'Net Banking', 'Wallet']"
/>
</VCol>
<VCol
cols="12"
sm="6"
>
<VSelect
v-model="formData.dealStatus"
label="Deal Status"
placeholder="Select Deal Status"
:items="['Active', 'Inactive', 'Suspended', 'Abandoned']"
/>
</VCol>
<VCol cols="12">
<VSwitch
v-model="formData.isSingleUserCustomer"
label="Limit this discount to a single-use per customer?"
/>
</VCol>
</VRow>
</VForm>
</template>

View File

@@ -0,0 +1 @@
export {}