Exemplo n.º 1
0
function form_edit($message = '')
{
    global $step;
    pagetop(gTxt('edit_forms'), $message);
    extract(gpsa(array('Form', 'name', 'type')));
    if ($step == 'form_create') {
        $Form = '';
        $name = '';
        $type = '';
        $inputs = fInput('submit', 'savenew', gTxt('save_new'), 'publish') . eInput("form") . sInput('form_save');
    } else {
        $name = (!$name or $step == 'form_delete') ? 'default' : $name;
        $rs = safe_row("*", "txp_form", "name='{$name}'");
        if ($rs) {
            extract($rs);
            $inputs = fInput('submit', 'save', gTxt('save'), 'publish') . eInput("form") . sInput('form_save') . hInput('oldname', $name);
        }
    }
    $out = startTable('edit') . tr(tdtl(hed(gTxt('useful_tags'), 2) . graf(gTxt('articles') . sp . popHelp('form_place_article') . br . popTagLinks('article')) . graf(gTxt('links') . sp . popHelp('form_place_link') . br . popTagLinks('link')) . graf(gTxt('displayed_comments') . sp . popHelp('form_place_comment') . br . popTagLinks('comment')) . graf(gTxt('comment_form') . sp . popHelp('form_place_input') . br . popTagLinks('comment_form')) . graf(gTxt('search_input_form') . sp . popHelp('form_place_search_input') . br . popTagLinks('search_input')) . graf(gTxt('search_results_form') . sp . popHelp('form_place_search_results') . br . popTagLinks('search_result')) . graf(tag('<strong>' . gTxt('file_download_tags') . '</strong>', 'a', ' href="#" onclick="toggleDisplay(\'downloadtags\');"') . sp . popHelp('form_file_download_tags')) . graf(popTagLinks('file_download'), ' style="display:none;" id="downloadtags"')) . tdtl('<form action="index.php" method="post">' . input_textarea($Form) . graf(gTxt('form_name') . br . fInput('text', 'name', $name, 'edit', '', '', 15)) . graf(gTxt('form_type') . br . formtypes($type)) . graf(gTxt('only_articles_can_be_previewed')) . fInput('submit', 'preview', gTxt('preview'), 'smallbox') . graf($inputs) . '</form>') . tdtl(form_list($name))) . endTable();
    echo $out;
}
Exemplo n.º 2
0
echo $ac;
?>
&fileurl=<?php 
echo $fileurl;
?>
">
		<input type="hidden" name="do" value="update" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">客户名称</td>
	  <?php 
form_list('crm_company');
?>
      <td width="80" align="center" class="TableHeader">业务人员</td>
      <td width="70" align="center" class="TableHeader">发布人</td>
      <td width="90" align="center" class="TableHeader">发布时间</td>
      <td width="90" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
	<tr>
      <td nowrap class="TableContent">
	<?php 
    get_boxlistkey("id[]", $row['id'], $row['uid'], $_USER->id);
    ?>
</td>
Exemplo n.º 3
0
Arquivo: bios.php Projeto: NazarK/sqp
function table_edit_form_generate($tablename, $r = "")
{
    global $tables;
    //this is for add
    if (!$r) {
        $r = new stdClass();
    }
    if (isset($tables[$tablename]["fields"])) {
        foreach ($tables[$tablename]["fields"] as $value) {
            //this is for add
            if (!isset($r->{$value})) {
                $r->{$value} = "";
            }
            if (str_end($value, "_check")) {
                form_checkbox("{~" . str_start($value, "_check") . "}:", $value, $r->{$value});
            } else {
                if (str_end($value, "_time")) {
                    $shortname = str_start($value, "_time");
                    form_timestamp($shortname, $shortname, $r->{$value});
                } else {
                    if (str_end($value, "_id")) {
                        $cap = substr($value, 0, strlen($value) - 3);
                        $table = $cap . "s";
                        if (!isset($tables[$table])) {
                            $table = str_prefix($tablename) . $table;
                        }
                        $fields = "id";
                        //use first field as list value
                        foreach ($tables[$table]['fields'] as $list_value) {
                            $fields .= ", {$list_value}";
                            break;
                        }
                        $list = db_list(db_query("SELECT {$fields} FROM {$table}"));
                        $table = table_long_alias($table);
                        form_list($table, $value, $list, $r->{$value});
                    } else {
                        //              $r->$value = htmlentities($r->$value,ENT_QUOTES);
                        if (str_end($value, "_text")) {
                            form_textarea("{~" . str_start($value, "_text") . "}", $value, $r->{$value});
                        } else {
                            form_input("{~{$value}}", $value, $r->{$value});
                        }
                    }
                }
            }
        }
    }
}
Exemplo n.º 4
0
echo $ac;
?>
&fileurl=<?php 
echo $fileurl;
?>
">
		<input type="hidden" name="do" value="update" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">代理商名称</td>
	  <?php 
