bug fix & new function

bug fix,  varible miss problem
new function listformaledge