我有一个允许用户绘制多边形的drawingManager.当用户完成绘制该多边形时,我计算该多边形的面积.除编辑多边形事件处理外,所有这些都可以完美地工作.我使用以下代码
google.maps.event.addListener(path, "set_at", function(){
//my code here
});
Run Code Online (Sandbox Code Playgroud)
所以这种工作只适用于多边形的"角落".主白色手柄之间有中间的,几乎看不见的编辑手柄(正方形).如果我通过拉动其中一个手柄来编辑多边形,则事件不会触发.
关于这种行为的任何想法?这是api或我的代码的意图还是某种错误?
感谢您的任何帮助.
格雷格
所以我试图优化一个相当奇怪的查询,但这是一个遗留数据库,所以我用我所拥有的.这些是我正在尝试的查询.它们此时提供相同的输出.w是我的查询集.
def future_schedule(request):
past = datetime.date.today()-datetime.timedelta(days=730)
extra_select = {
'addlcomplete': 'SELECT Complete FROM tblAdditionalDates WHERE Checkin.ShortSampleID = tblAdditionalDates.ShortSampleID',
'addldate': 'SELECT AddlDate FROM tblAdditionalDates WHERE Checkin.ShortSampleID = tblAdditionalDates.ShortSampleID'
}
extra_where = ['''(Checkin.Description <> "Sterilization Permit" AND Checkin.Description <> "Registration State" AND Checkin.Description <> "Miscellaneous" AND Checkin.Description <> "Equipment Purchase" AND Checkin.DateArrived > %s AND Checkin.DateCompleted IS NULL AND Checkin.Canceled = 0) OR (Checkin.Description <> "Sterilization Permit" AND Checkin.Description <> "Registration State" AND Checkin.Description <> "Miscellaneous" AND Checkin.Description <> "Equipment Purchase" AND …Run Code Online (Sandbox Code Playgroud) django django-templates query-optimization django-models django-queryset