form_list('crm_business');
?>
      <td width="80" align="center" class="TableHeader">业务人员</td>
      <td width="70" align="center" class="TableHeader">发布人</td>
      <td width="90" align="center" class="TableHeader">发布时间</td>
      <td width="90" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
	<tr>
      <td nowrap class="TableContent">
	<?php 
    get_boxlistkey("id[]", $row['id'], $row['uid'], $_USER->id);
    ?>
</td>
function form_edit_form_submit($data)
{
    $form = new DbForm();
    $response = $form->update($data);
    if ($response['code'] == 200) {
        return form_list($data['id']);
    }
}
Exemplo n.º 6
0
echo $ac;
?>
&fileurl=<?php 
echo $fileurl;
?>
">
		<input type="hidden" name="do" value="update" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">付款名称</td>
	  <?php 
form_list('crm_payment');
?>
	  <td width="80" align="center" class="TableHeader">金额</td>
      <td width="80" align="center" class="TableHeader">业务人员</td>
      <td width="70" align="center" class="TableHeader">发布人</td>
      <td width="90" align="center" class="TableHeader">发布时间</td>
	  <?php 
if ($_flow == 1) {
    ?>
	<td width="150" class="TableHeader">审批步骤</td>
	<?php 
}
?>
      <td width="110" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
Exemplo n.º 7
0
echo $ac;
?>
&fileurl=<?php 
echo $fileurl;
?>
">
		<input type="hidden" name="do" value="update" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">供应商名称</td>
	  <?php 
form_list('crm_supplier');
?>
      <td width="80" align="center" class="TableHeader">业务人员</td>
      <td width="70" align="center" class="TableHeader">发布人</td>
      <td width="90" align="center" class="TableHeader">发布时间</td>
      <td width="90" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
	<tr>
      <td nowrap class="TableContent">
	<?php 
    get_boxlistkey("id[]", $row['id'], $row['uid'], $_USER->id);
    ?>
</td>
Exemplo n.º 8
0
/**
 * Renders the main Form editor panel.
 *
 * @param string|array $message The activity message
 */
