Ver código fonte

support django 1.3

zhangfisher 13 anos atrás
pai
commit
4f48afcbc8

+ 1 - 1
.idea/DjangoUeditor.iml

@@ -4,7 +4,7 @@
     <facet type="django" name="Django">
       <configuration>
         <option name="rootFolder" value="$MODULE_DIR$" />
-        <option name="settingsModule" value="DjangoUeditor/settings.py" />
+        <option name="settingsModule" value="DUSite/settings.py" />
         <option name="manageScript" value="manage.py" />
       </configuration>
     </facet>

+ 2 - 0
.idea/dictionaries/wxzhang.xml

@@ -1,7 +1,9 @@
 <component name="ProjectDictionaryState">
   <dictionary name="wxzhang">
     <words>
+      <w>backends</w>
       <w>iframe</w>
+      <w>sqlite</w>
     </words>
   </dictionary>
 </component>

+ 1 - 1
.idea/runConfigurations/DjangoUeditor.xml

@@ -5,7 +5,7 @@
     <envs>
       <env name="PYTHONUNBUFFERED" value="1" />
     </envs>
-    <option name="SDK_HOME" value="C:/Python27/python.exe" />
+    <option name="SDK_HOME" value="D:/Python27/python.exe" />
     <option name="WORKING_DIRECTORY" value="" />
     <option name="IS_MODULE_SDK" value="false" />
     <module name="DjangoUeditor" />

+ 1 - 1
.idea/vcs.xml

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <project version="4">
   <component name="VcsDirectoryMappings">
-    <mapping directory="" vcs="" />
+    <mapping directory="" vcs="Git" />
   </component>
 </project>
 

+ 163 - 113
.idea/workspace.xml

@@ -1,7 +1,19 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <project version="4">
   <component name="ChangeListManager">
-    <list default="true" id="1bcdded4-a933-47e3-aef4-259720d783c0" name="Default" comment="" />
+    <list default="true" id="1bcdded4-a933-47e3-aef4-259720d783c0" name="Default" comment="">
+      <change type="DELETED" beforePath="E:\Work\Code\Django\DjangoUeditor\DUSite\test.db" afterPath="" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/DjangoUeditor.iml" afterPath="$PROJECT_DIR$/.idea/DjangoUeditor.iml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/dictionaries/wxzhang.xml" afterPath="$PROJECT_DIR$/.idea/dictionaries/wxzhang.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/runConfigurations/DjangoUeditor.xml" afterPath="$PROJECT_DIR$/.idea/runConfigurations/DjangoUeditor.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/vcs.xml" afterPath="$PROJECT_DIR$/.idea/vcs.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/DUSite/settings.py" afterPath="$PROJECT_DIR$/DUSite/settings.py" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/DjangoUeditor/urls.py" afterPath="$PROJECT_DIR$/DjangoUeditor/urls.py" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/DjangoUeditor/utils.py" afterPath="$PROJECT_DIR$/DjangoUeditor/utils.py" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/TestApp/models.py" afterPath="$PROJECT_DIR$/TestApp/models.py" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/TestApp/views.py" afterPath="$PROJECT_DIR$/TestApp/views.py" />
+    </list>
     <ignored path="DjangoUeditor.iws" />
     <ignored path=".idea/workspace.xml" />
     <option name="TRACKING_ENABLED" value="true" />
@@ -26,37 +38,55 @@
   </component>
   <component name="FileEditorManager">
     <leaf>
-      <file leaf-file-name="readme.txt" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/readme.txt">
+      <file leaf-file-name="models.py" pinned="false" current="true" current-in-tab="true">
+        <entry file="file://$PROJECT_DIR$/DjangoUeditor/models.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="85" column="13" selection-start="2965" selection-end="2965" vertical-scroll-proportion="0.0">
+            <state line="24" column="18" selection-start="1013" selection-end="1013" vertical-scroll-proportion="0.35947713">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="settings.py" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/DUSite/settings.py">
+      <file leaf-file-name="widgets.py" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/DjangoUeditor/widgets.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="160" column="20" selection-start="5606" selection-end="5606" vertical-scroll-proportion="0.0">
+            <state line="35" column="0" selection-start="1334" selection-end="1334" vertical-scroll-proportion="0.0">
+              <folding />
+            </state>
+          </provider>
+        </entry>
+      </file>
+      <file leaf-file-name="forms.py" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/TestApp/forms.py">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="6" column="30" selection-start="223" selection-end="223" vertical-scroll-proportion="0.0">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
       <file leaf-file-name="views.py" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/DjangoUeditor/views.py">
