X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2FSchema.pm;h=7f8e6dace0d0ce4a2ca6b3840b83e3a7cf47142f;hb=3684dae04773904d5500ef93253c5f4c2f6d7f38;hp=bd098def71f0efb95bfdc03cd4f2fa082348b399;hpb=dc39152e4b1b881f0115aa5cbe42fbf48a71e5c5;p=freeside.git diff --git a/FS/FS/Schema.pm b/FS/FS/Schema.pm index bd098def7..7f8e6dace 100644 --- a/FS/FS/Schema.pm +++ b/FS/FS/Schema.pm @@ -512,11 +512,12 @@ sub tables_hashref { 'amount', @money_type, '', '', 'otaker', 'varchar', '', 32, '', '', 'reason', 'text', 'NULL', '', '', '', + 'reasonnum', 'int', 'NULL', '', '', '', 'closed', 'char', 'NULL', 1, '', '', ], 'primary_key' => 'crednum', 'unique' => [], - 'index' => [ ['custnum'] ], + 'index' => [ ['custnum'], ['_date'] ], }, 'cust_credit_bill' => { @@ -664,13 +665,39 @@ sub tables_hashref { 'index' => [ [ 'county' ], [ 'state' ], [ 'country' ] ], }, + 'cust_pay_pending' => { + 'columns' => [ + 'paypendingnum','serial', '', '', '', '', + 'custnum', 'int', '', '', '', '', + 'paid', @money_type, '', '', + '_date', @date_type, '', '', + 'payby', 'char', '', 4, '', '', #CARD/BILL/COMP, should + # be index into payby + # table eventually + 'payinfo', 'varchar', 'NULL', 512, '', '', #see cust_main above + 'paymask', 'varchar', 'NULL', $char_d, '', '', + 'paydate', 'varchar', 'NULL', 10, '', '', + #'paybatch', 'varchar', 'NULL', $char_d, '', '', #for auditing purposes. + 'payunique', 'varchar', 'NULL', $char_d, '', '', #separate paybatch "unique" functions from current usage + + 'status', 'varchar', '', $char_d, '', '', + 'statustext', 'text', 'NULL', '', '', '', + 'gatewaynum', 'int', 'NULL', '', '', '', + #'cust_balance', @money_type, '', '', + 'paynum', 'int', 'NULL', '', '', '', + ], + 'primary_key' => 'paypendingnum', + 'unique' => [ [ 'payunique' ] ], + 'index' => [ [ 'custnum' ], [ 'status' ], ], + }, + 'cust_pay' => { 'columns' => [ 'paynum', 'serial', '', '', '', '', - #now cust_bill_pay #'invnum', 'int', '', '', '', '', 'custnum', 'int', '', '', '', '', - 'paid', @money_type, '', '', '_date', @date_type, '', '', + 'paid', @money_type, '', '', + 'otaker', 'varchar', 'NULL', 32, '', '', #NULL for the upgrade so we can create & populate the field 'payby', 'char', '', 4, '', '', # CARD/BILL/COMP, should be # index into payby table # eventually @@ -682,7 +709,7 @@ sub tables_hashref { 'closed', 'char', 'NULL', 1, '', '', ], 'primary_key' => 'paynum', - 'unique' => [ [ 'payunique' ] ], + #i guess not now, with cust_pay_pending, if we actually make it here, we _do_ want to record it# 'unique' => [ [ 'payunique' ] ], 'index' => [ [ 'custnum' ], [ 'paybatch' ], [ 'payby' ], [ '_date' ] ], }, @@ -846,7 +873,6 @@ sub tables_hashref { 'cust_refund' => { 'columns' => [ 'refundnum', 'serial', '', '', '', '', - #now cust_credit_refund #'crednum', 'int', '', '', '', '', 'custnum', 'int', '', '', '', '', '_date', @date_type, '', '', 'refund', @money_type, '', '', @@ -862,7 +888,7 @@ sub tables_hashref { ], 'primary_key' => 'refundnum', 'unique' => [], - 'index' => [ [ 'custnum' ] ], + 'index' => [ ['custnum'], ['_date'] ], }, 'cust_credit_refund' => { @@ -875,7 +901,7 @@ sub tables_hashref { ], 'primary_key' => 'creditrefundnum', 'unique' => [], - 'index' => [ [ 'crednum', 'refundnum' ] ], + 'index' => [ ['crednum'], ['refundnum'] ], }, @@ -1030,6 +1056,8 @@ sub tables_hashref { 'totalbytes','bigint', 'NULL', '', '', '', 'totalbytes_threshold', 'bigint', 'NULL', '', '', '', 'domsvc', 'int', '', '', '', '', + 'last_login', @date_type, '', '', + 'last_logout', @date_type, '', '', ], 'primary_key' => 'svcnum', #'unique' => [ [ 'username', 'domsvc' ] ], @@ -1865,7 +1893,7 @@ sub tables_hashref { 'columns' => [ 'reasonnum', 'serial', '', '', '', '', 'reason_type', 'int', '', '', '', '', - 'reason', 'varchar', '', $char_d, '', '', + 'reason', 'text', '', '', '', '', 'disabled', 'char', 'NULL', 1, '', '', ], 'primary_key' => 'reasonnum', @@ -1878,7 +1906,7 @@ sub tables_hashref { 'confnum', 'serial', '', '', '', '', 'agentnum', 'int', 'NULL', '', '', '', 'name', 'varchar', '', $char_d, '', '', - 'value', 'long varbinary', 'NULL', '', '', '', + 'value', 'text', 'NULL', '', '', '', ], 'primary_key' => 'confnum', 'unique' => [ [ 'agentnum', 'name' ]],