function form_edit($message = '')
{
    global $event, $step, $essential_forms;
    pagetop(gTxt('edit_forms'), $message);
    extract(array_map('assert_string', gpsa(array('copy', 'save_error', 'savenew'))));
    $name = sanitizeForPage(assert_string(gps('name')));
    $type = assert_string(gps('type'));
    $newname = sanitizeForPage(assert_string(gps('newname')));
    if ($step == 'form_delete' || empty($name) && $step != 'form_create' && !$savenew) {
        $name = 'default';
    } elseif ((($copy || $savenew) && $newname || $newname && $newname !== $name) && !$save_error) {
        $name = $newname;
    }
    $Form = gps('Form');
    if (!$save_error) {
        $rs = safe_row('*', 'txp_form', "name='" . doSlash($name) . "'");
        extract($rs);
    }
    if (in_array($name, $essential_forms)) {
        $name_widgets = span(gTxt('form_name'), array('class' => 'txp-label-fixed')) . br . span($name, array('class' => 'txp-value-fixed'));
        $type_widgets = span(gTxt('form_type'), array('class' => 'txp-label-fixed')) . br . span($type, array('class' => 'txp-value-fixed'));
    } else {
        $name_widgets = tag(gTxt('form_name'), 'label', 'for="new_form"') . br . fInput('text', 'newname', $name, 'input-medium', '', '', INPUT_MEDIUM, '', 'new_form', false, true);
        $type_widgets = tag(gTxt('form_type'), 'label', 'for="type"') . br . formTypes($type, false);
    }
    $buttons = href(gTxt('duplicate'), '#', array('id' => 'txp_clone', 'class' => 'clone', 'title' => gTxt('form_clone')));
    if (empty($type) || $type == 'article') {
        $buttons .= href(gTxt('preview'), '#', array('id' => 'form_preview', 'class' => 'form-preview'));
    }
    if ($name) {
        $name_widgets .= n . span($buttons, array('class' => 'txp-actions'));
    } else {
        $name_widgets .= hInput('savenew', 'savenew');
    }
    // Generate the tagbuilder links.
    // Format of each entry is popTagLink -> array ( gTxt string, class/ID ).
    $tagbuild_items = array('article' => array('articles', 'article-tags'), 'link' => array('links', 'link-tags'), 'comment' => array('comments', 'comment-tags'), 'comment_details' => array('comment_details', 'comment-detail-tags'), 'comment_form' => array('comment_form', 'comment-form-tags'), 'search_result' => array('search_results_form', 'search-result-tags'), 'file_download' => array('file_download_tags', 'file-tags'), 'category' => array('category_tags', 'category-tags'), 'section' => array('section_tags', 'section-tags'));
    $tagbuild_links = '';
    foreach ($tagbuild_items as $tb => $item) {
        $tagbuild_links .= wrapRegion($item[1] . '_group', popTagLinks($tb), $item[1], $item[0], $item[1]);
    }
    echo hed(gTxt('tab_forms') . popHelp('forms_overview'), 1, array('class' => 'txp-heading'));
    echo n . tag(n . tag(hed(gTxt('tagbuilder'), 2) . $tagbuild_links . n, 'div', array('id' => 'tagbuild_links', 'class' => 'txp-layout-cell txp-layout-1-4')) . n . tag(form(graf($name_widgets) . graf(tag(gTxt('form_code'), 'label', array('for' => 'form')) . br . '<textarea class="code" id="form" name="Form" cols="' . INPUT_LARGE . '" rows="' . TEXTAREA_HEIGHT_LARGE . '" dir="ltr">' . txpspecialchars($Form) . '</textarea>') . graf($type_widgets) . (empty($type) ? graf(gTxt('only_articles_can_be_previewed')) : '') . graf(fInput('submit', 'save', gTxt('save'), 'publish') . eInput('form') . sInput('form_save') . hInput('name', $name)), '', '', 'post', 'edit-form', '', 'form_form') . n, 'div', array('id' => 'main_content', 'class' => 'txp-layout-cell txp-layout-2-4')) . n . tag(graf(sLink('form', 'form_create', gTxt('create_new_form')), ' class="action-create"') . form_list($name) . n, 'div', array('id' => 'content_switcher', 'class' => 'txp-layout-cell txp-layout-1-4')) . n, 'div', array('id' => $event . '_container', 'class' => 'txp-layout-grid'));
}
Exemplo n.º 9
0
?>
">
	<input type="hidden" name="do" value="update" />
	<input type="hidden" name="cid" value="<?php 
echo $cid;
?>
" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">合同名称</td>
	  <?php 
form_list('crm_contract');
?>
	  <td width="90" align="center" class="TableHeader">总金额</td>
      <td width="90" align="center" class="TableHeader">发布人</td>
      <td width="100" align="center" class="TableHeader">发布时间</td>
	  <?php 
if ($_flow == 1) {
    ?>
<td width="150" class="TableHeader">审批步骤</td>
<?php 
}
?>
      <td width="110" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
