xiugairenwuzhuangtai

This commit is contained in:
shilixia 2020-04-24 09:10:48 +08:00
parent a989bd1d5a
commit 9163474c8f
7 changed files with 50 additions and 52 deletions

View File

@ -75,28 +75,28 @@
case 1: return 'color:green;font-weight:bold'; break; case 1: return 'color:green;font-weight:bold'; break;
case 2: return 'color:red;font-weight:bold'; break; case 2: return 'color:red;font-weight:bold'; break;
case 3: return 'color:yellow;font-weight:bold'; break; case 3: return 'color:yellow;font-weight:bold'; break;
case 4: return 'color:black;font-weight:bold'; break; case 4: return 'color:blue;font-weight:bold'; break;
}}}, }}},
{ // {
field: 'jobstate', title: '任务状态', width: 100, styler: function (value, row, index) { // field: 'jobstate', title: '任务状态', width: 100, styler: function (value, row, index) {
if (value == 1) { // if (value == 1) {
return 'background-color:yellow;'; // return 'background-color:yellow;';
} // }
else { // else {
return 'background-color:green;'; // return 'background-color:green;';
} // }
}, formatter: function (value, row, index) { // }, formatter: function (value, row, index) {
if (value == 1) { // if (value == 1) {
return '可执行'; // return '可执行';
} // }
else { // else {
return '已过期' // return '已过期'
} // }
} // }
}, //},
{ field: 'createdate', title: '创建时间', width: 100 }, { field: 'createdate', title: '创建时间', width: 100 },
{ field: 'yanshou', title: '验收时间', width: 100 }, { field: 'yanshou', title: '验收时间', width: 100 },
// //
@ -113,10 +113,7 @@
$.get('api/checkproject?a=jobdetail&id=' + row.id, function (res) { $.get('api/checkproject?a=jobdetail&id=' + row.id, function (res) {
var data = res.data var data = res.data
console.log(data) console.log(data)
if (data.jobstate == 2) { if (data.taskstate ==3) {
$.messager.alert('提示', '该任务已过期不能执行!');
}
else if (data.taskstate ==3) {
$.messager.alert('提示', '该任务已关闭不能执行!'); $.messager.alert('提示', '该任务已关闭不能执行!');
} }
else if (data.taskstate ==2) { else if (data.taskstate ==2) {

View File

@ -38,13 +38,7 @@
</td> </td>
</tr> </tr>
<tr>
<td>整改时间:</td>
<td>
<input id="zgtime" editable="false" name="zgtime" class="easyui-datetimebox" style="width:480px"
data-options="currentText:'今天',closeText:'关闭',showSeconds:false" />
</td>
</tr>
<tr> <tr>
<td>检查问题:</td> <td>检查问题:</td>
@ -72,27 +66,33 @@
</tr> </tr>
<tr>
<td>整改期限:</td>
<!--<tr>
<td>整改时间:</td>
<td> <td>
<input id="zgtime" editable="false" name="zgtime" class="easyui-datetimebox" style="width:480px" <input id="zgtime" editable="false" name="zgtime" class="easyui-datetimebox" style="width:480px"
data-options="currentText:'今天',closeText:'关闭',showSeconds:false" required=true /> data-options="currentText:'今天',closeText:'关闭',showSeconds:false" />
</td> </td>
</tr> </tr>
<tr>
<td>整改人:</td> <!--<tr>
<td> <td>整改时间:</td>
<input id="zguser" class="easyui-textbox" name="zguser" style="width:480px" required=true /> <td>
</td> <input id="zgtime" editable="false" name="zgtime" class="easyui-datetimebox" style="width:480px"
</tr> data-options="currentText:'今天',closeText:'关闭',showSeconds:false" required=true />
<tr> </td>
<td>整改要求:</td> </tr>
<td> <tr>
<input id="zgyq" class="easyui-textbox" name="zgyq" style="width:480px;height:60px" data-options="multiline:true" required=true> <td>整改人:</td>
</td> <td>
</tr></tr>--> <input id="zguser" class="easyui-textbox" name="zguser" style="width:480px" required=true />
</td>
</tr>
<tr>
<td>整改要求:</td>
<td>
<input id="zgyq" class="easyui-textbox" name="zgyq" style="width:480px;height:60px" data-options="multiline:true" required=true>
</td>
</tr></tr>-->
<tr> <tr>
<td>需要整改:</td> <td>需要整改:</td>
@ -137,7 +137,7 @@
</div> </div>
<div> <div>
<input class="easyui-textbox" id="content" name="content" style="width:480px;height:60px" <input class="easyui-textbox" id="content" name="content" style="width:480px;height:60px"
data-options="label:'经验教训:',multiline:true"> data-options="label:'经验总结:',multiline:true">
</div> </div>
</form> </form>
</div> </div>

View File

@ -107,7 +107,7 @@
</tr>--> </tr>-->
<tr> <tr>
<td style="font-weight: bold;">经验教训</td> <td style="font-weight: bold;">经验总结</td>
<td colspan="3">{{content}}</td> <td colspan="3">{{content}}</td>
</tr> </tr>
<tr> <tr>

View File

@ -29,6 +29,7 @@
<option value="4">每季度一次</option> <option value="4">每季度一次</option>
<option value="5">每半年一次</option> <option value="5">每半年一次</option>
<option value="6">每年一次</option> <option value="6">每年一次</option>
<option value="7">专项检查</option>
</select> </select>
</div> </div>
<div style="margin-top:10px;margin-bottom:5px"> <div style="margin-top:10px;margin-bottom:5px">

View File

@ -32,7 +32,7 @@
/> />
</div> </div>
<div style="margin-bottom:5px"> <div style="margin-bottom:5px">
<input id="lesson" class="easyui-textbox" name="lesson" style="width:480px;height:100px" data-options="label:'经验教训',multiline:true" <input id="lesson" class="easyui-textbox" name="lesson" style="width:480px;height:100px" data-options="label:'经验总结',multiline:true"
/> />
</div> </div>
</form> </form>

View File

@ -7780,8 +7780,9 @@ def checkprojects(req):
elif a == 'listchuli': elif a == 'listchuli':
a = Checkjob.objects.filter(usecomp=Partment.objects.get(partid=companyid),taskstate=2,checktask__createuser__userid=userid).exclude(deletemark=0) a = Checkjob.objects.filter(usecomp=Partment.objects.get(partid=companyid),taskstate=2,checktask__createuser__userid=userid).exclude(deletemark=0,yanshou=None)
total = a.count() total = a.count()
startnum, endnum = fenye(req) startnum, endnum = fenye(req)
a = a.order_by('-starttime')[startnum:endnum].values('id','checkname__name','checktask__checktaskname','jobstate','starttime','endtime','yanshou','checkquestion','zguser__username','zgtime','checktask__checktype__checktitle','checkname__username', 'taskstate','checktask__checktime','createuser__username','createdate') a = a.order_by('-starttime')[startnum:endnum].values('id','checkname__name','checktask__checktaskname','jobstate','starttime','endtime','yanshou','checkquestion','zguser__username','zgtime','checktask__checktype__checktitle','checkname__username', 'taskstate','checktask__checktime','createuser__username','createdate')
@ -7826,7 +7827,6 @@ def checkprojects(req):
zghtp = '?'.join(data['zghtp']) if 'zghtp' in data else [] zghtp = '?'.join(data['zghtp']) if 'zghtp' in data else []
obj = Checkjob.objects.get(id=req.GET.get('jobid')) obj = Checkjob.objects.get(id=req.GET.get('jobid'))
if data['checkquestion']: if data['checkquestion']:
obj.checkquestion = data['checkquestion'] obj.checkquestion = data['checkquestion']
obj.zgjg = data['zgjg'] obj.zgjg = data['zgjg']
obj.taskstate =int(data['taskstate']) obj.taskstate =int(data['taskstate'])