+        <entry file="file://$PROJECT_DIR$/TestApp/views.py">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="28" column="52" selection-start="909" selection-end="909" vertical-scroll-proportion="0.0">
+              <folding />
+            </state>
+          </provider>
+        </entry>
+      </file>
+      <file leaf-file-name="test.html" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/DUSite/templates/test.html">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="135" column="49" selection-start="5076" selection-end="5076" vertical-scroll-proportion="0.0">
+            <state line="10" column="0" selection-start="231" selection-end="231" vertical-scroll-proportion="0.0">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="settings.py" pinned="false" current="true" current-in-tab="true">
-        <entry file="file://$PROJECT_DIR$/DjangoUeditor/settings.py">
+      <file leaf-file-name="models.py" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/TestApp/models.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="25" column="47" selection-start="1215" selection-end="1215" vertical-scroll-proportion="0.040590405">
+            <state line="10" column="37" selection-start="329" selection-end="329" vertical-scroll-proportion="0.0">
               <folding />
             </state>
           </provider>
@@ -69,19 +99,26 @@
       <setting name="OPEN_NEW_TAB" value="false" />
     </FindUsagesManager>
   </component>
+  <component name="Git.Settings">
+    <option name="PUSH_AUTO_UPDATE" value="true" />
+    <option name="SYNC_SETTING" value="DONT" />
+    <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
+  </component>
   <component name="IdeDocumentHistory">
     <option name="changedFiles">
       <list>
         <option value="$PROJECT_DIR$/DUSite/urls.py" />
         <option value="$PROJECT_DIR$/DjangoUeditor/templates/ueditor.html" />
-        <option value="$PROJECT_DIR$/DjangoUeditor/urls.py" />
-        <option value="$PROJECT_DIR$/TestApp/models.py" />
-        <option value="$PROJECT_DIR$/DjangoUeditor/utils.py" />
-        <option value="$PROJECT_DIR$/DjangoUeditor/widgets.py" />
         <option value="$PROJECT_DIR$/DjangoUeditor/settings.py" />
         <option value="$PROJECT_DIR$/DjangoUeditor/views.py" />
         <option value="$PROJECT_DIR$/readme.txt" />
+        <option value="$PROJECT_DIR$/DjangoUeditor/urls.py" />
+        <option value="$PROJECT_DIR$/DjangoUeditor/models.py" />
+        <option value="$PROJECT_DIR$/DjangoUeditor/widgets.py" />
+        <option value="$PROJECT_DIR$/TestApp/models.py" />
+        <option value="$PROJECT_DIR$/DjangoUeditor/utils.py" />
         <option value="$PROJECT_DIR$/DUSite/settings.py" />
+        <option value="$PROJECT_DIR$/TestApp/views.py" />
       </list>
     </option>
   </component>
@@ -91,14 +128,14 @@
     <option name="width" value="1382" />
     <option name="height" value="744" />
   </component>
-  <component name="ProjectLevelVcsManager" settingsEditedManually="false">
+  <component name="ProjectLevelVcsManager" settingsEditedManually="true">
     <OptionsSetting value="true" id="Add" />
     <OptionsSetting value="true" id="Remove" />
     <OptionsSetting value="true" id="Checkout" />
     <OptionsSetting value="true" id="Update" />
     <OptionsSetting value="true" id="Status" />
     <OptionsSetting value="true" id="Edit" />
-    <ConfirmationsSetting value="0" id="Add" />
+    <ConfirmationsSetting value="1" id="Add" />
     <ConfirmationsSetting value="0" id="Remove" />
   </component>
   <component name="ProjectReloadState">
@@ -117,6 +154,16 @@
       <sortByType />
     </navigator>
     <panes>
+      <pane id="Scope">
+        <subPane subId="Project Files">
+          <PATH>
+            <PATH_ELEMENT USER_OBJECT="Root">
+              <option name="myItemId" value="" />
+              <option name="myItemType" value="" />
+            </PATH_ELEMENT>
+          </PATH>
+        </subPane>
+      </pane>
       <pane id="ProjectPane">
         <subPane>
           <PATH>
@@ -145,7 +192,7 @@
               <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
             </PATH_ELEMENT>
             <PATH_ELEMENT>
-              <option name="myItemId" value="TestApp" />
+              <option name="myItemId" value="DjangoUeditor" />
               <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
             </PATH_ELEMENT>
           </PATH>
