YYC
2023-10-19 6bd36a38fc587ba39bd50e26257ed6ece71363e7
igds-web/src/main/resources/static/admin/inout/out-ship-register.js
@@ -16,7 +16,7 @@
        });
        // 监听仓库选择,选择后自动调用仓库的粮品种和产地信息
        form.on('select(select_depotId)', function(obj) {
        form.on('select(select_depotId)', function (obj) {
            updateFoodVarietyByDepot(obj.value);
        });
    });
@@ -207,7 +207,7 @@
    // 渲染往来单位列表
    table.render({
        elem: '#tableNotice',
        url: '../../basic/inout/list-notice—out',
        url: '../../basic/inout/list-notice-out',
        page: false,
        // skin : "nob",
        // size : 'sm',
@@ -288,54 +288,54 @@
    var index = layer.load();
    // 渲染往来单位列表
    table.render({
        elem : '#tableFoodLoaction',
        url : '../../basic/common/page-food-location',
        page : false,
        toolbar : '#toolbarFoodLocaton',
        even : true,
        method : 'POST',
        contentType : "application/json;charset=UTF-8",
        cols : [ [ {
            field : 'code',
            title : '编码'
        elem: '#tableFoodLoaction',
        url: '../../basic/common/page-dicArea',
        page: false,
        toolbar: '#toolbarFoodLocaton',
        even: true,
        method: 'POST',
        contentType: "application/json;charset=UTF-8",
        cols: [[{
            field: 'code',
            title: '编码'
        }, {
            field : 'simple',
            title : '简拼'
            field: 'simple',
            title: '简拼'
        }, {
            field : 'name',
            title : '名称',
            width : '60%'
        } ] ],
        where : {
            "page" : 1,
            "limit" : 100
            field: 'name',
            title: '名称',
            width: '60%'
        }]],
        where: {
            "page": 1,
            "limit": 100
        },
        parseData : function(res) {
        parseData: function (res) {
            if ("0000" == res.code) {
                return {
                    "code" : "0",
                    "msg" : res.msg,
                    "count" : res.data.total,
                    "data" : res.data.records
                    "code": "0",
                    "msg": res.msg,
                    "count": res.data.total,
                    "data": res.data.records
                }
            } else {
                return {
                    "code" : "1",
                    "msg" : res.msg
                    "code": "1",
                    "msg": res.msg
                }
            }
        },
        done : function(res) {
        done: function (res) {
            layer.close(index);
        }
    });
    //双击显示选中数据
    table.on('rowDouble(tableFoodLoaction)', function(obj){
    table.on('rowDouble(tableFoodLoaction)', function (obj) {
        var data = obj.data;
        // 赋值
        form.val("form-data", {
            foodLocation : data.name,
            foodLocation: data.name,
        });
        // 关闭
        layer.close(index2);
@@ -343,18 +343,18 @@
    // 弹出对话框
    var index2 = layer.open({
        type : 1,
        title : "选择粮产地",
        area : [ '600px', '600px' ],
        shade : 0,
        content : $('#listFoodLocation'),
        btn : 0,
        btn : [ '取消' ],
        yes : function() {
        type: 1,
        title: "选择粮产地",
        area: ['600px', '600px'],
        shade: 0,
        content: $('#listFoodLocation'),
        btn: 0,
        btn: ['取消'],
        yes: function () {
            // 关闭
            layer.close(index2);
        },
        closeBtn : 0
        closeBtn: 0
    });
}
@@ -363,11 +363,11 @@
function flushFoodLocation() {
    var key = $("#key2").val();
    table.reload('tableFoodLoaction', {
        url : "../../basic/common/page-food-location",
        where : {
            key : key
        url: "../../basic/common/page-dicArea",
        where: {
            key: key
        },
        done : function(res) {
        done: function (res) {
            if (key) {
                $("#key2").val(key);
            }