Exemplo n.º 10
0
      * Form management
      */
 /*
  * Form management
  */
 case "form_list":
     print form_list();
     break;
 case 'form_list_pager':
     print form_list(NULL, $_GET['search'], $_GET['sort'], $_GET['page']);
     break;
 case 'form_list_sort':
     print form_list(NULL, $_GET['search'], $_GET['sort'], 1);
     break;
 case 'form_list_search':
     print form_list(NULL, $_GET['search']);
     break;
 case 'form_create_form':
     print form_create_form();
     break;
 case 'form_create_form_submit':
     print form_create_form_submit($_GET);
     break;
 case 'form_edit_form':
     print form_edit_form($_GET);
     break;
 case 'form_edit_form_submit':
     print form_edit_form_submit($_GET);
     break;
 case 'form_delete_form':
     print form_delete_form($_GET);
Exemplo n.º 11
0
/**
 * Renders the main Form editor panel.
 *
 * @param string|array $message The activity message
 */
function form_edit($message = '')
{
    global $event, $step, $essential_forms;
    pagetop(gTxt('edit_forms'), $message);
    extract(array_map('assert_string', gpsa(array('copy', 'save_error', 'savenew'))));
    $name = sanitizeForPage(assert_string(gps('name')));
    $type = assert_string(gps('type'));
    $newname = sanitizeForPage(assert_string(gps('newname')));
    if ($step == 'form_delete' || empty($name) && $step != 'form_create' && !$savenew) {
        $name = 'default';
    } elseif ((($copy || $savenew) && $newname || $newname && $newname !== $name) && !$save_error) {
        $name = $newname;
    }
    $Form = gps('Form');
    if (!$save_error) {
        $rs = safe_row("*", 'txp_form', "name = '" . doSlash($name) . "'");
        extract($rs);
    }
    if (in_array($name, $essential_forms)) {
        $name_widgets = inputLabel('new_form', fInput('text', 'newname', $name, 'input-medium', '', '', INPUT_MEDIUM, '', 'new_form', true), 'form_name', array('', 'instructions_form_name'), array('class' => 'txp-form-field'));
        $type_widgets = inputLabel('type', formTypes($type, false, 'type', true), 'form_type', array('', 'instructions_form_type'), array('class' => 'txp-form-field'));
    } else {
        $name_widgets = inputLabel('new_form', fInput('text', 'newname', $name, 'input-medium', '', '', INPUT_MEDIUM, '', 'new_form', false, true), 'form_name', array('', 'instructions_form_name'), array('class' => 'txp-form-field'));
        $type_widgets = inputLabel('type', formTypes($type, false), 'form_type', array('', 'instructions_form_type'), array('class' => 'txp-form-field'));
    }
    if ($name === '') {
        $name_widgets .= hInput('savenew', 'savenew');
    } else {
        $name_widgets .= hInput('name', $name);
    }
    $name_widgets .= eInput('form') . sInput('form_save');
    $buttonExtras = '';
    if ($name) {
        $buttonExtras .= href('<span class="ui-icon ui-icon-copy"></span> ' . gTxt('duplicate'), '#', array('class' => 'txp-clone', 'data-form' => 'form_form'));
    }
    $buttons = graf(tag_void('input', array('class' => 'publish', 'type' => 'submit', 'method' => 'post', 'value' => gTxt('save'), 'form' => 'form_form')), ' class="txp-save"') . graf(sLink('form', 'form_create', '<span class="ui-icon ui-extra-icon-new-document"></span> ' . gTxt('create_new_form'), 'txp-new') . $buttonExtras, array('class' => 'txp-actions'));
    // Generate the tagbuilder links.
    // Format of each entry is popTagLink -> array ( gTxt string, class/ID ).
    $tagbuild_items = array('article' => array('articles', 'article-tags'), 'link' => array('links', 'link-tags'), 'comment' => array('comments', 'comment-tags'), 'comment_details' => array('comment_details', 'comment-detail-tags'), 'comment_form' => array('comment_form', 'comment-form-tags'), 'search_result' => array('search_results_form', 'search-result-tags'), 'file_download' => array('file_download_tags', 'file-tags'), 'category' => array('category_tags', 'category-tags'), 'section' => array('section_tags', 'section-tags'));
    $tagbuild_links = '';
    foreach ($tagbuild_items as $tb => $item) {
        $tagbuild_links .= wrapRegion($item[1] . '_group', popTagLinks($tb), $item[1], $item[0], $item[1]);
    }
    // Forms code columm.
    echo n . tag(hed(gTxt('tab_forms') . popHelp('forms_overview'), 1, array('class' => 'txp-heading')) . form($name_widgets . $type_widgets . inputLabel('form', '<textarea class="code" id="form" name="Form" cols="' . INPUT_LARGE . '" rows="' . TEXTAREA_HEIGHT_LARGE . '" dir="ltr">' . txpspecialchars($Form) . '</textarea>', 'form_code', array('', 'instructions_form_code'), array('class' => 'txp-form-field')) . (empty($type) ? graf(gTxt('only_articles_can_be_previewed')) : ''), '', '', 'post', '', '', 'form_form'), 'div', array('class' => 'txp-layout-4col-cell-1-2-3', 'id' => 'main_content', 'role' => 'region'));
    // Forms create/switcher column.
    echo n . tag($buttons . form_list($name) . n, 'div', array('class' => 'txp-layout-4col-cell-4alt', 'id' => 'content_switcher', 'role' => 'region'));
    // Forms tag builder column. TODO: make this a modal?
    //    echo n.tag(
    //        hed(gTxt('tagbuilder'), 2).
    //        $tagbuild_links.n
    //    , 'div', array(
    //        'id'    => 'tagbuild_links',
    //        'class' => '',
    //    ));
}
Exemplo n.º 12
0
echo $type;
?>
" />
	<input type="hidden" name="cid" value="<?php 
