Spamworldpro Mini Shell
Spamworldpro


Server : Apache
System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64
User : corals ( 1002)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
Directory :  /home/corals/vreg/components/Forms/Edit/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/corals/vreg/components/Forms/Edit/ContactInformation.vue
<template>
  <b-modal :id="modalId" hide-footer
           modal-class="address-confirm-modal"
           visible
           hide-header-close
           header-class="justify-content-center"
           title="Contact Information"
           no-close-on-backdrop>


    <ValidationObserver v-slot="{ invalid }" ref="form">
      <form action="">

        <step1-fields :form="form"/>

        <div class="form-button-wrapper">
          <a href="#" @click.prevent="cancelEdit" class="btn-return">
            <svg width="6" height="10" viewBox="0 0 6 10" fill="none" xmlns="http://www.w3.org/2000/svg">
              <path d="M5 9L1 5L5 1" stroke="#182D40" stroke-width="1.2" stroke-linecap="round"
                    stroke-linejoin="round"/>
            </svg>
            Back
          </a>
          <button type="submit" class="btn btn-form-green" @click.prevent="frontendFormSubmitHandler"
                  :disabled=" invalid || !readyToContinue">
            Continue
            <svg width="7" height="13" viewBox="0 0 7 13" fill="none" xmlns="http://www.w3.org/2000/svg">
              <path d="M1 1.5L6 6.5L1 11.5" stroke="white" stroke-width="1.2" stroke-linecap="round"
                    stroke-linejoin="round"/>
            </svg>
          </button>


        </div>

      </form>
    </ValidationObserver>

  </b-modal>
</template>

<script>
import forms from "@/mixins/forms";
import Step1Fields from "@/components/Forms/Step1Fields";

export default {
  name: "ContactInformation",
  components: {Step1Fields},
  mixins: [forms],
  props: {
    form: {
      required: true
    },
    liveUpdate: {
      required: false,
      type: Boolean
    },
    ajaxURL: {
      required: false,
      type: String
    }

  },
  data() {
    return {
      readyToContinue: true,
      modalId: 'contact-information-modal',
      original: {
        first_name: this.form.first_name,
        middle_name: this.form.middle_name,
        last_name: this.form.last_name,
        email: this.form.email,
        phone: this.form.phone,
      }
    }
  },
  methods: {
    submit() {
      if (this.liveUpdate && this.ajaxURL) {
        this.$axios.post(this.ajaxURL, {
          first_name: this.form.first_name,
          middle_name: this.form.middle_name,
          last_name: this.form.last_name,
          email: this.form.email,
          phone: this.form.phone,
        }).then(response => {
          this.$emit('close-modal')
        });
      } else {
        this.$emit('close-modal');
      }
    },
    cancelEdit() {
      for (let key in this.original) {
        this.form[key] = this.original[key];
      }

      this.$emit('close-modal');
    }
  }
}
</script>

<style scoped>

</style>

Spamworldpro Mini