Changeset 8244 for main/waeup.kofa


Ignore:
Timestamp:
22 Apr 2012, 10:12:23 (13 years ago)
Author:
Henrik Bettermann
Message:

Remove all payment attributes which are not really necessary in the base package. All these parameters are only subject to customization.

Location:
main/waeup.kofa/trunk/src/waeup/kofa
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/applicants/browser.py

    r8243 r8244  
    472472        payment.p_category = p_category
    473473        payment.amount_auth = academic_session.acceptance_fee
    474         payment.surcharge_1 = academic_session.surcharge_1
    475         payment.surcharge_2 = academic_session.surcharge_2
    476         payment.surcharge_3 = academic_session.surcharge_3
     474        #payment.surcharge_1 = academic_session.surcharge_1
     475        #payment.surcharge_2 = academic_session.surcharge_2
     476        #payment.surcharge_3 = academic_session.surcharge_3
    477477        self.context[payment.p_id] = payment
    478478        self.flash(_('Payment ticket created.'))
     
    524524            return
    525525        self.context.r_amount_approved = self.context.amount_auth
    526         self.context.r_card_num = u'0000'
    527526        self.context.r_code = u'00'
    528527        self.context.p_state = 'paid'
  • main/waeup.kofa/trunk/src/waeup/kofa/interfaces.py

    r8230 r8244  
    576576        )
    577577
    578     surcharge_1 = schema.Float(
    579         title = _(u'Surcharge Portal Provider'),
    580         default = 0.0,
    581         required = False,
    582         )
    583 
    584     surcharge_2 = schema.Float(
    585         title = _(u'Surcharge Payment Gateway Provider'),
    586         default = 0.0,
    587         required = False,
    588         )
    589 
    590     surcharge_3 = schema.Float(
    591         title = _(u'Surcharge 3'),
    592         default = 0.0,
    593         required = False,
    594         )
     578    #surcharge_1 = schema.Float(
     579    #    title = _(u'Surcharge Portal Provider'),
     580    #    default = 0.0,
     581    #    required = False,
     582    #    )
     583
     584    #surcharge_2 = schema.Float(
     585    #    title = _(u'Surcharge Payment Gateway Provider'),
     586    #    default = 0.0,
     587    #    required = False,
     588    #    )
     589
     590    #surcharge_3 = schema.Float(
     591    #    title = _(u'Surcharge 3'),
     592    #    default = 0.0,
     593    #    required = False,
     594    #    )
    595595
    596596    clearance_fee = schema.Float(
  • main/waeup.kofa/trunk/src/waeup/kofa/payments/interfaces.py

    r8174 r8244  
    103103    """
    104104
    105     surcharge_1 = schema.Float(
    106         title = _(u'Portal Fee'),
    107         default = 0.0,
    108         required = False,
    109         readonly = True,
    110         )
    111 
    112     surcharge_2 = schema.Float(
    113         title = _(u'Surcharge 2'),
    114         default = 0.0,
    115         required = False,
    116         readonly = True,
    117         )
    118 
    119     surcharge_3 = schema.Float(
    120         title = _(u'Surcharge 3'),
    121         default = 0.0,
    122         required = False,
    123         readonly = True,
    124         )
    125 
    126     #order_id = schema.TextLine(
    127     #    title = u'Order Id',
    128     #    default = None,
    129     #    required = True,
    130     #    )
    131 
    132105    ac = schema.TextLine(
    133106        title = _(u'Activation Code'),
     
    144117        )
    145118
    146     r_desc = schema.TextLine(
    147         title = _(u'Response Description'),
    148         default = None,
    149         required = False,
    150         readonly = False,
    151         )
    152 
    153     r_pay_reference = schema.TextLine(
    154         title = _(u'Response Payment Reference'),
    155         default = None,
    156         required = False,
    157         readonly = False,
    158         )
    159 
    160119    r_code = schema.TextLine(
    161120        title = _(u'Response Code'),
     
    164123        readonly = False,
    165124        )
    166 
    167     r_card_num = schema.TextLine(
    168         title = _(u'Response Card Number'),
    169         default = None,
    170         required = False,
    171         readonly = False,
    172         )
  • main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py

    r8194 r8244  
    10991099        payment.p_session = p_session
    11001100        payment.amount_auth = pay_details['amount']
    1101         payment.surcharge_1 = pay_details['surcharge_1']
    1102         payment.surcharge_2 = pay_details['surcharge_2']
    1103         payment.surcharge_3 = pay_details['surcharge_3']
     1101        #payment.surcharge_1 = pay_details['surcharge_1']
     1102        #payment.surcharge_2 = pay_details['surcharge_2']
     1103        #payment.surcharge_3 = pay_details['surcharge_3']
    11041104        self.context[payment.p_id] = payment
    11051105        self.flash(_('Payment ticket created.'))
     
    11421142        write_log_message(self,'valid callback: %s' % self.context.p_id)
    11431143        self.context.r_amount_approved = self.context.amount_auth
    1144         self.context.r_card_num = u'0000'
    11451144        self.context.r_code = u'00'
    11461145        self.context.p_state = 'paid'
  • main/waeup.kofa/trunk/src/waeup/kofa/students/catalog.py

    r7811 r8244  
    141141    p_item = index.Field(attribute='p_item')
    142142    p_state = index.Field(attribute='p_state')
    143     r_pay_reference = index.Text(attribute='r_pay_reference')
  • main/waeup.kofa/trunk/src/waeup/kofa/students/tests/sample_payment_data.csv

    r8233 r8244  
    1 matric_number,p_state,p_category,r_pay_reference,r_desc,p_id,reg_number,session_id,r_amount_approved,p_item,amount_auth,r_card_num,r_code,creation_date,type,surcharge_1
    2 ,paid,schoolfee,GTB|WEB|FUT|26-11-2010|002295,Approved Successful,3816951290797973744#,1,2010,19500,BTECHBDT,19500,0942,00,2010/11/26 19:59:33.744 GMT+1,online,0
    3 100001,unpaid,schoolfee,GTB|WEB|FUT|25-11-2010|,Transaction status unconfirmed,3816951290712593757,,2010,0,BTECHBDT,19500,0942,Z0,2010-11-25 20:16:33.757 GMT+1,online,0
    4 ,paid,schoolfee,UBA|WEB|FUT|15-02-2010|000517,Approved Successful,p1266236341955,3,2009,19500,BTECHBDT,19500,0615,00,2010/02/15 13:19:01,online,0
     1matric_number,p_state,p_category,p_id,reg_number,session_id,r_amount_approved,p_item,amount_auth,r_card_num,r_code,creation_date,type
     2,paid,schoolfee,3816951290797973744#,1,2010,19500,BTECHBDT,19500,0942,00,2010/11/26 19:59:33.744 GMT+1,online
     3100001,unpaid,schoolfee,3816951290712593757,,2010,0,BTECHBDT,19500,0942,Z0,2010-11-25 20:16:33.757 GMT+1,online
     4,paid,schoolfee,p1266236341955,3,2009,19500,BTECHBDT,19500,0615,00,2010/02/15 13:19:01,online
  • main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_catalog.py

    r8082 r8244  
    7979        payment.p_category = 'schoolfee'
    8080        payment.p_state = 'paid'
    81         payment.r_pay_reference = u'GTB|WEB|FUT'
    8281        self.student['payments'][payment.p_id] = payment
    8382        return
     
    218217            'payments']['p1234567890']
    219218
    220     def test_search_by_reference(self):
    221         # We can find a payment ticket by parts of the response reference
    222         cat = queryUtility(ICatalog, name='payments_catalog')
    223         results = cat.searchResults(r_pay_reference='GTB')
    224         results = [x for x in results] # Turn results generator into list
    225         assert len(results) == 1
    226         assert results[0] is self.app['students'][self.student_id][
    227             'payments']['p1234567890']
    228 
    229219    def test_reindex(self):
    230220        # We can reindex any kind of catalog with the updateIndexes method.
  • main/waeup.kofa/trunk/src/waeup/kofa/students/utils.py

    r8234 r8244  
    256256            d['error'] = u'Session configuration object is not available.'
    257257            return d
    258         d['surcharge_1'] = academic_session.surcharge_1
    259         d['surcharge_2'] = academic_session.surcharge_2
    260         d['surcharge_3'] = academic_session.surcharge_3
     258        #d['surcharge_1'] = academic_session.surcharge_1
     259        #d['surcharge_2'] = academic_session.surcharge_2
     260        #d['surcharge_3'] = academic_session.surcharge_3
    261261        if category == 'schoolfee':
    262262            d['amount'] = academic_session.school_fee_base
     
    265265            d['p_item'] = student['studycourse'].certificate.code
    266266            d['amount'] = academic_session.clearance_fee
    267             d['surcharge_1'] = 0.0 # no portal fee
     267            #d['surcharge_1'] = 0.0 # no portal fee
    268268        elif category == 'bed_allocation':
    269269            d['p_item'] = self.getAccommodationDetails(student)['bt']
    270270            d['amount'] = academic_session.booking_fee
    271             d['surcharge_1'] = 0.0 # no portal fee
     271            #d['surcharge_1'] = 0.0 # no portal fee
    272272        return d
    273273
Note: See TracChangeset for help on using the changeset viewer.