@@ -159,7 +206,7 @@
               <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
             </PATH_ELEMENT>
             <PATH_ELEMENT>
-              <option name="myItemId" value="DjangoUeditor" />
+              <option name="myItemId" value="DUSite" />
               <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
             </PATH_ELEMENT>
           </PATH>
@@ -176,15 +223,9 @@
               <option name="myItemId" value="DUSite" />
               <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
             </PATH_ELEMENT>
-          </PATH>
-        </subPane>
-      </pane>
-      <pane id="Scope">
-        <subPane subId="Project Files">
-          <PATH>
-            <PATH_ELEMENT USER_OBJECT="Root">
-              <option name="myItemId" value="" />
-              <option name="myItemType" value="" />
+            <PATH_ELEMENT>
+              <option name="myItemId" value="templates" />
+              <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
             </PATH_ELEMENT>
           </PATH>
         </subPane>
@@ -194,10 +235,10 @@
   <component name="PropertiesComponent">
     <property name="options.splitter.main.proportions" value="0.3" />
     <property name="WebServerToolWindowFactoryState" value="false" />
-    <property name="options.lastSelected" value="com.jetbrains.python.configuration.PythonSdkConfigurable" />
     <property name="recentsLimit" value="5" />
-    <property name="options.splitter.details.proportions" value="0.2" />
+    <property name="options.lastSelected" value="com.jetbrains.django.DjangoModulesConfigurable" />
     <property name="options.searchVisible" value="true" />
+    <property name="options.splitter.details.proportions" value="0.2" />
   </component>
   <component name="PyConsoleOptionsProvider">
     <option name="myPythonConsoleState">
@@ -208,7 +249,7 @@
     </option>
   </component>
   <component name="RunManager" selected="Django server.DjangoUeditor">
-    <configuration default="true" type="PythonConfigurationType" factoryName="Python">
+    <configuration default="true" type="DjangoTestsConfigurationType" factoryName="Django tests">
       <option name="INTERPRETER_OPTIONS" value="" />
       <option name="PARENT_ENVS" value="true" />
       <envs>
@@ -219,12 +260,12 @@
       <option name="IS_MODULE_SDK" value="false" />
       <module name="DjangoUeditor" />
       <EXTENSION ID="PythonCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" runner="coverage.py" />
-      <option name="SCRIPT_NAME" value="" />
-      <option name="PARAMETERS" value="" />
-      <option name="MULTIPROCESS" value="false" />
+      <option name="TARGET" value="" />
+      <option name="SETTINGS_FILE" value="" />
+      <option name="CUSTOM_SETTINGS" value="false" />
       <method />
     </configuration>
-    <configuration default="true" type="Python.DjangoServer" factoryName="Django server">
+    <configuration default="true" type="PythonConfigurationType" factoryName="Python">
       <option name="INTERPRETER_OPTIONS" value="" />
       <option name="PARENT_ENVS" value="true" />
       <envs>
@@ -234,37 +275,13 @@
       <option name="WORKING_DIRECTORY" value="" />
       <option name="IS_MODULE_SDK" value="false" />
       <module name="DjangoUeditor" />
-      <option name="launchJavascriptDebuger" value="false" />
-      <option name="port" value="8000" />
-      <option name="host" value="" />
-      <option name="additionalOptions" value="" />
-      <option name="browserUrl" value="" />
-      <option name="runTestServer" value="false" />
-      <option name="runNoReload" value="false" />
-      <option name="useCustomRunCommand" value="false" />
-      <option name="customRunCommand" value="" />
-      <method />
-    </configuration>
-    <configuration default="true" type="tests" factoryName="Unittests">
-      <option name="INTERPRETER_OPTIONS" value="" />
-      <option name="PARENT_ENVS" value="true" />
-      <envs />
-      <option name="SDK_HOME" value="" />
-      <option name="WORKING_DIRECTORY" value="" />
-      <option name="IS_MODULE_SDK" value="false" />
-      <module name="DjangoUeditor" />
       <EXTENSION ID="PythonCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" runner="coverage.py" />
       <option name="SCRIPT_NAME" value="" />
-      <option name="CLASS_NAME" value="" />
-      <option name="METHOD_NAME" value="" />
-      <option name="FOLDER_NAME" value="" />
-      <option name="TEST_TYPE" value="TEST_SCRIPT" />
-      <option name="PATTERN" value="" />
-      <option name="USE_PATTERN" value="false" />
-      <option name="PUREUNITTEST" value="true" />
+      <option name="PARAMETERS" value="" />
+      <option name="MULTIPROCESS" value="false" />
       <method />
     </configuration>
