Difference between revisions of "Template:Payment form"
From cm2.liecourt.com
(Fill database) |
(Fill database) |
||
(9 intermediate revisions by 2 users not shown) | |||
Line 27: | Line 27: | ||
</noinclude><includeonly>{{#vardefine:@cols|4-8}}<!-- | </noinclude><includeonly>{{#vardefine:@cols|4-8}}<!-- | ||
− | --><h1>Please fill in your payment information</h1><wsform action="get" loadscript="disableSubmitButtonOnSubmit" formtarget="{{localurl:Special:PayTrace}}" > | + | -->{{#if: {{{Paytrace validated customer id|}}}|<h1>Please submit your payment</h1>|<h1>Please fill in your payment information</h1>}}<wsform action="get" loadscript="disableSubmitButtonOnSubmit" formtarget="{{localurl:Special:PayTrace}}" > |
<wsfield name="transactions" id="{{{Type|}}}-transactions" value="{{{Transactions|}}}" type="hidden"></wsfield>{{#if: {{{Billing name|}}} | | <wsfield name="transactions" id="{{{Type|}}}-transactions" value="{{{Transactions|}}}" type="hidden"></wsfield>{{#if: {{{Billing name|}}} | | ||
{{Item responsive |Cols={{#var:@cols}} |1=Client name |2=<wsfield name="billing_address_name" id="{{{Type|}}}-billing-name" value="{{{Billing name|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing name|}}} }} }} | {{Item responsive |Cols={{#var:@cols}} |1=Client name |2=<wsfield name="billing_address_name" id="{{{Type|}}}-billing-name" value="{{{Billing name|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing name|}}} }} }} | ||
− | {{Item responsive |Cols={{#var:@cols}} |1=Price |2=<wsfield name="amount" id="{{{Type|}}}-price" value="{{{Price|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Price|}}} }} | + | {{Item responsive |Cols={{#var:@cols}} |1=Price |2=<wsfield name="amount" id="{{{Type|}}}-price" value="{{{Price|}}}" type="hidden" class="form-control" required="required"></wsfield>$ {{{Price|}}},- }} |
+ | <wsfield name="quantity" type="hidden" value="{{{Quantity|}}}" /> | ||
+ | <wsfield name="User" type="hidden" value="{{{User|}}}" /> | ||
{{Item responsive |Cols={{#var:@cols}} |1=Description |2=<wsfield name="description" id="{{{Type|}}}-description" type="hidden" class="form-control" required="required" value="{{{Description|}}}" />{{{Description|}}} }} | {{Item responsive |Cols={{#var:@cols}} |1=Description |2=<wsfield name="description" id="{{{Type|}}}-description" type="hidden" class="form-control" required="required" value="{{{Description|}}}" />{{{Description|}}} }} | ||
− | {{Item responsive |Cols={{#var:@cols}} |1=Invoice nr |2=<wsfield name="invoice_id" id="{{{Type|}}}-invoice-id" value="{{{Invoice id|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Invoice id|}}} }}{{#if: {{{Billing address|}}} | | + | {{Item responsive |Cols={{#var:@cols}} |1=Invoice nr. |2=<wsfield name="invoice_id" id="{{{Type|}}}-invoice-id" value="{{{Invoice id|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Invoice id|}}} }}{{#if: {{{Billing address|}}} | |
− | {{Item responsive |Cols={{#var:@cols}} |1=Billing address street |2=<wsfield name="billing_address_street_address" id="{{{Type|}}}-billing-address" value="{{{Billing address|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing address|}}} }} }} | + | {{Item responsive |Cols={{#var:@cols}} |1=Billing address street |2=<wsfield name="billing_address_street_address" id="{{{Type|}}}-billing-address" value="{{{Billing address|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing address|}}} }} }} |
− | {{Item responsive |Cols={{#var:@cols}} |1=Billing email |2=<wsfield name="email" id="{{{Type|}}}-billing-email" value="{{{Billing email|}}}" type=" | + | {{Item responsive |Cols={{#var:@cols}} |1=Billing email |2=<wsfield name="email" id="{{{Type|}}}-billing-email" value="{{{Billing email|}}}" type="text" class="form-control" required="required"></wsfield>{{{Billing email|}}} }}{{#if: {{{Billing address 2|}}} | |
{{Item responsive |Cols={{#var:@cols}} |1=Billing address street 2 |2=<wsfield name="billing_address_street_address2" id="{{{Type|}}}-billing-address-2" value="{{{Billing address 2|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing address 2|}}} }} }}{{#if: {{{Billing city|}}} | | {{Item responsive |Cols={{#var:@cols}} |1=Billing address street 2 |2=<wsfield name="billing_address_street_address2" id="{{{Type|}}}-billing-address-2" value="{{{Billing address 2|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing address 2|}}} }} }}{{#if: {{{Billing city|}}} | | ||
{{Item responsive |Cols={{#var:@cols}} |1=Billing city |2=<wsfield name="billing_address_city" id="{{{Type|}}}-billing-city" value="{{{Billing city|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing city|}}} }} }}{{#if: {{{Billing state|}}} | | {{Item responsive |Cols={{#var:@cols}} |1=Billing city |2=<wsfield name="billing_address_city" id="{{{Type|}}}-billing-city" value="{{{Billing city|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing city|}}} }} }}{{#if: {{{Billing state|}}} | | ||
Line 41: | Line 43: | ||
{{Item responsive |Cols={{#var:@cols}} |1=Billing country |2=<wsfield name="billing_address_country" id="{{{Type|}}}-billing-country" value="{{{Billing country|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing country|}}} }} }} | {{Item responsive |Cols={{#var:@cols}} |1=Billing country |2=<wsfield name="billing_address_country" id="{{{Type|}}}-billing-country" value="{{{Billing country|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Billing country|}}} }} }} | ||
{{Item responsive |Cols={{#var:@cols}} |1=Paytrace validated customer id |2=<wsfield name="customer_id" id="{{{Type|}}}-paytrace-validated-customer-id" value="{{{Paytrace validated customer id|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Paytrace validated customer id|}}} }}{{#if: {{{Paytrace validated customer id|}}} || | {{Item responsive |Cols={{#var:@cols}} |1=Paytrace validated customer id |2=<wsfield name="customer_id" id="{{{Type|}}}-paytrace-validated-customer-id" value="{{{Paytrace validated customer id|}}}" type="hidden" class="form-control" required="required"></wsfield>{{{Paytrace validated customer id|}}} }}{{#if: {{{Paytrace validated customer id|}}} || | ||
− | {{Item responsive |Cols={{#var:@cols}} |1=Credit card nr |2=<wsfield name="credit_card_number" id="{{{Type|}}}-credit-card-nr" type=" | + | {{Item responsive |Cols={{#var:@cols}} |1=Credit card nr. |2=<wsfield name="credit_card_number" id="{{{Type|}}}-credit-card-nr" type="number" pattern="[0-9]*" data-inputmask="'mask': '9999 9999 9999 9999'" class="form-control" required="required"></wsfield> }} |
{{Item responsive |Cols={{#var:@cols}} |1=Credit card name |2=<wsfield name="CreditCardName" id="{{{Type|}}}-credit-card-name" type="text" class="form-control" required="required"></wsfield> }} | {{Item responsive |Cols={{#var:@cols}} |1=Credit card name |2=<wsfield name="CreditCardName" id="{{{Type|}}}-credit-card-name" type="text" class="form-control" required="required"></wsfield> }} | ||
− | {{Item responsive |Cols={{#var:@cols}} |1=Credit card | + | {{Item responsive |Cols={{#var:@cols}} |1=Credit card expiration |2=<div class="d-flex">{{#Widget:Creditcard select|id=month|{{{Type|}}}-credit-card-expiration-month|name=credit_card_expiration_month|placeholder=MM|options=<option value="01"> |
− | + | <option value="02"> | |
− | {{Item responsive |Cols={{#var:@cols}} |1=Credit card | + | <option value="03"> |
+ | <option value="04"> | ||
+ | <option value="05"> | ||
+ | <option value="06"> | ||
+ | <option value="07"> | ||
+ | <option value="08"> | ||
+ | <option value="09"> | ||
+ | <option value="10"> | ||
+ | <option value="11"> | ||
+ | <option value="12">}}<span class="sep">/</span><!-- | ||
+ | -->{{#Widget:Creditcard select|id={{{Type|}}}-credit-card-expiration-year|name=credit_card_expiration_year|placeholder=YY|options=<!-- | ||
+ | -->{{#vardefine: i | 0 }}{{#while: | ||
+ | | {{#ifexpr: {{#var: i }} < 20 | true }} | ||
+ | | <option value="{{#expr:{{#time:y|now}} + {{#var: i }} }}">{{#vardefine: i | {{#expr: {{#var: i }} + 1 }} }} | ||
+ | }}}}</div> }} | ||
+ | {{Item responsive |Cols={{#var:@cols}} |1=Credit card CSC |2=<wsfield name="csc" placeholder="XXX" id="{{{Type|}}}-credit-card-csc" type="text" class="form-control" required="required"></wsfield> }} | ||
}}<!-- | }}<!-- | ||
Line 58: | Line 75: | ||
--><div class="text-right"> | --><div class="text-right"> | ||
− | <wsfield type="submit" id="makepayment" class="btn btn- | + | <wsfield type="submit" id="makepayment" class="btn btn-green float-right" value="Submit payment"/> |
</div> | </div> | ||
− | </wsform></includeonly> | + | </wsform>{{#if: {{{Paytrace validated customer id|}}}|<wsform action="addToWiki"><!-- |
+ | -->{{#tag:wsedit||target={{PAGEID}}|template=Order|formfield=Paytrace validated customer id|value=}}<!-- | ||
+ | --><wsfield type="submit" class="btn btn-green float-left" value="Change credit-card"/></wsform>}}</includeonly> |
Latest revision as of 13:29, 7 December 2020
This is the Payment form template. It should be called in the following format:
{{Payment form |Type= |Invoice id= |Description= |Billing name= |Billing email= |Price= |Billing address= |Billing address 2= |Billing city= |Billing state= |Billing zip= |Billing country= |Paytrace validated customer id= }}