简体   繁体   English

Typo3 Powermail预填充

[英]Typo3 Powermail Prefill

Im using Typo3 and got 2 Powermail Forms on a Hotel Page. 我使用的是Typo3,并在酒店页面上收到了2个Powermail表格。

One small form on every Page where you can put the checkin and checkout date. 每个页面上都有一个小表格,您可以在其中输入签入和签出日期。 After this you will be redirected to the main form. 之后,您将被重定向到主表单。

How can i prefill the daterecords from the small after the redirect in the mainform? 在主表单中进行重定向后,如何从小的预填充日期记录?

Both forms have the same variable names {checkin} and {checkout} 两种形式具有相同的变量名{checkin}和{checkout}

Thanks 谢谢

Try it.. 试试吧..

 plugin.tx_powermail.settings.setup.prefill {
    # Fill field with marker {current_date}
    current_date = TEXT
    current_date{
      data = date : U
      strftime = %d-%m-%Y %H:%M:%S
    }
    form2date = TEXT
    form2date{
      data = date : U
      strftime = %d-%m-%Y %H:%M:%S
    }

    seminar = CONTENT
    seminar {
      table =   tx_news_domain_model_news
      select.pidInList = 118
      select.where.stdWrap.cObject = TEXT
      select.where.stdWrap.cObject.data = GP:tx_news_pi1|news
      select.where.stdWrap.cObject.wrap = uid = |
      select.where.stdWrap.cObject.insertData =1
      renderObj = COA
      renderObj {
            10 = TEXT
            10.dataWrap ={field:title}

      }
    }

    price = CONTENT
    price {
      table =   tx_news_domain_model_news
      select.pidInList = 118
      select.where.stdWrap.cObject = TEXT
      select.where.stdWrap.cObject.data = GP:tx_news_pi1|news
      select.where.stdWrap.cObject.wrap = uid = |
      select.where.stdWrap.cObject.insertData =1
      renderObj = COA
      renderObj {
            10 = TEXT
            10.dataWrap ={field:price}

      }
    }

    location = CONTENT
    location {
      table =   tx_news_domain_model_news
      select.pidInList = 118
      select.where.stdWrap.cObject = TEXT
      select.where.stdWrap.cObject.data = GP:tx_news_pi1|news
      select.where.stdWrap.cObject.wrap = uid = |
      select.where.stdWrap.cObject.insertData =1
      renderObj = COA
      renderObj {
            10 = TEXT
            10.dataWrap ={field:tx_roqnewsevent_location}
      }
    }

    event_startdate = CONTENT
    event_startdate {
      table =   tx_news_domain_model_news
      select.pidInList = 118
      select.where.stdWrap.cObject = TEXT
      select.where.stdWrap.cObject.data = GP:tx_news_pi1|news
      select.where.stdWrap.cObject.wrap = uid = |
      select.where.stdWrap.cObject.insertData =1
      renderObj = COA
      renderObj {
            10 = TEXT
            10.value.field = tx_roqnewsevent_startdate
            10.value.date = d-m-Y 
            #10.strftime = %d-%m-%Y 
      }
    }

}

Hi try add (width js on submit action) in form action url or redirect url width parametrs [checkin]="" and [checkout]="". 嗨,您可以尝试在表单操作网址中添加(提交动作时使用js宽度),或重定向网址宽度参数[checkin] =“”和[checkout] =“”。 Like this 像这样

<form class="form-horizontal powermail_form powermail_form_1" action="index.php?id=5&checkin=25.05.15&checkout=25.06.15" method="post"> 
...

for test try use url "yousite.com/index.php?id=5?checkin=25.05.15&checkout=25.06.15" fields in form must be fill. 要进行测试,请使用表单中的网址“ yousite.com/index.php?id=5?checkin=25.05.15&checkout=25.06.15”。 Where "5" - your main form page id 其中“ 5”-您的主表单页面ID

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM