Changeset 12536 for main/ikobacustom.pcn/trunk/src
- Timestamp:
- 1 Feb 2015, 07:30:33 (10 years ago)
- Location:
- main/ikobacustom.pcn/trunk/src/ikobacustom/pcn/customers
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/ikobacustom.pcn/trunk/src/ikobacustom/pcn/customers/interfaces.py
r12508 r12536 55 55 """ 56 56 57 date_of_birth = FormattedDate( 58 title = _(u'Date of Birth'), 59 required = True, 60 show_year = True, 61 ) 62 57 63 # Customer document interfaces 58 64 … … 74 80 75 81 """ 76 77 date_of_birth = FormattedDate(78 title = _(u'Date of Birth'),79 required = True,80 show_year = True,81 )82 82 83 83 state_of_origin = schema.Choice( -
main/ikobacustom.pcn/trunk/src/ikobacustom/pcn/customers/tests/test_browser.py
r12534 r12536 62 62 customer.reg_number = u'123' 63 63 customer.sex = u'f' 64 customer.date_of_birth = datetime.date(1981, 2, 4) 64 65 IWorkflowState(customer).setState('started') 65 66 self.app['customers'].addCustomer(customer) … … 92 93 result = open(self.outfile, 'rb').read() 93 94 self.assertEqual(result, 94 'customer_id, email,firstname,lastname,middlename,phone,'95 'customer_id,date_of_birth,email,firstname,lastname,middlename,phone,' 95 96 'reg_number,sex,suspended,suspended_comment,password,state,history\r\n' 96 'K1000000, ,Beate,Mueller,,,123,f,0,,,started,[]\r\n')97 'K1000000,1981-02-04#,,Beate,Mueller,,,123,f,0,,,started,[]\r\n') 97 98 # We can reimport the file ... 98 99 processor = PCNCustomerProcessor() 99 100 result = processor.doImport( 100 101 self.outfile, 101 ['customer_id',' email','firstname','lastname','middlename','phone',102 ['customer_id','date_of_birth','email','firstname','lastname','middlename','phone', 102 103 'reg_number','sex','suspended','suspended_comment','password','state'], 103 104 mode='create') … … 108 109 result = processor.doImport( 109 110 self.outfile, 110 ['customer_id',' email','firstname','lastname','middlename','phone',111 ['customer_id','date_of_birth','email','firstname','lastname','middlename','phone', 111 112 'reg_number','sex','suspended','suspended_comment','password','state'], 112 113 mode='create') … … 116 117 result = processor.doImport( 117 118 self.outfile, 118 ['customer_id',' email','firstname','lastname','middlename','phone',119 ['customer_id','date_of_birth','email','firstname','lastname','middlename','phone', 119 120 'xx_reg_number','sex','suspended','suspended_comment','password','state'], 120 121 mode='update') … … 221 222 self.assertMatches(result, 222 223 'categories_practice,class_name,comment,contract_category,contract_id,' 223 ' date_of_birth,history,last_product_id,lga,product_object,'224 'history,last_product_id,lga,product_object,' 224 225 'product_options,res_address,state,state_of_origin,superintendent,' 225 226 'tc_dict,title,user_id,work_address,work_email,work_phone,' 226 227 'year_qualification\r\n' 227 '[],RONContract,,ron,%s, ,'228 '[],RONContract,,ron,%s,' 228 229 '[u\'2015-01-18 16:40:01 WAT - Contract created by system\'],,,,' 229 230 '[],,created,,,{\'en\': u\'Hello World\'},,K1000000,,,,\r\n'
Note: See TracChangeset for help on using the changeset viewer.