echo $cid;
?>
" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">主题</td>
	  <?php 
form_list('crm_care');
?>
	  <td width="80" align="center" class="TableHeader">业务人员</td>
      <td width="90" align="center" class="TableHeader">发布人</td>
      <td width="100" align="center" class="TableHeader">发布时间</td>
      <td width="90" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
	<tr>
      <td nowrap class="TableContent">
	<?php 
    get_boxlistkey("id[]", $row['id'], $row['uid'], $_USER->id);
    ?>
</td>
Exemplo n.º 13
0
?>
">
	<input type="hidden" name="do" value="update" />
	<input type="hidden" name="cid" value="<?php 
echo $cid;
?>
" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">回访主题</td>
	  <?php 
form_list('crm_service');
?>
	  <td width="80" align="center" class="TableHeader">分配时间</td>
	  <td width="80" align="center" class="TableHeader">回访时间</td>
	  <td width="80" align="center" class="TableHeader">回访人员</td>
      <td width="90" align="center" class="TableHeader">发布人</td>
      <td width="100" align="center" class="TableHeader">发布时间</td>
      <td width="90" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
	<tr>
      <td nowrap class="TableContent">
	<?php 
    get_boxlistkey("id[]", $row['id'], $row['uid'], $_USER->id);
Exemplo n.º 14
0
?>
">
	<input type="hidden" name="do" value="update" />
	<input type="hidden" name="cid" value="<?php 
echo $cid;
?>
" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">报价单名称</td>
	  <?php 
form_list('crm_offer');
?>
	  <td width="80" align="center" class="TableHeader">总金额</td>
      <td width="90" align="center" class="TableHeader">发布人</td>
      <td width="100" align="center" class="TableHeader">发布时间</td>
	  <?php 
if ($_flow == 1) {
    ?>
		<td width="150" class="TableHeader">审批步骤</td>
		<?php 
}
?>
      <td width="110" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
Exemplo n.º 15
0
echo $ac;
?>
&fileurl=<?php 
echo $fileurl;
?>
">
		<input type="hidden" name="do" value="update" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">产品编号</td>
      <td align="left" class="TableHeader">产品名称</td>
	  <?php 
form_list('crm_product');
?>
      <td width="120" align="center" class="TableHeader">产品分类</td>
      <td width="80" align="center" class="TableHeader">产品价格</td>
      <td width="80" align="center" class="TableHeader">发布人</td>
      <td width="90" align="center" class="TableHeader">发布时间</td>
      <td width="90" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
	<tr>
      <td nowrap class="TableContent">
	<?php 
    get_boxlistkey("id[]", $row['id'], $row['uid'], $_USER->id);
    ?>
