zhangyanpeng
2024-08-20 8f9dce08ec70dc436b86a782e7bcb13872e52390
调整
5个文件已修改
2个文件已添加
1124 ■■■■■ 已修改文件
css/myelement.css 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
module/fee/page/fee_execute.html 45 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
module/fee/page/fee_qty.html 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
module/fee/page/popup/outBasePreGrantList.html 282 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
module/fee/page/popup/popup_edit_fee_execute.html 240 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
module/flow/page/flow_sales_list.html 333 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
module/tool/page/popup_list_dataname.html 219 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
css/myelement.css
@@ -390,6 +390,9 @@
.h_table .el-input--mini .el-input__inner {
    height: 24px;
    line-height: 24px;
}
.h_table .el-input-number .el-input__inner {
    text-align: right;
    padding-left: 5px;
    padding-right: 5px;
module/fee/page/fee_execute.html
@@ -14,7 +14,7 @@
                new ListVue({
                    el: "#vbody",
                    data: {
                        dataname: "fee_guide_settle_execute",
                        dataname: "fee_task_execute",
                        title: "执行单",
                        orderby: "",
                        filterfieldClick: {},
@@ -158,31 +158,8 @@
                                        notclick_val: "",//不可点击的值,1、是数组["11","22"];2、以“;”分隔的字符串"111;222"
                                        notclick_bindfield: [],//当该字段值等于指定字段值时不可点击["filterfield": "111"]
                                        onclick: function(obj) {//数据值点击事件
                                            var sceneCode_ = "browse";
                                            //如果是创建人且是录入状态或退回状态则是编辑状态
                                            if (obj.row.creator_id == window.top.vue.userinfo.id && (obj.row.state_code == "Input" || obj.row.state_code == "input" || obj.row.state_code == "Rejected")) {
                                                sceneCode_ = "edit";
                                            }
                                            var config = {
                                                totab: true, //true: 以Tab导航的方式打开
                                                width: "1100px",
                                                height: "520px",
                                                icon: "icon-product",
                                                text: "商业信息 " + (obj.row.name ? obj.row.name : ""),
                                                id: "customer_edit_browse" + obj.row.id,//totab: true时需设置,用于判断是否已打开此页面
                                                url: "module/md/page/customer/page/customer_edit.html",
                                                data: obj.row,
                                                delta: {closeCode:"1"},
                                                sceneCode: sceneCode_,//"refuseedit",//"approval", //"add"//"browse",
                                                callback: function(obj, callback) {
                                                    me.onQuery();
                                                    if (callback) {
                                                        callback();
                                                    }
                                                }
                                            };
                                            me.doPopupByPublic(config);
                                            me.editData("browse", obj.row);
                                        },
                                    },    
                                },
@@ -193,11 +170,12 @@
                            var me = this;
                            me.selectedrow = obj.row;
                        },
                        editData(sceneCode) {
                        addData() {
                            this.editData("add", {});
                        },
                        editData(sceneCode, row) {
                            var me = this;
                            var row = me.selectedrow;
                            if(!row){
                            if(sceneCode == "edit" && !row){
                                Root.message({
                                    type: 'warning',
                                    message: '请选择一条数据'
@@ -209,9 +187,9 @@
                                width: "900px",
                                height: "500px",
                                icon: "icon-product",
                                text: "数量单编辑",
                                id: "popup_edit_fee_qty" + sceneCode + row.id,//totab: true时需设置,用于判断是否已打开此页面
                                url: "module/fee/page/popup/popup_edit_fee_qty.html",
                                text: "执行单编辑",
                                id: "popup_edit_fee_execute" + sceneCode + row.id,//totab: true时需设置,用于判断是否已打开此页面
                                url: "module/fee/page/popup/popup_edit_fee_execute.html",
                                data: row,
                                delta: {},
                                sceneCode: sceneCode,//"refuseedit",//"approval", //"add"//"browse",
@@ -280,7 +258,8 @@
                    
                    <div :class="page_title == 'right' ? 'h_page_button_left' : 'h_page_button_right'">
                        <el-button-group style="margin-left: 3px;">
                            <el-button :disabled="!(selectedrow.id)" @click="editData('edit') " :icon="buttonsconfig.alter.icon":icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
                            <el-button  @click="addData() " :icon="buttonsconfig.add.icon">{{buttonsconfig.add.name}}</el-button>
                            <el-button :disabled="!(selectedrow.id)" @click="editData('edit', selectedrow) " :icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
                        </el-button-group>
                        
                        <el-button v-show="cbuttons_r.export ? cbuttons_r.export : false" @click="onDownload" :icon="buttonsconfig.export.icon">{{buttonsconfig.export.name}}</el-button>
module/fee/page/fee_qty.html
@@ -280,7 +280,7 @@
                    
                    <div :class="page_title == 'right' ? 'h_page_button_left' : 'h_page_button_right'">
                        <el-button-group style="margin-left: 3px;">
                            <el-button :disabled="!(selectedrow.id)" @click="editData('edit') " :icon="buttonsconfig.alter.icon":icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
                            <el-button :disabled="!(selectedrow.id)" @click="editData('edit') " :icon="buttonsconfig.alter.icon">{{buttonsconfig.alter.name}}</el-button>
                        </el-button-group>
                        
                        <el-button v-show="cbuttons_r.export ? cbuttons_r.export : false" @click="onDownload" :icon="buttonsconfig.export.icon">{{buttonsconfig.export.name}}</el-button>
module/fee/page/popup/outBasePreGrantList.html
New file
@@ -0,0 +1,282 @@
<!doctype html>
<html>
    <head>
        <meta charset="utf-8"><meta http-equiv="Expires" content="0"><meta http-equiv="Pragma" content="no-cache"><meta http-equiv="Cache-control" content="no-cache"><meta http-equiv="Cache" content="no-cache">
        <title>植入单列表</title>
        <script type="text/javascript">
            var pageVue = null;
            function loadJsCss(callback) {
                var jscss_urls = [];
                window.top.initJsCss(document, jscss_urls, callback);
            };
            function initVue() {
                new ListVue({
                    el: "#vbody",
                    data: {
                        dataname: "v_out_base_pre_grant",
                        title: "选择执行流向",
                        pageAttr: {
                            heightType: "popuppage"
                        },
                        default_filterFields: [
                            {isshow: "T", field: "code", name: "医院编码", filterfield:"", filteroperator: "like", type: ""},
                        ],
                        default_tableFields: [
                            {field: "code", name: "医院编码", isshow: "T", align: "center",width: "150"},
                            {field: "name", name: "医院", isshow: "T", align: "center"},
                        ],
                        default_tableData: [
                            {"code":"478389", "name":"武警湖北总队医院",},
                            {"code":"012345", "name":"常州市金坛区中医医院",},
                        ],
                        filterfieldClick: {},
                        tablefieldClick: {},
                        formfieldClick: {},
                        detailCancelDate: "",
                        tableHeight: 550,
                        basicfilterAttr: {
                            istitle: false,
                            title: "表单名称",
                            columnnumber: 5,
                            labelwidth: "0px",
                            labelposition: "left",//"left",// right//top
                            size: "mini",
                            border: "1px solid #c6c6c600"
                        },
                        selectedrows: [],
                        pagesize: 10,
                        filterData: {}
                    },
                    created() {
                        this.popupParames = clone(Root.popupParames);
                        // this.title = this.popupParames.title || this.popupParames.text
                        if (this.popupParames.filter) {
                            this.filterTxt = this.popupParames.filter
                        }
                        if (this.popupParames.delta && this.popupParames.delta.selectmap) {
                            this.filterData = this.popupParames.delta.selectmap;
                        }
                        if (this.popupParames.sceneCode) {
                            if (this.popupParames.sceneCode == "add") {//新增
                                this.isedit = true;
                            }
                        }
                    },
                    mounted() {
                        //获取数据
                        this.initData();
                        // 以服务的方式调用的 Loading 需要异步关闭
                        this.$nextTick(() => {
                            //重新设置弹窗宽高
                            this.$nextTick(function(){
                                //let w_ = this.$refs.popup_body.offsetWidth + "px";
                                let w_ = "1000px";
                                let h_ = "650px";
                                Root.setPopupWH(w_, h_);
                            })
                        });
                    },
                    methods:{
                        //关闭弹窗
                        closeDialog() {
                            this.docloseDialog(true);
                        },
                        //关闭前调回调
                        saveAfter() {
                            var me = this;
                            var selectedrows = this.$refs.table1.getShoppingcart();
                            if(this.popupParames.callback) {
                                let obj = {
                                    type: this.activeTabName,
                                    list: clone(selectedrows)
                                    // row: clone(this.selectedrow)
                                }
                                this.popupParames.callback(obj, function() {
                                    me.docloseDialog();
                                });
                            }
                            else {
                                me.docloseDialog();
                            }
                        },
                        initData() {
                            var me = this;
                            this.onQuery(function(result, callback) { //查询后的回调,用于获取字段的
                                if (result.meta && result.meta[me.dataname] && result.meta[me.dataname].fields) {
                                    var metas = clone(result.meta[me.dataname].fields);
                                    var filterFields_ = [];
                                    var tableFields_ = [];
                                    metas.map(f=>{
                                        f.isshow = "T";
                                        if (f.isfilter) {
                                            filterFields_.push(clone(f));
                                        }
                                        else {
                                            var filter_f = clone(f);
                                            filter_f.isshow = "F";
                                            filterFields_.push(filter_f);
                                        }
                                        tableFields_.push(clone(f));
                                    })
                                    if (!me.filterFields || (me.filterFields && me.filterFields.length == 0)) {
                                        me.filterFields = clone(filterFields_);
                                        me.tableFields = clone(tableFields_);
                                        //字段数组转字段obj,目的为了筛选时获取字段属性
                                        me.fieldsToFieldsObj();
                                        //设置字段事件
                                        me.tableFieldClick();
                                    }
                                }
                                if (callback) {
                                    callback();
                                }
                                hideLoading();
                            });
                        },
                        onQueryAfter() {
                            var me = this;
                            var tableData_ = clone(me.tableData);
                            tableData_.map(row=>{
                                var key_ = row.id
                                if (me.filterData[key_]) {
                                    row.h_classname = "z_notrowclick";
                                }
                            })
                            me.tableData = clone(tableData_);
                        },
                        tableFieldClick() {
                            var me = this;
                            //筛选字段事件设置
                            this.filterfieldClick = {
                            };
                            //表格字段事件设置
                            this.tablefieldClick = {
                            };
                            //表单字段事件设置
                            this.formfieldClick = {
                            };
                        },
                        selectionChange(obj){
                            var me = this;
                            me.selectedrows = obj;
                        },
                        saveShoppingcart(list) {
                            var me = this;
                            me.selectedrows = list;
                        },
                        // onRowDblClick() {
                        //     if (this.isedit) {
                        //         this.saveAfter();
                        //     }
                        // },
                    }
                });
            };
            loadJsCss(function () {
                initVue();
            });
        </script>
        <style>
            /* 在vue.js中 v-cloak 这个指令是防止页面加载时出现 vuejs 的变量名而设计的 */
            [v-cloak] {
                display: none !important;
            }
            .h_table .h_h_table .h_table_tool_right .h_table_right_filter {
                width: 85% !important;
            }
        </style>
    </head>
    <body style="margin: 0px;">
        <div v-cloak id="vbody">
            <div id="page_root">
                <div ref="popup_body" style="padding: 0 20px;">
                    <!-- 标题 -->
                    <div class="popup_el-dialog__header">
                        <div class="dialog-title">
                          <i class="iconfont icon-customermanagement"></i>
                          <span>{{title}}</span>
                        </div>
                    </div>
                    <!-- 主体 -->
                    <div class="h_dialog__body">
                        <h-table
                            v-if="isRefresh && tableFields && tableFields.length"
                            ref="table1"
                            :table-fields="tableFields"
                            :table-data="tableData"
                            :pagesize="pagesize"
                            :pagenum="pagenum"
                            :total="total"
                            :table-height="tableHeight"
                            :table-field-click="tablefieldClick"
                            :is-highlight-row="isedit"
                            :filtersobj="filterObj"
                            :basicfilterfieldslength="5"
                            :basicfilter-attr="basicfilterAttr"
                            :isdraggableorder="false"
                            :isqueryloading="tableloading"
                            v-on:get-data="getData"
                            v-on:row-click="rowClick"
                            :select-table-data="selectedrows"
                            :is-selection="true"
                            :isshow-shoppingcart="true"
                            v-on:selection-change="selectionChange"
                            v-on:save-shoppingcart="saveShoppingcart"
                            >
                        </h-table>
                    </div>
                    <!-- 底部工具栏 -->
                    <div class="el-dialog__footer" v-show="tableFields && tableFields.length">
                        <el-button size="small" type="default" @click="closeDialog">取 消</el-button>
                        <el-button size="small" v-if="isedit" type="primary" @click="saveAfter">确 定</el-button>
                    </div>
                </div>
            </div>
        </div>
        <div id="page_loading" style="position: absolute; top:0px; width: 100vw; height: 50vh;">
            <div class="spinner">
              <div class="cube1"></div>
              <div class="cube2"></div>
            </div>
        </div>
    </body>
</html>
module/fee/page/popup/popup_edit_fee_execute.html
@@ -16,18 +16,18 @@
                    el: "#vbody",
                    data: {
                        dataname: "fee_task_execute",
                        table_dataname: "fee_working_out_base_execute",
                        table_dataname: "v_fee_working_grant_detail",
                        title: "执行单信息",
                        dataRequest: [
                            {
                                name: "fee_working_out_base_execute", // 业务负责人字段
                                dataname: "fee_working_out_base_execute",
                                name: "v_fee_working_grant_detail", // 业务负责人字段
                                dataname: "v_fee_working_grant_detail",
                                url: "root/data/getEntitySet",
                                paramsobj: {dataname: "fee_working_out_base_execute", attachMeta: true, filter: "1<>1"},
                                paramsobj: {dataname: "v_fee_working_grant_detail", attachMeta: true, filter: "1<>1"},
                                isnotoption: true, //true:不是选项
                            }
                        ],
                        meta_fee_working_out_base_execute: [],
                        meta_v_fee_working_grant_detail: [],
                        
                        options_md_org_master: [],
                        md_bu_org_obj: {},
@@ -51,6 +51,7 @@
                        formFields: [],
                        
                        newformData: {
                            code: createBaseCode("ZX"),
                            state_code: "Input",
                            state_name: "录入",
                            is_active: true,
@@ -58,7 +59,9 @@
                            type_code: "Customer", // Standard标准价目表、Customer经销商价目表
                        },
                        formData: {},
                        formDataDefault: {
                            guide_id: "fee_guide_settle_execute"
                        },
                        isRefresh: true,
                        tableFields: [],
                        tableData: [],
@@ -92,13 +95,14 @@
                        approveremark: '',//填写理由
                        passOrRefuse:false,
                        loading_pass: false,
                        tablebuttonClick: []
                    },
                    created() {
                        this.popupParames = clone(Root.popupParames);
                        // this.title = this.popupParames.title || this.popupParames.text
                        if (this.popupParames.data) {
                            if (this.popupParames.data._datano) {
                                this.title = this.title + this.popupParames.data._datano;
                            if (this.popupParames.data.code) {
                                this.title = this.title + this.popupParames.data.code;
                            }
                            this.formData = clone(this.popupParames.data);
                        }
@@ -137,9 +141,9 @@
                                this.formAttr.disabled = true;
                                this.isapproval = true;
                                
                                if (this.formData.current_step_name && this.formData.current_step_name == "运营部门复核") {
                                    this.isedit = true;
                                }
                                // if (this.formData.current_step_name && this.formData.current_step_name == "运营部门复核") {
                                //     this.isedit = true;
                                // }
                                
                            }
                            else if (this.popupParames.sceneCode == "refuseedit") {//拒绝后的编辑
@@ -176,15 +180,15 @@
                                    }
                                }
                                // 获取变更的字段
                                if (me.dataRequestObj.fee_working_out_base_execute) {
                                    let meta_ = me.dataRequestObj.fee_working_out_base_execute.meta.fee_working_out_base_execute.fields;
                                if (me.dataRequestObj.v_fee_working_grant_detail) {
                                    let meta_ = me.dataRequestObj.v_fee_working_grant_detail.meta.v_fee_working_grant_detail.fields;
                                    meta_.map(f=>{
                                        f.isshow = "T";
                                        if (f.field == "_qty_trans" || f.field == "_qty_cal" || f.field == "_qty_final" || f.field == "_amt_final") {
                                        if (f.field == "grant_amt" || f.field == "grant_qty") {
                                            f.isfixed = "right";
                                        }
                                    })
                                    me.meta_fee_working_out_base_execute = clone(meta_)
                                    me.meta_v_fee_working_grant_detail = clone(meta_)
                                }
                                me.initData();
                            });
@@ -240,36 +244,14 @@
                                    
                                    metas.map(f=>{
                                        f.isshow = "T";
                                        if (f.field == "company_id") {
                                            // f.isshow = "F";
                                            f.options = me.options_md_org_master
                                        if (f.field == "amt") {
                                            f.inputtype = "span"
                                        }
                                        if (f.field == "product_id") {
                                            f.props = {label: "value", value: "code", multiple: false};
                                            if (me.options_product.length) {
                                                f.options = clone(me.options_product);
                                            }
                                            else if (me.formData.bu_id && me.md_bu_product_obj[me.formData.bu_id]) {
                                                f.options = clone(me.md_bu_product_obj[me.formData.bu_id].children);
                                            }
                                            else {
                                                f.options = [];
                                            }
                                        }
                                        // if (f.field == "customer_name" && (me.popupParames.sceneCode == "addbyagreement" || me.popupParames.sceneCode == "editbyagreement")) {
                                        //     f.disabled = true;
                                        // }
                                        // if ((f.field == "date_from" || f.field == "date_to") && (me.popupParames.sceneCode == "addbyagreement" || me.popupParames.sceneCode == "editbyagreement")) {
                                        //     f.isshow = false;
                                        // }
                                        formFields_.push(clone(f));
                                    })
                                    if (!me.formFields || (me.formFields && me.formFields.length == 0)) {
                                        me.formFields = clone(formFields_);
                                        me.tableFields = clone(me.meta_fee_working_out_base_execute);
                                        me.tableFields = clone(me.meta_v_fee_working_grant_detail);
                                        
                                        //设置字段事件
                                        me.tableFieldClick();
@@ -305,6 +287,11 @@
                                        me.formFields = clone(formFields_);
                                    }
                                    me.onTableQuery();
                                }
                                // 是否需要弹出植入单选择窗
                                if(me.popupParames.sceneCode == "add") {
                                    me.selectDetailPopup(true);
                                }
                            })
                        },
@@ -360,29 +347,122 @@
                            };
                            
                            this.tablefieldClick = {
                                _qty_trans: {
                                grant_qty: {
                                    input: {
                                        onchange: function(obj) {
                                            obj.row._qty_trans = obj.row._qty_trans * 1;
                                            if (obj.row._qty_cal) {
                                                obj.row._qty_final = (obj.row._qty_cal * 1) - (obj.row._qty_trans * 1)
                                                obj.row._amt_final = obj.row._qty_final  * obj.row._taxunitprice
                                            obj.row.grant_qty = obj.row.grant_qty * 1;
                                            var grant_price = 0;
                                            if (obj.row.grant_price) {
                                                grant_price = obj.row.grant_price
                                            }
                                            else if (table_row.grant_qty && table_row.grant_amt) {
                                                grant_price = table_row.grant_amt / table_row.grant_qty
                                            }
                                            obj.row.grant_amt = grant_price  * obj.row.grant_qty
                                            if (obj.row.id) {
                                            me.saveTableRow(obj.row);
                                            }
                                        }
                                    }
                                },
                            }
                            this.tablebuttonClick = [
                                {
                                    // name: "新增", // type: "primary", // icon: "el-icon-edit",
                                    isbuttonshow: me.isedit,
                                    code: "add", isselected: false, classname: "",
                                    onclick: function(obj) {
                                        me.selectDetailPopup(false)
                                    }
                                },
                                // {
                                //     // name: "删除", // type: "primary", // icon: "el-icon-edit",
                                //     isbuttonshow: me.isedit,    type: "danger",
                                //     code: "delete", isselected: true, classname: "",
                                //     disabled: function(selectRowList) {
                                //         var bo_ = true;
                                //         if (selectRowList[0] && selectRowList[0].state_code == "Input") {
                                //             bo_ = false;
                                //         }
                                //         return bo_
                                //     },
                                //     onclick: function(obj) {
                                //         me.delData()
                                //     }
                                // },
                            ]
                        },
                        selectDetailPopup(isclose) {
                            var me = this;
                            //排除已选物料
                            var selectmap_ = {};
                            me.tableData.map(row=>{
                                if (row.sell_qty_id) {
                                    var key_ = row.sell_qty_id
                                    selectmap_[key_] = true
                                }
                            })
                            var filter_ = "";
                            var config = {
                                totab: false, //true: 以Tab导航的方式打开
                                width: "1000px",
                                height: "650px",
                                icon: "icon-product",
                                filter: filter_,
                                text: "选择执行流向",
                                id: "outBasePreGrantList" + "add",//totab: true时需设置,用于判断是否已打开此页面
                                url: "module/fee/page/popup/outBasePreGrantList.html",
                                delta: {selectmap: selectmap_},
                                sceneCode: "add", //"refuseedit",//"approval", //"add"//"browse",
                                closecallback: function() {
                                    if (isclose) {
                                        me.closeDialog();
                                    }
                                },
                                callback: function(obj, callback) {
                                    me.loadDetailData(obj);
                                    if (callback) {
                                        callback();
                                    }
                                }
                            };
                            me.doPopupByPublic(config);
                        },
                        // 首次创建撤销单的植入单数据
                        loadDetailData(obj) {
                            var me = this;
                            me.formData.guide_id = me.formDataDefault.guide_id;
                            // 明细表格数据
                            var list_h = clone(obj.list); //购物车返回一个数组
                            var tableData_ = clone(me.tableData);
                            list_h.map(row=>{
                                console.log(row);
                                var table_row = clone(row);
                                table_row.id = null
                                table_row.task_id = null
                                table_row.data_no = row.datano
                                table_row.sell_qty_id = row.id
                                table_row.out_fee_id = row.out_fee_id
                                table_row.grant_qty = row.qty_check - (row.qty_grant ? row.qty_grant : 0)
                                table_row.grant_amt = row.amt_check ? row.amt_check/row.qty_check * (row.qty_check - (row.qty_grant ? row.qty_grant : 0)) : 0
                                table_row.grant_price = row.amt_check ? row.amt_check/row.qty_check : 0
                                tableData_.unshift(table_row)
                            })
                            me.tableData = clone(tableData_);
                        },
                        
                        saveTableRow(row) {
                            var me = this;
                            var entity_ = clone(row);
                            var entity = {
                                _qty_trans: entity_._qty_trans,
                                _qty_final: entity_._qty_final,
                                _amt_final: entity_._amt_final,
                                grant_qty: entity_.grant_qty,
                                grant_amt: entity_.grant_amt,
                                id: entity_.id
                            };
                            
@@ -567,7 +647,7 @@
                            let param_ = {
                                dataname: this.table_dataname,
                                filter: filter_,
                                orderby: "_dataNo",
                                orderby: "dataNo",
                                page: {
                                    pageno: this.pagenum,
                                    pagesize: this.pagesize
@@ -613,26 +693,52 @@
                        saveRowTable(callback) {
                            var me = this;
                            var operator_ = "saveEntity";//保存
                            // if(me.iscommit) {
                            //     operator_ = "commit";//提交
                            // }
                            if(me.iscommit) {
                                operator_ = "commit";//提交
                            }
                            
                            var entity_ = clone(this.formData);
                            var entity = {
                                _qty_trans: entity_._qty_trans,
                                _qty_final: entity_._qty_final,
                                _amt_final: entity_._amt_final,
                                id: entity_.id
                            };
                            var tableData_v = clone(this.tableData);
                            // var entity = {
                            //     _qty_trans: entity_._qty_trans,
                            //     _qty_final: entity_._qty_final,
                            //     _amt_final: entity_._amt_final,
                            //     id: entity_.id
                            // };
                            var tableData_ = [];
                            var sum_grant_amt = 0;
                            tableData_v.map(r=>{
                                var r_ = {
                                    data_no: r.data_no || r.datano,
                                    sell_qty_id: r.sell_qty_id,
                                    out_fee_id: r.out_fee_id,
                                    grant_qty: r.grant_qty,
                                    grant_amt: r.grant_amt,
                                }
                                if (r.id) {
                                    r_.id = r.id
                                }
                                if (entity_.id) {
                                    r_.task_id = entity_.id
                                }
                            
                                if (r.grant_amt) {
                                    sum_grant_amt += r.grant_amt;
                                }
                                tableData_.push(r_)
                            })
                            entity_.amt = sum_grant_amt;
                            let param = {
                                dataname: me.dataname,
                                dataname: "fee_task_execute",
                                data: {},
                            }
                            if (me.formData.id) {
                                param.id = me.formData.id
                            }
                            param.data[me.dataname] = entity;
                            param.data["fee_task_execute"] = entity_;
                            param.data["fee_working_grant_detail"] = tableData_;
                            
                            Server.call("root/data/" + operator_, param, function(result) {
                                console.log(result);
@@ -895,11 +1001,15 @@
                                    :pagesize="pagesize"
                                    :pagenum="pagenum"
                                    :total="total"
                                    :table-height="dheight - 252 - 64"
                                    :table-height="dheight - 147 - 64 - (isedit ? 28 : 0)"
                                    :is-highlight-row="true"
                                    :isdraggableorder="false"
                                    :isshowtool="false"
                                    :isbasicfilterfields="false"
                                    :isshow-shoppingcart="false"
                                    :isbasicfilterfields="false"
                                    :isfilterfield="false"
                                    :table-buttons-click="tablebuttonClick"
                                    
                                    v-on:get-data="getData"
                                >
@@ -929,9 +1039,9 @@
                            <el-button  size="small" v-if="isapproval" type="danger" plain @click="onShowApproval('goback')">退回到上一步</el-button>
                        </el-button-group>
                        <el-button size="small" type="default" @click="closeDialog">取 消</el-button>
                        <!-- <el-button size="small" v-if="isedit || isrefuseedit" type="primary" :loading="loading_save" @click="saveRowTable()":icon="buttonsconfig.save.icon">{{buttonsconfig.save.name}}</el-button>
                        <el-button size="small" v-if="isedit || isrefuseedit" type="primary" :loading="loading_save" @click="saveRowTable()":icon="buttonsconfig.save.icon">{{buttonsconfig.save.name}}</el-button>
                        <el-button size="small" v-if="isedit && !formData.agreement_id" type="success" :loading="loading_submit" @click="submitRowTable":icon="buttonsconfig.submit.icon">{{buttonsconfig.submit.name}}</el-button>
                         -->
                        <el-button size="small" v-if="isrefuseedit" type="success" @click="">再次提交</el-button>
                        
                        <el-button size="small" v-if="isapproval" type="success" @click="onShowApproval('approve')">通 过</el-button>
module/flow/page/flow_sales_list.html
@@ -18,7 +18,7 @@
                        title: "销售流向",
                        //Tab项设置
                        tabs_d: [
                            {code: "month", name: "月流向", dataname: "flow_month_sell", filterTxt: "", orderby: ""},
                            {code: "month", name: "月流向", dataname: "flow_month_sell_sum", filterTxt: "", orderby: ""},
                            {code: "daily", name: "日流向", dataname: "flow_daily_sell", filterTxt: "", orderby: ""},
                        ],
                        d_tabs: {
@@ -41,9 +41,10 @@
                            {isshow: "T", field: "org_code", name: "经销商编码", filterfield:"", filteroperator: "like", type: ""},
                            {isshow: "T", field: "org_name", name: "经销商名称", filterfield:"", filteroperator: "like", type: ""},
                        ],
                        dataversion: "月度初版",
                        default_filterObj: {
                            month: {
                                dataversion: "月度初版"
                                // dataversion: "月度初版"
                                //year: new Date().getFullYear().toString(),
                                //month: (new Date().getMonth() + 1).toString(),
                                // month: dateFormat(new Date(), "yyyy-MM"),
@@ -218,163 +219,33 @@
                        tableFieldClick() {
                            var me = this;
                            //辖区医院列表
                            var tablefieldClick_hospital = {
                                code: {//字段事件设置
                            var tablefieldClick_month = {
                                // flow_month_sell_qty__qty_check
                                // flow_month_sell_qty__amt_check
                                // flow_month_sell_qty__qty_grant
                                // flow_month_sell_qty__amt_grant
                                flow_month_sell_qty__qty_check: {//字段事件设置
                                    val: {//有值时的点击事件
                                        onclick: function(obj) {//数据值点击事件
                                            me.showInfo(obj);
                                            var filter_ = "_datano='"+ obj.row.datano +"'"
                                            me.showInfo(obj, "v_fee_working_qty_task", filter_, "结算明细");
                                        },
                                    },
                                }
                            };
                            //辖区变更
                            var tablefieldClick_info = {
                                //waiting
                                hospital_code: {//字段事件设置
                                },
                                flow_month_sell_qty__qty_grant: {//字段事件设置
                                    val: {//有值时的点击事件
                                        onclick: function(obj) {//数据值点击事件
                                            me.showChangeInfo(obj);
                                            var filter_ = "datano='"+ obj.row.datano +"'"
                                            me.showInfo(obj, "v_fee_working_grant_task", filter_, "执行明细");
                                        },
                                    },
                                },
                                state_name: {//状态
                                    val: {//有值时的点击事件
                                        notclick_val: ["草稿","草稿"],
                                        notclick_bindfield: [],
                                        onclick: function(obj) {
                                            var config = {
                                                totab: false,
                                                width: "1100px",
                                                height: "520px",
                                                icon: "icon-product",
                                                text: "流程步骤",
                                                id: "popup_workflow_step_user" + obj.row.id,
                                                url: "module/tool/page/popup_workflow_step_user.html?v=2023020703",
                                                data: obj.row,
                                                delta: {},
                                                sceneCode: "browse",
                                                callback: function(obj, callback) {
                                                    if (callback) {
                                                        callback();
                                                    }
                                                }
                                            };
                                            me.doPopupByPublic(config);
                                        },
                                    },
                                },
                            };
                            //医院授权列表
                            var tablefieldClick_org = {
                                category_name: {//授权产品
                                    val: {
                                        notclick_val: "",//不可点击的值,1、是数组["11","22"];2、以“;”分隔的字符串"111;222"
                                        notclick_bindfield: [
                                            {
                                                field: "id",
                                                val: null,
                                            }
                                        ],//当该字段值等于指定字段值时不可点击["filterfield": "111"]
                                        onclick: function(obj) {//数据值点击事件
                                            me.showAuthInfo(obj.row)
                                        },
                                    },
                                    defaultval: {
                                        val: "查看",//空值时的显示值
                                        onclick: function(obj) {//默认值点击事件,此事件需要设置val才有效
                                            me.showAuthInfo(obj.row)
                                        }
                                    },
                                },
                                state_name: {//状态
                                    val: {//有值时的点击事件
                                        notclick_val: ["草稿","草稿"],
                                        notclick_bindfield: [],
                                        onclick: function(obj) {
                                            var config = {
                                                totab: false,
                                                width: "1100px",
                                                height: "520px",
                                                icon: "icon-product",
                                                text: "流程步骤",
                                                id: "popup_workflow_step_user" + obj.row.id,
                                                url: "module/tool/page/popup_workflow_step_user.html?v=2023020703",
                                                data: obj.row,
                                                delta: {},
                                                sceneCode: "browse",
                                                callback: function(obj, callback) {
                                                    if (callback) {
                                                        callback();
                                                    }
                                                }
                                            };
                                            me.doPopupByPublic(config);
                                        },
                                    },
                                },
                            };
                            //授权变更
                            var tablefieldClick_auth = {
                                state_name: {//状态
                                    val: {//有值时的点击事件
                                        notclick_val: ["草稿","草稿"],
                                        notclick_bindfield: [],
                                        onclick: function(obj) {
                                            var config = {
                                                totab: false,
                                                width: "1100px",
                                                height: "520px",
                                                icon: "icon-product",
                                                text: "流程步骤",
                                                id: "popup_workflow_step_user" + obj.row.id,
                                                url: "module/tool/page/popup_workflow_step_user.html?v=2023020703",
                                                data: obj.row,
                                                delta: {},
                                                sceneCode: "browse",
                                                callback: function(obj, callback) {
                                                    if (callback) {
                                                        callback();
                                                    }
                                                }
                                            };
                                            me.doPopupByPublic(config);
                                        },
                                    },
                                },
                                type_name: {//授权产品
                                    val: {
                                        notclick_val: "",//不可点击的值,1、是数组["11","22"];2、以“;”分隔的字符串"111;222"
                                        notclick_bindfield: [],//当该字段值等于指定字段值时不可点击["filterfield": "111"]
                                        onclick: function(obj) {//数据值点击事件
                                            me.showAuthChange(obj.row)
                                        },
                                    },
                                    defaultval: {
                                        val: "查看",//空值时的显示值
                                        onclick: function(obj) {//默认值点击事件,此事件需要设置val才有效
                                            me.showAuthChange(obj.row)
                                        }
                                    },
                                },
                            };
                            
                            var filterfieldClick = {};
                            //医院管理列表-辖区医院tab
                            if (this.selectTabObj.code == "hospital") {
                                this.selectTabObj.tablefieldClick = tablefieldClick_hospital;
                            }
                            //辖区新增/变更-辖区审批中、全部辖区申请tab
                            else if (this.selectTabObj.code == "infoUnderApproval" || this.selectTabObj.code == "infoAll") {
                                this.selectTabObj.tablefieldClick = tablefieldClick_info;
                            }
                            //医院授权列表-医院授权tab
                            else if (this.selectTabObj.code == "authorize") {
                                this.selectTabObj.tablefieldClick = tablefieldClick_org;
                            }
                            //授权变更-授权审批中、全部授权申请tab
                            else if (this.selectTabObj.code == "authUnderApproval" || this.selectTabObj.code == "authAll") {
                                this.selectTabObj.tablefieldClick = tablefieldClick_auth;
                            if (this.selectTabObj.code == "month") {
                                this.selectTabObj.tablefieldClick = tablefieldClick_month;
                            }
                            
                            this.filterfieldClick = filterfieldClick;
@@ -465,173 +336,23 @@
                            }
                        },
                        
                        delDataPolicy(obj, row) {
                            let me = this;
                            let name_ = "该数据";
                            if (!row.id) {
                                Root.message({
                                    type: 'warning',
                                    message: '请选择删除数据'
                                });
                                return
                            }
                            if (row.md_hospital__name) {
                                name_ = "_" + row.md_hospital__name + "_";
                            }
                            Root.confirm('确定删除' + name_ + '吗?', '删除提示', {
                              confirmButtonText: '删除',
                              cancelButtonText: '取消',
                              type: 'warning'
                            }).then(() => {
                                let param = {
                                    id: row.id,
                                    dataname: me.selectTabObj.dataname,
                                }
                                Server.call("root/data/deleteEntity", param, function(result) {
                                    Root.message({
                                        type: 'success',
                                        message: '删除成功!'
                                    });
                                    me.onQuery();
                                });
                            }).catch(() => {
                                Root.message({
                                    type: 'info',
                                    message: '已取消删除'
                                });
                            });
                        },
                        commitData(obj) {
                        // 通用查看弹窗
                        showInfo(obj, dataname, filter, text) {
                            var me = this;
                            Root.confirm('确定提交辖区医院' + obj.md_hospital__name + '吗?', '提交提示', {
                              confirmButtonText: '提交',
                              cancelButtonText: '取消',
                              type: 'warning'
                            }).then(() => {
                                var param = {
                                    dataname: me.selectTabObj.dataname,
                                    id: obj.id,
                                    to_state: "OpeningApproval"
                                }
                                console.log(me.selectTabObj)
                                Server.call("root/data/commit", param, function(result) {
                                    console.log(result);
                                    if (result.success) {
                                        Root.message({
                                            type: 'success',
                                            message: '提交成功'
                                        });
                                        me.onQuery();
                                    }
                                });
                            }).catch(() => {
                                Root.message({
                                    type: 'info',
                                    message: '已取消'
                                });
                            });
                        },
                        openPolicy(sceneCode, row) {
                            let me = this;
                            var text = "";
                            // type_code: "", // Standard标准价目表、Customer经销商价目表
                            if (sceneCode == "add") {
                            }
                            else if (sceneCode == "edit" || sceneCode == "browse") {
                                if(!row){
                                    Root.message({
                                        type: 'warning',
                                        message: '请选择一条数据'
                                    });
                                    return;
                                }
                                // if (row.customer_name) {
                                //     text = row.customer_name;
                                // }
                            }
                            var config = {
                                totab: false, //true: 以Tab导航的方式打开
                                width: "900px",
                                height: "320px",
                                icon: "icon-product",
                                text: "辖区医院" + text,
                                id: "popup_position_hospital" + row.id + sceneCode,//totab: true时需设置,用于判断是否已打开此页面
                                url: "module/md/page/terminal/page/popup/popup_position_hospital.html",
                                data: row,
                                delta: {dataname: me.selectTabObj.dataname,},
                                sceneCode: sceneCode,//"refuseedit",//"approval", //"add"//"browse",
                                callback: function(obj, callback) {
                                    me.onQuery();
                                    if (callback) {
                                        callback();
                                    }
                                }
                            };
                            me.doPopupByPublic(config);
                        },
                        //辖区医院新增
                        onAddData() {
                            var me = this;
                            var config = {
                                totab: true, //true: 以Tab导航的方式打开
                                width: "900px",
                                height: "900px",
                                icon: "icon-product",
                                text: "医院管理信息",
                                id: "hospital_list_info",//totab: true时需设置,用于判断是否已打开此页面
                                url: "module/md/page/terminal/page/hospital_list_info.html",
                                data: {},
                                delta: {},
                                sceneCode: "add",//"refuseedit",//"approval", //"add"//"browse",
                                callback: function(obj, callback) {
                                    //isSales提交后刷新'辖区审批中'tab
                                    // if(me.isSales) {
                                        var tab = {
                                            name: 'infoUnderApproval',
                                        };
                                        me.activeTabName = 'infoUnderApproval';
                                        me.handleClick(tab);
                                        me.onQuery();
                                    // } else {
                                    //     me.onQuery();
                                    // }
                                    if (callback) {
                                        callback();
                                    }
                                }
                            };
                            me.doPopupByPublic(config);
                        },
                        //辖区医院信息查看
                        showInfo(obj) {
                            var me = this;
                            var config = {
                                totab: true, //true: 以Tab导航的方式打开
                                width: "1200px",
                                height: "600px",
                                icon: "icon-product",
                                text: obj.row.name  + " 医院管理信息",
                                text: text,
                                id: "hospital_list_info" + "browse" + obj.row.id,//totab: true时需设置,用于判断是否已打开此页面
                                url: "module/md/page/terminal/page/hospital_list_info.html",
                                data: obj.row,
                                url: "module/tool/page/popup_list_dataname.html",
                                data: {},
                                dataname: dataname,
                                filter: filter, // "sell_qty_id='"+ obj.row.id +"'",
                                delta: {},
                                sceneCode: "browse", //"add"//"browse",
                                callback: function(obj, callback) {
                                    me.onQuery();
                                    if (callback) {
                                        callback();
                                    }
@@ -1015,7 +736,7 @@
                    <div style="float: right; margin-right: 18px;">
                        <el-button-group
                            v-if="selectTabObj && selectTabObj.code == 'month' && selectTabObj.filterObj.dataversion == '月度初版'"
                            v-if="selectTabObj && selectTabObj.code == 'month' && dataversion == '月度初版'"
                            style="margin-left: 3px;">
                            <el-button :disabled="!(selectTabObj.selectedrow && selectTabObj.selectedrow.biz_date)"
                                type="primary" @click="onAddSS" :icon="buttonsconfig.add.icon">申诉</el-button>
@@ -1035,7 +756,7 @@
                        <span v-if="selectTabObj && selectTabObj.code == 'daily'">{{newdate_day}}</span>
                        <el-radio-group style="margin-left: 10px;"
                            v-if="selectTabObj && selectTabObj.filterObj && selectTabObj.code=='month'"
                            v-model="selectTabObj.filterObj.dataversion" size="mini" fill="#4cb108">
                            v-model="dataversion" size="mini" fill="#4cb108">
                            <el-radio-button label="月度初版">初版</el-radio-button>
                            <el-radio-button label="月度终版">终版</el-radio-button>
                        </el-radio-group>
module/tool/page/popup_list_dataname.html
New file
@@ -0,0 +1,219 @@
<!doctype html>
<html>
    <head>
        <meta charset="utf-8"><meta http-equiv="Expires" content="0"><meta http-equiv="Pragma" content="no-cache"><meta http-equiv="Cache-control" content="no-cache"><meta http-equiv="Cache" content="no-cache">
        <title>列表弹窗</title>
        <script type="text/javascript">
            var pageVue = null;
            function loadJsCss(callback) {
                var jscss_urls = [];
                window.top.initJsCss(document, jscss_urls, callback);
            };
            function initVue() {
                new ListVue({
                    el: "#vbody",
                    data: {
                        dataname: "",
                        title: "列表弹窗",
                        pageAttr: {
                            heightType: "popuppage"
                        },
                        default_tableFields:  [],
                        filterAttr: {
                            columnnumber: 3,
                            labelwidth: "100px",
                            labelposition: "right",//"left",//"right",
                            size: "medium",
                            border: "0px solid #c6c6c600"
                        },
                        filterfieldClick: {},
                        tablefieldClick: {},
                        formfieldClick: {},
                        selectedrows: [],
                    },
                    created() {
                        this.popupParames = clone(Root.popupParames);
                        this.title = this.popupParames.title || this.popupParames.text
                        if (this.popupParames.filter) {
                            this.filterTxt = this.popupParames.filter
                        }
                        if (this.popupParames.dataname) {
                            this.dataname = this.popupParames.dataname;
                        }
                        else if (this.popupParames.delta.dataname) {
                            this.dataname = this.popupParames.delta.dataname;
                        }
                        if (this.popupParames.sceneCode) {
                            if (this.popupParames.sceneCode == "add") {//新增
                                this.isedit = true;
                            }
                        }
                    },
                    mounted() {
                        //获取数据
                        this.initData();
                        this.$nextTick(() => { // 以服务的方式调用的 Loading 需要异步关闭
                            hideLoading();
                        });
                    },
                    methods:{
                        //关闭弹窗
                        closeDialog() {
                            this.docloseDialog(true);
                        },
                        //关闭前调回调
                        saveAfter() {
                            var me = this;
                            var selectedrows = this.$refs.table1.getShoppingcart();
                            if(this.popupParames.callback) {
                                let obj = {
                                    list: clone(selectedrows)
                                    // row: clone(this.selectedrow)
                                }
                                this.popupParames.callback(obj, function() {
                                    me.docloseDialog();
                                });
                            }
                            else {
                                me.docloseDialog();
                            }
                        },
                        initData() {
                            var me = this;
                            this.onQuery(function(result, callback) {//查询后的回调,用于获取字段的
                                if (result.meta && result.meta[me.dataname] && result.meta[me.dataname].fields) {
                                    var metas = clone(result.meta[me.dataname].fields);
                                    var filterFields_ = [];
                                    var tableFields_ = [];
                                    metas.map(f=>{
                                        f.isshow = "T";
                                        if (f.isfilter) {
                                            filterFields_.push(clone(f));
                                        }
                                        else {
                                            var filter_f = clone(f);
                                            filter_f.isshow = "F";
                                        }
                                        tableFields_.push(clone(f));
                                    })
                                    if (!me.filterFields || (me.filterFields && me.filterFields.length == 0)) {
                                        me.filterFields = clone(filterFields_);
                                        me.tableFields = clone(tableFields_);
                                        //字段数组转字段obj,目的为了筛选时获取字段属性
                                        me.fieldsToFieldsObj();
                                        //设置字段事件
                                        me.tableFieldClick();
                                    }
                                }
                                if (callback) {
                                    callback();
                                }
                            });
                        },
                        tableFieldClick() {
                            var me = this;
                            //筛选字段事件设置
                            this.filterfieldClick = {
                            };
                            //表格字段事件设置
                            this.tablefieldClick = {
                            };
                            //表单字段事件设置
                            this.formfieldClick = {
                            };
                        },
                        selectionChange(obj){
                            var me = this;
                            me.selectedrows = obj;
                        },
                        saveShoppingcart(list) {
                            var me = this;
                            me.selectedrows = list;
                        },
                        onRowDblClick() {
                            if (this.isedit) {
                                this.saveAfter();
                            }
                        },
                    }
                });
            };
            loadJsCss(function () {
                initVue();
            });
        </script>
        <style>
            /* 在vue.js中 v-cloak 这个指令是防止页面加载时出现 vuejs 的变量名而设计的 */
            [v-cloak] {
                display: none !important;
            }
        </style>
    </head>
    <body style="margin: 0px;">
        <div v-cloak id="vbody">
            <div id="page_root">
                <div ref="popup_body" style="padding: 0 20px;">
                    <div class="h_dialog__body">
                        <h-table
                            v-if="isRefresh && tableFields.length"
                            ref="table1"
                            :table-fields="tableFields"
                            :table-data="tableData"
                            :pagesize="pagesize"
                            :pagenum="pagenum"
                            :total="total"
                            :table-height="tableHeight"
                            :table-field-click="tablefieldClick"
                            :is-highlight-row="isedit"
                            :is-show-index="false"
                            :filtersobj="filterObj"
                            :isdraggableorder="false"
                            v-on:get-data="getData"
                            v-on:row-click="rowClick"
                        >
                        </h-table>
                    </div>
                    <!-- 底部工具栏 -->
                    <div class="el-dialog__footer">
                        <el-button size="small" type="default" @click="closeDialog">取 消</el-button>
                        <el-button size="small" v-if="isedit" type="primary" @click="saveAfter">确 定</el-button>
                    </div>
                </div>
            </div>
        </div>
        <div id="page_loading" style="position: absolute; top:0px; width: 100vw; height: 50vh;">
            <div class="spinner">
              <div class="cube1"></div>
              <div class="cube2"></div>
            </div>
        </div>
    </body>
</html>