Changeset 6910 for WAeUP_SRP/trunk


Ignore:
Timestamp:
19 Oct 2011, 06:56:47 (13 years ago)
Author:
Henrik Bettermann
Message:

Implement FUTMinna acceptance fee payment.

Location:
WAeUP_SRP/trunk
Files:
3 added
4 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/trunk/profiles/default/vocabularies/payment_categories.xml

    r5164 r6910  
    1313    <item key="transfer" msgid="">Transfer</item>
    1414    <item key="gown" msgid="">Gown Hire</item>
     15    <item key="acceptance" msgid="">Acceptance Fee</item>
    1516</object>
  • WAeUP_SRP/trunk/skins/waeup_epayment/interswitch_cb.py

    r5939 r6910  
    121121next_verdict = next_info['next_verdict']
    122122next_previous_verdict = next_info['next_previous_verdict']
    123 
    124123if  resp == '00':
    125124    if pay_doc.category == 'schoolfee': 
     
    170169        #    logger.info('%s no workflow action pay_maintenance_fee' % student_id)
    171170           
    172 
     171    elif pay_doc.category == 'acceptance':
     172        if context.getStudentReviewState() == "admitted":
     173            logger.info('%s paid acceptance fee' % (student_id))
     174            current = DateTime.DateTime()
     175            wf = context.portal_workflow
     176            info = context.getClearanceInfo()
     177            wftool.doActionFor(student,'enter_clearance_pin')
     178            context.waeup_tool.changeWorkflowState(info['clear'], 'opened')
     179            context.waeup_tool.changeWorkflowState(info['app'], 'closed')
     180            dc = {}
     181            app_doc = info['app_doc']
     182            #dc['clr_ac_pin'] = pay_doc.order_id
     183            dc['clr_ac_date'] = current
     184            dc['entry_date'] = current
     185            info['clear_doc'].edit(mapping = dc)
     186            if info['penalty']:
     187                logger.info('%s started late clearance' % (info['id']))
     188            #return redirect("%s/clearance_edit_form" % info['clear'].absolute_url())
    173189
    174190    logger.info('%s received valid callback' % student_id)
     
    177193    logger.info('%s received unsuccessful callback: %s' % (student_id,pd['resp_desc']))
    178194
    179 review_state = wftool.getInfoFor(context,'review_state',None)
    180 if review_state == 'opened':
    181     wftool.doActionFor(context,'close')
     195#review_state = wftool.getInfoFor(context,'review_state',None)
     196#if review_state == 'opened':
     197#    wftool.doActionFor(context,'close')
     198context.waeup_tool.changeWorkflowState(context, 'closed')
    182199
    183200return request.RESPONSE.redirect("%s/waeup_document_view" % context.absolute_url())
  • WAeUP_SRP/trunk/skins/waeup_futminna/getPaymentsFolderInfo.py

    r5214 r6910  
    6868info['prod_id'] = '117'
    6969
     70if review_state == 'admitted':
     71    info['acceptance'] = True
     72else:
     73    info['acceptance'] = False
     74
    7075if payment_disabled:
    7176    info['payment_method'] = ""
  • WAeUP_SRP/trunk/skins/waeup_futminna/payments_view.pt

    r5590 r6910  
    8787                   />
    8888          </form>   
     89
     90          <form tal:condition="info/acceptance|nothing"
     91                tal:attributes="action string: ${context/absolute_url}/pay_interswitch_accept" method="post" class="group">
     92            <input type="submit" name="epayment"
     93                   class="context"
     94                   value="Initiate Acceptance Fee Payment"
     95                   />
     96            <br /><br />
     97            <font tal:condition="python:False" color='red'>Surcharge for Late Registration is 10000 Naira. </font>
     98          </form>
    8999         
    90100          <form tal:condition="info/gown|nothing"
Note: See TracChangeset for help on using the changeset viewer.