Exemplo n.º 16
0
echo $ac;
?>
&fileurl=<?php 
echo $fileurl;
?>
">
		<input type="hidden" name="do" value="update" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">收款单名称</td>
	  <?php 
form_list('crm_price');
?>
	  <td width="80" align="center" class="TableHeader">金额</td>
      <td width="80" align="center" class="TableHeader">业务人员</td>
      <td width="70" align="center" class="TableHeader">发布人</td>
      <td width="90" align="center" class="TableHeader">发布时间</td>
	  <?php 
if ($_flow == 1) {
    ?>
	<td width="150" class="TableHeader">审批步骤</td>
	<?php 
}
?>
      <td width="110" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
Exemplo n.º 17
0
?>
">
	<input type="hidden" name="do" value="update" />
	<input type="hidden" name="cid" value="<?php 
echo $cid;
?>
" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">解决方案名称</td>
	  <?php 
form_list('crm_program');
?>
      <td width="90" align="center" class="TableHeader">发布人</td>
      <td width="100" align="center" class="TableHeader">发布时间</td>
	  <?php 
if ($_flow == 1) {
    ?>
<td width="150" class="TableHeader">审批步骤</td>
<?php 
}
?>
      <td width="110" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
Exemplo n.º 18
0
?>
">
	<input type="hidden" name="do" value="update" />
	<input type="hidden" name="cid" value="<?php 
echo $cid;
?>
" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">订单名称</td>
	  <?php 
form_list('crm_order');
?>
	  <td width="90" align="center" class="TableHeader">总金额</td>
      <td width="90" align="center" class="TableHeader">发布人</td>
      <td width="100" align="center" class="TableHeader">发布时间</td>
	  <?php 
if ($_flow == 1) {
    ?>
<td width="150" class="TableHeader">审批步骤</td>
<?php 
}
?>
      <td width="110" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
Exemplo n.º 19
0
function form_edit($message = '')
{
    global $event, $step, $essential_forms;
    pagetop(gTxt('edit_forms'), $message);
    extract(gpsa(array('Form', 'name', 'type')));
    $name = trim(preg_replace('/[<>&"\']/', '', $name));
    if ($step == 'form_create') {
        $inputs = fInput('submit', 'savenew', gTxt('save_new'), 'publish') . eInput("form") . sInput('form_save');
    } else {
        $name = (!$name or $step == 'form_delete') ? 'default' : $name;
        $rs = safe_row("*", "txp_form", "name='" . doSlash($name) . "'");
        extract($rs);
        $inputs = fInput('submit', 'save', gTxt('save'), 'publish') . eInput("form") . sInput('form_save') . hInput('oldname', $name);
    }
    if (!in_array($name, $essential_forms)) {
        $changename = graf(gTxt('form_name') . br . fInput('text', 'name', $name, 'edit', '', '', INPUT_REGULAR));
    } else {
        $changename = graf(gTxt('form_name') . br . tag($name, 'em') . hInput('name', $name));
    }
    // Generate the tagbuilder links
    // Format of each entry is popTagLink -> array ( gTxt string, class/ID )
    $tagbuild_items = array('article' => array('articles', 'article-tags'), 'link' => array('links', 'link-tags'), 'comment' => array('comments', 'comment-tags'), 'comment_details' => array('comment_details', 'comment-detail-tags'), 'comment_form' => array('comment_form', 'comment-form-tags'), 'search_result' => array('search_results_form', 'search-result-tags'), 'file_download' => array('file_download_tags', 'file-tags'), 'category' => array('category_tags', 'category-tags'), 'section' => array('section_tags', 'section-tags'));
    $tagbuild_links = '';
    foreach ($tagbuild_items as $tb => $item) {
        $tagbuild_links .= '<div class="' . $item[1] . '">' . hed('<a href="#' . $item[1] . '">' . gTxt($item[0]) . '</a>', 3, ' class="lever' . (get_pref('pane_form_' . $item[1] . '_visible') ? ' expanded' : '') . '"') . '<div id="' . $item[1] . '" class="toggle on" style="display:' . (get_pref('pane_form_' . $item[1] . '_visible') ? 'block' : 'none') . '">' . popTagLinks($tb) . '</div></div>';
    }
    $out = '<h1 class="txp-heading">' . gTxt('tab_forms') . sp . popHelp('forms_overview') . '</h1>' . '<div id="' . $event . '_container" class="txp-container">' . startTable('', '', 'txp-columntable') . tr(tdtl('<div id="tagbuild_links">' . hed(gTxt('tagbuilder'), 2) . $tagbuild_links . '</div>', ' class="column"') . tdtl('<form action="index.php" method="post" id="form_form">' . '<div id="main_content">' . '<div class="edit-title">' . gTxt('you_are_editing_form') . sp . strong($name ? $name : gTxt('untitled')) . '</div>' . '<textarea id="form" class="code" name="Form" cols="' . INPUT_LARGE . '" rows="' . INPUT_REGULAR . '">' . txpspecialchars($Form) . '</textarea>' . $changename . graf(gTxt('form_type') . br . formtypes($type)) . (empty($type) ? graf(gTxt('only_articles_can_be_previewed')) : '') . (empty($type) || $type == 'article' ? fInput('submit', 'form_preview', gTxt('preview')) : '') . graf($inputs) . '</div>' . n . tInput() . n . '</form>', ' class="column"') . tdtl('<div id="content_switcher">' . hed(gTxt('all_forms'), 2) . form_list($name) . '</div>', ' class="column"')) . endTable() . '</div>';
    echo $out;
}
Exemplo n.º 20
0
echo $type;
?>
" />
	<input type="hidden" name="cid" value="<?php 
