"userparams":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t71.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"pkey":0,
"logicname":"模块名称",
"majorfield":0,
"deftype":2,
"allowempty":1,
"fkey":0,
"formulaformat":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t51.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"formulaformat":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t71.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"querycode":"SELECT\nt1.`ACTIVATEDCOUNT`,\nt1.`ACTIVATEDDATE`,\nt1.`ASSIGNEDDATE`,\nt1.`ASSIGNEDTO`,\nt1.`BRANCH`,\nt21.`NAME` AS `BRANCHNAME`,\nt1.`BROWSER`,\nt1.`CASE`,\nt41.`TITLE` AS `CASENAME`,\nt1.`CASEVERSION`,\nt1.`CLOSEDBY`,\nt1.`CLOSEDDATE`,\nt1.`COLOR`,\nt1.`CONFIRMED`,\nt1.`DEADLINE`,\n(case when t1.deadline is null or t1.deadline = '0000-00-00' or t1.deadline = '1970-01-01' then '' when t1.`status` ='active' and t1.deadline <DATE_FORMAT(now(),'%y-%m-%d') then CONCAT_WS('','延期',TIMESTAMPDIFF(DAY, t1.deadline, now()),'天') else '' end) AS `DELAY`,\n( CASE WHEN t1.deadline IS NULL OR t1.deadline = '0000-00-00' OR t1.deadline = '1970-01-01' THEN '' WHEN t1.`status` = 'resolved' AND t1.deadline < DATE_FORMAT( t1.resolvedDate, '%y-%m-%d' ) THEN CONCAT_WS( '', '延期', TIMESTAMPDIFF( DAY, t1.deadline, t1.resolvedDate ), '天' ) ELSE '' END ) AS `DELAYRESOLVE`,\nt1.`DELETED`,\nt1.`DUPLICATEBUG`,\nt1.`ENTRY`,\nt1.`FOUND`,\nt1.`HARDWARE`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LINES`,\nt1.`LINKBUG`,\nt1.`MAILTO`,\n'' AS `MAILTOPK`,\nt1.`MODULE`,\nt71.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t51.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBUILD`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`OS`,\n(case when t1.DEADLINE = '0000-00-00' then 0 else datediff(t1.deadline, now() ) end) AS `OVERDUEBUGS`,\nt1.`PLAN`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt11.`NAME` AS `PRODUCTNAME`,\nt1.`PROJECT`,\nt51.`NAME` AS `PROJECTNAME`,\nt1.`REPO`,\nt1.`REPOTYPE`,\nt1.`RESOLUTION`,\nt1.`RESOLVEDBUILD`,\nt1.`RESOLVEDBY`,\nt1.`RESOLVEDDATE`,\nt1.`RESULT`,\nt1.`SEVERITY`,\nt1.`STATUS`,\nt1.`STEPS`,\nt1.`STORY`,\nt61.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TASK`,\nt31.`NAME` AS `TASKNAME`,\nt1.`TESTTASK`,\nt1.`TITLE`,\nt1.`TOSTORY`,\nt1.`TOTASK`,\nt1.`TYPE`,\nt1.`V1`,\nt1.`V2`\nFROM `zt_bug` t1 \nLEFT JOIN `zt_product` t11 ON t1.`PRODUCT` = t11.`ID` \nLEFT JOIN `zt_branch` t21 ON t1.`BRANCH` = t21.`ID` \nLEFT JOIN `zt_task` t31 ON t1.`TASK` = t31.`ID` \nLEFT JOIN `zt_case` t41 ON t1.`CASE` = t41.`ID` \nLEFT JOIN `zt_project` t51 ON t1.`PROJECT` = t51.`ID` \nLEFT JOIN `zt_story` t61 ON t1.`STORY` = t61.`ID` \nLEFT JOIN `zt_module` t71 ON t1.`MODULE` = t71.`ID` \n",
"querycode":"SELECT\nt1.`ACTIVATEDCOUNT`,\nt1.`ACTIVATEDDATE`,\nt1.`ASSIGNEDDATE`,\nt1.`ASSIGNEDTO`,\nt1.`BRANCH`,\nt21.`NAME` AS `BRANCHNAME`,\nt1.`BROWSER`,\nt1.`CASE`,\nt41.`TITLE` AS `CASENAME`,\nt1.`CASEVERSION`,\nt1.`CLOSEDBY`,\nt1.`CLOSEDDATE`,\nt1.`COLOR`,\nt1.`CONFIRMED`,\nt1.`DEADLINE`,\n(case when t1.deadline is null or t1.deadline = '0000-00-00' or t1.deadline = '1970-01-01' then '' when t1.`status` ='active' and t1.deadline <DATE_FORMAT(now(),'%y-%m-%d') then CONCAT_WS('','延期',TIMESTAMPDIFF(DAY, t1.deadline, now()),'天') else '' end) AS `DELAY`,\n( CASE WHEN t1.deadline IS NULL OR t1.deadline = '0000-00-00' OR t1.deadline = '1970-01-01' THEN '' WHEN t1.`status` = 'resolved' AND t1.deadline < DATE_FORMAT( t1.resolvedDate, '%y-%m-%d' ) THEN CONCAT_WS( '', '延期', TIMESTAMPDIFF( DAY, t1.deadline, t1.resolvedDate ), '天' ) ELSE '' END ) AS `DELAYRESOLVE`,\nt1.`DELETED`,\nt1.`DUPLICATEBUG`,\nt1.`ENTRY`,\nt1.`FOUND`,\nt1.`HARDWARE`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LINES`,\nt1.`LINKBUG`,\nt1.`MAILTO`,\n'' AS `MAILTOPK`,\nt1.`MODULE`,\nt71.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t71.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBUILD`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`OS`,\n(case when t1.DEADLINE = '0000-00-00' then 0 else datediff(t1.deadline, now() ) end) AS `OVERDUEBUGS`,\nt1.`PLAN`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt11.`NAME` AS `PRODUCTNAME`,\nt1.`PROJECT`,\nt51.`NAME` AS `PROJECTNAME`,\nt1.`REPO`,\nt1.`REPOTYPE`,\nt1.`RESOLUTION`,\nt1.`RESOLVEDBUILD`,\nt1.`RESOLVEDBY`,\nt1.`RESOLVEDDATE`,\nt1.`RESULT`,\nt1.`SEVERITY`,\nt1.`STATUS`,\nt1.`STEPS`,\nt1.`STORY`,\nt61.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TASK`,\nt31.`NAME` AS `TASKNAME`,\nt1.`TESTTASK`,\nt1.`TITLE`,\nt1.`TOSTORY`,\nt1.`TOTASK`,\nt1.`TYPE`,\nt1.`V1`,\nt1.`V2`\nFROM `zt_bug` t1 \nLEFT JOIN `zt_product` t11 ON t1.`PRODUCT` = t11.`ID` \nLEFT JOIN `zt_branch` t21 ON t1.`BRANCH` = t21.`ID` \nLEFT JOIN `zt_task` t31 ON t1.`TASK` = t31.`ID` \nLEFT JOIN `zt_case` t41 ON t1.`CASE` = t41.`ID` \nLEFT JOIN `zt_project` t51 ON t1.`PROJECT` = t51.`ID` \nLEFT JOIN `zt_story` t61 ON t1.`STORY` = t61.`ID` \nLEFT JOIN `zt_module` t71 ON t1.`MODULE` = t71.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -135,7 +135,7 @@
"ordervalue":32,
"psdedqcodeexpname":"MODULENAME"
},{
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t51.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t71.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"formulaformat":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"formulaformat":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -103,7 +103,7 @@
"ordervalue":23,
"psdedqcodeexpname":"MODULENAME"
},{
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -103,7 +103,7 @@
"ordervalue":23,
"psdedqcodeexpname":"MODULENAME"
},{
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -103,7 +103,7 @@
"ordervalue":23,
"psdedqcodeexpname":"MODULENAME"
},{
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRECONDITION`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"querycode":"SELECT\nt1.`AUTO`,\nt1.`BRANCH`,\nt1.`COLOR`,\nt1.`DELETED`,\nt1.`FRAME`,\nt1.`FREQUENCY`,\nt1.`FROMBUG`,\nt1.`FROMCASEID`,\nt1.`FROMCASEVERSION`,\nt1.`HOWRUN`,\nt1.`ID`,\n0 AS `ISFAVORITES`,\nt1.`KEYWORDS`,\nt1.`LASTEDITEDBY`,\nt1.`LASTEDITEDDATE`,\nt1.`LASTRUNDATE`,\nt1.`LASTRUNNER`,\nt1.`LASTRUNRESULT`,\n(case when t1.`LASTRUNRESULT` = '' or t1.`LASTRUNRESULT` is null then 'no' else t1.`LASTRUNRESULT` end) AS `LASTRUNRESULT1`,\nt1.`LIB`,\nt11.`NAME` AS `LIBNAME`,\nt1.`LINKCASE`,\nt1.`MODULE`,\nt31.`NAME` AS `MODULENAME`,\n(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end) AS `MODULENAME1`,\nt1.`OPENEDBY`,\nt1.`OPENEDDATE`,\nt1.`ORDER`,\nt1.`PATH`,\nt1.`PRECONDITION`,\nt1.`PRI`,\nt1.`PRODUCT`,\nt41.`NAME` AS `PRODUCTNAME`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` ) AS `RESULTCNT`,\n(SELECT COUNT(1) FROM zt_testresult WHERE `case` = t1.`ID` and caseResult in('fail','blocked') ) AS `RESULTFALICNT`,\nt1.`REVIEWEDBY`,\nt1.`REVIEWEDDATE`,\nt1.`SCRIPTEDBY`,\nt1.`SCRIPTEDDATE`,\nt1.`SCRIPTLOCATION`,\nt1.`SCRIPTSTATUS`,\nt1.`STAGE`,\nt1.`STATUS`,\n(case when t1.storyVersion < t21.version and t21.`status` <> 'changed' then 'storychange' else t1.`status` end ) AS `STATUS1`,\n(SELECT COUNT(1) FROM zt_casestep WHERE `case` = t1.`ID` AND version = t1.`VERSION` ) AS `STEPCNT`,\nt1.`STORY`,\nt21.`TITLE` AS `STORYNAME`,\nt1.`STORYVERSION`,\nt1.`SUBSTATUS`,\nt1.`TITLE`,\n(SELECT COUNT(1) FROM zt_bug WHERE `case` = t1.`ID` ) AS `TOBUGCNT`,\nt1.`TYPE`,\nt1.`VERSION`\nFROM `zt_case` t1 \nLEFT JOIN `zt_testsuite` t11 ON t1.`LIB` = t11.`ID` \nLEFT JOIN `zt_story` t21 ON t1.`STORY` = t21.`ID` \nLEFT JOIN `zt_module` t31 ON t1.`MODULE` = t31.`ID` \nLEFT JOIN `zt_product` t41 ON t1.`PRODUCT` = t41.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -99,7 +99,7 @@
"ordervalue":23,
"psdedqcodeexpname":"MODULENAME"
},{
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t11.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"expcode":"(case when t1.module = '0' then '/' else (SELECT GROUP_CONCAT( tt.NAME SEPARATOR '>' ) FROM zt_module tt WHERE FIND_IN_SET( tt.id, t31.path ) AND tt.type = 'story' GROUP BY tt.root limit 0,1) end)",
"formulaformat":"case when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\ncase when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end AS `DELAY`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\nt1.`STATUS`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -27,60 +27,68 @@
"ordervalue":3,
"psdedqcodeexpname":"BUGCNT"
},{
"expcode":"t1.`DELETED`",
"expcode":"case when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end",
"expcode":"(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end)",
"ordervalue":7,
"ordervalue":8,
"psdedqcodeexpname":"ENDSTR"
},{
"expcode":"(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )",
"ordervalue":8,
"ordervalue":9,
"psdedqcodeexpname":"ESTIMATECNT"
},{
"expcode":"(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end)",
"ordervalue":9,
"ordervalue":10,
"psdedqcodeexpname":"FUTURE"
},{
"expcode":"t1.`ID`",
"ordervalue":10,
"ordervalue":11,
"psdedqcodeexpname":"ID"
},{
"expcode":"(case when t1.`end` > now() then '0' else '1' end)",
"ordervalue":11,
"ordervalue":12,
"psdedqcodeexpname":"ISEXPIRED"
},{
"expcode":"t1.`PARENT`",
"ordervalue":12,
"ordervalue":13,
"psdedqcodeexpname":"PARENT"
},{
"expcode":"t11.`TITLE`",
"ordervalue":13,
"ordervalue":14,
"psdedqcodeexpname":"PARENTNAME"
},{
"expcode":"t1.`PRODUCT`",
"ordervalue":14,
"ordervalue":15,
"psdedqcodeexpname":"PRODUCT"
},{
"expcode":"t1.`STATUS`",
"ordervalue":16,
"psdedqcodeexpname":"STATUS"
},{
"expcode":"(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end)",
"ordervalue":15,
"ordervalue":17,
"psdedqcodeexpname":"STATUSS"
},{
"expcode":"((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ))",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\ncase when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end AS `DELAY`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\nt1.`STATUS`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -27,60 +27,68 @@
"ordervalue":3,
"psdedqcodeexpname":"BUGCNT"
},{
"expcode":"t1.`DELETED`",
"expcode":"case when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end",
"expcode":"(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end)",
"ordervalue":7,
"ordervalue":8,
"psdedqcodeexpname":"ENDSTR"
},{
"expcode":"(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )",
"ordervalue":8,
"ordervalue":9,
"psdedqcodeexpname":"ESTIMATECNT"
},{
"expcode":"(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end)",
"ordervalue":9,
"ordervalue":10,
"psdedqcodeexpname":"FUTURE"
},{
"expcode":"t1.`ID`",
"ordervalue":10,
"ordervalue":11,
"psdedqcodeexpname":"ID"
},{
"expcode":"(case when t1.`end` > now() then '0' else '1' end)",
"ordervalue":11,
"ordervalue":12,
"psdedqcodeexpname":"ISEXPIRED"
},{
"expcode":"t1.`PARENT`",
"ordervalue":12,
"ordervalue":13,
"psdedqcodeexpname":"PARENT"
},{
"expcode":"t11.`TITLE`",
"ordervalue":13,
"ordervalue":14,
"psdedqcodeexpname":"PARENTNAME"
},{
"expcode":"t1.`PRODUCT`",
"ordervalue":14,
"ordervalue":15,
"psdedqcodeexpname":"PRODUCT"
},{
"expcode":"t1.`STATUS`",
"ordervalue":16,
"psdedqcodeexpname":"STATUS"
},{
"expcode":"(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end)",
"ordervalue":15,
"ordervalue":17,
"psdedqcodeexpname":"STATUSS"
},{
"expcode":"((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ))",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\ncase when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end AS `DELAY`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\nt1.`STATUS`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -27,60 +27,68 @@
"ordervalue":3,
"psdedqcodeexpname":"BUGCNT"
},{
"expcode":"t1.`DELETED`",
"expcode":"case when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end",
"expcode":"(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end)",
"ordervalue":7,
"ordervalue":8,
"psdedqcodeexpname":"ENDSTR"
},{
"expcode":"(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )",
"ordervalue":8,
"ordervalue":9,
"psdedqcodeexpname":"ESTIMATECNT"
},{
"expcode":"(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end)",
"ordervalue":9,
"ordervalue":10,
"psdedqcodeexpname":"FUTURE"
},{
"expcode":"t1.`ID`",
"ordervalue":10,
"ordervalue":11,
"psdedqcodeexpname":"ID"
},{
"expcode":"(case when t1.`end` > now() then '0' else '1' end)",
"ordervalue":11,
"ordervalue":12,
"psdedqcodeexpname":"ISEXPIRED"
},{
"expcode":"t1.`PARENT`",
"ordervalue":12,
"ordervalue":13,
"psdedqcodeexpname":"PARENT"
},{
"expcode":"t11.`TITLE`",
"ordervalue":13,
"ordervalue":14,
"psdedqcodeexpname":"PARENTNAME"
},{
"expcode":"t1.`PRODUCT`",
"ordervalue":14,
"ordervalue":15,
"psdedqcodeexpname":"PRODUCT"
},{
"expcode":"t1.`STATUS`",
"ordervalue":16,
"psdedqcodeexpname":"STATUS"
},{
"expcode":"(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end)",
"ordervalue":15,
"ordervalue":17,
"psdedqcodeexpname":"STATUSS"
},{
"expcode":"((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ))",
"querycode":"SELECT t1.`BEGIN`, ( CASE WHEN t1.`begin` = '2030-01-01' THEN '待定' ELSE t1.`begin` END ) AS `BEGINSTR`, t1.`BRANCH`, ( ( SELECT count( t.id ) FROM zt_bug t WHERE ( t.plan = t1.id OR ( t.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) ) ) AND t.deleted = '0' ) ) AS `BUGCNT`, t1.`DELETED`, t1.`END`, ( CASE WHEN t1.`end` = '2030-01-01' THEN '待定' ELSE t1.`end` END ) AS `ENDSTR`, ( SELECT sum( t.estimate ) FROM zt_story t WHERE ( t.plan = t1.id OR ( t.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) ) ) AND t.deleted = '0' ) AS `ESTIMATECNT`, ( CASE WHEN t1.`begin` = '2030-01-01' OR t1.`end` = '2030-01-01' THEN 'on' ELSE '' END ) AS `FUTURE`, t1.`ID` , ( CASE WHEN t1.`end` > now( ) THEN '0' ELSE '1' END ) AS `ISEXPIRED`, t1.`PARENT`, t11.`TITLE` AS `PARENTNAME`, t1.`PRODUCT`, ( CASE WHEN t1.parent = - 1 THEN 'parent' WHEN t1.parent > 0 THEN 'chlid' ELSE 'normal' END ) AS `STATUSS`, ( ( SELECT COUNT( t.id ) FROM zt_story t WHERE ( t.plan = t1.id OR ( t.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) ) ) AND t.deleted = '0' ) ) AS `STORYCNT`, ((SELECT COUNT(t.id) from zt_task t where ( t.plan=t1.id OR ( t.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) ) ) )) AS `TASKSCNT`, ((SELECT COUNT(t.id) from zt_task t where ( t.plan=t1.id OR ( t.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) ) ) and t.`status` = 'done' )) AS `FINISHEDTASKSCNT`, ((SELECT COUNT(t.id) from zt_task t where ( t.plan=t1.id OR ( t.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) ) ) and t.`status` in ('doing','wait' ,'pause') )) AS `UNFINISHEDTASKSCNT`, ((SELECT COUNT(t.id) from zt_task t where ( t.plan=t1.id OR ( t.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) ) ) and t.`status` in ('wait','doing','pause') and t.deadline != '0000-00-00' and t.deadline != '1970-01-01' and t.deadline <DATE_FORMAT(now(),'%y-%m-%d') )) AS `DELAYTASKSCNT`, t1.`TITLE` FROM `zt_PRODUCTPLAN` t1 LEFT JOIN `zt_PRODUCTPLAN` t11 ON t1.`PARENT` = t11.`ID`",
"querycode":"SELECT\ncase when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end as delay,\n\tt1.`BEGIN`,\n\t( CASE WHEN t1.`begin` = '2030-01-01' THEN '待定' ELSE t1.`begin` END ) AS `BEGINSTR`,\n\tt1.`BRANCH`,\n\t(\n\t(\nSELECT\n\tcount( t.id ) \nFROM\n\tzt_bug t \nWHERE\n\t(\n\tt.plan = t1.id \n\tOR (\n\tt.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) \n\t) \n\t) \n\tAND t.deleted = '0' \n\t) \n\t) AS `BUGCNT`,\n\tt1.`DELETED`,\n\tt1.`END`,\n\t( CASE WHEN t1.`end` = '2030-01-01' THEN '待定' ELSE t1.`end` END ) AS `ENDSTR`,\n\t(\nSELECT\n\tsum( t.estimate ) \nFROM\n\tzt_story t \nWHERE\n\t(\n\tt.plan = t1.id \n\tOR (\n\tt.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) \n\t) \n\t) \n\tAND t.deleted = '0' \n\t) AS `ESTIMATECNT`,\n\t( CASE WHEN t1.`begin` = '2030-01-01' OR t1.`end` = '2030-01-01' THEN 'on' ELSE '' END ) AS `FUTURE`,\n\tt1.`ID`,\n\t( CASE WHEN t1.`end` > now( ) THEN '0' ELSE '1' END ) AS `ISEXPIRED`,\n\tt1.`PARENT`,\n\tt11.`TITLE` AS `PARENTNAME`,\n\tt1.`PRODUCT`,\n\t( CASE WHEN t1.parent = - 1 THEN 'parent' WHEN t1.parent > 0 THEN 'chlid' ELSE 'normal' END ) AS `STATUSS`,\n\t(\n\t(\nSELECT\n\tCOUNT( t.id ) \nFROM\n\tzt_story t \nWHERE\n\t(\n\tt.plan = t1.id \n\tOR (\n\tt.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) \n\t) \n\t) \n\tAND t.deleted = '0' \n\t) \n\t) AS `STORYCNT`,\n\t(\n\t(\nSELECT\n\tCOUNT( t.id ) \nFROM\n\tzt_task t \nWHERE\n\t(\n\tt.plan = t1.id \n\tOR (\n\tt.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) \n\t) \n\t) \n\t) \n\t) AS `TASKSCNT`,\n\t(\n\t(\nSELECT\n\tCOUNT( t.id ) \nFROM\n\tzt_task t \nWHERE\n\t(\n\tt.plan = t1.id \n\tOR (\n\tt.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) \n\t) \n\t) \n\tAND t.`status` = 'done' \n\t) \n\t) AS `FINISHEDTASKSCNT`,\n\t(\n\t(\nSELECT\n\tCOUNT( t.id ) \nFROM\n\tzt_task t \nWHERE\n\t(\n\tt.plan = t1.id \n\tOR (\n\tt.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) \n\t) \n\t) \n\tAND t.`status` IN ( 'doing', 'wait', 'pause' ) \n\t) \n\t) AS `UNFINISHEDTASKSCNT`,\n\t(\n\t(\nSELECT\n\tCOUNT( t.id ) \nFROM\n\tzt_task t \nWHERE\n\t(\n\tt.plan = t1.id \n\tOR (\n\tt.plan IN ( SELECT t2.id FROM zt_productplan t2 WHERE t2.parent = t1.id AND t2.deleted = '0' ) \n\t) \n\t) \n\tAND t.`status` IN ( 'wait', 'doing', 'pause' ) \n\tAND t.deadline != '0000-00-00' \n\tAND t.deadline != '1970-01-01' \n\tAND t.deadline < DATE_FORMAT( now( ), '%y-%m-%d' ) \n\t) \n\t) AS `DELAYTASKSCNT`,\n\tt1.`TITLE`,\n\tIFNULL(t2.LeftEstimate,0) as leftestimate,\n\tIFNULL(t2.ConsumedEstimate,0) as consumedestimate ,\n t1.`STATUS`\nFROM\n\t`zt_PRODUCTPLAN` t1\n\tLEFT JOIN `zt_PRODUCTPLAN` t11 ON t1.`PARENT` = t11.`ID`\n\tLEFT JOIN (\nSELECT\n\tSUM( t.LeftEstimate ) AS LeftEstimate,\n\tSUM( t.ConsumedEstimate ) AS ConsumedEstimate,\n\tt.plan \nFROM\n\t(\nSELECT\n\tt1.task,\n\tSUM( t1.LEFT ) AS LeftEstimate,\n\tSUM( t1.consumed ) AS ConsumedEstimate,\n\tt2.NAME,\n\tt2.plan \nFROM\n\tzt_taskestimate t1\n\tLEFT JOIN zt_task t2 ON t1.task = t2.id \nGROUP BY\n\tt1.task \n\t) t \nWHERE\n\tt.plan > 0 \nGROUP BY\n\tt.plan \n\t) t2 ON t1.id = t2.plan",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\ncase when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end AS `DELAY`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\nt1.`STATUS`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -27,60 +27,68 @@
"ordervalue":3,
"psdedqcodeexpname":"BUGCNT"
},{
"expcode":"t1.`DELETED`",
"expcode":"case when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end",
"expcode":"(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end)",
"ordervalue":7,
"ordervalue":8,
"psdedqcodeexpname":"ENDSTR"
},{
"expcode":"(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )",
"ordervalue":8,
"ordervalue":9,
"psdedqcodeexpname":"ESTIMATECNT"
},{
"expcode":"(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end)",
"ordervalue":9,
"ordervalue":10,
"psdedqcodeexpname":"FUTURE"
},{
"expcode":"t1.`ID`",
"ordervalue":10,
"ordervalue":11,
"psdedqcodeexpname":"ID"
},{
"expcode":"(case when t1.`end` > now() then '0' else '1' end)",
"ordervalue":11,
"ordervalue":12,
"psdedqcodeexpname":"ISEXPIRED"
},{
"expcode":"t1.`PARENT`",
"ordervalue":12,
"ordervalue":13,
"psdedqcodeexpname":"PARENT"
},{
"expcode":"t11.`TITLE`",
"ordervalue":13,
"ordervalue":14,
"psdedqcodeexpname":"PARENTNAME"
},{
"expcode":"t1.`PRODUCT`",
"ordervalue":14,
"ordervalue":15,
"psdedqcodeexpname":"PRODUCT"
},{
"expcode":"t1.`STATUS`",
"ordervalue":16,
"psdedqcodeexpname":"STATUS"
},{
"expcode":"(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end)",
"ordervalue":15,
"ordervalue":17,
"psdedqcodeexpname":"STATUSS"
},{
"expcode":"((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ))",
"querycode":"SELECT\n\tt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\n\tt1.`BRANCH`,\n\tt1.`DELETED`,\n\tt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n\tt1.`ID`,\n\tt1.`PARENT`,\n\tt11.`TITLE` AS `PARENTNAME`,\n\tt1.`PRODUCT`,\n\t(CONCAT(t31.`name`,'/',t1.title,'[',case when t1.`begin` is not null then t1.`begin` else '' end,'~',case when t1.`end` is not null then t1.`end` else '' end,']')) as `TITLE` \nFROM\n\t`zt_productplan` t1\n\tLEFT JOIN zt_productplan t11 ON t1.PARENT = t11.ID\n\tLEFT JOIN zt_product t31 ON t1.product = t31.id \n\tLEFT JOIN zt_projectproduct t21 ON t31.id = t21.product and t1.id = t21.plan",
"querycode":"SELECT\tt1.`BEGIN`, (case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`, \tt1.`BRANCH`, \tt1.`DELETED`, \tt1.`END`, (case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`, \tt1.`ID`, \tt1.`PARENT`, \tt11.`TITLE` AS `PARENTNAME`, \tt1.`PRODUCT`, \t(CONCAT(t31.`name`,'/',t1.title,'[',case when t1.`begin` is not null then t1.`begin` else '' end,'~',case when t1.`end` is not null then t1.`end` else '' end,']')) as `TITLE` FROM \t`zt_productplan` t1 \tLEFT JOIN zt_productplan t11 ON t1.PARENT = t11.ID \tLEFT JOIN zt_product t31 ON t1.product = t31.id \tLEFT JOIN zt_projectproduct t21 ON t31.id = t21.product and t1.id = t21.plan",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\ncase when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end AS `DELAY`,\nt1.`DELETED`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\nt1.`STATUS`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -27,60 +27,68 @@
"ordervalue":3,
"psdedqcodeexpname":"BUGCNT"
},{
"expcode":"t1.`DELETED`",
"expcode":"case when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end",
"expcode":"(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end)",
"ordervalue":7,
"ordervalue":8,
"psdedqcodeexpname":"ENDSTR"
},{
"expcode":"(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )",
"ordervalue":8,
"ordervalue":9,
"psdedqcodeexpname":"ESTIMATECNT"
},{
"expcode":"(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end)",
"ordervalue":9,
"ordervalue":10,
"psdedqcodeexpname":"FUTURE"
},{
"expcode":"t1.`ID`",
"ordervalue":10,
"ordervalue":11,
"psdedqcodeexpname":"ID"
},{
"expcode":"(case when t1.`end` > now() then '0' else '1' end)",
"ordervalue":11,
"ordervalue":12,
"psdedqcodeexpname":"ISEXPIRED"
},{
"expcode":"t1.`PARENT`",
"ordervalue":12,
"ordervalue":13,
"psdedqcodeexpname":"PARENT"
},{
"expcode":"t11.`TITLE`",
"ordervalue":13,
"ordervalue":14,
"psdedqcodeexpname":"PARENTNAME"
},{
"expcode":"t1.`PRODUCT`",
"ordervalue":14,
"ordervalue":15,
"psdedqcodeexpname":"PRODUCT"
},{
"expcode":"t1.`STATUS`",
"ordervalue":16,
"psdedqcodeexpname":"STATUS"
},{
"expcode":"(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end)",
"ordervalue":15,
"ordervalue":17,
"psdedqcodeexpname":"STATUSS"
},{
"expcode":"((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ))",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\nt1.`DELETED`,\nt1.`DESC`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`ORDER`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"querycode":"SELECT\nt1.`BEGIN`,\n(case when t1.`begin` = '2030-01-01' then '待定' else t1.`begin` end) AS `BEGINSTR`,\nt1.`BRANCH`,\n((select count(t.id) FROM zt_bug t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0')) AS `BUGCNT`,\ncase when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end AS `DELAY`,\nt1.`DELETED`,\nt1.`DESC`,\n(to_Days(t1.`END`) - to_Days(t1.`BEGIN`)) AS `DURATION`,\nt1.`END`,\n(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end) AS `ENDSTR`,\n(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ) AS `ESTIMATECNT`,\n(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end) AS `FUTURE`,\nt1.`ID`,\n(case when t1.`end` > now() then '0' else '1' end) AS `ISEXPIRED`,\nt1.`ORDER`,\nt1.`PARENT`,\nt11.`TITLE` AS `PARENTNAME`,\nt1.`PRODUCT`,\nt1.`STATUS`,\n(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end) AS `STATUSS`,\n((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )) AS `STORYCNT`,\nt1.`TITLE`\nFROM `zt_productplan` t1 \nLEFT JOIN `zt_productplan` t11 ON t1.`PARENT` = t11.`ID` \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -19,68 +19,76 @@
"ordervalue":3,
"psdedqcodeexpname":"BUGCNT"
},{
"expcode":"t1.`DELETED`",
"expcode":"case when t1.`end` is null or t1.`end` = '0000-00-00' or t1.`end` = '1970-01-01' then '' when t1.`status` in('wait','doing') and t1.`end` < DATE_FORMAT(NOW(),'%Y-%m-%d') then CONCAT('','延期',TO_DAYS(NOW()) - TO_DAYS(t1.`end`),'天') ELSE '' end",
"expcode":"(case when t1.`end` = '2030-01-01' then '待定' else t1.`end` end)",
"ordervalue":8,
"ordervalue":9,
"psdedqcodeexpname":"ENDSTR"
},{
"expcode":"(select sum(t.estimate) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' )",
"ordervalue":9,
"ordervalue":10,
"psdedqcodeexpname":"ESTIMATECNT"
},{
"expcode":"(case when t1.`begin` = '2030-01-01' or t1.`end` = '2030-01-01' then 'on' else '' end)",
"ordervalue":10,
"ordervalue":11,
"psdedqcodeexpname":"FUTURE"
},{
"expcode":"t1.`ID`",
"ordervalue":11,
"ordervalue":12,
"psdedqcodeexpname":"ID"
},{
"expcode":"(case when t1.`end` > now() then '0' else '1' end)",
"ordervalue":12,
"ordervalue":13,
"psdedqcodeexpname":"ISEXPIRED"
},{
"expcode":"t1.`ORDER`",
"ordervalue":13,
"ordervalue":14,
"psdedqcodeexpname":"ORDER"
},{
"expcode":"t1.`PARENT`",
"ordervalue":14,
"ordervalue":15,
"psdedqcodeexpname":"PARENT"
},{
"expcode":"t11.`TITLE`",
"ordervalue":15,
"ordervalue":16,
"psdedqcodeexpname":"PARENTNAME"
},{
"expcode":"t1.`PRODUCT`",
"ordervalue":16,
"ordervalue":17,
"psdedqcodeexpname":"PRODUCT"
},{
"expcode":"t1.`STATUS`",
"ordervalue":18,
"psdedqcodeexpname":"STATUS"
},{
"expcode":"(case when t1.parent = -1 then 'parent' when t1.parent > 0 then 'chlid' else 'normal' end)",
"ordervalue":17,
"ordervalue":19,
"psdedqcodeexpname":"STATUSS"
},{
"expcode":"((select COUNT(t.id) from zt_story t where (t.plan = t1.id or (t.plan in (select t2.id from zt_productplan t2 where t2.parent = t1.id and t2.deleted = '0')) ) and t.deleted = '0' ))",
"condcode":"t1.assignedTo = #{srf.sessioncontext.srfloginname} or t1.openedBy =#{srf.sessioncontext.srfloginname} or FIND_IN_SET(#{srf.sessioncontext.srfloginname}, t1.finishedList) or t1.closedBy = #{srf.sessioncontext.srfloginname} or t1.finishedBy = #{srf.sessioncontext.srfloginname} or t1.canceledBy = #{srf.sessioncontext.srfloginname}",
"condcode":"(t1.assignedTo = #{srf.sessioncontext.srfloginname} or t1.openedBy =#{srf.sessioncontext.srfloginname} or FIND_IN_SET(#{srf.sessioncontext.srfloginname}, t1.finishedList) or t1.closedBy = #{srf.sessioncontext.srfloginname} or t1.finishedBy = #{srf.sessioncontext.srfloginname} or t1.canceledBy = #{srf.sessioncontext.srfloginname})",
"querycode":"SELECT t1.`ASSIGNEDDATE`, t1.`ASSIGNEDTO`, t1.`CANCELEDBY`, t1.`CANCELEDDATE`, t1.`CLOSEDBY`, t1.`CLOSEDDATE`, t1.`CLOSEDREASON`, t1.`COLOR`, t1.`CONSUMED`, t1.`DELETED`, t1.`ESTIMATE`, (SELECT MIN(ESTSTARTED) FROM `zt_task` WHERE DELETED = '0' AND TYPE = t1.`TYPE` AND PROJECT = t1.`PROJECT` and ESTSTARTED <> '0000-00-00' and estStarted <> '0002-11-30' and estStarted <> '1970-01-01') AS `ESTSTARTED`, (SELECT MAX(DEADLINE) FROM `zt_task` WHERE DELETED = '0' AND TYPE = t1.`TYPE` AND PROJECT = t1.`PROJECT` and DEADLINE <> '0000-00-00' and estStarted <> '0002-11-30' and estStarted <> '1970-01-01') AS `DEADLINE`, (SELECT DATEDIFF(MAX(DEADLINE),MIN(ESTSTARTED)) + 1 FROM `zt_task` WHERE DELETED = '0' AND TYPE = t1.`TYPE` AND PROJECT = t1.`PROJECT` and ESTSTARTED <> '0000-00-00' AND DEADLINE <> '0000-00-00' and estStarted <> '0002-11-30' and estStarted <> '1970-01-01') AS `DURATION`, t1.`FINISHEDBY`, t1.`FINISHEDDATE`, t1.`FROMBUG`, t1.`ID`, t1.`LASTEDITEDBY`, t1.`LASTEDITEDDATE`, t1.`LEFT`, t1.`MODULE`, t21.`NAME` AS `MODULENAME`, t1.`NAME`, t1.`OPENEDBY`, t1.`OPENEDDATE`, t1.`PARENT`, t11.`NAME` AS `PARENTNAME`, t1.`PRI`, t31.`PRODUCT`, t41.`NAME` AS `PRODUCTNAME`, t1.`PROJECT`, t51.`NAME` AS `PROJECTNAME`, t1.`REALSTARTED`, t1.`STATUS`, t1.`STORY`, t31.`TITLE` AS `STORYNAME`, t1.`STORYVERSION`, t1.`SUBSTATUS`, t1.`TYPE`, ( CASE WHEN ( SELECT CASE\t WHEN count( t.`id` ) > 0 THEN 1 ELSE 0 END FROM `zt_team` t WHERE t.`type` = 'task' AND t.`root` = t1.`id` ) = 1 THEN '10' WHEN t1.parent = - 1 THEN'20' WHEN t1.parent = 0 THEN '30' ELSE '40' END) AS `TASKTYPE`, (case when t1.storyVersion < t31.version and t31.`status` <> 'changed' then 'storychange' else t1.`status` end ) as `STATUS1`, (case when t1.`status` = 'wait' then 10 when t1.`status` = 'doing' then 20 when t1.`status` = 'done' then 30 when t1.`status` = 'closed' then 40 when t1.`status` = 'cancel' then 50 else 60 end) as statusorder ,\nt1.`PLAN`,\nt61.`TITLE` AS `PLANNAME` FROM `zt_task` t1 LEFT JOIN zt_task t11 ON t1.PARENT = t11.ID LEFT JOIN zt_module t21 ON t1.MODULE = t21.ID LEFT JOIN zt_story t31 ON t1.STORY = t31.ID LEFT JOIN zt_product t41 ON t31.PRODUCT = t41.ID LEFT JOIN zt_project t51 ON t1.PROJECT = t51.ID LEFT JOIN `zt_productplan` t61 ON t1.`PLAN` = t61.`ID` WHERE t1.DELETED = '0'",
"querycode":"SELECT\nt1.`ACCOUNT`,\nt1.`ASSIGNEDBY`,\nt1.`ASSIGNEDDATE`,\nt1.`ASSIGNEDTO`,\nt1.ASSIGNEDTO AS `ASSIGNEDTOPK`,\nt1.`BEGIN`,\nt1.`CLOSEDBY`,\nt1.`CLOSEDDATE`,\nt1.`CONFIG`,\nt1.`CYCLE`,\nt1.`DATE`,\n(case when t1.`DATE` = '2030-01-01' then '待定' else t1.`DATE` end) AS `DATE1`,\nt1.`DESC`,\nt1.`END`,\nt1.`FINISHEDBY`,\nt1.`FINISHEDDATE`,\nt1.`ID`,\nt1.`IDVALUE`,\nt1.`NAME`,\nt1.`PRI`,\nt1.`PRIVATE`,\nt1.`STATUS`,\nt1.`TYPE`\nFROM `zt_todo` t1 \n",
"querycode":"SELECT\nt1.`ACCOUNT`,\nt1.`ASSIGNEDBY`,\nt1.`ASSIGNEDDATE`,\nt1.`ASSIGNEDTO`,\nt1.ASSIGNEDTO AS `ASSIGNEDTOPK`,\nt1.`BEGIN`,\nt1.`CLOSEDBY`,\nt1.`CLOSEDDATE`,\nt1.`CONFIG`,\nt1.`COST`,\nt1.`CYCLE`,\nt1.`DATE`,\n(case when t1.`DATE` = '2030-01-01' then '待定' else t1.`DATE` end) AS `DATE1`,\nt1.`DESC`,\nt1.`END`,\nt1.`FINISHEDBY`,\nt1.`FINISHEDDATE`,\nt1.`ID`,\nt1.`IDVALUE`,\nt1.`NAME`,\nt1.`PRI`,\nt1.`PRIVATE`,\nt1.`STATUS`,\nt1.`TYPE`\nFROM `zt_todo` t1 \n",
"dbtype":"MYSQL5",
"psdedqcodename":"MySQL5",
"psdedqcodeexps":[{
...
...
@@ -39,60 +39,64 @@
"ordervalue":8,
"psdedqcodeexpname":"CONFIG"
},{
"expcode":"t1.`CYCLE`",
"expcode":"t1.`COST`",
"ordervalue":9,
"psdedqcodeexpname":"COST"
},{
"expcode":"t1.`CYCLE`",
"ordervalue":10,
"psdedqcodeexpname":"CYCLE"
},{
"expcode":"t1.`DATE`",
"ordervalue":10,
"ordervalue":11,
"psdedqcodeexpname":"DATE"
},{
"expcode":"(case when t1.`DATE` = '2030-01-01' then '待定' else t1.`DATE` end)",