Browse Source

回滚修改

master
wanghongjun 2 years ago
parent
commit
eb10dbb57c
  1. 6
      addons/weliam_smartcity/web/controller/agentset/diyForm.ctrl.php
  2. 1
      addons/weliam_smartcity/web/view/default/agentset/diy_form/edit.html
  3. 14
      addons/weliam_smartcity/web/view/default/agentset/diy_form/list.html
  4. 204
      addons/weliam_smartcity/web/view/default/agentset/diy_form/template_config.html

6
addons/weliam_smartcity/web/controller/agentset/diyForm.ctrl.php

@ -23,14 +23,11 @@ class DiyForm_WeliamController{
if(is_store()) $where .= " AND a.sid = {$_W['storeid']} "; if(is_store()) $where .= " AND a.sid = {$_W['storeid']} ";
if($title) $where .= " AND a.title LIKE '%{$title}%'"; if($title) $where .= " AND a.title LIKE '%{$title}%'";
//列表信息获取 //列表信息获取
$field = "a.id,a.title,a.create_time,a.update_time,a.template_type,b.storename"; $field = "a.id,a.title,a.create_time,a.update_time,b.storename";
$sql = "SELECT {$field} FROM ".tablename(PDO_NAME."diyform") $sql = "SELECT {$field} FROM ".tablename(PDO_NAME."diyform")
." as a LEFT JOIN ".tablename(PDO_NAME."merchantdata") ." as a LEFT JOIN ".tablename(PDO_NAME."merchantdata")
." as b ON a.sid = b.id {$where}"; ." as b ON a.sid = b.id {$where}";
$list = pdo_fetchall($sql." ORDER BY a.update_time DESC,a.create_time DESC limit {$pageStart},{$pageIndex}"); $list = pdo_fetchall($sql." ORDER BY a.update_time DESC,a.create_time DESC limit {$pageStart},{$pageIndex}");
foreach ($list as &$itemVal) {
$itemVal['template_type_title'] = FormTemplate::$template_type[$itemVal['template_type']];
}
//总数信息获取 //总数信息获取
$countSql = str_replace($field,"count(*)",$sql); $countSql = str_replace($field,"count(*)",$sql);
$total = pdo_fetchcolumn($countSql); $total = pdo_fetchcolumn($countSql);
@ -67,7 +64,6 @@ class DiyForm_WeliamController{
//信息拼装 //信息拼装
$params = [ $params = [
'title' => $data['base']['title'] ? : '自定义表单', 'title' => $data['base']['title'] ? : '自定义表单',
'template_type' => $data['base']['template_type'] ? : 1,
'info' => base64_encode(json_encode($data,JSON_UNESCAPED_UNICODE)), 'info' => base64_encode(json_encode($data,JSON_UNESCAPED_UNICODE)),
'update_time' => time() 'update_time' => time()
]; ];

1
addons/weliam_smartcity/web/view/default/agentset/diy_form/edit.html

@ -475,7 +475,6 @@
base:{ base:{
title: '自定义表单',//表单名称 title: '自定义表单',//表单名称
align: 'left', align: 'left',
template_type: 1,
}, },
list:{}, list:{},
}, },

14
addons/weliam_smartcity/web/view/default/agentset/diy_form/list.html

@ -33,8 +33,7 @@
<tr> <tr>
<th class="text-center" width="5%">ID</th> <th class="text-center" width="5%">ID</th>
<th class="text-center" width="20%">标题</th> <th class="text-center" width="20%">标题</th>
<!-- <th class="text-center" width="20%">所属商户</th>--> <th class="text-center" width="20%">所属商户</th>
<th class="text-center" width="20%">模板类型</th>
<th class="text-center" width="20%">创建时间</th> <th class="text-center" width="20%">创建时间</th>
<th class="text-center" width="20%">最近编辑</th> <th class="text-center" width="20%">最近编辑</th>
<th class="text-center" width="35%">操作</th> <th class="text-center" width="35%">操作</th>
@ -47,16 +46,9 @@
<td>{$item['title']}</td> <td>{$item['title']}</td>
<td> <td>
{if $item['storename']} {if $item['storename']}
<!-- <label class="label label-primary">{$item['storename']}</label>--> <label class="label label-primary">{$item['storename']}</label>
{else} {else}
<!-- <label class="label label-info">当前代理</label>--> <label class="label label-info">当前代理</label>
{/if}
{if $item['template_type'] == 1}
<label class="label label-primary">{$item['template_type_title']}</label>
{elseif $item['template_type'] == 2}
<label class="label label-info">{$item['template_type_title']}</label>
{elseif $item['template_type'] == 3}
<label class="label label-success">{$item['template_type_title']}</label>
{/if} {/if}
</td> </td>
<td>{php echo date("Y-m-d H:i:s",$item['create_time']);}</td> <td>{php echo date("Y-m-d H:i:s",$item['create_time']);}</td>

