public function set_f() { $id = $this->get("id", "int"); if ($id) { $rs = $this->model('email')->get_one($id); $this->assign("rs", $rs); $this->assign("id", $id); } else { $rs = array("content" => ''); } $edit_content = form_edit('content', $rs['content'], 'editor', 'height=300&btn_image=1&is_code=1'); $this->assign('edit_content', $edit_content); $this->view("email_set"); }
public function set_f() { $site_id = $_SESSION["admin_site_id"]; $id = $this->get("id", "int"); $idstring = ""; if ($id) { $this->assign("id", $id); $rs = $this->model('project')->get_one($id); $this->assign("rs", $rs); $ext_module = "project-" . $id; } else { $rs = array(); $ext_module = "add-project"; $parent_id = $this->get("pid"); $rs["parent_id"] = $parent_id; $rs['taxis'] = $this->model('project')->project_next_sort($parent_id); $this->assign("rs", $rs); } $parent_list = $this->model('project')->get_all($site_id, 0); $this->assign("parent_list", $parent_list); $this->assign("ext_module", $ext_module); $forbid = array("id", "identifier"); $forbid_list = $this->model('ext')->fields("project"); $forbid = array_merge($forbid, $forbid_list); $forbid = array_unique($forbid); $this->assign("ext_idstring", implode(",", $forbid)); $module_list = $this->model('module')->get_all(); $this->assign("module_list", $module_list); $site_id = $_SESSION["admin_site_id"]; $catelist = $this->model('cate')->root_catelist($site_id); $this->assign("catelist", $catelist); $emailtpl = $this->model('email')->simple_list($site_id); $this->assign("emailtpl", $emailtpl); $c_rs = $this->model('sysmenu')->get_one_condition("appfile='list' AND parent_id>0"); $gid = $c_rs["id"]; unset($c_rs); $note_content = form_edit('admin_note', $rs['admin_note'], "editor", "btn_image=1&height=300"); $this->assign('note_content', $note_content); $icolist = $this->lib('file')->ls('images/ico/'); if ($rs['ico'] && !in_array($rs['ico'], $icolist) || !$rs['ico']) { $rs['ico'] = 'images/ico/default.png'; } $this->assign('icolist', $icolist); $this->view("project_set"); }
public function set_f() { $id = $this->get("id", "int"); if ($id) { if (!$this->popedom["modify"]) { error(P_Lang('您没有权限执行此操作'), '', 'error'); } $rs = $this->model('email')->get_one($id); $this->assign("rs", $rs); $this->assign("id", $id); } else { if (!$this->popedom["add"]) { error(P_Lang('您没有权限执行此操作'), '', 'error'); } $rs = array("content" => ''); } $edit_content = form_edit('content', $rs['content'], 'editor', 'height=480&btn_image=1&is_code=1'); $this->assign('edit_content', $edit_content); $this->view("email_set"); }
function form_save() { global $vars; extract(doSlash(gpsa($vars))); if ($savenew) { if (safe_insert("txp_form", "Form='{$Form}', type='{$type}', name='{$name}'")) { form_edit(messenger('form', $name, 'created')); } else { form_edit(messenger('form', $name, 'already_exists')); } } else { safe_update("txp_form", "Form='{$Form}',type='{$type}',name='{$name}'", "name='{$oldname}'"); form_edit(messenger('form', $name, 'updated')); } }
public function email_f() { $content = form_edit('content', '', 'editor', 'height=300&btn_image=1&etype=simple'); $this->assign('content', $content); $this->view("all_email"); }
if ($user->AsWebMaster == false) { $tpl = new templates(); echo "alert('" . $tpl->javascript_parse_text("{ERROR_NO_PRIVS}") . "');"; die; exit; } if (isset($_GET["listwebs-search"])) { lists(); exit; } if (isset($_GET["zmd5-js"])) { form_edit_js(); exit; } if (isset($_GET["zmd5"])) { form_edit(); exit; } if (isset($_GET["adv-js"])) { adv_js(); exit; } if (isset($_GET["adv"])) { adv_form(); exit; } if (isset($_POST["ProxyVia"])) { adv_form_save(); exit; } if (isset($_POST["ProxyPass"])) {
function form_save() { global $vars, $step, $essential_forms; extract(doSlash(gpsa($vars))); $name = doSlash(trim(preg_replace('/[<>&"\']/', '', gps('name')))); if (!$name) { $step = 'form_create'; $message = gTxt('form_name_invalid'); return form_edit(array($message, E_ERROR)); } if (!in_array($type, array('article', 'category', 'comment', 'file', 'link', 'misc', 'section'))) { $step = 'form_create'; $message = gTxt('form_type_missing'); return form_edit(array($message, E_ERROR)); } if ($savenew) { $exists = safe_field('name', 'txp_form', "name = '{$name}'"); if ($exists) { $step = 'form_create'; $message = gTxt('form_already_exists', array('{name}' => $name)); return form_edit(array($message, E_ERROR)); } safe_insert('txp_form', "Form = '{$Form}', type = '{$type}', name = '{$name}'"); update_lastmod(); $message = gTxt('form_created', array('{name}' => $name)); return form_edit($message); } safe_update('txp_form', "Form = '{$Form}', type = '{$type}', name = '{$name}'", "name = '{$oldname}'"); update_lastmod(); $message = gTxt('form_updated', array('{name}' => $name)); form_edit($message); }
public function editopen_f() { $id = $this->get('id', 'int'); if (!$id) { error(P_Lang('未指定ID')); } $rs = $this->model('res')->get_one($id); if (!$rs) { error(P_Lang('数据不存在')); } $this->popedom_action($rs['session_id'], $rs['user_id']); $note = form_edit('note', $rs['note'], 'editor', 'width=650&height=250&etype=simple'); $this->assign('rs', $rs); $this->assign('note', $note); $this->view($this->dir_phpok . "open/res_editopen.html", 'abs-file', false); }
</tr> <tr> <td nowrap class="TableContent" width="15%"> 回访人员:</td> <td class="TableData" width="35%"><?php echo $view['user']; ?> </td> <td class="TableContent" width="15%"> </td> <td class="TableData" width="35%"> </td> </tr> </table> <?php //引入表单 form_edit('客户回访信息', 'crm_service', $view['id']); //引入编辑器 form_edit_eweb('crm_service', $view['id']); ?> </div> </form> </body> </html>
" /> </td> </tr> <tr> <td nowrap class="TableContent">客户名称:</td> <td class="TableData"> <?php if ($view['cid'] != '') { echo public_value('title', 'crm_company', 'id=' . $view['cid']); } ?> </td> <td class="TableContent"></td> <td class="TableData"> </td> </tr> </table> <?php //引入表单 form_edit('收款单信息', 'crm_price', $view['id']); //引入编辑器 form_edit_eweb('crm_price', $view['id']); ?> </div> </form> </body> </html>
投诉时间:<?php get_helps(); ?> </td> <td class="TableData" width="35%"><input type="text" name="comdate" class="BigInput" size="15" value="<?php echo $view['comdate']; ?> " onClick="WdatePicker();"/></td> <td class="TableContent" width="15%"> </td> <td class="TableData" width="35%"> </td> </tr> </table> <?php //引入表单 form_edit('客户投诉信息', 'crm_complaints', $view['id']); //引入编辑器 form_edit_eweb('crm_complaints', $view['id']); ?> </div> </form> </body> </html>
if (!$s->cfg['ver']['demo']) { $s->db_vars_save($s->cfg['file']['categories'], $db); } $m->location("sec=categories", "Categoria adicionada"); } else { if ($act == "edit") { if (count($s->req['sel']) < 1) { $m->error_redir("nosel"); } $l->form("categories", "edit_save"); $l->table(505); foreach ($s->cat as $id => $val) { if (!$s->req['sel'][$id]) { continue; } form_edit($id, $val); $l->tb_separator(30); } $l->tb_caption("Preencha todos os campos em <b>negrito</b>"); $l->tb_button("submit", "Salvar", array("accesskey" => "s")); $l->tb_button("cancel", "Cancelar", array("_go" => "sec=categories")); $l->table_end(); $l->form_end(); } else { if ($act == "edit_save") { foreach ($s->req['c'] as $id => $req) { $m->req('c|' . $id . '|name', 'c|' . $id . '|headlines|cut', 'c|' . $id . '|news|cut', 'c|' . $id . '|news|limit', 'c|' . $id . '|comments|limit_title', 'c|' . $id . '|comments|limit_comment'); $m->req_sync('c|' . $id . '|fullnews', 'c|' . $id . '|comments|active', 'c|' . $id . '|comments|req_mail', 'c|' . $id . '|comments|req_title', 'c|' . $id . '|comments|mzncode', 'c|' . $id . '|comments|smilies', 'c|' . $id . '|comments|queue', 'c|' . $id . '|comments|field1_r', 'c|' . $id . '|comments|field2_r'); } $db = $s->db_vars_open($s->cfg['file']['categories']); $db = $m->array_sync($db, $s->req['c']);
function editar($cp, $tabela) { $ed = new form(); $ed->id = $this->id; $ed->tabela = $tabela; /* Valida botao */ $bt = 0; for ($r = 0; $r < count($cp); $r++) { if (UpperCaseSQL(substr($cp[$r][0], 0, 2)) == '$B') { $bt = 1; } } if ($bt == 0) { array_push($cp, array('$B8', '', msg('submit'), False, False)); } /* Monta forumário */ $ed->cp = $cp; $result = form_edit($ed); $t = $result['tela']; $this->saved = $result['saved']; return $t; }
public function adm_f() { $id = $this->get('id', 'int'); if (!$id) { error(P_Lang('未指定ID')); } $rs = $this->model('reply')->get_one($id); if (!$rs) { error(P_Lang('数据记录不存在')); } $this->assign("id", $id); $this->assign("rs", $rs); $title_rs = $this->model('list')->get_one($rs["tid"]); $this->assign("title_rs", $title_rs); $edit_content = form_edit('content', $rs['adm_content'], 'editor', 'width=680&height=300'); $this->assign('edit_content', $edit_content); $this->view("reply_adm"); }
public function set_f() { $backurl = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : $this->url('res'); $this->assign("home_url", $error_url); $id = $this->get("id", "int"); if (!$id) { error(P_Lang('未指定ID'), $backurl, "error"); } $this->assign("id", $id); $rs = $this->model('res')->get_one($id, true); if (!$rs) { error(P_Lang('附件不存在'), $backurl, "error"); } $this->assign("id", $id); $this->assign("rs", $rs); $this->lib('form')->cssjs(array('form_type' => 'upload')); $this->addjs('js/webuploader/admin.upload.js'); $content = form_edit('note', $rs['note'], 'editor', 'width=650&height=250&etype=simple'); $this->assign('content', $content); $this->assign('backurl', $backurl); $this->view("res_manage"); }
echo trim($row['number']); ?> " /></td> <td class="TableData" width="15%" align="center"><input name="unit_<?php echo trim($row['id']); ?> " type="text" class="BigInput" id="unit" style="width: 100px;" value="<?php echo trim($row['unit']); ?> " /></td> </tr> <?php } ?> </table> <?php //引入表单 form_edit('合同信息', 'crm_contract', $view['id']); //引入编辑器 form_edit_eweb('crm_contract', $view['id']); ?> </div> </form> </body> </html>
function form_save() { global $vars, $step, $essential_forms; extract(doSlash(gpsa($vars))); if (!$name) { $step = 'form_create'; form_edit(); } elseif ($savenew) { if (safe_insert("txp_form", "Form='{$Form}', type='{$type}', name='{$name}'")) { form_edit(messenger('form', $name, 'created')); } else { form_edit(messenger('form', $name, 'already_exists')); } } else { safe_update("txp_form", "Form='{$Form}',type='{$type}'" . (!in_array($name, $essential_forms) ? ",name='{$name}'" : ''), "name='{$oldname}'"); form_edit(messenger('form', $name, 'updated')); } }
" type="text" class="BigInput" id="number" style="width: 100px;" onKeyUp="value=value.replace(/[^0-9]/g,'');" value="<?php echo trim($row['number']); ?> " /></td> <td class="TableData" width="15%" align="center"><input name="unit_<?php echo trim($row['id']); ?> " type="text" class="BigInput" id="unit" style="width: 100px;" value="<?php echo trim($row['unit']); ?> " /></td> </tr> <?php } ?> </table> <?php //引入表单 form_edit('报价单信息', 'crm_offer', $view['id']); //引入编辑器 form_edit_eweb('crm_offer', $view['id']); ?> </div> </form> </body> </html>
echo $view['title']; ?> " /> </td> </tr> <tr> <td nowrap class="TableContent">业务员:</td> <td class="TableData"> <?php echo get_pubuser(1, 'user', $view['user'], "+选择人员", '', 22); ?> </td> <td class="TableContent"></td> <td class="TableData"> </td> </tr> </table> <?php //引入表单 form_edit('供应商信息', 'crm_supplier', $view['id']); //引入编辑器 form_edit_eweb('crm_supplier', $view['id']); ?> </div> </form> </body> </html>
<td nowrap class="TableContent" width="15%"> </td> <td class="TableData" width="35%"></td> <td class="TableContent" width="15%"> 客户名称:</td> <td class="TableData" width="35%"> <?php if ($view['cid'] != '') { echo public_value('title', 'crm_company', 'id=' . $view['cid']); } ?> </td> </tr> </table> <?php //引入表单 form_edit('解决方案信息', 'crm_program', $view['id']); //引入编辑器 form_edit_eweb('crm_program', $view['id']); ?> </div> </form> </body> </html>
/** * Saves a form template. */ function form_save() { global $essential_forms, $form_types; extract(doSlash(array_map('assert_string', psa(array('savenew', 'Form', 'type', 'copy'))))); $name = sanitizeForPage(assert_string(ps('name'))); $newname = sanitizeForPage(assert_string(ps('newname'))); $save_error = false; $message = ''; if (in_array($name, $essential_forms)) { $newname = $name; $type = fetch('type', 'txp_form', 'name', $newname); $_POST['newname'] = $newname; } if (!$newname) { $message = array(gTxt('form_name_invalid'), E_ERROR); $save_error = true; } else { if (!isset($form_types[$type])) { $message = array(gTxt('form_type_missing'), E_ERROR); $save_error = true; } else { if ($copy && $name === $newname) { $newname .= '_copy'; $_POST['newname'] = $newname; } $exists = safe_field('name', 'txp_form', "name = '" . doSlash($newname) . "'"); if ($newname !== $name && $exists !== false) { $message = array(gTxt('form_already_exists', array('{name}' => $newname)), E_ERROR); if ($savenew) { $_POST['newname'] = ''; } $save_error = true; } else { if ($savenew or $copy) { if ($newname) { if (safe_insert('txp_form', "Form = '{$Form}',\n type = '{$type}',\n name = '" . doSlash($newname) . "'")) { update_lastmod(); $message = gTxt('form_created', array('{name}' => $newname)); } else { $message = array(gTxt('form_save_failed'), E_ERROR); $save_error = true; } } else { $message = array(gTxt('form_name_invalid'), E_ERROR); $save_error = true; } } else { if (safe_update('txp_form', "Form = '{$Form}',\n type = '{$type}',\n name = '" . doSlash($newname) . "'", "name = '" . doSlash($name) . "'")) { update_lastmod(); $message = gTxt('form_updated', array('{name}' => $name)); } else { $message = array(gTxt('form_save_failed'), E_ERROR); $save_error = true; } } } } } if ($save_error === true) { $_POST['save_error'] = '1'; } else { callback_event('form_saved', '', 0, $name, $newname); } form_edit($message); }
<td class="TableData" width="35%"> <?php if ($view['type'] == 1) { $company = 'crm_company'; } else { $company = 'crm_business'; } if ($view['cid'] != '') { echo public_value('title', $company, 'id=' . $view['cid']); } ?> </td> </tr> </table> <?php //引入表单 form_edit('客户关怀信息', 'crm_care', $view['id']); //引入编辑器 form_edit_eweb('crm_care', $view['id']); ?> </div> </form> </body> </html>
function form_save() { global $vars, $step, $essential_forms, $form_types; extract(doSlash(array_map('assert_string', gpsa($vars)))); $name = doSlash(trim(preg_replace('/[<>&"\']/', '', gps('name')))); if (!$name) { $step = 'form_create'; $message = gTxt('form_name_invalid'); return form_edit(array($message, E_ERROR)); } if (!isset($form_types[$type])) { $step = 'form_create'; $message = gTxt('form_type_missing'); return form_edit(array($message, E_ERROR)); } if ($savenew) { $exists = safe_field('name', 'txp_form', "name = '{$name}'"); if ($exists) { $step = 'form_create'; $message = gTxt('form_already_exists', array('{name}' => $name)); return form_edit(array($message, E_ERROR)); } if (safe_insert('txp_form', "Form = '{$Form}', type = '{$type}', name = '{$name}'")) { update_lastmod(); $message = gTxt('form_created', array('{name}' => $name)); } else { $message = array(gTxt('form_save_failed'), E_ERROR); } return form_edit($message); } if (safe_update('txp_form', "Form = '{$Form}', type = '{$type}', name = '{$name}'", "name = '{$oldname}'")) { update_lastmod(); $message = gTxt('form_updated', array('{name}' => $name)); } else { $message = array(gTxt('form_save_failed'), E_ERROR); } form_edit($message); }
public function set_f() { if (!$this->popedom["set"]) { error(P_Lang('您没有权限执行此操作'), '', 'error'); } $site_id = $_SESSION["admin_site_id"]; $id = $this->get("id", "int"); $idstring = ""; if ($id) { $this->assign("id", $id); $rs = $this->model('project')->get_one($id); $this->assign("rs", $rs); $ext_module = "project-" . $id; } else { $rs = array(); $ext_module = "add-project"; $parent_id = $this->get("pid"); $rs["parent_id"] = $parent_id; $this->assign("rs", $rs); } $parent_list = $this->model('project')->get_all($site_id, 0); $this->assign("parent_list", $parent_list); $this->assign("ext_module", $ext_module); $forbid = array("id", "identifier"); $forbid_list = $this->model('ext')->fields("project,id"); $forbid = array_merge($forbid, $forbid_list); $forbid = array_unique($forbid); $this->assign("ext_idstring", implode(",", $forbid)); $module_list = $this->model('module')->get_all(); $this->assign("module_list", $module_list); $site_id = $_SESSION["admin_site_id"]; $catelist = $this->model('cate')->root_catelist($site_id); $this->assign("catelist", $catelist); $currency_list = $this->model('currency')->get_list(); $this->assign('currency_list', $currency_list); $emailtpl = $this->model('email')->simple_list($site_id); $this->assign("emailtpl", $emailtpl); $c_rs = $this->model('sysmenu')->get_one_condition("appfile='list' AND parent_id>0"); $gid = $c_rs["id"]; unset($c_rs); $popedom_list = $this->model('popedom')->get_all("pid=0 AND gid='" . $gid . "'", false, false); $this->assign("popedom_list", $popedom_list); if ($id) { $popedom_list2 = $this->model('popedom')->get_all("pid='" . $id . "' AND gid='" . $gid . "'", false, false); if ($popedom_list2) { $m_plist = array(); foreach ($popedom_list2 as $key => $value) { $m_plist[] = $value["identifier"]; } $this->assign("popedom_list2", $m_plist); } } $note_content = form_edit('admin_note', $rs['admin_note'], "editor", "btn_image=1&height=300"); $this->assign('note_content', $note_content); $icolist = $this->lib('file')->ls('images/ico/'); if ($rs['ico'] && !in_array($rs['ico'], $icolist) || !$rs['ico']) { $rs['ico'] = 'images/ico/default.png'; } $this->assign('icolist', $icolist); $grouplist = $this->model('usergroup')->get_all("status=1"); if ($grouplist) { foreach ($grouplist as $key => $value) { $tmp_popedom = array('read' => false, 'post' => false, 'reply' => false, 'post1' => false, 'reply1' => false); $tmp = $value['popedom'] ? unserialize($value['popedom']) : false; if ($tmp && $tmp[$_SESSION['admin_site_id']]) { $tmp = $tmp[$_SESSION['admin_site_id']]; $tmp = explode(",", $tmp); foreach ($tmp_popedom as $k => $v) { if ($id && in_array($k . ':' . $id, $tmp)) { $tmp_popedom[$k] = true; } else { if (!$id && $k == 'read') { $tmp_popedom[$k] = true; } } } } $value['popedom'] = $tmp_popedom; $grouplist[$key] = $value; } } $this->assign('grouplist', $grouplist); $this->view("project_set"); }
public function editopen_f() { $id = $this->get('id', 'int'); if (!$id) { error(P_Lang('未指定ID')); } $rs = $this->model('res')->get_one($id); $note = form_edit('note', $rs['note'], 'editor', 'width=650&height=250&etype=simple'); $this->assign('rs', $rs); $this->assign('note', $note); $this->view("res_editopen"); }
" type="text" class="BigInput" id="number" style="width: 100px;" onKeyUp="value=value.replace(/[^0-9]/g,'');" value="<?php echo trim($row['number']); ?> " /></td> <td class="TableData" width="15%" align="center"><input name="unit_<?php echo trim($row['id']); ?> " type="text" class="BigInput" id="unit" style="width: 100px;" value="<?php echo trim($row['unit']); ?> " /></td> </tr> <?php } ?> </table> <?php //引入表单 form_edit('采购信息', 'crm_purchase', $view['id']); //引入编辑器 form_edit_eweb('crm_purchase', $view['id']); ?> </div> </form> </body> </html>
} else { if ($act == "edit") { if (count($s->req['sel']) < 1) { $m->error_redir("nosel"); } $l->form("users", "edit_save"); $l->table(505); $db = $s->db_table_open($s->cfg['file']['users']); foreach ($db['data'] as $k => $v) { if (!$s->req['sel'][$v['id']]) { continue; } if ($v['user'] == $s->usr['user']) { $m->error_redir("login_own"); } form_edit($k, $v); $l->tb_separator(30); } $l->tb_caption("Preencha todos os campos em <b>negrito</b>"); $l->tb_button("submit", "Salvar", array("accesskey" => "s")); $l->tb_button("cancel", "Cancelar", array("_go" => "sec=users")); $l->table_end(); $l->form_end(); } else { if ($act == "edit_save") { foreach ($s->req['c'] as $id => $req) { $m->req('c|' . $id . '|data|name', 'c|' . $id . '|data|mail'); } if (!$s->cfg['ver']['demo']) { $nl = array(); foreach ($s->req['c'] as $id => $req) {
<td nowrap class="TableContent">客户名称:</td> <td class="TableData"> <?php if ($view['sid'] != '') { echo public_value('title', 'crm_supplier', 'id=' . $view['sid']); } ?> </td> <td class="TableContent">采购单:</td> <td class="TableData"> <?php if ($view['perid'] != '') { echo public_value('title', 'crm_purchase', 'id=' . $view['perid']); } ?> </td> </tr> </table> <?php //引入表单 form_edit('付款信息', 'crm_payment', $view['id']); //引入编辑器 form_edit_eweb('crm_payment', $view['id']); ?> </div> </form> </body> </html>
<tr> <td nowrap class="TableHeader" colspan="4">联系人信息</td> </tr> <tr> <td nowrap class="TableContent" width="15%"> 姓名:<?php get_helps(); ?> </td> <td class="TableData" width="35%"><input name="name" type="text" class="BigInput" id="name" style="width: 200px;" value="<?php echo $user['name']; ?> " maxlength="100" /></td> <td class="TableContent" width="15%"> </td> <td class="TableData" width="35%"> </td> </tr> </table> <?php //引入表单 form_edit('', 'crm_contact', $user['id']); //引入编辑器 form_edit_eweb('crm_contact', $user['id']); ?> </div> </form> </body> </html>
} } } } } open_db(); update_row($table, $pk, $id, $values); close_db(); $posted = TRUE; } ?> <?php if ($posted == FALSE) { ?> <?php form_edit($table, $pk, $id); ?> <?php } else { ?> <p> Update complete </p> <p> <?php echo '<a href="list.php?table=' . $table . '">Bacl to List</a>'; ?> </p> <?php } ?>