-    <configuration default="true" type="tests" factoryName="Doctests">
+    <configuration default="true" type="tests" factoryName="Unittests">
       <option name="INTERPRETER_OPTIONS" value="" />
       <option name="PARENT_ENVS" value="true" />
       <envs />
@@ -280,9 +297,10 @@
       <option name="TEST_TYPE" value="TEST_SCRIPT" />
       <option name="PATTERN" value="" />
       <option name="USE_PATTERN" value="false" />
+      <option name="PUREUNITTEST" value="true" />
       <method />
     </configuration>
-    <configuration default="false" name="DjangoUeditor" type="Python.DjangoServer" factoryName="Django server">
+    <configuration default="true" type="Python.DjangoServer" factoryName="Django server">
       <option name="INTERPRETER_OPTIONS" value="" />
       <option name="PARENT_ENVS" value="true" />
       <envs>
@@ -301,12 +319,24 @@
       <option name="runNoReload" value="false" />
       <option name="useCustomRunCommand" value="false" />
       <option name="customRunCommand" value="" />
-      <RunnerSettings RunnerId="PyDebugRunner" />
-      <RunnerSettings RunnerId="PythonCover" />
-      <RunnerSettings RunnerId="PythonRunner" />
-      <ConfigurationWrapper RunnerId="PyDebugRunner" />
-      <ConfigurationWrapper RunnerId="PythonCover" />
-      <ConfigurationWrapper RunnerId="PythonRunner" />
+      <method />
+    </configuration>
+    <configuration default="true" type="tests" factoryName="Doctests">
+      <option name="INTERPRETER_OPTIONS" value="" />
+      <option name="PARENT_ENVS" value="true" />
+      <envs />
+      <option name="SDK_HOME" value="" />
+      <option name="WORKING_DIRECTORY" value="" />
+      <option name="IS_MODULE_SDK" value="false" />
+      <module name="DjangoUeditor" />
+      <EXTENSION ID="PythonCoverageRunConfigurationExtension" enabled="false" sample_coverage="true" runner="coverage.py" />
+      <option name="SCRIPT_NAME" value="" />
+      <option name="CLASS_NAME" value="" />
+      <option name="METHOD_NAME" value="" />
+      <option name="FOLDER_NAME" value="" />
+      <option name="TEST_TYPE" value="TEST_SCRIPT" />
+      <option name="PATTERN" value="" />
+      <option name="USE_PATTERN" value="false" />
       <method />
     </configuration>
     <list size="1">
@@ -338,6 +368,11 @@
       <created>1344652076173</created>
       <updated>1344652076173</updated>
     </task>
+    <task id="LOCAL-00001" summary="support django 1.3">
+      <created>1346127105141</created>
+      <updated>1346127105141</updated>
+    </task>
+    <option name="localTasksCounter" value="2" />
     <servers />
   </component>
   <component name="TodoView" selected-index="0">
@@ -364,20 +399,21 @@
     <frame x="-8" y="-8" width="1382" height="744" extended-state="6" />
     <editor active="true" />
     <layout>
-      <window_info id="Data Sources" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32954547" sideWeight="0.60032105" order="3" side_tool="false" content_ui="tabs" />
-      <window_info id="Changes" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
+      <window_info id="Data Sources" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32954547" sideWeight="0.7314974" order="3" side_tool="false" content_ui="tabs" />
+      <window_info id="Changes" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32874355" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
       <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32744783" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
-      <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="true" content_ui="tabs" />
-      <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.28257576" sideWeight="0.71428573" order="0" side_tool="false" content_ui="combo" />
-      <window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4061962" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
+      <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.21742424" sideWeight="0.19449225" order="1" side_tool="true" content_ui="tabs" />
+      <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22121212" sideWeight="0.59380376" order="0" side_tool="false" content_ui="combo" />
+      <window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.4061962" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
       <window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="2" side_tool="true" content_ui="tabs" />
       <window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
-      <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.2857143" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
-      <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
+      <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.2685026" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
+      <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32874355" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
       <window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
       <window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
       <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
-      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
+      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32874355" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
+      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32874355" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
       <window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
       <window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