echo $cid;
?>
" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">主题</td>
	  <?php 
form_list('crm_complaints');
?>
	  <td width="80" align="center" class="TableHeader">投诉时间</td>
	  <td width="80" align="center" class="TableHeader">投诉人</td>
      <td width="90" align="center" class="TableHeader">记录人</td>
      <td width="100" align="center" class="TableHeader">记录时间</td>
      <td width="90" align="center" class="TableHeader">操作</td>
    </tr>
<?php 
foreach ($result as $row) {
    ?>
	<tr>
      <td nowrap class="TableContent">
	<?php 
    get_boxlistkey("id[]", $row['id'], $row['uid'], $_USER->id);
    ?>
Exemplo n.º 21
0
function form_edit($message = '')
{
    global $step, $essential_forms;
    pagetop(gTxt('edit_forms'), $message);
    extract(gpsa(array('Form', 'name', 'type')));
    $name = trim(preg_replace('/[<>&"\']/', '', $name));
    if ($step == 'form_create') {
        $inputs = fInput('submit', 'savenew', gTxt('save_new'), 'publish') . eInput("form") . sInput('form_save');
    } else {
        $name = (!$name or $step == 'form_delete') ? 'default' : $name;
        $rs = safe_row("*", "txp_form", "name='" . doSlash($name) . "'");
        extract($rs);
        $inputs = fInput('submit', 'save', gTxt('save'), 'publish') . eInput("form") . sInput('form_save') . hInput('oldname', $name);
    }
    if (!in_array($name, $essential_forms)) {
        $changename = graf(gTxt('form_name') . br . fInput('text', 'name', $name, 'edit', '', '', 15));
    } else {
        $changename = graf(gTxt('form_name') . br . tag($name, 'em') . hInput('name', $name));
    }
    $out = startTable('edit') . tr(tdtl(hed(gTxt('tagbuilder'), 2) . hed('<a href="#article-tags" onclick="toggleDisplay(\'article-tags\'); return false;">' . gTxt('articles') . '</a>' . sp . popHelp('form_articles'), 3, ' class="plain"') . '<div id="article-tags" class="toggle on" style="display:block">' . popTagLinks('article') . '</div>' . hed('<a href="#link-tags" onclick="toggleDisplay(\'link-tags\'); return false;">' . gTxt('links') . '</a>' . sp . popHelp('form_place_link'), 3, ' class="plain"') . '<div id="link-tags" class="toggle" style="display:none">' . popTagLinks('link') . '</div>' . hed('<a href="#comment-tags" onclick="toggleDisplay(\'comment-tags\'); return false;">' . gTxt('comments') . '</a>' . sp . popHelp('form_comments'), 3, ' class="plain"') . '<div id="comment-tags" class="toggle" style="display:none">' . popTagLinks('comment') . '</div>' . hed('<a href="#comment-detail-tags" onclick="toggleDisplay(\'comment-detail-tags\'); return false;">' . gTxt('comment_details') . '</a>' . sp . popHelp('form_comment_details'), 3, ' class="plain"') . '<div id="comment-detail-tags" class="toggle" style="display:none">' . popTagLinks('comment_details') . '</div>' . hed('<a href="#comment-form-tags" onclick="toggleDisplay(\'comment-form-tags\'); return false;">' . gTxt('comment_form') . '</a>' . sp . popHelp('form_comment_form'), 3, ' class="plain"') . '<div id="comment-form-tags" class="toggle" style="display:none">' . popTagLinks('comment_form') . '</div>' . hed('<a href="#search-result-tags" onclick="toggleDisplay(\'search-result-tags\'); return false;">' . gTxt('search_results_form') . '</a>' . sp . popHelp('form_search_results'), 3, ' class="plain"') . '<div id="search-result-tags" class="toggle" style="display:none">' . popTagLinks('search_result') . '</div>' . hed('<a href="#file-tags" onclick="toggleDisplay(\'file-tags\'); return false;">' . gTxt('file_download_tags') . '</a>' . sp . popHelp('form_file_download_tags'), 3, ' class="plain"') . '<div id="file-tags" class="toggle" style="display:none">' . popTagLinks('file_download') . '</div>' . hed('<a href="#category-tags" onclick="toggleDisplay(\'category-tags\'); return false;">' . gTxt('category_tags') . '</a>' . sp . popHelp('form_category_tags'), 3, ' class="plain"') . '<div id="category-tags" class="toggle" style="display:none">' . popTagLinks('category') . '</div>' . hed('<a href="#section-tags" onclick="toggleDisplay(\'section-tags\'); return false;">' . gTxt('section_tags') . '</a>' . sp . popHelp('form_section_tags'), 3, ' class="plain"') . '<div id="section-tags" class="toggle" style="display:none">' . popTagLinks('section') . '</div>') . tdtl('<form action="index.php" method="post">' . '<textarea id="form" class="code" name="Form" cols="60" rows="20">' . htmlspecialchars($Form) . '</textarea>' . $changename . graf(gTxt('form_type') . br . formtypes($type)) . graf(gTxt('only_articles_can_be_previewed')) . fInput('submit', 'form_preview', gTxt('preview'), 'smallbox') . graf($inputs) . '</form>') . tdtl(form_list($name))) . endTable();
    echo $out;
}
Exemplo n.º 22
0
echo $ac;
?>
&fileurl=<?php 
echo $fileurl;
?>
">
		<input type="hidden" name="do" value="update" />
<table class="TableBlock" border="0" width="100%" align="center">
 
   
	<tr>
      <td width="30" align="center" nowrap class="TableHeader">选项</td>
      <td width="130" align="center" class="TableHeader">流水号</td>
      <td align="left" class="TableHeader">采购名称</td>
	  <?php 
form_list('crm_purchase');
?>
	  <td width="80" align="center" class="TableHeader">金额合计</td>
      <td width="80" align="center" class="TableHeader">申请人</td>
      <td width="70" align="center" class="TableHeader">发布人</td>
      <td width="90" align="center" class="TableHeader">发布时间</td>
	  <?php 
if ($_flow == 1) {
    ?>
	  <td width="150" class="TableHeader">审批步骤</td>
	  <?php 
}
?>
      <td width="110" align="center" class="TableHeader">操作</td>
    </tr>
<?php