增加一个明细扩展字段djmx 然后把下面的脚本加到int show_row_ext() int i,id string sql,vr_note sql="select count(*) from ebs_vr_item where voucher_id=(select voucher_id from ebs_v where voucher_no='"+voucher_no+"')" db_run(sql) id=db_res(0) //msg(id) vr_note="" for(i=1;i<=id;i++) { sql="select b.res_name&'/ '&b.res_spec&'/ 数量:'&a.std_num&' / 单价:'&a.inp_price/100&'/ 金额:'&a.total_amount/100 from ebs_vr_item a,res b,ebs_v c where a.res_id=b.res_id" sql=sql+" and a.item_id="+i+" and a.voucher_id=c.voucher_id and c.voucher_no='"+voucher_no+"' and c.voucher_no<>''" db_run(sql) vr_note=vr_note+nl()+" "+db_res(0) } grid_set_v("MG","djmx",change_row_id,vr_note) |