@@ -420,7 +456,7 @@
     <option name="SHOW_VCS_ERROR_NOTIFICATIONS" value="true" />
     <option name="FORCE_NON_EMPTY_COMMENT" value="false" />
     <option name="CLEAR_INITIAL_COMMIT_MESSAGE" value="false" />
-    <option name="LAST_COMMIT_MESSAGE" />
+    <option name="LAST_COMMIT_MESSAGE" value="support django 1.3" />
     <option name="MAKE_NEW_CHANGELIST_ACTIVE" value="true" />
     <option name="OPTIMIZE_IMPORTS_BEFORE_PROJECT_COMMIT" value="false" />
     <option name="CHECK_FILES_UP_TO_DATE_BEFORE_COMMIT" value="false" />
@@ -433,82 +469,96 @@
     <option name="UPDATE_GROUP_BY_CHANGELIST" value="false" />
     <option name="SHOW_FILE_HISTORY_AS_TREE" value="false" />
     <option name="FILE_HISTORY_SPLITTER_PROPORTION" value="0.6" />
+    <MESSAGE value="support django 1.3" />
   </component>
   <component name="XDebuggerManager">
-    <breakpoint-manager>
-      <breakpoints>
-        <line-breakpoint enabled="true" type="python-line">
-          <url>file://$PROJECT_DIR$/DjangoUeditor/utils.py</url>
-        </line-breakpoint>
-      </breakpoints>
-    </breakpoint-manager>
+    <breakpoint-manager />
   </component>
   <component name="editorHistoryManager">
-    <entry file="file://$APPLICATION_HOME_DIR$/helpers/pydev/pydevd.py">
+    <entry file="file://$PROJECT_DIR$/DjangoUeditor/urls.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="173" column="0" selection-start="6643" selection-end="6697" vertical-scroll-proportion="0.3313783" />
+        <state line="6" column="0" selection-start="173" selection-end="173" vertical-scroll-proportion="0.36263737" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DjangoUeditor/models.py">
+    <entry file="file://$PROJECT_DIR$/DjangoUeditor/views.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="3" column="0" selection-start="102" selection-end="102" vertical-scroll-proportion="0.0" />
+        <state line="105" column="35" selection-start="3791" selection-end="3791" vertical-scroll-proportion="5.9095745" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DUSite/urls.py">
+    <entry file="file://$PROJECT_DIR$/TestApp/tests.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="17" column="52" selection-start="610" selection-end="610" vertical-scroll-proportion="-0.053691275" />
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DjangoUeditor/widgets.py">
+    <entry file="file://$PROJECT_DIR$/DjangoUeditor/utils.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="3" column="59" selection-start="131" selection-end="131" vertical-scroll-proportion="0.0" />
+        <state line="11" column="21" selection-start="328" selection-end="328" vertical-scroll-proportion="-5.65873" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DjangoUeditor/urls.py">
+    <entry file="file://$PROJECT_DIR$/DjangoUeditor/settings.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="1" column="0" selection-start="14" selection-end="14" vertical-scroll-proportion="0.06896552" />
+        <state line="49" column="7" selection-start="1880" selection-end="1880" vertical-scroll-proportion="0.0" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DjangoUeditor/utils.py">
+    <entry file="file://$PROJECT_DIR$/debug.log">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="21" column="6" selection-start="645" selection-end="645" vertical-scroll-proportion="0.41379312">
-          <folding />
-        </state>
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0" />
       </provider>
     </entry>
-    <entry file="file://D:/Python27/Lib/site-packages/django/core/handlers/wsgi.py">
+    <entry file="file://$PROJECT_DIR$/DUSite/settings.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="248" column="0" selection-start="8311" selection-end="8311" vertical-scroll-proportion="0.31045753" />
+        <state line="123" column="12" selection-start="4504" selection-end="4511" vertical-scroll-proportion="7.0103626" />
+      </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/readme.txt">
+      <provider selected="true" editor-type-id="text-editor">
+        <state line="41" column="29" selection-start="1308" selection-end="1308" vertical-scroll-proportion="0.5699482" />
       </provider>
     </entry>
     <entry file="file://D:/Python27/Lib/site-packages/django/core/handlers/base.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="193" column="0" selection-start="9119" selection-end="9119" vertical-scroll-proportion="0.31045753" />