204
addons/weliam_smartcity/web/view/default/agentset/diy_form/template_config.html

@ -9,18 +9,6 @@
</div> </div>
</div> </div>
</div> </div>
<div class="form-group">
<div class="col-sm-2 control-label">模板类型</div>
<div class="col-sm-9">
<div class="form-group">
<select v-model="params.template_type" name="template_type" class="form-control">
<option value="1">校园活动</option>
<!-- <option value="2">培训体验课</option>-->
<!-- <option value="3">平台活动</option>-->
</select>
</div>
</div>
</div>
<div class="form-group"> <div class="form-group">
<div class="col-sm-2 control-label">标题对齐</div> <div class="col-sm-2 control-label">标题对齐</div>
<div class="col-sm-9"> <div class="col-sm-9">
@ -76,18 +64,18 @@
</label> </label>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="info.att_show" value="0"> 显示--> <input type="radio" v-model="info.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="info.att_show" value="1"> 隐藏--> <input type="radio" v-model="info.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
</div> </div>
</template> </template>
<!-- 文本域 --> <!-- 文本域 -->
@ -138,18 +126,18 @@
</label> </label>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="0"> 显示--> <input type="radio" v-model="params.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="1"> 隐藏--> <input type="radio" v-model="params.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
</div> </div>
</template> </template>
<!-- 下拉框 --> <!-- 下拉框 -->
@ -177,18 +165,18 @@
</div> </div>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="0"> 显示--> <input type="radio" v-model="params.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="1"> 隐藏--> <input type="radio" v-model="params.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
</div> </div>
</template> </template>
<!-- 多选框 --> <!-- 多选框 -->
@ -216,18 +204,18 @@
</div> </div>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="0"> 显示--> <input type="radio" v-model="params.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="1"> 隐藏--> <input type="radio" v-model="params.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
</div> </div>
</template> </template>
<!-- 图片 --> <!-- 图片 -->
@ -253,18 +241,18 @@
</div> </div>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="0"> 显示--> <input type="radio" v-model="params.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="1"> 隐藏--> <input type="radio" v-model="params.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
<div class="form-group"> <div class="form-group">
<div class="col-sm-2 control-label">是否必传</div> <div class="col-sm-2 control-label">是否必传</div>
<div class="col-sm-9"> <div class="col-sm-9">
@ -312,18 +300,18 @@
</div> </div>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="0"> 显示--> <input type="radio" v-model="params.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="1"> 隐藏--> <input type="radio" v-model="params.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
</div> </div>
</template> </template>
<!-- 时间范围 --> <!-- 时间范围 -->
@ -380,18 +368,18 @@
</div> </div>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="0"> 显示--> <input type="radio" v-model="params.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="1"> 隐藏--> <input type="radio" v-model="params.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
</div> </div>
</template> </template>
<!-- 城市 --> <!-- 城市 -->
@ -419,17 +407,17 @@
</label> </label>
</div> </div>
</div> </div>
<!-- <div class="form-group" v-if="attflag">--> <div class="form-group" v-if="attflag">
<!-- <div class="col-sm-2 control-label">认证内容显示</div>--> <div class="col-sm-2 control-label">认证内容显示</div>
<!-- <div class="col-sm-9">--> <div class="col-sm-9">
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="0"> 显示--> <input type="radio" v-model="params.att_show" value="0"> 显示
<!-- </label>--> </label>
<!-- <label class="radio-inline">--> <label class="radio-inline">
<!-- <input type="radio" v-model="params.att_show" value="1"> 隐藏--> <input type="radio" v-model="params.att_show" value="1"> 隐藏
<!-- </label>--> </label>
<!-- <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>--> <span class="help-block">当此表单作为商户认证表单时,是否显示把此项内容显示在商户资质中。</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
</div> </div>
</template> </template>
Loading…
Cancel
Save