* code for issue #776.

This commit is contained in:
wangyidong
2023-04-13 16:00:40 +08:00
parent b38b7e992e
commit 8a69021d9b
6 changed files with 6 additions and 7 deletions
+1
View File
@@ -1,3 +1,4 @@
#lib_chosen.chosen-container .chosen-results {max-height: 100px;}
.radio-inline+.radio-inline { margin-top: 0; margin-left: 0px;}
.radio-inline {margin-right: 10px;}
#mainContent{height:310px;}
+1 -1
View File
@@ -32,7 +32,7 @@ function loadExecutions(projectID)
$('#executionBox').load(link, function()
{
var $extension = $('#executionBox').find('select');
$extension.attr('data-placeholder', holders.execution).attr('onchange', "loadObjectModules('execution', this.value)").picker();
$extension.attr('onchange', "loadObjectModules('execution', this.value)").picker();
if($extension.hasClass('disabled')) $('#executionBox').find('.picker').addClass('disabled');
});
loadObjectModules('project', projectID);
+1 -1
View File
@@ -341,7 +341,7 @@ $lang->doc->noticeAcl['doc']['private'] = '只有创建者自己可以访问。'
$lang->doc->placeholder = new stdclass();
$lang->doc->placeholder->url = '相应的链接地址';
$lang->doc->placeholder->execution = '执行为空时,创建文件在项目库下';
$lang->doc->placeholder->execution = '执行为空时,创建文档在项目库下';
$lang->doc->summary = "本页共 <strong>%s</strong> 个附件,共计 <strong>%s</strong>,其中<strong>%s</strong>。";
$lang->doc->ge = '个';
+1 -2
View File
@@ -71,7 +71,7 @@
<td class='required'><?php echo html::select('project', $objects, isset($execution) ? $execution->project : $objectID, "class='form-control picker-select' onchange=loadExecutions(this.value)");?></td>
<?php if($this->app->tab == 'doc' and $config->vision == 'rnd'):?>
<th><?php echo $lang->doc->execution?></th>
<td id='executionBox'><?php echo html::select('execution', $executions, isset($execution) ? $objectID : '', "class='form-control chosen' data-placeholder='{$lang->doc->placeholder->execution}' onchange='loadObjectModules(\"execution\", this.value)'")?></td>
<td id='executionBox'><?php echo html::select('execution', $executions, isset($execution) ? $objectID : '', "class='form-control chosen' onchange='loadObjectModules(\"execution\", this.value)'")?></td>
<td class='pl-0px'><i class='icon icon-help' title='<?php echo $lang->doc->placeholder->execution;?>'></i></td>
<?php endif;?>
</tr>
@@ -150,7 +150,6 @@
<?php js::set('textType', $config->doc->textTypes);?>
<?php js::set('docType', $docType);?>
<?php js::set('objectType', $objectType);?>
<?php js::set('holders', $lang->doc->placeholder);?>
<?php js::set('type', 'doc');?>
<?php js::set('requiredFields', ',' . $config->doc->create->requiredFields . ',');?>
<?php js::set('libNotEmpty', sprintf($lang->error->notempty, $lang->doc->lib));?>
-1
View File
@@ -148,7 +148,6 @@ $(function()
<?php js::set('confirmUpdateContent', $lang->doc->confirmUpdateContent);?>
<?php js::set('docID', $doc->id);?>
<?php js::set('draft', $doc->draft);?>
<?php js::set('holders', $lang->doc->placeholder);?>
<?php js::set('type', 'doc');?>
<?php js::set('defaultSave', $lang->doc->defaultSave);?>
<?php js::set('titleNotEmpty', sprintf($lang->error->notempty, $lang->doc->title));?>
+2 -2
View File
@@ -36,7 +36,7 @@
<th><?php echo $lang->doc->project;?></th>
<td class='required'><?php echo html::select('project', $projects, key($projects), "class='form-control picker-select'");?></td>
<th class='executionTH'><?php echo $lang->doc->execution?></th>
<td id='executionBox'><?php echo html::select('execution', array(), '', "class='form-control picker-select' data-placeholder='{$lang->doc->placeholder->execution}' onchange='loadObjectModules(\"execution\", this.value)'")?></td>
<td id='executionBox'><?php echo html::select('execution', array(), '', "class='form-control picker-select' onchange='loadObjectModules(\"execution\", this.value)'")?></td>
<td class='executionHelp pl-0px'><i class='icon icon-help' title='<?php echo $lang->doc->placeholder->execution;?>'></i></td>
</tr>
<tr class='productTR hidden'>
@@ -53,7 +53,6 @@
</table>
</form>
</div>
<?php js::set('holders', $lang->doc->placeholder);?>
<script>
$(function(){changeSpace()});
@@ -73,6 +72,7 @@ function changeSpace()
$('#typeapi').toggleClass('hidden', space == 'mine' || space == 'custom');
$('#typedoc').closest('.radio-inline').toggleClass('hidden', space == 'api');
$('#typeapi').closest('.radio-inline').toggleClass('hidden', space == 'mine' || space == 'custom');
$('#docType').toggleClass('hidden', $('#docType [name=type]:not(.hidden)').length == 1);
var docType = $('[name=type]:not(.hidden):checked').val();
if(space == 'project' && docType) $('#project').change();