+        <state line="110" column="0" selection-start="4677" selection-end="4677" vertical-scroll-proportion="0.33333334" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/TestApp/models.py">
+    <entry file="file://D:/Python27/Lib/site-packages/django/forms/models.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="8" column="28" selection-start="254" selection-end="254" vertical-scroll-proportion="0.503268" />
+        <state line="224" column="6" selection-start="8641" selection-end="8641" vertical-scroll-proportion="0.3322884" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/readme.txt">
+    <entry file="file://$PROJECT_DIR$/TestApp/forms.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="85" column="13" selection-start="2965" selection-end="2965" vertical-scroll-proportion="0.0" />
+        <state line="6" column="30" selection-start="223" selection-end="223" vertical-scroll-proportion="0.0" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DUSite/settings.py">
+    <entry file="file://$PROJECT_DIR$/DUSite/templates/test.html">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="160" column="20" selection-start="5606" selection-end="5606" vertical-scroll-proportion="0.0" />
+        <state line="10" column="0" selection-start="231" selection-end="231" vertical-scroll-proportion="0.0">
+          <folding />
+        </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DjangoUeditor/views.py">
+    <entry file="file://$PROJECT_DIR$/TestApp/models.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="135" column="49" selection-start="5076" selection-end="5076" vertical-scroll-proportion="0.0" />
+        <state line="10" column="37" selection-start="329" selection-end="329" vertical-scroll-proportion="0.0" />
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/DjangoUeditor/settings.py">
+    <entry file="file://$PROJECT_DIR$/TestApp/views.py">
+      <provider selected="true" editor-type-id="text-editor">
+        <state line="28" column="52" selection-start="909" selection-end="909" vertical-scroll-proportion="0.0">
+          <folding />
+        </state>
+      </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/DjangoUeditor/widgets.py">
+      <provider selected="true" editor-type-id="text-editor">
+        <state line="35" column="0" selection-start="1334" selection-end="1334" vertical-scroll-proportion="0.0">
+          <folding />
+        </state>
+      </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/DjangoUeditor/models.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="25" column="47" selection-start="1215" selection-end="1215" vertical-scroll-proportion="0.040590405">
+        <state line="24" column="18" selection-start="1013" selection-end="1013" vertical-scroll-proportion="0.35947713">
           <folding />
         </state>
       </provider>

+ 1 - 1
DUSite/settings.py

@@ -15,7 +15,7 @@ PROJECT_PATH = os.path.abspath(os.path.dirname(__file__))
 DATABASES = {
     'default': {
         'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
-        'NAME': PROJECT_PATH+'/test.db',                      # Or path to database file if using sqlite3.
+        'NAME':os.path.join(PROJECT_PATH,'test.db').replace("\\","/"),                      # Or path to database file if using sqlite3.
         'USER': '',                      # Not used with sqlite3.
         'PASSWORD': '',                  # Not used with sqlite3.
         'HOST': '',                      # Set to empty string for localhost. Not used with sqlite3.

BIN
DUSite/test.db


+ 1 - 1
DjangoUeditor/urls.py

@@ -2,7 +2,7 @@
 from django import VERSION
 if VERSION[0:2]>(1,3):
     from django.conf.urls import patterns, url
-else: 
+else:
     from django.conf.urls.defaults import patterns, url
 
 from DjangoUeditor.views import UploadFile,ImageManager,RemoteCatchImage,SearchMovie

+ 1 - 1
DjangoUeditor/utils.py

@@ -4,7 +4,7 @@
 def FixFilePath(OutputPath):
     if callable(OutputPath):
         try:
-            OutputPath=OutputPath()
+            OutputPath=OutputPath(modelrow)
         except Exception:
             OutputPath=""
     if len(OutputPath)>0:

+ 3 - 0
TestApp/models.py

@@ -3,8 +3,11 @@
 from django.db import models
 from DjangoUeditor.models import UEditorField
 
+
 class Blog(models.Model):
     Name=models.CharField('姓名',max_length=100,blank=True)
     Description=models.TextField('描述',blank=True)
     ImagePath=models.CharField('图片目录',max_length=100,blank=True)
     Content=UEditorField('内容',height=200,width=500,default='test',imagePath="aaa/",imageManagerPath="bb",toolbars="mini",options={"elementPathEnabled":True},filePath='bb',blank=True)
+
+

+ 1 - 1
TestApp/views.py

@@ -26,7 +26,7 @@ def TestUEditorModel(request):
     else:
         try:
             M=Blog.objects.get(pk=1)
-            form = TestUeditorModelForm(model=M)
+            form = TestUeditorModelForm(instance= M)
         except Exception:
             form = TestUeditorModelForm(
                 initial={'Description': '测试'}