'零售店',
// 2 => '已签署',
// 3 => '已作废',
);
$status = array
(
1 => '待交付',
2 => '已交付',
// 3 => '已作废',
);
$manage_audit = array
(
1 => '待财务终审',
2 => '交付确认',
3 => '已完成',
4 => '驳回',
);
$audit = array
(
1 => '审核通过',
2 => '拒绝',
);
$col = Dever::input('col');
$policy = function()
{
$array = array();
$data = Dever::load('agent/option_policy-state');
if($data)
{
$array += $data;
}
return $array;
};
$exercise = function()
{
$array = array();
$data = Dever::load('agent/option_exercise-state');
if($data)
{
$array += $data;
}
return $array;
};
$release = function()
{
$array = array();
$data = Dever::load('agent/option_release-state');
if($data)
{
$array += $data;
}
return $array;
};
return array
(
# 表名
'name' => 'option_account',
# 显示给用户看的名称
'lang' => '期权账户管理',
'order' => 1,
// 'config_type' => $type,
'config_status' => $status,
'end' => array
(
'update' => 'agent/lib/option_account.updateAccount',
'insert' => 'agent/lib/option_account.updateAccount',
),
# 数据结构
'struct' => array
(
'id' => array
(
'type' => 'int-11',
'name' => '受益人姓名/电话',
'default' => '',
'desc' => '',
'match' => 'is_numeric',
'search' => 'order',
'search' => array
(
'api' => 'agent/option_account-getSearch',
'col' => 'col',
'result' => 'id',
'search' => 'id',
),
// 'update' => 'hidden',
//'list' => true,
),
'name' => array
(
'type' => 'varchar-100',
'name' => '受益人姓名',
'default' => '',
'desc' => '姓名',
'match' => 'is_string',
'update' => 'text',
'list_name' => '受益人',
'list' => 'Dever::load("agent/lib/option_account.show#list",{id})',
),
'mobile' => array
(
'type' => 'bigint-11',
'name' => '受益人电话',
'default' => '',
'desc' => '请输入受益人电话',
'match' => Dever::rule('mobile'),
'update' => 'text',
// 'search' => 'fulltext',
// 'list' => true,
),
'email' => array
(
'type' => 'varchar-150',
'name' => '邮箱',
'default' => '',
'desc' => '请输入邮箱',
'match' => 'option||' . Dever::rule('email'),
'update' => 'text',
),
'idcard' => array
(
'type' => 'varchar-32',
'name' => '身份证号码',
'default' => '',
'desc' => '身份证号码',
'match' => Dever::rule('idcard'),
'search' => 'fulltext',
'update' => 'text',
),
'area' => array
(
'type' => 'varchar-500',
'name' => '门店地址',
'default' => '',
'desc' => '门店地址',
'match' => 'option',
'search' => 'linkage',
'update' => 'linkage',
'option' => Dever::url('api.get?level_total=4', 'area'),
),
'address' => array
(
'type' => 'varchar-200',
'name' => '详细地址',
'default' => '',
'desc' => '地址',
'match' => 'is_string',
'update' => 'text',
// 'list' => true,
),
'number' => array
(
'type' => 'varchar-200',
'name' => '门店编号',
'default' => '',
'desc' => '门店编号',
'match' => 'is_string',
'update' => 'text',
// 'list' => true,
),
'title' => array
(
'type' => 'varchar-100',
'name' => '期权记录标题',
'default' => '',
'desc' => '期权记录标题',
'match' => 'is_string',
'update' => 'text',
'list' => true,
),
'desc' => array
(
'type' => 'varchar-600',
'name' => '说明',
'default' => '',
'desc' => '记录说明',
'match' => 'option',
'update' => 'textarea',
'list' => true,
),
'type' => array
(
'type' => 'tinyint-1',
'name' => '记录类型',
'default' => '1',
'desc' => '记录类型',
'match' => 'is_numeric',
'update' => 'radio',
'option' => $type,
// 'search' => 'select',
// 'list' => true,
),
'price' => array
(
'type' => 'decimal-11,2',
'name' => '开店投入金额-单位:元',
'default' => '0',
'desc' => '开店投入金额',
'match' => 'is_numeric',
'update' => 'text',
'list_name' => '开店投入金额
政策对应期权价值
实际补贴期权价值',
'list' => 'Dever::load("agent/lib/option_account.show#price",{id})',
'list_order' => 9,
),
'policy_id' => array
(
'type' => 'int-11',
'name' => '零售店政策',
'default' => '',
'desc' => '零售店政策',
'match' => 'is_numeric',
'search' => 'select',
'update' => 'radio',
'option' => $policy,
// 'list' => $search_auth == 2 ? true : false,
),
'zh_price' => array
(
'type' => 'decimal-11,2',
'name' => '政策对应期权价值-单位:元',
'default' => '0',
'desc' => '政策对应期权价值',
'match' => 'is_numeric',
'update' => 'text',
// 'list' => true,
),
'zj_price' => array
(
'type' => 'decimal-11,2',
'name' => '实际补贴期权价值-单位:元',
'default' => '0',
'desc' => '实际补贴期权价值',
'match' => 'is_numeric',
'update' => 'text',
// 'list' => true,
),
'exercise_id' => array
(
'type' => 'varchar-32',
'name' => '行权条件',
'default' => '',
'desc' => '行权条件',
'match' => 'is_numeric',
'search' => 'select',
'update' => 'checkbox',
'option' => $exercise,
// 'list' => $search_auth == 2 ? true : false,
),
'release_id' => array
(
'type' => 'int-11',
'name' => '释放比例',
'default' => '',
'desc' => '释放比例',
'match' => 'is_numeric',
'search' => 'select',
'update' => 'radio',
'option' => $release,
// 'list' => $search_auth == 2 ? true : false,
),
// 'other_price' => array
// (
// 'type' => 'decimal-11,2',
// 'name' => '其他费用-单位:万元',
// 'default' => '0',
// 'desc' => '其他费用',
// 'match' => 'option',
// 'update' => 'text',
// // 'list' => true,
// ),
'pic' => array
(
'type' => 'text-255',
'name' => '上传凭证-门店租赁合同,支付凭证等',
'default' => '',
'desc' => '多张图片',
'match' => 'is_string',
'update' => 'images',
'key' => '1',
// 'place' => '759*562',
),
'annex' => array
(
'type' => 'text-800',
'name' => '上传附件',
'default' => '',
'desc' => '上传附件',
'match' => 'option',
'update' => 'upload',
'key' => '10',
// 'place' => '759*562',
),
'status' => array
(
'type' => 'tinyint-1',
'name' => '交付状态',
'default' => '1',
'desc' => '交付状态',
'match' => 'is_numeric',
// 'update' => 'select',
'option' => $status,
'search' => 'select',
'list_name' => '交付状态
交付时间',
'list' => 'Dever::load("agent/lib/option_account.show#date",{id})',
),
'jf_date' => array
(
'type' => 'int-11',
'name' => '交付时间',
'match' => 'option',
'default' => '0',
'desc' => '',
'match' => 'is_numeric',
// 'update' => 'day',
'search' => 'date',
'callback' => 'maketime',
// 'list' => '{buy_date} > 0 ? date("Y-m-d H:i", {buy_date}) : "无"',
),
'audit_type' => array
(
'type' => 'tinyint-1',
'name' => '审核状态',
'default' => '1',
'desc' => '审核状态',
'match' => 'is_numeric',
// 'update' => 'select',
'option' => $manage_audit,
'search' => 'select',
'list_name' => '审核状态
审核时间',
'list' => 'Dever::load("agent/lib/option_account.show#audit",{id})',
),
'audit_date' => array
(
'type' => 'int-11',
'name' => '审核时间',
'match' => 'option',
'default' => '0',
'desc' => '',
'match' => 'is_numeric',
// 'update' => 'day',
'search' => 'date',
'callback' => 'maketime',
// 'list' => '{buy_date} > 0 ? date("Y-m-d H:i", {buy_date}) : "无"',
),
'audit' => array
(
'type' => 'int-11',
'name' => '审核状态',
'default' => '1',
'desc' => '审核状态',
'match' => 'is_numeric',
'update' => $col ? 'radio' : false,
'option' => $audit,
// 'search' => 'select',
'mul' => true,
'control' => 'audit',
),
'remark' => array
(
'type' => 'varchar-600',
'name' => '备注',
'default' => '',
'desc' => '备注',
'match' => 'option',
'update' => 'textarea',
// 'list' => '"{audit_desc}" ? "{audit_desc}" : "-"',
// 'list_order' => 9,
'show' => 'audit=2',
),
'audit_desc' => array
(
'type' => 'varchar-600',
'name' => '审核说明',
'default' => '',
'desc' => '审核说明',
'match' => 'is_string',
'update' => $col ? 'textarea' : false,
// 'list' => '"{audit_desc}" ? "{audit_desc}" : "-"',
// 'list_order' => 9,
'show' => 'audit=2',
),
'num' => array
(
'type' => 'int-11',
'name' => '确认期权数-行权3年期。自门店注册日期开始计算。满一年30%,满两年35%,满三年35%',
'default' => '',
'desc' => '姓名',
'match' => 'is_numeric',
// 'update' => $col ? 'text' : false,
// 'show' => 'audit=1',
),
'audit_admin' => array
(
'type' => 'int-11',
'name' => '添加人',
'default' => '',
'match' => 'is_numeric',
'desc' => '操作人',
'list' => '"{audit_admin}" > 0 ? Dever::load("manage/admin-find#username", {audit_admin}) : "-"',
'list_order' => 10,
),
'state' => array
(
'type' => 'tinyint-1',
'name' => '状态',
'default' => '1',
'desc' => '请选择状态',
'match' => 'is_numeric',
),
'cdate' => array
(
'type' => 'int-11',
'name' => '添加时间',
'match' => array('is_numeric', time()),
'desc' => '',
# 只有insert时才生效
'insert' => true,
// 'search' => 'date',
'list' => 'date("Y-m-d H:i:s", {cdate})',
'list_order' => 11,
),
),
'manage' => array
(
// 'insert' => $insert,
'delete' => false,
'edit' => false,
// 'page_list' => 'option_account',
// 'button' => $button,
'list_button' => array
(
'list' => array('查看详情', '"option_policy&project=agent&id={id}&page_type=1&[refer]"'),
// 'list' => array('查看详情', 'Dever::load("agent/lib/option_account.list",{id})'),
),
'button' => array
(
'零售政策' => array('location', 'l=project/database/list&project=agent&table=option_policy&&oper_table=option_account&page_type=2'),
'行权条件' => array('location', 'l=project/database/list&project=agent&table=option_exercise&&oper_table=option_account'),
'释放比例' => array('location', 'l=project/database/list&project=agent&table=option_release&oper_table=option_account'),
),
),
'request' => array
(
'getSearch' => array
(
# 匹配的正则或函数 选填项
'option' => array
(
'col' => array('yes-mobile,name', 'like'),
),
'type' => 'all',
'col' => '*|id',
),
),
);